Linux Common Command Learning

Source: Internet
Author: User

Java-version View JDK version

Ps-ef |grep XXX: Show the process containing XXX

PS: Show a process

grep: Finding

|: For pipeline command, indicates that PS and grep are executed together

Rpm-qa | grep java: detecting JDK installation packages

RPM: Check the installation package

-A: Query all kits

-Q: Using the inquiry mode, the rpm command asks the user first when any problems are encountered

RPM-E--nodeps java-1.7.0-openjdk-1.7.0.111-2.6.7.8.el7.x86_ 64: Ignore dependencies Uninstall java-1.7.0-openjdk-1.7.0.111-2.6.7.8.el7.x86_64

-e:< Kit File > or--erase< kit;: Delete the specified package

--nodeps: Do not check dependencies

Yum remove xxx: Uninstall XXX

Yum: Installing and uninstalling software

Yum install XXX: Installing XXX

Mkdir-p/USR/LIB/JVM: Create folder usr,usr subfolders Lib,lib subfolder JVM

mkdir: Creating a Folder

-p:--parents Create a top-level directory when needed, not as an error if the directory already exists

TAR-ZXVF jdk-8u131-linux-x64.tar.gz-c/USR/LIB/JVM: Extract jdk-8u131-linux-x64.tar.gz to/USR/LIB/JVM

Tar: Unzip

-Z: With gzip properties

-X: Unzip

-V: Show All procedures

-F: Use the file name, remember, this parameter is the last parameter, only after the file name

Vim/etc/profile: Edit Profile

Vim: Editing files

Export java_home=/usr/lib/jvm/jdk1.8.0_131: Set environment variable java_home=/usr/lib/jvm/jdk1.8.0_131

Export: Used to set or display environment variables

Source/etc/profile: Make profile changes effective

The Source:source command is typically used to re-execute a newly modified initialization file for immediate effect without having to log off and log back on

Clear: Clear the screen

Netstat-ln |grep 8080: Check if port 8080 is occupied

Netstat: Display network connection port information

Netstat-lntup: Querying all network connection port information

Vim filename: View a file

G: Go to the bottom of the file

MV Filename/var: Move file to/var

RM-RF filename: Deleting files

Rm-r: Delete files under folders and folders

Alternatives--config Java: switch JDK version

chmod 764 jetty.sh: Change permissions for jetty.sh

chmod: Permission to change a file or directory

chmod 7 (Owner rights) 6 (Group User Rights) 4 (other user rights) XXX (target file)

Permissions and number Correspondence

R Read right 4;
W Write right 2;
x executive right 1;
RWX (read, Write, execute): 7
rw-(Read, write): 6

Linux Common Command Learning

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.