Step 5: Lets Synchronize
So the next step is to start the MobiLink Server and get it to generate our Synchronization scripts.
Open a command window and type the following on the same line.
start dbmlsrv9 -c “dsn=SQL Server” -zu+ -za -x tcpip -vn
With this method we are starting the Mobilink server directly by running the executable, but typically in production you would set this up as a service.
The parameters explained…
• The -c option tells Mobilink what the connection parameters are to connect to SQL Server
• The -zu+ -za options tell Mobilink server to generate the default sync scripts
• The -x options specifies the protocol, and in this case we are using TCP / IP
• And -vn specify that we will log only row-count values
So once the MobiLink server is started we are ready to synchronize. To do this we issue the following command to start the Mobilink client.
Start dbmlsync -c “uid=dba;pwd=sql” -n remote_pub -e scn=on -vn
The parameters explained…
• The -c option tells Mobilink client what the connection parameters are to connect to the remote database
• The -n option tell Mobilink server which publication to execute
• The -e option is an extended option that tells Mobilink server to generate our default sync scripts
• And -vn specify that we will log only row-count values
To verify this we can go back to Sybase Central and look at each of our tables, and here we will see all the data that has been downloaded from the SQL Server.
So, SUCCESS. Our initial sync has worked. This is all we need to do to start moving data bi-directionally between SQL Server and SQL Anywhere. If we made any changes to our remote database now, that will go up to the Northwind database in SQL Server.
For more advanced synchronization concepts and other Moblink synchronization techniques email jane.ray@ianywhere.com.