1.停库
[[email protected] ~]$ sqlplus / as sysdba
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> exit
2.停监听
[[email protected] ~]$ lsnrctl stop
LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 23-DEC-2016 14:44:52
Copyright (c) 1991, 2013, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=testdb)(PORT=1521)))
The command completed successfully
3.停HTTP服务
[[email protected] ~]# service httpd stop
Stopping httpd: [ OK ]
4.用su或重新登录到root(如果重新安装可以保留oracle用户)
5.删除安装目录
[[email protected] ~]# rm -rf /u01/app/oracle/
[[email protected] ~]# rm -rf /u01/app/oraInventory/
6.删除/usr/bin下文件
[[email protected] ~]# rm -rf /usr/local/bin/dbhome
[[email protected] ~]# rm -rf /usr/local/bin/oraenv
[[email protected] ~]# rm -rf /usr/local/bin/coraenv
7.删除/etc/oratab
[[email protected] ~]# rm /etc/oratab
8.删除/etc/oraInst.loc
[[email protected] ~]# rm /etc/oraInst.loc
9.删除oracle用户(若要重新安装,可以不删除)
[[email protected] ~]# userdel -r oracle
10.删除用户组(若要重新安装,可以不删除)
[[email protected] ~]# groupdel oinstall
[[email protected] ~]# groupdel dba
11.删除启动服务
到此为止重启后,Linux系统下Oracle数据库已完全删除
总结
以上所述是小编给大家介绍的linux环境下卸载oracle 11g的方法,希望对大家有所帮助,如果大家有任何疑问请给我留言,小编会及时回复大家的。在此也非常感谢大家对我们网站的支持!
如果你觉得本文对你有帮助,欢迎转载,烦请注明出处,谢谢!
文章标题: linux环境下卸载oracle 11g的过程
文章地址: http://www.szneuvisiontec.com/shujuku/211508.html