My favorites | Sign in
Project Home Downloads Wiki Issues Source
Checkout   Browse   Changes    
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
#!/bin/bash -
#=======================================================================
#
# FILE: netconsole_devel_set.sh
# USAGE: ./netconsole_devel_set.sh <ip>
# DESCRIPTION: Set netconsole on development machine
# REQUIREMENTS: netconsole
# BUGS: N/A
# NOTES: N/A
# AUTHOR: Ali Ayoub
# EMAIL: ali@mellanox.com
# COMPANY: N/A
# CREATED: 09.17.2010-15:24:52
# REVISION: 1.1
#=======================================================================

USAGE="Usage: $0 <monitor-server-ip>"
EXAMPLE="Example: $0 10.20.1.20"

if [ $# != 1 ]; then
echo $USAGE
echo $EXAMPLE
exit 1
fi


ip=$1

egrep -v '^$|^#|SYSLOGADDR=' /etc/sysconfig/netconsole > /etc/sysconfig/netconsole.new
echo "SYSLOGADDR=$ip" >> /etc/sysconfig/netconsole.new
\cp /etc/sysconfig/netconsole /etc/sysconfig/netconsole.orig
\mv /etc/sysconfig/netconsole.new /etc/sysconfig/netconsole

dmesg -n 8
chkconfig netconsole on
/etc/init.d/netconsole restart
rc=$?
echo "-I- Done [$rc]."
exit $rc

rmmod netconsole
insmod /lib/modules/2.6.32.21-15xen/kernel/drivers/net/netconsole.ko netconsole=6666@10.20.4.153/eth1,514@10.20.1.20/00:30:48:7D:DE:E4
dmesg -n 8
rmmod tun
modprobe tun

Change log

r23 by aliayoub on Sep 14, 2011   Diff
scripts: bugfixes
Go to: 
Project members, sign in to write a code review

Older revisions

r3 by Ali.Ayoub on Sep 17, 2010   Diff
add netconsole scripts
All revisions of this file

File info

Size: 1217 bytes, 46 lines

File properties

svn:executable
*
Powered by Google Project Hosting