I deleted /var/cache/* today to free up some space on my /var partition. However, instead of applications re-creating the files as I expected, I recieved a bunch of error messages.
apt/apt-get refused to do anything until I manually created the directory /var/cache/apt/archives/partial I also got a few messages from cron.daily: /etc/cron.daily/dwww: mkdir: cannot create directory `/var/cache/dwww/dwww-build.1008': No such file or directory run-parts: /etc/cron.daily/dwww exited with return code 1 /etc/cron.daily/man-db: fopen: No such file or directory mandb: can't create index cache /var/cache/man/1075: No such file or directory mandb: can't chmod /var/cache/man/index.bt: No such file or directory mandb: warning: can't update index cache /var/cache/man/index.bt: No such file or directory fopen: No such file or directory mandb: can't create index cache /var/cache/man/oldlocal/1075: No such file or directory mandb: can't chmod /var/cache/man/oldlocal/index.bt: No such file or directory mandb: warning: can't update index cache /var/cache/man/oldlocal/index.bt: No such file or directory fopen: No such file or directory mandb: can't create index cache /var/cache/man/X11R6/1075: No such file or directory mandb: can't chmod /var/cache/man/X11R6/index.bt: No such file or directory mandb: warning: can't update index cache /var/cache/man/X11R6/index.bt: No such file or directory Sure, these errors are relatively simple to fix, but I am wondering if they are bugs. So before I file them as such, I'd like to know is it a requirement of using /var/cache that directories and files be automatically re-created? According to FHS 5.2: Files located under /var/cache may be expired in an application specific manner, by the system administrator, or both. The application should always be able to recover from manual deletion of these files (generally because of a disk space shortage). No other requirements are made on the data format of the cache directories. True, the FHS does not specifically say that directories have to be recreated, but I would consider it a bug if they aren't. Anyone agree? -- Duncan Findlay