|
CentOS Linux Server Guide |
Sorting file contents in CentOS Linux |
|||||||||||||||||||||||||||||
Sort command is used to sort the the contents of a file.
Command and Options: sort [options] filename(s)
Option:
Example:
The the following example will sort the given file A.log
The following example will do reverse sorting on the content of A.log
The following example will sort the content of A.log and the redirect the output (saved) to B.log
The following example will sort the field 2 to filed 10 of A.log
The following example, the sort command will merge the files of A.log and C.log by sorting them together
|
|||||||||||||||||||||||||||||
|
Copyright 2011 http://www.1a-centosserver.com All Rights Reserved All trademarks are the property of their respective owners. Contact Us | Terms of Use | Privacy Policy |