Ubuntu Server Guide Changes, errors and bugs


Download 1.27 Mb.
Pdf ko'rish
bet246/286
Sana20.12.2022
Hajmi1.27 Mb.
#1035308
1   ...   242   243   244   245   246   247   248   249   ...   286
Bog'liq
ubuntu-server-guide

Additional Plugins
The munin-plugins-extra package contains performance checks additional services such as DNS, DHCP,
Samba, etc. To install the package, from a terminal enter:
sudo apt i n s t a l l munin−p l u g i n s −e x t r a
Be sure to install the package on both the server and node machines.
References
• See the Munin website for more details.
• Specifically the Munin Documentation page includes information on additional plugins, writing plugins,
etc.
Rsnapshot
Rsnapshot is an rsync-based filesystem snapshot utility. It can take incremental backups of local and remote
filesystems for any number of machines. Rsnapshot makes extensive use of hard links, so disk space is only
used when absolutely necessary. It leverages the power of rsync to create scheduled, incremental backups.
To install it open a terminal shell and run:
sudo apt−g e t i n s t a l l r s n a p s h o t
If you want to backup a remote filesystem the rsnapshot server needs to be able to access the target machine
over SSH without password. For more information on how to enable it please see OpenSSH documentation.
If the backup target is a local filesystem there is no need to set up OpenSSH.
Configuration
The rsnapshot configuration resides in /etc/rsnapshot.conf. Below you can find some of the options available
there.
The root directory where all snapshots will be stored:
298


s n a p s h o t _ r o o t
/ var / c a c h e / r s n a p s h o t /
How many old backups you would like to keep. Since rsnapshot uses incremental backups, we can afford
to keep older backups for awhile before removing them. You set these up under the BACKUP LEVELS /
INTERVALS section. You tell rsnapshot to retain a specific number of backups of each kind of interval.
r e t a i n
d a i l y
6
r e t a i n
weekly
7
r e t a i n
monthly
4
In this example we will keep 6 snapshots of our daily strategy, 7 snapshots of our weekly strategy, and 4
snapshots of our monthly strategy. These data will guide the rotation made by rsnapshot.
If you are accessing a remote machine over SSH and the port to bind is not the default (port 22), you need
to set the following variable with the port number:
s s h _ a r g s
−p 22222
And the most important part, you need to decide on what you would like to backup. If you are backing up
locally to the same machine, this is as easy as specifying the directories that you want to save and following
it with localhost/ which will be a sub-directory in the snapshot_root that you set up earlier.
backup
/home/
l o c a l h o s t /
backup
/ e t c /
l o c a l h o s t /
backup
/ u s r / l o c a l /
l o c a l h o s t /
If you are backing up a remote machine you just need to tell rsnapshot where the server is and which
directories you would like to back up.
backup root@example . com : / home/ example . com/
+rsync_long_args=−−b w l i m i t =16 ,
e x c l u d e=c o r e
backup root@example . com : / e t c /
example . com/
e x c l u d e=mtab , e x c l u d e=c o r e
As you can see you can see you can pass extra rsync parameters (the + append the parameter to the default
list, if you remove the + sign you override it) and also exclude directories.
You can check the comments in /etc/rsnapshot.conf and the rsnapshot man page for more options.

Download 1.27 Mb.

Do'stlaringiz bilan baham:
1   ...   242   243   244   245   246   247   248   249   ...   286




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling