In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Three steps to start oracle
Oracle startup will go through three processes, namely, nomount, mount, and open
I. nomount stage
In the nomount phase, you can see that the instance has been started. The oracle process creates a shared memory pool based on the parameter file.
SQL > startup nomount;ORACLE instance started.Total System Global Area 1653518336 bytesFixed Size 2213896 bytesVariable Size 956303352 bytesDatabase Buffers 687865856 bytesRedo Buffers 7135232 bytesSQL >
You can see that shared memory has been opened up.
[root@localhost dbs] # ipcs-m-Shared Memory Segments-key shmid owner perms bytes nattch status 0x00000000 98304 oracle 393216 2 dest 0x00000000 131073 oracle 600 393216 2 dest 0x00000000 163842 oracle 600393216 2 dest 0x00000000 196611 oracle 600 393216 2 dest 0x00000000 229380 oracle 600 393216 2 dest 0x00000000 262149 oracle 600 393216 2 dest 0x00000000 294918 oracle 600 393216 2 dest 0x00000000 327687 oracle 600 393216 2 dest 0x00000000 360456 oracle 600 393216 2 dest 0x33554094 1048585 oracle 660 4096 0 0x00000000 425994 oracle 600 393216 2 dest 0x00000000 458763 oracle 600 393216 2 dest 0x00000000 491532 oracle 600 393216 2 dest 0x00000000 524301 oracle 600 393216 2 dest 0x00000000 557070 oracle 600 393216 2 dest 0x00000000 688143 oracle 600 393216 2 dest 0x00000000 720912 oracle 600 393216 2 dest
The process has started.
Oracle 2965 1 0 04:44? 00:00:00 ora_pmon_testoracle 2967 1 0 04:44? 00:00:00 ora_vktm_testoracle 2971 1 0 04:44? 00:00:00 ora_gen0_testoracle 2973 1 0 04:44? 00:00:00 ora_diag_testoracle 2975 1 0 04:44? 00:00: 00 ora_dbrm_testoracle 2977 1 0 04:44? 00:00:00 ora_psp0_testoracle 2979 1 0 04:44? 00:00:00 ora_dia0_testoracle 2981 1 0 04:44? 00:00:01 ora_mman_testoracle 2983 1 0 04:44? 00:00:00 ora_dbw0_testoracle 2985 1 0 04:44? 00:00:00 ora_lgwr_testoracle 2987 1 0 04:44? 00:00:00 ora_ckpt_testoracle 2989 1 0 04:44? 00:00:00 ora_smon_testoracle 2991 1 0 04:44? 00:00:00 ora_reco_testoracle 2993 1 0 04:44? 00:00:00 ora_mmon_testoracle 2995 1 0 04: 44? 00:00:00 ora_mmnl_testoracle 2997 1 0 04:44? 00:00:00 ora_d000_testoracle 2999 1 0 04:44? 00:00:00 ora_s000_test
View parameter profile location
SQL > show parameter spfileNAME TYPE VALUE -spfile string / u01/app/oracle/product/11.2.4 / db_1/dbs/spfiletest.oraSQL >
Startup nomount after the configuration file is removed, the error is as follows:
SQL > startup nomount;ORA-01078: failure in processing system parametersLRM-00109: could not open parameter file'/ u01/app/oracle/product/11.2.4/db_1/dbs/inittest.ora'SQL > II. Mount stage
In the mount stage, oracle will find the name and location of the control file according to the parameter file of the nomount phase. Once found, the control file will be locked immediately, and the very important information such as data file, log file, checkpoint information in the database will be recorded in the control file. When starting mount, nomount will be started automatically first.
Startup mount
As you can see in the mount phase, there is one more hint for database mounted than in the nomount phase.
SQL > startup mount;ORACLE instance started.Total System Global Area 1653518336 bytesFixed Size 2213896 bytesVariable Size 956303352 bytesDatabase Buffers 687865856 bytesRedo Buffers 7135232 bytesDatabase mounted.SQL >
View control file location
SQL > show parameter controlNAME TYPE VALUE -control_file_record_keep_time integer 7control_files string / u01/app/oracle/oradata/test/c ontrol01.ctl / u01/app/oracle/ flash_recovery_area/test/contr ol02.ctlcontrol_management_pack_access string DIAGNOSTIC+TUNINGSQL >
Remove the configuration file and start it again.
SQL > startup mount;ORACLE instance started.Total System Global Area 1653518336 bytesFixed Size 2213896 bytesVariable Size 956303352 bytesDatabase Buffers 687865856 bytesRedo Buffers 7135232 bytesORA-00205: error in identifying control file, check alert log for more infoSQL > III, open stage
According to the information recorded in the control file, the open phase will locate the database file, log file, and so on, and formally open the bridge between the instance and the database. If the data file or log file is missing, the open fails.
After open, if you use the archive log feature, you can see the progress of the archive log.
SQL > alter database open;Database altered.SQL >
View log files and location of log files
SQL > select file_name from dba_data_files;FILE_NAME---/u01/app/oracle/oradata/test/users01.dbf/u01/app/oracle/oradata/test/undotbs01.dbf/u01/app/oracle/oradata/test/sysaux01.dbf/u01/app/oracle/oradata/test/system01.dbfSQL > SQL > select group#,member from v$logfile GROUP# MEMBER-- 3 / u01/app/oracle/oradata/test/redo03.log 2 / u01/app/oracle/oradata/test/redo02.log 1/ u01/app/oracle/oradata/test/redo01.log
Start after moving a data file, and the error is as follows
SQL > startup;ORACLE instance started.Total System Global Area 1653518336 bytesFixed Size 2213896 bytesVariable Size 956303352 bytesDatabase Buffers 687865856 bytesRedo Buffers 7135232 bytesDatabase mounted.ORA-01157: cannot identify/lock data file 4-see DBWR trace fileORA-01110: data file 4:'/ u01/app/oracle/oradata/test/users01.dbf'SQL >
Is it okay if I copy any file into it? Start as follows:
SQL > alter database open;alter database open*ERROR at line 1:ORA-01122: database file 4 failed verification checkORA-01110: data file 4:'/ u01/app/oracle/oradata/test/users01.dbf'ORA-01210: data file header is media corrupt Summary
We can use statup to start the oracle database, or we can use shutdwon to shut down. If you start with startup, you have already gone through three processes.
In general, without parameter files, the instance cannot be created, the database cannot nomount successfully, there is no configuration file, the database cannot mount; without data files, and the database cannot be opened and used.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.