1,echo "AA" Test.txt and echo "BB" "test.txt
The original file is emptied and the content is written to the file, and the content is placed at the end of the file
2,chmod go+w-r/home/zhangy//Add Write permission to group users and other users
3,TAR-TZVF test.tar.gz//List archived content
4,du-ah//view file list size
5,du-sh//View total size of all files
6,echo ' 1+2 ' |bc-l//mathematical operations
7,UNAME-A//View some information about the Linux kernel, etc.
8,badblocks-s/DEV/SDA//bad path scan shows progress
9,time command//View the run time of the commands
10,LS-LRT//In reverse order by time
11,rsync-p//Show progress while synchronizing
12.history-c//Clear History command
13,CD-//return to last directory
14,tree//Display directory tree
15,umount-n/mnt/hda2//forced unload
16,echo ~///Display the user's home directory
17,echo $[5*5]//arithmetic operations
18,echo $ ((5*5))//arithmetic operations
19,eval ls;ps aux|grep httpd//These two commands can be executed
20,FREE-M//have MB display memory
21,uptime
Shows how long the system has been running, which in turn displays the following information: The current time, how long the system has been running, how many users are currently logged in, the average load of the system in the last 1 minutes, 5 minutes, and 15 minutes
22, addition operation
[[email protected] mytest]# let a=34+3;
[Email protected] mytest]# echo $a;
23,export//View all environment variables
24,echo $PATH//view a single variable
25,CMP file1 file2//file content comparison
26,clear//Clear screen
27,echo 23423 |awk--re-interval '/[0-9]{3,}/'//If not added Re-interval, do not show
28,cal//Get a neat calendar format
29,wc-l//Count rows, wc-w statistical words
30,echo "AaDCbd23" |TR "[A-Z]" "[A-z]" uppercase lowercase, echo "AaDCbdc23" |tr-c b-d =
Replace a string other than b-d with =
31,echo "ADSF" | Iconv-f utf8-t GBK//Turn character from UTF8 to GBK
-F is the from and shorthand,-t seems to be a shorthand for terminal
32,cat-n File//content is displayed in front of the line number
33,chattr +i File//read-only, root user cannot modify it
34,lsattr File//View files Properties
35,CAT/ETC/PASSWD |awk-f: ' {print $} '//View all users in the system
36,cat/etc/group//View all groups in the system
37,groups//Pre-check the current user's location, all groups
38,USERMOD-G Group name User//This method is overridden in a way that uses the time to be careful if User A is a sex in MySQL usermod-g php
MySQL, that's just PHP.
39,USERMOD-G Group name user//This way is increased by the way if user A is in MySQL usermod-g php
MySQL in this case, MySQL belongs to 2 groups.
40,BC//Enter into the mathematical calculation
41,umask 003 U permission is 7,g permission is 7, other user is 4, that is 774,777-003=774
42,MKFS-T VFAT/DEV/HDA6//format a partition in the removable hard drive into VFAT format
43,mount/dev/cdrom/media/cdrom//Mount CDROM
44,getent Group 532//through group ID, to find groups information
45,last//Login Successful user record
46,LASTB//Login unsuccessful user record
47,dump-s/dev/sda2//Check the capacity you want to back up the/dev/sda2
48,dump-0j-f/dev/hda2/sda2_bak.dump.bz2/dev/sda2//sda2 to be backed up and compressed
49,restore-t-f/dev/hda2/sda2_bak.dump//view backup information
50,restore-r-f/dev/hda2/sda2_bak.dump//restore Backup
51,fc-list//viewing fonts installed in the system
52,find. /-type f-exec grep-q "root" {}; -exec echo {};
Find the string contained in the file under the directory
53,vmstat 5//5 display System Information, CPU,MEMORY,I/O, etc.
54,top after SHIFT + P in the order of the process display
55,top after SHIFT + M in memory-based sort display
56,IPTRAF-G//View traffic for each interface
57,ostat-d-x/dev/sda2 2//Use Iostat to see disk I/O for disk/dev/sda2, refreshed every two seconds
Paste-sd ' | | | n ' test//files are converted to 1 lines per 4 lines, separated by |
59,lsof-i: 22//Know what program is running on Port 22 now
60,LSOF-C ABC//SHOW ABC process now open file
61,lsof-p 12//See which files the process with process number 12 opens
63,route//View routing information
64,ifup//Turn on the network card
65,ifdown//Turn off the network card
66,route del-net 172.168.0.0 netmask 255.255.0.0 dev eth0//delete
172.168 this network segment
67,route add-net 172.168.10.0 netmask 255.255.255.0 dev eth0//Add a route
68,NETSTAT-TUNL//List the network service ports that are listening
69,netstat-tun//List Connected Network service ports
70,NMAP-SP 172.30.4.0/24//How many users are operating on my console in this network segment, a good security check tool
71,vgdisplay//viewing available space in the system
72,lvextend-l+20g/dev/tank/part1//Add 20G of space to the Part1 partition
73,lvresize-l-10g/dev/tank/part2//To part2 this partition to reduce the space of 10G
74,pvdisplay//View disk information
75,mplayer-loop 10/mnt/song/music/flowers open. mp3//Cycle 10 times
76,pacman-s firefox-nd//nd Remove Dependency
77,wget-c//Breakpoint Download
78,chroot/mnt/ubuntu//Change root directory to/mnt/ubuntu
79,ctrl+a//Command line, cursor is called to start
80,ctrl+e//command line, cursor movement end
81,cut-d:-F 1-4 Test//used: Split file, take split 1-4 columns
82,file/home/zhangy/test.php//To view some basic information about a file
83,touch test.txt//Create an empty file Text.txt
84,htpasswd-cbd/usr/local/nginx/conf/authfile//Create an Access control file
85,DF//view disk space, and current number of disks
86,fdisk-l//View all disks
87,alsamixer//After entering, the M key can be used for mute
88,killall httpd//Kill all httpd processes
89,killall-9 Mysqld_safe//Some process Superuser also can't stop,-9 is forced to delete
90,mirror/mysql//Download MySQL directory
91,mirror-r/mysql//upload MySQL directory
92,rmmod PCSPKR//Turn off tab beep
93,modprobe PCSPKR//Turn on tab beep
94,gpasswd-a zhangy Wheel//Add zhangy This user to wheel this group
95,dd If=/dev/zero of=/virtual/ubuntu.virt.img bs=1m count=4096
Create an IMG image of 4G
96,lspic//Display PCI device
97,LSUSB//Display USB device
98,history | Less//less root more a little bit like, feel more comfortable point
99,ln-s//If you forget-s becomes a hard link
100,tar zxvf test.tar.gz-c/home/zhangy//extract content to the specified directory
The above is the XP system download compiled compiled Linux command Daquan, hope to help everyone.
Linux Common commands Daquan 100 article