DB2: Unix Linux Startup Script: Difference between revisions

From Wiki
No edit summary
 
Line 42: Line 42:
  esac
  esac
  exit 0
  exit 0
== Ver também ==
* [[DB2: Instalando o DB2 no Linux]]
* [[DB2: Criando usuários adicionais para o DB2]]
* [[DB2: Comandos Uteis]]
* [[DB2: Comandos Database]]
* [[DB2: Comandos Start e Stop]]
*[[DB2|  Mais Artigos sobre DB2]]
*[[Oracle|  Mais Artigos sobre Oracle]]
*[[Linux|  Mais Artigos sobre Linux / UNIX / AIX]]
*[[Tecnologias|  Mais Artigos sobre outras Tecnologias]]
[[Category:DB2]]
[[Category:Databases]]
[[Category:Tecnologias]]

Latest revision as of 23:18, 5 February 2013

Versions

Version 1.0 (Current Version)

#! /bin/sh
########################################################################
# chkconfig: 345 98 16
# description: IBM DB2

### BEGIN INIT INFO
# Provides: rc_db2
# Required-Start: $remote_fs $syslog
# Required-Stop:  $remote_fs $syslog
# Default-Start:  3 5
# Default-Stop:   0 1 2 6
# Short-Description: IBM DB2 Linux Script version 20100622.01
# Author: Sasa Brkic (http://lsoy.posterous.com)
# Copyright (C) 2010 Creative Commons
# License: GNU GPL V2 or (at your option) any later version.
### END INIT INFO

########################################################################

case "$1" in
        start)
               echo -n "Starting IBM DB2: "
               su - db2admin -c db2start > /dev/null
       ;;
       stop)
               echo -n "Stopping IBM DB2: "
               su - db2admin -c db2stop > /dev/null
       ;;
       reload|restart)
               $0 stop
               $0 start
       ;;
       *)
               echo "Usage: $0 start|stop|restart|reload"
       exit 1
esac
exit 0

Ver também