Rman Connection:
connect to the local database:
1, first specify ORACLE_SID;--if there is only one instance of the database, you do not need to specify it, Rman is connected to a unique instance by default;
>set ORACLE_SID=ORCL
2, then Rman target usr/pwd nocatalog;--so the default is to connect the specified database service name, about the catalog is what mean, I do not know;
>rman Target usr/pwd Nocatalog;
3, you can also do not specify the user name and password Rman target/;--in this way to what identity, I have not checked;
>rman Target/
Of course, you can also start Rman before connecting to the target database via connect;
1, first specify ORACLE_SID
>set ORACLE_SID=ORCL
2. Then Rman
>rman
3. Then connnet target/
> then connnet target/
to connect to a remote database:
If the target database to which you are connecting is a remote database, you must specify a valid network service name when you establish the connection, and you must have the correct configuration of the network service name in your local Tnsname.ora file. Examples are as follows:
1. >rman Target Sys/[email protected]//relies on Tnsname.ora
2, you can first enter the Rman, and then connect; examples are as follows:
>rman
>connect target/@orcl2//To retrieve the path configuration of the service Orcl2 so directly to Tnsname.ora
If you want to not rely on the Tnsname.ora file, you can write:
> Connect target/@zhanglei-pc:1521/orcl2
PS:
1, sqlplus connection remote database is exactly the same, can also be directly @ service name, such as Sqlplus Seem/[email protected], Where SORCL is the service name written in Tnsname.ora; the original sqlplus connection I was written full, do not rely on Tnsname.ora files such as >sqlplus username/password @ip address [: Port]/service_name [AS Sysdba
2. Common Oracle System User/Password: system/manager, Sys/change_on_install, Scott/tiger
3, tnsping---can directly test the database service name is normal, very useful