Sort by a column in the file
Cat log.xls | sort-k1> log1.xls
Column: 1.txt
Content:
Gongdexin12 ttt
Gongdexin23 aaa
Xulibo rrr
Libai 999
Dufu 000
Cat 1.txt | sort-k1
Result:
Dufu 000
Gongdexin12 ttt
Gongdexin23 aaa
Libai 999
Xulibo rrr
1: indicates the domain to be sorted.
If your rongid is k3 in the third domain
-------------------------------------------------------------------------
Encode the file:
Iconv-f utf8-t gbk log.xls> log1.xls
View/modify Linux time zone and time
I. Time Zone
1. view the current time zone
Date-R
2. Modify the time zone
Method (1)
Tzselect
Method (2) Limited to RedHat Linux and CentOS
Timeconfig
Method (3) applicable to Debian
Dpkg-reconfigure tzdata
3. Copy the corresponding time zone file, replace the system time zone file, or create a link file.
Cp/usr/share/zoneinfo/$ main Time Zone/$ Time Zone/etc/localtime
Available in China:
Cp/usr/share/zoneinfo/Asia/Shanghai/etc/localtime
Ii. Time
1. view the time and date
Date
2. Set the time and date
Set the system date to June 10, 1996.
Data-s 06/22/96
Set the system time to 01:52:00 P.M..
Date-s 13:52:00
3. Write the current time and date to the BIOS to prevent failure after restart
Hwclock-w
Iii. Scheduled synchronization time
* ***/Usr/sbin/ntpdate 210.72.145.44>/dev/null 2> & 1
Gg from vim To File Header
Shift + g from vim to the end of the file
Copy a row to which: 50, 39y, and then p
Multi-line comment and delete multi-line comment in vim
1. multi-line comment:. press Ctrl + v to enter the column mode. B. select the line to be commented at the beginning of the line; c. press "I" and enter the annotator ("//", "#", etc.); d. press the "Esc" key twice. (If you see some information on the Internet, you only need to press "Esc", but you have to press it twice on my machine ).
2. delete comments from multiple rows: a. Press Ctrl + v to enter the column mode; B. Select the comments to be canceled; c. Press "x" or "d ".
Find all files in the directory containing the string: quick_power.-v is filtered out.
Grep quick_power/home/rong/www/trunk/rong360/main-r * | grep-v "\. svn"
Linux Virtual Machine Time Synchronization:
Crontab-e
*/5 */etc/init. d/ntp restart;