On Thu, 13 Jul 2006, Daniel A. Ramaley wrote:
The lines in sensorsd.conf start with "hw.sensors.N" (where N is a small
natural number). How do i determine N for each sensor? Is there a list
You can retrieve sensors information using the sysctl command:
$ sysctl hw.sensors
hw.sensors.0=viaenv0, TSENS1, temp, 50.50 degC / 122.90 degF
hw.sensors.1=viaenv0, TSENS2, temp, 52.00 degC / 125.60 degF
hw.sensors.2=viaenv0, TSENS3, temp, 26.82 degC / 80.28 degF
hw.sensors.3=viaenv0, FAN1, fanrpm, 0 RPM
hw.sensors.4=viaenv0, FAN2, fanrpm, 0 RPM
hw.sensors.5=viaenv0, VSENS1, volts_dc, 1.20 V
hw.sensors.6=viaenv0, VSENS2, volts_dc, 2.51 V
hw.sensors.7=viaenv0, Vcore, volts_dc, 3.26 V
hw.sensors.8=viaenv0, VSENS3, volts_dc, 4.95 V
hw.sensors.9=viaenv0, VSENS4, volts_dc, 11.83 V
Now, to know what hw.sensors.0 is, you have a loot at the man page
corresponding to your sensor (here viaenv):
$ man viaenv
(...)
The device has 10 sensors:
Sensor Units Typical Use
TSENS1 uK CPU temperature
TSENS2 uK System temperature
TSENS3 uK Unknown
FAN1 RPM CPU fan
FAN2 RPM System fan
VSENS1 uV DC CPU core voltage (2.0V)
VSENS2 uV DC North Bridge core voltage (2.5V)
Vcore uV DC Internal core voltage (3.3V)
VSENS3 uV DC +5V
VSENS4 uV DC +12V
(...)
Let's say you want to monitor your CPU temperature, in your
/etc/sensorsd.conf file, you could put something like:
hw.sensors.0:high=60C:\
:command=echo "%2 \(high=%4\)" | mail -s "[`hostname`] sensorsd WARNING \(CPU
Temp.\)" root
Regards,
--
Antoine