Stopping SAP ASE

Only the system administrator can issue a shutdown command. Using a shutdown command minimizes the amount of work that automatic recovery needs to do when the servers are restarted. The preferred method of stopping SAP ASE is to use the Transact-SQL shutdown command.

  1. Log in to an SAP ASE account with System Administrator privileges:
    isql -Usa -Ppassword -Sserver_name
  2. Enter:
    1> shutdown 
    2> go

The default for the shutdown command is with wait. The with wait option allows SAP ASE to finish executing SQL statements or procedures, perform a checkpoint in each database, disable new logins, and perform other shutdown tasks.

A message similar to this prints to the stderr file:
Server SHUTDOWN by request. The SQL Server is terminating this process.
CT-LIBRARY error:

This is normal behavior.

If the message indicates that SAP ASE is waiting for processes to complete, and you must stop SAP ASE immediately, you can use the shutdown with nowait command. shutdown with nowait does not wait for currently executing statements to finish, nor does it perform checkpoints in every database. Use the shutdown with nowait command only when necessary.