LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-30-2004, 08:59 AM   #16
minm
Member
 
Registered: Jun 2003
Location: Canada
Distribution: suse 9.2
Posts: 582

Original Poster
Rep: Reputation: 30

ok, the final instructions it gives me are these:

Copy /usr/share/doc/packages/sensors/prog/init/lm_sensors.init.suse
to /etc/init.d/lm_sensors for initialization at boot time.

how can i copy within a file?
or am i just copying the contents of that file to /etc/init.d/lm_sensors ?
 
Old 09-30-2004, 09:01 AM   #17
minm
Member
 
Registered: Jun 2003
Location: Canada
Distribution: suse 9.2
Posts: 582

Original Poster
Rep: Reputation: 30
i also don't know where to put the part of some rc.*

there are two files.. rc.status and rc.d?

which one should i put the code in?
 
Old 09-30-2004, 09:18 AM   #18
mdg
Member
 
Registered: Sep 2003
Distribution: Slackware
Posts: 626

Rep: Reputation: 38
Quote:
Originally posted by minm
ok, the final instructions it gives me are these:

Copy /usr/share/doc/packages/sensors/prog/init/lm_sensors.init.suse
to /etc/init.d/lm_sensors for initialization at boot time.

how can i copy within a file?
or am i just copying the contents of that file to /etc/init.d/lm_sensors ?
Copy the file to /etc/init.d and rename it lm_sensors


Quote:
i also don't know where to put the part of some rc.*

there are two files.. rc.status and rc.d?

which one should i put the code in?
As I said on one of my earlier posts in this thread, /etc/rc.d/rc.local usually works, but I'm not familiar with Suse
 
Old 09-30-2004, 09:29 AM   #19
minm
Member
 
Registered: Jun 2003
Location: Canada
Distribution: suse 9.2
Posts: 582

Original Poster
Rep: Reputation: 30
hmm, ok.. i did all that, restarted, and it's showing nothing..

by showing nothing i mean it's not displaying the temperatures or fan speed or anything.

Last edited by minm; 09-30-2004 at 11:16 AM.
 
Old 09-30-2004, 12:10 PM   #20
mdg
Member
 
Registered: Sep 2003
Distribution: Slackware
Posts: 626

Rep: Reputation: 38
I assume you're using GKrellm. Have you enabled the sensors in GKrellm? Right-click on the title-bar, Configuration, Builtins/sensors. Enable the sensors you want.
 
Old 09-30-2004, 01:39 PM   #21
minm
Member
 
Registered: Jun 2003
Location: Canada
Distribution: suse 9.2
Posts: 582

Original Poster
Rep: Reputation: 30
well iwant the temperatures and fan speed but it says

No sensors detected. in the info tab..
 
Old 09-30-2004, 01:44 PM   #22
minm
Member
 
Registered: Jun 2003
Location: Canada
Distribution: suse 9.2
Posts: 582

Original Poster
Rep: Reputation: 30
hmm it's very wierd, i tried doing sensors-detect again and it says it made the config file /usr/share/doc/packages/sensors/prog/init/lm_sensors.init.suse

but it's not even there

i remember it was generating it, but i did cut it and paste it ,but since it didn't work i deleted it, and tried doing it again, mabye cause i deleted it it's gons?

Last edited by minm; 09-30-2004 at 01:47 PM.
 
Old 09-30-2004, 01:56 PM   #23
mdg
Member
 
Registered: Sep 2003
Distribution: Slackware
Posts: 626

Rep: Reputation: 38
If you don't have the lm_sensors.init.suse file in place, lm_sensors won't start.
I compiled lm_sensors from source and my lm_sensors.init file is in my home directory, specifically /home/marc/lm_sensors-2.8.7/prog/init/lm_sensors.init. I copied it to /etc/rc.d/init.d and renamed it lm_sensors.

Once you've found it and copied/renamed it (lm_sensors.init.suse in your case), reboot and watch the scrolling kernel messages for any mention of lm_sensors being loaded. If you've followed all the previous steps, you should be set up.
 
