FedoraForum.org - Fedora Support Forums and Community
Page 1 of 2 12 LastLast
Results 1 to 15 of 17
  1. #1
    Join Date
    Feb 2009
    Posts
    82
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    How to set the default GRUB2 font and splash screen in Fedora

    When I installed F16 on my laptop, the installer set up a coarse default font and a blank background. You have to use a manual method the set up the font and background splash. The following works for a wide screen. If you have a non-wide screen, adjust the numbers accordingly, and change the "wide" subdirectory to "standard".

    Make a GRUB2 font using (ignore the screen messages - the font is still made)
    Code:
    grub2-mkfont --output=/boot/grub2/DejaVuSansMono.pf2 --size=24 /usr/share/fonts/dejavu/DejaVuSansMono.ttf
    Edit /etc/default/grub and insert the following lines:
    Code:
    GRUB_FONT=/boot/grub2/DejaVuSansMono.pf2
    GRUB_GFXMODE=1280x800
    GRUB_GFXPAYLOAD_LINUX=keep
    GRUB_BACKGROUND=/usr/share/backgrounds/verne/default/wide/verne.png
    Rebuild the cfg file using
    Code:
    grub2-mkconfig -o /boot/grub2/grub.cfg
    ------------------Edited Jun 9, 2012--------------------

    Note that F17 implements an alternative method of setting the grub2 theme. If you wish to use the new method, comment out GRUB_FONT and GRUB_BACKGROUND and uncomment GRUB_THEME. It points to a text file theme.txt which contains the variables you need to adjust. After adjusting, rebuild the cfg file as described above.
    Last edited by plasmonics; 9th June 2012 at 01:07 PM. Reason: Software Upgrade

  2. #2
    Join Date
    Dec 2009
    Location
    India
    Posts
    712
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    thanks, i will try

  3. #3
    Join Date
    Mar 2004
    Location
    In your closet
    Posts
    16,565
    Mentioned
    19 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    I've tried this and it worked well. I give it an 8 out of 10. There are some minor issues but nothing critical.

    Thank you Plasmonics. I've been waiting for someone to figure this out. Since I like to have a menu background I've researched exaustively but the avalable (yes, I've seem them all) GRUB2 documentation, while good, is far from complete and quite lacking in a lot of areas.

  4. #4
    Join Date
    Mar 2011
    Location
    /
    Posts
    5,242
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    Quote Originally Posted by plasmonics
    When I installed F16 on my laptop, the installer set up a coarse default font and a blank background. You have to use a manual method the set up the font and background splash. The following works for a wide screen. If you have a non-wide screen, adjust the numbers accordingly, and change the "wide" subdirectory to "standard".

    Make a GRUB2 font using (ignore the screen messages - the font is still made)
    Code:
    grub2-mkfont --output=/boot/grub2/DejaVuSansMono.pf2 --size=24 /usr/share/fonts/dejavu/DejaVuSansMono.ttf
    Edit /etc/default/grub and insert the following lines:
    Code:
    GRUB_FONT=/boot/grub2/DejaVuSansMono.pf2
    GRUB_GFXMODE=1280x800
    GRUB_GFXPAYLOAD_LINUX=keep
    GRUB_BACKGROUND=/usr/share/backgrounds/verne/default/wide/verne.png
    Rebuild the cfg file using
    Code:
    grub2-mkconfig -o /boot/grub2/grub.cfg
    This will not work if the / partition is encrypted and there is no separate /usr partition - right? Can the image also be copied to /boot like the font?
    Last edited by nonamedotc; 23rd February 2012 at 04:22 PM. Reason: added

  5. #5
    PabloTwo's Avatar
    PabloTwo is offline "Fedora User" T-Shirt Winner
    Join Date
    Mar 2007
    Location
    Seville, FL
    Posts
    8,919
    Mentioned
    39 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    Quote Originally Posted by nonamedotc
    Can the image also be copied to /boot like the font?
    Yes. This is mine: GRUB_BACKGROUND=/boot/grub/farcry_3-1440x900.jpg

  6. #6
    Join Date
    Mar 2011
    Location
    /
    Posts
    5,242
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    Ah ! Excellent! Time to make the splash screen colorful

  7. #7
    Join Date
    Feb 2009
    Posts
    82
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    The image file can be in any directory. It also doesn't have to be png.

    The font can also be any ttf. I gave that example, because DejaVu is my default for many applications.


    -----------------------
    Correction (2/24/2012): It supports only tga, jpg, and png. grub2-mkconfig warns if the graphics format is unsupported.
    Last edited by plasmonics; 24th February 2012 at 11:15 AM.

  8. #8
    Join Date
    Mar 2005
    Location
    Brisbane, Australia
    Age
    55
    Posts
    264
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    I'm having trouble with this. I've placed an image in /boot/grub/blue_energy_tornado_grub_splash.jpg but when I run grub2-mkconfig I get nothing..
    GRUB_TIMEOUT=5
    GRUB_DISTRIBUTOR="Fedora"
    GRUB_DEFAULT=0
    GRUB_GFXMODE=1366x768
    GRUB_GFXPAYLOAD_LINUX=keep
    GRUB_BACKGROUND=/boot/grub/blue_energy_tornado_grub_splash.jpg
    GRUB_CMDLINE_LINUX="rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8"
    and

    [root@Faeland ~]# grub2-mkconfig -o /boot/grub2/grub.cfg
    Generating grub.cfg ...
    Found linux image: /boot/vmlinuz-3.3.0-4.fc16.x86_64
    Found initrd image: /boot/initramfs-3.3.0-4.fc16.x86_64.img
    Found linux image: /boot/vmlinuz-3.1.0-7.fc16.x86_64
    Found initrd image: /boot/initramfs-3.1.0-7.fc16.x86_64.img
    No volume groups found
    done
    [root@Faeland ~]#
    What am I doing wrong?

    EDIT:

    Off topic but what about the Fedora loading screen; that comes up after grub but before the login screen? That takes longer. Anyone point me in the right direction for changing that one?

    Thanks
    Last edited by synic; 24th March 2012 at 10:21 PM.

  9. #9
    PabloTwo's Avatar
    PabloTwo is offline "Fedora User" T-Shirt Winner
    Join Date
    Mar 2007
    Location
    Seville, FL
    Posts
    8,919
    Mentioned
    39 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    Quote Originally Posted by synic
    What am I doing wrong?
    You're failing to follow all the instructions. Go back up to post#1 of this thread and read it.
    It won't work without the font file.

  10. #10
    Join Date
    Mar 2005
    Location
    Brisbane, Australia
    Age
    55
    Posts
    264
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    Ah... you HAVE to have the font title.

    EDIT:

    KOOOOOL Hell Yes..

    Thanks.
    Last edited by synic; 24th March 2012 at 10:30 PM.

  11. #11
    Join Date
    Feb 2009
    Posts
    82
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    There is a code fragment in the bash script /etc/grub.d/00_header that looks for the font file. If it is not defined, it does not load the graphics part.

    This is also the standard behaviour in another (non-Fedora) distro that I use.

  12. #12
    Join Date
    Mar 2005
    Location
    Brisbane, Australia
    Age
    55
    Posts
    264
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    Quote Originally Posted by plasmonics
    There is a code fragment in the bash script /etc/grub.d/00_header that looks for the font file. If it is not defined, it does not load the graphics part.

    This is also the standard behaviour in another (non-Fedora) distro that I use.
    That's what I wanted to know. Weird that Grub2 would require this feature in order to be customisable.

  13. #13
    Join Date
    Dec 2009
    Posts
    4
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    Works well with Fedora 17 with the beefy-miracle image. I have two questions:
    I used the same font and size as in #1, but the vertical borderlines are not continuous, they are broken between the lines. Should I use other font or how could I fix that?
    How can I change the main title at the top?

  14. #14
    Join Date
    Feb 2009
    Posts
    82
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    The vertical lines remain broken with DejaVu. This is true with Debian/grub2 as well. I believe that the border decorations are written into the font definition file. You can try reducing the font size. You can also experiment with other fonts in /usr/share/fonts. Not all of them work. In the end, I switched back to DejaVu.

    I think the title is in /etc/defaults/grub.

  15. #15
    Join Date
    May 2012
    Location
    germany
    Posts
    49
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: How to set the default GRUB2 font and splash screen in Fedora

    Nice Thank you

    Furthermore you do not want anything if you do a fresh install simply use the following steps to enable background.

    Please open /etc/default/grub and uncomment the line "GRUB_THEME". Here an example for my config:
    Code:
    GRUB_TIMEOUT=30
    GRUB_DISTRIBUTOR="Fedora"
    GRUB_DEFAULT=saved
    GRUB_CMDLINE_LINUX="rd.md=0 rd.lvm=0 rd.dm=0 SYSFONT=True  KEYTABLE=de rd.luks=0 LANG=en_US.UTF-8 rhgb quiet"
    GRUB_THEME="/boot/grub2/themes/system/theme.txt"
    In the "theme.txt" is all you need to install a theme. Sure, you can change the background by simple change the background with your favourite one. This is a standard-entry after the fresh FD17 install.

    Don't forget to update grub as shown by @plasmonics

Page 1 of 2 12 LastLast

Similar Threads

  1. Is that hideous GRUB splash screen the current GRUB default?
    By Mariusz W in forum Reviews, Rants & Things That Make You Scream
    Replies: 10
    Last Post: 29th May 2011, 01:29 AM
  2. Huge font/DPI on Splash Screen
    By Crusnik01 in forum Using Fedora
    Replies: 2
    Last Post: 13th July 2008, 12:19 PM
  3. how do i get a splash screen for fedora 7?
    By $Linux in forum Installation, Upgrades and Live Media
    Replies: 0
    Last Post: 10th October 2007, 09:51 PM
  4. Fedora 4 Splash Screen?
    By carlwill in forum Using Fedora
    Replies: 1
    Last Post: 22nd October 2005, 01:15 AM
  5. How to make Splash screen default to gnome?
    By Trendkill in forum Using Fedora
    Replies: 10
    Last Post: 4th April 2005, 01:56 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •