LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   How do I install a driver in linux? (https://www.linuxquestions.org/questions/linux-newbie-8/how-do-i-install-a-driver-in-linux-321162/)

jacobselvin 05-07-2005 09:48 PM

How do I install a driver in linux?
 
I'm new to linux community. I have installed Red hat linux 9 on my PC which is running on Intel Pentium IV. I couldn't find a driver for my network card. From where can I find a suitable linux driver for my Marvell Yukon Gigabit Ethernet 10/100/1000Base-T Adapter, Copper RJ 45. I think a linux driver will be a RPM file which we just have to install. Is my understanding right? Or is there any other file formats available?
Thanx,
- Jacob

teckk 05-07-2005 10:44 PM

http://www.marvell.com/products/pcconn/yukon/index.jsp
http://www.marvell.com/drivers/drive...?dId=107&pId=9

Looks like they are supporting Linux.

fancypiper 05-07-2005 10:59 PM

# Compiling/installing kernel modules
You will need to have installed:
1. The developmental packages (compiler)
2. The kernel-source code that matches your running kernel
3. The module source or install code

Check out your system and look under the hood and see if you installed the stuff you need to do the job. Open an x terminal and type in this sequence of commands to see what kernel we are running and see if you have the kernel source installed:
Code:

[fancy@tinwhistle fancy]$ su -
Password:
[root@tinwhistle root]# uname -r
2.4.20-28.7

I am running kernel version 2.4.20-28.7. Do I have the proper source code?
Code:

[root@tinwhistle root]# cd /usr/src
[root@tinwhistle src]# ls -alc
total 3
drwxr-xr-x    4 root    root          136 Jun 12 14:53 .
drwxr-xr-x  16 root    root          424 Jun  4 12:04 ..
lrwxrwxrwx    1 root    root          14 Jun  4 12:11 linux-2.4 -> linux-2.4.20-28.7
drwxr-xr-x  16 root    root          584 Jun  4 12:11 linux-2.4.20-28.7
drwxr-xr-x    7 root    root          168 Jun  4 12:08 redhat
[root@tinwhistle src]#

I do have the same kernel version source code installed in the directory /usr/src/linux-2.4.20-28.7 and there is a symbolic link named linux-2.4 pointing to it.

If you don't see something similiar to this (but in color), you will need to install the kernel source.

NOTE: I noticed that Red Hat didn't make the symbolic link /usr/src/linux that all of the INSTALL files that I have read mentioned that I need. I may as well make one now to save editing the files in the source code every time I need to compile anything concerning the kernel. So, I'll make that link just now:
Code:

[root@tinwhistle src]# ln -s linux-2.4.20-28.7 linux       
[root@tinwhistle src]# ls -alc
total 3
drwxr-xr-x    4 root    root          160 Jun 12 15:46 .
drwxr-xr-x  16 root    root          424 Jun  4 12:04 ..
lrwxrwxrwx    1 root    root          14 Jun 12 15:46 linux -> linux-2.4.20-28.7
lrwxrwxrwx    1 root    root          14 Jun  4 12:11 linux-2.4 -> linux-2.4.20-28.7
drwxr-xr-x  16 root    root          584 Jun  4 12:11 linux-2.4.20-28.7
drwxr-xr-x    7 root    root          168 Jun  4 12:08 redhat
[root@tinwhistle src]#

Ah, there it is, so that's done.

Next, did I install the compiler?
Code:

[root@tinwhistle src]# gcc -v         
Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/2.96/specs
gcc version 2.96 20000731 (Red Hat Linux 7.3 2.96-113)
[root@tinwhistle src]#

Yes, I have a compiler installed.

If you don't have those two things installed, you have to install them first off your install CD.

If they are installed, download the source and happy compiling. :tisk: Make sure you carefully read the README and INSTALL files after extracting and before compiling/installing. :study:

I have Linux installed, now how do I work install stuff like more software?
# I can't figure out what software I want and how to install/uninstall it
The table of equivalents, replacements, analogs of Windows software in Linux
# Find software here
Freshmeat
Sourceforge
rpmfind
# Guides to software management
LNAG: 4.5 Package installation and rpm package manager
Rute Guide's software explanation
You might want to check out CheckInstall to manage source code installations/uninstallation

SML 05-07-2005 11:07 PM

OPTION 1 - EASIEST
Why don't you just use a later distribution and it will be all be automatically set-up.

OPTION 2 - EASIER
Or you could upgrade your kernel that will the include the right module for the Marvell Yukon.

OPTION 3
Load in the module to your old RH9 distro.

BTW
The sk98lin module is the one you are after.

jacobselvin 05-08-2005 01:27 AM

Thank you all for your quick response.

First I tried to download the driver from marvell site. I downloaded a file called install-8_16.tar.bz2. I'm not sure how to use this file. I had never seen any file with such extension. I tried to unzip it by removing the bz2 extension and still no luck.
Next I looked at the installation instructions. It says no additional files are required. And just the linux kernal source is enough. I followed the following instructions

1. Select the menu "Network device support" and then "Ethernet(1000Mbit)"
2. Mark "Marvell Yukon Chipset / SysKonnect SK-98xx family support"
with (*)
3. Build a new kernel when the configuration of the above options is
finished.
4. Install the new kernel.
5. Reboot your system.

Here I'm not sure how to install the new kernal. I rebuilt the new kernel (using make dep) and rebooted the server. Now the card was not detected automatically. I tried to configure it manually and still it was not detecting the card. I used the System Setting > Network menu to setup.
My linux kernal version is 2.4.20-8. Will there be any use if I upgrade my kernal. If yes how can I upgrade my kernal.

fancypiper 05-08-2005 01:40 AM

The Red Hat Linux 9 documentation site should provide some help if my previous links didn't explain to your satisfaction about how to handle those files.

# Guides to software management
LNAG: 4.5 Package installation and rpm package manager. Read section 4.5.1.2
Rute Guide's software explanation

# Red Hat & Fedora links
FedoraNEWS.ORG
The Fedora HOWTO explains the different software managers.
Maximum RPM
rpmfind
Easier software management: apt4rpm
ATrpms - installation instructions
Fedora Core 1 Tips and Tricks
Fedora Core 2 Tips and Tricks
Fedora Core 3 Tips and Tricks
apt, yum, and up2date repository settings (configuration files) for Fedora Core 3
# Handling NTFS
New Technology FileSystem (NTFS) HOWTOs
Linux NTFS project

SML 05-08-2005 02:34 AM

Sounds like you rebuilt the new kernel, but did you set it up to actually have access to the new kernel image with your lilo or grub booter?

Have you tried an #lsmod to see if it is loaded?

If you upgrade your kernel (partcularly a nice fat pre-built 2.6 Fedora kernel) then the sk98lin will be already loaded in.

Refer to my first email - you chose the hardest of your options in my opinion.

jacobselvin 05-08-2005 08:35 AM

Hi,
I managed to instal the suggested driver and the NW is working fine now. I'm using Red hat linux 9 kernel version 2.4.20-8. If I want to upgrade my kernel version which version can I upgrade to. Can I upgrade to a kernal version 2.6.11-8 (which seems to be latest stable version)? Or I can only upgrade to latest 2.4.X-X? If I upgrade to 2.6.11-8 will my applications (that I installed along with RedHat 9 i.e web server, DNS, My SQL etc) have any compatibility issue?
Thanx,
- Jacob

SML 05-08-2005 08:48 AM

Not sure.

But if you follow the set-up guidelines, when you boot up you can just select any kernel image.

For example, your grub or lilo would list:
2.4.20-8
2.6.11-8
Plus any other custom kernels that you may set-up yourself.

Therefore there is no harm in trying! The worst that will happen is that it will fail and you wil have to press 'reset' and then just go back to your 2.4.20.


All times are GMT -5. The time now is 05:56 PM.