环境: IBM T60  &  ubuntu 6.06 update to 6.10

T60-D63
Core2 Duo
T7200-2.0G
Intel
945PM
DDR2 667
1G×1
100G
5400转
ATI
X1400-128M

刚开始 ubuntu6.06 装了估计半个多月没搞定,后来才知道好像要升级 Xorg 版本,于是索性升级成了 ubuntu6.10
安装相当顺利,过程如下( source.list 见文章末尾)

升级6.06到6.10 --> gksu "update-manager -c"


安装 ati 驱动和该死的 beryl
wget http://download.tuxfamily.org/3v1deb/EDD1E155.gpg -O- | sudo apt-key add -
wget http://ubuntu.beryl-project.org/root@lupine.me.uk.gpg -O- | sudo apt-key add -
sudo apt-get update
sudo apt-get -y --force-yes install xorg-driver-fglrx fglrx-control
sudo depmod -a
sudo aticonfig --initial
sudo aticonfig --overlay-type=Xv
sudo apt-get -y --force-yes install xserver-xgl
sudo apt-get -y --force-yes install beryl emerald-themes

sudo gedit /etc/X11/xorg.conf
文件末尾添加如下内容
Section "Extensions"
        Option  "Composite" "0"
EndSection
Section "ServerFlags"
        Option  "AIGLX" "off"
EndSection

sudo reboot

检查 fglrxinfo ,我的输出如下:
$ fglrxinfo
Xlib:  extension "XFree86-DRI" missing on display ":1.0".
display: :0.0  screen: 0
OpenGL vendor string: ATI Technologies Inc.
OpenGL renderer string: ATI Mobility Radeon X1400 Generic
OpenGL version string: 2.0.6011 (8.28.8)

sudo gedit /usr/share/bin/startxgl.sh
添加如下内容:
#!/bin/sh
Xgl -fullscreen :1 -ac -br -accel glx:pbuffer -accel xv:pbuffer &
sleep 4
export DISPLAY=:1
exec /etc/X11/Xsession

sudo chmod a+x /usr/local/bin/startxgl.sh

sudo gedit /usr/share/xsessions/xgl.desktop
添加如下内容:
[Desktop Entry]
Encoding=UTF-8
Name=Xgl
Exec=/usr/local/bin/startxgl.sh
Icon=
Type=Application

重启, session 选择 xgl ,登录,执行 beryl-manager

装完之后发现 supper 键失效,选择系统 –> 首选项 –> 键盘 –> 布局 –> 键盘型号 " 通用 104 键电脑 " 解决


----------------------------------------------------------- source.list-----------------------------------------------------

deb cdrom:[Ubuntu 6.06.1 _Dapper Drake_ - Release i386 (20060806.1)]/ dapper main restricted
deb http://cn.archive.ubuntu.com/ubuntu/
edgy main restricted
deb-src http://cn.archive.ubuntu.com/ubuntu/
edgy main restricted

## Major bug fix updates produced after the final release of the
## distribution.
deb http://cn.archive.ubuntu.com/ubuntu/
edgy-updates main restricted
deb-src http://cn.archive.ubuntu.com/ubuntu/
edgy-updates main restricted

## Uncomment the following two lines to add software from the 'universe'
## repository.
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## universe WILL NOT receive any review or updates from the Ubuntu security
## team.
# deb http://cn.archive.ubuntu.com/ubuntu/
dapper universe
# deb-src http://cn.archive.ubuntu.com/ubuntu/
dapper universe

## Uncomment the following two lines to add software from the 'backports'
## repository.
## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
# deb http://cn.archive.ubuntu.com/ubuntu/
dapper-backports main restricted universe multiverse
# deb-src http://cn.archive.ubuntu.com/ubuntu/
dapper-backports main restricted universe multiverse

deb http://security.ubuntu.com/ubuntu edgy-security main restricted
deb-src http://security.ubuntu.com/ubuntu
edgy-security main restricted
# deb http://security.ubuntu.com/ubuntu
dapper-security universe
# deb-src http://security.ubuntu.com/ubuntu
dapper-security universe


################# add by 009 ######################
deb http://download.tuxfamily.org/3v1deb
edgy beryl-svn
deb-src http://download.tuxfamily.org/3v1deb
edgy beryl-svn

deb http://ubuntu.beryl-project.org/ edgy main
 
----------------------------------------------------------- xorg.conf ---------------------------------------------------------------

# /etc/X11/xorg.conf (xorg X Window System server configuration file)
#
# This file was generated by dexconf, the Debian X Configuration tool, using
# values from the debconf database.
#
# Edit this file with caution, and see the /etc/X11/xorg.conf manual page.
# (Type "man /etc/X11/xorg.conf" at the shell prompt.)
#
# This file is automatically updated on xserver-xorg package upgrades *only*
# if it has not been modified since the last upgrade of the xserver-xorg
# package.
#
# If you have edited this file but would like it to be automatically updated
# again, run the following command:
#   sudo dpkg-reconfigure -phigh xserver-xorg

