- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- startup script
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-16-2008 08:58 AM
тАО05-16-2008 08:58 AM
Re: startup script
kindly find contents of dbora script
ORACLE_HOME=/u01/app/oracle/OraHome_1;export ORACLE_HOME
#;export ORACLE_HOME
ORACLE_SID=ciehoi;export ORACLE_SID
# oracle owner at your site.
ORACLE=oracle
PATH=${PATH}:$ORACLE_HOME/bin
HOST=`hostname`
PLATFORM=`uname`
export ORACLE_HOME PATH
#
LOG=$ORACLE_HOME/stop1.log
touch $LOG
chmod a+r $LOG
#
case $1 in
'start')
echo "$0: starting up" >> $LOG
date >> $LOG
# Start Oracle Net
if [ -f $ORACLE_HOME/bin/tnslsnr ] ;
then
echo "starting Oracle Net Listener"
su - $ORACLE -c "lsnrctl start" >> $LOG2>&1 &
fi
echo "Starting Oracle databases"
su - $ORACLE -c "dbstart" >> $LOG2>&1 &
;;
'stop')
echo "$0: shutting down" >> $LOG
date >> $LOG
# Stop Oracle Net
if [ -f $ORACLE_HOME/bin/tnslsnr ] ;
then
echo "stopping Oracle Net Listener">> $LOG2>&1&
su - $ORACLE -c "lsnrctl stop" >> $LOG2>&1 &
fi
echo "stopping Oracle databases">>$LOG2>&1&
su - $ORACLE -c "dbshut" >> $LOG2>&1 &
;;
*)
echo "usage: $0 {start|stop}"
exit
;;
thanks
shabir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-17-2008 01:59 AM
тАО05-17-2008 01:59 AM
Re: startup script
This script is not according to standards. Please modify the script such that it looks something similar to /sbin/init.d/syslogd
i.e.
#!/sbin/sh
...
rval=0
set_return() {
x=$?
if [ $x -ne 0 ]; then
echo "EXIT CODE: $x"
rval=1
fi
}
...
exit $rval
Please let us know if this works!
kind regards
yogeeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-18-2008 09:07 PM
тАО05-18-2008 09:07 PM
Re: startup script
it didn't work
for u info,rc.log contents
usage: /sbin/rc2.d/S99dbora {start|stop}
Output from "/sbin/rc2.d/S99dbora start":
----------------------------
/sbin/rc2.d/S99dbora[11]: exit0: not found.
/sbin/rc2.d/S99dbora[18]: hostname: not found.
/sbin/rc2.d/S99dbora[23]: touch: not found.
starting Oracle Net Listener
/sbin/rc2.d/S99dbora[34]: su: not found.
Starting Oracle databases
/sbin/rc2.d/S99dbora[37]: su: not found.
usage: /sbin/rc2.d/S99dbora.org {start|stop}
Output from "/sbin/rc2.d/S99dbora.org start":
----------------------------
/sbin/rc2.d/S99dbora.org[7]: hostname: not found.
/sbin/rc2.d/S99dbora.org[12]: touch: not found.
starting Oracle Net Listener
Starting Oracle databases
thanks
shabir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-18-2008 10:53 PM
тАО05-18-2008 10:53 PM
Re: startup script
can you please post your "new" dbora script?
kind regards
yogeeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-18-2008 11:08 PM
тАО05-18-2008 11:08 PM
Re: startup script
PATH=${PATH}:$ORACLE_HOME/bin
This is the first time PATH is declared. You need to incorporate the path of the commands su, hostname, etc.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-18-2008 11:40 PM
тАО05-18-2008 11:40 PM
Re: startup script
let s see behind what to use
#!/sbin/sh
PATH=/usr/sbin:/usr/bin:/sbin
export PATH
case $1 in
'start_msg')
echo "a string"
;;
'stop_msg')
echo "a string"
;;
'start')
/sbin/init.d/yourscript start
;;
'stop')
/sbin/init.d/yourscript stop
;;
'status')
/sbin/init.d/yourscript status
;;
*)
echo "Utilisation $0 start|stop|status"
exit 1
;;
esac
exit 0
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-19-2008 10:24 AM
тАО05-19-2008 10:24 AM
Re: startup script
pls find new dbor script contents
# directory for you installation
ORACLE_HOME=/u01/app/oracle/OraHome_1;export ORACLE_HOME
rval=0
set_return() {
x=$?
if [ $x -ne 0 ]; then
echo "EXIT CODE: $x"
rval=1
fi
}
exit$rval
#;export ORACLE_HOME
ORACLE_SID=ciehoi;export ORACLE_SID
# oracle owner at your site.
ORACLE=oracle
PATH=${PATH}:$ORACLE_HOME/bin
HOST=`hostname`
PLATFORM=`uname`
export ORACLE_HOME PATH
#
LOG=$ORACLE_HOME/stop1.log
touch $LOG
chmod a+r $LOG
#
case $1 in
'start')
echo "$0: starting up" >> $LOG
date >> $LOG
# Start Oracle Net
if [ -f $ORACLE_HOME/bin/tnslsnr ] ;
then
echo "starting Oracle Net Listener"
su - $ORACLE -c "lsnrctl start" >> $LOG2>&1 &
fi
echo "Starting Oracle databases"
su - $ORACLE -c "dbstart" >> $LOG2>&1 &
;;
'stop')
echo "$0: shutting down" >> $LOG
date >> $LOG
# Stop Oracle Net
if [ -f $ORACLE_HOME/bin/tnslsnr ] ;
then
echo "stopping Oracle Net Listener">> $LOG2>&1&
su - $ORACLE -c "lsnrctl stop" >> $LOG2>&1 &
fi
echo "stopping Oracle databases">>$LOG2>&1&
su - $ORACLE -c "dbshut" >> $LOG2>&1 &
;;
*)
echo "usage: $0 {start|stop}"
exit
;;
esac
#
exit
thanks
shabir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-19-2008 11:24 AM
тАО05-19-2008 11:24 AM
Re: startup script
when you had read Fabian's carefully, you would have identified the problematic lines:
>>>
...
# oracle owner at your site.
ORACLE=oracle
PATH=${PATH}:$ORACLE_HOME/bin
...
<<<
Nothing of the variable PATH is set but you use it. Put at least this at the beginning of your startup script:
PATH=${PATH:-/usr/bin}
The logfile should contain much lesser 'not found's (if any).
The statement
exit$rval
is wrong - there needs to be a space between command and argument:
exit $rval
mfg Peter
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-19-2008 08:30 PM
тАО05-19-2008 08:30 PM
Re: startup script
based on the recommendations made by Fabian and Peter above. I have modified your dbora script and uploading it again.
can you please try this again?
kind regards
yogeeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-19-2008 08:34 PM
тАО05-19-2008 08:34 PM