Version 8 (modified by admin, 3 years ago)

--

Usage

ssh -A root@hosting8.rennes.tld
for i in 8 9 10 11 12 13 14 15 16 17 ; do ipmitool -H 10.5.25.$i -I lan -P "" -l admin power status | sed -e "s/^/$i: /" ; done
8: Chassis Power is on
9: Chassis Power is off
10: Chassis Power is on
11: Chassis Power is on
12: Chassis Power is on
13: Chassis Power is on
14: Chassis Power is on
15: Chassis Power is on
16: Chassis Power is on
17: Chassis Power is on

config

* IP : 10.5.25.0/24 for rennes

The config may not work if the Service Manager has not been reseted before.

configure command host

On each host of the lan that needs to access the IPMI add the following line to /etc/network/interfaces

post-up ip addr add 10.5.25.112/24 dev xen-br0

Assuming 10.5.25.112 is an IP that is not already used.

configure lan

If the lan parameters aren't configured, you can configure them from host.

apt-get install ipmitool openipmi
modprobe ipmi_si
modprobe ipmi_devintf
#you need to reset the ip config
ipmitool lan set 1 ipsrc none
ipmitool lan set 1 ipsrc dhcp
#Here your ip should be set to 0.0.0.0
ipmitool lan print
ipmitool lan set 1 ipsrc static
ipmitool lan set 1 ipaddr 10.5.25.13
ipmitool lan set 1  defgw ipaddr 10.5.25.1
ipmitool lan set 1  netmask 255.255.255.0

From the gateway (rennes.tld) :

enable initial access

ssh -l setup 10.5.25.X

And follow steps

  • user : admin
  • password : ror8OmEf

Once the user has been created, the setup user is locked

enable lan

ssh -l admin 10.5.25.X ipmi enable channel lan

It will ask for the admin's password first, then for the LAN password (will ask twice), leave it empty.

To check it's ok, try to query ipmi using the lan interface :

ipmitool -H 10.5.25.X -I lan -P "" -l admin lan print

configure Serial over lan

  • on the host :
    • edit /etc/inittab
    • check you have :
      T0:23:respawn:/sbin/getty -L ttyS0 9600 vt102
      
    • use "init q" to reload inittab without reboot.
  • Then, using ipmi :
    ssh -l admin 10.5.25.X platform set console -s sp -e -S 9600
    

To use it :

ssh -l admin 10.5.25.X platform console

It will prompt you for admin password, then display something like :

[no, admin@localhost.localdomain is attached]

To log on the serial console, press ctrl+E,c,a,enter, which should show you the console login prompt :

[Enter `^Ec?' for help]
^Eca
[ok]

Debian GNU/Linux squeeze/sid hosting9.rennes.tld ttyS0

hosting9.rennes.tld login:

If it does not work try ctrl-E,c,f,enter (to force attach read/write).

hosting12:~# ip=$(getent hosts $(hostname) | cut -f1 -d' ' | cut -f4 -d.)
hosting12:~# ssh -l admin 10.5.25.$ip
admin@10.5.25.12's password: 

Sun Microsystems
IPMI v2.0 Service Processor

Version:  V2.4.0.6
localhost $ platform console
[Enter `^Ec?' for help]
[no, admin@localhost.localdomain is attached]
^Ecf
[bumped admin@localhost.localdomain]

Debian GNU/Linux squeeze/sid hosting12 ttyS0

hosting12 login: 

grub

To be able to have the console during the boot, you need to add :

console=ttyS0,9600n81r

At the end of the "kopt" line of menu.lst, then update-grub.

Attachments