# cd /usr/src/linux
# make menuconfig# make && make modules_install
# mount /boot
# cp arch/i386/boot/bzImage /boot/kernel-2.6.13-28Nov2005-2037
# cp System.map /boot/System.map-2.6.13-28Nov2005-2037
# cp .config /boot/config-2.6.13-28Nov2005-2037
# nano -w /boot/grub/grub.conf# emerge -pv lm_sensors
# emerge lm_sensors>>> /etc/init.d/lm_sensors
*
* Next you need to run:
* /usr/sbin/sensors-detect
* to detect the I2C hardware of your system and create the file:
* /etc/conf.d/lm_sensors
*
* You will also need to run the above command if you're upgrading from
* <=lm_sensors-2.9.0, as the needed entries in /etc/conf.d/lm_sensors has
* changed.
*
* Be warned, the probing of hardware in your system performed by
* sensors-detect could freeze your system. Also make sure you read
* the documentation before running lm_sensors on IBM ThinkPads.
*
* Please see the lm_sensors documentation and website for more information.
*
>>> Regenerating /etc/ld.so.cache...
>>> sys-apps/lm_sensors-2.9.2 merged.
(snip)
# /usr/sbin/sensors-detect# sensors-detect revision 1.393 (2005/08/30 18:51:18)
This program will help you determine which I2C/SMBus modules you need to
load to use lm_sensors most effectively. You need to have i2c and
lm_sensors installed before running this program.
Also, you need to be `root', or at least have access to the /dev/i2c-*
files, for most things.
If you have patched your kernel and have some drivers built in, you can
safely answer NO if asked to load some modules. In this case, things may
seem a bit confusing, but they will still work.
It is generally safe and recommended to accept the default answers to all
questions, unless you know what you're doing.
We can start with probing for (PCI) I2C or SMBus adapters.
You do not need any special privileges for this.
Do you want to probe now? (YES/no): yes
Probing for PCI bus adapters...
Use driver `i2c-matroxfb' for device 01:00.0: MGA G200 AGP
Use driver `i2c-viapro' for device 00:07.3: VIA Technologies VT82C596 Apollo ACPI
Probe succesfully concluded.
We will now try to load each adapter module in turn.
Load `i2c-matroxfb' (say NO if built into your kernel)? (YES/no): yes
FATAL: Module i2c_matroxfb not found.
Loading failed... skipping.
Load `i2c-viapro' (say NO if built into your kernel)? (YES/no): yes
Module loaded succesfully.
If you have undetectable or unsupported adapters, you can have them
scanned by manually loading the modules before running this script.
To continue, we need module `i2c-dev' to be loaded.
If it is built-in into your kernel, you can safely skip this.
i2c-dev is not loaded. Do you want to load it now? (YES/no): yes
Module loaded succesfully.
We are now going to do the adapter probings. Some adapters may hang halfway
through; we can't really help that. Also, some chips will be double detected;
we choose the one with the highest confidence value in that case.
If you found that the adapter hung after probing a certain address, you can
specify that address to remain unprobed. That often
includes address 0x69 (clock chip).
Next adapter: SMBus Via Pro adapter at 5000
Do you want to scan it? (YES/no/selectively): yes
Client found at address 0x50
Probing for `SPD EEPROM'... Success!
(confidence 8, driver `eeprom')
Probing for `DDC monitor'... Failed!
Probing for `Maxim MAX6900'... Failed!
Client found at address 0x51
Probing for `SPD EEPROM'... Success!
(confidence 8, driver `eeprom')
Client found at address 0x52
Probing for `SPD EEPROM'... Success!
(confidence 8, driver `eeprom')
Client found at address 0x69
Some chips are also accessible through the ISA bus. ISA probes are
typically a bit more dangerous, as we have to write to I/O ports to do
this. This is usually safe though.
Do you want to scan the ISA bus? (YES/no): yes
Probing for `National Semiconductor LM78'
Trying address 0x0290... Failed!
Probing for `National Semiconductor LM78-J'
Trying address 0x0290... Failed!
Probing for `National Semiconductor LM79'
Trying address 0x0290... Failed!
Probing for `Winbond W83781D'
Trying address 0x0290... Failed!
Probing for `Winbond W83782D'
Trying address 0x0290... Failed!
Probing for `Winbond W83627HF'
Trying address 0x0290... Failed!
Probing for `Winbond W83627EHF'
Trying address 0x0290... Failed!
Probing for `Winbond W83697HF'
Trying address 0x0290... Failed!
Probing for `Silicon Integrated Systems SIS5595'
Trying general detect... Failed!
Probing for `VIA Technologies VT82C686 Integrated Sensors'
Trying general detect... Failed!
Probing for `VIA Technologies VT8231 Integrated Sensors'
Trying general detect... Failed!
Probing for `ITE IT8712F'
Trying address 0x0290... Failed!
Probing for `ITE IT8705F / SiS 950'
Trying address 0x0290... Failed!
Probing for `IPMI BMC KCS'
Trying address 0x0ca0... Failed!
Probing for `IPMI BMC SMIC'
Trying address 0x0ca8... Failed!
Some Super I/O chips may also contain sensors. Super I/O probes are
typically a bit more dangerous, as we have to write to I/O ports to do
this. This is usually safe though.
Do you want to scan for Super I/O sensors? (YES/no): yes
Probing for `ITE 8702F Super IO Sensors'
Failed! (skipping family)
Probing for `Nat. Semi. PC87351 Super IO Fan Sensors'
Failed! (skipping family)
Probing for `SMSC 47B27x Super IO Fan Sensors'
Failed! (skipping family)
Probing for `VT1211 Super IO Sensors'
Failed! (skipping family)
Probing for `Winbond W83627EHF/EHG Super IO Sensors'
Failed! (skipping family)
Do you want to scan for secondary Super I/O sensors? (YES/no): yes
Probing for `ITE 8702F Super IO Sensors'
Failed! (skipping family)
Probing for `Nat. Semi. PC87351 Super IO Fan Sensors'
Failed! (skipping family)
Probing for `SMSC 47B27x Super IO Fan Sensors'
Failed! (skipping family)
Probing for `VT1211 Super IO Sensors'
Failed! (skipping family)
Probing for `Winbond W83627EHF/EHG Super IO Sensors'
Failed! (skipping family)
Now follows a summary of the probes I have just done.
Just press ENTER to continue:
Driver `eeprom' (should be inserted):
Detects correctly:
* Bus `SMBus Via Pro adapter at 5000'
Busdriver `i2c-viapro', I2C address 0x50
Chip `SPD EEPROM' (confidence: 8)
* Bus `SMBus Via Pro adapter at 5000'
Busdriver `i2c-viapro', I2C address 0x51
Chip `SPD EEPROM' (confidence: 8)
* Bus `SMBus Via Pro adapter at 5000'
Busdriver `i2c-viapro', I2C address 0x52
Chip `SPD EEPROM' (confidence: 8)
I will now generate the commands needed to load the I2C modules.
Sometimes, a chip is available both through the ISA bus and an I2C bus.
ISA bus access is faster, but you need to load an additional driver module
for it. If you have the choice, do you want to use the ISA bus or the
I2C/SMBus (ISA/smbus)? isa
If you want to load the modules at startup, generate a config file
below and make sure lm_sensors gets started; e.g
$ rc-update add lm_sensors default.
To make the sensors modules behave correctly, add these lines to
/etc/modules.conf:
#----cut here----
# I2C module options
alias char-major-89 i2c-dev
#----end cut here----
WARNING! If you have some things built into your kernel, the list above
will contain too many modules. Skip the appropriate ones! You really should
try these commands right now to make sure everything is working properly.
Monitoring programs won't work until it's done.
To load everything that is needed, execute the commands above...
#----cut here----
# I2C adapter drivers
modprobe i2c-viapro
# I2C chip drivers
modprobe eeprom
# sleep 2 # optional
/usr/bin/sensors -s # recommended
Do you want to generate /etc/conf.d/lm_sensors? Enter s to specify other file name?
(YES/no/s): yes
Done.vt596_smbus 0000:00:07.3: using Interrupt SMI# for SMBus.
vt596_smbus 0000:00:07.3: SMBREV = 0x0
vt596_smbus 0000:00:07.3: VT596_smba = 0x5000
i2c_adapter i2c-0: registered as adapter #0
i2c-core: driver eeprom registered.
i2c_adapter i2c-0: found normal i2c entry for adapter 0, addr 50
i2c_adapter i2c-0: Transaction (pre): CNT=00, CMD=3f, ADD=a0, DAT0=06, DAT1=00
i2c_adapter i2c-0: SMBus busy (0x02). Resetting...
i2c_adapter i2c-0: Successfull!
i2c_adapter i2c-0: Transaction (post): CNT=00, CMD=3f, ADD=a0, DAT0=06, DAT1=00
i2c_adapter i2c-0: Transaction (pre): CNT=00, CMD=3f, ADD=a0, DAT0=06, DAT1=00
i2c_adapter i2c-0: Transaction (post): CNT=00, CMD=3f, ADD=a0, DAT0=06, DAT1=00
i2c_adapter i2c-0: client [eeprom] registered to adapter
registering 0-0050
i2c_adapter i2c-0: found normal i2c entry for adapter 0, addr 51
i2c_adapter i2c-0: Transaction (pre): CNT=00, CMD=3f, ADD=a2, DAT0=06, DAT1=00
i2c_adapter i2c-0: Transaction (post): CNT=00, CMD=3f, ADD=a2, DAT0=06, DAT1=00
i2c_adapter i2c-0: Transaction (pre): CNT=00, CMD=3f, ADD=a2, DAT0=06, DAT1=00
i2c_adapter i2c-0: Transaction (post): CNT=00, CMD=3f, ADD=a2, DAT0=06, DAT1=00
i2c_adapter i2c-0: client [eeprom] registered to adapter
registering 0-0051
i2c_adapter i2c-0: found normal i2c entry for adapter 0, addr 52
i2c_adapter i2c-0: Transaction (pre): CNT=00, CMD=3f, ADD=a4, DAT0=06, DAT1=00
i2c_adapter i2c-0: Transaction (post): CNT=00, CMD=3f, ADD=a4, DAT0=06, DAT1=00
i2c_adapter i2c-0: Transaction (pre): CNT=00, CMD=3f, ADD=a4, DAT0=06, DAT1=00
i2c_adapter i2c-0: Transaction (post): CNT=00, CMD=3f, ADD=a4, DAT0=06, DAT1=00
i2c_adapter i2c-0: client [eeprom] registered to adapter
registering 0-0052
i2c_adapter i2c-0: found normal i2c entry for adapter 0, addr 53
i2c_adapter i2c-0: Transaction (pre): CNT=00, CMD=3f, ADD=a6, DAT0=06, DAT1=00
i2c_adapter i2c-0: Error: no response!
i2c_adapter i2c-0: Transaction (post): CNT=00, CMD=3f, ADD=a6, DAT0=06, DAT1=00
i2c_adapter i2c-0: found normal i2c entry for adapter 0, addr 54
i2c_adapter i2c-0: Transaction (pre): CNT=00, CMD=3f, ADD=a8, DAT0=06, DAT1=00
i2c_adapter i2c-0: Error: no response!
i2c_adapter i2c-0: Transaction (post): CNT=00, CMD=3f, ADD=a8, DAT0=06, DAT1=00
i2c_adapter i2c-0: found normal i2c entry for adapter 0, addr 55
i2c_adapter i2c-0: Transaction (pre): CNT=00, CMD=3f, ADD=aa, DAT0=06, DAT1=00
i2c_adapter i2c-0: Error: no response!
i2c_adapter i2c-0: Transaction (post): CNT=00, CMD=3f, ADD=aa, DAT0=06, DAT1=00
i2c_adapter i2c-0: found normal i2c entry for adapter 0, addr 56
i2c_adapter i2c-0: Transaction (pre): CNT=00, CMD=3f, ADD=ac, DAT0=06, DAT1=00
i2c_adapter i2c-0: Error: no response!
i2c_adapter i2c-0: Transaction (post): CNT=00, CMD=3f, ADD=ac, DAT0=06, DAT1=00
i2c_adapter i2c-0: found normal i2c entry for adapter 0, addr 57
i2c_adapter i2c-0: Transaction (pre): CNT=00, CMD=3f, ADD=ae, DAT0=06, DAT1=00
i2c_adapter i2c-0: Error: no response!
i2c_adapter i2c-0: Transaction (post): CNT=00, CMD=3f, ADD=ae, DAT0=06, DAT1=00# lsmod
Module Size Used by
eeprom 5528 -
i2c_sensor 2984 -
i2c_viapro 7640 -
dm_mod 45340 -
* net-misc/ntp
Latest version available: 4.2.0.20040617-r3
Latest version installed: [ Not Installed ]
Size of downloaded files: 2,403 kB
Homepage: http://www.ntp.org/
Description: Network Time Protocol suite/programs
License: as-is
* net-misc/openntpd
Latest version available: 3.7_p1
Latest version installed: 3.7_p1
Size of downloaded files: 133 kB
Homepage: http://www.openntpd.org/
Description: Lightweight NTP server ported from OpenBSD
License: BSD
# hwclock --show
# zdump GMT
# zdump EST5EDT
# dateDec 19 21:33:10 localhost ntpd[5673]: adjusting local clock by -11.800044s
Dec 19 21:36:23 localhost ntpd[5673]: adjusting local clock by -11.691234s
Dec 19 21:39:36 localhost ntpd[5673]: adjusting local clock by -11.621488sLabels: NTP
1:35c
3:35c
CONFIG_HOTPLUG=y
2:36c
# CONFIG_HOTPLUG is not set
1:35c
3:35c
CONFIG_HOTPLUG=y
2:36c
# CONFIG_HOTPLUG is not set
1:61c
3:60c
# CONFIG_MODULE_FORCE_UNLOAD is not set
2:62c
CONFIG_MODULE_FORCE_UNLOAD=y
1:110c
3:102c
# CONFIG_SOFTWARE_SUSPEND is not set
2:120,121c
CONFIG_SOFTWARE_SUSPEND=y
CONFIG_PM_STD_PARTITION=""
1:211c
3:189c
# CONFIG_IA32_AOUT is not set
2:211c
CONFIG_IA32_AOUT=y
1:895c
3:613c
# CONFIG_NETCONSOLE is not set
2:591,595c
CONFIG_NETCONSOLE=y
CONFIG_NETPOLL=y
# CONFIG_NETPOLL_RX is not set
# CONFIG_NETPOLL_TRAP is not set
CONFIG_NET_POLL_CONTROLLER=y
1:1597c
3:1334c
# CONFIG_PROFILING is not set
2:1089,1090c
CONFIG_PROFILING=y
CONFIG_OPROFILE=y
livecd / # dmesg
Bootdata ok (command line is initrd=gentoo.igz root=/dev/ram0 init=/linuxrc looptype=squashfs loop=/livecd.squashfs udev nodevfs dokeymap cdroot vga=791 splash=silent,theme:livecd-2005.1 CONSOLE=/dev/tty1 quiet BOOT_IMAGE=gentoo )
Linux version 2.6.12-gentoo-r6 (root@poseidon) (gcc version 3.4.3 20041125 (Gentoo 3.4.3-r1, ssp-3.4.3-0, pie-8.7.7)) #1 SMP Mon Aug 1 14:22:17 UTC 2005
(snip)livecd ~ # cat /proc/partitions
major minor #blocks name
7 0 49712 loop0
33 0 292970160 hde - 300GB 5400rpm PATA (PDC20269)
34 0 292970160 hdg - 300GB 5400rpm PATA (PDC20269)
57 0 292970160 hdk - 300GB 5400rpm PATA (HPT302)
89 0 292970160 hdo - 300GB 5400rpm PATA (HPT302)
91 0 292970160 hds - 300GB 5400rpm PATA (HPT302)
3 0 293057352 hda - 300GB 7200rpm PATA (motherboard primary IDE)
8 0 293057352 sda - 300GB 7200rpm PATA (PDC20378 m/b)
8 16 199148544 sdb - 200GB 7200rpm SATA (m/b SATA)
livecd ~ ## cat /proc/config.gz | gzip -d | lessnogitsune linux # diff /boot/config-2.6.13-8Nov2005 /boot/config-2.6.13-9Nov2005
4c4
< # Tue Nov 8 18:19:03 2005
---
> # Wed Nov 9 05:13:43 2005
416c416
< # CONFIG_CHR_DEV_SG is not set
---
> CONFIG_CHR_DEV_SG=y
456c456
< # CONFIG_SCSI_SATA_PROMISE is not set
---
> CONFIG_SCSI_SATA_PROMISE=y
nogitsune linux #livecd ~ # modprobe md
livecd ~ # modprobe dm-mod
livecd ~ # modprobe raid1
livecd ~ # for i in 0 1 2 3; do mknod /dev/md$i b 9 $i; done
livecd ~ # swapon /dev/md1
swapon: /dev/md1: Invalid argument
livecd ~ # mdadm --assemble /dev/md0 /dev/hda1 /dev/sda1
mdadm: /dev/md0 has been started with 2 drives.
livecd ~ # mdadm --assemble /dev/md1 /dev/hda2 /dev/sda2
mdadm: /dev/md1 has been started with 2 drives.
livecd ~ # mdadm --assemble /dev/md2 /dev/hda3 /dev/sda3
mdadm: /dev/md2 has been started with 2 drives.
livecd ~ # mdadm --assemble /dev/md3 /dev/hda4 /dev/sda4
mdadm: /dev/md3 has been started with 1 drive (out of 2) and 1 spare.
livecd ~ # swapon /dev/md1
livecd ~ # mount /dev/md2 /mnt/gentoo
livecd ~ # mount /dev/md0 /mnt/gentoo/boot
livecd ~ # vgchange -ay vgmirror
6 logical volume(s) in volume group "vgmirror" now active
livecd ~ # mount /dev/vgmirror/opt /mnt/gentoo/opt
livecd ~ # mount /dev/vgmirror/usr /mnt/gentoo/usr
livecd ~ # mount /dev/vgmirror/var /mnt/gentoo/var
livecd ~ # mount /dev/vgmirror/home /mnt/gentoo/home
livecd ~ # mount /dev/vgmirror/tmp /mnt/gentoo/tmp
livecd ~ # chmod 1777 /mnt/gentoo/tmp
livecd ~ # mount /dev/vgmirror/vartmp /mnt/gentoo/var/tmp
livecd ~ # chmod 1777 /mnt/gentoo/var/tmp
livecd ~ # mount -t proc none /mnt/gentoo/proc
livecd ~ # chroot /mnt/gentoo /bin/bash
livecd / # env-update
>>> Regenerating /etc/ld.so.cache...
livecd / # source /etc/profilelivecd linux # cat /proc/modules
raid1 14720 4 - Live 0xffffffff880f9000
md 36480 5 raid1, Live 0xffffffff880ef000
ipv6 212928 10 - Live 0xffffffff880ba000
floppy 52824 0 - Live 0xffffffff880ac000
pcspkr 4056 0 - Live 0xffffffff880aa000
skge 30224 0 - Live 0xffffffff880a1000
dm_mod 39264 7 - Live 0xffffffff88096000
ata_piix 7812 0 - Live 0xffffffff88093000
ahci 9348 0 - Live 0xffffffff8808f000
sata_qstor 8068 0 - Live 0xffffffff8808c000
sata_vsc 6788 0 - Live 0xffffffff88089000
sata_uli 6144 0 - Live 0xffffffff88086000
sata_sis 5888 0 - Live 0xffffffff88083000
sata_sx4 11396 0 - Live 0xffffffff8807f000
sata_nv 7556 0 - Live 0xffffffff8807c000
sata_via 7172 0 - Live 0xffffffff88079000
sata_svw 6404 0 - Live 0xffffffff88076000
sata_sil 7940 0 - Live 0xffffffff88073000
sata_promise 9092 4 - Live 0xffffffff8806f000
libata 30856 12 ata_piix,ahci,sata_qstor,sata_vsc,sata_uli,sata_sis,sata_sx4,sata_nv,sata_via,sata_svw,sata_sil,sata_promise, Live 0xffffffff88066000
sbp2 19080 0 - Live 0xffffffff88060000
ohci1394 27596 0 - Live 0xffffffff88058000
ieee1394 63096 2 sbp2,ohci1394, Live 0xffffffff88047000
sl811_hcd 11392 0 - Live 0xffffffff88043000
ohci_hcd 17156 0 - Live 0xffffffff8803d000
uhci_hcd 26528 0 - Live 0xffffffff88035000
usb_storage 55616 0 - Live 0xffffffff88026000
usbhid 27680 0 - Live 0xffffffff8801e000
ehci_hcd 25864 0 - Live 0xffffffff88016000
usbcore 86008 7 sl811_hcd,ohci_hcd,uhci_hcd,usb_storage,usbhid,ehci_hcd, Live 0xffffffff88000000
livecd linux #
Losing some ticks... checking if CPU frequency changed.
kjournald starting. Commit interval 5 seconds
EXT3 FS on dm-2, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
kjournald starting. Commit interval 5 seconds
EXT3 FS on dm-3, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
kjournald starting. Commit interval 5 seconds
EXT3 FS on dm-4, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
kjournald starting. Commit interval 5 seconds
EXT3 FS on dm-5, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
skge eth0: enabling interface
skge eth0: Link is up at 1000 Mbps, full duplex, flow control tx and rx
eth0: no IPv6 routers present
warning: many lost ticks.
Your time source seems to be instable or some driver is hogging interupts
rip __do_softirq+0x48/0xb0# emerge mdadm
# emerge lvm2
# cd /usr/src/linux
# make menuconfig# make && make modules_install# mount /boot
# ls -l /boot
# ls -l arch/x86_64/boot
# df
# cp arch/x86_64/boot/bzImage /boot/kernel-2.6.13-9Nov2005
# cp System.map /boot/System.map-2.6.13-9Nov2005
# cp .config /boot/config-2.6.13-9Nov2005
# ls -l /boot
# nano -w /boot/grub/grub.confwarning: many lost ticks.
Your time source seems to be instable or some driver is hogging interupts
rip __do_softirq+0x48/0xb0# cd /usr/src/linux
# find . -print | xargs grep -i 'hpt302'
# grep -i 'hpt366' .configkernel BUG at <bad filename>:55433!
Invalid operand: 0000 [#1]
PREEMPT SMP
Modules linked in: ...
(bunch of registers)
Process swapper (pid: 0 ...
(trace dump)
<0> Kernel panic - not syncing: Fatal exception in interruptlivecd ~ # cat /proc/partitions
major minor #blocks name
7 0 49712 loop0
33 0 292970160 hde
34 0 292970160 hdg
57 0 292970160 hdk
89 0 292970160 hdo
91 0 292970160 hds
3 0 293057352 hda
8 0 293057352 sda
8 16 199148544 sdb
livecd ~ #