如何安装ATI/nvidia/SmartLink modem?
发表于 : 2005-04-01 10:20
Install the ATI (fglrx) Driver if any of these are true:
*
You know you own a "Radeon" card
*
When you first turn the computer on an ATI logo appears in the top left corner
*
You know your card model begins with "7", "8", "9", or "X".
*
cat /proc/pci reveals a card with "ATI" in it
Install the NVIDIA Driver if any of these are true:
*
You know you own a "Ge-Force" or a "Quadro" graphics card.
*
When you first turn the computer on it says something about NVIDIA in the top left of the screen.
*
You know your card model begins with "4", "FX", or "6".
*
cat /proc/pci reveals a card with "NVIDIA" in it
ATI (fglrx) Graphics Card
Note: Currently, ATI Drivers for AMD64 are only available in Hoary
If you use Warty (Ubuntu version 4.10)
1.
Install the following package for Warty:
sudo apt-get install fglrx-driver
2.
echo fglrx | sudo tee -a /etc/modules
*
This command won't have any effect until you reboot. To load the kernel module immediately, run sudo depmod -a ; sudo modprobe fglrx, but this will only work if you have already rebooted since upgrading the kernel. If it doesn't work, perform the next step (below) and then reboot.
3.
Edit /etc/X11/XF86Config-4 and change "ati" to "fglrx", perhaps with a command like:
*
sudo sed -i -e 's/"ati"/"fglrx"/'/etc/X11/XF86Config-4. Alternatively, just use your favourite text editor, or use sudo dpkg-reconfigure xserver-xfree86 and select "fglrx" instead of "ati".
For Hoary (Ubuntu version 5.04)
1.
Install the xorg-driver-fglrx package:
sudo apt-get install xorg-driver-fglrx
2.
echo fglrx | sudo tee -a /etc/modules
*
This command won't have any effect until you reboot. To load the kernel module immediately, run sudo depmod -a ; sudo modprobe fglrx, but this will only work if you have already rebooted since upgrading the kernel. If it doesn't work, perform the next step (below) and then reboot.
3.
Edit /etc/X11/xorg.conf and change "ati" to "fglrx", perhaps with a command like: sudo sed -i -e 's/"ati"/"fglrx"/' /etc/X11/xorg.conf. Alternatively, just use your favourite text editor, or use sudo dpkg-reconfigure xserver-xorg and select "fglrx" instead of "ati".
Notes
Note (optional): If you are going to compile 3d applications, you will want to install the fglrx-driver-dev package
Note (optional): You might want to install the fglrx-control package, which provides a control panel to configure graphics card options such as dual-head display (two monitors).
One also needs to move the nvidia module (/lib/modules/kernel_version/kernel/drivers/video/nvidia.ko) from the directory. Something was loading it and it was taking over the AGP port. This condition can be see by running fireglcontrol and seeing Mesa Indirect as the OpenGL? driver instead of the ATI driver. This results in a major reduction in speed when going throught the MESA drivers. (SL)
On my NFORCE2 board, I had to modify my /etc/X11/XF86config-4 to finally get rid of the '..MESA...' in the OpenGL? section of fireglcontrol. In the device section of the grafic card I added the following line:
*
Option "UseInternalAGPGART?" "no"
This option does not appear to work with other boards.
The needed nvidia_agp module was started automatically (I think hwscan is starting it). Use 'lsmod | grep "nvidia"' to check if it is there. (TAK)
EXTREMELY IMPORTANT : REBOOT!! (I had a hell of a time cursing my PC, got frustrated, turned it off, and the next day it worked perfectly after booting up)
NVIDIA Graphics Card
Note: requires linux-restricted modules >= 2.6.8.1.1-3
1.
sudo apt-get install nvidia-glx
2.
sudo nvidia-glx-config enable
Note: If you wish to use these drivers and run the XMMS music player, you should be aware of this bug
Note: You can get around this bug by installing libmik.
Note (optional): If you are going to compile 3d applications, you will want to install the nvidia-glx-dev package
Note (optional): the nvidia-settings package provides a control panel to configure graphics card options such as gamma correction.
Notes
Edit: That script worked for me perfectly, but keep sure to have the right version of linux-restricted-modules installed (it must match the version of the running kernel).
Edit: The above script worked perfectly on a fresh Warty install, from ISO dated Sep 15. No additional changes needed.(OM)
Edit: Here are notes on how I (WW) got the nvidia drivers to work.
1.
After I installed Ubuntu, the package linux-restricted-modules was already installed. I have version 2.6.8.1.0-2 installed, which does not appear to be >= 2.6.8.1.1-3, but it works.
2.
As above, run the command sudo apt-get install nvidia-glx (or use Synaptic to install it). This installs the "nvidia" driver.
3.
Run the command sudo dpkg-reconfigure xserver-xfree86. Select the nvidia driver in the first screen. Go through the rest of the screens, keeping all the defaults, until you get to the modules. Disable GLCore?. Also, the glx module should be enabled (and it probably already is). Finish the configuration by again choosing all the defaults. You have now updated /etc/X11/XF86Config-4.
4.
As root (i.e. with sudo), use your favorite editor to edit the file /etc/modules. Add a line that contains just the word "nvidia" (without the quotes). This will cause the nvidia module to be loaded the next time you reboot.
5.
To load the module now, enter the command sudo modprobe nvidia.
6.
Now all you have to do is restart X so that the changes take effect. (It might be a good idea to exit any other applications that you have running.) I could swear that I did this by just hitting ctrl-alt-backspace. This should stop X, then you'll get the nvidia splash screen, and then a new login screen. On the IRC channel, someone else said you must enter the command sudo /etc/init.d/gdm stop, and then sudo /etc/init.d/gdm start in order for the changes to take effect.
I (WW) think that's it. Note that I didn't use nvidia-glx-config, which might automate some of the steps that I listed.
Edit: I tried to follow the above steps and found that some are unnecessary or don't work. Here's what I did:
1. Run the command 'sudo apt-get install nvidia-glx'.
2. Run the command 'sudo dpkg-reconfigure xserver-xfree86'. Select the nvidia driver in the first screen. (The first time I did this, I didn't see the nvidia option. But I was tired. If it's really not there, run the command 'sudo modprobe nvidia' and try again.) Go through the rest of the screens, keeping all the defaults, until you get to the modules. Disable GLCore? and dri. glx should be enabled. (Every other site I have read says dri should NOT be enabled, but I followed WW's directions above and it seems to work.) Finish the configuration by again choosing all the defaults.
3. Edit /etc/modules, and add 'nvidia' (without the quotes) on its own line.
4. Run the command 'sudo modprobe nvidia' if you haven't already.
5. Hit ctrl-alt-backspace to restart the X server. You should see the nvidia splash screen.
SmartLink? modem
Note:
This modem is very common on laptop motherboards. It looks something like this when you type "lspci" in a terminal:
0000:00:1f.6 Modem: Intel Corp. 82801DB (ICH4) AC'97 Modem Controller (rev 03)
Modifying your sources
In order to install this driver (and other non-free drivers that Ubuntu does not support), you will need to edit the file
/etc/apt/sources.list
with your favourite editor under "root" and activate the "multiverse" repository by changing the lines that look like this:
deb http://archive.ubuntu.com/ubuntu/ warty main restricted universe
deb-src http://archive.ubuntu.com/ubuntu/ warty main restricted universe
to look like this:
deb http://archive.ubuntu.com/ubuntu/ warty main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ warty main restricted universe multiverse
Notes
1.
Unlike the above drivers, this driver is provided by Ubuntu in the multiverse repository and unlike drivers from the restricted repository is basically untouched by the Ubuntu development team. Hence you have to do a bit more work to get this one to go. And if you have trouble with it, the fault lies more with Debian than with Ubuntu, but is somewhat up in the air, since noone has the code.
2.
Every time you update your operating system core (called "the kernel"), you're going to have to run through the "Compiling the driver" procedure below again.
Preliminaries
These are steps you will only have to run through the first time you build this driver, we're just making sure you have all the installed packages you need. If any of these packages are already installed, that's fine, but if not, use Synaptic, aptitude or apt-get to install them.
Make sure you have the most up-to-date kernel available unless there's some reason why you want to run a specific kernel. Install the following package:
1.
linux-ARCH (where ARCH is one of 686, 686-smp, k7 or k7-smp if you use Intel, powerpc for PPC...)
Also, you're going to be compiling this driver, and Ubuntu doesn't install the necessary programs for you to do this by default. So first we need to install several packages:
1.
build-essential
2.
linux-headers-2.6-ARCH
3.
fakeroot
These will pull in some other packages too.
You also need to install the source of the SmartLink? driver itself:
1.
sl-modem-daemon
2.
sl-modem-source
You can install all packages listed above at the same time.
Compiling the driver
Run the following steps in a console. Note that whatever directory you're working in will be filled with files. It doesn't matter exactly where this is done as long as you have write access in the directory.
1.
tar -xjf /usr/src/sl-modem.tar.bz2 [this command unpacks all the files we will use into the current directory]?
2.
cd modules/sl-modem/debian [change to a particular directory where the instructions for building the module are, because we need to fix them to work with Ubuntu rather than Debian
3.
Edit the control.modules.in file in this directory. In this file, there is a line reading:
*
Depends: kernel-image-_KVERS_
*
Change this line to read:
o
Depends: linux-image-_KVERS_
1.
cd ..
2.
fakeroot debian/rules kdist KVERS=`uname -r` KSRC=/usr/src/linux-headers-`uname -r` [this does the actual building of the driver against the current running kernel, it has a lot of output]?
3.
cd ..
4.
sudo dpkg -i sl-modem-modules-*.deb [this sometimes freezes, canceling it with Ctrl+C and trying again will eventually work]?
Getting the modem to work
This driver seems rather finicky. Basically, if it works, a file called /dev/ttySL0 will exist. If it doesn't work, running sudo /etc/init.d/sl-modem-daemon restart may help, as might running modprobe slamr, but it seems somewhat random. A reboot may help too.
http://www.ubuntulinux.org/wiki/BinaryDriverHowto
*
You know you own a "Radeon" card
*
When you first turn the computer on an ATI logo appears in the top left corner
*
You know your card model begins with "7", "8", "9", or "X".
*
cat /proc/pci reveals a card with "ATI" in it
Install the NVIDIA Driver if any of these are true:
*
You know you own a "Ge-Force" or a "Quadro" graphics card.
*
When you first turn the computer on it says something about NVIDIA in the top left of the screen.
*
You know your card model begins with "4", "FX", or "6".
*
cat /proc/pci reveals a card with "NVIDIA" in it
ATI (fglrx) Graphics Card
Note: Currently, ATI Drivers for AMD64 are only available in Hoary
If you use Warty (Ubuntu version 4.10)
1.
Install the following package for Warty:
sudo apt-get install fglrx-driver
2.
echo fglrx | sudo tee -a /etc/modules
*
This command won't have any effect until you reboot. To load the kernel module immediately, run sudo depmod -a ; sudo modprobe fglrx, but this will only work if you have already rebooted since upgrading the kernel. If it doesn't work, perform the next step (below) and then reboot.
3.
Edit /etc/X11/XF86Config-4 and change "ati" to "fglrx", perhaps with a command like:
*
sudo sed -i -e 's/"ati"/"fglrx"/'/etc/X11/XF86Config-4. Alternatively, just use your favourite text editor, or use sudo dpkg-reconfigure xserver-xfree86 and select "fglrx" instead of "ati".
For Hoary (Ubuntu version 5.04)
1.
Install the xorg-driver-fglrx package:
sudo apt-get install xorg-driver-fglrx
2.
echo fglrx | sudo tee -a /etc/modules
*
This command won't have any effect until you reboot. To load the kernel module immediately, run sudo depmod -a ; sudo modprobe fglrx, but this will only work if you have already rebooted since upgrading the kernel. If it doesn't work, perform the next step (below) and then reboot.
3.
Edit /etc/X11/xorg.conf and change "ati" to "fglrx", perhaps with a command like: sudo sed -i -e 's/"ati"/"fglrx"/' /etc/X11/xorg.conf. Alternatively, just use your favourite text editor, or use sudo dpkg-reconfigure xserver-xorg and select "fglrx" instead of "ati".
Notes
Note (optional): If you are going to compile 3d applications, you will want to install the fglrx-driver-dev package
Note (optional): You might want to install the fglrx-control package, which provides a control panel to configure graphics card options such as dual-head display (two monitors).
One also needs to move the nvidia module (/lib/modules/kernel_version/kernel/drivers/video/nvidia.ko) from the directory. Something was loading it and it was taking over the AGP port. This condition can be see by running fireglcontrol and seeing Mesa Indirect as the OpenGL? driver instead of the ATI driver. This results in a major reduction in speed when going throught the MESA drivers. (SL)
On my NFORCE2 board, I had to modify my /etc/X11/XF86config-4 to finally get rid of the '..MESA...' in the OpenGL? section of fireglcontrol. In the device section of the grafic card I added the following line:
*
Option "UseInternalAGPGART?" "no"
This option does not appear to work with other boards.
The needed nvidia_agp module was started automatically (I think hwscan is starting it). Use 'lsmod | grep "nvidia"' to check if it is there. (TAK)
EXTREMELY IMPORTANT : REBOOT!! (I had a hell of a time cursing my PC, got frustrated, turned it off, and the next day it worked perfectly after booting up)
NVIDIA Graphics Card
Note: requires linux-restricted modules >= 2.6.8.1.1-3
1.
sudo apt-get install nvidia-glx
2.
sudo nvidia-glx-config enable
Note: If you wish to use these drivers and run the XMMS music player, you should be aware of this bug
Note: You can get around this bug by installing libmik.
Note (optional): If you are going to compile 3d applications, you will want to install the nvidia-glx-dev package
Note (optional): the nvidia-settings package provides a control panel to configure graphics card options such as gamma correction.
Notes
Edit: That script worked for me perfectly, but keep sure to have the right version of linux-restricted-modules installed (it must match the version of the running kernel).
Edit: The above script worked perfectly on a fresh Warty install, from ISO dated Sep 15. No additional changes needed.(OM)
Edit: Here are notes on how I (WW) got the nvidia drivers to work.
1.
After I installed Ubuntu, the package linux-restricted-modules was already installed. I have version 2.6.8.1.0-2 installed, which does not appear to be >= 2.6.8.1.1-3, but it works.
2.
As above, run the command sudo apt-get install nvidia-glx (or use Synaptic to install it). This installs the "nvidia" driver.
3.
Run the command sudo dpkg-reconfigure xserver-xfree86. Select the nvidia driver in the first screen. Go through the rest of the screens, keeping all the defaults, until you get to the modules. Disable GLCore?. Also, the glx module should be enabled (and it probably already is). Finish the configuration by again choosing all the defaults. You have now updated /etc/X11/XF86Config-4.
4.
As root (i.e. with sudo), use your favorite editor to edit the file /etc/modules. Add a line that contains just the word "nvidia" (without the quotes). This will cause the nvidia module to be loaded the next time you reboot.
5.
To load the module now, enter the command sudo modprobe nvidia.
6.
Now all you have to do is restart X so that the changes take effect. (It might be a good idea to exit any other applications that you have running.) I could swear that I did this by just hitting ctrl-alt-backspace. This should stop X, then you'll get the nvidia splash screen, and then a new login screen. On the IRC channel, someone else said you must enter the command sudo /etc/init.d/gdm stop, and then sudo /etc/init.d/gdm start in order for the changes to take effect.
I (WW) think that's it. Note that I didn't use nvidia-glx-config, which might automate some of the steps that I listed.
Edit: I tried to follow the above steps and found that some are unnecessary or don't work. Here's what I did:
1. Run the command 'sudo apt-get install nvidia-glx'.
2. Run the command 'sudo dpkg-reconfigure xserver-xfree86'. Select the nvidia driver in the first screen. (The first time I did this, I didn't see the nvidia option. But I was tired. If it's really not there, run the command 'sudo modprobe nvidia' and try again.) Go through the rest of the screens, keeping all the defaults, until you get to the modules. Disable GLCore? and dri. glx should be enabled. (Every other site I have read says dri should NOT be enabled, but I followed WW's directions above and it seems to work.) Finish the configuration by again choosing all the defaults.
3. Edit /etc/modules, and add 'nvidia' (without the quotes) on its own line.
4. Run the command 'sudo modprobe nvidia' if you haven't already.
5. Hit ctrl-alt-backspace to restart the X server. You should see the nvidia splash screen.
SmartLink? modem
Note:
This modem is very common on laptop motherboards. It looks something like this when you type "lspci" in a terminal:
0000:00:1f.6 Modem: Intel Corp. 82801DB (ICH4) AC'97 Modem Controller (rev 03)
Modifying your sources
In order to install this driver (and other non-free drivers that Ubuntu does not support), you will need to edit the file
/etc/apt/sources.list
with your favourite editor under "root" and activate the "multiverse" repository by changing the lines that look like this:
deb http://archive.ubuntu.com/ubuntu/ warty main restricted universe
deb-src http://archive.ubuntu.com/ubuntu/ warty main restricted universe
to look like this:
deb http://archive.ubuntu.com/ubuntu/ warty main restricted universe multiverse
deb-src http://archive.ubuntu.com/ubuntu/ warty main restricted universe multiverse
Notes
1.
Unlike the above drivers, this driver is provided by Ubuntu in the multiverse repository and unlike drivers from the restricted repository is basically untouched by the Ubuntu development team. Hence you have to do a bit more work to get this one to go. And if you have trouble with it, the fault lies more with Debian than with Ubuntu, but is somewhat up in the air, since noone has the code.
2.
Every time you update your operating system core (called "the kernel"), you're going to have to run through the "Compiling the driver" procedure below again.
Preliminaries
These are steps you will only have to run through the first time you build this driver, we're just making sure you have all the installed packages you need. If any of these packages are already installed, that's fine, but if not, use Synaptic, aptitude or apt-get to install them.
Make sure you have the most up-to-date kernel available unless there's some reason why you want to run a specific kernel. Install the following package:
1.
linux-ARCH (where ARCH is one of 686, 686-smp, k7 or k7-smp if you use Intel, powerpc for PPC...)
Also, you're going to be compiling this driver, and Ubuntu doesn't install the necessary programs for you to do this by default. So first we need to install several packages:
1.
build-essential
2.
linux-headers-2.6-ARCH
3.
fakeroot
These will pull in some other packages too.
You also need to install the source of the SmartLink? driver itself:
1.
sl-modem-daemon
2.
sl-modem-source
You can install all packages listed above at the same time.
Compiling the driver
Run the following steps in a console. Note that whatever directory you're working in will be filled with files. It doesn't matter exactly where this is done as long as you have write access in the directory.
1.
tar -xjf /usr/src/sl-modem.tar.bz2 [this command unpacks all the files we will use into the current directory]?
2.
cd modules/sl-modem/debian [change to a particular directory where the instructions for building the module are, because we need to fix them to work with Ubuntu rather than Debian
3.
Edit the control.modules.in file in this directory. In this file, there is a line reading:
*
Depends: kernel-image-_KVERS_
*
Change this line to read:
o
Depends: linux-image-_KVERS_
1.
cd ..
2.
fakeroot debian/rules kdist KVERS=`uname -r` KSRC=/usr/src/linux-headers-`uname -r` [this does the actual building of the driver against the current running kernel, it has a lot of output]?
3.
cd ..
4.
sudo dpkg -i sl-modem-modules-*.deb [this sometimes freezes, canceling it with Ctrl+C and trying again will eventually work]?
Getting the modem to work
This driver seems rather finicky. Basically, if it works, a file called /dev/ttySL0 will exist. If it doesn't work, running sudo /etc/init.d/sl-modem-daemon restart may help, as might running modprobe slamr, but it seems somewhat random. A reboot may help too.
http://www.ubuntulinux.org/wiki/BinaryDriverHowto