on 2013 Dec 23 3:09 PM
BH, Hi i'm having a problem when trying to use database mirroring on two different machines. I have 2 computers. 1st computer is running server1 and Arbiter. 2nd computer is running server2. I've created 2 services (using sybase central) on computer1 with the following configurations.
-x tcpip(port=2640) -n arbiter -xa AUTH=abc;DBN=mtrs16 -xf 😧\\RMT\\arbiter\\arbiterstate.txt -su
and 2nd service:
-n mtrs16a -x tcpip(PORT=2638) -xf d:\\RMT\\mtrs16\\mtrs16astate.txt -su sql d:\\RMT\\mtrs16\\mtrs16.db -sn mirrordemo_test -xp partner=(ENG=mtrs16b;LINKS=tcpip(PORT=2639;TIMEOUT=1));auth=abc;arbiter=(ENG=arbiter;LINKS=tcpip(PORT=2640;TIMEOUT=1));mode=sync
On the 2nd computer I have one service running with following commands.
-n mtrs16b -x tcpip(PORT=2639) -xf d:\\RMT\\mtrs16\\mtrs16bstate.txt -su sql d:\\RMT\\mtrs16\\mtrs16.db -sn mirrordemo_test -xp partner=(ENG=mtrs16b;LINKS=tcpip(PORT=2638;TIMEOUT=1));auth=abc;arbiter=(ENG=arbiter;LINKS=tcpip(PORT=2640;TIMEOUT=1));mode=sync
The strange thing is, that when I have server1, server2, and arbiter all on the same computer, than it works fine. However, when I move server2 to a different computer, it does not connect to arbiter and to server1. I'm sure that the computer2 sees the computer1, because I can ping the ip and connect to computer1 using the ODBC Administrator. What am I doing wrong?
Thanks so much for all your help.
Aron
I somehow solved the problem. When i connected to a different network, i was able to connect to the servers and arbitrator. I'm not exactly sure why the other network was giving me such a hard time, but the only explanation i can think of is the difference in the 3rd set of the ip addresses. For example: Senario 1. Srv1 ipv4: 192.168.254.18 Srv2 ipv4: 192.168.100.17 DOES NOT WORK.
Senario 2. Srv1 ipv4: 192.168.254.18 Srv2 ipv4: 192.168.254.17 WORKS. Could that have been possibly the problem?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ah, I was wondering if you were trying to connect across subnets!
Note that when crossing subnets you need to specify the host name of the computer in your connection string. The reason for this is that most (all?) network routers will not broadcast UDP packets across subnets and SQL Anywhere uses UDP broadcasts to find the database server (when you do not specify the host parameter in the connection string).
Example: dbping -c "UID=DBA;PWD=sql;ServerName=demo16;Host=my_host:2638"
See the documentation for more information: http://dcx.sybase.com/index.html#sa160/en/dbadmin/connect-server.html
Your -xp parameter on the 2nd computer has the wrong ENG= value - it says mtrs16b and should be mtrs16a.
Also check to make sure that you don't have firewalls getting in the way: on your 2nd computer run
dbping -c ENG=mtrs16a;LINKS=tcpip(PORT=2638)
to test connectivity to your primary server and run
dbping -c ENG=arbiter;LINKS=tcpip(PORT=2640)
to test connectivity to your arbiter.
If the above two dbping commands are successful then ensure that connections in the other direction also work. I.e. run
dbping -c ENG=mtrs16b;LINKS=tcpip(PORT=2639)
HTH
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I highly doubt that the issue is the version of windows.
Some virus software also include port blocking features. Are you running virus detection/protection software of either computers? If yes, then you should check the feature settings of the virus software to make sure that the outgoing connection requests and incoming ports are not being blocked.
BTW: Did you correct your connection string?
Mark,
I've checked, and don't have antiviruses installed on either machines.
I've noticed something strange, however. When i start the service on one machine, and try to dbping from another one, it fails. However, if I "Test Connection" in the "ODBC Administrator", it successfully connects, and then i re-try to dbping, it is successful. From that point on, dbping will be successful, until i stop and restart the service again. In that case, i have to go back to odbc administrator, and do "Test Connection" again. What could possibly be causing this weird behavior?
User | Count |
---|---|
66 | |
11 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.