Re: oracle for linux
Date: Wed, 16 Jan 2002 16:25:10 +0100
Message-ID: <a244up$ott$1_at_fe1.cs.interbusiness.it>
"Steven Luk" <ginwah_at_ix.netcom.com> ha scritto nel messaggio
news:a22o8e$tf7$1_at_slb7.atl.mindspring.net...
> Can somebody tell me how to invoke Oracle 9i Enterprise Manager Console
from
> Suse Linux 7.1? I can't find the executable in /$ORACLE_HOME/bin. How do I
> find the list of programs available for Oracle in linux? I located dbca,
> netca, sqlplus and netmgr. But how about the schema and data managers? I
> need a tool to create a new database without having to enter all the sql
> commands.
> Also my db service failed the test because this isn't a listener. But I've
> installed two listeners using tcp/ip, port 1521 and a hostname
"linux.local"
> and "localhost" respectively. Should I set up a new hostname for my new
> linux machine to make the service work? What kind of system is required to
> enable the db service? My service name is inv.localhost by the way.
Put this in your /etc/rc.d/init.d:
#!/bin/sh # chkconfig: 345 75 25 # description: Runs the Oracle RDBMS # processname: oracle #
. /etc/rc.d/init.d/functions
export ORACLE_HOME=/opt/oracle/Server/9.0.1 export ORACLE_OWNER=oracle export ORACLE_SID=econ3k [ -d $ORACLE_HOME ] || exit 0
[ -x $ORACLE_HOME/bin/dbstart ] || exit 0 [ -x $ORACLE_HOME/bin/dbshut ] || exit 0
# See how we were called.
case "$1" in
start)
echo -n "Starting Oracle RDBMS: "
touch /var/lock/subsys/dbora
su -l -s /bin/bash -c "exec $ORACLE_HOME/bin/dbstart" oracle
echo
echo -n "Starting Oracle TNS Listener: "
touch /var/lock/subsys/tnslsnr
su -l -s /bin/bash -c "exec $ORACLE_HOME/bin/lsnrctl start" oracle
echo
echo -n "Starting Oracle InterMedia: "
touch /var/lock/subsys/ctx
su -l -s /bin/bash -c "exec $ORACLE_HOME/bin/ctxstart" oracle
echo
echo -n "Starting Oracle Apache Server: "
touch /var/lock/subsys/JServ
su -l -s /bin/bash -c "exec $ORACLE_HOME/Apache/Apache/bin/startJServ.sh"
oracle
echo
;;
stop)
echo -n "Shutting down Oracle Apache Server: "
su -l -s /bin/bash -c "exec $ORACLE_HOME/Apache/Apache/bin/stopJServ.sh"
oracle
rm -f /var/lock/subsys/JServ
echo
echo -n "Shutting down Oracle InterMedia: "
su -l -s /bin/bash -c "exec killall ctxsrv" oracle
rm -f /var/lock/subsys/ctx
echo
echo -n "Shutting down Oracle TNS Listener: "
su -l -s /bin/bash -c "exec $ORACLE_HOME/bin/lsnrctl stop" oracle
rm -f /var/lock/subsys/tnslsnr
echo
echo -n "Shutting down Oracle RDBMS: "
su -l -s /bin/bash -c "exec $ORACLE_HOME/bin/dbshut" oracle
rm -f /var/lock/subsys/dbora
echo
;;
restart)
$0 stop
$0 start
;;
*)
echo "Usage: dbora {start|stop|restart}"
exit 1
esac
exit 0
then create this links:
cd /etc/rc.d/rc2.d
ln -s ../init.d/S98dbora
cd /etc/rc.d/rc3.d
ln -s ../init.d/S98dbora
cd /etc/rc.d/rc4.d
ln -s ../init.d/S98dbora
cd /etc/rc.d/rc5.d
ln -s ../init.d/S98dbora
cd /etc/rc.d/rc0.d
ln -s ../init.d/K10dbora
cd /etc/rc.d/rc1.d
ln -s ../init.d/K10dbora
cd /etc/rc.d/rc6.d
ln -s ../init.d/K10dbora
This starts up and shutdown the db and the listener (and the InterMedia, if you have it)
to create the database go in X and start dbca.
Ni hao, lelle. Received on Wed Jan 16 2002 - 16:25:10 CET