XenServer How to clean up logs

Source: Internet
Author: User

Reprint: http://vps.gl/vps/259.html

XenServer server after six months or a year of use, XenServer produced a lot of log files. XenServer default is 4G system space, and these log files will occupy a lot of system space, the log file fills up, will cause the system problems: XAPI crashes, or the system is stuck, restart is not valid. Therefore, checking the log files of the cleaning system regularly is an important way to ensure the normal operation of the system.

1. Check the partition space

Df-hal

2. View the size of each directory under the root directory

Du-sh/* | Sort-nr

3. Check the Var directory, the size of each directory

du-sh/var/* | SORT-NR//Here you can see the log file logs occupy the most space

4. View Log log file

CD Log

Ls

5. Delete log file

You can delete all of the following files
RM-RF./* (make sure the current directory is in the/var/log/directory)

RM-RF file name (in the case of uncertainty, a file can be deleted)

6. Restart XAPI

After deletion, you need to restart the next XAPI

Service XAPI Restart

Note: Log space is not released after deletion

Restart the System log process

Service Syslog Restart

XenServer How to clean up logs

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.