Page 1 of 1

[SOLVED] Where is grub located in the file structure?

PostPosted: Nov 28th, '15, 03:39
by trexneb
I want to edit grub IOT set the correct resolution for my parallels instance on my MacBook Pro. Where is grub located in the file structure and, if it is in root, how do I access it as an administrator since my normal login doesn't have those privileges?

Re: Where is grub located in the file structure?

PostPosted: Nov 28th, '15, 06:22
by xboxboy
I suspect the file you want is in /boot/grub/menu.lst

Although I usually edit grub using the MCC tools. Not sure which desktop you use, but in KDE there is an icon on the lower panel of a screwdriver and spanner crossed, over the top of a 'm' type shape. Click that, enter your root password, then select boot from the left.

Try that.

Re: Where is grub located in the file structure?

PostPosted: Nov 29th, '15, 18:31
by fixxer
Edit as root file /etc/default/grub, e.g. by console text editor - nano:
Code: Select all
sudo nano /etc/default/grub


Search for line:
Code: Select all
GRUB_GFXMODE=1024x768x32

Change for you purposes, save changes and update Grub2 configuration file:
Code: Select all
sudo update-grub2

OR
Code: Select all
sudo grub2-mkconfig -o /boot/grub2/grub.cfg

REboot your computer.

Re: Where is grub located in the file structure?

PostPosted: Nov 29th, '15, 19:14
by doktor5000
Either of you two assumes that either grub legacy or grub2 is used ... why not simply ask the OP?

@fixxer: You assume that sudo is configured and that nano is installed, which is not the case in a default installation.
Also for Mageia both latter steps you mention are done by update-grub

Re: Where is grub located in the file structure?

PostPosted: Jan 30th, '16, 04:55
by trexneb
Thanks for the replies, sorry I didn't get back to the thread 'til just now.

@doktor5000: What do you mean, ask the OP? If grub/grub2 is not used, then what is?
@fixxer: I used edit instead of nano and grub doesn't exist at the specified loc'n.
@xboxboy: I'm using Gnome. The screwdriver and spanner don't allow me to set the resolution but I can choose between Gnome Display Mgr (GDM) and XDM. I've remained w/ GDM. I was able to open /boot/grub/menu.lst using edit, but was unable to see where I needed to work. I'm following the instructions from http://slobytes.org/smf/index.php?topic=311.0, which has allowed me to adjust my resolutions for most of my virtual machines. I'm just stumped on how to do it in Mageia.

Re: Where is grub located in the file structure?

PostPosted: Jan 30th, '16, 04:57
by trexneb
gedit (which my computer autocorrected to edit)

Re: Where is grub located in the file structure?

PostPosted: Jan 30th, '16, 09:37
by xboxboy
I'm lost: What is the reason you want to edit grub?

Re: Where is grub located in the file structure?

PostPosted: Jan 30th, '16, 09:44
by doktor5000
trexneb wrote:@doktor5000: What do you mean, ask the OP? If grub/grub2 is not used, then what is?


xboxboy assumed that grub legacy is used, fixxer assumed grub2 is used. One should not assume, but verify what is actually used, IMHO.
And if you wouldn't have mentioned grub explicitly, lilo could also be possible.

trexneb wrote:@xboxboy: I'm using Gnome. The screwdriver and spanner don't allow me to set the resolution but I can choose between Gnome Display Mgr (GDM) and XDM. I've remained w/ GDM. I was able to open /boot/grub/menu.lst using edit, but was unable to see where I needed to work. I'm following the instructions from http://slobytes.org/smf/index.php?topic=311.0, which has allowed me to adjust my resolutions for most of my virtual machines. I'm just stumped on how to do it in Mageia.

FWIW, drakboot -- boot allows to configure the bootloader from MCC, refer to http://doc.mageia.org/mcc/5/en/content/ ... -boot.html
And the instructions you refer to from http://slobytes.org/smf/index.php?topic=311.0 are only for grub2, which is not the default in Mageia yet.

If you want to change the resolution, you would need the vga=xxx option. See http://pierre.baudu.in/other/grub.vga.modes.html for an overview.
You can configure that in MCC, look at the link above. You probably want vga=791.
This is explained in more detail (e.g. if you need a custom resolution) also at https://wiki.archlinux.org/index.php/GR ... resolution

Re: Where is grub located in the file structure?

PostPosted: Jan 30th, '16, 12:29
by trexneb
@xboxboy: I wanted to change the resolution in my Mageia VM from 800:600 to 1440:900
@doktor5000: Thanks. I used the vga=ask, then selected 33F for 1440:900:32. Really appreciate it. Danke.

Re: Where is grub located in the file structure?

PostPosted: Jan 30th, '16, 14:57
by doktor5000
Please mark the thread accordingly by editing the topic of the first post and prefix it by [SOLVED], thanks

Re: [SOLVED] Where is grub located in the file structure?

PostPosted: Jan 30th, '16, 15:37
by trexneb
WILCO