Old 09-30-2004, 02:02 PM   #24
minm
Member
 
Registered: Jun 2003
Location: Canada
Distribution: suse 9.2
Posts: 582

Original Poster
Rep: Reputation: 30
hmm
it's not in my home directory
idid a file search and it appears to be no where..

hmm
i'm also doing it through root so it SHOULD create it..?
 
Old 09-30-2004, 02:04 PM   #25
minm
Member
 
Registered: Jun 2003
Location: Canada
Distribution: suse 9.2
Posts: 582

Original Poster
Rep: Reputation: 30
is there a way to retrieve that file??
or make a new one?
 
Old 09-30-2004, 02:11 PM   #26
mdg
Member
 
Registered: Sep 2003
Distribution: Slackware
Posts: 626

Rep: Reputation: 38
Here's the code for lm_sensors.init.suse
Code:
#!/bin/sh
#
### BEGIN INIT INFO
# Provides:			lm_sensors
# Required-Start:		$local_fs 
# X-UnitedLinux-Should-Start:	
# Required-Stop:		$local_fs 
# X-UnitedLinux-Should-Stop:	
# Default-Start:		3 4 5
# Default-Stop:			0 1 2 6
# Short-Description:		LM Sensors
# Description:			LM Sensors for hardware monitoring
### END INIT INFO
# chkconfig: 2345 26 74
# description: sensors is used for monitoring motherboard sensor values.
# config: /etc/sysconfig/sensors
#
#    This program is free software; you can redistribute it and/or modify
#    it under the terms of the GNU General Public License as published by
#    the Free Software Foundation; either version 2 of the License, or
#    (at your option) any later version.
#
#    This program is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#    GNU General Public License for more details.
#
#    You should have received a copy of the GNU General Public License
#    along with this program; if not, write to the Free Software
#    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.

# See also the lm_sensors homepage at:
#     http://www2.lm-sensors.nu/~lm78/index.html

# It uses a config file /etc/sysconfig/sensors that contains the modules to
# be loaded/unloaded. That file is sourced into this one.

# The format of that file a shell script that simply defines the modules 
# in order as normal shell variables with the special names:
#    MODULE_1, MODULE_2, MODULE_3, etc.

# If sensors isn't supported by the kernel, try loading the module...
[ -e /proc/sys/dev/sensors ] || /sbin/modprobe i2c-proc &>/dev/null

# Don't bother if /proc/sensors still doesn't exist, kernel doesn't have
# support for sensors.
[ -e /proc/sys/dev/sensors ] || exit 0

# If sensors was not already running, unload the module...
[ -e /var/lock/subsys/sensors ] || /sbin/modprobe -r i2c-proc &>/dev/null

CONFIG=/etc/sysconfig/lm_sensors
PSENSORS=/usr/local/bin/sensors

# Source function library.
#. /etc/init.d/functions

# Shell functions sourced from /etc/rc.status:
#      rc_check         check and set local and overall rc status
#      rc_status        check and set local and overall rc status
#      rc_status -v     ditto but be verbose in local rc status
#      rc_status -v -r  ditto and clear the local rc status
#      rc_status -s     display "skipped" and exit with status 3
#      rc_status -u     display "unused" and exit with status 3
#      rc_failed        set local and overall rc status to failed
#      rc_failed <num>  set local and overall rc status to <num>
#      rc_reset         clear local rc status (overall remains)
#      rc_exit          exit appropriate to overall rc status
#      rc_active	checks whether a service is activated by symlinks
#      rc_splash arg    sets the boot splash screen to arg (if active)
. /etc/rc.status

# Reset status of this service
rc_reset

# Return values acc. to LSB for all commands but status:
# 0	  - success
# 1       - generic or unspecified error
# 2       - invalid or excess argument(s)
# 3       - unimplemented feature (e.g. "reload")
# 4       - user had insufficient privileges
# 5       - program is not installed
# 6       - program is not configured
# 7       - program is not running
# 8--199  - reserved (8--99 LSB, 100--149 distrib, 150--199 appl)
# 
# Note that starting an already running service, stopping
# or restarting a not-running service as well as the restart
# with force-reload (in case signaling is not supported) are
# considered a success.

