HOWTO Splash image in GRUB

本文介绍如何使用GIMP创建并安装自定义的GRUB启动画面背景图。通过调整图片尺寸和颜色数量,再利用gzip压缩并配置grub.conf文件指向新图片路径,即可实现个性化启动界面。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Contents

[hide]

[ edit]

Introduction

The splash image is the image shown in the background when GRUB (the GRand Unified Bootloader) is displaying the list of operating systems you can boot. All you need to customize it is the GIMP and gzip. You will need to make sure your GRUB supports the splashimage command. I took image from gentoo.org and cut a little for the GRUB background

Image:Gentoo-box.png

[ edit]

Creating image

  1. Start the GIMP.
  2. Click on File->New or type Ctrl+N
  3. In the new image dialog, change Width to 640 pixels and Height to 480 pixels. (The image should be of size 640x480 pixels.) Now click OK.
  4. Create the image which you would like to be the splash image. It's quite fun to experiment with the various tools of the GIMP!
  5. After you have finished creating the image, hit Alt+i or right click on the image and click on Image->Mode->Indexed...
  6. In the Indexed Color Conversion dialog that appears, click on the radio button "Generate optimal Palette" and in "# of colors" enter 14. Click OK.(The image should be of only 14 colors)
  7. Now right-click on the image and click on File->Save As...Save the file as ImageName.xpm in a directory of your choice.
For some reasons i could not create *.xpm so i save it as *.png and then
convert ImageName.png ImageName.xpm

(convert is a part of media-gfx/imagemagick

You can save image from this page and convert it skipping image creation hassle
[ edit]

Creating image (alternative)

  • You can also pick an image (any type supported by ImageMagick) and execute:
convert -resize 640x480 -colors 14 picture.jpg ImageName.xpm
[ edit]

Installing the Image

gzip ImageName.xpm
mount /boot
mv ImageName.xpm.gz /boot/grub/
  • In the /boot/grub/grub.conf you have to point splashimage to newly created image i.e.
File: /boot/grub/grub.conf
# Splash Image
splashimage=(hd0,0)/grub/ImageName.xpm.gz

That's it! When you reboot, you will find your image in the background, with the menu of operating systems etc. in the foreground.

[ edit]

Credits

Customizing the splash image in GRUB by C.R. Jayanth

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值