From: nils t. <use...@ni...> - 2005-02-28 23:45:49
|
Moin *, this is about combining SKAS & XEN without having any clue. If you are only interested in the details, go here: <http://nils.toedtmann.net/stuff/xen-skas.txt> It does not really work, but almost. Maybe it's only a small last step to produce a functional SKAS-on-XEN-patch. Maybe someone could complete it? ###### I run several UMLs, and know i started playing with XEN. What is needed for testing and migration is a linux kernel which can act as a UML host (SKAS & sysemu patch) _and_ as a XEN host (XEN patch, configured for a "XEN domain 0"). So I patched a linuxtree with both and tried to understand why it would not work. Spending some time on the trial-and- error-method i came to the hypothesis (as i have NO F*CKING CLUE WHAT THE HELL I'M DOING HERE, i should say: wild guess) that i had to re-apply the SKAS-patches for arch/i386/* and include/asm-i386/* to arch/xen/i386/* and include/asm-xen/\ /asm-i386/*, too. Surprisingly that worked - more or less: The patches apply (with offsets, but no rejects), the host- kernel (XEN domain 0) builds, boots and runs. On that host- kernel, most applications run fine (firefox and some gnome- applets got unstable, but that seems to happen without SKAS, too). Indeed: now i can boot the same system image as a UML guest or as a XEN guest ("unprivileged domains"), and UML recog- nizes SKAS, /proc/mm & sysemu! Unfortunately, within my FC3 UMLs some binaries now crash :-( While sysV startup (including network, cron, syslog, sshd), bash, find, host, ping, ... all work fine, others like /bin/rpm or /bin/ls segfault. /usr/bin/vim also segfaults, but when it runs within strace, it works (WTF?). I could not produce such segfaults within a debian (woody) UML, yet. Example segfault (FC3, /bin/ls): <http://nils.toedtmann.net/stuff/ls-strace.txt> All segfaults i looked at end with set_thread_area(...) = -1 ENOSYS (Function not implemented) modify_ldt(...) = 0 --- SIGSEGV (Segmentation fault) @ 0 (0) --- The "set_thread_area(...) = -1 ENOSYS" is normal (or?), since there are no TLS libs any more, so it comes down to "modify_ldt". Maybe it's not coincidence that one of the kernel files i patched was arch/xen/i386/kernel/ldt.c ...? (ooops, yet another wild guess) When the host runs a non-SKAS XEN kernel, the segfaults in- side the UMLs disappear (but performance disappears, too). So it seems that this task cannot be accomplished without some knowledge ... anybody? /nils. ps: Booting a FC3 image as UML ... $ /home/uml/boot/linux-2.6.9-bb4-terminal-cleanup-nils9 umid=FC3test mem=128M \ con=null con0=null,fd:1 con1=fd:0,fd:1 eth0=tuntap,tap0,FE:FD:00:DE:AD:09 \ ubda=/home/uml/ubd/FC3-rootfs.ext3 ubdb=/home/uml/ubd/swap ... translates to this config file /etc/xen/FC3test.xm kernel = "/boot/vmlinuz-2.6.10-xen-2.0.4-domU-nils.2" name = "FC3test" memory = 128 nics = 1 vif = [ 'mac=FE:FD:00:DE:AD:09, bridge=xen-br0' ] disk = [ 'file:/home/uml/ubd/FC3-rootfs.ext3,hda1,w', 'file:/home/uml/ubd/swap,hda2,w' ] root = "/dev/hda1 ro" ... and this XEN domain startup command: # xm create -c FC3test.xm You only have to switch the guest's fstab from ubd* to hd*. -- there is no sig. |
From: Christopher S. A. <ca...@th...> - 2005-02-28 23:57:35
|
First off -- nice work. I attempted this a while back and quickly abandoned the idea :) > Unfortunately, within my FC3 UMLs some binaries now crash :-( > While sysV startup (including network, cron, syslog, sshd), > bash, find, host, ping, ... all work fine, others like > /bin/rpm or /bin/ls segfault. /usr/bin/vim also segfaults, > but when it runs within strace, it works (WTF?). I could not > produce such segfaults within a debian (woody) UML, yet. Dead give-away. UML doesn't support NPTL/TLS -- simply try: "mv /lib/tls /lib/tls-disabled" inside your guest filesystem. Following your script, it isn't clear to me if there's a final all-in-one diff for applying SKAS to Xen. Is one needed, or will your script take care of it? -Chris |
From: nils t. <use...@ni...> - 2005-03-01 13:33:09
|
On Mon, Feb 28, 2005 at 05:57:24PM -0600, Christopher S. Aker wrote: > >Unfortunately, within my FC3 UMLs some binaries now crash :-( > >While sysV startup (including network, cron, syslog, sshd), > >bash, find, host, ping, ... all work fine, others like > >/bin/rpm or /bin/ls segfault. /usr/bin/vim also segfaults, > >but when it runs within strace, it works (WTF?). I could not > >produce such segfaults within a debian (woody) UML, yet. > > Dead give-away. UML doesn't support NPTL/TLS -- simply try: "mv > /lib/tls /lib/tls-disabled" inside your guest filesystem. When i wrote ... > > The "set_thread_area(...) = -1 ENOSYS" is normal (or?), > > since there are no TLS libs any more, so it comes down to ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ... i exactly meant that :) This is a different problem. > Following your script, it isn't clear to me if there's a final > all-in-one diff for applying SKAS to Xen. Is one needed, or will your > script take care of it? I would not call that a script, it's more a journal of what i did. As xen comes with a script symlinking from the kernel tree to the xen tree, i first produce a classical xen-only patch. The last diff makes an all- in-one (xen & skas!) patch against the vanilla 2.6.10. But as i said: it doesn't work (yet). /nils. -- there is no sig. |
From: Christopher S. A. <ca...@th...> - 2005-03-01 18:39:11
|
>>>The "set_thread_area(...) = -1 ENOSYS" is normal (or?), >>>since there are no TLS libs any more, so it comes down to > > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ > ... i exactly meant that :) This is a different problem. Yeah, didn't see that line :) The issue with TLS/NPTL and UML is that it doesn't implement the get/set_thread_area syscalls, and AFAIK those syscalls should only me called from an NPTL enabled glibc. Perhaps the LD_ASSUME_KERNEL work-around will suffice for you. -Chris |
From: nils t. <use...@ni...> - 2005-03-01 21:56:12
|
On Tue, Mar 01, 2005 at 12:38:45PM -0600, Christopher S. Aker wrote: > >>>The "set_thread_area(...) = -1 ENOSYS" is normal (or?), > >>>since there are no TLS libs any more, so it comes down to > > > > ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ > >... i exactly meant that :) This is a different problem. > > Yeah, didn't see that line :) The issue with TLS/NPTL and UML is that > it doesn't implement the get/set_thread_area syscalls, and AFAIK those > syscalls should only me called from an NPTL enabled glibc. Perhaps the > LD_ASSUME_KERNEL work-around will suffice for you. As i understand it, the return code "-1 ENOSYS (Function not implemented)" of "set_thread_area()" is perfect - it means that set_thread_area() cannot be called because it's not there (because i deleted the TLS libs). You'll see that all the time on any running FC3 UML. The problem is the next function "modify_ldt()", it caused the segfault. Gerd Knorr solved it (kudos to him), see the other branch of this thread. No LD_ASSUME_KERNEL= needed. /nils. -- there is no sig. |
From: Jim C. <ji...@ma...> - 2005-03-01 01:54:24
|
On Tue, 1 Mar 2005, nils toedtmann wrote: > Unfortunately, within my FC3 UMLs some binaries now crash :-( > While sysV startup (including network, cron, syslog, sshd), > bash, find, host, ping, ... all work fine, others like > /bin/rpm or /bin/ls segfault. /usr/bin/vim also segfaults, > but when it runs within strace, it works (WTF?). I could not > produce such segfaults within a debian (woody) UML, yet. > --snip-- > All segfaults i looked at end with > > set_thread_area(...) = -1 ENOSYS (Function not implemented) > modify_ldt(...) = 0 > --- SIGSEGV (Segmentation fault) @ 0 (0) --- > > The "set_thread_area(...) = -1 ENOSYS" is normal (or?), > since there are no TLS libs any more, ... Is this how you discourage too-advanced TLS, by deleting or renaming /lib/tls/libc.so.6? It's a good move; an alternative in kernel 2.6.x, if you want to avoid mutilating distro files that might get "fixed" in online updates, is "export LD_ASSUME_KERNEL=2.4.1" (per BlaisorBlade) in a file in /etc/profile.d or your guest's $HOME/.profile or the equivalent for tcsh. And similarly when starting the UML kernel. SuSE provides a startup script exporting 2.4.21 and I've found that this is enough with kernel 2.6.8 and glibc-2.3.3. (I don't actually know if there was a change in TLS style between these endpoint versions.) When I was having TLS problems, though, "ls" ran and "host" crashed, for me on the guest without LD_ASSUME_KERNEL. Am I right that Debian Woody has a 2.4.x kernel, using a different TLS method, which UML can deal with? > so it comes down to > "modify_ldt". Maybe it's not coincidence that one of the > kernel files i patched was arch/xen/i386/kernel/ldt.c ...? > (ooops, yet another wild guess) Evidently the LDT is being monkeyed with despite your efforts. I notice that arch/um/sys-i386/kernel/ldt.c actually does something with PTRACE_LDT (not in the man page for ptrace) with SKAS, but with TT (as I've seen mentioned here and there) there is a separate host process per guest process, and ldt.c just passes the call through to the host O.S. Comments on this list indicate that LDT with SKAS is actively being developed but that progress is very difficult. If the XEN guest is not crashing, maybe the XEN people have some ideas for handling the LDT that could be made useful in UML. James F. Carter Voice 310 825 2897 FAX 310 206 6673 UCLA-Mathnet; 6115 MSA; 405 Hilgard Ave.; Los Angeles, CA, USA 90095-1555 Email: ji...@ma... http://www.math.ucla.edu/~jimc (q.v. for PGP key) |
From: Gerd K. <kr...@by...> - 2005-03-01 10:55:13
|
nils toedtmann <use...@ni...> writes: > Moin *, > > this is about combining SKAS & XEN without having any clue. Just did that last week. It's to be applied on top of 2.6.11-rc<recent> plus 2.6.11-v8-rc2 skas patch plus fix for that from bodo (fished from devel list) plus a batch of xen patches maintained by someone else ;) Port from arch/i386 to arch/xen was mostly straight forward, the only tricky thing is entry.S where you have to fixup the cli which isn't allowed in arch/xen. Enjoy, Gerd Subject: skas for arch/xen From: kr...@su... Patch-mainline: never Virtualization unlimited: run uml machines within xen domains ;) --- arch/xen/i386/Kconfig | 4 + arch/xen/i386/kernel/entry.S | 15 +++++- arch/xen/i386/kernel/ldt.c | 54 ++++++++++++++----------- include/asm-xen/asm-i386/desc.h | 3 + include/asm-xen/asm-i386/mmu_context.h | 19 +++++++- include/asm-xen/asm-i386/ptrace.h | 22 ++++++++++ 6 files changed, 90 insertions(+), 27 deletions(-) Index: linux-2.6.10/arch/xen/i386/Kconfig =================================================================== --- linux-2.6.10.orig/arch/xen/i386/Kconfig 2005-02-23 08:25:31.000000000 +0100 +++ linux-2.6.10/arch/xen/i386/Kconfig 2005-02-23 14:48:54.000000000 +0100 @@ -958,4 +958,8 @@ config PC depends on X86 && !EMBEDDED default y +config PROC_MM + bool "/proc/mm support" + default y + endmenu Index: linux-2.6.10/include/asm-xen/asm-i386/ptrace.h =================================================================== --- linux-2.6.10.orig/include/asm-xen/asm-i386/ptrace.h 2005-02-23 08:25:31.000000000 +0100 +++ linux-2.6.10/include/asm-xen/asm-i386/ptrace.h 2005-02-23 14:48:54.000000000 +0100 @@ -64,4 +64,26 @@ extern unsigned long profile_pc(struct p #endif #endif +/*For SKAS3 support.*/ +#ifndef _LINUX_PTRACE_STRUCT_DEF +#define _LINUX_PTRACE_STRUCT_DEF + +#define PTRACE_FAULTINFO 52 +#define PTRACE_SIGPENDING 53 +#define PTRACE_LDT 54 +#define PTRACE_SWITCH_MM 55 + +struct ptrace_faultinfo { + int is_write; + unsigned long addr; +}; + +struct ptrace_ldt { + int func; + void *ptr; + unsigned long bytecount; +}; + +#endif /*ifndef _LINUX_PTRACE_STRUCT_DEF*/ + #endif Index: linux-2.6.10/arch/xen/i386/kernel/ldt.c =================================================================== --- linux-2.6.10.orig/arch/xen/i386/kernel/ldt.c 2005-02-23 08:25:31.000000000 +0100 +++ linux-2.6.10/arch/xen/i386/kernel/ldt.c 2005-02-23 14:58:10.000000000 +0100 @@ -18,6 +18,7 @@ #include <asm/system.h> #include <asm/ldt.h> #include <asm/desc.h> +#include <asm/mmu_context.h> #ifdef CONFIG_SMP /* avoids "defined but not used" warnig */ static void flush_ldt(void *null) @@ -29,11 +30,12 @@ static void flush_ldt(void *null) } #endif -static int alloc_ldt(mm_context_t *pc, int mincount, int reload) +static int alloc_ldt(struct mm_struct *mm, int mincount, int reload) { void *oldldt; void *newldt; int oldsize; + mm_context_t * pc = &mm->context; if (mincount <= pc->size) return 0; @@ -63,11 +65,12 @@ static int alloc_ldt(mm_context_t *pc, i #endif make_pages_readonly(pc->ldt, (pc->size * LDT_ENTRY_SIZE) / PAGE_SIZE); - load_LDT(pc); + if (¤t->active_mm->context == pc) + load_LDT(pc); flush_page_update_queue(); #ifdef CONFIG_SMP mask = cpumask_of_cpu(smp_processor_id()); - if (!cpus_equal(current->mm->cpu_vm_mask, mask)) + if (!cpus_equal(mm->cpu_vm_mask, mask)) smp_call_function(flush_ldt, NULL, 1, 1); preempt_enable(); #endif @@ -84,13 +87,13 @@ static int alloc_ldt(mm_context_t *pc, i return 0; } -static inline int copy_ldt(mm_context_t *new, mm_context_t *old) +static inline int copy_ldt(struct mm_struct *new, struct mm_struct *old) { - int err = alloc_ldt(new, old->size, 0); + int err = alloc_ldt(new, old->context.size, 0); if (err < 0) return err; - memcpy(new->ldt, old->ldt, old->size*LDT_ENTRY_SIZE); - make_pages_readonly(new->ldt, (new->size * LDT_ENTRY_SIZE) / + memcpy(new->context.ldt, old->context.ldt, old->context.size*LDT_ENTRY_SIZE); + make_pages_readonly(new->context.ldt, (new->context.size * LDT_ENTRY_SIZE) / PAGE_SIZE); flush_page_update_queue(); return 0; @@ -100,22 +103,24 @@ static inline int copy_ldt(mm_context_t * we do not have to muck with descriptors here, that is * done in switch_mm() as needed. */ -int init_new_context(struct task_struct *tsk, struct mm_struct *mm) +int copy_context(struct mm_struct *mm, struct mm_struct *old_mm) { - struct mm_struct * old_mm; int retval = 0; - init_MUTEX(&mm->context.sem); - mm->context.size = 0; - old_mm = current->mm; if (old_mm && old_mm->context.size > 0) { down(&old_mm->context.sem); - retval = copy_ldt(&mm->context, &old_mm->context); + retval = copy_ldt(mm, old_mm); up(&old_mm->context.sem); } return retval; } +int init_new_context(struct task_struct *tsk, struct mm_struct *mm) +{ + init_new_empty_context(mm); + return copy_context(mm, current->mm); +} + /* * No need to lock the MM as we are the last user */ @@ -136,11 +141,11 @@ void destroy_context(struct mm_struct *m } } -static int read_ldt(void __user * ptr, unsigned long bytecount) +static int read_ldt(struct mm_struct * mm, void __user * ptr, + unsigned long bytecount) { int err; unsigned long size; - struct mm_struct * mm = current->mm; if (!mm->context.size) return 0; @@ -189,9 +194,8 @@ static int read_default_ldt(void __user return err; } -static int write_ldt(void __user * ptr, unsigned long bytecount, int oldmode) +static int write_ldt(struct mm_struct * mm, void __user * ptr, unsigned long bytecount, int oldmode) { - struct mm_struct * mm = current->mm; __u32 entry_1, entry_2, *lp; unsigned long mach_lp; int error; @@ -216,7 +220,7 @@ static int write_ldt(void __user * ptr, down(&mm->context.sem); if (ldt_info.entry_number >= mm->context.size) { - error = alloc_ldt(¤t->mm->context, ldt_info.entry_number+1, 1); + error = alloc_ldt(mm, ldt_info.entry_number+1, 1); if (error < 0) goto out_unlock; } @@ -248,23 +252,29 @@ out: return error; } -asmlinkage int sys_modify_ldt(int func, void __user *ptr, unsigned long bytecount) +int __modify_ldt(struct mm_struct * mm, int func, void __user *ptr, + unsigned long bytecount) { int ret = -ENOSYS; switch (func) { case 0: - ret = read_ldt(ptr, bytecount); + ret = read_ldt(mm, ptr, bytecount); break; case 1: - ret = write_ldt(ptr, bytecount, 1); + ret = write_ldt(mm, ptr, bytecount, 1); break; case 2: ret = read_default_ldt(ptr, bytecount); break; case 0x11: - ret = write_ldt(ptr, bytecount, 0); + ret = write_ldt(mm, ptr, bytecount, 0); break; } return ret; } + +asmlinkage int sys_modify_ldt(int func, void __user *ptr, unsigned long bytecount) +{ + return __modify_ldt(current->mm, func, ptr, bytecount); +} Index: linux-2.6.10/include/asm-xen/asm-i386/mmu_context.h =================================================================== --- linux-2.6.10.orig/include/asm-xen/asm-i386/mmu_context.h 2005-02-23 08:25:31.000000000 +0100 +++ linux-2.6.10/include/asm-xen/asm-i386/mmu_context.h 2005-02-23 15:00:27.000000000 +0100 @@ -6,13 +6,25 @@ #include <asm/atomic.h> #include <asm/pgalloc.h> #include <asm/tlbflush.h> +#include <asm/semaphore.h> /* - * Used for LDT copy/destruction. + * Used for LDT initialization/destruction. You cannot copy an LDT with + * init_new_context, since it thinks you are passing it a new LDT and won't + * deallocate its old content. */ int init_new_context(struct task_struct *tsk, struct mm_struct *mm); void destroy_context(struct mm_struct *mm); +/* LDT initialization for a clean environment - needed for SKAS.*/ +static inline void init_new_empty_context(struct mm_struct *mm) +{ + init_MUTEX(&mm->context.sem); + mm->context.size = 0; +} + +/* LDT copy for SKAS - for the above problem.*/ +int copy_context(struct mm_struct *mm, struct mm_struct *old_mm); static inline void enter_lazy_tlb(struct mm_struct *mm, struct task_struct *tsk) { @@ -29,6 +41,10 @@ static inline void switch_mm(struct mm_s { int cpu = smp_processor_id(); +#ifdef CONFIG_SMP + prev = per_cpu(cpu_tlbstate, cpu).active_mm; +#endif + if (likely(prev != next)) { /* stop flush ipis for the previous mm */ cpu_clear(cpu, prev->cpu_vm_mask); @@ -50,7 +66,6 @@ static inline void switch_mm(struct mm_s #ifdef CONFIG_SMP else { per_cpu(cpu_tlbstate, cpu).state = TLBSTATE_OK; - BUG_ON(per_cpu(cpu_tlbstate, cpu).active_mm != next); if (!cpu_test_and_set(cpu, next->cpu_vm_mask)) { /* We were in lazy tlb mode and leave_mm disabled Index: linux-2.6.10/include/asm-xen/asm-i386/desc.h =================================================================== --- linux-2.6.10.orig/include/asm-xen/asm-i386/desc.h 2005-02-23 08:25:31.000000000 +0100 +++ linux-2.6.10/include/asm-xen/asm-i386/desc.h 2005-02-23 15:03:45.000000000 +0100 @@ -128,6 +128,9 @@ static inline void load_LDT(mm_context_t put_cpu(); } +extern int __modify_ldt(struct mm_struct * mm, int func, void __user *ptr, + unsigned long bytecount); + #endif /* !__ASSEMBLY__ */ #endif Index: linux-2.6.10/arch/xen/i386/kernel/entry.S =================================================================== --- linux-2.6.10.orig/arch/xen/i386/kernel/entry.S 2005-02-23 08:25:31.000000000 +0100 +++ linux-2.6.10/arch/xen/i386/kernel/entry.S 2005-02-23 15:51:32.000000000 +0100 @@ -244,7 +244,7 @@ sysenter_past_esp: SAVE_ALL GET_THREAD_INFO(%ebp) - testb $(_TIF_SYSCALL_TRACE|_TIF_SYSCALL_AUDIT),TI_flags(%ebp) + testb $(_TIF_SYSCALL_EMU|_TIF_SYSCALL_TRACE|_TIF_SYSCALL_AUDIT),TI_flags(%ebp) jnz syscall_trace_entry cmpl $(nr_syscalls), %eax jae syscall_badsys @@ -267,8 +267,8 @@ ENTRY(system_call) pushl %eax # save orig_eax SAVE_ALL GET_THREAD_INFO(%ebp) - # system call tracing in operation - testb $(_TIF_SYSCALL_TRACE|_TIF_SYSCALL_AUDIT),TI_flags(%ebp) + # system call tracing in operation / emulation + testb $(_TIF_SYSCALL_EMU|_TIF_SYSCALL_TRACE|_TIF_SYSCALL_AUDIT),TI_flags(%ebp) jnz syscall_trace_entry cmpl $(nr_syscalls), %eax jae syscall_badsys @@ -344,10 +344,19 @@ syscall_trace_entry: movl %esp, %eax xorl %edx,%edx call do_syscall_trace + cmpl $0, %eax + jne syscall_skip # ret != 0 -> running under PTRACE_SYSEMU, + # so must skip actual syscall movl ORIG_EAX(%esp), %eax cmpl $(nr_syscalls), %eax jnae syscall_call jmp syscall_exit +syscall_skip: + XEN_BLOCK_EVENTS(%esi) # make sure we don't miss an interrupt + # setting need_resched or sigpending + # between sampling and the iret + movl TI_flags(%ebp), %ecx + jmp work_pending # perform syscall exit tracing ALIGN |
From: nils t. <use...@ni...> - 2005-03-01 13:22:50
|
On Tue, Mar 01, 2005 at 11:53:21AM +0100, Gerd Knorr wrote: > nils toedtmann <use...@ni...> writes: > > this is about combining SKAS & XEN without having any clue. > > Just did that last week. ... but _with_ clue ;-) Thanks! > It's to be applied on top of 2.6.11-rc<recent> plus 2.6.11-v8-rc2 > skas patch plus fix for that from bodo (fished from devel list) You probably mean this one: <http://sourceforge.net/mailarchive/message.php?msg_id=10867344> Blaisorblade: <http://www.user-mode-linux.org/~blaisorblade/patches/skas3-2.6/skas-2.6.11-v8-rc2-fix.patch> gives a 403. > plus a batch of xen patches maintained by someone else ;) Where did you find them? xen-[2.0.4|2.0-testing|unstable] only has patches for 2.6.10. When i apply them to 2.6.11-rc5 it won't compile :-( Or did you a bk pull? > Port from arch/i386 to arch/xen was mostly straight forward, the only > tricky thing is entry.S where you have to fixup the cli which isn't > allowed in arch/xen. Can that be backported to 2.6.10-skas-v7 using nothing but human patternmatching ;-? > Virtualization unlimited: run uml machines within xen domains ;) We are not the only ones: somebody wants to run vservers within xen domains: <http://thread.gmane.org/gmane.comp.emulators.xen.devel/6716> /nils. -- there is no sig. |
From: Gerd K. <kr...@by...> - 2005-03-01 14:25:09
|
> <http://sourceforge.net/mailarchive/message.php?msg_id=10867344> Yes, that one. > > plus a batch of xen patches maintained by someone else ;) > > Where did you find them? xen-[2.0.4|2.0-testing|unstable] only > has patches for 2.6.10. When i apply them to 2.6.11-rc5 it won't > compile :-( Or did you a bk pull? ftp://ftp.suse.com/pub/projects/kernel/kotd/i386/HEAD/ It's actually 2.6.11-rc4+, althrough the rpm version is 2.6.10. ready-to-go binary kernels for suse, the kernel-source.src.rpm contains all the individual patches. Some are home-brew I think (adaption for 4lvl page tables for example), not from the xen project. > Can that be backported to 2.6.10-skas-v7 using nothing but > human patternmatching ;-? Should be easy. Just diff xen entry.S against i386 entry.S and you'll see what must be changed ;) > We are not the only ones: somebody wants to run vservers > within xen domains: I've seen that as well ;) Gerd |
From: nils t. <use...@ni...> - 2005-03-01 17:05:17
|
On Tue, Mar 01, 2005 at 03:22:03PM +0100, Gerd Knorr wrote: > > <http://sourceforge.net/mailarchive/message.php?msg_id=10867344> > > Yes, that one. > > > > plus a batch of xen patches maintained by someone else ;) > > > > Where did you find them? xen-[2.0.4|2.0-testing|unstable] only > > has patches for 2.6.10. When i apply them to 2.6.11-rc5 it won't > > compile :-( Or did you a bk pull? > > ftp://ftp.suse.com/pub/projects/kernel/kotd/i386/HEAD/ > > It's actually 2.6.11-rc4+, althrough the rpm version is 2.6.10. > > ready-to-go binary kernels for suse, the kernel-source.src.rpm > contains all the individual patches. Some are home-brew I think > (adaption for 4lvl page tables for example), not from the xen > project. > > > Can that be backported to 2.6.10-skas-v7 using nothing but > > human patternmatching ;-? > > Should be easy. Just diff xen entry.S against i386 entry.S and > you'll see what must be changed ;) I was lazy and applied xen-2.0.4, Blaisorblades skas-2.6.11-v8-rc2 and your patch to 2.6.10. Works better now: No more segfaults in my UMLs! Thanks! Only the Xen tools in domain 0 sometimes looses connection to the Xen kernel (so i cannot control domains via "xm" any more), but i doubt that this has anything to do with SKAS. /nils. Summary: <http://nils.toedtmann.net/stuff/virtualization/xen-skas.txt> Selfcontained Xen patch for 2.6.10: <http://nils.toedtmann.net/stuff/virtualization/linux-2.6.10-xen-2.0.4.patch.bz2> Gerd Knorr's combo patch: <http://nils.toedtmann.net/stuff/virtualization/skas-2.6.11-v8-rc2-xen-2.0-gknorr.patch> All-in-one-patch including SKAS & XEN: <http://nils.toedtmann.net/stuff/virtualization/linux-2.6.10-skas3-v8-rc2-xen-2.0.4-gknorr.patch.bz2> -- there is no sig. -- there is no sig. |
From: Gerd K. <kr...@by...> - 2005-03-01 17:25:14
|
> Only the Xen tools in domain 0 sometimes looses connection to the > Xen kernel (so i cannot control domains via "xm" any more), but > i doubt that this has anything to do with SKAS. Network setup is a bit tricky indeed because both xen and uml use bridges to make virtual machines appear transparently on the physical network. Its easy to get that wrong ... xm connects to xend via localhost (i.e. loop device) though, so that shouldn't cause trouble in theory. Double-checking routing and interfaces is worth a try neverless. Gerd |
From: Blaisorblade <bla...@ya...> - 2005-03-02 14:30:53
|
On Tuesday 01 March 2005 15:22, Gerd Knorr wrote: > > <http://sourceforge.net/mailarchive/message.php?msg_id=10867344> > > Yes, that one. > > > > plus a batch of xen patches maintained by someone else ;) > > > > Where did you find them? xen-[2.0.4|2.0-testing|unstable] only > > has patches for 2.6.10. When i apply them to 2.6.11-rc5 it won't > > compile :-( Or did you a bk pull? > > ftp://ftp.suse.com/pub/projects/kernel/kotd/i386/HEAD/ > > It's actually 2.6.11-rc4+, althrough the rpm version is 2.6.10. > > ready-to-go binary kernels for suse, the kernel-source.src.rpm > contains all the individual patches. Some are home-brew I think > (adaption for 4lvl page tables for example), not from the xen > project. > > > Can that be backported to 2.6.10-skas-v7 using nothing but > > human patternmatching ;-? > > Should be easy. Just diff xen entry.S against i386 entry.S and > you'll see what must be changed ;) > > > We are not the only ones: somebody wants to run vservers > > within xen domains: > I've seen that as well ;) And some more time ago, somebody asked about combining SKAS and vserver patches... to run UMLs inside and outside vservers. -- Paolo Giarrusso, aka Blaisorblade Linux registered user n. 292729 http://www.user-mode-linux.org/~blaisorblade |
From: Blaisorblade <bla...@ya...> - 2005-03-02 15:08:52
|
On Tuesday 01 March 2005 14:22, nils toedtmann wrote: > On Tue, Mar 01, 2005 at 11:53:21AM +0100, Gerd Knorr wrote: > Blaisorblade: > <http://www.user-mode-linux.org/~blaisorblade/patches/skas3-2.6/skas-2.6.11 >-v8-rc2-fix.patch> gives a 403. Sorry, fixed. Simply kmail saved the fail with 0700 permission and I didn't notice. -- Paolo Giarrusso, aka Blaisorblade Linux registered user n. 292729 http://www.user-mode-linux.org/~blaisorblade |