Determining boot device in autorun script

All other questions
mkblackwell
Posts: 2
Joined: 30 Aug 2011, 19:24

Determining boot device in autorun script

Postby mkblackwell » 17 Nov 2014, 21:31

If I boot with the docache option is there any way for the autorun script to determine what device I booted off of?

I'd like to re-mount that device, copy some files off of it, then eject it. Right now I have two different script, one for cdrom (/dev/sr0) and one for usb thumb drive (/dev/sdb1), but I'd like to converge on a single script (plus, the usb drive might not always be sdb1).

gernot
Posts: 1127
Joined: 07 Apr 2010, 16:19

Re: Determining boot device in autorun script

Postby gernot » 18 Nov 2014, 05:40

I think the bootdevicename is not stored in "new root"
There are some directory and filenames which are cached at boot.
Boot with the "minishell" option and take a look to init.

Gernot


Return to “Other”

Who is online

Users browsing this forum: No registered users and 6 guests