Fix Black Screen After Boot Problem of Ubuntu 9.10 on D630

Platform: Dell Latitude D630, Nvidia NVS 135M, Intel CPU, Ubuntu 9.10

Problem:

1. Boot from livecd, select install. After a glowing ubuntu Symbol, screen shows nothing, even no CLI.

2. After installation with "text mode", boot from HD. After a glowing ubuntu Symbol, screen shows nothing, even no CLI.

Solution:

I am not very sure whether this problem is caused by the NV 185 driver(nvidia-glx-185). Installing or removing this package gave no help. I googled a lot, found many people encountered the same problem. However, no answer could work on my laptop. Then I tried to install NV driver manually...it works! So, here is the fix:

1. When you get the GRUB boot menu screen, press 'e' to edit the fist entry. Add a word 'single' after 'linux /boot/vmlinuz..... quiet splash', then press 'Ctrl+x' to boot. (I cannot enable networking in recovery mode, so I tried with the single mode.)

2. Select the 'netroot' entry. You will get a root command line with network support.

3. Download the latest NV driver for linux (2010-11-3):

# wget http://us.download.nvidia.com/XFree86/Linux-x86/190.42/NVIDIA-Linux-x86-190.42-pkg1.run

[You can visit http://www.nvidia.com/object/unix.html for the latest NV driver.]

4. Install development tools to build NV driver on you os.

# apt-get update
# apt-get install build-essential

5. Install the NV driver:

# chmod u+x NVIDIA-Linux-x86-190.42-pkg1.run
# ./NVIDIA-Linux-x86-190.42-pkg1.run

6. Reboot.

If you are using a livecd, please use the "text mode" to install Ubuntu 9.10. After installation, try the solution above.

Ubuntu 9.10 启动后黑屏的解决方法

平台: Dell Latitude D630, Nvidia NVS 135M, Intel CPU, Ubuntu 9.10

问题描述:

1. 从 livecd 启动后,选择安装,在白色 Ubuntu 图标闪烁结束之后,无任何屏显,连命令行都没有。

2. 用文本模式安装完成后,从硬盘启动,在白色 Ubuntu 图标闪烁结束之后,无任何屏显,连命令行都没有。

解决方法:

我不太清楚是不是 NV 的 185 驱动有问题(nvidia-glx-185),安装或者删除它对状况没有任何帮助。我搜索了一下,发现很多人遇到和我类似的问题,不过没有任何解决方法可以在我的电脑上工作。无奈下我尝试手动安装了一下 NV 的最新驱动——居然解决了!下面是我的解决方法:

1. 当你进入 grub 启动菜单选择屏幕时,在第一条上按 e 进入编辑状态,在 'linux /boot/vmlinuz..... quiet splash' 这一行最后添加一个单词 single,然后按 Ctrl+x 启动。其实 recovery mode 能做类似的事,但是 9.10 的 recovery mode 好像不能启动网络,所以只好自己进入 single 模式了。

2. 启动后选择 'netroot' 选项,进入带网络的 root 命令行。

3. 下载最新的 NV 驱动(2010-11-3):

# wget http://us.download.nvidia.com/XFree86/Linux-x86/190.42/NVIDIA-Linux-x86-190.42-pkg1.run

[你可以先访问 http://www.nvidia.com/object/unix.html 查看 NV 最新驱动的地址。]

4. 安装编译 NV 驱动需要的编译工具:

# apt-get update
# apt-get install build-essential

5. 安装 NV 驱动:

# chmod u+x NVIDIA-Linux-x86-190.42-pkg1.run
# ./NVIDIA-Linux-x86-190.42-pkg1.run

6. 重启

如果您使用 livecd 安装 Ubuntu 9.10 的话,您应该选择 "text mode" 进行安装。成功安装完成后,仍然遇到黑屏问题,请尝试上述方法。

在 Ubuntu Linux 8.04 上安装永中 Office 2007

这篇文章介绍了在 Ubuntu Linux 8.04上安装永中 Office 2007 遇到的问题以及解决的办法。由于其主要问题在于 Java 虚拟机,其它 Linux 平台如果遇到同样情况也可以借鉴这里的方法。

永中 Office 2007 Linux

目录

1. 介绍
2. 下载
3. 安装问题
4. 运行问题

1. 介绍

用 OpenOffice 总会遇到这样那样的中文问题,有时候怎么也搞不定,很令人沮丧。听说永中 Office 虽然只放出试用版,但在 Linux 下超过试用期后只会提示超期而不会禁止使用,就尝试着装了一下永中 Office。

2. 下载

从官方下载地址:http://www.evermoresw.com.cn/webch/download/downEIOffice.jsp 下载永中 Office 2007 Linux 安装包。

安装之后才知道 Ubuntu 中文源中有打包好的 deb 文件,要从源中直接安装就方便许多了。比如用 CN99 源的话,将:

deb http://ubuntu.cn99.com/ubuntu-cn hardy main restricted universe multiverse

加入 /etc/apt/sources.list 中,然后:

$ sudo apt-get install eio

即可。我没有尝试这一方法,从源直接安装显然不会出现下面的"3. 安装问题",但不知道会不会出现下面讨论的"4. 运行问题"。

3. 安装问题

下载好官方的 Office 2007 Linux 安装包之后,先解压:

$ tar -xzvf EIO2007BetaZH_Lin.tar.gz

然后,进入安装目录,执行安装脚本:

$ cd 4.3.1210.101ZH.L1/
$ sudo sh setup.sh

将会出现下面错误,而且安装窗口显示为空白(窗口空白可能是由于 Beryl 引起的 Java Swing 界面问题):

Decompression in Progress,Please Wait.
Locking assertion failure. Backtrace:
#0 /usr/lib/libxcb-xlib.so.0 [0xb2a66767]
#1 /usr/lib/libxcb-xlib.so.0(xcb_xlib_unlock+0x31) [0xb2a668b1]
...

这个问题可能因为永中 Office 使用自带的 JRE 和系统的某些库不匹配导致的,所以我们只需更改安装脚本,让它使用系统的 JRE。用编辑器(如 vim)打开 setup.sh,按照下面的方法注释掉解压和使用自带 JRE 的两行,添加一行使用系统 JRE 的命令。(注意:使用 gcj 的 jre 也会出现错误,最好使用 Sun 官方的 jre,Ubuntu 下使用 sudo apt-get install sun-java6-jre 安装。)

$ vim setup.sh
#unzip $progdir/Jre.zip -d /tmp/EIOffice/ &> /dev/null
#/tmp/EIOffice/Jre/bin/java -jar $progdir/dispose.jar $1
/usr/lib/jvm/java-6-sun/jre/bin/java -jar $progdir/dispose.jar $1

然后再执行 sudo sh setup.sh 命令,就能出现正常的安装窗口了。下面的安装步骤和 Windows 下软件的安装步骤颇为相似,只是选择安装路径那一项最好将 /usr/local 改成 /opt,因为永中 Office 不是开源软件。

4. 运行问题

安装完成后,运行永中 Office:
$ eio
Locking assertion failure. Backtrace:
#0 /usr/lib/libxcb-xlib.so.0 [0xb7d37767]
#1 /usr/lib/libxcb-xlib.so.0(xcb_xlib_unlock+0x31) [0xb7d378b1]
...

和刚开始安装时一样,出现下面错误,主窗口中也是空白。如前面所说,窗口空白可能是由于使用了 Beryl 窗口管理器引起的 Java Swing 界面问题,可以通过修改永中 Office 的启动文件解决,在 /usr/bin/eio 中正式代码前添加 export AWT_TOOLKIT=MToolkit 一行:

$ sudo vim /usr/bin/eio
#!/bin/bash
export AWT_TOOLKIT=MToolkit
exec 4<&0 0

在 Dell Latitude D630 上硬盘安装 Ubuntu Linux 8.04

最后更新时间:2008年4月18日

摘要

这份文档主要描述了我在自己的 Dell Latitude D630 上安装 Ubuntu Linux 8.04 的过程。

目录

1. 介绍
2. 安装
3. 效果截图
4. 总结

1. 介绍

虽然一直想忍着等 Ubuntu Linux 8.04(Hardy Heron) 正式发布了再安装它,但最后还是受不了诱惑,在还有 6 天就发布时候当了一次小白。这次 Ubuntu 真的是让我相当相当满意,安装过程什么问题都没有出,所有硬件均一步识别,太爽了!这次写的安装介绍,要比上次那篇简单多了,我真心希望以后的 Ubuntu 版本安装的时候再也不用看别人的安装介绍了。

而且这次 Ubuntu Studio 的 theme 也比 7.10 漂亮许多,Compiz-fusion 的 3D 桌面特效也更好了,真酷!兄弟姐妹们,来玩 Ubuntu 吧!

2. 安装

[安装基本操作系统]
由于我电脑上本来就有 Ubuntu 7.10 和 Cent OS 5.1,所以我的 Ubuntu 8.04 是通过修改 grub 的 menu.lst 来进行硬盘安装的。

首先,下载安装光盘镜像文件:
$ wget -c http://cdimage.ubuntu.com/daily/current/hardy-alternate-i386.iso
由于现在 Ubuntu 8.04 还没有正式发布,所以我是从 daily build 的地址下的,当看到这篇文章时可能它已经发布了,那就请到官方公布的地址下吧。

其次,下载硬盘安装文件:
$ wget http://archive.ubuntu.com/ubuntu/dists/hardy/main/installer-i386/current/images/hd-media/vmlinuz
$ wget http://archive.ubuntu.com/ubuntu/dists/hardy/main/installer-i386/current/images/hd-media/initrd.gz

将这三个文件放在某个分区根目录下,再修改 /boot/grub/menu.lst,在列表最后添加上以下几行:
title Ubuntu 8.04 Install Entry
root (hd0,3)
kernel /vmlinuz root=/dev/ram ramdisk_size=100000 devfs=mount,dall
initrd /initrd.gz
请注意第二行的(hd0,3)是指放镜像文件那个分区编号,请根据自己情况自行修改。一般情况下如果放到了 /dev/sdan 下的话,这个就应该是 (hd0,n-1)。

然后重启电脑,在 grub 中选择引导项 Ubuntu 8.04 Install Entry 进行安装,安装过程不赘述。我一般选择系统语言为英语,地域为中国。

[修改更新源列表]
选择速度最快的源,将 /etc/apt/sources.list 中默认的官方源替换掉,比如我的 sources.list 文件内容就是
deb http://debian.ustc.edu.cn/ubuntu/ hardy main restricted universe multiverse
deb http://debian.ustc.edu.cn/ubuntu/ hardy-updates main restricted universe multiverse
deb http://debian.ustc.edu.cn/ubuntu/ hardy-security main restricted multiverse universe
deb http://debian.ustc.edu.cn/ubuntu/ hardy-backports main restricted universe multiverse

[更新操作系统]
$ sudo apt-get update
$ sudo apt-get upgrade

[安装受限驱动]
在更新完操作系统后,System Notifacation Area(桌面右上角) 中会出现提示安装受限驱动的气泡,点击安装即可。

[安装中文输入法]
在 System->Administration->Language Support 中选择安装中文支持,并在下方勾选上 Enable support to enter complex characters. 系统会自动下载并安装中文支持和中文输入法,安装完后系统会要求重启,重启以后就可以在软件中直接用 Ctrl+Space 调出输入法了。^_^ 比以前的版本配置中文输入法简单太多了!!!

[安装 Windows XP 中文字体]
这是我写的一个小脚本,可以将双系统的 XP 字体拷贝到 Linux 下并使用它们。注意,这将涉及到版权问题,如果不确信的话,请跳过这一步。
$ wget http://share.solrex.org/scripts/install_win_CN_fonts_to_linux.sh
$ sudo sh install_win_CN_fonts_to_linux.sh
然后重新登录 X window

[安装 Ubuntu Studio 主题]
Ubuntu Studio 的黑色桌面主题是我非常喜欢的桌面主题,再配上诺贝尔和平奖得主戈尔的获奥斯卡最佳纪录片奖的电影 An Inconvenient Truth 的灰色背景海报,简直太配了。如果不喜欢,请跳过这一步。
$ sudo apt-get install ubuntustudio-theme
然后在 System->Preference->Appearance 中选择使用 Ubuntu Studio Theme。

[安装 Compiz-Fusion 3D 桌面特效引擎]
$ sudo apt-get install compiz-fusion-plugins-* compizconfig-settings-manager emerald
然后在 System->Preference->Advanced Desktop Effect Settings 中配置喜欢的桌面特效。

[安装 Mplayer/SMplayer 媒体播放器以及解码器]
$ sudo apt-get install mplayer smplayer
下载最新解码器:
$ wget -c http://www.mplayerhq.hu/MPlayer/releases/codecs/all-20071007.tar.bz2
将最新解码器库扔到 /usr/lib/win32 目录下:
$ tar -xjvf all-20071007.tar.bz2
$ sudo mkdir /usr/lib/win32
$ sudo mv all-20071007/* /usr/lib/win32
这样就可以使用 Mplayer/SMplayer 播放几乎任何格式的影片了。

[安装 星际译王(StarDict) 和辞典包]
$ sudo apt-get install stardict
然后到星际译王官方网站下载安装需要的辞典包

[安装 MP3 播放器 Amarok/xmms]
$ sudo apt-get install amarok

[安装 BBS 登录软件 Qterm]
$ sudo apt-get install qterm

[安装聊天工具 Pidgin, Eva]
$ sudo apt-get install pidgin eva

[安装邮件客户端 ThunderMail]
$ sudo apt-get install mozilla-thunderbird

[安装系统启动项管理软件 sysv-rc-conf]
$ sudo apt-get install sysv-rc-conf

[安装 vim 完全版(gvim)]
$ sudo apt-get install vim-full

[安装编译工具库, g++ 和 javac]
$ sudo apt-get install libc6-dev g++ g++-4.2 sun-java6-jdk

[安装压缩解压缩工具 unzip, unrar, 7zip]
$ sudo apt-get install unzip unrar p7zip-full

[安装 Internet 时间同步工具 ntp]
$ sudo apt-get install ntp

[安装程序开发工具 kscope, eclipse, SVN tool, 十六进制文本编辑器, 网络文件系统]
$ sudo apt-get install kscope eclipsesubversion hexedit nfs-client

[安装工程图画图工具]
$ sudo apt-get install dia kivio

[安装摄像头查看工具]
$ sudo apt-get install cheese

[安装 CHM 文件查看工具]
$ sudo apt-get install chmsee kchmviewer

[安装 tex 编辑编译工具]
$ sudo apt-get install texlive cjk-latex kile

[安装 dos unix 文件转换工具]
$ sudo apt-get install tofrodos

[安装 Adobe Reader]
$ sudo apt-get install acroread
如果上面命令不管用,用下面方法下载安装:
$ wget -c http://debian.cn99.com/ubuntu-cn/dists/gutsy/main/binary-i386/adobe/AdobeReader_chs-8.1.1-1.i386.deb
$ sudo dpkg -i AdobeReader_chs-8.1.1-1.i386.deb

3. 效果截图

Amarok 播放器

4. 总结

Ubuntu 8.04 对电脑硬件的支持又进了一步,至少在我以前曾经有问题的显卡和声卡上都没有出现问题,让人很开心。而更好看的桌面主题,更酷的 3D 桌面效果,更简化的安装过程,更完善的多语言支持,真的很赞,我相信 Ubuntu 将借此进一步巩固和扩大它在 Linux 桌面市场占有率。大家都来用 Ubuntu 吧,它可 Windows 酷多了!

在 Dell Latitude D630 上安装 Ubuntu LInux 7.10

摘要

这份文档主要描述了我在自己的 Dell Latitude D630 上安装 7.10 的过程,Ubuntu 7.10 现在在我的笔记本电脑上运行正常(准确说基本功能工作正常,因为我未做太多测试)。

目录

1. 介绍
2. 安装
3. 总结
4. 计算机硬件信息
5. 参考文章

1. 介绍

我最近买了一台 Dell Latitude D630 笔记本电脑。除了原装的 Windows XP Home Edition, 我已经在这台笔记本上安装 RHEL5,然后又安装了 Ubuntu 7.10 Linux 操作系统,下面是我安装 Gutsy Gibbon(Ubuntu 7.10) 的过程介绍。

2. 安装

[ 安装基本操作系统 ]
# wget http://releases.ubuntu.com/7.10/ubuntu-7.10-alternate-i386.iso
# wget http://archive.ubuntu.com/ubuntu/dists/gutsy/main/installer-i386/current/images/hd-media/initrd.gz
# wget http://archive.ubuntu.com/ubuntu/dists/gutsy/main/installer-i386/current/images/hd-media/vmlinuz
# cp vmlinuz initrd.gz /media/sda5
# echo "title Gutsy Install Entry" >> /boot/grub/menu.lst
# echo " root (hd0,4)" >> /boot/grub/menu.lst
# echo "kernel /vmlinuz root=/dev/ram ramdisk_size=40000 devfs=mount,dall" >> /boot/grub/menu.lst
# echo "initrd /initrd.gz" >> /boot/grub/menu.lst
# reboot
以上下载地址可以换成任何 Ubuntu 镜像站点的下载地址。重新启动时在 Grub 的启动列表中选择 Gusty Install Entry,接下来就是标准的安装过程了。关于里面硬盘分区的位置问题(即 (hd0,4), sda5) 等这些名字,每个计算机有所不同,请根据自己计算机分区和硬盘情况相应修改。最简单的办法,把那两个文件放在某个分区根目录下,一个分区一个分区的试。

[ 修改更新源列表 ]
添加以下行到 /etc/apt/source.list 中:
deb http://ubuntu.cn99.com/ubuntu/ gutsy main restricted
deb http://ubuntu.cn99.com/ubuntu/ gutsy-updates main restricted
deb http://ubuntu.cn99.com/ubuntu/ gutsy universe
deb http://ubuntu.cn99.com/ubuntu/ gutsy-updates universe
deb http://ubuntu.cn99.com/ubuntu/ gutsy multiverse
deb http://ubuntu.cn99.com/ubuntu/ gutsy-updates multiverse
deb http://ubuntu.cn99.com/ubuntu/ gutsy-security multiverse
deb http://ubuntu.cn99.com/ubuntu/ gutsy-security main restricted
deb http://ubuntu.cn99.com/ubuntu/ gutsy-security universe

在其它行前加上注释符 #

[ 更新操作系统,安装工具软件包 ]
$ sudo apt-get update
$ sudo apt-get upgrade
$ sudo apt-get install libc6 libc6-dev
$ sudo apt-get install gcc-4.2
$ sudo apt-get install g++-4.2
libc6 和 gcc 主要是为下面安装显卡驱动准备的。

[ 下载 nVidia 最新显卡驱动 ]
$ wget http://us.download.nvidia.com/XFree86/Linux-x86/100.14.09/NVIDIA-Linux-x86-100.14.09-pkg1.run

[ 修改 root 用户密码 ]
$ sudo passwd

[ 安装显卡驱动 ]
$ sudo reboot
重新启动时在 Grub 的启动列表中选择 Ubuntu 7.10, kernel 2.6.22-14-generic (recovery mode),输入 root 用户密码,运行 NVIDIA-Linux-x86-100.14.09-pkg1.run,按照指示进行。安装成功后重新启动系统,在系统启动前跳出的对话框里选择配置显示效果,选择 1280x800 分辨率的基本配置,并在下方的使用宽屏选项栏打上勾。

[ 解决 DVD±RW 驱动问题 ]
$ cp /etc/modules /etc/modules.bak
$ cp /etc/modules /tmp
$ echo piix >> /tmp/modules
$ sudo cp /tmp/modules /etc/modules
$ sudo reboot
这个我未曾尝试,因为还没有在 Linux 下刻录过光盘。

[ 解决声卡驱动问题 ]
因为 Dell Latitude D630 声卡版本比较新,用 Ubuntu 自带的 ALSA 驱动无法配置。解决办法是手工安装 ALSA 最新版本的 driver, lib 和 utils。详细步骤请参考:
http://blog.solrex.org/articles/solve-ubuntu-intel-soundcard-problem-with-latest-alsa-driver.html

[ 安装中文输入法 ]
首先在 System->Administration->Language Support 中选择安装中文支持,自动安装完中文支持以后:
$ sudo apt-get install scim-bridge-agent
$ sudo im-switch -s scim -z default
在 /etc/X11/xinit/xinput.d/scim 中找到以下两行并更改:
GTK_IM_MODULE=scim-bridge
QT_IM_MODULE=xim
如果 im-switch 不成功,可以手动将设置文件 copy 到 default 去
$ sudo cp /etc/X11/xinit/xinput.d/default /etc/X11/xinit/xinput.d/default.bak
$ sudo cp /etc/X11/xinit/xinput.d/scim /etc/X11/xinit/xinput.d/default
$ sudo reboot
如果重启后 Firefox 仍然不可以使用中文输入,可以在 Firefox 的启动脚本 /usr/lib/firefox/run-mozilla.sh 中最后 exit 前面加这么一句:
export GTK_IM_MODULE=xim

[ 安装 Windows 中文字体 ]
未在电脑上安装 Windows 操作系统者不需要此步骤,已安装者也可以选择跳过。我写了一个脚本做这个工作,可以下面链接下载。

$ wget http://share.solrex.org/scripts/install_win_CN_fonts_to_linux.sh
$ sudo sh install_win_CN_fonts_to_linux.sh
重新登录 X window

[ 安装 compiz-fusion 3D 桌面效果 ]
为了这一步的安装,你需要修改一下 xorg.conf 文件,请参考:http://compiz.org/NVidia。需要特别注意的是,如果选择了官方驱动,请不要安装任何 Ubuntu 软件仓库里的驱动。你可以从下面得到我的 xorg.conf 文件。
$ wget http://share.solrex.org/scripts/xorg.conf
$ sudo apt-get install compiz-fusion-plugins-* compizconfig-settings-manager
安装完成以后在 System->Preference->Appearance 中的 Visual Effects 中多出一项 Custom,选择以后,点右侧的 Preferences 配置效果。
注:最新版本的 Ubuntu 官方驱动已经支持 D630 的显卡,在选择 Custom选项时会自动安装驱动。安装完驱动后自动配置的 xorg.conf文件为:
http://share.solrex.org/scripts/xorg.conf.glx 

3. 总结

硬件信息 Linux 下状态 备注
Intel Core2 Duo T7100 @ 1.8 GHz 工作正常
14.1" WXGA TFT (1280x800) 工作正常
nVidia Corporation Quadro NVS 135M 工作正常 手工安装驱动程序
1 GB RAM (2 x 512 MB DDR2 533 MHz) 工作正常
120 GB HDD (Hitachi HTS722016K9A300) 工作正常
DVD±RW (PBDS DVD±RW DS-8W1P) 未验证 据说可以在 /etc/modules 增加 piix 解决.
Broadcom NetXtreme BCM5755M Gigabit Ethernet 工作正常
Broadcom Corporation BCM94311MCG wlan mini-PCI 未验证
Intel 82801H sound card (ICH8) 工作正常 Ubuntu 7.10 参见上面讲的处理方法.
Memory card reader 未验证
Internal 56k modem 未验证

4. 计算机信息

[ 所有 pci 设备 ]
$ lspci
00:00.0 Host bridge: Intel Corporation Mobile PM965/GM965/GL960 Memory Controller Hub (rev 0c)
00:01.0 PCI bridge: Intel Corporation Mobile PM965/GM965/GL960 PCI Express Root Port (rev 0c)
00:1a.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Contoller #4 (rev 02)
00:1a.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #5 (rev 02)
00:1a.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #2 (rev 02)
00:1b.0 Audio device: Intel Corporation 82801H (ICH8 Family) HD Audio Controller (rev 02)
00:1c.0 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 1 (rev 02)
00:1c.1 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 2 (rev 02)
00:1c.5 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 6 (rev 02)
00:1d.0 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #1 (rev 02)
00:1d.1 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #2 (rev 02)
00:1d.2 USB Controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #3 (rev 02)
00:1d.7 USB Controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #1 (rev 02)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev f2)
00:1f.0 ISA bridge: Intel Corporation 82801HEM (ICH8M) LPC Interface Controller (rev 02)
00:1f.1 IDE interface: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) IDE Controller (rev 02)
00:1f.2 IDE interface: Intel Corporation 82801HBM/HEM (ICH8M/ICH8M-E) SATA IDE Controller (rev 02)
00:1f.3 SMBus: Intel Corporation 82801H (ICH8 Family) SMBus Controller (rev 02)
01:00.0 VGA compatible controller: nVidia Corporation Quadro NVS 135M (rev a1)
03:01.0 CardBus bridge: O2 Micro, Inc. Cardbus bridge (rev 21)
03:01.4 FireWire (IEEE 1394): O2 Micro, Inc. Firewire (IEEE 1394) (rev 02)
09:00.0 Ethernet controller: Broadcom Corporation NetXtreme BCM5755M Gigabit Ethernet PCI Express (rev 02)
0c:00.0 Network controller: Broadcom Corporation BCM94311MCG wlan mini-PCI (rev 01)

以下省略了,只是写一下查看这些信息的命令
[ 电池信息 ]
$ less /proc/acpi/battery/BAT0/info
[ CPU 信息 ]
$ less /proc/cpuinfo
[ 内存信息 ]
$ less /proc/meminfo
[ 内核消息 ]
$ dmesg
[ 加载的内核模块 ]
$ lsmod
[ X.org 设置文件(显示及输入设置)]
$ less /etc/X11/xorg.conf

5. 参考文章

* HARDWARE Dell Latitude D630
* My Ubuntu Installation
* Ubuntu on my Dell Latitude D630

在双系统环境中使用Windows字体美化Linux中文字体

安装完 Linux 操作系统的中文支持后,看到那些难看的字体是不是很不爽,下面这个脚本就帮助你使用 Windows 字体来自动美化 Linux 中文字体。

下面的脚本使用 windows 自带字体美化 Linux 字体,主要是将软件中文字体使用宋体,终端使用黑体替换。脚本源程序可以在 http://share.solrex.org/scripts/install_win_CN_fonts_to_linux.sh 下载到。

首先确保 windows 系统所在分区被挂载到 /media 目录下将以下内容保存为脚本文件:install_win_CN_fonts_to_linux.sh

#!/bin/bash
check_answer()
{
    case $1 in
        y|Y|Yes|yes|YES)
            return 0;
            ;;
        n|N|No|no|NO)
            return 1;
            ;;
        *) echo "Answer either yes or no, default is yes"
            return 2
            ;;
    esac
}

LIN_FONTS_DIR=/usr/share/fonts/zh_CN/TrueType
LANG_SEL_FILE=/etc/fonts/language-selector.conf
SEARCH_DIR=/media

echo -n "This script is for installing Windows Chinese fonts to Linux on a dual-OS-installed computer. And the writer doesn't promise it will work on your system. Do you want to continue?(y/n)[y]:"
read ANS_STR
: ${ANS_STR:="y"}
check_answer $ANS_STR
ANS=$?
if [ $ANS -ne 0 ]; then
    echo "Exit."
    exit
fi

echo -n "There might be license problems, i.e. you have no permission to use Windows fonts in other program except Windows OS. Do you want to continue?(y/n)[y]:"
read ANS_STR
: ${ANS_STR:="y"}
check_answer $ANS_STR
ANS=$?
if [ $ANS -ne 0 ]; then
    echo "Exit."
    exit
fi

echo -n "You run this script with root account or "sudo" command?(y/n)[y]:"
read ANS_STR
: ${ANS_STR:="y"}
check_answer $ANS_STR
ANS=$?
if [ $ANS -ne 0 ]; then
    echo "Exit."
    exit
fi

echo -n "You mounted Windows System partation "C:\" to /media directory?(y/n)[y]:"
read ANS_STR
: ${ANS_STR:="y"}
check_answer $ANS_STR
ANS=$?
if [ $ANS -ne 0 ]; then
    echo "Exit."
    exit
fi

echo "Searching for windows's fonts directory..."
echo "That may take a few minutes, please wait."
WIN_FONTS_DIR=`echo $(find $SEARCH_DIR -name simsun.ttc -type f) | sed s/simsun.ttc//g`
if [ -d $WIN_FONTS_DIR ]; then
    while true; do
        echo "Windows fonts dir found! Your windows fonts directory is: "
        echo -n ""$WIN_FONTS_DIR" Is it right?(y/n)[y]:"
        read ANS_STR
        : ${ANS_STR:="y"}
        check_answer $ANS_STR
        ANS=$?
        if [ $ANS -eq 0 ]; then
            break
        elif [ $ANS -eq 1 ]; then 
            echo "Please enter path to your windows fonts dir?"
            read ANS_STR
            if [ -d $ANS_STR ]; then
                WIN_FONTS_DIR=$ANS_STR
                break
            else
                echo "Your input is not a dir. Exit."
                exit
            fi
        else
            echo "Unrecognized input."
        fi
    done
else
    echo "Can not find windows fonts directory. "
    echo -n "Please enter path to your windows fonts dir:"
    read ANS_STR
    if [ -d $ANS_STR ]; then
        WIN_FONTS_DIR=$ANS_STR
    else
        echo "Your input is not a dir. Exit."
        exit
    fi
fi

echo "Entering $WIN_FONTS_DIR"
cd $WIN_FONTS_DIR

echo "Creating Linux fonts directory: $LIN_FONTS_DIR..."
mkdir -p $LIN_FONTS_DIR
if [ $? -ne 0 ]; then
    echo "Creating Linux fonts dir failed. Exit."
    exit
fi

echo "Copying windows fonts to linux fonts dir... sim*|tahoma|tohomabd.ttf"
cp sim* SimSun18030.ttc tahoma.ttf tahomabd.ttf $LIN_FONTS_DIR
if [ $? -ne 0 ]; then
    echo "Copying windows fonts to linux fonts dir failed. Exit."
    exit
fi

echo "Changing font files' access permissions.."
chmod 644 $LIN_FONTS_DIR/*

echo "Entering $LIN_FONTS_DIR"
cd $LIN_FONTS_DIR

echo "Creating an index of scalable font files in $LIN_FONTS_DIR for X..."
mkfontscale
if [ $? -ne 0 ]; then
    echo "Creating an index of scalable font files for X failed. Exit."
    exit
fi

echo "Creating an index of X font files in $LIN_FONTS_DIR"
mkfontdir
if [ $? -ne 0 ]; then
    echo "Creating an index of X font files in $LIN_FONTS_DIR failed. Exit."
    exit
fi

echo "Creating an index of FreeType font files in $LIN_FONTS_DIR"
fc-cache $LIN_FONTS_DIR
if [ $? -ne 0 ]; then
    echo "Creating an index of FreeType font files in $LIN_FONTS_DIR failed. Exit."
    exit
fi

echo "Backing up $LANG_SEL_FILE"
if [ -f $LANG_SEL_FILE ]; then
    cp $LANG_SEL_FILE $LANG_SEL_FILE.bak
fi

echo "Generating new $LANG_SEL_FILE... for language select"
echo '
<fontconfig>
  <alias>
    <family>serif</family>
      <prefer>
        <family>Bitstream Vera Serif</family>
        <family>SimSun</family>
        <family>DejaVu Serif</family>
        <family>AR PL ShanHeiSun Uni</family>
        <family>AR PL ZenKai Uni</family>
      </prefer>
  </alias>
  <alias>
    <family>sans-serif</family>
      <prefer>
        <family>Bitstream Vera Sans</family>
        <family>SimSun</family>
        <family>DejaVu Sans</family>
        <family>AR PL ShanHeiSun Uni</family>
        <family>AR PL ZenKai Uni</family>
      </prefer>
  </alias>
  <alias>
    <family>monospace</family>
      <prefer>
        <family>DejaVu Sans Mono</family>
        <family>Bitstream Vera Sans Mono</family>
        <family>SimHei</family>
    </prefer>
  </alias>

<match target="font" >
  <test name="family" compare="contains" >
    <string>Song</string>
    <string>Sun</string>
    <string>Kai</string>
    <string>Ming</string>
  </test>
  <test compare="more_eq" target="pattern" name="weight" >
    <int>180</int>
  </test>
  <edit mode="assign" name="embolden" >
    <bool>true</bool>
  </edit>
</match>

<match target="font" >
  <test name="family" compare="contains" >
    <string>Song</string>
    <string>Sun</string>
    <string>Kai</string>
    <string>Ming</string>
  </test>
  <edit name="globaladvance">
    <bool>false</bool>
  </edit>
  <edit name="spacing">
    <int>0</int>
  </edit>
  <edit name="hinting">
    <bool>true</bool>
  </edit>
  <edit name="autohint">
    <bool>false</bool>
  </edit>
  <edit name="antialias" mode="assign">
    <bool>true</bool>
  </edit>
  <test name="pixelsize" compare="less_eq">
    <int>18</int>
  </test>
  <edit name="antialias" mode="assign" >
    <bool>false</bool>
  </edit>
</match>

<match target="pattern">
  <test name="family">
    <string>SimSun</string>
    <string>SimSun-18030</string>
    <string>AR PL ShanHeiSun Uni</string>
    <string>AR PL New Sung</string>
    <string>MingLiU</string>
    <string>PMingLiU</string>
  </test>
  <edit binding="strong" mode="prepend" name="family">
    <string>Tahoma</string>
    <string>Verdana</string>
  </edit>
</match>

<match target="pattern">
  <test name="family">
    <string>宋体</string>
  </test>
  <edit name="family" mode="assign">
    <string>SimSun</string>
  </edit>
</match>
<match target="pattern">
  <test name="family">
    <string>新宋体</string>
  </test>
  <edit name="family" mode="assign">
    <string>SimSun</string>
  </edit>
</match>
<match target="pattern">
  <test name="family">
    <string>仿宋_GB2312</string>
  </test>
  <edit name="family" mode="assign">
    <string>FangSong_GB2312</string>
  </edit>
</match>
<match target="pattern">
  <test name="family">
    <string>楷体_GB2312</string>
  </test>
  <edit name="family" mode="assign">
    <string>KaiTi_GB2312</string>
  </edit>
</match>
<match target="pattern">
  <test name="family">
    <string>黑体</string>
  </test>
  <edit name="family" mode="assign">
    <string>SimHei</string>
  </edit>
</match>
</fontconfig> ' > $LANG_SEL_FILE
echo "Finished. Please quit your X session and relogin."
echo "If you have problems on start X(sometimes happened on Ubuntu 7.04.), please delete $LIN_FONTS_DIR and copy the backuped $LANG_SEL_FILE.bak to $LANG_SEL_FILE. Then do "fc-cache" with no options. That may work."

执行:
sudo sh ./install_win_CN_fonts_to_linux.sh

登出 Xwindow,再重新登录即可。

Red Hat 的安装和更新

Linux安装远没有想象中的艰难。很多书或文章都建议大家将Linux安装在另一块硬盘上,而且对双系统安装的安全性很怀疑,其实经过体验以后才能发现,这种担心完全是没有必要的。

首先得到Linux的拷贝,可以是光盘,也可以从网上下载到硬盘然后再从硬盘安装。我是从光盘安装的。先从BIOS里面将FIRST BOOT DEVICE设成CDROM,我的联想机子是有一个快捷键F12,直接就改过来了,不用进BIOS。将光盘插入CDROM,然后就从光盘启动LINUX的安装,开始让你选择是图形界面还是字符界面,一般选图形,直接敲回车,然后就是一些区域,语言,键盘,鼠标选项什么的,随便你怎么选,一般默认就行,除非你懂得怎样。然后就是执行安装了,安装类型一般选“定制”,因为这样对要安装的组件比较清楚。下一个屏幕就是“磁盘分区设置”,这是最重要的,一定要确保选择了“用DISK DRUID手工分区”,不然自动分区很有可能覆盖你的原有系统,不过对这个可能性我可没兴趣尝试一下。

然后就是磁盘分区表了,这里要说明一下的是,LINUX并不是像WINDOWS一样是用盘符来表示分区的。/DEV表示系统的设备表,这下面是系统的所有设备,然后如果是单硬盘,就只有一个/DEV/HDA,就是指你的硬盘,如果是双硬盘,就还会有一个/HDB,这个就不用说了。然后一般情况下,如果机子上已经装了WINDOWS,并且已经有了几个WIN下的分区,就会有/DEV/HDA1,/DEV/HDA2等等,其中/DEV/HDA1就是代表WIN的系统分区C盘,这个不重要,我们不用看它们到底有几个,我们关心的是有没有空闲空间。LINUX当然不能装在C盘上了,除非你不需要WIN系统了。

这里还要说说空闲空间是怎么来的,安装WINDOWS系统的时候人们一般把所有的空间都利用上了,所以如果不进行任何步骤就直接安装LINUX,是不会有空闲空间的。我们要给LINUX留下安装的空间,并且这个空间应该是没有主人的,就是别的系统没有使用,并且没有管理的空间。好多文章介绍,用这个工具,那个工具的来剥离出来空闲空间,这里我不否认那个方法可行,可是如果WINDOWS自己带工具,干吗去求助于别的软件呢?如果你有一个分区没有使用,并且它大概有5G的空间,恭喜你,那你就可以跳过下一句话了。如果你没有空闲的分区,但是硬盘空间足够大,你可以先将一个分区上的有用文件拷贝到另一个分区,然后从开始菜单里选“管理工具”->“计算机管理”,打开计算机管理界面,在左侧窗格里有“磁盘管理”(注意这个需要管理员权限),选择你已经移空的那个分区,选择“删除逻辑驱动器”,然后再重新分区,给LINUX留下大约最少4G的空间。这样你可以再恢复原来的那个盘,只不过空间少了4G,然后把移到别的驱动器的文件拷贝回来。当然,PATITIONAL MAGIC等等一些软件可以实现不用移动文件就分出来空间,但是我们选择的不就是笨点,但是最安全省事的办法嘛!然后,确保留给LINUX的那个空间没有格式化,没有盘符,如果有就右键选择“删除逻辑驱动器”。这样空闲空间就有了。

回到LINUX安装,如果你有空闲空间,就用鼠标选中它,然后点“新建”,在弹出的窗口里,第一格是挂载点,这里挂载点的意思相当于WINDOWS里面的盘符,你必须至少选一个“/BOOT”,这个分区将要包含操作系统的内核还有引导文件,一般设为100MB,其他不用选,点“确定”。然后还要新建一个分区,不要选择挂载点,选择文件类型为SWAP,大小建议设为内存的1.5到2倍。这个是交换分区,是用来支持虚拟内存的,必须要选。不然会影响到运行。然后再新建一个挂载点为“/”的分区,这个分区看你需要安装什么,一般打算安装全部文件的话,至少设为3G,或者说选择将剩下的空间全部使用。这个就是相当于WINDOWS里面的C盘。如果是新手的话,建议分区就设两个,因为这个和系统只有C盘一个道理,只有一个盘也好管理些。最后再确认一遍,一定要把上面三个分区建立在空闲空间里,千万别建到已用空间。

最重要的部分完了,下面还有一个设置引导装载程序,LINUX较新的版本都可以识别出来硬盘上已经存在的操作系统,但是所有WIN系统都识别成DOS,所以就要改一下,选中DOS,点编辑按钮,就可以将DOS改为WINDOWS XP。然后将其改为默认引导的操作系统,这样安装完成后,每次你电脑启动的时候就会出来一个选择界面,默认的操作系统会高亮显示,如果没有方向键选择,在5秒后就会自动进入默认操作系统。

这样整个设置基本上就完了。下面的东西一般选默认。设置根口令的时候需要你输入每次登陆的时候需要的密码,默认根用户名为:root,注意大小写。LINUX是用C语言写的,大小写不兼容。然后会有选择要安装的软件包,根据你的需要选择。然后就要开始安装了。注意,现在退出还来得及,按CTRL+ALT+DEL,不然等开始安装以后,再后悔就来不及了。安完后会提醒你要不要创建启动盘,但是现在机子谁有软驱啊,所以选择不创建。如果选择了安装X-WINDOWS,安装完后会有一个显示卡和显示器配置,选择合适的配置,然后就完成了。

如果安装过程中出现问题,你可以选择最小化安装,只需要一张盘,这样比较不容易出问题,然后安装完成后再选择安装其他软件,不过过程比较复杂,建议能一次安全就安完。

如果不满意安装的配置,可以执行一下升级。开始过程和安装是一样的,但是到了鼠标配置以后,如果你机子里面已经有LINUX,会显示你是要执行新安装或者升级。选择升级,并且选中下面“定制要升级的软件包”,这样下面你就可以选择要新安装的软件包了。