Proxmox and etckeeper

Dataaja95

New Member
Jan 10, 2024
15
0
1
hi
My intention would be to use etckeeper to track the changes in the etc folder of the hosts of the pve cluster and, if necessary, to cancel them if there are errors in the configuration. However, based on this thread, the /etc/pve folder would produce problems,
because it is shared between hosts and part("pmxcfs filesystem, is this the case and has anyone tried this with pve
https://forum.proxmox.com/threads/using-etckeeper-with-proxmox.93224/
 
The post you responded to is 2 years old.

That said, /etc/pve directory isn't a real directory, it is a fuse mount of a database. So you probably should be excluding it from etckeeper. I don't use that software so can't tell you how to do it. Sorry.
 
Last edited:
The post you responded to is 2 years old.

That said, /etc/pve directory isn't a real directory, it is a fuse mount of a database. So you probably should be excluding it from etckeeper. I don't use that software so can't tell you how to do it. Sorry.
yep, I tried etckeeper today with Proxmox 9 and ran into a problem. I found this thread and saw that @mac.linux.free successfully solved the problem, so I asked him "how exactly" ;)
BTW, I solved it too:

1. Update the /etc/etckeeper/pre-commit.d/30store-metadata script, find the
Code:
        NOVCS='. -path ./.git -prune -o -path ./.bzr -prune -o -path ./.hg -prune -o -path ./_darcs -prune -o'
line and add -path ./.pve -prune -o at the end:
Code:
        NOVCS='. -path ./.git -prune -o -path ./.bzr -prune -o -path ./.hg -prune -o -path ./_darcs -prune -o -path ./.pve -prune -o'
2. Delete the /etc/.etckeeper file
Code:
rm /etc/.etckeeper
3. Run
Code:
etckeeper init
now everything will go smoothly


and it would be necessary to remove a couple of files that Proxmox regularly updates, they don’t make much sense in terms of saving the configuration and only create “noise” in the diffs:
Code:
git rm -r --cached pve/.clusterlog
git rm -r --cached pve/.rrd
git rm -r --cached pve/nodes/*/lrm_status

echo "pve/.clusterlog" >> /etc/.gitignore
echo "pve/.rrd" >> /etc/.gitignore
echo "pve/nodes/*/lrm_status" >> /etc/.gitignore
 
  • Like
Reactions: UdoB