天天看点

ubuntu12.04更改登录背景,grub设置背景以及开机过程背景 关闭Ubuntu的载入画面

ubuntu12.04更改登录背景,grub设置背景以及开机过程背景

http://blog.sina.com.cn/s/blog_aef2d8550101a017.html

从大的过程来看,分为grub,plymouth和登录界面三个过程。

grub:/etc/default/grub文件和/boot/grub目录

splash screen&plymouth:   /lib/plymouth/theme/

登录界面: /usr/share/backgrounds

  1. grub设置背景:

https://help.ubuntu.com/community/Grub2/Displays#Choosing_a_GRUB_2_Background_Image

GRUB 1.99 and later

The following guidance for setting the background image is for GRUB 2 version found in Ubuntu 11.04, Natty Narwhal and later.

GRUB 1.99 greatly simplified adding a GRUB 2 splash image. In addition to the following procedures, the methods detailed for GRUB 1.98 will also work.

Note: Adding a background image requires system folder operations. The user must use administrator privileges to make the required changes.

  1. Review image requirements in the previous section to ensure the image you select is compatible with GRUB 2.

The user has two options for selecting the splash image to be used. The first requires editing a GRUB 2 configuration file. The second is to copy a compatible image file to thegrub folder.

  1. Open /etc/default/grub with a text editor.
    • Add the following line:
      • GRUB_BACKGROUND=/path/filename
      • Example: GRUB_BACKGROUND="~/Pictures/grubbackround.png"
    • This option takes precedence over the next method.

OR:

  1. Place a suitable image in the grub folder.
    • The default location for this folder is /boot/grub.
    • If more than one suitable image resides in the grub folder, the priority for the image used in GRUB 2 is:
      • First image found in /boot/grub
        • The first image found, in this order: jpg, JPG, jpeg, JPEG, png, PNG, tga, TGA
        • If multiple images of the same extension, alphanumerically.
  2. Update GRUB to incorporate the image into the GRUB 2 menu:
    • sudo update-grub      

        把图片放到/boot/grub目录下,运行sudo update-grub就行了。

2. 开机背景稍稍麻烦:更改开机背景

      找到自己喜欢的主题,放在/lib/plymouth/themes目录下

      然后运行sudoupdate-alternatives –config default.plymouth,按数字选择自己喜欢的主题包。

        sudo update-initramfs -u更新就行了

如何添加自己的主题:

http://www.ubuntugeek.com/quick-tipplymouth-themes-in-ubuntu-10-04-lucid-lynx.html

To change the default splash screen:

sudo update-alternatives --config default.plymouth

sudo update-initramfs -u

To fix the delayed loading of the splash:

sudo -s

echo FRAMEBUFFER=y >>/etc/initramfs-tools/conf.d/splash

update-initramfs -u

To install new themes manually; First copy the downloaded theme to /lib/plymouth/themes/mytheme; Then execute (replace mytheme with the name of the theme you are installing):

sudo update-alternatives --install /lib/plymouth/themes/default.plymouth default.plymouth /lib/plymouth/themes/mytheme/mytheme.plymouth 100

sudo update-alternatives --config default.plymouth

sudo update-initramfs -u

如果想屏蔽掉倒计时点点闪烁的画面,可以参考此方法:

关闭Ubuntu的载入画面

ubuntu启动时,会有一个ubuntu字样出现在屏幕,文字下方有闪烁的点,这时按ESC可以在动画和文字界面之间切换。这一步骤不属于lightdm,而是一个叫plymouth 的进程在起作用。实际上,plymouth的意义就在于,在开机到图形桌面(lightdm)起来这段时间里展示出一个动画,从而提高用户体验。

屏蔽的方法:

一、编辑 /etc/default/grub 文件,原文11行附近:

GRUB_CMDLINE_LINUX_DEFAULT="quietsplash" 

去掉”splash“,改后:

GRUB_CMDLINE_LINUX_DEFAULT="quiet"

二、执行命令:

sudu updat-grub

重启,即可看到,不再有载入画面出现了。

这次装完系统,开机画面很慢。。进度条得至少15s ,决定干掉它

ubuntu12.04更改登录背景,grub设置背景以及开机过程背景 关闭Ubuntu的载入画面

。。话不多说,上代码

1. cd /etc/default/

2.sudo cp grub grub.bak

3.sudo vim grub

把下面一行

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

改为

GRUB_CMDLINE_LINUX_DEFAULT="quiet"

