[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

generating list of user-modified conf files


I'm looking for a way to get a list of all non-standard configuration
files on a system. I'm considering writing a bash script that does the

 - grab all filenames from /var/lib/dpkg/info/*.conffiles
 - get these files' md5sums from /var/lib/dpkg/info/*.md5sums, place
these in e.g. "foo.bar"
 - check all these with "md5sum -c foo.bar" or "md5sum -cv foo.bar"...
As inexperienced as I am, md5sum -cv looks simpler to process, as I
simply take the first word of each line that contains "FAILED"... what's
the simplest way to get the filename out of -c's output?)
- Lastly, to get at files generated by postinst scripts, I'll remove all
files specified in /var/lib/dpkg/info/*.list from a list generated by
"find /etc/".

What I want to know, is am I reinventing the wheel? Is there a simpler
way to do something like this? (dpkg checks the md5sums of conffiles
when upgrading, so it has *some* of this funcionality.)

Hugo van der Merwe

p.s. I'll appreciate a CC: directly to me. (Though I'll also check the
archives. debian-devel is too high volume for my modem... ;) Maybe I'll 
subscribe again when back at University... that's on Sunday.)

Reply to: