[Samba] Backup of Samba Server files

Steve Scanavarro steve.scanavarro at gmail.com
Mon Sep 17 21:10:19 GMT 2007


Hello!

Tomasz, I think you misunderstood me, my point is the backup of the *samba
configurations* (the tdb files, SID maybe?), not the content of my shares.

Ryan is right, I'm thinking about a new samba installation in a new server,
that will serve the same users/machines/accounts, it's just (for example) a
hardware upgrade (that requires a fresh new installation).
Ryan, I couldn't find in the manual a session about that. What I'm doing
today is:
- stop smb (is this really necessary?)
- copy /var/lib/samba/*.tdb, and /etc/samba/*.tdb to my backup device
- start smb
- copy net getlocalsid > mysid.sid to my backup device

My fear(?!) is: Is that all I'll need in the case I have to reinstall Samba
in a new machine with a fresh new OS?

PS: My LDAP base is backed up using slapcat > file.ldif, so in the "LDAP
side" is everything guaranteed! I'm worried about the "Samba side" (domain
logons by the clients and etc)

Thanks again you all!

Best,

Steve





On 9/17/07, Ryan Novosielski <novosirj at umdnj.edu> wrote:
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Tomasz Chmielewski wrote:
> > Steve Scanavarro schrieb:
> >> Hello everyone.
> >> I have a Samba+LDAP server running here in my company.
> >> Everything is working fine, but I'm now worried about the backup of my
> >> configurations.
> >> In the LDAP, I just slapcat my base to an ldif file and that's
> everything
> >> ok!
> >>
> >> But in Samba, if I need to upgrade to a new machine, how am I gonna be
> >> able
> >> to create another Samba server, with the SAME configurations? By "same
> >> configurations", I mean, same domain name, same netbios name and
> without
> >> asking all my 400 users to exit the domain COMPANY (old machine) and
> >> joining
> >> the COMPANY (yeah, same name) of the new machine again?
> >>
> >> In the past, when the MS Active Directory was used here, we used to
> >> backup
> >> the "System State" in Windows 2000. This was enough to rebuild a new
> >> domain
> >> controler machine transparently for the users.
> >>
> >> But, what about Samba? Should I just backup my /var/lib/samba/* files
> and
> >> everything would be fine in the case of a new Samba in a new machine?
> >> What
> >> about the SID? In a different machine it is going to be different
> >> isn't it?
> >> Just a net setlocalsid OLDSIDNUMBER would be enough?
> >
> > Realistically, just how big is your server (I mean, the amount of data
> > it stores - /bin, /usr etc., everything)?
> >
> > 1 GB? 2 GB? That's nothing.
> > Perhaps dozens of GBs if you keep some extra data like user profiles for
> > 400 users - but then, you surely make a backup of that, anyway.
> >
> > Just backup everything, it's easiest.
>
> He has a valid point though... let's say that he wants to just move
> Samba from this server to that server -- maybe separating applications
> on a box, or... who knows what else... He wants to make sure he can just
> do some sort of cutover and it will work; in that case, one DOES need to
> make sure they know what files are necessary. The one that contains the
> domain SID is very important (or at least, knowing what your domain SID
> is before a move)... but I think this stuff is all covered in detail in
> the manual. Am I wrong?
>
> - --
> ---- _  _ _  _ ___  _  _  _
> |Y#| |  | |\/| |  \ |\ |  | |Ryan Novosielski - Systems Programmer II
> |$&| |__| |  | |__/ | \| _| |novosirj at umdnj.edu - 973/972.0922 (2-0922)
> \__/ Univ. of Med. and Dent.|IST/AST - NJMS Medical Science Bldg - C630
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.5 (MingW32)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iD8DBQFG7uXnmb+gadEcsb4RAlFIAJ4hv6MzA3UK6nOSNRPA3sl5dQh9LwCeL8ZE
> KeqHojBm0Z2amQjx6xQwpX0=
> =cv7y
> -----END PGP SIGNATURE-----
>
>


More information about the samba mailing list