Re: [PATCH 0/5] Remove /var/cache from volatiles directory

Phil Blundell
2013-02-04T18:03:22Z

On Mon, 2013-02-04 at 12:03 +0200, Laurentiu Palcu wrote:
> Not necessarily. We are trying to have all postinstalls run on host, so
> we don't have to do any postinstall activity on target. Any cache
> generated during postinstall, will be generated at do_rootfs time. Then,
> we can deploy the image with the cache already in place.
>
> Also, on a RO rootfs, there is really no need to update the cache since
> the cached files do not really change. Hence, the cache created on host
> should, in theory, be valid.

What sort of files in /var/cache are you trying to address with this
change? The impression I have is that most of the things in there are
created dynamically by applications running on the target system and not
by postinst scripts that could be run on the host.

For example, an (admittedly somewhat unscientific) survey on my desktop
machine suggests that fontconfig, samba and cups, at least, are creating
files in /var/cache at run time with contents that you wouldn't be able
to predict in advance. (Apt also uses /var/cache as its download area,
but I guess if you have a read-only roofs then you aren't going to be
running apt very much so that one probably isn't an issue.) I wasn't
able to immediately identify any files in there that would be obvious
candidates for creating in a postinst and then leaving untouched
afterwards.

p.