It will likely be too late when you read this
From FBSD_tips
Buuuuut .. here goes anyway. The purpose here is to put all the stuff I "would have said" to them, [insert apropriate number here] minutes BEFORE they came and said "I just did $X and now $Y is happenning" ...
Top ten (or so) things that I could have done before I screwed up my system.
- Make a full back of your system.
This is the grand-daddy of them all, if you haven't taken this precaution I may not even engage in offering help and if I do, it will likely be of the "newfs and remount/reinstall" variety.
The handbook guidance on backing up : http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/backup-basics.html
- Backup your disklabels.
There is only the working copy, and if it is damaged or deleted, you can FUBAR a file system in a slice that you reconstructed wrong.
- Mark down the locations of backup superblocks.
- Backup your installed packages.
Here is a tip to make pkg_add-able backups of your currently installed packages. Once you have updated your ports many of these exact versions may become inaccessable to you, making your only recourse a "cascading upgrade" that can often end in tears.
- Capture the state of your network.
Write the output of things like ifconfig, netstat, route, etc. to a text file so that when somehting is not working right you have a baselines to refer to. Often times it is not the sweeping, catastrophic changes but the small ones that will trip you up.
- Backup key system files and/or whole directories to somewhere handy (e.g. /usr/local/backup/)
Likely candidates are /etc, /usr/local/etc/ and anything specific to the installation. Either whole directories or just important files like /etc/rc.conf. This could save you from pulling a full back up in just to find a minor change and shave minutes off of your downtime.
- Get to know the loader and boot process
Don't wait until you are looking at the prompt of an unbootable machine to learn the commands available at the boot loader.
- Consider making a snapshot in the / (root) file system
The root filesystem should not change much, so this sould not be too consumptive of disk space, but can really be a life saver if something get really borked on your root.
- Backup the installed packages database (it is directory tree in /var/db/pkg/).
Even if you lose all your packages, you can still know what WAS there and reconstruct it from that. This is especially useful is you also backed up all your packages.
So, with this in mind, better luck next time!
