您的位置:首页 > 运维架构 > Linux

如何让你linux启动时有可爱的企鹅图片?--关于framebuffer

2010-06-04 10:45 561 查看
方法一:如果没有fb设备就在/boot/grub/下
用vi grub.conf
打开grub.conf
在以下内容上
title Red Hat Enterprise Linux WS-up (2.6.9-5.EL )
root (hd0,6)
kernel /boot/vmlinuz-2.6.9-5.EL ro root=LABEL=/ rhgb quiet
initrd /boot/initrd-2.6.9-5.EL.img添加vag=0x0317后如下所示:title Red Hat Enterprise Linux WS-up (2.6.9-5.EL framebuffer)
root (hd0,6)
kernel /boot/vmlinuz-2.6.9-5.EL ro root=LABEL=/ rhgb quiet vga=0x0317
initrd /boot/initrd-2.6.9-5.EL.img
保存退出;重启。
重启后要按E键选择Red Hat Enterprise Linux WS-up (2.6.9-5.EL framebuffer),按B键进入就可以看到小企鹅了。
方法二:直接在启动过程中修改,此时修改不会保存下来的。在grub处按E键后选择Red Hat Enterprise Linux WS-up (2.6.9-5.EL framebuffer),再按E键编辑,在后面加上vag=0x0317,按回车后再按B启动,此时小企鹅就出现了。神奇吧?
***[/b]其实这是使用了Framebuffer***我们配置内核对framebuffer的支持,需要下面几个步骤。1. 察看/usr/src/linux-2.8.20.8目录下是否有内核源代码 2. 以root用户登录,并进入/usr/src/linux-2.4.20.8目录3. 运行make menuconfig//解决 选择“Code Maturity level opention”菜单,进入后设置“Prompt for development and/or incomplete code/drivers”,返回上级菜单,选择“Console drivers”,进入后选择“Frame-buffer support”,对于常用的图形卡设置“VESA VGA graphics console”,针对特定的图形卡可以使用特定的配置,最后我们在选择“Advanced low level driver options”,打开对16和32 bpp的像素支持。4. 随后编译内核 make dep ;//要花好几分钟make bzImage;//5到6分钟对于RedHat9.0 我们还可以通过修改/boot/grub/menu.lst文件来激活VESA Frame Buffer 驱动程序。即上面开始所述的做法只需要再该文件kernel开头的一行加入vga=0x0317,或者复制原有的引导选项,并修改得到原有的引导信息以及新修改的支持framebuffer的引导信息。# grub.conf generated by anaconda## Note that you do not have to rerun grub after making changes to this file# NOTICE: You do not have a /boot partition. This means that# all kernel and initrd paths are relative to /, eg.# root (hd0,0)# kernel /boot/vmlinuz-version ro root=/dev/hda1# initrd /boot/initrd-version.img#boot=/dev/hdadefault=0timeout=10splashimage=(hd0,0)/boot/grub/splash.xpm.gztitle Red Hat Linux (2.4.20-8, FrameBuffer) root (hd0,0) kernel /boot/vmlinuz-2.4.20-8 ro root=/dev/hda1 vga=0x0317 initrd /boot/initrd-2.4.20-8.imgtitle Red Hat Linux (2.4.20-8) root (hd0,0) kernel /boot/vmlinuz-2.4.20-8 ro root=/dev/hda1 initrd /boot/initrd-2.4.20-8.img注:RedHat使用的是grub引导装载器,若使用其它引导装载器请参考相关资料。本文出自 “no brothers,no linux” 博客,请务必保留此出处http://tonychiu.blog.51cto.com/656605/326526
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: