Linux server hardware check and file transfer

Source: Internet
Author: User
Tags scp command dmesg
Linux server hardware check and file transfer-Linux Enterprise Application-Linux server application information. The following is a detailed description. Recently, I want to check the server. I want to check the information and package all the files to a master server for batch processing.

Let's take a look at how to handle the relevant content:
Command for viewing hardware information: linux:
Memory: cat/proc/meminfo
Cpu: cat/proc/cpuinfo
Hard Disk: df-h-T (no device is visible)
Fdisk-l can be viewed in redhat9.0; redhat Enterprise Edition does not work.
Solaris:
Nic speed: dmesg | grep link
CPU frequency: psrinfo-v or mpstat
Cpu/memory, etc.: prtdiag-v (most of the information is listed) needs to first enter/usr/platform/sun4u/sbin
Hard Disk: iostat-E

There are several commands in linux to view the information of many hardware devices.
Lspci-v
Dmidecode
Dmesg

For more information about file transfer methods, see:
There are three common methods to copy files between different Linux systems. The first method is ftp, that is, installing the ftp Server on one of the Linux systems, in this way, another ftp client program can be used to copy files. The second method is to use the samba service, similar to the Windows file copy method, which is simple and convenient. The third method is to use the scp command to copy files.

Scp is a file copy with Security and is used for ssh logon. For example, to copy the current file to another remote host, you can run the following command.

Scp/home/daisy/full.tar.gz root@172.19.2.75:/home/root

Then, you will be prompted to enter the logon password of the root user of the other 172.19.2.75 host, and copy the password.

If you want to copy files from the remote host to the current system, it is also very easy.

Root@172.19.2.75 scp:/home/root/home/daisy/full.tar.gz

The hard disk information can be as follows:
Df-h-T>/root/info/hd.txt

The memory can be as follows:
Cat/proc/meminfo>/root/info/mem.txt

Then copy the startup script to perform the check:
Cp/etc/rc. local/root/info/mem.txt

Copy the scheduled task script to perform the check:
Cp/etc/crontab/root/info/crontab.txt

Check the current program list:
Top-n1>/root/info/top.txt

You can also put it in a folder for checking.
Then package:
Tar cvfz info.tar.gz./info

Transfer to the server:
Scp/root/info.tar.gz root @ target_server:/home/root

Finally, there are several statements:
QUOTE:
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.