Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

Here is the scenario. I want to be able to switch the end users database connections automatically in case we ever have to switch to our backup SDE server. My first thought was to set up sde connections to the backup server on the users machines, then write a batch file that would simply rename the connections to the users standard connections. I'm hoping to find a more automated solution. Ideally find some way to tell if a connection can't be made, then switch to the alternate connections. Has anyone implemented something like this? Any help much appreciated.

share|improve this question
add comment

3 Answers 3

up vote 5 down vote accepted

I think you'll have to configure some major database pooling, so that your two servers appear as one. Then, connecting clients won't (and shouldn't) know which server they are actually connecting to, and you can tinker with the back ends as much as you like.

Now, this is only an ideal solution if your backup is for availability - or if you want to take the machines offline and online as you see fit. If your backups are for data integrity (recovering from the oops-I-deleted-it-all), then pooling won't work, as the accidental deletes will automatically be propagated to all nodes.

share|improve this answer
add comment

Couldn't you possibly do some sort of port forwarding? I'm no network guy, so I can't provide a whole lot of details. I know that we had a named database server once that got upgraded from SQL Server 2005 to 2008 and ended up getting put on a new server with a new name. I asked the dba if I could still connect with the old name and he said that they had set it up so the old name got redirected to the new name - forwarded. Basically this sounds like a disaster recovery issue - one server goes down, the DR server comes on - transparent to your users. There has to be a way to do this. Look into forwarding the connections. Do you have a sys admin or network guy on hand you could talk to?

share|improve this answer
add comment

We're running under this scenario now: two servers running with a "virtual" server in front of them. Users map their connection to the virtual connection, which monitors the primary and backup SDEs. If the primary SDE fails, the virtual connection picks up the backup SDE. This is all being accomplished with Oracle RAC technology.

Now the downside: there is no transparent failover for the user. If the primary SDE fails, the users' desktop application tells them they've lost connection. If they exit the application and restart it, the virtual connection points them to the backup SDE at that time and the users have no idea they are running on the backup. If they haven't saved their edits, those edits are lost. Not completely transparent, but less painful and a lot quicker then having to change database connections.

I've talked to Esri about this, and they've said the problem lies in the fact that the cursors for the user sessions are stored in the SDE they are connected to and are not replicated over to the backup SDE. The only way to get a truly transparent failover is to deactivate the session cursors, which apparently comes with a decent performance hit. Esri pointed out that you have to weigh the pros and cons for this: take a performance hit for an event that (hopefully) never/rarely occurs or just have the user get out and get back in.

At least that's how I understand the situation. I'm an analyst, not a DBA. Let me know if you have any more questions.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.