WARNING: This is the _old_ Lustre wiki, and it is in the process of being retired. The information found here is all likely to be out of date. Please search the new wiki for more up to date information.

Netconsole: Difference between revisions

From Obsolete Lustre Wiki
Jump to navigationJump to search
No edit summary
No edit summary
 
(15 intermediate revisions by one other user not shown)
Line 1: Line 1:
= Netconsole with UDP =
<small>''(Updated: Nov 2009)''</small>


* Configuring netconsole on the 2.6 kernel
''Netconsole'' supports kernel-level network logging over UDP. A system request (''SysRq'') allows users to collect relevant data through ''netconsole''.
** 1) add this line "netconsole=[src-port]@[src-ip]/[<dev>],[tgt-port]@<tgt-ip>/[tgt-macaddr]" in your boot command line.
** 2) bootup the netconsole machine.
** 3) 2.6 netconsole has been setup.
* Configure conman over netconsole, download conman from ftp://www.clusterfs.com/pub/conman
** 1) edit your /etc/conman.conf, make sure you have set SERVER logdir,  SERVER logfile, SERVER port,
*** add following line in /etc/conman.conf
*** NETCONSOLE name="netconsole" dev="client1_ip_address:client1_port" (clientX is netconsole machine)
*** NETCONSOLE1 name="netconsole" dev="client2_ip_address:client2_port"
*** ............
** 2) start conmand server conmand
** 3) start conman netconsole with conman -d conmand_server_ip:conmand_server_port  NETCONSOLEx
** 4) Input sysrq command (& + S + sysrq_command) over conman netconsole, you will get the result in conman netconsole


To configure ''netconsole'' on the 2.6 kernel, complete the following steps.


1. Add the following line to your boot command:
netconsole=[src-port]@[src-ip]/[<dev>],[tgt-port]@<tgt-ip>/[tgt-macaddr]


There is a ''netconsole patch'' available that supports kernel level network logging over UDP. More information and a link to the kernel patches can be found at: [http://lwn.net/2001/0927/a/netconsole.php3].
Command options:


----
:{|
*'''LinuxDebugging'''
|src-port||Source for UDP packets (defaults to 6665)
|-
|src-ip||Source IP to use (interface address)
|-
|dev||Network interface (eth0)
|-
|tgt-port||Port for logging agent (6666)
|-
|tgt-ip||IP address for logging agent
|-
|tgt-macaddr||Ethernet MAC address for logging agent (broadcast)
|}
 
Examples:
 
linux netconsole=4444@10.0.0.1/eth1,9353@10.0.0.2/12:34:56:78:9a:bc
 
or
 
insmod netconsole netconsole=4444@10.0.0.1/eth1,9353@10.0.0.2/12:34:56:78:9a:bc
 
2. Boot the ''netconsole'' machine.
 
 
To configure ''conman'' over ''netconsole'', complete the following steps.
 
1. Download ''conman'' from [http://home.gna.org/conman/ http://home.gna.org/conman/]
 
2. Edit ''/etc/conman.conf'' to set the ''SERVER logdir'', ''SERVER logfile'', and ''SERVER port''.
 
3. Add the following to ''/etc/conman.conf'', where ''clientX'' is the netconsole machine:
<pre>
NETCONSOLE name="netconsole" dev="client1_ip_address:client1_port"
NETCONSOLE1 name="netconsole" dev="client2_ip_address:client2_port"
............
</pre>
 
4.Start the ''conmand'' server by entering
conmand
 
5. Start the ''conman'' netconsole by entering:
conman -d conmand_server_ip:conmand_server_port NETCONSOLEx
 
6. To see results in the ''conman'' netconsole, enter the ''sysrq'' command inside the ''conman'' console (enter "&", then "S", and then the ''sysrq'' command).
 
'''''Note:''''' A ''netconsole patch'' is available that supports kernel level network logging over UDP. More information and a link to the kernel patches can be found at: [http://lwn.net/2001/0927/a/netconsole.php3 http://lwn.net/2001/0927/a/netconsole.php3].

Latest revision as of 10:52, 22 February 2010

(Updated: Nov 2009)

Netconsole supports kernel-level network logging over UDP. A system request (SysRq) allows users to collect relevant data through netconsole.

To configure netconsole on the 2.6 kernel, complete the following steps.

1. Add the following line to your boot command:

netconsole=[src-port]@[src-ip]/[<dev>],[tgt-port]@<tgt-ip>/[tgt-macaddr]

Command options:

src-port Source for UDP packets (defaults to 6665)
src-ip Source IP to use (interface address)
dev Network interface (eth0)
tgt-port Port for logging agent (6666)
tgt-ip IP address for logging agent
tgt-macaddr Ethernet MAC address for logging agent (broadcast)

Examples:

linux netconsole=4444@10.0.0.1/eth1,9353@10.0.0.2/12:34:56:78:9a:bc

or

insmod netconsole netconsole=4444@10.0.0.1/eth1,9353@10.0.0.2/12:34:56:78:9a:bc

2. Boot the netconsole machine.


To configure conman over netconsole, complete the following steps.

1. Download conman from http://home.gna.org/conman/

2. Edit /etc/conman.conf to set the SERVER logdir, SERVER logfile, and SERVER port.

3. Add the following to /etc/conman.conf, where clientX is the netconsole machine:

NETCONSOLE name="netconsole" dev="client1_ip_address:client1_port"
NETCONSOLE1 name="netconsole" dev="client2_ip_address:client2_port"
............

4.Start the conmand server by entering

conmand

5. Start the conman netconsole by entering:

conman -d conmand_server_ip:conmand_server_port NETCONSOLEx

6. To see results in the conman netconsole, enter the sysrq command inside the conman console (enter "&", then "S", and then the sysrq command).

Note: A netconsole patch is available that supports kernel level network logging over UDP. More information and a link to the kernel patches can be found at: http://lwn.net/2001/0927/a/netconsole.php3.