[Borgbackup] BorgBackup Cache Not Regenerating

Richard richjunk at pacbell.net
Mon Aug 23 23:07:36 EDT 2021



> Increase log level to see if Borg doesn't do things without running
> into any warning or error condition.

I set 'borg create' to --info.   I did not see any issues, however, this
time the cache was created.

> Besides that: How do you remount or whatever ~/.cache exactly? There
> might be some chicken-egg-probelm with when you execute Borg. Is
> ~/.cache created ever at all for the user for which Borg doesn't seem
> to create it? Is that directory maybe availble in the default file
> system instead of youre expected TMPFS?

The issue might have been the chicken-or-egg.  I use xterm for most
things and when I su up to root /root/.bash_profile runs:

# for root cache area
if [ ! -d /tmp/cache-root ]; then
        /bin/mkdir /tmp/cache-root
        /bin/chmod 700 /tmp/cache-root
fi

and /root/.cache is a symbolic link to /tmp/cache-root.

/tmp is a tmpfs file system. So the first time a root bash shell is open
the above code would create the cache area.  I thought that the bash
shell script containing 'borg create' would also call
/root/.bash_profile, but perhaps not?  If I reboot the system and don't
open a root shell before 'borg create' is run there may not be a cache
area.   I just added the code above to the top of my borg backup script
 to ensure the cache area exists.  Now after the next reboot  I'll see
if the issue is resolved.

Thank you for the reply.




More information about the Borgbackup mailing list