Database auto start with machine on and shutdown with machine shutdown

i have installed oracle 10g release 2 on linux 5.1. now i want to start my database with machine on and shut down when the machine is shutdown.
for this i have do the following steps but i does not works.
Log in as the root user
vi /etc/oratab
$ORACLE_SID are not allowed.
orcl:/u01/app/oracle/product/10.2.0/db_1:Y
change the directory to /etc/init.d
Create a file called dbora, and copy the following lines into this file:
vi dbora
#! /bin/sh -x
# Change the value of ORACLE_HOME to specify the correct Oracle home
# directory for your installation.
ORACLE_HOME=/u01/app/oracle/product/10.2.0/db_1
# Change the value of ORACLE to the login name of the
# oracle owner at your site.
ORACLE=oracle
PATH=${PATH}:$ORACLE_HOME/bin
HOST=`hostname`
PLATFORM=`uname`
export ORACLE_HOME PATH
if [ ! "$2" = "ORA_DB" ] ; then
if [ "$PLATFORM" = "HP-UX" ] ; then
remsh $HOST -l $ORACLE -n "$0 $1 ORA_DB"
exit
else
rsh $HOST -l $ORACLE $0 $1 ORA_DB
exit
fi
fi
case $1 in
'start')
if [ "$PLATFORM" = "Linux" ] ; then
touch /var/lock/subsys/dbora
fi
$ORACLE_HOME/bin/dbstart $ORACLE_HOME &
'stop')
$ORACLE_HOME/bin/dbshut $ORACLE_HOME &
echo "usage: $0 {start|stop}"
exit
esac
Change the group of the dbora file to the OSDBA group (typically dba), and set the permissions to 750:
# chgrp dba dbora
# chmod 750 dbora
Create symbolic links to the dbora script in the appropriate run-level script directories as follows.
# ln -s /etc/init.d/dbora /etc/rc.d/rc0.d/K01dbora
# ln -s /etc/init.d/dbora /etc/rc.d/rc3.d/S99dbora
# ln -s /etc/init.d/dbora /etc/rc.d/rc5.d/S99dbora
after done these changes i restarted my system but the database is not started automatically.....
please help where i am doing wrong...and correct me..

Re: Oracle 10g on linux 5.1 issue
DUPLICATE!

