Good Practice Guides

A recent post where someone suggested redirecting with a clobber ">" to a file the same command was reading from prompted me to post this sysad good practice list. Some items are from times where I have learned things the hard way. I think this would be helpful so we can learn from each others mistakes.

  1. Test thy backups
  2. pwd before rm
  3. hostname before reboot
  4. Executing a command with a recursive option on .* can be unpredictable
  5. One word. Clustering
  6. Test patches on a staging machine
  7. If you are going to do it frequently, script it
  8. Don't redirect to a file you are reading from
  9. Copy a file before editing it
  10. Document your systems' configuration and topology

backup , backup and good ducumentation :smiley:

This may be obvious but sometimes it does not get done.
11. Keep your documentation up to date. (The only time you realize that it is out of date is when you really need it. A bit like 1. Test thy backups. The only time you realize that the backups are wrong is when you really need them.)

This goes aong with backing up a file before you change it, but since I'm in CM, Use source control. That way you can recover from that last "update".

And documentation isn't something you do once and then forget. I can't count the number of times that I've used documentation (in house written) and it was a few releases behind or for hardware that had been replaced.

We are all using (distributed) version control systems these days, aren't we? Point taken though, not all files are versioned.

my number one rule:

don't "believe or guess"... know!

It is crucial to write up how you configured your OS. Get a journal and start documenting every step.

@Jakob: how do you see this being different from step 10, Document your systems' configuration and topology? Do you mean a tutorial?

I usually do:
"When you think it is a critical command, type very slowly"
:slight_smile: