Critical system file's.
Hello!
I wrote a small script that run's from 'crond' that find's modified file's in my system every monday at 4:30 am. I would like to know what the critical system file's are to keep my system running at a very basic level so when my script run's i will be able to learn/check the most important file's. *hoping there arn't too many* Thank you, Tarts. |
I think you may want to cut down on the apostrophes a little bit :)
As for critical stuff, definitely anything in /sbin or /usr/sbin is important. Configuration stuff is significant also, so anything in /etc and its subdirectories could be considered of critical importance. |
Quote:
Quote:
Thank's, Tarts. |
Here is my script:
Code:
#!/bin/bash Thank's. |
You're not doing anything with checksumming. If anyone replaced a file and kept the MAC times intact, you wouldn' t notice it.
You're also keeping the "databases" on the system while they should be copied/saved to "tamper resistant" read-only media. |
Quote:
Quote:
|
You may want to read the man page for touch to see why just checking the timestamps is a problems. Look at md5sum or some other similar tool to do get checksums.
|
Quote:
I'm kinda upset i don't think i can run this as a 'crond' job if it's on read-only media... Thank's for the advise everyone. |
Quote:
|
Quote:
Here is the "completed" script.: Code:
#!/bin/bash Tarts. |
Quote:
|
\/ \/ \/ \/ \/ \/ \/ \/
|
Quote:
[mildly offtopic] does any one how I can get 'cksum' to print all the directory's under '/etc' recursively? Or any idea's about how to implement this with out doing every directory separately... Thank's, Tarts. [/mildly offtopic] |
You could use find:
find /etc -exec cksum {} \; |
Quote:
I could kiss you stickman! Thank's. :) |
All times are GMT -5. The time now is 03:31 PM. |