Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Detect Grub target in use. #3

Open
vbence opened this issue Dec 26, 2014 · 2 comments
Open

Detect Grub target in use. #3

vbence opened this issue Dec 26, 2014 · 2 comments

Comments

@vbence
Copy link
Owner

vbence commented Dec 26, 2014

By default Grub will install the bootloader (UEFI, or MBR) which was used to boot the current environment.

This information have to be made available to the restore script, which can then use the --target parameter to force the right installation method.

@vbence
Copy link
Owner Author

vbence commented Jan 11, 2015

Method will be:
http://unix.stackexchange.com/a/178027/23586

Not the sweetest solution though - involves some guesswork.

@vbence
Copy link
Owner Author

vbence commented Feb 24, 2015

The following line should guess the right value pretty accurately:

comm -12 <(find /boot/grub -name moddep.lst | sed -r "s/^.*\/([^\/]+)\/.+$/\1/g") <(find /usr/lib/grub -name moddep.lst | sed -r "s/^.*\/([^\/]+)\/.+$/\1/g") 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant