Jump to content

lm_sensors MDK 10? error I do not understand.


tsw
 Share

Recommended Posts

Mandrake 10 official

AMD XP2400

machspeed V2MDMP

512 RAM

kernel: 2.6.3.7mdk

 

 

Hello has anyone gotten lm_sensors to work properly with mandrake 10 and the 2.6.3.7 kerenl.

 

I have done suggested steps many times over. Sensors-detect will detect sensors and I copy the lines it asks to copy over to the rc.d files. However, when I run /usr/bin/sensors -s I get this error:

 

[root@gusto tsw]# /usr/bin/sensors -s

it87-isa-0290: Can't access procfs/sysfs file for writing;

Run as root?

 

I am running it as root by the way. What the f is up? And yes my board and cpu have sensor capabilities. AMD or Machspeed (i forget which company) has a windows monitoring program that came with the set. It seems to work well in windoze, I however do not work so well in windows so I would like to get this figured out. Further, according to the lm_sensors home page the km400 chipsets of the mobo have proven to be supported.

 

From the lm_sensors home page (http://www2.lm-sensors.nu/~lm78/FAQ.txt) I got this information:

 

4.20 Sensors says 'Can't access /proc file'

 

(release 2.6.0 and later) Did you 'modprobe i2c-proc'? Check 'lsmod'.

(release 2.5.5 and earlier) Did you 'modprobe sensors'? Check 'lsmod'.

If you did 'sensors -s', did you run it as root?

Do you have /proc support in your kernel (is /proc there?)

 

The 2.6.3.7mdk kernel has proc support doesn't it? When I tried to 'modprobe i2c-proc' I get the following error:

 

# modprobe i2c-proc

FATAL: Module i2c-proc not found.

 

A urpmi search for file names containing 'i2c-proc' returns a healthy list of 2.4.** kernels:

 

kernel-2.4.25.2mdk

kernel2.4-marcelo

kernel24-tmb-2.4.25-2.tmb.1mdk

etc....

 

Does this mean that the 'i2c-proc' module is not supported in the mandrake 2.6.** kernels? I really do not have a clue? As you can probably tell. /proc support is enabled in kernel.

 

Then there is also this line that makes no sense to me:

 

Do you want to generate /etc/sysconfig/lm_sensors? (YES/no): YES

Copy prog/init/lm_sensors.init to /etc/rc.d/init.d/lm_sensors

for initialization at boot time.

 

The file 'prog/init/lm_sensors.init ' is no where to be found on my machine.

 

KSensors is also installed and when ran will read CPU information such as cpu speed, cpu state, and RAM usage, but not CPU TEMP (in which I am most interested) nor will it read CPU VOLTAGE.

 

If anyone has had any success with this program please enlightenment me. I have hit a brick wall.

Thanks in advance for any assistance.

 

regards

tsw

Edited by tsw
Link to comment
Share on other sites

The 'modprobe' command installs modules (in Windows: d'rivers'). So if you can't install the modules to acces your mobo sensor capabilities lm_sensors wont work.

 

The 'lsmod' command gives a list of all the modules installed on your computer. So if i2c-proc isn't mentioned in the list it isn't installed and so you can't use the sensor capabilities and so lm-sensors won't work. (you have a 2.6 kernel so you must use this module, not 'sensors')

 

Best is to begin again. Remove lm_sensors and install it with urmpi.

 

Run the setup script again.

 

Check if i2c-proc is installed by doing lsmod.

 

If not do depmod -ae and then modprobe i2c-proc and then check lsmod again.

 

The use lm_sensors

 

Good luck

Link to comment
Share on other sites

Thanks for responding. I have been using Madrake for about a year now and have a pretty good understanding of the basics of linux. That is what is frustrating about this little bugger.

 

A google search for i2c-proc gave me this:

 

http://www.ussg.iu.edu/hypermail/linux/ker...305.3/1639.html

 

It seems that this module is no longer a separate compile option in the 2.6.** kernels. So this leads me to believe that the main problem as to why the program will not respond is this:

 

[root@gusto tsw]# /usr/bin/sensors -s

it87-isa-0290: Can't access procfs/sysfs file for writing;

Run as root?

 

Since the sensor cannot access the proper files there is no way for it to report what is going on with the machine. I have tried changing permissions for /proc and /sys ( where sysfs is mounted ) however these changes do not take effect.

 

Might you have an idea how I can configure either /proc or /sys to be writable?

 

Thank you,

 

tsw

Link to comment
Share on other sites

There's another thread here on this problem you might want to search for. IIRC the kernel you are using will only work with a specific version of lm_sensors which no one seems to be able to find. Here's the quote form lm_sensors:

 

Naming and magnitude standards for sysfs data was just stabilizing in early 2.6 kernels. As a result, we did our best to ensure that lm_sensors was compatible with the kernel state at any given state, and released often. This also means that each version of lm_sensors from 2.8.2 (the first 2.6 kernel compatible release) to 2.8.5 only work properly for a limited range of kernel versions.

 

Recommended kernel and lm_sensors combinations:

 

    * Kernels 2.6.5-rc1 and later: lm_sensors 2.8.6 or any later version

    * Kernels 2.6.3-rc2 to 2.6.4: lm_sensors 2.8.5

    * Kernels 2.6.2-rc1 to 2.6.3-rc1: lm_sensors 2.8.4

    * Kernels 2.6.1-rc1 to 2.6.1: lm_sensors 2.8.3

    * Kernels 2.6.0 and earlier: lm_sensors 2.8.2

 

No one can find v2.8.5 which is what I believe you need to work with the mandrake kernel.

Link to comment
Share on other sites

I've successfully run the Mandrake supplied lm_sensors package on kernels 2.6.3-7mdk, 2.6.3-13mdk and 2.6.3-15mdk (current). My MOBO (ASUS A7V600) also uses the it87-isa-0290 chipset. I've had no problems with lm_sensors. I have lm_sensors-2.8.4-2mdk installed.

 

One thing puzzles me in your sensors-detect messages. I don't rember seeing any message to copy a file into /etc/rc.d/init.d. The /etc/init.d/lm_sensors file is added when you install the lm_sensors rpm. sensors-detect offer to setup /etc/sysconfig/lm_sensors for you is correct and required for MDK's /etc/init.d/lm_sensors script to work correctly. It is this script that loads all the required modules.

 

Are you using the Mandrake rpm or are you trying to install lm_sensors by another means? If you're not using the MDK package, I'd recommend it. If you are, then the problem may have more to do with the procfs/sysfs message. In MDK 10.0, lm_sensors uses sysfs, found under /sys. If everything is working correctly, you see all the lm_sensors related hardware under /sys/bus/i2c/*. The lm_sensors modules are supplied with the kernel, and invoked by /etc/init.d/lm_sensors, using info (sh variables) read from /etc/sysconfig/lm_sensors. /sys/bus/i2c will only be created when module i2c-proc is loaded successfull by /etc/init.d/lm_sensors.

 

I'd first check to see that you have the correct packages installed, then check /etc/sysconfig/lm_sensors to see how sensors-detect has configured your system. If all that looks ok, check /var/log/syslog (or messages) for output from /etc/init.d/lm_sensors. That should give you some clues as to what's happening.

Link to comment
Share on other sites

One thing puzzles me in your sensors-detect messages. I don't rember seeing any message to copy a file into /etc/rc.d/init.d. The /etc/init.d/lm_sensors file is added when you install the lm_sensors rpm. sensors-detect offer to setup /etc/sysconfig/lm_sensors for you is correct and required for MDK's /etc/init.d/lm_sensors script to work correctly. It is this script that loads all the required modules.

 

Yes, this puzzles me as well. The first package I used was the rpm form Mandrake. As you can tell it did not work properely. I also tried to downgrade to version 2.8.6 form the Mandrake repository. Same results. Version 2.8.5 have not found yet.

 

Yeah the whole:

[root@gusto tsw]# /usr/bin/sensors -s

it87-isa-0290: Can't access procfs/sysfs file for writing;

Run as root?

I think it the problem but I have no idea what it means. As I wrote before it is not a permissions problem as far as I can tell.

 

A quick check of /var/sys/log did not show much, but I will check again after I get some rest.

 

Here is the meat of my /ect/sysconfig/lm_sensors. Is this correct?

 

# List the modules that are to be loaded for your system

#

# Generated by sensors-detect on Tue Aug 10 04:19:34 2004

MODULE_0=i2c-viapro

MODULE_1=i2c-isa

MODULE_2=eeprom

MODULE_3=it87

 

Thanks for the posts folks. It at least gives another direction.

 

tsw

Link to comment
Share on other sites

From the FAQ:

 

4.20 Sensors says `Can't access procfs/sysfs file'

==================================================

 

   * (Linux 2.6) Did you `modprobe i2c_sensor'? Check `lsmod'.

 

   * (Linux 2.4) Did you `modprobe i2c-proc'? Check `lsmod'.

 

   * If you did `sensors -s', did you run it as root?

 

   * (Linux 2.6) Do you have sysfs support in your kernel (is `/sys'

     there and populated)?

 

   * (Linux 2.4) Do you have procfs support in your kernel (is `/proc'

     there and populated)?

 

and from Google: http://www2.lm-sensors.nu/~lm78/readticket.cgi?ticket=1648

 

Good luck

Link to comment
Share on other sites

Are you sure you removed all of previously installed lm_sensors?

 

Yes, without a doubt. First I 'modprobe -r' the modules. Then 'urpme lm_sensors.' A quick 'updatedb'. Followed by a 'locate lm_sensors' which resultes in:

 

[root@gusto tsw]# locate lm_sensors

[root@gusto tsw]#

 

So, to the best of my knowledge all previously installed versions of lm_sensors are always removed before I try either a redo or a different version #.

 

tsw

Link to comment
Share on other sites

[root@gusto tsw]# /usr/bin/sensors -s

it87-isa-0290: Can't access procfs/sysfs file for writing;

Run as root?

 

I suspect that this message means that some or all of the device special files created by the lm_sensor kernel drivers under /sys are missing. That would mean that some or all of the drivers failled to load or successfully initialize.

 

When

/etc/init.d/lm_sensors start

is run (at boot, or manually). i2c-proc and the modules listed in your /etc/sysconfig/lm_sensor file should have been loaded. They will create entries under /sys/bus. On my system, it looks like this:

 

[root@cougar kjel]# ls -lR /sys/bus/i2c
/sys/bus/i2c:
total 0
drwxr-xr-x  2 root root 0 Aug 11 10:00 devices/
drwxr-xr-x  5 root root 0 Aug 11 10:00 drivers/
                                                                                                         
/sys/bus/i2c/devices:
total 0
lrwxrwxrwx  1 root root 53 Aug 11 10:00 0-0050 -> ../../../devices/pci0000:00/0000:00:11.0/i2c-0/0-0050/
lrwxrwxrwx  1 root root 53 Aug 11 10:00 0-0051 -> ../../../devices/pci0000:00/0000:00:11.0/i2c-0/0-0051/
lrwxrwxrwx  1 root root 38 Aug 11 10:00 1-0290 -> ../../../devices/platform/i2c-1/1-0290/
                                                                                                         
/sys/bus/i2c/drivers:
total 0
drwxr-xr-x  2 root root 0 Aug 11 10:00 eeprom/
drwxr-xr-x  2 root root 0 Aug 11 10:00 i2c_adapter/
drwxr-xr-x  2 root root 0 Aug 11 10:00 IT87xx/
                                                                                                         
/sys/bus/i2c/drivers/eeprom:
total 0
lrwxrwxrwx  1 root root 56 Aug 11 10:00 0-0050 -> ../../../../devices/pci0000:00/0000:00:11.0/i2c-0/0-0050/
lrwxrwxrwx  1 root root 56 Aug 11 10:00 0-0051 -> ../../../../devices/pci0000:00/0000:00:11.0/i2c-0/0-0051/
                                                                                                         
/sys/bus/i2c/drivers/i2c_adapter:
total 0
                                                                                                         
/sys/bus/i2c/drivers/IT87xx:
total 0
lrwxrwxrwx  1 root root 41 Aug 11 10:00 1-0290 -> ../../../../devices/platform/i2c-1/1-0290/

 

If you don't see something like this there is some kind of driver falilure.

 

Under the device directories you should see something like this:

[root@cougar devices]# ls -L *
0-0050:
detach_state  eeprom  name  power/
                                                                                                         
0-0051:
detach_state  eeprom  name  power/
                                                                                                         
1-0290:
alarms        fan_input2  in_input1  in_input7  in_max4  in_min2  name         temp_input2  temp_min2
detach_state  fan_input3  in_input2  in_input8  in_max5  in_min3  power/       temp_input3  temp_min3
fan_div1      fan_min1    in_input3  in_max0    in_max6  in_min4  sensor1      temp_max1
fan_div2      fan_min2    in_input4  in_max1    in_max7  in_min5  sensor2      temp_max2
fan_div3      fan_min3    in_input5  in_max2    in_min0  in_min6  sensor3      temp_max3
fan_input1    in_input0   in_input6  in_max3    in_min1  in_min7  temp_input1  temp_min1

Link to comment
Share on other sites

I ran those commands and mine looks identical to yours, but still get:

 

[root@gusto tsw]# /usr/bin/sensors -s

it87-isa-0290: Can't access procfs/sysfs file for writing;

Run as root?

 

And when "sensors" ran I get this:

 

[root@gusto devices]# sensors

it87-isa-0290

Adapter: ISA adapter

ERROR: Can't get IN0 data!

ERROR: Can't get IN1 data!

ERROR: Can't get IN2 data!

ERROR: Can't get IN3 data!

ERROR: Can't get IN4 data!

ERROR: Can't get IN5 data!

ERROR: Can't get IN6 data!

ERROR: Can't get IN7 data!

ERROR: Can't get IN8 data!

ERROR: Can't get FAN1 data!

ERROR: Can't get FAN2 data!

ERROR: Can't get FAN3 data!

ERROR: Can't get TEMP1 data!

ERROR: Can't get TEMP2 data!

ERROR: Can't get TEMP3 data!

 

eeprom-i2c-0-51

Adapter: SMBus Via Pro adapter at 5000

Memory type: DDR SDRAM DIMM

Memory size (MB): 512

 

eeprom-i2c-0-50

Adapter: SMBus Via Pro adapter at 5000

Memory type: DDR SDRAM DIMM

Memory size (MB): 512

 

I do not want to give up on this project, but perhaps it is time. I just do not get it!!!!

 

Thanks for the help

 

tsw

Link to comment
Share on other sites

I ran those commands and mine looks identical to yours, ....

 

That's a good sign. At least your drivers are loading. There is one final thing you should do to isolate the source of your problems. The program sensor gets its raw data by reading from all those files in the /sys/bus/i2c/devices/* directories. Two of your devices are being read correctly -- those for the two eeproms -- but there is a problem with the it87 chip. The final check you need to make is to review the permissions on the files in the /sys/bus/i2c/devices/i-0290 directory. They should all be world readable and some will be root writable. You should be able to read the values of the sensors yourself by cat-ing the files. If you can do that then he problem is with the user-space program sensors and/or its support library /usr/lib/libsensors.so.3.0.2

 

As I noted earlier, rpm packages liblm_sensors3-2.8.4-2mdk and lm_sensors-2.8.4-2mdk have worked for me on all versions of the 2.6.3 kernel so far (but you have a different MOBO). If everything on the kernel driver side looks fine, then recheck your client side installation versions and run an rpm --verify on them to make sure they are properly installed. If that all checks out and you still have problems, then their is likely a bug or incompatibilty specific to your hardware or configuration. You could probably run strace on sensors to narrow down the problem more precisely.

 

Here's what the permissions on the i1-0290 (it87 chip) files should look like.

 

[kjel@cougar 1-0290]$ ls -l
total 0
-rw-r--r--  1 root root 4096 Aug 12 09:43 alarms
-rw-r--r--  1 root root 4096 Aug 12 09:43 detach_state
-rw-r--r--  1 root root    0 Aug 12 09:43 fan_div1
-rw-r--r--  1 root root    0 Aug 12 09:43 fan_div2
-rw-r--r--  1 root root    0 Aug 12 09:43 fan_div3
-r--r--r--  1 root root 4096 Aug 12 09:43 fan_input1
-r--r--r--  1 root root 4096 Aug 12 09:43 fan_input2
-r--r--r--  1 root root 4096 Aug 12 09:43 fan_input3
-rw-r--r--  1 root root    0 Aug 12 09:43 fan_min1
-rw-r--r--  1 root root    0 Aug 12 09:43 fan_min2
-rw-r--r--  1 root root    0 Aug 12 09:43 fan_min3
-r--r--r--  1 root root 4096 Aug 12 09:43 in_input0
-r--r--r--  1 root root 4096 Aug 12 09:43 in_input1
-r--r--r--  1 root root 4096 Aug 12 09:43 in_input2
-r--r--r--  1 root root 4096 Aug 12 09:43 in_input3
-r--r--r--  1 root root 4096 Aug 12 09:43 in_input4
-r--r--r--  1 root root 4096 Aug 12 09:43 in_input5
-r--r--r--  1 root root 4096 Aug 12 09:43 in_input6
-r--r--r--  1 root root 4096 Aug 12 09:43 in_input7
-r--r--r--  1 root root 4096 Aug 12 09:43 in_input8
-rw-r--r--  1 root root    0 Aug 12 09:43 in_max0
-rw-r--r--  1 root root    0 Aug 12 09:43 in_max1
-rw-r--r--  1 root root    0 Aug 12 09:43 in_max2
-rw-r--r--  1 root root    0 Aug 12 09:43 in_max3
-rw-r--r--  1 root root    0 Aug 12 09:43 in_max4
-rw-r--r--  1 root root    0 Aug 12 09:43 in_max5
-rw-r--r--  1 root root    0 Aug 12 09:43 in_max6
-rw-r--r--  1 root root    0 Aug 12 09:43 in_max7
-rw-r--r--  1 root root    0 Aug 12 09:43 in_min0
-rw-r--r--  1 root root    0 Aug 12 09:43 in_min1
-rw-r--r--  1 root root    0 Aug 12 09:43 in_min2
-rw-r--r--  1 root root    0 Aug 12 09:43 in_min3
-rw-r--r--  1 root root    0 Aug 12 09:43 in_min4
-rw-r--r--  1 root root    0 Aug 12 09:43 in_min5
-rw-r--r--  1 root root    0 Aug 12 09:43 in_min6
-rw-r--r--  1 root root    0 Aug 12 09:43 in_min7
-r--r--r--  1 root root 4096 Aug 12 09:43 name
drwxr-xr-x  2 root root    0 Aug 12 09:43 power/
-rw-r--r--  1 root root    0 Aug 12 09:43 sensor1
-rw-r--r--  1 root root    0 Aug 12 09:43 sensor2
-rw-r--r--  1 root root 4096 Aug 12 09:43 sensor3
-r--r--r--  1 root root 4096 Aug 12 09:43 temp_input1
-r--r--r--  1 root root 4096 Aug 12 09:43 temp_input2
-r--r--r--  1 root root 4096 Aug 12 09:43 temp_input3
-rw-r--r--  1 root root    0 Aug 12 09:43 temp_max1
-rw-r--r--  1 root root    0 Aug 12 09:43 temp_max2
-rw-r--r--  1 root root    0 Aug 12 09:43 temp_max3
-rw-r--r--  1 root root    0 Aug 12 09:43 temp_min1
-rw-r--r--  1 root root    0 Aug 12 09:43 temp_min2
-rw-r--r--  1 root root    0 Aug 12 09:43 temp_min3

Link to comment
Share on other sites

Thanks to everyone who helped with this little problem. It was a bugger. All of the permissions checked out but still did not work. So I decided to try a new kernel. Last night I upgraded to the 2.6.8.rc2 kernel which was a joy all its own (hi memory support, nvidia support, and of course matching kernel source). Once I got that kernel running lm_sensors now works. This is great. Oviously the problem was with the 2.6.3 kernel, perhaps not properely loading procfs/sysfs correctly. In any case it feels good to rejoin the world of apps-working-properly! Thanks again for your time and assistance.

 

tsw

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...