From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.6) Gecko/20050322 Epiphany/1.5.8 Description of problem: The ability to run # reboot title where title is a grub title, something like "mykernel1", "xp", etc, would be nice. Version-Release number of selected component (if applicable): How reproducible: Always Steps to Reproduce: x Additional info:
Any way to set a single 'boot this by default once' entry for grub?
wow -- this is really a dangerous suggested option; several motherboards, and poweroff/reboot implementations 'hang' on the way down and require manual intervention to get restarted. I never prefer unattended reboots, as they inevitably seem to happen on Saturday night at 4 am requiring a drive to a COLO facility the following Monday. About as far as I think this should go is it issue an advisory email to root@localhost (on the assumption that root's email is being forwarded offhost to a monitored account; or [on the asumption that one cannot count on a MTA running or being properly configured] perhaps emitting to 'logger' a advisory request for a reboot, to be 'caught' by logwatch on the remote syslog box [wame issue as to a properly set up and monitored syslog].
Huh? This is simply adding an option to the normal reboot syntax, saying it should boot something else by default first. The reboot command itself works the same as it always has.
You can do this with grub, but the method of doing it is different for every boot loader, which would make it kind of sucky to implement for the general case. To use, something like the following works: echo -e "savedefault --default=2 --once\nquit" |/sbin/grub --batch --device-map=/boot/grub/device.map
OK, sounds like functionality that needs to be wrapped in grubby first before reboot could sanely use it.
grub-reboot does this.
This should be able to be done just like pm-utils does it: [ -x /sbin/grubby -a -x /sbin/grub ] || return 1 [ -e /boot/vmlinuz-$(uname -r) ] || return 1 out=$(/sbin/grubby --info /boot/vmlinuz-$(uname -r) |grep index) [ -n "${out}" ] || return 1 current=${out#index=} echo "savedefault --default=${current} --once" | /sbin/grub --batch --no-floppy --device-map=/boot/grub/device.map --no-floppy (except you obviously don't want "current" since it's specified by hand)
That's still grub-specific.
Package name is now sysvinit in latest Fedora.
Closing, this is unlikely to be implemented. Patches accepted, though.