简体   繁体   中英

how to connect to local oracle database 19c using sysdba

i have install oracle 19c in my PC, but when i want to connect using SQL Plus i cannot login. i got error like this the error is like my password wrong or cannot open.

尝试使用默认密码时出错 when i install the installer not require password. when i try to use default password as password i got error. so how to fix my problem here?? i have try search in internet how to fix it but still got error

i use Windows 10 for this Oracle19c

There's no default password any more; was until (I think) 10g.

If you're logged on to Windows 10 as user who installed Oracle software, then - at the operating system command prompt - run

sqlplus / as sysdba

/ means that Oracle trusts your operating system account as it is recognized as the "owner" of installed Oracle software and should let you in. Once you're logged into the database, change any password you want for any user you want, eg

alter user sys identified by some_new_password;

The TNS: Protocol adapter error usually means you don't have your envirnoment set correctly

Try defining the ORACLE_SID variable with your database name and then connect again /as sysdba

Also, i'd advise you to set your ORACLE_HOME too, if it's not already

set ORACLE_HOME=<YourOracleHomePAth>
set ORACLE_SID=<YourDBName>

There's no default password, the installer should've asked you to set a password for your SYS and SYSTEM users - if you don't remember them, you can always change them, once connected to the Database, by issuing the command

alter user sys identified by <NewPassword>;
alter user system identified by <NewPassword>;

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM