Netdump server Construction

Source: Internet
Author: User
Netdump server construction-Linux Enterprise Application-Linux server application information. The following is a detailed description. NetDump is the result of a client-server. If you need to use NetDump, you must configure it on the server and client at the same time.
The configuration is also relatively simple, probably because of a small amount of use, so there are few such documents. Linux Netdump
Windows Dump is similar, that is, when the kernel crashes, the content in the memory is stored in a file for the Troubleshooting
Analysis. Windows is a windows directory in the system partition and is named by the Memory. dmp command. In Unix, crash occurs in kernel.
Stored in the SWAP partition, so in another article about memory, one of my colleagues thinks that SWAP must be larger than the memory (in UNIX ).
In Linux, a central server provides netdump to all servers of an enterprise, just like a syslog server. Netdump has two functions. One is that the Client dumps its memory dump to the server through UDP during the Kernel Crash process. This is called netdump.
The other is to send the information on the console to the syslog server. This is called netsole, because some emails are displayed on the screen when there is a problem with the kernel. If the administrator cannot access the server, check the syslog server to view the information displayed on the console. This function is called netsole. The service of this function depends on the syslogd function.

The following is a summary.
1. RPM
Client netdump-x-x-x.rpm
Netdump-server-x-x-x.rpm
2. Configuration
Server:
For netdump
(1) Verify enough free space in/var/crash for memory dump.
(2) Set the password for user netdump.
(3) Enable sshd service.
# Service sshd start
(4) Enable netdump-server service.
# Service netdump-server start
# Chkconfig -- level 345 netdump-server on
For Netconsole need a remote syslog server.
Add the-r option to SYSLOGD_OPTIONS in/etc/sysconfig/syslog

Client:
(1) configure file
The main client-side configuration file is/etc/sysconfig/netdump
-SYSLOGADDR for netconsole
-NETDUMPADDR for netdump
For example:
NETDUMPADDR = 192.168.0.3
SYSLOGMACADDR = 192.168.0.3
(2) copy DSA public key to server netdump user, for dump the memory to the server by sshd without prompt password.
Run the comand "# service netdump propagate" on the client, This will copy the 64-session key/etc/sysconfig/netdump_id_dsa.pub to the server/var/crash/. ssh/authorized_key2.
(3) Start netdump service.
# Service netdump start
# Chkconfig -- level 345 netdump on
Examine the log file/var/log/message to verify theat network card is supported.

3. The netdump Protocol
On client startup:
Copy the 64-bit session cookie to netdump server by ssh.
Send netdump start message to server.
On client crash:
Client sends kernel crash message to server.
Server get the memory dump and crash signature from clietn.
When the transfer compleses, the client sends a "netdump reboot" message to server and reboot.
BTW, a 4 GB memroy over 100 M ethernet shocould take about five minutes.
The crash file in/var/crash/Clietn_IP_address $ Date $ time.

5. Testing
Compile the crash. c program in the/usr/share/doc/netdump-0 .*.*
Gcc-DKERNEL-DMODULE-I/lib/modules/$ (uname-r)/build/include-c crash. c
Insmod./crash. o
If everythink is working, the client shoshould crash, pause for a short delay to dump memory, and then reboot.
See the folder/var/crash on the server.

--------------------------------------------------------------------------------

Hello, I encountered a Problem When configuring netdump. The client always sends "netdump start, waiting for start-ACK" to NETDUMP-server"
The server did not respond. How can this problem be solved? Thank you.
Understand why, because this step is missing
"Copy the 64-bit session cookie to netdump server by ssh ."
I did not notice that this step is automatic in school, but I deleted the/var/crash/magic directory on the server, so the execution will fail,
In addition, if you delete this directory, you can create one by yourself, but pay attention to the owner and permissions, You can rename this directory to allow all users to operate chmod 777 magic, or change the directory owner to netdump.
Otherwise, a message is displayed.
Bash: line 1:/var/crash/magic/211.160.75.104: No such file or directory Error
Or
Bash: line 1:/var/crash/magic/211.160.75.104: Permission denied Error
This is mainly because "ssh-x-I/etc/sysconfig/netdump_id_dsa netdump @ $ NETDUMPADDR echo" $ MAGIC2 $ MAGIC1 "\>/var/crash/magic/$ LOCALADDR "of

Follow the steps above.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.