CENTOS7 View Port command

Source: Internet
Author: User
Tags nameserver


# NETSTAT-LNTP #查看监听 (Listen) port
# NETSTAT-ANTP #查看所有建立的TCP连接
Other about View server Network Information command:
1. View the Linux system hostname: Linux learning,/HTTP/linux.it.net.cn
# hostname
Localhost.localdomain
2. View server IP Address:
# ifconfig|grep ' inet addr: ' |grep-v ' 127.0.0.1 ' |cut-d:-f2|awk ' {print '} '
192.168.17.238
192.168.1.9
3. View the Linux gateway:
# route |grep Default
Default 192.168.1.1 0.0.0.0 UG 0 0 0 em1
4. View Linux Open service:
# chkconfig--list|grep Enable #查看开启的服务
sshd 0: Off 1: Off 2: Enable 3: Enable 4: Enable 5: Enable 6: Off
httpd 0: Off 1: Off 2: Off 3: Enabled 4: Off 5: off 6: Off
5. View Server DNS configuration:
# cat/etc/resolv.conf
NameServer 192.168.0.66
NameServer 202.106.0.20
6. Other Network information:
# iptables-l #查看防火墙规则
# route-n #查看路由表
# netstat-s #查看网络统计信息

CENTOS7 View Port command

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.