Select Your Language

Infrastructure and Management

Cloud Computing

Storage

Runtimes

Integration and Automation

  • Comments
  • Moving /var/log folders to new partitions

    Posted on

    I had a RHEL 7 server initially installed with separate partitions configured - i.e. /, /home, /boot, /var, /tmp.

    In response to a security audit, we were required to add separate partitions for /var/log, /var/tmp, and /var/log/audit.

    I added some additional drive space to the server (the server is a VMware virtual machine), created a physical volume and logical group, and divided the logical group into 3 logical volumes, formatted the lv with xfs file system, and added the partitions to /etc/fstab.

    When the system came back up, ssh didn't work anymore (the connection would immediately drop after entering the username and password), and much of the logging didn't work. I had assumed the different files would automatically be created (/var/log/messages, /var/log/secure, /var/log/maillog, /var/log/wtmp) but noticed I had to create most of them. Adding wtmp got the "last" command working, adding dmesg got dmesg working, but some logging never started, i.e. messages.

    To get the system back to normal, I commented out the 3 lines in /etc/fstab, and ssh started working again, and the previous log entries were still there as well.

    So, I'm assuming its possible to successfully add the additional partitions, but I'm missing some important details in the implementation.

    Can anyone fill in the blanks here?

    Thanks

    Paul Greene

    by

    points

    Responses

    Red Hat LinkedIn YouTube Facebook X, formerly Twitter

    Quick Links

    Help

    Site Info

    Related Sites

    © 2026 Red Hat