Jump to content
Sign in to follow this  
PiNoY

25 Quick Linux Command Line Tips - Part 4

Recommended Posts

76. How to change system date ?

 

# date -s "December 25 2007 01:01:01"

 

77. How to know your free base memory and other memory / swap statistics ?

 

# free

 

78. How to show disk space usage of your filesystem in human readable form?

 

# df -ah

 

79. How to get the top 10 of your mbox mail users?

 

# cd /var/spool/mail

# ls -lS | head -10

 

80. How to find process ID of a running service like httpd?

 

# pidof httpd

 

81. How to locate a binary file, command source and its man pages?

 

# whereis ping

 

82. How to find the location of a executable file that could have been executed when entered from a prompt?

 

# which ping

 

83. How to download ISO or any file from web using command line?

 

# wget -c www.google.com/testfile.txt

# wget -c ftp://google.com/google.ISO

 

84. How to transfer file via ssh?

 

# scp -c testfile.txt user@remote-hostname

 

85. How to transfer files that has been only changed from one host to another without taking comparison?

 

# rsync -avz remoteserver:/home/remotefolder /home/localfolder

 

86. How to transfer your identity.pub into a remote machine's authorized_keys?

 

# ssh-copy-id -i identity-rsa-dsa.pub user@remote-hostname

 

87. How to know who you are in a shell?

 

# whoami

 

88. How to get more real-time view linux process stats and info?

 

# top

 

89. How to issue a continuous trace route to a host?

 

# mtr host-ip-addres

 

90. How to trace route without resolving IP address?

 

# mtr --no-dns hostname

 

91. What is another text-based alternative to chkconfig?

 

# ntsysv

 

92. How to list out current cron jobs?

 

# crontab -l

 

93. How to get the CPU time?

 

# clock

 

94. How to set date and time from NTP server?

 

# ntpdate 0.fedora.pool.ntp.org

 

95. How to show current system path?

 

# set | grep PATH

 

96. How to list out currently loaded kernel modules?

 

# lsmod

 

97. How to know the total days of your system without reboot?

 

# uptime

 

98. How to get a system bootstrapped from redhat network?

 

# /usr/bin/go-rhn.sh

 

99. How to see current running user jobs?

 

# jobs

 

100. How to edit text files from terminal?

 

# vi textfile.txt

# nano textfile.txt

# joe textfile.txt

# vim textfile.txt

# pico textfile.txt (if pico is installed - Pico is a trademark of the University of Washington)

# tee vv

Edited by Fearless News

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

About Us

We are glad you decided to stop by our website and servers. At Fearless Assassins Gaming Community (=F|A=) we strive to bring you the best gaming experience possible. With helpful admins, custom maps and good server regulars your gaming experience should be grand! We love to have fun by playing online games especially W:ET, Call of Duty Series, Counter Strike: Series, Minecraft, Insurgency, DOI, TF2 & Battlefield Series and if you like to do same then join us! Here, you can make worldwide friends while enjoying the game. Anyone from any race and country speaking any language can join our Discord and gaming servers. We have clan members from US, Canada, Europe, Sri Lanka, India, Japan, Australia, Brazil, UK, Austria, Poland, Finland and many other countries. It doesn't matter how much good you are in the game or how much good English you speak. We believe in making new friends from all over the world. If you want to have fun and want to make new friends join up our gaming servers and our VoIP servers any day and at any time. .

×

Important Information

By using this site, you agree to our Terms of Use.