4.sudo update-grub

我reboot了一下,6s到登录窗口(没测冷启动),舒服(而且满屏跑码,拿出去别人一看,挺像回事儿

ubuntu12.04更改登录背景,grub设置背景以及开机过程背景 关闭Ubuntu的载入画面

OK!

仅在10.04上试了,其他版本没试,希望大家看看其他版本下行不(特别是12.04,正纠结于升不升)

3.  更改登录背景:

找到/usr/share/backgrounds文件夹。然后你就找到名字为warty-final-ubuntu.png的图片,这个就是开机登录的画面了。先删除掉,我门要做的就是把他改掉成你想要的图片就行了。

首先,上网搜索出你想要的画面。下载下来,接着呢。sudo chmod -R 777/usr/share/backgrounds更改权限,因为这个目录是要root权限的。

接着吧你的图片复制到这个目录下,把名字改为warty-final-ubuntu.png就行了。

就是这么简单。希望能帮到你。

发现了如下路径的文件/usr/share/unity-greeter目录,与/usr/share/backgrounds目录并列关系。但对于该目录的处理方法就有所不同了。

down vote

For 11.10:

You need to edit /etc/lightdm/unity-greeter.conf (

sudo nano /etc/lightdm/unity-greeter.conf

). In that file you have to replace value ofBACKGROUND tag.

对于12.04版本,没找到/etc/lightdm/unity-greeter.conf文件。搜到了如下文件路径:/usr/share/glib-2.0/schemas/com.canonical.unity-greeter.gschema.xml  在这里面,有对于unity-greeter.png的配置。

有人也提到了,在进入自己的图片之前,会显示几秒系统默认的图片。但这里也没有提到解决办法:

http://askubuntu.com/questions/64001/how-do-i-change-the-wallpaper-of-the-login-screen

12.04

In Ubuntu 12.04 you don't need to do all those command line edits anymore. All you have to do is change your wallpaper andvoilá, LightDM will use it as the background (:

Sadly it seems not fully implemented yet, since when your computer starts, you see the defaultUbuntu wallpaper for some seconds before it change to your wallpaper. But since we are talking about a beta (Ubuntu 12.04 is in Beta 2 right now), it's expected.

手动修改配置文件xml,并重新编译:

12.04

Bruno Pereira's answer worked for me but could not be used in a context without X11.Here is an other way to do the same ... without the need of X11 (and easily scriptable) :

Edit the following file :

sudoedit /usr/share/glib-2.0/schemas/10_unity_greeter_background.gschema.override

[com.canonical.unity-greeter]
draw-user-backgrounds=false
background='/foo/wallpaper.png'
           

Apply the new settings :

sudo glib-compile-schemas /usr/share/glib-2.0/schemas/

英文网站有人专门就此问题展开解释:很难获得的网页:http://jdbausch.blogspot.com/2012/10/change-default-wallpaper-ubuntu.html

bing.com搜索关键词:wallpaper default before 

I'm really happy with how smooth Gnome-Shell is now.However, I still have one issue, which has been bugging me. When you first logon, you see the ugly-assUbuntu default wallpaper for just an instance before your chosen wallpaper comes up. Also, if you use wally to change yourwallpaper, you see the defaultwallpaper for a second or so when thewallpaper changes. Well, the fine folks on the #ubuntu-gnome freenode IRC channel explained how to change the defaultwallpaper: First, if you take a look at the file:     /usr/share/glib-2.0/schemas/10_ubuntu-settings.gschema.override You will find this section:     [org.gnome.desktop.background]     show-desktop-icons=true     picture-uri='file:///usr/share/backgrounds/warty-final-ubuntu.png' This is what is telling the system the location of the default wallpaper.So you could just modify this section, and then be done. But if you did that any update that rewrites that file may overwrite your changes. So this fix will be more resistant to updates: In the same folder mentioned above, make a new file called:     30_custom-settings.gschema.override and put the following text in it:     [org.gnome.desktop.background]     picture-uri='file:///usr/share/backgroundsWHATEVERBACKGROUNDYOUWANT' Two things to note about this: First, you will want to pick an image in that folder, or put an image in there you want to use. Second, the file in question can be named whatever you like, but must have a number on it - the higher the number the greater the priority with overridden settings.  After you have saved the file, run this from the terminal:     sudo glib-compile-schemas /usr/share/glib-2.0/schemas/ Then logout, and you should see the chosen wallpaper instead of that default one.