Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 157085 - sys-apps/lm_sensors-2.10.1 - sensors-detect creates bad /etc/init.d/lm_sensors
Summary: sys-apps/lm_sensors-2.10.1 - sensors-detect creates bad /etc/init.d/lm_sensors
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: High normal
Assignee: Christian Heim (RETIRED)
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks: 161851
  Show dependency tree
 
Reported: 2006-12-04 05:31 UTC by Peter Humphrey
Modified: 2007-01-14 20:19 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (emerge.info,2.79 KB, text/plain)
2006-12-04 05:32 UTC, Peter Humphrey
Details
lm_sensors-2.10.1-sensors-detect-gentoo.patch (lm_sensors-2.10.1-sensors-detect-gentoo.patch,4.63 KB, text/plain)
2007-01-13 18:36 UTC, Christian Heim (RETIRED)
Details
Corrected sensors-detect patch against 'lm_sensors' one. (diff-u-lm-sensors-2.10.1-prog-detect-sensors-detec-which-sensors-detect,4.51 KB, patch)
2007-01-14 12:32 UTC, Marc Finet
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Humphrey 2006-12-04 05:31:06 UTC
Two examples:

# /etc/init.d/lm_sensors start
FATAL: Module i2c_viapromodprobe not found.
 * Loading lm_sensors modules...
 *   Loading i2c-viapro ...                                                                               [ ok ]
 *   Loading eeprom ...                                                                                   [ ok ]
 *   Loading k8temp ...                                                                                   [ ok ]
 *   Loading w83627hf ...                                                                                 [ ok ]
 * Initializing sensors ...                                                                               [ ok ]


# /etc/init.d/lm_sensors restart
FATAL: Module i2c_viapromodprobe not found.
 * Unloading lm_sensors modules...
 *   Unloading w83627hf ...                                                                               [ ok ]
 *   Unloading k8temp ...                                                                                 [ ok ]
 *   Unloading eeprom ...                                                                                 [ ok ]
 *   Unloading i2c-viapro ...                                                                             [ ok ]
 * Loading lm_sensors modules...
 *   Loading i2c-viapro ...                                                                               [ ok ]
 *   Loading eeprom ...                                                                                   [ ok ]
 *   Loading k8temp ...                                                                                   [ ok ]
 *   Loading w83627hf ...                                                                                 [ ok ]
 * Initializing sensors ...                                                                               [ ok ]

# equery l lm_sensors
[ Searching for package 'lm_sensors' in all categories among: ]
 * installed packages
[I--] [ ~] sys-apps/lm_sensors-2.10.1 (0)

emerge --info in attachment
Comment 1 Peter Humphrey 2006-12-04 05:32:16 UTC
Created attachment 103322 [details]
emerge --info
Comment 2 Jakub Moc (RETIRED) gentoo-dev 2006-12-04 05:33:34 UTC
Post the output of `grep ^MODULE /etc/conf.d/lm_sensors` please.
Comment 3 Jakub Moc (RETIRED) gentoo-dev 2006-12-04 06:07:52 UTC
See above.
Comment 4 Peter Humphrey 2006-12-04 08:40:05 UTC
# grep ^MODULE /etc/conf.d/lm_sensors
MODULE_0=i2c-viapro
MODULE_1=eeprom
MODULE_2=k8temp
MODULE_3=w83627hf

This is as written by sensors-detect; I've made no changes.
Comment 5 Marijn Schouten (RETIRED) gentoo-dev 2006-12-04 08:51:17 UTC
the sensors-detect script put this line in my conf:

modprobe i2c-i801modprobe eeprommodprobe w83627ehf# Load modules at startup
Comment 6 Marijn Schouten (RETIRED) gentoo-dev 2006-12-04 08:52:09 UTC
using lm_sensors-2.10.1
Comment 7 Thomas Fischer 2007-01-05 07:22:50 UTC
Hi, same here

/usr/sbin/sensors-detect creates this lines in /etc/conf.d/lm_sensors and the init script fails to start lm_sensors.

/etc/conf.d/lm_sensors
modprobe i2c-sis96xmodprobe eeprommodprobe w83627hf# Load modules at startup
LOADMODULES=yes

# Initialize sensors at startup
INITSENSORS=yes

MODULE_0=i2c-sis96x
MODULE_1=eeprom
MODULE_2=w83627hf
Comment 8 Marc Finet 2007-01-13 15:47:12 UTC
Problem comes from the patch lm_sensors-2.10.0-sensors-detect-gentoo.patch that reverses two lines:
      print SYSCONFIG
-       "# Generated by sensors-detect on " . scalar localtime() . "\n";
+	  "# Generated by sensors-detect on " . scalar localtime() . "\n\n";
+      print SYSCONFIG

Rq: a warning is generated too. Fixing this patch will solve the warning and this strange line.
Comment 9 Marc Finet 2007-01-13 15:53:28 UTC
Sorry, culprit is lm_sensors-2.10.1-sensors-detect-gentoo.patch  (not 2.10.0):
     print SYSCONFIG
-      "# Generated by sensors-detect on " . scalar localtime() . "\n";
     my @modules = grep /^modprobe /, split "\n", $modprobes;
-    my $i = 0;
+	  "# Generated by sensors-detect on " . scalar localtime() . "\n\n";


I was too quick in my previous reply.
Comment 10 Christian Heim (RETIRED) gentoo-dev 2007-01-13 18:36:06 UTC
Created attachment 106827 [details]
lm_sensors-2.10.1-sensors-detect-gentoo.patch

(In reply to comment #9)
> Sorry, culprit is lm_sensors-2.10.1-sensors-detect-gentoo.patch  (not 2.10.0):
>      print SYSCONFIG
> -      "# Generated by sensors-detect on " . scalar localtime() . "\n";
>      my @modules = grep /^modprobe /, split "\n", $modprobes;
> -    my $i = 0;
> +         "# Generated by sensors-detect on " . scalar localtime() . "\n\n";

There is no special patch for 2.10.1 .. only the one for 2.10.0 that is being applied to 2.10.1 .. I assume this is still a problem with 2.10.1 ?

If yes, could you please see if the above patch solves this ? Thanks in advance.
Comment 11 Christian Heim (RETIRED) gentoo-dev 2007-01-13 18:37:30 UTC
(In reply to comment #10)

> There is no special patch for 2.10.1 .. only the one for 2.10.0 that is being
> applied to 2.10.1 .. I assume this is still a problem with 2.10.1 ?

*ugh* there is, I even attached the changed one. Must be too stupid to read correctly currently :P
Comment 12 Marc Finet 2007-01-14 12:32:52 UTC
Created attachment 106923 [details, diff]
Corrected sensors-detect patch against 'lm_sensors' one.

Here is the patch for a correct sensors-detect (i fixed the sensors-detect patched), and diff'ed from the lm_sensors one.

diff -u lm_sensors-2.10.1/prog/detect/sensors-detect `which sensors-detect`

Rq: the previous patch (http://bugs.gentoo.org/attachment.cgi?id=106827&action=view) will not work.
Comment 13 Christian Heim (RETIRED) gentoo-dev 2007-01-14 20:19:14 UTC
(In reply to comment #12)
> Created an attachment (id=106923) [edit]
> Corrected sensors-detect patch against 'lm_sensors' one.
> 
> Here is the patch for a correct sensors-detect (i fixed the sensors-detect
> patched), and diff'ed from the lm_sensors one.
> 
> diff -u lm_sensors-2.10.1/prog/detect/sensors-detect `which sensors-detect`

Thanks a lot for the patch. You guys rock. I just commited the changes to the tree. Wait the usual amount of time an sync up.