In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article shows you how to view a variety of service information in CentOS, the content is concise and easy to understand, it will definitely brighten your eyes. I hope you can get something through the detailed introduction of this article.
View server CPU model
Grep "model name" / proc/cpuinfo | cut-f2-d:
View server memory capacity
Grep MemTotal / proc/meminfo
Grep MemTotal / proc/meminfo | cut-f2-d:
Free-m | grep "Mem" | awk'{print $2}'
Check whether the server's CPU is 32-bit or 64-bit.
Getconf LONG_BIT
View the current version of Linux
More / etc/redhat-release cat / etc/redhat-release
View the Linux kernel version
Uname-r
Uname-a
View the server's current time
Date
View server hard drives and partitions
Df-h
Fdisk-l
View directory siz
Du / etc-sh
View the software packages initially installed by the server
Cat-n / root/install.log
More / root/install.log | wc-l
View installed software packages
Rpm-qa
Rpm-qa | wc-l
Yum list installed | wc-l
View the server keyboard layout
Cat / etc/sysconfig/keyboard
Cat / etc/sysconfig/keyboard | grep KEYTABLE | cut-f2-d =
View Selinux status
Sestatus
Sestatus | cut-f2-d:
Cat / etc/sysconfig/selinux
View the ip,Mac address of the server network card
You can see mac, gateway and other information in the ifcfg-eth0 file.
Ifconfig
Cat / etc/sysconfig/network-scripts/ifcfg-eth0 | grep IPADDR
Cat / etc/sysconfig/network-scripts/ifcfg-eth0 | grep IPADDR | cut-f2-d =
Ifconfig eth0 | grep "inet addr:" | awk'{print $2}'| cut-c 6-
Ifconfig | grep 'inet addr:' | grep-v' 127.0.0.1' | cut-d:-f2 | awk'{print $1}'
View server default gateway
Cat / etc/sysconfig/network
View the default DNS of the server
Cat / etc/resolv.conf
View server default language
Echo $LANG $LANGUAGE
Cat / etc/sysconfig/i18n
View the time zone and UTC time of the server
Cat / etc/sysconfig/clock
View server hostname
Hostname
Cat / etc/sysconfig/network
The above is how to view all kinds of service information in CentOS. Have you learned any knowledge or skills? If you want to learn more skills or enrich your knowledge reserve, you are welcome to follow the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.