How to view the log file on VPS

The view log file is the work normally done by the administrator server. In Linux, the log file of the server is saved in the folder/var/log.

To navigate to this folder using the command:


Use the ls-l to list all files in this folder you will see a number of the main log file:

/var/log/auth.log: save the log to verify

/var/log/boot.log: Log the activities in the process of booting the system

/var/log/cron: Log save the automatic activity calendar

/var/log/dmesg: seed log message below but mostly log buffers

/var/log/message: Log save General information of the system

/var/log/httpd/: this folder contains the log of Apache services

/var/log/maillog: The log mail on server

/var/log/secure: Log Security

/var/log/wtmp: Log log log

/var/log/yum.log: The log of Yum

If you install other software, will be the log file with the corresponding name here.

To view the log file we usually use the command tail or less


tail-n 30/var/log/secure 30//xem first line of log

Leave a Reply

Your email address will not be published.