Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

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 :)

share|improve this question
up vote 6 down vote accepted

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.

share|improve this answer
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. – Sandro Dzneladze Oct 9 '11 at 22:16

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.