1, See release information

cat /etc/issue

2, Check the kernel version number

uname -r Check the kernel version number

uname -p Look at the processor type 32bit/64bit

uname -n View the network host name (or hostname)

3,OpenJDK and JDK What's the difference ?

Oracle JDK is based on the OpenJDK source code. In addition, it contains closed-source
components. in other words ,OpenJDK Removed JDK Some copyright issues are involved in API And the source code , Functional ratio JDK Less .

4, Father Shell、 Son Shell

When running a Shell Script when , Father Shell Will be based on Script The first line of the program #! Later specified Shell The program opens a child Shell Environmental Science , And then in the Shell Run this Shell Script. Once it's done Shell Medium Script Run complete , This son Shell And then it's over . Back to the father Shell in . It doesn't affect the father Shell The original environment . Son Shell Environment has and father Shell The same environment variable 、 The standard input 、 Output 、 Errors, etc .

5,
source Command function ?

Able to use help source View help documents .P.S. Order and source command , Usage method: .
filename [arguments]

source: source filename [arguments]

Execute commands from a file in the current shell.

Read
and execute commands from FILENAME in the current shell.  The entries in $PATH are used to find the directory containing
FILENAME.  If any ARGUMENTS are supplied, they become the positional parameters when FILENAME
is executed.

Exit Status:

Returns the status of the last command executed in FILENAME; fails if FILENAME
cannot be read.

file filename Can run without permission .

At present shell Run in and in sub shell The difference between the two is , The variables and functions defined by the latter disappear at the end of the run , And the former can survive . therefore , If we change /etc/profile What's in it , Such as adding environment variables . So if it's going to take effect immediately , Must use source Command or click command in the current shell I'm gonna run it in .

6, environment variable

(1) View all environment variables :

$ set

(2) Look at an environment variable :

$ echo "$PATH"

(3) Environment variable Settings :

export ANT_HOME=/path/to/ant/dir
export PATH=${PATH}:${ANT_HOME}/bin:${JAVA_HOME}/bin

(4) Persistent environment variable file :

/etc/profile, Where system level environment variables are stored , Valid for all users . After setting, you need to log in again to take effect .

~/.bashrc, The place where the current user environment variables are stored , Valid only for current users .

After setting, you just need to start it again shell.

Of course , It's described above source The order can take effect immediately .

Copyright notice : This article is an original blog article . Blog , Without consent , Shall not be reproduced .

Linux C/C++ plan Shell A hodgepodge of orders (1) More articles about

  1. utilize ganymed-ssh2 Remote execution of other Linux On the machine shell command

    Practical application , Sometimes you need to go from web On the management interface , Remote to start other linux Programs on the host , utilize ssh Protocol can easily meet this demand . in fact hadoop Architecture , from nn Start the dn when , It's using no password ssh Sign in .gany ...

  2. self-taught Linux Shell2.1- Get into shell Command line

    Click on the return   self-taught Linux Command line and Shell The script road 2.1- Get into shell Command line Enter the text command line interface (CLI) The two methods : Console terminal Graphic terminal 1. adopt Linux Console terminal access CLI Press down Ctrl ...

  3. linux C Call in shell Command and run shell Script

    1.system( perform shell command ) Correlation function fork,execve,waitpid,popen Header file #include<stdlib.h> Defined function int system(cons ...

  4. linux 8 -- Pipeline combination Shell Command system management

    twenty . Through the combination of pipes Shell Command to get system running data : 1.  Output the most occupied memory in the current system 5 Bar command :     #1) adopt ps Command lists all the processes currently running on the host .     #2) According to the fifth field, based on the number ...

  5. Linux Next commonly used shell Command record 1

      Hardware chapter CPU relevant lscpu # Check out cpu Statistical information . cat /proc/cpuinfo # see CPU Information details , Like each CPU Model , Main frequency, etc Memory related free -m # Overview view memory ...

  6. Linux Next commonly used shell Command record

      Hardware chapter CPU relevant lscpu # Check out cpu Statistical information . cat /proc/cpuinfo # see CPU Information details , Like each CPU Model , Main frequency, etc Memory related free -m # Overview view memory ...

  7. 【linux Use 】bash shell Command line shortcuts are often used ( Reprint )

    Move : Ctrl + A: Move to the beginning of the command line of the current editor , Ctrl + E: Move to the end of the currently edited command line , Ctrl + F or ->: Shift right by character ( Towards the end of the command line , Move forward ) Ctrl + B or & ...

  8. Linux First of all shell command

    I'm learning today shell Script writing , I saw one on the Internet helloworld Of chestnuts : #!/bin/sh #print hello world in the console window a = "he ...

  9. Linux Next commonly used Shell command

    Link to original English :https://www.lopezferrando.com/30-interesting-shell-commands/ 1. Monitoring command ( Every time 2 Run once per second ) watch "ls ...

Random recommendation

  1. c#_1: backstage post request

    1:aspx Content <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Push.as ...

  2. 【codevs 1200】【NOIP 2012】 Congruence equation Expand Euclidean inverse multiplication template problem

    Templates ,,, #include<cstdio> using namespace std; void exgcd(long long a,long long b,long long & ...

  3. mysql Import and export

    1. Import entire library Access to database ,source The entry statement is equivalent to the data statement after directly connecting to the database >source /var/www/test.sql perhaps sy$ mysql -uroot -p Database name ( ...

  4. python Generate captcha script

    I use it every day recently python Write a little script , Practice using python grammar . Generation of verification code : It's used here python Image processing library PIL, install PIL There's a little trouble in the process of , Just use Pillow-win32 A document of ...

  5. A small example is jsonp

    1. What is the jsonp(json with padding) json We all know and use . that jsonp Well , Uh , I seem to have heard of , But it didn't work . For a long time, the landlord has only heard of this term . It's not until I read an article tonight (http:/ ...

  6. [ turn ]Java Code Examples for android.util.JsonReader

    [ turn ]Java Code Examples for android.util.JsonReader The following are top voted examples for showing h ...

  7. java double-click jar Package operation

    How to make jar Double click the package directly to run ? test :MyMenu.java   Class name :MyMenu finish writing sth. java After code , It is found that the physical path is : When I hold Shift key , Travel notes here , Open the command line window : Carry out orders :javac My ...

  8. Confluence 6 SQL Server Create a database and database users

    Once you've successfully installed SQL Server The server , Please follow the steps below for your Confluence Create database users and databases : Use your SQL Administrator rights , Create a new database ( for example confluence). ...

  9. ActiveMQ Pit filling

    Preface MQ It is an indispensable Middleware in the large-scale system architecture , There are biased articles before <MQ( Message queue ) Common application scenario analysis > Introduced MQ Application scenarios of , Some popular ones MQ yes rabbitmq,rocketma,ka ...

  10. webpack Build a problem summary

    To sum up the problems : 1. Such warnings (The 'mode' option has not been set, webpack will fallback to 'production' for thi ...