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.

I had been trying to connect a MSSQL Server/SDE 9.3 to an FME (2013) Reader for 2 days until I noticed from an earlier fme project that each sde Database has a unique port number. I thought the sde connection was as standard 5151 but it seems that my database was 5158.

Does every database have a seperate port number? Or is this somehow defined per sde connection?

How can I get a list of which database is connected to which port?

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

Yes, each application server instance must be run on a unique port. The registered default port is 5151/tcp, but any port can be used (that is, any port not used for some other process). The 'sdeservice -o list' command can be used to obtain the list of port names used (you can also look a the Windows Services list [which includes the symbolic port name]), but then you need to look at the server etc/services file to map the name to port number.

The recommended practice is to use Direct Connect, which will free you from keeping track of ports. It will become mandatory practice after 10.2 (application servers are deprecated at 10.2).

share|improve this answer
    
Thanks for your reply. So as I understand it, everytime I create an sde connection with the postinstallation method, a new sde instance is created with it´s unique port number. And the only way to find out which port is used is to use the sdeservice command line or the windows services method (as you explained). Is that Correct? How would I create a two tier connection? –  Robert Buckley Nov 21 '13 at 12:45
1  
Not exactly. The postinstall GUI (which I never use) accepts input for the service mnemonic (which must be established in advance); it doesn't choose a port on its own. I use several different naming schemes, but I've filled my services file with 'sdeNNNN' aliases, so that 'sde5154' is known to be running on 5154. All ArcSDE clients have the ability to use Direct Connect, just by using 'sde:{rdbmsname}{:optional_parameters}' for the instance, along with a valid database, user, and password. See the documentation for details. –  Vince Nov 21 '13 at 13:19
    
Hi..Thanks for your comment. I´m curious as to why you don´t use the Postinstall GUI and what you do instead. Can you tell me how you create an sde connection to a db if you are not using the postinstall mechanism? –  Robert Buckley Nov 22 '13 at 10:20
    
I need to run a number of different versions of ArcSDE simultaneously, and the only way to accomplish this is to install, make a zip archive, uninstall, and unzip. The GUI tools only work when installed, so I learned how to use the command-line utilities to maintain services over a decade ago. I still have 8-10 services on my laptop, but they're all set to manual start, and I use Direct Connect from Desktop. –  Vince Nov 22 '13 at 13:25
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.