Section "ServerLayout"
    Identifier     "Default Layout"
    Screen      0  "aticonfig-Screen[0]" 0 0
    InputDevice    "Generic Keyboard"
    InputDevice    "Configured Mouse"
    InputDevice    "stylus" "SendCoreEvents"
    InputDevice    "cursor" "SendCoreEvents"
    InputDevice    "eraser" "SendCoreEvents"
    InputDevice    "Synaptics Touchpad"
EndSection

Section "Files"

    # path to defoma fonts
    FontPath "/usr/share/fonts/zh_CN/TrueType"
    FontPath     "/usr/share/X11/fonts/misc"
    FontPath     "/usr/share/X11/fonts/cyrillic"
    FontPath     "/usr/share/X11/fonts/100dpi/:unscaled"
    FontPath     "/usr/share/X11/fonts/75dpi/:unscaled"
    FontPath     "/usr/share/X11/fonts/Type1"
    FontPath     "/usr/share/X11/fonts/100dpi"
    FontPath     "/usr/share/X11/fonts/75dpi"
    FontPath     "/usr/share/fonts/X11/misc"
    FontPath     "/var/lib/defoma/x-ttcidfont-conf.d/dirs/TrueType"
EndSection

Section "Module"
    Load  "bitmap"
    Load  "ddc"
    Load  "dri"
    Load  "extmod"
    Load  "freetype"
    Load  "glx"
    Load  "int10"
    Load  "type1"
    Load  "vbe"
EndSection

Section "InputDevice"
    Identifier  "Generic Keyboard"
    Driver      "kbd"
    Option        "CoreKeyboard"
    Option        "XkbRules" "xorg"
    Option        "XkbModel" "pc104"
    Option        "XkbLayout" "us"
EndSection

Section "InputDevice"
    Identifier  "Configured Mouse"
    Driver      "mouse"
    Option        "CorePointer"
    Option        "Device" "/dev/input/mice"
    Option        "Protocol" "ExplorerPS/2"
    Option        "ZAxisMapping" "4 5"
    Option        "Emulate3Buttons" "true"
EndSection

Section "InputDevice"
    Identifier  "Synaptics Touchpad"
    Driver      "synaptics"
    Option        "SendCoreEvents" "true"
    Option        "Device" "/dev/psaux"
    Option        "Protocol" "auto-dev"
    Option        "HorizScrollDelta" "0"
EndSection

Section "InputDevice"

                                                      # /dev/input/event
                                                      # for USB
    Identifier  "stylus"
    Driver      "wacom"
    Option        "Device" "/dev/wacom"          # Change to
    Option        "Type" "stylus"
    Option        "ForceDevice" "ISDV4"               # Tablet PC ONLY
EndSection

Section "InputDevice"

                                                      # /dev/input/event
                                                      # for USB
    Identifier  "eraser"
    Driver      "wacom"
    Option        "Device" "/dev/wacom"          # Change to
    Option        "Type" "eraser"
    Option        "ForceDevice" "ISDV4"               # Tablet PC ONLY
EndSection

Section "InputDevice"

                                                      # /dev/input/event
                                                      # for USB
    Identifier  "cursor"
    Driver      "wacom"
    Option        "Device" "/dev/wacom"          # Change to
    Option        "Type" "cursor"
    Option        "ForceDevice" "ISDV4"               # Tablet PC ONLY
EndSection

Section "Monitor"
    Identifier   "aticonfig-Monitor[0]"
    Option        "VendorName" "ATI Proprietary Driver"
    Option        "ModelName" "Generic Autodetecting Monitor"
    Option        "DPMS" "true"
EndSection

Section "Device"
    Identifier  "aticonfig-Device[0]"
    Driver      "fglrx"
    Option        "VideoOverlay" "on"
    Option        "OpenGLOverlay" "off"
EndSection

Section "Screen"
    Identifier "aticonfig-Screen[0]"
    Device     "aticonfig-Device[0]"
    Monitor    "aticonfig-Monitor[0]"
    DefaultDepth     24
    SubSection "Display"
        Viewport   0 0
        Depth     24
    EndSubSection
EndSection

Section "DRI"
    Mode         0666
EndSection

Section "Extensions"
        Option  "Composite" "0"
EndSection

Section "ServerFlags"
        Option  "AIGLX" "off"
EndSection


---------------------------------- 以下参考 http://www.osxcn.com/ubuntu/ati-xgl-beryl.html -------------------------------------

因为Ubuntu 6.10默认没有安装gtk2-engines-pixbuf,
导致在“主题”里面选择控件和图标没有反应。

解决办法:
sudo apt-get install gtk2-engines-pixbuf

找到:
系统-首选项-会话-启动程序
添加:
gnome-settings-daemon

sudo ln -s ~/.themes/* /usr/share/themes
sudo ln -s ~/.icons/* /usr/share/icons

进入Xgl,没有重启和关机选项。
解决办法,在sudo gedit /usr/local/bin/startxgl.sh中加入:
cookie="$(xauth -i nextract - :0 | cut -d ' ' -f 9)"
xauth -i add :1 . "$cookie"

最终如下:
#!/bin/sh
Xgl -fullscreen :1 -ac -br -accel glx:pbuffer -accel xv:pbuffer &
sleep 4
export DISPLAY=:1
cookie="$(xauth -i nextract - :0 | cut -d ' ' -f 9)"
xauth -i add :1 . "$cookie"
exec /etc/X11/Xsession