Linux Ask!

Linux Ask! is a Q & A web site specific for Linux related questions. Questions are collected, answered and audited by experienced Linux users.

Jan 212010
 

Synchronize data on disk with memory

Answer:

sync flush data buffered in memory (e.g. delayed reads/writes) out to disk by executing the sync(2) system call.

# sync

Some people like to execute multiple sync commands before reboot (But in fact it is not needed in most modern Linux distributions)

# sync; sync; sync; reboot

Jan 202010
 

Network connectivity testing using ping command

Answer:

To test the network connection between your server and other place, such as google.com, you can use the ping command

# ping google.com
PING google.com (64.233.189.103) 56(84) bytes of data.
64 bytes from hkg01s01-in-f103.1e100.net (64.233.189.103)..
64 bytes from hkg01s01-in-f103.1e100.net (64.233.189.103)..
64 bytes from hkg01s01-in-f103.1e100.net (64.233.189.103)..
64 bytes from hkg01s01-in-f103.1e100.net (64.233.189.103)..
.
.
.

Successful connection will return something similar to the above