RETVAL=0

start() {
	echo -n $"Starting up sensors: "
	test -r "$CONFIG" && . "$CONFIG"

        modules=`grep \^MODULE_ $CONFIG | wc -l | tr -d ' '`
        i=0
        while [ $i -lt $modules ] ; do
                module=`eval echo '$'MODULE_$i`
		echo starting module __${module}__
		/sbin/modprobe $module &>/dev/null
		i=`expr $i + 1`
	done
        $PSENSORS -s

	RETVAL=$?
	if [ $RETVAL -eq 0 ] && touch /var/lock/subsys/sensors ; then
	    rc_status -v
	else
	    rc_status -v
	fi
}

stop() {
	echo -n $"Shutting down sensors: "
	test -r "$CONFIG" && . "$CONFIG"

        modules=`grep \^MODULE_ $CONFIG | wc -l | tr -d ' '`
        i=`expr $modules`
        while [ $i -ge 0 ] ; do
                module=`eval echo '$'MODULE_$i`
		/sbin/modprobe -r $module &>/dev/null
		i=`expr $i - 1`
	done
	/sbin/modprobe -r i2c-proc &>/dev/null

	RETVAL=$?
	if [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/sensors ; then
	    rc_status -v
	else
	    rc_status -v
	fi
}

dostatus() {
        $PSENSORS
	RETVAL=$?
}

restart() {
	stop
	start
	RETVAL=$?
}

condrestart() {
	[ -e /var/lock/subsys/sensors ] && restart || :
}

# See how we were called.
case "$1" in
  start)
	start
	;;
  stop)
	stop
	;;
  status)
	dostatus
	;;
  restart|reload)
	restart
	;;
  condrestart)
	condrestart
	;;
  *)
	echo "Usage: sensors.init {start|stop|status|restart|reload|condrestart}"
	exit 1
esac

exit $RETVAL
Copy it to /etc/rc.d/init.d and renamed it lm_sensors.
 
Old 09-30-2004, 02:16 PM   #27
minm
Member
 
Registered: Jun 2003
Location: Canada
Distribution: suse 9.2
Posts: 582

Original Poster
Rep: Reputation: 30
ok, i did that and still to no avail
 
Old 09-30-2004, 02:17 PM   #28
mdg
Member
 
Registered: Sep 2003
Distribution: Slackware
Posts: 626

Rep: Reputation: 38
Did you reboot?
 
Old 09-30-2004, 02:18 PM   #29
minm
Member
 
Registered: Jun 2003
Location: Canada
Distribution: suse 9.2
Posts: 582

Original Poster
Rep: Reputation: 30
yes
 
Old 09-30-2004, 02:38 PM   #30
mdg
Member
 
Registered: Sep 2003
Distribution: Slackware
Posts: 626

Rep: Reputation: 38
Okay, looks like something has been missed.

1. Configure the kernel as per lm_sensors page

2. Do lsmod. Make sure you have the needed modules loaded:
i2c-nforce2
asb100
w83l785ts
eeprom
thermal
processor
fan
i2c_sensor
i2c_dev
i2c_core

3. Run sensors-detect, don't skip any questions, answer default for all

4. Copy/paste/rename code to appropriate locations

5. Reboot

6. Configure gkrellm

Last edited by mdg; 10-10-2004 at 02:18 AM.
 
  


Reply



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
problem installing lm_sensors PunkPT Slackware 3 07-29-2004 03:22 PM
lm_sensors problem JJX Linux - Newbie 5 04-18-2004 04:15 AM
lm_sensors problem mkzmonkeylagger Linux - Software 1 04-16-2004 07:29 PM
lm_sensors problem! r3l4x Debian 4 10-20-2003 10:15 AM
I2c & lm_sensors installation question. nidua18 Linux - General 1 10-16-2003 05:49 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:26 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
Open Source Consulting | Domain Registration