dbca报错java.lang.ClassNotFoundException: oracle.sysman.oii.oiii.OiiiInstallInventory

有个AIX单实例的环境dbca无法创建数据库,后来发现dbca  -help都报错

nzo2pdb:/u01/app/oracle/product/11.2.0/db_1/bin>dbca -help
Exception in thread "main" java.lang.NoClassDefFoundError: oracle.sysman.oii.oiii.OiiiInstallInventory
        at java.lang.J9VMInternals.verifyImpl(Native Method)
        at java.lang.J9VMInternals.verify(J9VMInternals.java:69)
        at java.lang.J9VMInternals.initialize(J9VMInternals.java:131)
        at oracle.sysman.assistants.util.OracleHome.getNodeNames(OracleHome.java:332)
        at oracle.sysman.assistants.util.OracleHome.isClusterInstalled(OracleHome.java:307)
        at oracle.sysman.assistants.dbca.backend.CommandLineArguments.<init>(CommandLineArguments.java:405)
        at oracle.sysman.assistants.dbca.Dbca.execute(Dbca.java:95)
        at oracle.sysman.assistants.dbca.Dbca.main(Dbca.java:189)
Caused by: java.lang.ClassNotFoundException: oracle.sysman.oii.oiii.OiiiInstallInventory
        at java.net.URLClassLoader.findClass(URLClassLoader.java:499)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:650)
        at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:616)
        ... 8 more

dbca报错,搜索了一些资料,更改部分环境变量也没有解决

因为不是我装的数据库软件,不知道前面runinstaller有什么问题,所以干脆直接把环境卸载了重装。

 

