#!/bin/sh # # Startup script for Sybase SQL server # # # Adjust tcp's keepalive param to 10 mins for PCs which disconnect unexpectedly. # Sun recommend that the value be set no lower than 10 minutes or performance # may be affected. # /usr/sbin/ndd -set /dev/tcp tcp_keepalive_interval 600000 # # Path to Sybase and install. # SYBASE=/usr/sybase ISQL=$SYBASE/bin/isql INSTALL=$SYBASE/install export SYBASE ISQL INSTALL case "$1" in 'start') # # Sybase server startup. # su sybase -c "$INSTALL/startserver -f $INSTALL/RUN_FOO -f $INSTALL/RUN_FOO_BACKUP &" ;; 'stop') # # Sybase server shutdown. # $ISQL -S FOO -U sa -P password > /dev/console 2>&1 <<-'END' shutdown SYB_BACKUP go shutdown go END ;; *) # # Invalid param. # echo "Usage: /etc/init.d/sybase { start | stop }" ;; esac