File System on Control Domain Full on XenServer

The causes of these problems and the steps to take can be different depending on the partition layout of your XenServer host. For more information about partition layouts, see https://docs.citrix.com/en-us/xenserver/current-release/install/partition-layout.html.

This section includes steps to take to free up space right now. It also includes practices that you can put in place to avoid the problem occurring in the future.

What partition layout is your host using?

  • Legacy partition layout: This partition layout allows a 4 GB partition for the Control Domain. The Control Domain partition is also used for swap and logging.

    All XenServer hosts of version 6.5 and earlier use the legacy partition layout. Some XenServer hosts of version 7.0 and later use the legacy partition layout; this is the case when the host was upgraded from XenServer 6.5 or earlier and kept its existing layout, or when the host is a small device that does not have enough space for the new partition layout.

    If the output of the df -h command shows the size of the file system mounted on / as 4 GB, your host has the legacy partition layout.
  • New partition layout: This partition layout allows a dedicated 18 GB partition for the Control Domain. Logs are saved to a separate dedicated partition. XenServer hosts with this partition layout are less likely to experience this problem.

    All XenServer hosts of version 7.0 and later have this partition layout by default. However, some hosts can use the legacy partition layout if they were upgraded from XenServer version 6.5 or earlier and kept their existing layout or if they are a small device that does not have enough space for the new partition layout.

    If the output of the df -h command shows the size of the file system mounted on / as 18 GB, your host has the new partition layout.

Freeing up space on the Control Domain filesystem now

1. Remove additional logs

Legacy partition layout only: You can clear surplus logs for all XenServer hosts, but it will free space in the Control Domain filesystem only for those hosts that have the legacy partition layout.

  1. Change directory into the /var/log directory

    # cd /var/log
  2. Remove old compressed logs (.gz files). Do not remove *.log files as this will break log rotation and requires a reboot of the host to fix.

    # rm *.gz

Refer to the following screen shot for an example command. This command ensures that all the current logs files will be intact and will not be deleted.

In the /var/log directory, command rm -rf audit.log.* messages.* SMlog.* xensource.log.* xenstored-access.log.*

2. Remove cached uploaded patch files

For XenServer 7.0 and earlier:
1. Change directory into /var/patch

# cd /var/patch

2. Remove all the entries except the “/applied” folder

3. Use the following command to remove all the uploaded patches and without deleting the applied folder

# find /var/patch -maxdepth 1 -type f -exec rm -v {} +
For XenServer 7.1 and later:
1. Change directory into /var/update

# cd /var/update

2.
Remove all the entries except the "/applied" folder

3. Use the following command to remove all the uploaded patches and without deleting the applied folder


# find /var/update -maxdepth 1 -type f -exec rm -v {} +

3. Remove the patch-backups

  1. cd /opt/xensource/patch-backup
  2. ls
  3. rm -rf *

In the /opt/xensource/patch-backup directory, command rm -rf

4. Remove stunnel entries

1. Change to the tmp directory

# cd /tmp/

2. Remove any old stunnel log entries


In the /tmp directory, command rm -rf stunnel0* stunnel8* stunnelf*

Note: If these steps do not reflect the space being cleared, run #service syslog restart and the usage inside the root file system will be cleared.

5. Remove additional files

  • Check /tmpdirectory for any rogue files. You can delete everything inside it as XenServer won't store any default files in it.

  • Check "~" and "/" to see if there are any additional ISO files or any extra packages are present inside the directory. If yes, delete them.

Even after executing all those above steps if the space is still not reclaimed, contact Citrix Technical support.

Avoiding a full Control Domain file system in the future

The following practices to manage your logs reduce the used space in your control domain only if you are using the legacy partition layout.

Enable Log Compression

  1. Open the /etc/logrotate.conf file by using a text editor (for example, nano).
  2. Remove the comment symbol (#) from the #compress line so that it reads compress:
  3. Save the file and exit text editor. (In nano, press CTRL+O to save, and CTRL+X to exit). XenServer uses the new configuration from the next time.

Rotate your logs

For more information, see https://support.citrix.com/article/CTX238919.

Store your logs on a separate file system

For more information, see https://support.citrix.com/article/CTX130245.

Related:

  • No Related Posts

Leave a Reply