You are not logged in.
I am attempting to get arch linux booting off my usb. I use cfdisk to create a /dev/sdb1 partition then use mkfs.ext4 /dev/sdb1, mount the usb, pacstrap it, use install-syslinux_update -iam, generate fstab and then attempt to boot from it.
The boot extracts the kernel but then complains that DEVICE is missing in the option APPEND root=DEVICE (in syslinux.cfg). I looked in /dev/disk (on the temporary filesystem shell), it showed my ssd and cd drive but not the usb. Does anyone know what could be causing the USB to not load in that particular section of the kernel?
Last edited by afree10 (2013-12-11 14:28:14)
Offline
Did you edit syslinux.cfg? Did you use labels or UUIDs for the root device in syslinux.cfg?
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
yes, both
Offline
Care to post it?
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
LABEL arch
MENU LABEL Arch Linux
LINUX ../vmlinuz-linux
APPEND root=/dev/sdb1
INITRD ../initramfs-linux.img
also tried root=UUID=blah blah AND other /dev/sd configurations which just caused extra warnings since it was attempting to access my ssd; but since the device is not available in the temporary filesystem it isn't going to matter much what I put here
Last edited by afree10 (2013-12-11 12:49:46)
Offline
Can you post mkinitcpio.conf? Can you also type 'lsmod' in the ramfs shell and provide the output? The file list from initramfs-linux.img (use lsinitcpio to see it) is helpful too.
Last edited by brain0 (2013-12-11 12:50:07)
Offline
Due to my situation I have to type the file in from scratch so I will only type uncommented lines:
MODULES=""
BINARIES=""
FILES=""
HOOKS="base udev autodetect modconf block filesystems keyboard fsck"
I will reboot and get that lsmod output.
Offline
Due to my situation I have to type the file in from scratch so I will only type uncommented lines:
MODULES=""
BINARIES=""
FILES=""
HOOKS="base udev autodetect modconf block filesystems keyboard fsck"I will reboot and get that lsmod output.
Since you'll probably want to boot from different computers (portable USB system), you want to remove 'autodetect' from that line. This is the same as always booting the initramfs-linux-fallback.img image. To save some space, you could remove 'autodetect' from the configuration file, disable the fallback image in /etc/mkinitcpio.d/linux.preset and delete initramfs-linux.img (otherwise, you'll get two identical images).
Of course, run mkinitcpio -P when you're done.
Offline
Module Size Used By
sd_mod 0
sr_mod 0
cdrom 1 sr_mod
ahci 0
libahci 1 ahci
libata 2 ahci, libahci
scsi_mod 3 libata, sd_mod, sr_mod
I will try your advice now.
Offline
I get the error: initramfs bad file number
Offline
Module Size Used By
sd_mod 0
sr_mod 0
cdrom 1 sr_mod
ahci 0
libahci 1 ahci
libata 2 ahci, libahci
scsi_mod 3 libata, sd_mod, sr_modI will try your advice now.
No USB modules loaded. I guess you boot from a different machine than the one you generate the image on? (In any case, ehci should probably be loaded.)
I get the error: initramfs bad file number
Where do you get that error?
Offline
I install arch to the USB on a virtual machine (running arch) and then boot from the real hardware.
About the same time the kernel image is being extracted.
I have never generated a initramfs before btw, but it seems to have been created just fine (no errors or anything other than two warnings that I know are okay from looking elsewhere). I did backup the orginal so I can restore that but I have a feeling I am going to need to build a initramfs with usb support.
Last edited by afree10 (2013-12-11 13:55:27)
Offline
The initramfs already has USB support. However, due to being built in the virtual machine (presumably without USB support), the autodetection strips all USB modules from the image - hence I told you to disable autodetection in the image generation.
The initramfs extraction error at boot must be due to file corruption, probably from not properly umounting the USB drive before "unplugging" it from the VM.
Offline
I removed autodetection from both the vm and the usb os and chrooted the usb and generated the image with the command there.
That is probably the case, I will be more careful to ensure I umount the USB whenever its necessary/shutdown the vitual machine system "the long way", though I am rather surprised corruption could have resulted from that.
Offline
It is booting now, I will mark the thread as solved. Thank you very much.
Last edited by afree10 (2013-12-11 14:27:42)
Offline