This Blog is intended to collect information of my various Intrests,pen my opinion on the information gathered and not intended to educate any one of the information posted,but are most welcome to share there view on them
Wednesday, June 15, 2011
Useful 100+ Linux commands
1. Schedule a queue to run at 9am on March 1st. Note: Ctrl-d to save and exit.
# at 9am March 1
2. Schedule a queue to run after 5 minutes.
# at now +5 minutes
3. Check any jobs pending to run, same as at -l .
4. Empty out a file.
# cat /dev/null > /path/to/file
5. Change directory, see also pushd and popd.
6. List run level information for the service type.
# chkconfig –list
7. Change owner recursively.
# chown -R : /path/to/directory
8. Change shell.
9. Scan recursively for viruses.
# clamscan -r
10. Compare two files.
# cmp file1 file2
11. Copy keeping the directory structure.
# cp –parent /source/path /destination/path
12. Copy keeping the permissions of the user.
# cp -p
13. Copy recursive.
# cp -r
14. Copy without shell aliasing.
15. List crontab for user.
# crontab -u -l
16. Check current date and time.
17. Set current date and time, may need to set the hardware clock to the system time too, `man hwclock`.