Its been long time am writing a post on technical side. Yes, these days (actually months) were very busy with the current project. Not enough time for personal work even. 😦 . OK. Let me share some basic ArcSDE commands that every developer should aware of. As a GIS developer (or any developer/programmer) should know atleast one database. Though this is not a mandatory but in GIS context, knowing ArcSDE is very much essential. You cannot claim yourself a spatial developer (a.k.a ESRI Developer) if you are not knowing some basics of ArcSDE (in terms of ESRI).
I just wanted to write share the most useful and often used ArcSDE administration commands . Parameters embraced in <> are defined by user; so, if we have “<servicename>” that would result to “esri_sde”.
To show all SDE instances:
Sdeservice -o list
To show status of a specific sde instance including the number of accepting connections:
Sdemon -o status -i <servicename>
To show who is connected to an ArcSDE service:
Sdemon -o info -I users -i <servicename> -p <sdepassword>
To stop an sde service:
Sdemon -o shutdown -i <servicename> -p <sdepassword>
To start an sde service:
Sdemon -o start -i <servicename> -p <sdepassword>
To start an sde service remotely:
sdemon -o start -p <sdepassword> -s <servername> -i <servicename>
NOTE: ArcSDE administrator should be in the Windows admins group/power users group on the remote server.
To kill all connections to an sde service:
Sdemon -o kill -t all -i <servicename>
To kill a direct connect to an sde database:
Ths can be done either by restarting SQL Server database engine or by using SQL Server Activity Monitor, tracing the locked processes, and killing those processes. These things are being done on the SQL Server level, because direct connection has nothing to do with sde services – all users connect directly to the SQL Server database engine bypassing sde.
To shut down a stalled giomgr process (go to %sdehome%\tools and then run):
NOTE: Process ID (PID) can be seen in the Windows Task Manager. Click Select Columns button on the Processes tab from the View menu. Then select properties you want to appear as column headings and then click OK.
To get list of layers and their properties from a specific sde service:
Sdelayer -o describe -i <servicename>
To get the list of current locks for a certain sde service:
sdemon -o info -I locks -i <servicename>
For further references : You can visit ESRI ArcSDE Manual and many useful blogs like
http://bingluo.blogspot.com [Spatial DBA] lot of useful tips and tracks.
Hope this helps you.