Jump to content

Change the grub menu pic with gfxboot


skinky
 Share

Recommended Posts

Hi all

 

I only just figured out how to change the image displayed at the grub boot menu whilst still keeping animations (Mandriva's timer animation) with gfxboot - as opposed to the not-quite-so-pretty (IMHO) pics with standard grub. There is very little info on the internet about gfxboot so I thought this may help someone else who wishes to change Mandriva's nice pic.

 

I haven't experimented with changing the text/fonts or anything else - just the image. Also I've only done this with Mandriva Spring (2007.1).

 

Mandriva Spring installs the mandriva-gfxboot-theme package by default which also comes with a program called /usr/sbin/grub-gfxmenu to update the gfxmenu. So all I did was replace Mandriva's images with my own! The images are 800x600 in size and I did not reduce the colours at all. Here's a list of the files I replaced - all with the same image:

 

		  /usr/share/gfxboot/themes/Mandriva/back.jpg
	  /usr/share/gfxboot/themes/Mandriva/welcome.jpg
	  /usr/share/gfxboot/themes/Mandriva/install/back.jpg
	  /usr/share/gfxboot/themes/Mandriva/install/welcome.jpg

 

I then did the following:

 

		  #  su
	  #  cd /usr/share/gfxboot/themes/
	  #  ln -s Mandriva current
	  #  /usr/sbin/grub-gfxmenu --update-gfxmenu
	  #  grub-install /dev/hda

 

Then I rebooted and voila! My pic is now at the grub boot menu and Mandriva's timer animation still works! :thumbs:

 

IMORTANT NOTE: Obviously the above command (grub-install /dev/hda) should point to where you have grub installed if not in the MBR of the first IDE disk!

 

HTH someone.

Edited by skinky
Link to comment
Share on other sites

Thanks a bunch -- I figured stuff out the hard way (by editing the file referenced by the gfxmeny command in grub's menu.lst). The commands to do this (for a file called 'gfxmenu', like the one located in /boot) are:

cd work				# Go to an empty directory
cpio -i < gfxmenu	# Unpack all files from mandriva default GRUB splash
...				# Commands to modify and/or replace the graphic file
ls . |cpio -o > ../newsplash	# Create a new archive
...				# copy file back to /boot and adapt /boot/grub/menu.lst accordingly

(gfxmenu expects its input in n an CPIO archive)

 

The only info I have been able to find on gfxmenu (some Suse forums) was that the image should be 800x600 and 'not too big'.

Link to comment
Share on other sites

  • 1 month later...
Thanks a bunch -- I figured stuff out the hard way (by editing the file referenced by the gfxmeny command in grub's menu.lst). The commands to do this (for a file called 'gfxmenu', like the one located in /boot) are:

cd work				# Go to an empty directory
cpio -i < gfxmenu	# Unpack all files from mandriva default GRUB splash
...				# Commands to modify and/or replace the graphic file
ls . |cpio -o > ../newsplash	# Create a new archive
...				# copy file back to /boot and adapt /boot/grub/menu.lst accordingly

(gfxmenu expects its input in n an CPIO archive)

 

The only info I have been able to find on gfxmenu (some Suse forums) was that the image should be 800x600 and 'not too big'.

 

Thanks for the info guys , you saved me a lot of time searching for the location of that pic.

 

I used pindakoes method, but I can't get the before last part " ls . |cpio -o > ../newsplash # Create a new archive "

 

I extracted all the gfxmenu CPIO archive to a folder or directory, so when I try to archive that directory with the extracted file I get a message saying that I can not archive that path because it is a directory, I don't know of any other way of archiving a bunch of files at once into one archive. I'm used to using archiver and winrar where you can just archive a folder or directory.

 

Any ideas ? B) :unsure:

Edited by Littleguy
Link to comment
Share on other sites

I was able to create the CPIO archive, but I just realized that the files inside my new gfxmenu archive were pointing to my home folder, and then I would have to update Grub ..

 

All I wanted to do is change the Mandriva Blue Powepack Picture for the Orange Mandriva One Picture ... It's a shame I can't just drag the picture into the original gfxmenu archive and replace it...since they have the same name(back.jpg) and size(800x600).

 

My gfxmenu archive is in the root folder(/) in: sda8/boot/gfxmenu

Is there a command by any chance to replace blue (back.jpg)mandriva picture for the Orange(back.jpg) picture ? :rolleyes: ..I'm not getting thrue with the above methods and it's basicaly cause I don't know anything , in other words , i'm lost with all the commands

Edited by Littleguy
Link to comment
Share on other sites

Just realised there is a small but significant type in my comment. The whole set of commands becomes:

 

cd ~
cp /boot/gfxmenu .
# Now make new dir to construct updated gfxmenu
mkdir test
cd test
cpio -i < ../gfxmenu
# Now replace the old graphic by the new one. Make sure name stays the same
mv /path/to/old/orange.jpg back.jpg
ls |cpio -o > ../gfxmenu2

At the end of this you will have the old boot menu (gfxmenu) and the new one (gfxmenu2). Update your /boot/grub/menu.lst with the location of the new bootgraphic and restart.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...