Getting Started with Linux Basics (iii)

Source: Internet
Author: User


1. Look at the type of shell you are using:

[Email protected] ~]# echo $SHELL

/bin/bash


2.SS command:

function: View system listening port (socket)

Options:

-T:TCP protocol

-U:UDP protocol

-N: Resolve service Name

-L: Listening port number

Example:

[Email protected] ~]# SS-TNL

650) this.width=650; "src=" Https://s5.51cto.com/wyfs02/M02/8E/1C/wKioL1i2NQbity-mAAAjIbR9R9A965.png "title=" Ss.png "width=" 740 "height=" "border=" 0 "hspace=" 0 "vspace=" 0 "style=" width:740px;height:110px; "alt=" Wkiol1i2nqbity-maaajibr9r9a965.png "/>


3.IFCONFIG/IP Addr List command:

Function: View server IP Address

Example:

[Email protected] ~]# ifconfig

[[Email protected] ~]# IP Addr List

650) this.width=650; "src=" Https://s3.51cto.com/wyfs02/M00/8E/1F/wKiom1i2OvzAVy3UAADvHi6ug8E160.png "title=" Ifconfig.png "width=" 740 "height=" 565 "border=" 0 "hspace=" 0 "vspace=" 0 "style=" width:740px;height:565px; "alt=" Wkiom1i2ovzavy3uaadvhi6ug8e160.png "/>


4. Shutdown Command :

CentOS 7:

[Email protected] ~]# Systemctl Poweroff

[Email protected] ~]# Systemctl reboot


Applies to all systems:

[Email protected] ~]# Poweroff

[email protected] ~]# halt

[email protected] ~]# reboot


5.basename/dirname Command :

Basename-strip directory and suffix from filenames

Dirname-strip non-directory suffix from file name

[Email protected] ~]# basename/etc/sysconfig/network-scripts/ifcfg-eno16777736

ifcfg-eno16777736

[Email protected] ~]# dirname/etc/sysconfig/network-scripts/ifcfg-eno16777736

/etc/sysconfig/network-scripts


Subsequent re-writing


This article is from the "Disguised Geek" blog, please be sure to keep this source http://waldenkk.blog.51cto.com/2410270/1902373

Getting Started with Linux Basics (iii)

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.