Similar Messages

  • DB and listner  auto start with linux problem

    Dear all :
    i can't set DB auto start with linux
    my db version 10g linux 5
    I followed these steps :
    edit the "/etc/oratab" file setting the restart flag for each instance to 'Y'.
    TSH1:/u01/app/oracle/oracle/product/10.2.0/db_1:Y
    create a file called "/etc/init.d/dbora" as the root user, containing the following.
    #!/bin/sh
    # chkconfig: 345 99 10
    # description: Oracle auto start-stop script.
    # Set ORA_HOME to be equivalent to the $ORACLE_HOME
    # from which you wish to execute dbstart and dbshut;
    # Set ORA_OWNER to the user id of the owner of the
    # Oracle database in ORA_HOME.
    ORA_HOME=/u01/app/oracle/oracle/product/10.2.0/db_1
    ORA_OWNER=oracle
    if [ ! -f $ORA_HOME/bin/dbstart ]
    then
    echo "Oracle startup: cannot start"
    exit
    fi
    case "$1" in
    'start')
    # Start the Oracle databases:
    # The following command assumes that the oracle login
    # will not prompt the user for any values
    su - $ORA_OWNER -c "$ORA_HOME/bin/lsnrctl start"
    su - $ORA_OWNER -c $ORA_HOME/bin/dbstart
    'stop')
    # Stop the Oracle databases:
    # The following command assumes that the oracle login
    # will not prompt the user for any values
    su - $ORA_OWNER -c $ORA_HOME/bin/dbshut
    su - $ORA_OWNER -c "$ORA_HOME/bin/lsnrctl stop"
    esac
    chmod 750 /etc/init.d/dbora
    chkconfig --level 345 dbora on
    # ln -s /etc/init.d/dbora /etc/rc.d/rc3.d/K01dbora
    # ln -s /etc/init.d/dbora /etc/rc.d/rc3.d/S99dbora
    # ln -s /etc/init.d/dbora /etc/rc.d/rc5.d/K01dbora
    # ln -s /etc/init.d/dbora /etc/rc.d/rc5.d/S99dbora

    Follow this part of Oracle Doc,
    Automating Shutdown and Startup
    http://download.oracle.com/docs/cd/B19306_01/server.102/b15658/strt_stp.htm#sthref249
    Also run your script manually see if it will run sucessfully.
    /etc/init.d/dbora start
    /etc/init.d/dbora stop

  • Will database Auto-Start?

    I have two databases running in a windows server, due to some other issue server got rebooted. When i try to start the DB's I found one of my database is already up and running! and the other DB was down i had started it manually.
    Is it possible to have a DB auto-start on Windows? If so how to do it?

    user011232 wrote:
    Hi,
    Install Oracle Grid Infrastructure for a Standalone Server and use RESTART future, this is best
    Define "Best".
    I'd consider installing GI for the sole purpose of getting Oracle Restart to be a case of severe over-engineering.
    Besides, a server shutdown should be considered "A Big Deal" (tm)*.  Personally, I don't think having a database auto-start after a server shutdown to be desirable.  I want to check out the server itself, confirm things are working correctly after the reason for the shutdown.  Only after the server itself is checked out do I want to try to bring up a database.
    * Yes, I know that with Windows, a weekly reboot is often considered "normal operations".  One more reason I consider Windows to be a poor excuse of an OS.

  • Skype 7.2 doesn't auto-start with Windows

    A week or two ago, Skype stopped auto-starting with Windows.  At the same time, I started appearing as offline to my contacts and cannot message any of my contacts.  I've uninstalled/re-installed Skype but it hasn't fixed my issue.  I suspect this coincided with a Windows Update but I can't be 100% sure of that.  I've searched thru Event Viewer but don't find any Skype errors.  Can anyone offer a suggestion on how I can get Skype working properly again?
    Win 7 with all updates
    Skype 7.2
    Thanks in advance, Andre

    Please, run the DirectX diagnostics tool.
    Go to Windows Start and in the Run box type dxdiag.exe and press the OK button. This will start the DirectX diagnostics program. Run this diagnostics and save the results to a file. Please, attach this file to your post. Info on all installed devices should be available in this file.
    Be aware that you will have to zip this file before attaching it here.

  • Knwoing the database was started with which pfile/spfile

    hello to everyone,
    Actually, a question that crossed my mind and I wondered if it's possible in Oracle.
    For an already started database, is there a way to know the database was started with which pfile/spfile? Is there a view that tells this for example.
    Many thnx.
    H Hiruya

    If spfile parameter is null, then you can look for a
    pfile with the name convention of
    init<ORACLE_SID>.ora.Yes, you can, but that won't tell you anything about which pfile was used to start the instance. I can just as easily type:
    startup pfile=/my/pfile/that/does/not/conform/to/any/naming/standard
    There's no way to definitively determine which pfile was used to start an instance.
    -Mark

  • I plugged IPOD in to sync ( first time in over a year) it auto started with the "Do Not Disconnect", but did not sync.  Now the IPOD is stuck in that mode, won't shut off, won't sync, won't work.  is there a way to reboot it?

    I plugged IPOD in to sync ( first time in over a year) it auto started with the "Do Not Disconnect", but did not sync.  Now the IPOD is stuck in that mode, won't shut off, won't sync, won't work.  is there a way to reboot it?

    It has already been 6 days from your post, my apology for responding so late, but it is my habit to help only the leftovers, which the other contributors missed.
    Toggle the hold switch make sure there is no red showing.
    To reboot an iPod. (Or RESET in Apple iPod jargon)
    Press Menu and Center button for about 10 secs till the Apple logo comes ON , this would not erase any data from your iPod.
    I would advice you to leave the iPod charging for about 4 hours, if it has been discharged for 1 year or more, and also Apple recommends that you charge the iPod at least once a month, to prevent a discharged battery leakage, which may corrrode the circuitry in the iPod.
    Hopefully you don't get the dreaded RED X on the iPod screen.
    Good Luck!

  • Creating Database view starting with m_z

    Hi,
    How to create a database view starting with m_z without using access key. Please help in this.

    Hi,
    You cannot create the Database view with namespace M_Z any custom objects should be created with Y/Z/ if you want to create the Objects using other than these namespace..you need have access key from SAP.
    You need to buy the Namespace from SAP to create the custom object M_Z*

  • Database accidently started with lower version binary.

    We recently upgraded and patched a version 9206 database to 9208. However, after this was done the database was bounced and accidently started with the 9206 binary and it has been running this way for a couple of weeks. My fix is to shut the database down as 9206, reset the environment to 9208 and restart. Is that all I need to do? Any feedback would be appreciated. Thanks

    Thanks Mike. Just to clarify. The database was a 9208 database at the end of the upgrade. The upgrade to 9208 completed successfully and then I applied the AprCPU2008 patch.
    When we upgrade databases we install a brand new binary patched to the level we want to upgrade to. Then we open the database, in migrate mode, using the new binary and run the catpatch and utlrp. So for a short time I have both the 9208 and 9206 binaries available.
    What happened is that the server the database was on, in a Veritas cluster, was patched the next day. The Veritas resource setting for startup had not yet been changed to use 9208, so when the database came back up after the server patching Veritas used the 9206 OracleHome and binary to start the database.
    So is my fix. "Just shutdown the database using the 9206 binary change the database environment to use the 9208 binary and restart and be done with it." valid. So I really have a 9208 database that was started with a 9206 OracleHome. Hopefully that makes sense.
    Jon P

  • Do people auto start with init?

    Hi. I was just wondering whether it is a common practice to auto start an entire stack (e.g. Node Manager, Admin Server(s), Management Server(s)) all via init scripts+chkconfig?
    I have been doing this for Oracle Application Server, now requested to do this for WebLogic Server so that someone can bootup/shutdown/restart the OS without care.
    What do you guys think?

    Hi,
    But general common practice is starting nodemanager as background process. Starting AdminServer and Managed Servers is based on customer's requirement.
    Thanks & Regards,
    Murali.
    ============

  • Auto Start, with no theme

    Hello Folks,
    I am new here and found the FCP discussion to be very helpful, so.... here I am.
    I have just updated to iLife 06' and have a question. I don't want a theme whatsoever. I want the DVD to be able to start when it is loaded into the DVD player without having to push menu buttons; Although I have completed the first task of dropping the clip into the auto start area, I do not know how to get rid of the theme. Please help.....
    Thank you in advance, as this is probably a novice question to the talent on this discussion board.
    CR

    Thank you for all who replied! My question did get answered, and I also found another method...... DVD Studio Pro Thanks again.
    Oh, by the way.. I do not see the area where I could put that these answers were helpful (they were).
    CR
    CR
    PowerMac G5 Mac OS X (10.4.6)

  • Database not start with srvctl  command in rac 10g

    hi
    when i change parameter in sqlnet file
    SQLNET.AUTHENTICATION_SERVICES= (NTS) to SQLNET.AUTHENTICATION_SERVICES= (NONE)
    then database is not started with srvctl utillity but started with sqlplus enviroment.
    please help in this issue

    user521214 wrote:
    hi,
    we are implementing security policy for our client. our databas is on RAC . As per the security, we need to revoke sys dba priviliges. when i used SQLNET.AUTHENTICATION_SERVICES=(NTS) in sqlnet.ora or SQLNET.AUTHENTICATION_SERVICES=(NONE). the instance not start with the following command in rac 10g.
    $srvctl start database -d abc
    $ crs_stat -t
    Name Type Target State Host
    ora.db.db application OFFLINE OFFLINE
    ora....b1.inst application ONLINE OFFLINE hosttest01
    Edited by: user521214 on Apr 21, 2011 4:08 AMIs this the only parameter you changed? What happens when you undo this modification?
    What do you see on log files?

  • Want my DVDs to auto start with the main menu when inserted into a player

    I used idvd to burn an imovie that I made. I have a main menu theme from idvd on the project but when I insert the dvd into a dvd player or computer, the project automatically starts playing without going to the main menu first. How can I make it so it goes to the main menu first, allowing me the chance to click the button I made on the menu to play the project. THANK YOU SOO MUCH FOR ANY HELP!!

    By default, projects created with iDVD will always go to the menu screen first. If it doesn't that usually means you made a change to the iDVD map.
    To check, click on the "Map" button (Three small squares joined by a line at the bottom of the screen).
    Take a look at the far left menu square. If there is anything in this square it will play that square first before going to the menu.
    Click on that left hand square and tap the delete key to remove the auto-play item.
    Hope that helps.

  • MacBook Auto Start with power?

    MacBook Pro is starting up whenever there is any power available to it. It doesn't matter is the AC Adapter is plugged in or not.
    Plug in the power adapter: it turns on.
    Shut down: turns back on
    Shut down with no power adapter: turns back on!
    Shut down with as little battery as I can possibly have: TURNS BACK ON.
    I've looked for the option to turn on after power faliure, I can't find such an option. I've done the Shift-Option-Command and the Option-Command-P-R,  no avail.
    Don't know if this has any relation, but my Bluetooth has disapeared as well. Recently installed a new hardrive, do you think perhaps I accidently disconneceted something?

    Thank you for all who replied! My question did get answered, and I also found another method...... DVD Studio Pro Thanks again.
    Oh, by the way.. I do not see the area where I could put that these answers were helpful (they were).
    CR
    CR
    PowerMac G5 Mac OS X (10.4.6)

  • How to make the listener auto start with OS?

    Using: 10gR2 (10.2.0.3) RAC +ASM 64bit  &  11g Gateway (11.1.0.7) 64bit
    2 Node Cluster
    Platform: SUSE Linux Enterprise Server 8 (x86_64) (kernel: 2.6.5-7.276-smp)
    I have a two node cluster that uses a 10gR2 DB home. I have setup a 11g Gateway home to allow the 10gR2 Home to connect to an AS/400 system.
    The Heterogeneous connection works perfectly.
    The problem is that when I reboot the nodes the 11g Gateway listener doesn't startup with the OS.
    Question: How can I setup my OS to have the listener startup at system boot?
    Currently, I have to manually set ORACLE_SID, change to 11g Gateway home and start the listener.
    Thanks,
    (BLL)

    user10860953 wrote:
    My initial research (google) the subject of "oracle 10g adding listener clusterware" finds plenty of hits for adding instances to the cluster.
    I was less successful with finding information on adding a listener as a node app.
    Any suggestions on a reference article?
    The way to add applications is documented in the Admin Guide.
    Would not the netca (run under 11g) achieve the same?

  • How to automate the Oracle database start and shutdown process

    How we can automate and oracle database start and stop procees with Linux start/shutdown process.
    I want to automatically start the oracle database at the time linux server and shutdown the database on shutdown linux server.

    Hi,
    I can share my scripts:
    1) /home/oracle/start_oracle.sh
    #Script should be ran as Oracle user
    cd /tmp
    export ORACLE_SID=orcl
    export ORACLE_HOME=/oracle/ora9i
    lsnrctl start
    sqlplus -S /nolog <<ENDSQL
    connect / as sysdba
    startup
    exit
    ENDSQL
    emctl start dbconsole
    isqlplusctl start
    NOTE: emctl and isqlplus are optional
    2) /home/oracle/stop_oracle.sh
    #Script should be ran as Oracle user
    cd /tmp
    export ORACLE_SID=orcl
    export ORACLE_HOME=/oracle/ora9i
    isqlplusctl stop
    emctl stop dbconsole
    sqlplus -S /nolog <<ENDSQL
    connect / as sysdba
    shutdown immediate
    exit
    ENDSQL
    lsnrctl stop
    NOTE: emctl and isqlplus are optional
    Then what you need:
    1) K91oracle_stop (put it in the desired run level)
    #!/bin/bash
    # description: Stop Oracle before reboots
    su - oracle -c "/home/oracle/stop_oracle.sh" >> /home/oracle/stoporacle.log
    2) S91oracle_start (put it in the desired run level)
    #!/bin/bash
    # description: Start Oracle after reboots
    su - oracle -c "/home/oracle/start_oracle.sh" >> /home/oracle/startoracle.log
    Bye.

Maybe you are looking for