[uClibc] chroot issues with busybox+uclibc

ShadowRage shadowrage at acidchat.net
Wed Oct 22 01:19:36 UTC 2003


turns out to be that since busybox is having trouble multitasking.. it wont run env or any of those... so it freaks out.
and I accidently installed busybox over the root_fs
if anyone has the glibc version of busybox for the root fs.. send it
On Tue, 21 Oct 2003 06:12:07 -0700
ShadowRage <shadowrage at acidchat.net> wrote:

> 
>  strace -f -F chroot /mnt/lfs/tsunami/AcidLinux /usr/bin/env -i     HOME=/root TERM=$TERM PS1='\u:\w\$ ' PATH=/bin:/usr/bin:/sbin:/usr/sbin:/bin /bin/ash --login
> execve("/usr/sbin/chroot", ["chroot", "/mnt/lfs/tsunami/AcidLinux", "/usr/bin/env", "-i", "HOME=/root", "TERM=rxvt", "PS1=\\u:\\w\\$ ", "PATH=/bin:/usr/bin:/sbin:/usr/sbin:/bin", "/bin/ash", "--login"], [/* 45 vars */]) = 0
> uname({sys="Linux", node="Monolith.gamersmix", ...}) = 0
> brk(0)                                  = 0x804b7c4
> open("/etc/ld.so.preload", O_RDONLY)    = -1 ENOENT (No such file or directory)
> open("/etc/ld.so.cache", O_RDONLY)      = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=81050, ...}) = 0
> old_mmap(NULL, 81050, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40012000
> close(3)                                = 0
> open("/lib/i686/libc.so.6", O_RDONLY)   = 3
> read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\220\201"..., 1024) = 1024
> fstat64(3, {st_mode=S_IFREG|0755, st_size=1167240, ...}) = 0
> old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40026000
> old_mmap(NULL, 1179584, PROT_READ|PROT_EXEC, MAP_PRIVATE, 3, 0) = 0x40027000
> mprotect(0x4013e000, 36800, PROT_NONE)  = 0
> old_mmap(0x4013e000, 20480, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 3, 0x117000) = 0x4013e000
> old_mmap(0x40143000, 16320, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x40143000
> close(3)                                = 0
> munmap(0x40012000, 81050)               = 0
> brk(0)                                  = 0x804b7c4
> brk(0x804b7ec)                          = 0x804b7ec
> brk(0x804c000)                          = 0x804c000
> open("/usr/share/locale/locale.alias", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=2601, ...}) = 0
> mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40012000
> read(3, "# Locale name alias data base.\n#"..., 4096) = 2601
> brk(0x804d000)                          = 0x804d000
> read(3, "", 4096)                       = 0
> close(3)                                = 0
> munmap(0x40012000, 4096)                = 0
> open("/usr/share/locale/en_US/LC_IDENTIFICATION", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=370, ...}) = 0
> mmap2(NULL, 370, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40012000
> close(3)                                = 0
> open("/usr/share/locale/en_US/LC_MEASUREMENT", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=28, ...}) = 0
> mmap2(NULL, 28, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40013000
> close(3)                                = 0
> open("/usr/share/locale/en_US/LC_TELEPHONE", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=64, ...}) = 0
> mmap2(NULL, 64, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40014000
> close(3)                                = 0
> open("/usr/share/locale/en_US/LC_ADDRESS", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=160, ...}) = 0
> mmap2(NULL, 160, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40015000
> close(3)                                = 0
> open("/usr/share/locale/en_US/LC_NAME", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=82, ...}) = 0
> mmap2(NULL, 82, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40016000
> close(3)                                = 0
> open("/usr/share/locale/en_US/LC_PAPER", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=39, ...}) = 0
> mmap2(NULL, 39, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40017000
> close(3)                                = 0
> open("/usr/share/locale/en_US/LC_MESSAGES", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
> close(3)                                = 0
> open("/usr/share/locale/en_US/LC_MESSAGES/SYS_LC_MESSAGES", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=57, ...}) = 0
> mmap2(NULL, 57, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40018000
> close(3)                                = 0
> open("/usr/share/locale/en_US/LC_MONETARY", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=291, ...}) = 0
> mmap2(NULL, 291, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40019000
> close(3)                                = 0
> open("/usr/share/locale/en_US/LC_COLLATE", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=21499, ...}) = 0
> mmap2(NULL, 21499, PROT_READ, MAP_PRIVATE, 3, 0) = 0x4001a000
> close(3)                                = 0
> open("/usr/share/locale/en_US/LC_TIME", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=2456, ...}) = 0
> mmap2(NULL, 2456, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40020000
> close(3)                                = 0
> open("/usr/share/locale/en_US/LC_NUMERIC", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=59, ...}) = 0
> mmap2(NULL, 59, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40021000
> close(3)                                = 0
> brk(0x804e000)                          = 0x804e000
> open("/usr/share/locale/en_US/LC_CTYPE", O_RDONLY) = 3
> fstat64(3, {st_mode=S_IFREG|0644, st_size=173408, ...}) = 0
> mmap2(NULL, 173408, PROT_READ, MAP_PRIVATE, 3, 0) = 0x40147000
> close(3)                                = 0
> chroot("/mnt/lfs/tsunami/AcidLinux")    = 0
> chdir("/")                              = 0
> execve("/usr/bin/env", ["/usr/bin/env", "-i", "HOME=/root", "TERM=rxvt", "PS1=\\u:\\w\\$ ", "PATH=/bin:/usr/bin:/sbin:/usr/sb"..., "/bin/ash", "--login"], [/* 45 vars */]) = 0
> old_mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, 0, 0) = 0x40005000
> readlink("/lib/ld-uClibc.so.0", "ld-uClibc-0.9.21.so", 1024) = 19
> open("/lib/libm.so.0", O_RDONLY)        = 3
> read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\310\26"..., 4096) = 4096
> old_mmap(NULL, 57344, PROT_NONE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40006000
> old_mmap(0x40006000, 50264, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 3, 0) = 0x40006000
> old_mmap(0x40013000, 1524, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 3, 0xc000) = 0x40013000
> close(3)                                = 0
> open("/lib/libc.so.0", O_RDONLY)        = 3
> read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0 \335\0"..., 4096) = 4096
> old_mmap(NULL, 270336, PROT_NONE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40014000
> old_mmap(0x40014000, 249883, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 3, 0) = 0x40014000
> old_mmap(0x40052000, 3852, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 3, 0x3d000) = 0x40052000
> old_mmap(0x40053000, 11628, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x40053000
> close(3)                                = 0
> ioctl(0, SNDCTL_TMR_TIMEBASE, {B38400 opost isig icanon echo ...}) = 0
> ioctl(1, SNDCTL_TMR_TIMEBASE, {B38400 opost isig icanon echo ...}) = 0
> brk(0x8172b2c)                          = 0x8172b2c
> brk(0x8173000)                          = 0x8173000
> brk(0x8174000)                          = 0x8174000
> brk(0x8175000)                          = 0x8175000
> --- SIGSEGV (Segmentation fault) ---
> +++ killed by SIGSEGV +++
> 
> I disabled the use of /etc/busybox.conf
> and turned off locale support
> and turned on debug support in busybox
> any ideas?
> 
> On Mon, 20 Oct 2003 19:06:17 -0600
> Erik Andersen <andersen at codepoet.org> wrote:
> 
> > On Mon Oct 20, 2003 at 05:03:40PM -0700, ShadowRage wrote:
> > > 
> > > chroot /mnt/lfs/tsunami/AcidLinux /usr/bin/env -i     HOME=/root TERM=$TERM PS1='\u:\w\$ ' PATH=/bin:/usr/bin:/sbin:/usr/sbin:/bin /bin/ash --login
> > > Using fallback suid method
> > > Segmentation fault
> > > 
> > > 
> > > ideas?
> > 
> > Could you provide a bit more detail as to exactly which versions
> > of various things you are using and for which architecture?  You
> > may also want to try doing an 'strace -f -F' of the segfaulting
> > process...
> > 
> >  -Erik
> > 
> > --
> > Erik B. Andersen             http://codepoet-consulting.com/
> > --This message was written using 73% post-consumer electrons--
> 
> 
> -- 
> AcidChat IRC Network
> www.acidchat.net
> free chatrooms!
> _______________________________________________
> uClibc mailing list
> uClibc at uclibc.org
> http://uclibc.org/mailman/listinfo/uclibc


-- 
AcidChat IRC Network
www.acidchat.net
free chatrooms!



More information about the uClibc mailing list