Troubleshooting the Configuration for Sybase

If the database service and Jetty service do not start or stop as expected, or if you would like to establish and run these services without using the Smart Client, use these procedures.

Verify your Installation

First, verify that your installation is correct. In particular check that:

The ARCHIBUS Setup checks the registry for supported versions of Sybase Adaptive Server Anywhere. If the database server program is present on the workstation, the Setup program updates the application configuration file (c:\Program Files\archibus\20.1\SmartClient\SmartClient.Common.dll.config) to note that the program is present and in what location.

Based on which databases are active, the Start Servers command uses this information to update the Jetty configuration file to note the service dependencies, registers the services, and starts them.

Creating the Services from the Command Line

From the command line or from a desktop icon, you can follow the same steps in creating the Windows services as the Smart Client does. You can access the Windows command line on XP by selecting Start/Run and then entering command. On Windows 7, type command in the "Search programs and files" control. In either environment, you can use the icon at the top-left of the dialog to paste statements like those below to the command line.

Create the Sybase Database Service

To create the Sybase service, execute a statement like the following. Substitute your own location for the Sybase Adaptive Server Anywhere program file and your own database file location and name.

"c:\Program Files\Sybase\win32\dbsvc.exe" -y -as -i -sn SybaseASA_for_ARCHIBUS_201 -sd SybaseASA_for_ARCHIBUS_201 -w SybaseASA_for_ARCHIBUS_201 -n SybaseASA_for_ARCHIBUS_201 -c 300M -gp 4096 "C:\Documents and Settings\All Users\ARCHIBUS\projects\hq\data\hq.db"

To delete the service, first stop the service, then execute a statement like the following.

c:\Program Files\Sybase\win32\dbsvc.exe" -d SybaseASA_for_ARCHIBUS_201

To get the full list of switches that are available, invoke the command above with no command-line arguments.

Create the Jetty Application Server Service

To create the Jetty Service, execute a statement like the following.

"C:\Program Files (x86)\ARCHIBUS\20.1\Jetty\Bin\Jetty-Service.exe" --install "C:\Documents and Settings\All Users\ARCHIBUS\WEB-INF\config\jetty-service.conf"

To remove the Jetty Service, first stop the service, then execute a statement like the following.

"C:\Program Files (x86)\ARCHIBUS\20.1\Jetty\Bin\Jetty-Service.exe" --remove "C:\Documents and Settings\All Users\ARCHIBUS\WEB-INF\config\jetty-service.conf"

To get the full list of switches that are available, invoke the command above with "-?" instead of "--remove". Useful switches are --start and --stop.

You must start your Sybase database service before running the Jetty application server service. If you rename your Sybase database service, update the service dependencies in the Jetty configuration file (WEB-INF\config\jetty-service.conf).

Starting and Stopping the Services

You can start and stop the services from the Windows Services Manager. You can also change the services from automatic (meaning that they will restart automatically when you restart your workstation) to manual (meaning that the services won't retart until you do so yourself).

To access the Windows Services Manager, execute services.msc at the Windows command prompt.

Creating the Sybase Service from Sybase Central

Instead of the Start Servers command, if you prefer, you can use the Sybase Central management utility to create, start, and stop the Sybase database service.

To do so:

You can now start Jetty from an icon, as described in the Alternate Server Startup Procedures topic.

You can also create the Jetty service using the method described above. Be sure to update (or remove) the services dependencies from the Jetty configuration file (jetty-service.conf), as the Sybase Central utility names the service as "Adaptive Server Anywhere - SybaseASA_for_ARCHIBUS_201".

Or, you can use the database with Tomcat, WebLogic, or WebSphere as described in the Enterprise Installation topics.

Test your Connection from Interactive SQL

If the server is running, but you still cannot connect, verify that you can log into the program and query data.

If this check fails, your Sybase server is not installed properly, the server is not started, or the server did not load the database file itself. Recheck your installation or server startup steps.

Pinging the Server

While the particular connection details of each site's network differ, it is worthwhile to point out one or two common diagnostic strategies for TCP/IP networks.

One common test to use is the "Ping" utility that comes with most operating systems that support the TCP/IP protocol. This will help you to determine if the client workstation can communicate with the database server computer using the same low-level protocol that the database client and server use. For instance, if the IP Address of the database computer is 193.182.9.2, you might enter the following command line to see if you could get a response.

Ping 193.182.9.2

If this test shows no response on a TCP/IP network, there is an underlying network issue involved, not a database server issue.

Sybase uses a broadcast strategy to find the server. On mid-sized or large networks, this broadcast will often be stopped at an intermediate router, which is designed to limit the flow of traffic between subnets.

If this is the case at your site, you can still connect to the server by explicitly specifying the IP address of the database server. You do this by using the HOST parameter in the connection parameters switch, for example,

-x tcpip(HOST=kangaroo;HOST=197.75.209.222:2369)

Refer to the Adaptive Server Anywhere online reference material for more information on configuring the broadcast and server connection communication links.