-----deinstall
rm -rf /u01/app/oracle/*
rm -rf $ORACLE_HOME
rm -rf /etc/ora*
rm -rf /tmp/*
rm /usr/local/bin/dbhome
rm /usr/local/bin/oraenv
rm /usr/local/bin/coraenv

 

--install

--跑下下面的命令

chmod -R 775 /u01
chuser capabilities=CAP_NUMA_ATTACH,CAP_BYPASS_RAC_VMM,CAP_PROPAGATE oracle
lsuser -a capabilities oracle


chuser nproc='-1' cpu'=-1' fsize='-1' stack='-1' data='-1' stack='-1' rss='-1' nofiles='-1' core='2097151' oracle
chuser nproc='-1' cpu'=-1' fsize='-1' stack='-1' data='-1' stack='-1' rss='-1' nofiles='-1' core='2097151' root

no -r -o ipqmaxlen=512
no -p -o rfc1323=1
no -p -o tcp_recvspace=65536
no -p -o tcp_sendspace=65536
no -p -o udp_recvspace=655360
no -p -o udp_sendspace=65536

--no -p -o sb_max=131072

vmo -p -o minperm%=3
vmo -p -o maxperm%=90
vmo -p -o maxclient%=90
vmo -p -o strict_maxclient=1
vmo -p -o strict_maxperm=0

no -p -o tcp_ephemeral_low=9000 -o tcp_ephemeral_high=65500
no -p -o udp_ephemeral_low=9000 -o udp_ephemeral_high=65500

chdev -l sys0 -a maxuproc=16384

 

--runinstaller安装数据库软件

更改response file安装数据库软件

oracle:./runInstaller -responseFile /u01/database/response/db_install.rsp -silent -ignorePrereq -showProgress
netca -silent -responsefile /u01/app/oracle/product/11.2.0/db_1/assistants/netca

nzo2pdb:/u01/database>./runInstaller -responseFile /u01/database/response/db_install.rsp -silent -ignorePrereq -showProgress
********************************************************************************

Your platform requires the root user to perform certain pre-installation
OS preparation.  The root user should run the shell script 'rootpre.sh' before
you proceed with Oracle installation.  rootpre.sh can be found at the top level 
of the CD or the stage area.

Answer 'y' if root has run 'rootpre.sh' so you can proceed with Oracle 
installation.
Answer 'n' to abort installation and then ask root to run 'rootpre.sh'.

********************************************************************************

Has 'rootpre.sh' been run by root? [y/n] (n)
y

Starting Oracle Universal Installer...

Checking Temp space: must be greater than 190 MB.   Actual 6280 MB    Passed
Checking swap space: must be greater than 150 MB.   Actual 16384 MB    Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2018-10-09_11-21-50AM. Please wait ...nzo2pdb:/u01/database>You can find the log of this install session at:
 /u01/app/oraInventory/logs/installActions2018-10-09_11-21-50AM.log

Prepare in progress.
..................................................   9% Done.

Prepare successful.

Copy files in progress.
..................................................   14% Done.
..................................................   19% Done.
..................................................   24% Done.
..................................................   29% Done.
..................................................   34% Done.
..................................................   39% Done.
..................................................   44% Done.
....................
Shell will time out in 60 seconds.
..............................   50% Done.
..................................................   55% Done.
..................................................   60% Done.
..................................................   65% Done.
..................................................   70% Done.
..........
Copy files successful.

Link binaries in progress.
..........ksh: Timed out waiting for input.
[nzo2pdb:root:/u01/database] 
Link binaries successful.
..................................................   77% Done.

Setup files in progress.
..................................................   94% Done.

Setup files successful.
The installation of Oracle Database 11g was successful.
Please check '/u01/app/oraInventory/logs/silentInstall2018-10-09_11-21-50AM.log' for more details.

Execute Root Scripts in progress.

As a root user, execute the following script(s):
        1. /u01/app/oraInventory/orainstRoot.sh
        2. /u01/app/oracle/product/11.2.0/db_1/root.sh


..................................................   100% Done.

Execute Root Scripts successful.
Successfully Setup Software.

跑完2个root脚本,数据库软件便安装完成

 

--dbca监控

nzo2pdb:/u01/app/oracle>params db_create_online_log_dest_1='/u01/app/oracle/oradata/o2pdb/'  -sysPassword Oracle1234 -systemPassword Oracle1234 -memoryPercentage 30          <
Copying database files
1% complete
3% complete
11% complete
18% complete
26% complete
37% complete
Creating and starting Oracle instance
100% complete
Look at the log file "/u01/app/oracle/cfgtoollogs/dbca/o2pdb/o2pdb.log" for further details.
nzo2pdb:/u01/app/oracle>ps -ef|grep ora_

这里报错了,查看日志文件,发现控制文件没有成功创建

nzo2pdb:/u01/app/oracle>more /u01/app/oracle/cfgtoollogs/dbca/o2pdb/o2pdb.log
Copying database files
File "/etc/oratab" is not accessible. 
DBCA_PROGRESS : 1%
DBCA_PROGRESS : 3%
DBCA_PROGRESS : 11%
DBCA_PROGRESS : 18%
DBCA_PROGRESS : 26%
DBCA_PROGRESS : 37%
Creating and starting Oracle instance
ORA-01503: CREATE CONTROLFILE failed
ORA-00200: control file could not be created
ORA-00202: control file: '/u01/app/oracle/fast_recovery_area/o2pdb/control02.ctl'
ORA-27040: file create error, unable to create file

ORA-01503: CREATE CONTROLFILE failed
ORA-00200: control file could not be created
ORA-00202: control file: '/u01/app/oracle/fast_recovery_area/o2pdb/control02.ctl'
ORA-27040: file create error, unable to create file
检查了没有/u01/app/oracle/fast_recovery_area/o2pdb这样的路径

#不能写,创建控制文件时会报错 -initparams db_create_file_dest='/u01/app/oracle/oradata/o2pdb/' -initparams db_create_online_log_dest_1='/u01/app/oracle/oradata/o2pdb/' 

dbca -silent -createDatabase -templateName $ORACLE_HOME/assistants/dbca/templates/General_Purpose.dbc -gdbname o2pdb -sid o2pdb -characterSet ZHS16GBK  -nationalCharacterSet AL16UTF16  -responseFile NO_VALUE -emConfiguration NONE  -sysPassword Oracle1234 -systemPassword Oracle1234 -memoryPercentage 30 

Cleaning up failed steps
5% complete
Copying database files
7% complete
9% complete
16% complete
23% complete
30% complete
41% complete
Creating and starting Oracle instance
43% complete
48% complete
53% complete
57% complete
58% complete
59% complete
62% complete
64% complete
Completing Database Creation
68% complete
71% complete
75% complete
85% complete
96% complete
100% complete
Look at the log file "/u01/app/oracle/cfgtoollogs/dbca/o2pdb/o2pdb0.log" for further details.
nzo2pdb:/u01/app/oracle/oradata/o2pdb>
nzo2pdb:/u01/app/oracle/oradata/o2pdb>ps -ef|grep smon
  oracle  6619318        1   0 11:58:34      -  0:00 ora_smon_o2pdb
  oracle 22937786  6291588   0 12:00:17  pts/1  0:00 grep smon

创建完成

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

liuzhilongDBA

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值