Common centos commands

Source: Internet
Author: User

Net table fireproof ROC iptable no information USB computer name

1. First, check the processes running by the system. If you need to check all processes currently running by the system,

Run the following command: # ps auxw

The parameter A shows the processes of all users in the system, the user information of the output process, and the process without the console; if the displayed row is truncated because it is too long, the F parameter can be used;

2. view the services monitored by the System

# Netstat-ln L indicates to display the port information of the current system listener; n indicates to display the port according to the port number without converting it to the port name defined in the service file; if you want to know which processes listen on each port, you can use the p parameter. If you find unnecessary services, you can use the linuxconf or ntsysv command to disable these services from starting when the system is started, and then restart the system, the services will be running. Some services are monitored by the inetd super server. You need to mark/etc/inetd. conf to disable these services. System # uname-A # view kernel/operating system/CPU information # Head-N 1/etc/issue # view operating system version # Cat/proc/cpuinfo # view CPU information # hostname # View computer name # lspci-TV # list all PCI devices # lsusb-TV # list all USB devices # lsmod # list loaded kernel modules # env # view environment variable resources # Free- M # view memory usage and swap zone usage # DF-h # view the usage of each partition # Du-SH <Directory Name> # view the size of a specified directory # grep memtotal/proc/meminfo # view the total memory # grep memfree/proc/meminfo # view the Amount of idle memory # uptime # view the system running time, number of users, and load # Cat/proc/loadavg # Viewing system load disks and partitions # Mount | column-T # viewing the status of mounted partitions # fdisk-L # viewing all partitions # Swapon-s # viewing all swap partitions # hdparm-I /dev/hda # view disk parameters (only applicable to ide devices) # dmesg | grep ide # view the IDE Device Detection Status at startup Network # ifconfig # view the attributes of all network interfaces # iptables-L # view firewall settings # route-N # view route table # netstat -lntp # view all listening ports # netstat-antp # view all established connections # netstat-s # view network statistics process # ps-Ef # view all processes # top # Real-Time display Process status user # W # view active users # id <User Name> # view specified user information # La St # view User Logon logs # P # page title # e # Cut-D:-F1/etc/passwd # view all users in the system # Cut-D: -F1/etc/group # view all system groups # crontab-L # view the scheduled Task Service of the current user # chkconfig-list # list all system services # chkconfig-list | grep on # list all started system service programs # rpm-Qa # view all installed software packages original from [Happy Onion] link: http://www.75271.com/1787.html Source: Happy onion copyright owned by the author. For commercial reprint, please contact the author for authorization. For non-commercial reprint, please indicate the source.

common centos commands

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.