System Monitoring: linux System Monitoring command details

Source: Internet
Author: User
Tags mysql commands

Most linux releases are equipped with a large number of monitoring tools. These tools provide a measure for obtaining relevant information and system activities. The following is a detailed description of linux system monitoring commands, hoping to help you with linux system monitoring.
I. Preparations for linux System Monitoring
You can verify whether the rstatd daemon is configured on the server in two ways:
① Use the rup command to report various statistical information of the computer, including the configuration information of rstatd. Run the command rup10.130.61.203. 10.130.61.203 is the Ip address of the linux/Unix server to be monitored. If this command returns relevant statistics. The rstatd daemon has been configured and activated. If no meaningful statistical information is returned or an error report is displayed, the rstatd daemon has not been configured or has problems.
② Use the find command
# Find/-namerpc. rstatd, which is used to find whether the rpc. rstatd file exists in the system. If no, the rstatd daemon is installed.
Sources. This is a source code that needs to be compiled. You can download and install rstatd at http://sourceforge.net/projects/rstatd)
After the download, start the installation. The installation steps are as follows:
Tar-xzvfrpc.rstatd-4.0.1.tar.gz
Cdrpc, rstatd-4.0.1/
./Configure-configuration operation
Make-compile
Makeinstall-start Installation
Rpc. rstatd-start the rstatd Process

2. After linux system monitoring is installed, configure the rstatd target daemon xinetd. Its main configuration file is/etc/xinetd. conf, which contains the following basic information:
#
# Xinetd. conf
#
# Copyright (c) 1998-2001SuSEGmbHNuernberg, Germany.
# Copyright (c) 2002 SuSELinuxAG, Nuernberg, Germany.
#
Ults
{
Log_type = FILE/var/log/xinetd. log
Log_on_success = HOSTEXITDURATION
Log_on_failure = HOSTATTEMPT
# Only_from = localhost
Instances = 30
Cps = 5010
#
# Thespecificationofaninterfaceisinteresting, ifweareonafirewall.
# Forexample, ifyouonlywanttoprovideservicesfromaninternal
# Networkinterface, youmayspecifyyourinternalinterfacesIP-Address.
#
# Interface = 127.0.0.1
}
Includedir/etc/xinetd. d

Here we need to modify/etc/xinetd. the three conf files rlogin, rsh, and rexec under d, change disable = yes in the three files to disable = no (disabled is used in the default {} to disable the service) or set # default: when xinetd is started, the above three services are started by default!
Note: When I configure it myself, if no disable = yes, I will change # default: off To: default: on. After restarting (cd/etc/init. d /. /xinetdrestart) is viewed through netstat-an | grep514 and no result is returned. Then, I manually add disable = no to the last row of the three files, restart xinetd, and use netstat-an | grep514 to view the result of tcp000.0.0.0: 5140.0.0.0: * LISTEN, indicates that the rsh server has been started.

You only need to ensure that the processes on the Linux machine contain the rstatd and xinetd services and you can use LR to monitor them.
Two tips:
① Check whether the rshserver is enabled. The TCP listening speed of the rshserver is 514.
[Root @ mg04root] # netstat-an | grep514
Tcp000.0.0.0: 5140.0.0.0: * LISTEN
If 514 is displayed, the rsh server has been started.
② Check whether it is started: rstatd
Enter the command: rpcinfo-p
If the following information is displayed:
Program version protocol port
201715udp937rstatd
201714udp937rstatd
1000013udp937rstatd
201712udp937rstatd
201711udp937rstatd
It indicates that the rstatd service has been started. (psax can also be used here)
③ Method for restarting xinetd:
Perform the following operations on suselinux:
Cd/etc/init. d/
./Xinetdrestart
The following command is used in some places on the Internet:
# Servicexinetdreload
#/Sbin/servicexinetdrstart
I don't know what system is used.
④ How to install rsh and rsh-server service packages
A. Uninstall rsh
# Rpm-qrsh ---------- view version number
# Rpm-e version --------- Uninstall this version.
B. Installation
# Rpm-ivhrsh-0.17-14.i386.rpmrsh-server-0.17-14.i386.rpm
⑤ When rpc. rstatd is started, "Cannotregisterservice: RPC: Unabletoreceive; errno = Ctionrefused" is returned ".
The solution is as follows:
#/Etc/init. d./portmapstart
#/Etc/init. d./nfsstart
Then start rpc. rstatd again.

Finally, in the controller, Drag and Drop UNIXresources to the right window, right-click and select AddMeasurements, add the IP address of the monitored linux, and then select the metric to be monitored for the entire system monitoring: linux system monitoring is complete.

  1. Correct application of linux MySQL commands
  2. In Linux, apache + svn + ssl works perfectly together to build a secure Version Control Platform
  3. How to configure apache + svn + ssl in Linux
  4. Full guidance on SVN + Apache + SSL installation and configuration in Linux
  5. Comparison of Three solutions for installing MySQL in Linux

Related Article

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.