Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Anyone have a good config for Grub2 (graphical mode)?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
Seph64
Apprentice
Apprentice


Joined: 13 May 2003
Posts: 191

PostPosted: Sun Dec 06, 2009 2:47 pm    Post subject: Anyone have a good config for Grub2 (graphical mode)? Reply with quote

I tried following the grub2 article at the gentoo wiki with no success on this issue.

it says to:
Quote:
if loadfont /boot/grub/unifont.pf2 ; then
set gfxmode="1280x1024x32;1024x768x32;800x600x32;640x480x32;1280x1024;1024x768;800x600;640x480"
insmod gfxterm
insmod vbe
terminal_output gfxterm
if terminal_output gfxterm; then true ; else
terminal gfxterm
fi
fi

insmod png
background_image /boot/grub/gentoo.png


The only difference is my image is grub.png

When grub loads I see what appears to be a small menu then goes in to the main menu (console) before I can see what items are listed in the first one.

I even followed the grub2 article for enabling graphics mode from the official grub wiki.

Anyone know what I am missing?

Here's my current grub.cfg file:
Quote:
cat /boot/grub/grub.cfg
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /sbin/grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
set default=0
set timeout=50
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/10_linux ###
menuentry "Gentoo GNU/Linux, with Linux x86_64-2.6.31-gentoo-r6" {
insmod ext2
set root=(hd0,5)
search --no-floppy --fs-uuid --set 5b49b784-c574-49ed-86a7-ed9e875322dc
linux /boot/kernel-genkernel-x86_64-2.6.31-gentoo-r6 root=/dev/ram0 real_root=/dev/sda5 ro
initrd /boot/initramfs-genkernel-x86_64-2.6.31-gentoo-r6
}
menuentry "Gentoo GNU/Linux, with Linux x86_64-2.6.31-gentoo-r6 (recovery mode)" {
insmod ext2
set root=(hd0,5)
search --no-floppy --fs-uuid --set 5b49b784-c574-49ed-86a7-ed9e875322dc
linux /boot/kernel-genkernel-x86_64-2.6.31-gentoo-r6 root=/dev/sda5 ro single
}
menuentry "Windows" {
insmod chain
set root=(hd0,2)
chainloader +1
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/30_os-prober ###
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.

insmod video
insmod vbe
insmod font
loadfont /boot/grub/unifont.pf2
insmod vbeinfo
insmod gfxterm
set gfxmode="1440x900x32;1024x786x32;800x500x32"
terminal_output vbeinfo gfxterm

insmod png
background_image /boot/grub/grub.png

### END /etc/grub.d/40_custom ###


Any help will be appreciated.
Back to top
View user's profile Send private message
Zoboulo
Tux's lil' helper
Tux's lil' helper


Joined: 07 Apr 2007
Posts: 97

PostPosted: Tue Dec 08, 2009 2:02 pm    Post subject: Reply with quote

Hi,

It seems you didn't paste the code from gentoo wiki at the right place : The "graphic" part should be configured before the "menu entry" section.
Here is my grub.cfg :

Code:

# Header

insmod ext2
set root=(hd0,5)
search --no-floppy --fs-uuid --set 38ab79ac-89ca-4cdd-a811-cce38a028836
if loadfont /boot/grub/unifont.pf2; then
        set gfxmode=1440x900
        insmod gfxterm
        insmod vbe
        terminal_output gfxterm
        insmod jpeg
        background_image /boot/grub/gentoo.jpg
fi

set timeout=10

# GRUB Linux Section


menuentry "Funtoo Linux 64-bit - /boot/kernel-2.6.31-r6" {
        insmod ext2
        set root=(hd0,5)
        search --no-floppy --fs-uuid --set 38ab79ac-89ca-4cdd-a811-cce38a028836
        linux /boot/kernel-2.6.31-r6 video=vesafb root=/dev/sda5 resume=/dev/sda7 quiet console=tty1 splash=silent,theme:natural_gentoo rootfstype=ext4
        set gfxpayload=1440x900
}

# GRUB Windows Section


menuentry "Windows XP" {
        set root=(hd0,1)
        chainloader +1
}


It works fine !
Back to top
View user's profile Send private message
Seph64
Apprentice
Apprentice


Joined: 13 May 2003
Posts: 191

PostPosted: Tue Dec 08, 2009 5:37 pm    Post subject: Reply with quote

Well to be honest the cfg I posted was an old one, a newer one placed the options before the menu entries but still didn't work. But your config file helped, it's working now...

But it's not displaying in the desired resolution. It's 1024x768 even though it is should be configured to 1440x900. And according to this article, that resolution should be supported by Vesa.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum