Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Initramfs boot from USB
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
[n00b@localhost]
Apprentice
Apprentice


Joined: 30 Aug 2004
Posts: 212
Location: London, UK

PostPosted: Sat Apr 13, 2013 1:41 pm    Post subject: Initramfs boot from USB Reply with quote

I have an old laptop that I have installed Gentoo on. This laptop doesn't have BIOS support for booting from USB so I used the Gentoo live DVD. Seeing as I have a habit of doing stupid things to my Gentoo installs I need an easy way to boot from a rescue system I have on my USB key which I almost always have on me - not so with a live DVD.

Booting from DVD is also a bit hit or miss with this laptop as the DVD drive is one of those low-power ones that doesn't always spin up in time for the BIOS to recognise it has a bootable disk in it. I have tried using GRUB to boot from a USB stick but GRUB doesn't recognise it either. I have an initramfs set up as I have a separate /usr filesystem so I was thinking I might be able to use the initramfs to boot from USB.

Does anyone know what I need to include in an initramfs to have support for booting from a USB stick? Can it even be done?

The laptop is a Thinkpad T22 which I know some other people on this forum have in case they have any other suggestions.
Back to top
View user's profile Send private message
eccerr0r
Advocate
Advocate


Joined: 01 Jul 2004
Posts: 4097
Location: USA

PostPosted: Sat Apr 13, 2013 6:40 pm    Post subject: Reply with quote

This might do what you need to do: http://www.plop.at/en/bootmanager/index.html

Not knowing what's on your USB stick, this should boot arbitrary OSes including NetBSD or something. Likely initramfs solutions will only boot Linux.
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed to be advocating?
Back to top
View user's profile Send private message
[n00b@localhost]
Apprentice
Apprentice


Joined: 30 Aug 2004
Posts: 212
Location: London, UK

PostPosted: Sun Apr 14, 2013 12:07 am    Post subject: Reply with quote

The USB key has System Rescue CD on it which boots using syslinux. I may also rarely have a USB key with the Gentoo livecd on it. In any case the USB key will always contain a Linux installation.

Is there a way to boot a Linux USB key from an initramfs?
Back to top
View user's profile Send private message
eccerr0r
Advocate
Advocate


Joined: 01 Jul 2004
Posts: 4097
Location: USA

PostPosted: Sun Apr 14, 2013 2:26 am    Post subject: Reply with quote

If you mean any arbitrary USB bootable system, no. The "key" problem is that the filesystem on the USB may be tied to the kernel on that media - which may not match the one that's already loaded - the only possibility is that you can somehow kexec the kernel on the USB filesystem and set it up to load the right options... I've not really experimented much with kexec so this is unchartered territory for me...
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed to be advocating?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum