Unable to set GRUB background image

Yubin Ruan ablacktshirt at gmail.com
Fri Aug 18 02:51:43 UTC 2017


2017-08-17 2:19 GMT+08:00 Sreyan Chakravarty <sreyan.mailing at gmail.com>:
>
> I am unable to set a background image, for the Grub bootloader.
>
> Please note that my system boots of an encrypted LVM and the /boot partition
> is there on a separate unencrypted partition. And I am running on EFI.
>
> What I have tried so far-:
>
> I tried manually adding the following line to grub.cfg located in the /boot
> partition.
>
> GRUB_BACKGROUND="../IMAGE.JPG"
>
> this did not make any difference.
>
> Second, I have tried copying /usr/share/grub/default/grub
> to /etc/default and then added
>
> GRUB_BACKGROUND="IMAGE.JPG"
>
> and tried running update-grub but the generated grub.cfg in my /boot
> partition did not contain the above attribute. Also I am not sure if this
> would work since the image is in an encrypted partition and will not be
> available during the boot.
>
> What I want is to manually edit grub.cfg and place the attribute for the
> background image.
>
> My question is that should it be
> GRUB_BACKGROUND="../IMAGE.JPG"
> with quotes or without quotes ? Are relative paths supported ?
>
> Also should "set" be added before the attribute ?
>
> like
> set GRUB_BACKGROUND="../IMAGE.JPG" ?

Note sure whether I remember it correctly, but you should really use
absolute path when updating /etc/default/grub, i.e.,
GRUB_BACKGROUND="/path/to/your/img". And also, make sure that if you
use JPG/JPEG, it should be 8-bit (256 color), and images should be
non-indexed, RGB.

Yubin




More information about the ubuntu-users mailing list