[Samba] How to move a samba PDC to a diffrent box

Wes Deviers wdevie at hrcsb.org
Tue Jun 3 20:01:57 GMT 2008


On Tue 3 Jun  2008 4:42:40 am ml wrote:
> Hello List,
>
> i have got a samba pdc running based on the smbldap tools and Debian Sarge.
> Now we would like to move everything over to Ubuntu Hardy.
>
> Can i simply:
> - Create the same users and groups with the same id on Hardy
> - Move the files and profiles over by keeping their permissions (rsync
> -avzp ...)
> - Set the samba SID to be the old orginial one (i do not know how this
> could be done and if it even works)
>
> Will i then simply be able to log back in with my Windows clients?
> Is there a HowTo explaining this scenario?
>
> Thanks,
> Mario


I don't know how "official" it is, but if you move all the files and 
everything beforehand, making sure to keep the ACLs, then shutdown samba on 
machine 1.  Then move

/etc/samba
/var/lib/samba

to the new machine, overwriting the existing ones created by the .debs.  Start 
samba on the new machine, and you're done.  

Of course, that's not very high-availability, and it's assuming you're not 
using LDAP or something...even though it should work.  Have to make sure 
everybody is off of the original.  I may be forgetting something, but I've 
done it dozens of times; one of the benefits of samba versus MS 
implementations is that there's much "magic" involved and so it really can be 
as simple as moving the files.

Wes


More information about the samba mailing list