In this article, we will look how to reset Oracle SYSTEM User Password without old password from backend using SQL Plus.
Here we are going to use oracle 21c however we can follow same process for any version of oracle like oracle 11g, oracle 12c, oracle 18c, oracle 19c, any latest/old oracle database version.
In order to reset password we need to make sure our oracle database is up & running. We will see how you can check it using SQL plus. SQL plus is oracle client which will be installed on windows system along with oracle database.
Check oracle database connectivity using SQL Plus
To launch SQL plus, type SQL Plus in search box on the taskbar & click on it, it will be launched as shown in below screen-shot.
As we can see in screen-shot, we are connected to our oracle 21c database & it’s asking for database credentials to login.
We use default user name SYSTEM & some random password to login.
In next step, we get error “ORA-01017: invalid username/password; logon denied“. This way we can verify our oracle database is running & it’s trying to login using SYSTEM user however it failed with error ORA-01017 as we used in-valid password.
Reset Oracle Password
Now we will use windows command prompt (cmd) to login oracle database which is installed on our local windows system using same windows user.
To launch windows cmd, type cmd in search box on the taskbar & click on it. cmd will be opened as shown in below screen-shot.
Here type below command to login into oracle database using sysdba user without password.
sqlplus / as sysdba
Once we execute above sqlplus command on cmd, we should be able to login oracle database as shown in below screen-shot
.
In SQL terminal, we will use ALTER USER command to reset password for SYSTEM user. Please user ALTER USER followed by user for which we want to reset password followed by keyword IDENTIFIED BY & new password for given user. Below is the sample command to reset password for SYSTEM user.
ALTER USER SYSTEM IDENTIFIED BY pass123;
After successful execution of ALTER USER command we get message “User altered.“
Now again go back to your SQL plus terminal & try to login using SYSTEM user & new password which you set for SYSTEM, we should be able to login into oracle database as shown in below screen-shot with our new password. We can use same password for any other oracle client or code.
That’s all. Hope this article helped you to reset password of your oracle database.
Please don’t forget to leave your feedback in below comments section!!