mdev and usb device node creation
Greetings: I am using an older version of busybox (1.7.0) with a newer linux kernel (3.10) and trying to get it to discover and dynamically create usb device nodes underneath /dev/bus/usb. This doesn't seem to work when I execute mdev with the -s option. Can someone please tell me if this capability is supported in newer versions of busybox? Thanks, Dallas ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
Re: mdev and usb device node creation
On Tue, Mar 10, 2015 at 4:48 PM, Harald Becker ra...@gmx.de wrote: Hi Dallas ! I am using an older version of busybox (1.7.0) with a newer linux kernel (3.10) and trying to get it to discover and dynamically create usb device nodes underneath /dev/bus/usb. This doesn't seem to work when I execute mdev with the -s option. And were is the rest of your setup? What matching entries in /etc/mdev.conf belong to your concern? Can someone please tell me if this capability is supported in newer versions of busybox? mdev -s scans the sys file system for devices and setup the /dev entries. If you want dynamic setup you should use the hotplug feature, but the device node handling of both depend on the entries in /etc/mdev.conf. So what happens and when, what is wrong in your eyes? May be you just need to enter your correct device setup. -- Harald ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox Hi Harald, I was sort of expecting a mdev scan to discover and create device nodes for usb. Sounds like I need some rules defined in /etc/mdev.conf. I just have a default one. In the meantime, I have been dynamically adding / removing the usb device nodes triggered off of hotplug events. Seems to be working fine so far. ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
Is it possible to cancel a poweroff?
Is there any way to cancel a delayed poweroff like you can with the traditional shutdown -c ? ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
Re: hfsprogs
Thanks Gilles. The Debian package was a very good starting point. I had to make a few more tweaks to be able to cross-compile, but it builds fine. I appreciate the help! Dallas On Sat, Nov 13, 2010 at 2:17 AM, Gilles Espinasse g@free.fr wrote: - Original Message - From: Dallas Clement dallas.a.clem...@gmail.com To: busybox@busybox.net Sent: Friday, November 12, 2010 9:26 PM Subject: hfsprogs Hi, Do you any of you busybox users have experience building hfsprogs from source? I am befuddled by the package builder makefiles that come with. Seems like there has got to be an easier way, i.e. configure, make etc. I downloaded the source from http://hfsprogs.sourcearchive.com/. I was hoping for something that was as easy to build as e2fsprogs. Is there an easier way to build these utilities? Any advice much appreciated. Thanks, Dallas You could look how debian do at https://buildd.debian.org/pkg.cgi?pkg=hfsprogs Gilles ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
hfsprogs
Hi, Do you any of you busybox users have experience building hfsprogs from source? I am befuddled by the package builder makefiles that come with. Seems like there has got to be an easier way, i.e. configure, make etc. I downloaded the source from http://hfsprogs.sourcearchive.com/. I was hoping for something that was as easy to build as e2fsprogs. Is there an easier way to build these utilities? Any advice much appreciated. Thanks, Dallas ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
Having problems with init
Hi All, I'm struggling to get init to find /etc/init.d/inittab and or execute /etc/init.d/rcS. It just sits and waits on nanosleep. I have included the strace output below. I'm using version 1.7.0 ( I know it's a bit old, but I'm not able to upgrade it for this project ). I don't think I'm doing anything too out of the ordinary. I am able to successfully NFS mount my root file system. I execute the following from my initrd / linuxrc: /sbin/ifconfig eth1 192.168.1.40 up mount -o nolock 192.168.1.5:/home/dallasc/development/cs/BTUS/hddroot/img /mnt cd /mnt mkdir -p initrd ls . /sbin/pivot_root . initrd if [ $? != 0 ]; then echo pivot root failed else exec chroot . /usr/local/bin/strace /sbin/init \ dev/console dev/console 21 umount /initrd If I replace /sbin/init with /bin/sh, I get a shell prompt and I can look at my NFS mounted root fs. So I know that the exec is working and I can execute binaries over NFS. init however just sits and waits forever on nanosleep. I don't see it attempt to open the inittab file or the rcS file. Could it perhaps be a UID or PID problem? Any help, much appreciated. Thanks, Dallas execve(/sbin/init, [/sbin/init], [/* 8 vars */]) = 0 brk(0) = 0xde000 uname({sys=Linux, node=(none), ...}) = 0 mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x4001d000 access(/etc/ld.so.preload, R_OK) = -1 ENOENT (No such file or directory) open(/etc/ld.so.cache, O_RDONLY) = 3 fstat64(3, {st_mode=S_IFREG|0644, st_size=7909, ...}) = 0 mmap2(NULL, 7909, PROT_READ, MAP_PRIVATE, 3, 0) = 0x4001e000 close(3)= 0 open(/lib/libm.so.6, O_RDONLY)= 3 read(3, \177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0(\0\1\0\0\0\0342\0\000..., 512) = 512 fstat64(3, {st_mode=S_IFREG|0755, st_size=739248, ...}) = 0 mmap2(NULL, 712856, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x40026000 mprotect(0x400cc000, 28672, PROT_NONE) = 0 mmap2(0x400d3000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xa5) = 0x400d3000 close(3)= 0 open(/lib/libc.so.6, O_RDONLY)= 3 read(3, \177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0(\0\1\0\0\0\340J\1\000..., 512) = 512 fstat64(3, {st_mode=S_IFREG|0755, st_size=1481034, ...}) = 0 mmap2(NULL, 1237404, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x400d5000 mprotect(0x401f7000, 28672, PROT_NONE) = 0 mmap2(0x401fe000, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x121) = 0x401fe000 mmap2(0x40201000, 8604, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x40201000 close(3)= 0 mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x4002 syscall_983045(0x400204a0, 0x400256f4, 0x40020b78, 0x40025058, 0x40, 0x40025000, 0, 0xf0005, 0x40025738, 0x1, 0, 0xbe87cbbc, 0, 0xbe87c930, 0x88, 0x40002290, 0x2010, 0x400204a0, 0, 0, 0xdbe0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0) = 0 mprotect(0x401fe000, 8192, PROT_READ) = 0 mprotect(0x400d3000, 4096, PROT_READ) = 0 munmap(0x4001e000, 7909)= 0 getpid()= 629 getuid32() = 0 brk(0) = 0xde000 brk(0x109000) = 0x109000 mmap2(NULL, 401408, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40204000 munmap(0x40204000, 401408) = 0 write(2, BusyBox v1.15.3 (2010-04-23 20:1..., 41BusyBox v1.15.3 (2010-04-23 20:10:06 JST)) = 41 write(2, multi-call binary\n, 19 multi-call binary )= 19 write(2, \nUsage: , 8 Usage: )= 8 write(2, init, 4init) = 4 write(2, , 1 )= 1 write(2, \n\nInit is the parent of all proc..., 37 Init is the parent of all processes) = 37 write(2, \n\n, 2 ) = 2 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0 rt_sigaction(SIGCHLD, NULL, {SIG_DFL}, 8) = 0 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 nanosleep({2592000, 0}, ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
Re: Having problems with init
Hello again, I found the answer to my own problem. It turns out that 'init' was not reading inittab or running rcS because my PID != 1. So in other words, init needs to be run as the special init process ID 1. I actually already knew that, but never suspected that my PID would not be 1 since I was doing my pivot_root from my initrd / linuxrc script. It turns out that two options *must* be explicitly added to the linux command line for your PID to be 1. You should add root=/dev/ram0 and init=/linuxrc if you want your PID to be 1 and busybox init to work. It would sure be nice if busybox init produced some sort of error message if PID != 1. It could save a lot of grief. Finding this information is challenging to say the least!! Dallas On Tue, Nov 2, 2010 at 11:44 AM, Dallas Clement dallas.a.clem...@gmail.com wrote: Hi All, I'm struggling to get init to find /etc/init.d/inittab and or execute /etc/init.d/rcS. It just sits and waits on nanosleep. I have included the strace output below. I'm using version 1.7.0 ( I know it's a bit old, but I'm not able to upgrade it for this project ). I don't think I'm doing anything too out of the ordinary. I am able to successfully NFS mount my root file system. I execute the following from my initrd / linuxrc: /sbin/ifconfig eth1 192.168.1.40 up mount -o nolock 192.168.1.5:/home/dallasc/development/cs/BTUS/hddroot/img /mnt cd /mnt mkdir -p initrd ls . /sbin/pivot_root . initrd if [ $? != 0 ]; then echo pivot root failed else exec chroot . /usr/local/bin/strace /sbin/init \ dev/console dev/console 21 umount /initrd If I replace /sbin/init with /bin/sh, I get a shell prompt and I can look at my NFS mounted root fs. So I know that the exec is working and I can execute binaries over NFS. init however just sits and waits forever on nanosleep. I don't see it attempt to open the inittab file or the rcS file. Could it perhaps be a UID or PID problem? Any help, much appreciated. Thanks, Dallas execve(/sbin/init, [/sbin/init], [/* 8 vars */]) = 0 brk(0) = 0xde000 uname({sys=Linux, node=(none), ...}) = 0 mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x4001d000 access(/etc/ld.so.preload, R_OK) = -1 ENOENT (No such file or directory) open(/etc/ld.so.cache, O_RDONLY) = 3 fstat64(3, {st_mode=S_IFREG|0644, st_size=7909, ...}) = 0 mmap2(NULL, 7909, PROT_READ, MAP_PRIVATE, 3, 0) = 0x4001e000 close(3) = 0 open(/lib/libm.so.6, O_RDONLY) = 3 read(3, \177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0(\0\1\0\0\0\0342\0\000..., 512) = 512 fstat64(3, {st_mode=S_IFREG|0755, st_size=739248, ...}) = 0 mmap2(NULL, 712856, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x40026000 mprotect(0x400cc000, 28672, PROT_NONE) = 0 mmap2(0x400d3000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xa5) = 0x400d3000 close(3) = 0 open(/lib/libc.so.6, O_RDONLY) = 3 read(3, \177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0(\0\1\0\0\0\340J\1\000..., 512) = 512 fstat64(3, {st_mode=S_IFREG|0755, st_size=1481034, ...}) = 0 mmap2(NULL, 1237404, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x400d5000 mprotect(0x401f7000, 28672, PROT_NONE) = 0 mmap2(0x401fe000, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x121) = 0x401fe000 mmap2(0x40201000, 8604, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x40201000 close(3) = 0 mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x4002 syscall_983045(0x400204a0, 0x400256f4, 0x40020b78, 0x40025058, 0x40, 0x40025000, 0, 0xf0005, 0x40025738, 0x1, 0, 0xbe87cbbc, 0, 0xbe87c930, 0x88, 0x40002290, 0x2010, 0x400204a0, 0, 0, 0xdbe0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0) = 0 mprotect(0x401fe000, 8192, PROT_READ) = 0 mprotect(0x400d3000, 4096, PROT_READ) = 0 munmap(0x4001e000, 7909) = 0 getpid() = 629 getuid32() = 0 brk(0) = 0xde000 brk(0x109000) = 0x109000 mmap2(NULL, 401408, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40204000 munmap(0x40204000, 401408) = 0 write(2, BusyBox v1.15.3 (2010-04-23 20:1..., 41BusyBox v1.15.3 (2010-04-23 20:10:06 JST)) = 41 write(2, multi-call binary\n, 19 multi-call binary ) = 19 write(2, \nUsage: , 8 Usage: ) = 8 write(2, init, 4init) = 4 write(2, , 1 ) = 1 write(2, \n\nInit is the parent of all proc..., 37 Init is the parent of all processes) = 37 write(2, \n\n, 2 ) = 2 rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0 rt_sigaction
Re: Having problems with init
Thanks Dennis. I figured things out. Please see my reply. Looks like we crossed paths... ;) I was definitely running from linuxrc, but my PID was not 1 until I added the extra linux command params. On Tue, Nov 2, 2010 at 1:17 PM, Denys Vlasenko vda.li...@googlemail.com wrote: On Tuesday 02 November 2010 17:44, Dallas Clement wrote: I'm struggling to get init to find /etc/init.d/inittab and or execute /etc/init.d/rcS. It just sits and waits on nanosleep. I have included the strace output below. I'm using version 1.7.0 ( I know it's a bit old, but I'm not able to upgrade it for this project ). I don't think I'm doing anything too out of the ordinary. I am able to successfully NFS mount my root file system. I execute the following from my initrd / linuxrc: /sbin/ifconfig eth1 192.168.1.40 up mount -o nolock 192.168.1.5:/home/dallasc/development/cs/BTUS/hddroot/img /mnt cd /mnt mkdir -p initrd ls . /sbin/pivot_root . initrd if [ $? != 0 ]; then echo pivot root failed else exec chroot . /usr/local/bin/strace /sbin/init \ dev/console dev/console 21 umount /initrd If I replace /sbin/init with /bin/sh, I get a shell prompt and I can look at my NFS mounted root fs. So I know that the exec is working and I can execute binaries over NFS. init however just sits and waits forever on nanosleep. I don't see it attempt to open the inittab file or the rcS file. Could it perhaps be a UID or PID problem? Yes: if (!DEBUG_INIT) { /* Expect to be invoked as init with PID=1 or be invoked as linuxrc */ if (getpid() != 1 (!ENABLE_FEATURE_INITRD || !strstr(applet_name, linuxrc)) ) { bb_show_usage(); } #ifdef RB_DISABLE_CAD /* Turn off rebooting via CTL-ALT-DEL - we get a * SIGINT on CAD so we can shut things down gracefully... */ reboot(RB_DISABLE_CAD); /* misnomer */ #endif } See? It checks PID == 1. And under strace, PID will not be 1. (Unless you run strace -D, which requires very recent strace). Why you don't see bb_show_usage() output I don't know - perhaps you compiled without CONFIG_SHOW_USAGE? That init sleeps after this instead of exiting is a known bug, it will be fixed in 1.18.x What happens if you don't run init under strace, or if you run it under strace -D? -- vda ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
Re: Having problems with init
I prefer ...but you didn't run me as PID 1 process. Bad boy. ;^) But, init: must be run as PID 1 will be just fine. Thanks, Dallas On Tue, Nov 2, 2010 at 2:10 PM, Denys Vlasenko vda.li...@googlemail.com wrote: On Tuesday 02 November 2010 19:17, Dallas Clement wrote: Hello again, I found the answer to my own problem. It turns out that 'init' was not reading inittab or running rcS because my PID != 1. So in other words, init needs to be run as the special init process ID 1. I actually already knew that, but never suspected that my PID would not be 1 since I was doing my pivot_root from my initrd / linuxrc script. It turns out that two options *must* be explicitly added to the linux command line for your PID to be 1. You should add root=/dev/ram0 and init=/linuxrc if you want your PID to be 1 and busybox init to work. It would sure be nice if busybox init produced some sort of error message if PID != 1. But it does produce a message: write(2, BusyBox v1.15.3 (2010-04-23 20:1..., 41BusyBox v1.15.3 (2010-04-23 20:10:06 JST)) = 41 write(2, multi-call binary\n, 19 multi-call binary ) = 19 write(2, \nUsage: , 8 Usage: ) = 8 write(2, init, 4init) = 4 write(2, , 1 ) = 1 write(2, \n\nInit is the parent of all proc..., 37 Init is the parent of all processes) = 37 write(2, \n\n, 2 Just isn't the clearest one, right? The message doesn't say ...but you didn't run me as PID 1 process. Bad boy How about this fixed behavior? Is it enough? - # ./busybox init init: must be run as PID 1 -- vda ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
insmod: invalid module format with 2.6.27 kernel
Hello All, I have been using busybox version 1.13.3 just fine with the linux kernel version 2.6.21.1. I recently upgraded my kernel to 2.6.27 and am now getting an error when I try to insert a kernel module. For example: ext2: no symbol version for struct_module insmod: cannot insert '/lib/modules/2.6.27/ext2.ko': invalid module format Does anyone have ideas for me on what might be the problem? I am assuming that this is a problem with insmod. Thanks, Dallas ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
Re: insmod: invalid module format with 2.6.27 kernel
I have just been inserting / loading them manually from my initramfs, just prior to doing a switchroot. #!/bin/ash # NOTE: The modules must be inserted in exactly this order # due to module dependencies. MOD_DIR=/lib/modules/2.6.27 insmod ${MOD_DIR}/scsi_mod.ko insmod ${MOD_DIR}/sd_mod.ko insmod ${MOD_DIR}/libata.ko insmod ${MOD_DIR}/ahci.ko insmod ${MOD_DIR}/ide-core.ko insmod ${MOD_DIR}/ehci-hcd.ko insmod ${MOD_DIR}/uhci-hcd.ko insmod ${MOD_DIR}/usb-storage.ko insmod ${MOD_DIR}/via82cxxx.ko #insmod ${MOD_DIR}/ide-generic.ko insmod ${MOD_DIR}/ide-disk.ko insmod ${MOD_DIR}/mbcache.ko insmod ${MOD_DIR}/jbd.ko insmod ${MOD_DIR}/ext2.ko insmod ${MOD_DIR}/ext3.ko insmod ${MOD_DIR}/edd.ko sleep 5 # Give device drivers enough time to load On Sun, Apr 12, 2009 at 3:20 PM, Gilles Espinasse g@free.fr wrote: - Original Message - From: Dallas Clement To: busybox@busybox.net Sent: Sunday, April 12, 2009 10:04 PM Subject: insmod: invalid module format with 2.6.27 kernel Hello All, I have been using busybox version 1.13.3 just fine with the linux kernel version 2.6.21.1. I recently upgraded my kernel to 2.6.27 and am now getting an error when I try to insert a kernel module. For example: ext2: no symbol version for struct_module insmod: cannot insert '/lib/modules/2.6.27/ext2.ko': invalid module format Does anyone have ideas for me on what might be the problem? I am assuming that this is a problem with insmod. I had this sort of message when using a copy of modules.dep produced by module-init-tools used on boot by busybox modprobe. Not exactly this message, and I only the error with manual modprobe -r Despite the error message, module was really unloaded Has busybox depmod produced modules.dep using with insmod? Gilles ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
Re: Trouble with insmod
I'm definitely using insmod and not modprobe to load these modules from initramfs. This is the snippet of ash script which does the loading: MOD_DIR=/lib/modules/2.6.21.1 insmod ${MOD_DIR}/scsi_mod.ko insmod ${MOD_DIR}/sd_mod.ko insmod ${MOD_DIR}/libata.ko insmod ${MOD_DIR}/ahci.ko insmod ${MOD_DIR}/ide-core.ko insmod ${MOD_DIR}/ehci-hcd.ko insmod ${MOD_DIR}/uhci-hcd.ko insmod ${MOD_DIR}/usb-storage.ko insmod ${MOD_DIR}/via82cxxx.ko insmod ${MOD_DIR}/ide-generic.ko insmod ${MOD_DIR}/ide-disk.ko insmod ${MOD_DIR}/mbcache.ko insmod ${MOD_DIR}/jbd.ko insmod ${MOD_DIR}/ext2.ko insmod ${MOD_DIR}/ext3.ko insmod ${MOD_DIR}/edd.ko The exact error message I am getting on the target when it tries to load the first module is: insmod: module '/lib/modules/2.6.21.1/scsi_mod.ko' not found It's going to take me some time to incorporate the strace utility into my app so that we can see what's happening at the system level. I'll report that a bit later. For now, please find my busybox config attached. Thanks for the help! ~Dallas On Thu, Mar 12, 2009 at 6:49 AM, Denys Vlasenko vda.li...@googlemail.comwrote: On Thursday 12 March 2009 06:06:55 am Dallas Clement wrote: I have been using busybox 1.12.1 for some time now and have been successfully using the 'insmod' command to load certain kernel modules. Everything was working great until I upgraded my cross-compiler toolchain from gcc 4.1.1 and glibc 2.3.6 to gcc 4.2.4 and glibc 2.8. Everything else, including kernel version remained unchanged. My application builds just fine with the new toolchain, however when I run the application on the target, insmod is failing with the following error message: insmod: module module name not found insmod.c does not have such message. Are you sure you are using insmod and not modprobe? Now I have checked and re-checked that the kernel modules I am trying to load exist in this file system. They are definitely there. Yet insmod is no longer able to find them or this error message is misleading and simply masking another problem. Run strace -o LOGFILE your command here and post LOGFILE. Also post your busybox .config -- vda config-busybox-1.12.1 Description: Binary data ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
Re: Trouble with insmod
Yes sir, upgrading to 1.13.3 did the trick. Everything is working nice. Thanks a million for the speedy help! On Thu, Mar 12, 2009 at 10:55 AM, Denys Vlasenko vda.li...@googlemail.comwrote: On Thursday 12 March 2009 02:57:42 pm Dallas Clement wrote: I'm definitely using insmod and not modprobe to load these modules from initramfs. This is the snippet of ash script which does the loading: MOD_DIR=/lib/modules/2.6.21.1 insmod ${MOD_DIR}/scsi_mod.ko insmod ${MOD_DIR}/sd_mod.ko insmod ${MOD_DIR}/libata.ko insmod ${MOD_DIR}/ahci.ko insmod ${MOD_DIR}/ide-core.ko insmod ${MOD_DIR}/ehci-hcd.ko insmod ${MOD_DIR}/uhci-hcd.ko insmod ${MOD_DIR}/usb-storage.ko insmod ${MOD_DIR}/via82cxxx.ko insmod ${MOD_DIR}/ide-generic.ko insmod ${MOD_DIR}/ide-disk.ko insmod ${MOD_DIR}/mbcache.ko insmod ${MOD_DIR}/jbd.ko insmod ${MOD_DIR}/ext2.ko insmod ${MOD_DIR}/ext3.ko insmod ${MOD_DIR}/edd.ko The exact error message I am getting on the target when it tries to load the first module is: insmod: module '/lib/modules/2.6.21.1/scsi_mod.ko' not found Aha! the real message is with '' ! It's going to take me some time to incorporate the strace utility into my app so that we can see what's happening at the system level. I'll report that a bit later. For now, please find my busybox config attached. Bingo. CONFIG_MODPROBE_SMALL=y Either switch it off and use bigger modutils, or switch to 1.13.x, it is fixed there. -- vda ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
Trouble with insmod
Hello, I have been using busybox 1.12.1 for some time now and have been successfully using the 'insmod' command to load certain kernel modules. Everything was working great until I upgraded my cross-compiler toolchain from gcc 4.1.1 and glibc 2.3.6 to gcc 4.2.4 and glibc 2.8. Everything else, including kernel version remained unchanged. My application builds just fine with the new toolchain, however when I run the application on the target, insmod is failing with the following error message: insmod: module module name not found Now I have checked and re-checked that the kernel modules I am trying to load exist in this file system. They are definitely there. Yet insmod is no longer able to find them or this error message is misleading and simply masking another problem. Does anyone have some ideas of what could be going wrong? Thanks, Dallas ___ busybox mailing list busybox@busybox.net http://lists.busybox.net/mailman/listinfo/busybox
How do I add a user to multiple groups?
Hello All, I'd like to use the busybox 'adduser' command to add a user to multiple groups. Can anyone show me how to do this? This is an example of what I would like the group file to look like afterward: [EMAIL PROTECTED]:~/fs-images/common/etc$ cat group root::0:root bin:x:1:root,bin,daemon daemon:x:2:root,bin,daemon sys:x:3:root,bin tty:*:4:root,tty sshd:x:33:sshd As you can see, the 'root' user is a member of multiple groups. It would be nice if I could do something like this, but it does not work: adduser -h /root -g root user -s /bin/ash -G 0 -G 1 -G 2 -G 3 -G 4 root Thanks, Dallas ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
reboot/poweroff/halt commands not working
I'm using 1.6.1 and none of these commands seem to work all by themselves. If I provide the -f option, they all work just fine. I'm not sure if this is a regression problem or it has always been this way. I thought things were working properly in previous versions. I'm pretty sure I did not have to supply the -f option. ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Re: Help using 'dpkg' command to install debian packages
On Fri, 2007-07-13 at 08:23 +1000, Hamish Moffatt wrote: On Thu, Jul 12, 2007 at 08:49:26AM -0500, Dallas Clement wrote: Here is my scenario: I built a binary libc6-i386.deb package on my Debian host and installed it on another host which has nothing but a bare Linux 2.6.21.1 kernel and a static busybox 1.6.0 installed. I used the busybox 'dpkg' command to install the package. Everything went fine and the output of the 'dpkg -l' command is: [...] When I try to install this package, it fails during the installation. This is the error I get: dpkg: package busybox depends on libc6-i386, which is not installed or flagged to be installed I cannot understand why I am getting this error, when clearly the libc6-i386 package is installed as you can see from the previous 'dpkg -l' output. [...] Clearly, the libc6-i386 package is installed. Is there anything else that 'dpkg' checks other than this 'status' file to do the dependency check? Is it just a simple package name check, or is there more involved? Any insight you could provide will be greatly appreciated! I'm at my wit's end trying to get this to work. It looks like you are doing the right thing to me, ie if you were using the real dpkg I believe it would work. Perhaps busybox's emulation is buggy. Hamish I have confirmed that the busybox 'dpkg' command is indeed buggy. It is not checking dependencies correctly. I wasn't able to pinpoint the exact location in the source code for the problem I reported earlier. The code is not exactly easy reading. I download the real dpkg source, built it and am using it instead. It works perfectly. ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Help using 'dpkg' command to install debian packages
Hello All, I need some help understanding how the busybox 'dpkg -i' command works. Specifically, I would like to know how the mechanism for checking debian package dependencies works. I'd like to know what essential files are needed to do the checking. I've built a few packages and tried to install them. Those with dependencies are failing to install for some reason. Here is my scenario: I built a binary libc6-i386.deb package on my Debian host and installed it on another host which has nothing but a bare Linux 2.6.21.1 kernel and a static busybox 1.6.0 installed. I used the busybox 'dpkg' command to install the package. Everything went fine and the output of the 'dpkg -l' command is: Name Version +++-=-== ii libc6-i386 2.3.6 After this, I built a busybox package to re-install the full busybox implementation on to my target host. This package is dependent on libc6-i386 as can be seen from the 'dpkg --info' command: [EMAIL PROTECTED]:~/packages$ dpkg --info busybox_1.6.0-1_i386.deb new debian package, version 2.0. size 233752 bytes: control archive= 619 bytes. 444 bytes, 12 lines control 258 bytes, 4 lines md5sums Package: busybox Version: 1.6.0-1 Section: unknown Priority: extra Architecture: i386 Depends: libc6-i386 (= 2.3.5-1) Installed-Size: 436 Maintainer: Dallas Clement [EMAIL PROTECTED] Description: Busybox UNIX command utilities. BusyBox combines tiny versions of many common UNIX utilities into \ a single small executable. It provides replacements for most of the \ utilities you usually find in GNU fileutils, shellutils, etc. When I try to install this package, it fails during the installation. This is the error I get: dpkg: package busybox depends on libc6-i386, which is not installed or flagged to be installed I cannot understand why I am getting this error, when clearly the libc6-i386 package is installed as you can see from the previous 'dpkg -l' output. In fact, the contents of the /var/lib/dpkg/status file are as follows: cat /var/lib/dpkg/status Package: libc6-i386 Version: 2.3.6 Section: libs Priority: required Architecture: i386 Maintainer: Dallas Clement [EMAIL PROTECTED] Description: The GNU C library The GNU C library is the standard C/C++ library \ needed to support most Linux applications. Status: install ok installed Clearly, the libc6-i386 package is installed. Is there anything else that 'dpkg' checks other than this 'status' file to do the dependency check? Is it just a simple package name check, or is there more involved? Any insight you could provide will be greatly appreciated! I'm at my wit's end trying to get this to work. ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Re: Help using 'dpkg' command to install debian packages
On Fri, 2007-07-13 at 08:23 +1000, Hamish Moffatt wrote: On Thu, Jul 12, 2007 at 08:49:26AM -0500, Dallas Clement wrote: Here is my scenario: I built a binary libc6-i386.deb package on my Debian host and installed it on another host which has nothing but a bare Linux 2.6.21.1 kernel and a static busybox 1.6.0 installed. I used the busybox 'dpkg' command to install the package. Everything went fine and the output of the 'dpkg -l' command is: [...] When I try to install this package, it fails during the installation. This is the error I get: dpkg: package busybox depends on libc6-i386, which is not installed or flagged to be installed I cannot understand why I am getting this error, when clearly the libc6-i386 package is installed as you can see from the previous 'dpkg -l' output. [...] Clearly, the libc6-i386 package is installed. Is there anything else that 'dpkg' checks other than this 'status' file to do the dependency check? Is it just a simple package name check, or is there more involved? Any insight you could provide will be greatly appreciated! I'm at my wit's end trying to get this to work. It looks like you are doing the right thing to me, ie if you were using the real dpkg I believe it would work. Perhaps busybox's emulation is buggy. Hamish I think you're right - must be buggy. Though, what I am doing seems so simple!! I'm looking at the file dpkg.c now and putting in some debug messages to see why it is behaving this way. Cheers, Dallas ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Difficulty with dpkg dependencies
Hello All, I'm having some trouble installing a busybox debian package which I built on my Debian system. I previously built and installed a glibc binary debian package successfully. The busybox package installation is failing complaining that the libc6-i386 package which it depends on is not installed. It gives the following error: dpkg: package busybox depends on libc6-i386, which is not installed or flagged to be installed However, I know that libc6-i386 is installed. If I examine the contents of the dpkg 'status' file as follows I get the following: cat /var/lib/dpkg/status Package: libc6-i386 Version: 2.3.6 Section: libs Priority: optional Architecture: i386 Maintainer: Dallas Clement [EMAIL PROTECTED] Description: The GNU C library The GNU C library is the standard C/C++ library \ needed to support most Linux applications. Status: install ok installed -- The following is the info for the glibc package which I built: [EMAIL PROTECTED]:~/packages/glibc$ dpkg --info libc6-i386.deb new debian package, version 2.0. size 7129020 bytes: control archive= 328 bytes. 280 bytes,11 lines control Package: libc6-i386 Version: 2.3.6 Section: libs Priority: optional Architecture: i386 Depends: Maintainer: Dallas Clement [EMAIL PROTECTED] Description: The GNU C library The GNU C library is the standard C/C++ library \ needed to support most Linux applications. The following is the info for the busybox package which I built: [EMAIL PROTECTED]:~/packages$ dpkg --info busybox_1.6.0-1_i386.deb new debian package, version 2.0. size 233752 bytes: control archive= 619 bytes. 444 bytes,12 lines control 258 bytes, 4 lines md5sums Package: busybox Version: 1.6.0-1 Section: unknown Priority: extra Architecture: i386 Depends: libc6-i386 (= 2.3.5-1) Installed-Size: 436 Maintainer: Dallas Clement [EMAIL PROTECTED] Description: Busybox UNIX command utilities. BusyBox combines tiny versions of many common UNIX utilities into \ a single small executable. It provides replacements for most of the \ utilities you usually find in GNU fileutils, shellutils, etc. -- I could very likely be doing something wrong, but just not sure what it is. I don't see a reason for the dependency to fail. I'd sure appreciate any help. Regards, Dallas Clement ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
dpkg-deb vs. dpkg
Hi All, Can somebody tell me what the difference is between these two commands? I'm assuming both should work with a .deb package... Thanks, Dallas Clement ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Problem with ash -n non-zero length string test
Hello All, I'm experiencing some weird things when trying to use -n to test for a non-empty string as in the following example. boot_drive_name= if [ -n $boot_drive_name ]; then retval=0 else echo Could not determine boot drive name. fi To my surprise, this condition evaluates true and I do not see my echo message. However, if I use the -z test, with the following logic, I do see my echo message. boot_drive_name= if [ -z $boot_drive_name ]; then echo Could not determine boot drive name. else retval=0 fi I'm not sure if -n does not work 100 percent of the time in all cases or if it is an erratic problem that only happens under certain conditions. I have seen it fail in several different logic scenarios. Has anyone else observed this? Am I doing something wrong? I'm seeing this on busybox 1.6.0 ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Re: Problem with ash -n non-zero length string test
On Sat, 2007-07-07 at 23:44 +0200, Yann E. MORIN wrote: Hello Dallas, Hello all, On Saturday 07 July 2007 23:34, Dallas Clement wrote: if [ -n $boot_drive_name ]; then retval=0 else echo Could not determine boot drive name. fi I'd suggest either one of: - enclose the variable between double quotes: $boot_drive_name - use this: [ x$boot_drive_name = x ] I would also enclose the variable b=name between curly brackets: ${boot_drive_name} I would personnally use: if [ -z ${boot_drive_name} ]; then do_error_out exit 1 fi do_something_usefull Regards, Yann E. MORIN. Thank you Yann Mike: The -n check works when the variable is enclosed in double quotes! :0 Regards, Dallas ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Re: Does control-C from console interrupt ash script execution?
On Fri, 2007-06-29 at 18:18 +0200, Denis Vlasenko wrote: On Wednesday 27 June 2007 17:35, Dallas Clement wrote: Hello All, I am executing an ash init script from initramfs. I have only the console for I/O at this time -- no TTYs available. My init script prompts for input like so: printf is that correct? (y|n) - read confirm Should I be able to interrupt ash script execution with a control-C? I am trying to trap it in my script as follows: trap abort 2 No, it won't work. Ctrl-C, Ctrl-Z etc have special meaning only when they come from controlling tty. /dev/console cannot be a controlling tty in Linux. (there is code in kernel which disallows this). See cttyhack (and its help text) in newer busybox. -- vda Thanks for the reply. Can I hi-jack my PC VGA port with getty then to get a controlling terminal? I'd like to avoid forcing a login. I'm trying to do this from an init script. ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Re: Ash Documentation?
On Sat, 2007-06-30 at 04:44 +0200, Alexander Kriegisch wrote: One more late answer: I just installed the virtual ash (- dash) package on my Elive Debian system, and now man ash info ash show something different from man sh or man bash. Comparing the variable substitution sections, this really seems to be an ash man-page or as close as it gets. I think this should be good for a quick look. Regards -- Alexander Kriegisch Thanks for the tip. This should be a bit more reader friendly than opengroup docs. ;) ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Ash Documentation?
Can anyone please suggest a reference to some good Ash scripting documentation? I am trying to implement scripting like I'm using Bourne shell and things are not behaving too well... In particular, I'm wondering how to correctly define shell script functions and call the functions. I presume this is supported with the busybox ash implementation. Any help appreciated. --Dallas Clement ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Re: Ash Documentation?
On Wed, 2007-06-27 at 11:08 -0400, Paul Smith wrote: On Wed, 2007-06-27 at 05:02 -0500, Dallas Clement wrote: Can anyone please suggest a reference to some good Ash scripting documentation? I am trying to implement scripting like I'm using Bourne shell and things are not behaving too well... Most likely you're actually using bash syntax, not Bourne shell syntax. Bash has a number of enhancements that are not supported by Bourne shell (or the POSIX sh standard). However, because many GNU/Linux distributions come with bash as /bin/sh, people who are learning shell scripting on GNU/Linux often make the mistake of thinking bash features are Bourne shell features. In particular, I'm wondering how to correctly define shell script functions and call the functions. I presume this is supported with the busybox ash implementation. Yes, functions are supported. Since you don't give an example of what you're doing, we'll just have to guess: I guess you're doing this: function myfunc () { ... } This is not valid Bourne/POSIX sh syntax. The function keyword is a bash-ism, and is not needed in Bourne/POSIX sh. Just write: myfunc () { ... } If this isn't the problem, please provide a sample of the code you're using and show us what errors you get when you try it. Cheers! Apologies for the rather length example of what I'm doing below. I'm basically invoking this ash script from within initramfs. It's an install script. What I've noticed is that the echo statements within my functions are not being seen on the console. So I can't tell whether they are being entered or not. Neither can I see any output from other commands such as fdisk. Hence, not sure if I'm using correct syntax or doing something else wrong. Thanks for the help! determine_boot_drive_name() { echo Entering determine_boot_drive_name local dev80_dir=/sys/firmware/edd/int13_dev80 local heads_file=/sys/firmware/edd/int13_dev80/default_heads local spt_file=/sys/firmware/edd/int13_dev80/default_sectors_per_track local cylinders_file=/sys/firmware/edd/int13_dev80/default_cylinders if [ -d $dev80_dir ]; then if [ -f $heads_file ]; then if [ -f $spt_file ]; then if [ -f $cylinders_file ]; then num_bios_drive_heads=$(cat $heads_file) num_bios_drive_sectors_per_track=$(cat $spt_file) num_bios_drive_cylinders=$(cat $cylinders_file) export num_bios_drive_heads export num_bios_drive_sectors_per_track export num_bios_drive_cylinders local num_disk_lines=$(fdisk -l | grep Disk | wc -l) local num_heads_lines=$(fdisk -l | grep heads | wc -l) if [ $num_disk_lines -eq $num_heads_lines ]; then if [ $num_disk_lines -gt 0 ]; then line_num=$(fdisk -l | awk '/heads/ \ {if ($1 == ENVIRON[num_bios_drive_heads] \ $3 == ENVIRON[num_bios_drive_sectors_per_track] \ $5 == ENVIRON[num_bios_drive_cylinders]) {print NR; exit;}}') export line_num boot_drive_name=$(cat $drive_names_tmp_file | \ awk '{if (NR == ENVIRON[line_num]) {print substr($2,0,8); exit}}') return 0 else echo Unable to detect boot drive using fdisk fi else echo Unable to detect boot drive using fdisk; names and params don't match. fi else echo Couldn't find boot drive BIOS EDD cylinders file. fi else echo Couldn't find boot drive BIOS EDD sectors file. fi else echo Couldn't find boot drive BIOS EDD heads file. fi else echo Couldn't find boot drive BIOS EDD directory. fi return 1 } create_device_files() { echo Entering create_device_files local device_tmp_file=/var/tmp/device_tmp_file local partitions_file=/proc/partitions if [ -f $partitions_file ]; then cat $partitions_file | awk '$1 ~ /[0-9]/ {print mknod -m 660 /dev/ \ $4, b, $1, $2}' $device_tmp_file cat $device_tmp_file . $device_tmp_file rm -f $device_tmp_file else echo Partitions file not found fi return 0 } foobar() { echo Entering foobar echo $boot_drive_name if [ -n $boot_drive_name ]; then # fdisk -l | grep Disk | grep -v $boot_drive_name | \ # awk '/Disk/ {print NR ., $0}' $drive_names_tmp_file # cat $drive_names_tmp_file fdisk -l return 0 else echo Boot drive name is unknown fi return 1 } main() { echo Entering main mount -t sysfs none /sys mount -t proc none /proc ./load
Re: Ash Documentation?
On Wed, 2007-06-27 at 11:29 -0400, Paul Smith wrote: On Wed, 2007-06-27 at 17:08 +0200, Alexander Kriegisch wrote: I do not have a dedicated ash reference either, but as I am working on a firmware mod for a WLAN/DSL router series called Fritz!Box by AVM and always use ash, I can encourage you to refer to man sh on any Linux desktop. This is not a 100% thing, but fairly good from my experience. I noticed differences concerning variable substitution stuff like substrings - e.g. ${myvar:index} and ${myvar:index:length} yield errors - but I get along well enough. The man page for sh on a GNU/Linux system is for bash. As I mentioned there are a LOT of features of bash that aren't supported by POSIX sh (and hence ash). The best thing to do is register with The Open Group, then you can read their documentation online. I personally always write all my programs and scripts to the POSIX specification, for maximum portability. If there's some advanced feature I need that isn't provided by POSIX, only then will I carefully venture into Linux-specific areas. http://www.opengroup.org/ http://www.opengroup.org/bookstore/catalog/t041.htm https://www.opengroup.org/online-pubs-short?DOC=759899FORM=HTML Good luck! Thanks everyone for the help! Things are working great now, and I surely appreciate the tips and references. Have a happy day. ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Does control-C from console interrupt ash script execution?
Hello All, I am executing an ash init script from initramfs. I have only the console for I/O at this time -- no TTYs available. My init script prompts for input like so: printf is that correct? (y|n) - read confirm Should I be able to interrupt ash script execution with a control-C? I am trying to trap it in my script as follows: trap abort 2 In case you are wondering, 'abort' is a shell script function. Thanks, Dallas ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Re: how can I determine the root device?
Hi Mike, Thanks for the reply. I guess what I am really trying to determine is which device I booted Linux from. Do you know of any way to do that? I am booting into initramfs and I would like to determine the boot device major/minor numbers while running my init script. On 6/20/07, Mike Frysinger [EMAIL PROTECTED] wrote: On Wednesday 20 June 2007, Dallas Clement wrote: Does anyone know of a way to determine the root device from which the kernel has been booted? I've heard of a utility called rdev which will do this. Just wondering if something like this is included in busybox or if there is a way to determine this from files found in the proc filesystem or something... rdev works by comparing the major/minor from stat(/) to the major/minor of the device nodes in /dev/ depending on what you want to do, /dev/root may also work -mike ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
how can I determine the root device?
Does anyone know of a way to determine the root device from which the kernel has been booted? I've heard of a utility called rdev which will do this. Just wondering if something like this is included in busybox or if there is a way to determine this from files found in the proc filesystem or something... ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Re: mke2fs command
I see now that it is part of the e2fsprogs. Sorry for the spam... On Tue, 2007-06-19 at 18:26 -0500, Dallas Clement wrote: I'd like to use this command, however I seem to be having difficulty finding it in the busybox configuration editor. Does this command still exist? If so, could someone please tell me how to enable it? Thanks, Dallas Clement ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Help installing libc and busybox as debian packages...
Hello All, I'm wanting to install libc and busybox as Debian packages onto my embedded target system as sort of a bootstrap installation process. My target system thankfully has a IDE DOM drive which can be removed and attached to my separate development system and mounted there as a non-root filesystem for installation purposes. Could anyone please guide me on how to install these packages onto my DOM drive filesystem? I am assuming that I can use the 'dpkg -i' command on my development system to do this, but not sure how to install it on my DOM drive only and not have it listed with all the other packages on my development system. Maybe there is a better way? Thanks in advance, Dallas Clement ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
Re: fsck.ext2: No such file or directory
Thanks for the clarification. I downloaded e2fsprogs and it works fine. Regards, Dallas On Sun, 2007-06-03 at 19:14 +0200, Denis Vlasenko wrote: On Saturday 02 June 2007 17:12, Dallas Clement wrote: I'm trying to do a check on a flash DOM drive that has been formatted with EXT2 and getting the error: fsck (busybox 1.5.0, 2007-05-16 15:12:30 CDT) fsck: fsck.ext2: No such file or directory Can anyone please tell me what I might be doing wrong? I believe I have included the fsck applet in my busybox build. fsck applet is only a driver. Real checking is done by executing fsck.fs_type binary. Currently, busybox does not build fsck.ext2 (although code is still around in e2fsprogs/old_e2fsprogs/e2fsck.c). -- vda ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
fsck.ext2: No such file or directory
I'm trying to do a check on a flash DOM drive that has been formatted with EXT2 and getting the error: fsck (busybox 1.5.0, 2007-05-16 15:12:30 CDT) fsck: fsck.ext2: No such file or directory Can anyone please tell me what I might be doing wrong? I believe I have included the fsck applet in my busybox build. Thanks, Dallas ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
ash: Can't access tty problems (initramfs)
I'm getting the infamous Can't access tty; job control turned off message when I try to invoke the ash shell during my initial bootup. I'm using busybox 1.5.0. I also understand that ash requires a controlling tty rather than the console. Though, I don't understand all the reasons. If I don't define a console however, I get a kernel panic from initramfs. Could someone please give me some pointers on how tty and console should be configured? I'm connected via my VGA port (not a serial port). Here is the contents of my initramfs makefile: dir /dev 755 0 0 nod /dev/tty0 666 0 5 c 5 0 nod /dev/tty1 666 0 5 c 4 1 nod /dev/tty2 666 0 5 c 4 2 nod /dev/tty3 666 0 5 c 4 3 nod /dev/tty4 666 0 5 c 4 4 nod /dev/tty5 666 0 5 c 4 5 nod /dev/tty6 666 0 5 c 4 6 nod /dev/tty7 666 0 5 c 4 7 nod /dev/tty8 666 0 5 c 4 8 nod /dev/ttyS0 666 0 5 c 5 0 nod /dev/console 644 0 0 c 5 1 nod /dev/null 666 0 0 c 1 3 nod /dev/hda 660 0 6 b 3 0 nod /dev/hda1 660 0 0 b 3 1 nod /dev/hdb 660 0 6 b 3 0 nod /dev/hdb1 660 0 0 b 3 1 nod /dev/hdf 660 0 6 b 3 0 nod /dev/hdf1 660 0 0 b 3 1 dir /bin 755 1000 1000 file /bin/busybox /home/dallas/initramfs/busybox 755 0 0 slink /bin/ash busybox 777 0 0 slink /bin/mkdir busybox 777 0 0 slink /bin/mount busybox 777 0 0 slink /bin/cat busybox 777 0 0 slink /bin/switch_root busybox 777 0 0 dir /root 700 0 0 dir /proc 755 0 0 dir /sys 755 0 0 dir /var 755 0 0 dir /var/lock 755 0 0 dir /tmp 755 0 0 dir /mnt 755 0 0 dir /mnt/realroot 755 0 0 dir /etc 755 0 0 file /etc/fstab /home/dallas/initramfs/fstab 755 0 0 file /init /home/dallas/initramfs/init.ash 755 0 0 ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
RE: Can't access tty problems (initramfs)
Yes, it was a cut-n-paste mistake. The tty0 should have ended in 4 0. I corrected it, but sadly still getting the Can't access tty error message. Thanks for the help. -Original Message- From: Christopher Reder [mailto:[EMAIL PROTECTED] Sent: Thursday, May 17, 2007 11:39 AM To: [EMAIL PROTECTED] Subject: RE: Can't access tty problems (initramfs) I apologize if I just don't understand it, but are your tty0 and ttyS0 the same? Should that first one tty0 end in 4 0 ? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Dallas Clement Sent: Thursday, May 17, 2007 11:28 AM To: busybox@busybox.net Subject: ash: Can't access tty problems (initramfs) I'm getting the infamous Can't access tty; job control turned off message when I try to invoke the ash shell during my initial bootup. I'm using busybox 1.5.0. I also understand that ash requires a controlling tty rather than the console. Though, I don't understand all the reasons. If I don't define a console however, I get a kernel panic from initramfs. Could someone please give me some pointers on how tty and console should be configured? I'm connected via my VGA port (not a serial port). Here is the contents of my initramfs makefile: dir /dev 755 0 0 nod /dev/tty0 666 0 5 c 5 0 nod /dev/tty1 666 0 5 c 4 1 nod /dev/tty2 666 0 5 c 4 2 nod /dev/tty3 666 0 5 c 4 3 nod /dev/tty4 666 0 5 c 4 4 nod /dev/tty5 666 0 5 c 4 5 nod /dev/tty6 666 0 5 c 4 6 nod /dev/tty7 666 0 5 c 4 7 nod /dev/tty8 666 0 5 c 4 8 nod /dev/ttyS0 666 0 5 c 5 0 nod /dev/console 644 0 0 c 5 1 nod /dev/null 666 0 0 c 1 3 nod /dev/hda 660 0 6 b 3 0 nod /dev/hda1 660 0 0 b 3 1 nod /dev/hdb 660 0 6 b 3 0 nod /dev/hdb1 660 0 0 b 3 1 nod /dev/hdf 660 0 6 b 3 0 nod /dev/hdf1 660 0 0 b 3 1 dir /bin 755 1000 1000 file /bin/busybox /home/dallas/initramfs/busybox 755 0 0 slink /bin/ash busybox 777 0 0 slink /bin/mkdir busybox 777 0 0 slink /bin/mount busybox 777 0 0 slink /bin/cat busybox 777 0 0 slink /bin/switch_root busybox 777 0 0 dir /root 700 0 0 dir /proc 755 0 0 dir /sys 755 0 0 dir /var 755 0 0 dir /var/lock 755 0 0 dir /tmp 755 0 0 dir /mnt 755 0 0 dir /mnt/realroot 755 0 0 dir /etc 755 0 0 file /etc/fstab /home/dallas/initramfs/fstab 755 0 0 file /init /home/dallas/initramfs/init.ash 755 0 0 ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox
RE: ash: Can't access tty problems (initramfs)
Thanks for the tip! At least I can make progress with it. I'd still like to know why I'm having trouble with 1.5.0. I saw some explanation in the FAQ, but I'm afraid it needs to be translated into noobese with some specific examples of how to setup the tty / console. Regards, Dallas -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Hamish Moffatt Sent: Thursday, May 17, 2007 5:29 PM To: busybox@busybox.net Subject: Re: ash: Can't access tty problems (initramfs) On Thu, May 17, 2007 at 11:28:06AM -0500, Dallas Clement wrote: I'm getting the infamous Can't access tty; job control turned off message when I try to invoke the ash shell during my initial bootup. I'm using busybox 1.5.0. I also understand that ash requires a controlling tty rather than the console. Though, I don't understand all the reasons. I saw this too when I upgraded from 1.4.2 from 1.5.0, so I switched back. The same /dev entries work perfectly in 1.4.2. I did not have time/need to debug it. Hamish -- Hamish Moffatt VK3SB [EMAIL PROTECTED] [EMAIL PROTECTED] ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox ___ busybox mailing list busybox@busybox.net http://busybox.net/cgi-bin/mailman/listinfo/busybox