After the Oracle installation is complete, how do I start and close the database with the command line?

Source: Internet
Author: User

After the Oracle installation is complete, how do I start and close the database with the command line?

Answer:

Open: STARTUP [Force] [RESTRICT] [pfile= filename] [open [recover][Database] | MOUNT | Nomount] STARTUP open:startup The default parameter is open, which opens the database, allowing access to the database. All files that are described in the control file for the current instance are already open. The STARTUP mount:mount database, which only manages the DBA, does not allow access to the database user. Only the control file for the current instance is opened and the data file is not open. Startup Nomount: Simply initialize the file, allocate the SGA area, start the database background process, do not open the control files and data files. Cannot access any database. Startup pfile= FileName: Starts the database with filename as the initialization file, not the default initialization file. Startup force: Aborts the running of the current database and begins a normal startup of the database. STARTUP RESTRICT: Only users with restricted session permissions are allowed to access the database. Startup RECOVER: Database starts, and media recovery begins

Shut down

Shutdown has four parameters: NORMAL, transactional, IMMEDIATE, ABORT. The default is normal if no parameters are taken.

Command shutdown NORMAL: Do not allow new connections, wait for the session to end, wait for the transaction to end, make a checkpoint, and close the data file. No instance recovery is required at startup. SHUTDOWN transactional: Does not allow a new connection, does not wait for the session to end, waits for the transaction to end, makes a checkpoint, and closes the data file. No instance recovery is required at startup. SHUTDOWN IMMEDIATE: Do not allow a new connection, do not wait for the session to end, do not wait for the transaction to end, make a checkpoint, and close the data file. Transactions that do not end are automatically rollback. No instance recovery is required at startup. SHUTDOWN ABORT: Do not allow new connections, do not wait for the session to end, do not wait for the transaction to end, do not checkpoint, and do not close the data file. Automatic instance recovery on startup. In addition, the contents of the normal, transactional, immediate,db Buffer cache are written to the data file, no committed transactions are rolled back, all resources are freed, and the database is "cleanly" closed. The contents of the Abort,db Buffer cache are not written to the data file, and no committed transactions are rolled back. The database is not dismount and closed, and the data file is not closed. When the database starts, it needs to recover data via redo log, by rolling back

The segment rolls back the transaction, freeing the resource.

After the Oracle installation is complete, how do I start and close the database with the command line?

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.