[arch-general] [arch-dev-public] [signoff] dcron 4.2

Jim Pryor lists+arch-general at jimpryor.net
Tue Jan 12 18:47:25 EST 2010


On Wed, Jan 13, 2010 at 01:34:52AM +0200, Dimitrios Apostolou wrote:
>
> Since I've been bitten by this, how can I know if the file I
> modified is goint to be overwritten or not, *before* it actually
> happens? 

    pacman -Qo $file

will tell you what package installed $file.

    find /var/abs -type d -name $package

will give you the directory containing the PKGBUILD.

    fgrep /var/abs/path/to/PKGBUILD -e backup=

will give you the backup array. If it's not there, it will be
overwritten or removed on upgrades.

> And even if it is, a .pacsave wouldn't hurt anyone, if I
> remember correctly (it's been some time) I had completely lost my
> changes, and I had to rewrite them.

I know, I've been bitten too. I highly recommend setting up a script to
backup your /etc directory daily, and keep at least a week or so of
rotated backups. If you've got a good backup system, you can just
include this in it. If not, you should get one. But you could in the
meantime, or additionally, just set up a separate /etc backup. It
needn't take up much space. My /etc is 9 M and the total of a week's
worth of daily backups and three weeks of weekly backups beyond that is
20 M. Look into rdiff-backup or rsnapshot.

-- 
profjim at jimpryor.net


More information about the arch-general mailing list