- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- script start-up for Oracle in the boot
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
тАО06-08-2005 05:09 AM
тАО06-08-2005 05:09 AM
I need a script for start instance-database (oracle) for Service desk.
How can do that ??
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-08-2005 05:39 AM
тАО06-08-2005 05:39 AM
Re: script start-up for Oracle in the boot
cp template oracle
Edit the oracle script to do su - oracle -c "command to start up oracle"
make sure /sbin/init.d oracle script can be executed by root.
cd /sbin/rc3.d
ln -s /sbin/init.d/oracle S900oracle
cd /sbin/rc2.d
ln -s /sbin/init.d/oracle K100oracle
You will need a valid /etc/oratab file. This file should be read to see what instances should be started.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-08-2005 06:39 AM
тАО06-08-2005 06:39 AM
Re: script start-up for Oracle in the boot
I need put "su - oracle -c command to start up oracle" in the file oracle.
Where part the file oracle I need put
su - oracle -c command to start up oracle
cd /sbin/rc3.d
ln -s /sbin/init.d/oracle S900oracle
cd /sbin/rc2.d
ln -s /sbin/init.d/oracle K100oracle
and
How can do that for shutdown?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-08-2005 07:11 AM
тАО06-08-2005 07:11 AM
SolutionThe softlink starting with a K will execute the shutdown.
I had a lot of problems with the stock oracle shutdown script hanging on shutdown, causing long, sometimes interminable shutdowns of my oracle servers.
So I re-wrote the process.
In the /sbin/init.d/oracle script stop section.
/usr/bin/su - oracle -c "/usr/contrib/bin/shut.oracle"
The core of shut.oracle
cat $ORATAB | while read LINE
do
case $LINE in
\#*) ;;#comment-line in oratab
*)
if [ "`echo $LINE | awk -F: '/^[^#*]+:/ {print $3}' -`" = "Y" ] ; then
ORACLE_SID=`echo $LINE | awk -F: '{print $1}' -`
echo "checking oracle sid: $ORACLE_SID "
/usr/contrib/bin/shutsid.sh $ORACLE_SID
fi
esac
done
Sorry for what the forums do to my nicely indented code.
#!/sbin/sh
ORACLE_SID=$1
. /usr/contrib/bin/setOraProfile
sqlplus internal << EOFTOP1
select * from v\$database;
shutdown immediate;
exit;
EOFTOP1
exit;
SetOraProfile gets replaced with whatever script or source set you use to set proper oracle environment variables.
SEP
http://www.isnamerica.com/contactsep.shtml
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2005 07:34 AM
тАО06-09-2005 07:34 AM
Re: script start-up for Oracle in the boot
If you'ave a valid oratab file in the /var/opt/oracle directory and the ORACLE_HOME variable is defined and exported, use the attached script and follow the steps below:
1. Install the script in the /sbin/init.d directory, name it oracle.
2. make symbolic links to the 2 and 3 run-levels for stopping and starting oracle respectively like...
ln -s /sbin/init.d/oracle /sbin/rc3.d/S900oracle
ln -s /sbin/init.d/oracle /sbin/rc2.d/K100oracle