Migration from 3.0 to 3.5/4.0 version, Single Domain Controller

From Zentyal Linux Small Business Server
Jump to: navigation, search

This document covers File sharing migration from a Zentyal 3.0 box to a 3.5 /4.0 (when available) We will need two boxes for this procedure, one with the Zentyal 3.0 and one for the 3.x. Alternatively we could save all needed data to a temporary location and once the 3.5 is ready move the data as shown in this guide.

 Zentyal 3.0:
   1 external interface
   1 internal interface with IP
   (Optional) Mail module installed (This document won't cover migration from Zarafa to Standard Mail/Openchange)
   (Optional) Jabber Module

1. We will have then a Zentyal 3.0 server called zentyal.zentyal-domain.lan:


It has some users, like this:


And some groups as well:


It is a Domain Controller for zentyal-domain.lan :


It also has one (or more) shares:


Additionally (and optionally) it will be a mail server and a jabber server (if this is not your case last steps may be skipped)

2. First Step will be to deploy a brand new 3.5 server, with exactly the same hostname and domain the same amount of network interfaces and with the same hostname and domain. For the sake of this example, we will set up the internal interface to and the external interface to any IP which may not exist on the network.

3. Now, we will install File Sharing module on this 3.5 and provision a (temporary) domain with exactly the same name as the 3.0 one. Please note that while Administrator password was available in Zentyal 3.0 under /var/lib/zentyal/conf/samba.passwd, on 3.x you will have to reset the password of the Administrator user to a known one using the Zentyal interface itself or RSAT tools

4. We will not install Mail nor Jabber yet.

5. Stop DNS and Samba modules in the old (3.0) server


6. Do the same on the 3.5/4.0 server


7. From the 3.0 server create a tarball of folder /opt/samba4/private and copy it to the 3.5 node


8. In the 3.5 server, uncompress the tarball in the Samba directory. Please note that samba data folder has changed from /opt/samba4/private in Zentyal 3.0 to /var/lib/samba/private in Zentyal 3.5. Please make sure that links between /var/lib/samba/private/sam.ldb.d/*DNS* and /var/lib/samba/private/dns/sam.ldb.d/*DNS* have been preserved (more information at https://wiki.samba.org/index.php/DNS_Backend_BIND)


9. Check and fix any error in samba database:


10. Start Zentyal DNS and Samba modules. Samba module will fail to start , but don't worry about this for now, we will fix later on


11. Some Unix attributes, like uidNumber for users and gidNumber for groups, in Zentyal 3.0 were stored in OpenLDAP, so are not present in the Samba database, we need these so the Linux system can set shared folder permissions, we will use the following script to create these missing attributes. Once done, Samba module should start with no error:


12. Recreate all your shares and apply the original permissions.

13. Create a tarball of your shares in your 3.0 server and upload it to the 3.5 one:


14. Uncompress the tarball to the appropriate location. Once done, in order to make sure that files have the right permission, change them on GUI, save changes, revert the change and save changes again. If zentyal.log complained when applying permissions changing owner to root should fix it (but you will to do the save changes again). In case you were setting permissions through Windows Workstations, you will need to do it this way, after changing the appropriate config key on /etc/zentyal/samba.conf


15. Create another tarball with the sysvol, and upload it to the 3.5 sever, uncompressing it to /var/lib/samba/sysvol/domain-name. After this, you will need to run samba-tool ntacl sysvolreset to correct permissions



16. (Only if mail is to be restored) Create a tarball for the /var/vmail and upload it to the 3.5 server


17. (Only if mail is to be restored) Install mail module on the 3.5 server, enable it, and create as many virtual domains as you had in the 3.0 server, and enable the accounts for the users that were enabled.

18. (Only if jabber is to be restored) Install jabber module on the 3,5 server, enable it and enable the users that should be able to use it.

19. Switch off the 3.0 server and change the IP of the 3.5 server to the one it originally had the 3.0 server. Make sure with samba-tool that after doing this change no traces remain of the IP


Personal tools


Zentyal Wiki

Zentyal Doc