2

I have Ubuntu 14.04 Server and Ubuntu 14.04 Desktop installed.

My task is:

  • restart running Ubuntu Desktop (with crontab)
  • boot into Ubuntu Server
  • do backup etc.
  • restart running Ubuntu Server
  • boot into Ubuntu Desktop

I have tried How do I change the GRUB boot order? (edit the file /etc/default/grub) but I can only change the boot order in running Ubuntu Server, not in running Ubuntu Desktop.

But I have to change the boot order every time the system changes. Is there a way?

1

On both systems a script in autostart:

#!/bin/bash
sudo grub-install /dev/sda
sudo update-grub

and in /etc/default/grub

GRUB_DEFAULT=4

So everytime a system starts it reinstalls grub, puts itself on the top of the boot list and the other system on place 4. When a system switches the boot order switches too.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.