Results 1 to 9 of 9
  1. #1
    Joined
    May 2000
    Location
    /home/christop54
    Age
    48
    Posts
    4,430

    gkrellm sensor configuration help

    I installed gkrellm from Mandrake CD 1, but can't get the sensors (temps, fans, and voltages) to work. I've searched the net, but can't find any useful info. I need, or at least I think I need, to do something with lm_sensors, but am confused.

    Thanks in advance!

  2. #2
    Joined
    Jul 2001
    Location
    UK
    Age
    51
    Posts
    20,229

    Re: gkrellm sensor configuration help

    Yes, you need to get lm_sensors working first as this is what actually reads the data from your board. The first thing to do is run sensors-detect.

    A search on the forums will yield loads of hits as it's something nearly everyone struggles with. Here's a thread from HarryC:

    http://forums.pcper.com/showthread.php?t=326355

    I never managed to work out how the hell to get it working on one of my older boards, but in FC3 for my nForce2 board it was already preconfigured and worked fine. All I'll say is good luck, and don't waste too much time on it if you can't get it working. It's one of those things that will likely just drive you mad under linux It should be simple but often it isn't!

    Ned

  3. #3
    Joined
    Apr 2001
    Location
    Los Angeles
    Posts
    21,104

    Re: gkrellm sensor configuration help

    Just booted my mandrake 10 to try it. Lm sensors was not installed. You can check yours by running sensors-detect as Ned gave you. If nothing, and "locate lm_sensors" doesn't turn it up, just get urpmi to install it.

    su -
    pass

    urpmi lm_sensors

    It will list a couple of dependents, then type "y" for yes. I think it is on Disk 2, but my disk is messed up so it downloaded and installed it.

    Then you can run "sensors-detect".

    You can just keep hitting enter as you go through the process, it will give a list at the end of what it finds.

    This is for your A7N8X? On mine, at the end I was given this

    Code:
    #----cut here----
    # I2C adapter drivers
    # modprobe unknown adapter bt878 #0 [sw] using Algorithm unavailable
    modprobe i2c-nforce2
    # modprobe unknown adapter bt878 #0 [sw] using Algorithm unavailable
    # I2C chip drivers
    modprobe asb100
    modprobe w83l785ts
    modprobe smbus-arp
    modprobe eeprom
    # sleep 2 # optional
    /usr/local/bin/sensors -s # recommended
    #----cut here----
    You don't need everything, just figure out which one gives you your sensor listing. For example, the eeprom one will just list out your dimms, the bt878 is a TV card, so you don't need that. In my case I found that

    modprobe asb100

    would result in my sensors coming up if I ran

    sensors

    On the command line right afterwards. So to finish off the setup, I now edit my /etc/rc.local file and add these lines in at the end:

    modprobe asb100
    /usr/local/bin/sensors -s

    And that does it. On reboot, just typing "sensors" gives the output. Don't have Gkrellm on mandrake here, but just start it up, right-click->configure->Built ins->Sensors, and you should find everything you need.

    Edit: Actually, might want to add the w83 sensor in too. Looks like in Gkrellm (went ahead and installed it) the w83l785ts-2-002e temp1 is the diode if you want it.
    Last edited by Senor Panadero; 03-06-2005 at 09:22 PM.

  4. #4
    Joined
    Jul 2001
    Location
    UK
    Age
    51
    Posts
    20,229

    Re: gkrellm sensor configuration help

    Got mine working now - I followed pretty much what HarryC described in the thread I linked above.

    Mine also detected a i2c-matroxfb sensor that it tried to load for my Matrox G400 graphics card and that killed my system dead

    Then I discovered that the SMBus sensors gave screwy readouts for all my temps. In the end, just using the ISA sensors worked for me so I just commented out (#) all the sensors detected on the SMBus.

    gkrellm installed and ran without problem for me - but I'll be darned if I can make the display look as nice/flashy as some manage

    Where are you at Christop - lets see if we can talk you through it if you get stuck.

    Ned

  5. #5
    Joined
    May 2000
    Location
    /home/christop54
    Age
    48
    Posts
    4,430

    Re: gkrellm sensor configuration help

    Senor Panadero,
    Yes, this is for my A7N8X.

    Ned,
    I had no luck with sensors-detect or locate lm_sensors, so I followed Senor Panadero's advice:

    su -
    pass

    urpmi lm_sensors

    This worked. (What is the difference, if any, between su and su -) So I did sesnors-detect and, per Senor Panadero's post, and kept hitting enter. I also got this (or at least very close. I've rebooted since seeing it.):
    Code:
    #----cut here----
    # I2C adapter drivers
    # modprobe unknown adapter bt878 #0 [sw] using Algorithm unavailable
    modprobe i2c-nforce2
    # modprobe unknown adapter bt878 #0 [sw] using Algorithm unavailable
    # I2C chip drivers
    modprobe asb100
    modprobe w83l785ts
    modprobe smbus-arp
    modprobe eeprom
    # sleep 2 # optional
    /usr/local/bin/sensors -s # recommended
    #----cut here----
    I rebooted, and there are now sensors available in gkrellm. Most look right, except the CPU temps. (several hundered degrees to about 2k F) Regarding adding entries to file. Senor Panadero and HarryC referenced /etc/rc.local.

    My /etc/rc.local looks like this:
    Code:
    #!/bin/sh
    #
    # This script will be executed *after* all the other init scripts.
    # You can put your own initialization stuff in here if you don't
    # want to do the full Sys V style init stuff.
    
    [ -f /etc/sysconfig/system ] && source /etc/sysconfig/system
    [ -f /etc/sysconfig/msec ] && source /etc/sysconfig/msec
    [ -z "$SECURE_LEVEL" ] && SECURE_LEVEL=3
    [ -f /etc/sysconfig/init ] && source /etc/sysconfig/init
    if [ $SECURE_LEVEL -lt 4 ]; then
        [ -z "$REWRITEISSUE" ] && REWRITEISSUE=rewrite
        if [ $SECURE_LEVEL -lt 3 ]; then
    	[ -z "$REWRITEISSUENET" ] && REWRITEISSUENET=rewrite
        fi
    fi
    
    SYSTEM=${SYSTEM=Mandrakelinux}
    
    # Source functions
    . /etc/init.d/functions
    
    if [ "$REWRITEISSUE" = "rewrite" -a -f /etc/mandrake-release ]; then
        R=$(cat /etc/mandrake-release)
    
        arch=$(uname -m)
        a="a"
        case "_$arch" in
    	    _a*) a="an";;
    	    _i*) a="an";;
        esac
        
        NUMPROC=`egrep -c "^cpu[0-9]+" /proc/stat`
        if [ "$NUMPROC" -gt "1" ]; then
            SMP="$NUMPROC-processor "
    	[ "$NUMPROC" = "2" ] && \
    	SMP="Dual-processor "
            if [ "$NUMPROC" = "8" -o "$NUMPROC" = "11" ]; then
                a="an"
    	else
    	    a="a"
            fi
        fi
    
        # This will overwrite /etc/issue at every boot.  So, make any changes you
        # want to make to /etc/issue here or you will lose them when you reboot.
    
        if [ -x /usr/bin/linux_logo ]; then
    	/usr/bin/linux_logo -c -n -f | sed -e 's|\\|\\\\|g' > /etc/issue
    	echo "" >> /etc/issue
        else
    	> /etc/issue
        fi
        echo "$R" >> /etc/issue
        echo "Kernel $(uname -r) on $a $SMP$(uname -m) / \l" >> /etc/issue
        
        if [ "$REWRITEISSUENET" = "rewrite" ]; then
    	echo "Welcome to ${HOST}" > /etc/issue.net
    	echo "$R" >> /etc/issue.net
    	echo "Kernel $(uname -r) on $a $SMP$(uname -m)" >> /etc/issue.net
        else
    	NAME="$SYSTEM"
    	gprintf "Welcome to %s\n" "$NAME" > /etc/issue.net
    	echo "-------------------------" >> /etc/issue.net
        fi
    else
        if [ -f /etc/security/msec/issue.$SECURE_LEVEL ]; then
    	cat /etc/security/msec/issue.$SECURE_LEVEL > /etc/issue
        elif [ -f /etc/security/msec/issue ]; then
    	cat /etc/security/msec/issue > /etc/issue
        else
    	rm -f /etc/issue
        fi
        if [ -f /etc/security/msec/issue.net.$SECURE_LEVEL ]; then
    	cat /etc/security/msec/issue.net.$SECURE_LEVEL > /etc/issue.net
        elif [ -f /etc/security/msec/issue.net ]; then
    	cat /etc/security/msec/issue.net > /etc/issue.net
        else
    	rm -f /etc/issue.net
        fi
    fi
    
    touch /var/lock/subsys/local
    If I follow, I need to add something like:

    modprobe asb100
    /usr/local/bin/sensors -s

    But I'm not sure where, and don't want to cause any problems. Please advise. Thanks!

  6. #6
    Joined
    Apr 2001
    Location
    Los Angeles
    Posts
    21,104

    Re: gkrellm sensor configuration help

    Quote Originally Posted by Christop54

    If I follow, I need to add something like:

    modprobe asb100
    /usr/local/bin/sensors -s

    But I'm not sure where, and don't want to cause any problems. Please advise. Thanks!
    Just for comparison, the end of my file looks like this now:
    Code:
        if [ -f /etc/security/msec/issue.net.$SECURE_LEVEL ]; then
            cat /etc/security/msec/issue.net.$SECURE_LEVEL > /etc/issue.net
        elif [ -f /etc/security/msec/issue.net ]; then
            cat /etc/security/msec/issue.net > /etc/issue.net
        else
            rm -f /etc/issue.net
        fi
    fi
    
    touch /var/lock/subsys/local
    
    modprobe asb100
    modprobe w83l785ts
    # sleep 2 # optional
    /usr/local/bin/sensors -s # recommended
    So all you do is edit the file, and put these lines at the end of it. Have you edited config files before? That is a topic in and of itself.

    You can either edit the formula for the sensors in /etc/sensors.conf file (hard) or (easy) use the "Offset" function in GKrellm to fix the obvious problems with readings.

    One problem did come up for me, hope it doesn't for you. I am getting a hang on shutdown, it is failing when trying to unload the sensord and hanging when unloading the sensor modules. Someone else might have an idea there.

  7. #7
    Joined
    May 2000
    Location
    /home/christop54
    Age
    48
    Posts
    4,430

    Re: gkrellm sensor configuration help

    I messed around with the "Offset" function in GKrellm, but don't see how to properly adjust them. (They aren't very accurate, and besides checking in the BIOS I don't see when you'd know when to stop adjusting. That and if you'd want to get an accurate reading, it seems to me that you'd have to go back and forth between the OS and the BIOS. The result wouldn't be very accurate.) I'm sure Google might provide something helpful.

    Regarding editing the formula for the sensors in /etc/sensors.conf file. Would this work? Open a terminal program and enter vi? Or, the method I would prefer, opening a terminal program and entering gvim file.txt? I think both ways are basically the same, but the second is text based (easier).

    What do you do when your system hangs on shutdown? Hit the reset button and boot back into Linux? Do you have problems booting into Linux?

  8. #8
    Joined
    Apr 2001
    Location
    Los Angeles
    Posts
    21,104

    Re: gkrellm sensor configuration help

    Quote Originally Posted by Christop54
    Regarding editing the formula for the sensors in /etc/sensors.conf file. Would this work? Open a terminal program and enter vi? Or, the method I would prefer, opening a terminal program and entering gvim file.txt? I think both ways are basically the same, but the second is text based (easier).
    Right. Need to find the section for that chip and edit there. Have changed labels and such before, never done anything with the forumulas, but it looks straightforward enough.

    What do you do when your system hangs on shutdown? Hit the reset button and boot back into Linux? Do you have problems booting into Linux?
    Yes, just turning it off for now, and that causes a file system check on startup. Never had this problem before with lm_sensors, so don't really know what the deal is. Have three other distributions on this machine, all the others seem accurate and there are no other issues. Something about the mandrake package? Could be. Could rtry removing it through urpmi and installing another package or build from source I guess.

  9. #9
    Joined
    Jul 2001
    Location
    UK
    Age
    51
    Posts
    20,229

    Re: gkrellm sensor configuration help

    Quote Originally Posted by Christop54
    This worked. (What is the difference, if any, between su and su -)
    The "-" symbol makes the shell a login shell so doing "su -" will run root's login scripts. This means you'll notice that you are in root's home directory (/root) and that you have adopted root's PATH so you'll be able to run most commands without having to know where they're located and specify the path to them.

    It's best illustrated with an example. Most normal user commands are located in /bin or /usr/bin and these directories are on your path so when you type the command, the linux shell knows where to look to find them and they run. Most commands that require root previledges to run are stored in /sbin or /usr/sbin. These directories aren't by default on a normal users path so if you just type the command, you'll get command not found. If you just do "su", you haven't run root's login scripts so /sbin or /usr/sbin is not on your current path and you'd still get a command not found, bt if you do "su -" the command will be found and run fine.

    This catches out a lot of new users - someone says run command X as root and the user will respond with it says command not found, is it not installed on my system? because they did "su", not "su -".

    Basically, if you haven't changed your path and/or you don't know the full path to the command you want, then it's probably simpler to use "su -" rather than "su".

    Hope that explains it!

    Ned

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •