Novell Home

Using RSYNC to Synchronize Windows XP Group Policy on NetWare

Novell Cool Solutions: Feature
By Vikas Johari

Digg This - Slashdot This

Posted: 17 Aug 2006
 

Problem:

Using RSYNC to Synchronize Windows XP Group Policy on NetWare server.

Solution:

Biggest challenge is how to copy & synchronize Windows XP/2000 Group Policy & Applications, for which we need to use ZENworks for Servers. This becomes more complicated when the customer has NetWare 5.1 and a WAN network.

After spending a day I have found a way to do this by using RSYNC. This solution is a workaround not the full proof solution ... best solution is ZENworks for Servers.

I have taken one NetWare 6.5 SP5 (IP: 172.18.1.20 Name: NW 65 eDirctory: 8.7.3.7 ) Server that will work as the Policy distribution server, one NetWare 5.1 SP8 (IP: 172.18.1.21, Name: NW51, NDS: 8.85) server that will act as the policy receiving server. Both servers are in the same TREE.

My NetWare 6.5 Server stores Policy files in SYS:\Public\Policy folder which I need to Sync with the NetWare 5.1 Server ...

Rsync supports NetWare 5.1 SP5 and above ...

Note: Novell Technical Support does not support RSYNC without Novell Branch Office, in other words, "There is no technical support provided via NTS if you are using this method".

Steps to set RSYNC

  1. Download RSYNC from http://forge.novell.com/modules/xfmod/project/?rsync or use Google to find Rsync for NetWare. I have downloaded rsync-2.6.0.zip ( it contains default NCF files which are very use full )


  2. Extract Rsync using WinZIP in your Desktop's folder and remove readonly attribute from all files in it.


  3. Copy RSYNCD.CONF from rsync-2.6.0\rsync\sys\etc to SYS:\ETC in both servers.


  4. Copy RSYNC-2.6.0\RSYNC folder to SYS: in both servers.


  5. Now both servers has RSYNC folder in SYS:


  6. Go to SYS:\rsync\sys\rsync folder and move all files to SYS:\RSYNC in both Servers.


  7. Now open SYS:\ETC\RSYNC.CONF file in notepad or any editor of NW51 Server and modify as:

    ### Start of RSYNCD.CONF #####
    uid = nobody 
    gid = nobody 
    max connections = 0 
    syslog facility = local5 
    
    # Change the pid file, log file, and motd as needed
    pid file = SYS:/rsync/rsyncd.pid 
    log file = SYS:/rsync/rsyncd.log
    motd file = SYS:/rsync/rsyncd.motd
    
    # Set the timeout value to 1 hour (60 seconds * 60 minutes) for now
    # this will affect all modules, or you can put it under each module
    timeout = 3600
    
    [NW65]
        path = sys:/public/policy
        comment = Policy Files Area
        read only = no
        use chroot = no 
        strict modes = no
        timeout = 3600
        transfer logging = yes
        use lfs = no
        hosts allow=172.18.1.20
        hosts deny=*
        
    ### End of RSYNCD.CONF #####


  8. Add few Lines in AUTOEXEC.NCF in NetWare 5.1 server as:
    SEARCH ADD SYS:\RSYNC
    SEARCH ADD SYS:\RSYNC\SYS\RSYNC
    RSYNCSTR


  9. Modify SYS:\RSYNC\RSYNCSTR.NCF of NetWare 5.1 server as:
    #### Start of RSYNCSTR.NCF ######
    
    echo Start RSYNC
    sys:\rsync\rsync  -v --progress --address=172.18.1.21 
    --config=sys:/etc/rsyncd.conf --port=873 --daemon
    
    #### End of RSYNCSTR.NCF ######


  10. Run commands added in point no 8 from console of NetWare 5.1, now it ready for RSYNC


  11. Now switch to NetWare 6.5 server


  12. Add lines in SYS:\System\Autoexe.ncf of NetWare 6.5 Server as given below and run them from the server console too.
    SEARCH ADD SYS:\RSYNC
    SEARCH ADD SYS:\RSYNC\SYS\RSYNC
    LOAD CRON


  13. Open and modify SYS:\ETC\RSYNCD.CONF of NetWare 6.5 server as:
    ### Start of RSYNCD.NCF #####
    
    uid = nobody 
    gid = nobody
    max connections = 0
    syslog facility = local5
    pid file = SYS:/rsync/rsyncd.pid 
    log file = SYS:/rsync/rsyncd.log
    motd file = SYS:/rsync/rsyncd.motd
    
    [NW5118.1.21]
       path=SYS:/public/Policy1.21
       comment=Policy Files Transfer
       read only=no
       use chroot=no
       strict modes = no
       transfer logging=yes
       timeout=3600
       use lfs=no
       hosts allow=172.18.1.21
       hosts deny=*
    
    ### End of RSYNCD.CONF #####


  14. Open Create SYS:\RSYNC\RESTORE.NCF of NW65 Server
    #### Start of RESTORE.NCF ####
    
    sys:\rsync\rsync -arz -v /public/policy/ NW51::NW65 --port=873 --progress
    
    #### END of RESTORE.NCF ####


  15. Now you can try by running RESTORE from NetWare 6.5 Server console ... if everything fine it will copy all the files & folders from NetWare 6.5 Server's SYS:\PUBLIC\POLICY to NetWare 5.1 Server's SYS:\PUBLIC\POLICY.


  16. If everything is fine then you can put RESTORE.NCF in SYS:\ETC\CRONTAB of NetWare 6.5 server to run in schedule. I have modified my NetWare 6.5 server's crontab as it should run restore.ncf in every hour's 15 min. NetWare 6.5 server's CRONTAB is:
    ##### Start of SYS:\ETC\CRONTAB #####
    # Run perl script to rotate logs each midnight.
    0 0 * * * perl sys:/apache2/rotate.pl sys:/apache2/rotate.ini --noscreen
    15 * * * * RESTORE.NCF
    
    ##### End of SYS:\ETC\CRONTAB #####


  17. Have Fun ...


  18. You can find some useful documents in Novell Cool Solutions ...

Environment:

NetWare 6.5, NetWare 5.1, RSYNC.NLM


Novell Cool Solutions (corporate web communities) are produced by WebWise Solutions. www.webwiseone.com

© 2014 Novell