Oracle beginner backup problems (two problems)
Question 1: I want to learn how to use RMAN to back up and restore a database. I can see from the Internet and books that the log_mode of the database is required.
It is in archivelog mode, and my mode is as follows:
SQL> select dbid, name, log_mode, current_scn from V $ database;
Dbid name log_mode current_scn
------------------------------------------
3574435446 EMS noarchivelog 12605597
How can I change log_mode to archivelog?
Question 2: If I have two database cases: EMS and domo
Currently, I am using EMS. to change it to domo, do I need to modify the following parameters? The procedure is as follows:
1) Regedit: Set "Database Name" to the default service (two services in total): HKEY_LOCAL_MACHINE | SOFTWARE |
Change the value of oracle_sid under ORACLE | home0 to "Database Name" and change EMS TO domo
2) modify the tnsnames. ora file, for example:
Demo =
(Description =
(Address_list =
(Address = (Protocol = TCP) (host = 192.168.1.79) (Port =
1521 ))
)
(CONNECT_DATA =
(SERVICE_NAME = demo)
)
(Server = dedicated)
)
I want to ask, is that all done? You do not need to modify the listener. ora file as follows:
Sid_list_listener =
(Sid_list =
(Sid_desc =
(Sid_name = plsextproc)
(ORACLE_HOME = D: \ oracle \ product \ 10.1.0 \ db_1)
(Program = EXTPROC)
)
)
(Sid_desc =
(Global_dbname = EMS)
(ORACLE_HOME = D: \ oracle \ product \ 10.1.0 \ db_1)
(Sid_name = EMS)
)
Change EMS TO domo
To be resolved... (The solution is as follows :)
Question 1:
1. Shutdown immediate;
2. startup Mount;
3. Alter database archivelog;
5. Alter system set log_archive_start = true scope = spfile;
6. Alter system set log_archive_dest = 'd: \ backup 'scope = spfile;
7. Shutdown immediate;
8. startup;
9. Select dbid, name, log_mode, current_scn from V $ database;
Question 2:
I want to ask, is that all done? You do not need to modify the listener. ora file as follows:
Sid_list_listener =
(Sid_list =
(Sid_desc =
(Sid_name = plsextproc)
(ORACLE_HOME = D: \ oracle \ product \ 10.1.0 \ db_1)
(Program = EXTPROC)
)
)
(Sid_desc =
(Global_dbname = EMS)
(ORACLE_HOME = D: \ oracle \ product \ 10.1.0 \ db_1)
(Sid_name = EMS)
)
Change EMS TO domo
Add the demo instance to the Registry.
sid_list_listener =
(sid_list =
(sid_desc =
(sid_name = plsextproc)
(ORACLE_HOME = D: \ oracle \ product \ 10.1.0 \ db_1)
(program = EXTPROC)
)
(sid_desc =
(global_dbname = EMS)
(ORACLE_HOME = D: \ oracle \ product \ 10.1.0 \ db_1)
(sid_name = EMS)
(global_dbname = demo)
(ORACLE_HOME = D: \ oracle \ product \ 10.1.0 \ db_1)
(sid_name = demo)
)