LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-15-2010, 10:15 AM   #1
xwishmasterx
Member
 
Registered: Jul 2008
Posts: 30

Rep: Reputation: 0
Exclamation Not loading drivers (insmod ....*ko)


Hi

I am trying to make a device load some drivers with the "insmod" command
but somehow it doesn't seem to work.

I do not have any direct connection to my device, so I am doing this with a flash stick when the device boots.

my code is:
Code:
insmod /tmp/mnt/sda1/r8192s_usb.ko
is there something wrong with this command, or more likely wrong path?

other alternatives?
 
Old 11-15-2010, 10:43 AM   #2
camorri
LQ Guru
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 14.1, 14.2
Posts: 5,090

Rep: Reputation: 483Reputation: 483Reputation: 483Reputation: 483Reputation: 483
Loading modules is a privileged command, you need to be root to load a module.

insmod is the old version command to load a module. modprobe is the newer one. I'm not sure I understand how you are trying to accomplish this task. Usually you open a root konsole and 'modprobe nameofmodule'. If you get no errors, then it worked. Errors indicate something is wrong.

Once you know the module(s) you need loaded, then there are file on each distro to load the modules at boot time. The file names may be different. If you need help with that, then post the version and release of the distro you are running.

You said you do not have a direct connection to the device. Can you ssh into it?

Last edited by camorri; 11-15-2010 at 10:45 AM.
 
Old 11-15-2010, 10:46 AM   #3
xwishmasterx
Member
 
Registered: Jul 2008
Posts: 30

Original Poster
Rep: Reputation: 0
First of all, I'm not even considering myself a "linux-beginner", I'm not that skilled :/

Second, the command line is located in a file that is loaded on boot.

third, I have no idea what "distro" means..lol
 
Old 11-15-2010, 01:51 PM   #4
camorri
LQ Guru
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 14.1, 14.2
Posts: 5,090

Rep: Reputation: 483Reputation: 483Reputation: 483Reputation: 483Reputation: 483
Quote:
Second, the command line is located in a file that is loaded on boot.
Hmmm... Mandriva uses a file called /etc/modprobe.preload to load drivers. It has to be edited as root to add commands. I load some modules there on my system. Is this what you are talking about, or some similar file??? The root user owns this file.

The command has to be run as a root user( in a konsole), or it will not work. What makes sense is to ssh ( like telnet in DOS ) into the system, and run the commands, and if possible set it up to load at boot time.

Distro, short for Distribution. Examples are Debain, Slackware, Ubuntu. A distro is a linux kernel, with a group of programs that will install from a file.
 
Old 11-15-2010, 02:16 PM   #5
xwishmasterx
Member
 
Registered: Jul 2008
Posts: 30

Original Poster
Rep: Reputation: 0
my problem is my device does not support network access, so no ssh/telnet. In fact this is what I am trying to setup. A custom firmware has been built and a wireless-mod.bin.
However my wifi dongle is not supported, an compiling is not really anything I can do (had a friend trying but it doesn't work)

I have gotten my hands on the driver as .ko file and therefore trying to load the drivers this way.

If this is to hard (if not impossible), maybe I can find a real linux-genius who would be kind enough to compile it for me again.
 
Old 11-15-2010, 04:55 PM   #6
camorri
LQ Guru
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 14.1, 14.2
Posts: 5,090

Rep: Reputation: 483Reputation: 483Reputation: 483Reputation: 483Reputation: 483
Quote:
I have gotten my hands on the driver as .ko file and therefore trying to load the drivers this way.
That file has to compiled against your kernel source, or it will not load or work. So I think you will need to find someone to compile a kernel. Then of course you will have to install it.
 
Old 11-15-2010, 05:19 PM   #7
xwishmasterx
Member
 
Registered: Jul 2008
Posts: 30

Original Poster
Rep: Reputation: 0
I do believe the kernel has been compiled also.

I am trying to compile it again myself with a step by step guide (and that's even hard to do).

Is there a way I can check the .bin to see if the kernel has been compiled or not?
 
Old 11-26-2010, 10:43 AM   #8
ORBiTrus
Member
 
Registered: Sep 2004
Location: On a compile thread
Distribution: CentOS, Debian, Fedora, Gentoo, Mandriva, Slackware, Ubuntu
Posts: 42

Rep: Reputation: 15
What device is this? A router? A NAS? A netbook?

What you've described in the first posts suggests that the wifi driver/firmware was built on a separate system, then loaded on whatever you are work on. That's normally a very bad way to do things, unless you can ensure that the two systems are mirror images of one another.

But without knowing what type of system you are working with, it's hard for us to know if what you probably need to do (build on the device you are installing to, or use an upstream-provided package) is even feasible.

Regardless, I think it would help everyone here have a better idea what you're working with if you could tell us the output of:
uname -a

ls /etc/*release /etc/*version

cat /etc/*release /etc/*version
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
RHEL install Vostro 400 - sys "Loading SCSI drivers" "loading ata_piix driver..." sreekr_news Linux - Newbie 11 01-21-2010 02:25 PM
loading drivers lchisholm Linux - Hardware 5 12-08-2006 09:53 AM
Device drivers : How to insmod and mknod through an application program? shendeswanand Linux - Newbie 0 02-08-2006 12:28 PM
ATI drivers not loaded at boot, and cannot insmod. Suggestions? Kramer Linux - Software 2 11-02-2005 07:06 AM
lots of insmod: errors when loading slackware Belize Slackware 2 12-02-2003 04:34 PM


All times are GMT -5. The time now is 06:46 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration