5

I need help.

Every time I restart apache log directory gets deleted. So after each reboot, I've to mkdir /var/log/apache2

any ideas how to solve this issue?

I've a hunch it's permissions problem, but hey... you know more than me :)

1
  • It looks that stacer can cause this issue. Commented Mar 16, 2022 at 1:26

1 Answer 1

5

It sounds like you've mounted /var/log as tmpfs. Check your /etc/fstab file for a line like:

tmpfs /var/log ... 

Another possibility is that you're using "disk cleanup" software or have a cronjob that purges the directory on boot.

1
  • 1
    Awesome, memory is tricky... I modified fstab to ease write/load on my SDHC boot drive, and I totally forgot about this. But - I thought ubuntu would write to actuall log files on shutdown. Commented Oct 9, 2011 at 22:16

You must log in to answer this question.