How to backup samba4

Ricky Nance ricky.nance at weaubleau.k12.mo.us
Thu Aug 23 14:54:00 MDT 2012


- What do I have to backup from samba (byside the data on the shares) to
restore the whole AD if neccessary? (/usr/local/samba/private|etc|**var +
sysvol + netlogon folder?

Lets say you have your samba4 install at /usr/local/samba, you will need to
backup (at a minimum) /usr/local/samba/etc, /usr/local/samba/private
and /usr/local/samba/sysvol (which has been moved in later release
to /usr/local/samba/var/locks/sysvol). Its really important to ensure that
you backup ACL's as they are stored on the filesystem not in a tdb or ldb
(unless you have this in your config, again not recommended). If you don't
get the ACL's backed up, then you are in for a LONG restore, however I
think Andrew is working on some samba-tool commands to make this a bit
easier for future installs, but even then it will not know what you have on
your current install, so at best it will only do defaults. Currently in the
master git there is a way to restore your sysvol ACL's to default, this is
part of a patch for Domain Admins being able to modify/create GPO's, but
this code could be (and I think will be at some point) expanded to work
with other shares.

By the way, the sysvol directory by default has all the GPO's and your
netlogon info, so there is no need to backup sysvol and netlogon. I have
not seen any case where var, include, share, lib, bin or sbin need to be
backed up, but if you are paranoid, they normally aren't too large. I have
a couple of large msi files (around 350mb) sitting in my GPO's and my
entire samba directory is only 605mb. I have around 350 users and 250
machines. It is also worth mentioning if you are using bind9 dlz, you need
to backup the symlinks exactly in private/dns, otherwise your restore will
work fine, but your zones won't update with your AD.

Hope this has answered your questions,
Ricky



On Thu, Aug 23, 2012 at 12:30 PM, Marc Muehlfeld <
Marc.Muehlfeld at medizinische-genetik.de> wrote:

> Hi,
>
> I'm currently planing and testing the final steps for our switch to s4 in
> 3 weeks and now got the following two important questions:
>
> - How do I backup samba4 (databases, etc.) while it's running?
> - What do I have to backup from samba (byside the data on the shares) to
> restore the whole AD if neccessary? (/usr/local/samba/private|etc|**var +
> sysvol + netlogon folder?
>
> Regards,
> Marc
>


More information about the samba-technical mailing list