Not much to say, first write my reference address: https://blog.csdn.net/testleaf/article/details/105303336
Explain in advance, if you refer to the original text and find that you are stuck in operation 1 of the sixth step, You can come back and read this article of mine
Check Linux version
1. Execute the command lsb_release -r to view the system version
2. Upgrade the system in the original text (my system is 7.5, and the installation can be successful without upgrading)
yum -y clean all
yum -y update
Finally, when you see "Complete!", the update is complete.
Finished, check the system version again
lsb_release -r
Download the Oracle19c installation package and pre-installation package
3. Just download the file oracle-database-ee-19c-1.0-1.x86_64.rpm.
Due to the slow downloading of Oracle's official website, the link to the Baidu network disk below is provided. (Original author's network disk)
链接: https://pan.baidu.com/s/1QDDFUGPu39kh7ObmHQTF2g
提取码: leaf
4. Upload the two packages to the root directory of Linux
start installation
5. In the root directory, execute the command to pre-install Oracle19c.
yum -y localinstall oracle-database-preinstall-19c-1.0-1.el7.x86_64.rpm
6. In the root directory, execute the command to install Oracle19c.
yum -y localinstall oracle-database-ee-19c-1.0-1.x86_64.rpm
Environment configuration
7. Initialize the Oracle database
/etc/init.d/oracledb_ORCLCDB-19c configure
我在这里卡住了,后来配置了一个文件就好了
我配置了/etc/hosts文件
vim /etc/hosts
8. Modify the root user password, do remember this step, or you will regret it.
Execute the command passwd, enter 123456 twice, and that's it.
9. Configure environment variables and switch to the oracle user.
Execute the command su-oracle,
execute the command vi .bash_profile,
and add the following content to the document:
export ORACLE_HOME=/opt/oracle/product/19c/dbhome_1
export PATH=$PATH:/opt/oracle/product/19c/dbhome_1/bin
export ORACLE_SID=ORCLCDB
Check if the modification is correct, execute the command
cat .bash_profile
Then execute the command
source .bash_profile
Use database
10. Log in to the oracle database and execute the command
sqlplus / as sysdba
11. Enter the database statement to confirm that the database statement can be executed normally
show pdbs;
12. Change the password of the username system to 123456
alter user system identified by 123456;
Note:
Under the root user authority, you need to enter the account and password to enter the database;
under the oracle user authority, you do not need to enter the account and password to enter the database.
Navicat connect to Oracle database
1. Service name query
Enter the query statement in the database,
select global_name from global_name;
2. Navicat new Oracle connection
Not much to say, first write my reference address: https://blog.csdn.net/testleaf/article/details/105303336