今天在用dbca创建数据库时,自动配置EM时报错,通过安装日志文件查看,发现以下错误:
Mar 25, 2011 4:52:03 PM oracle.sysman.emcp.EMConfig perform
CONFIG: Stack Trace:
oracle.sysman.emcp.exception.EMConfigException: Failed to allocate port(s) in the specified range(s)
for the following process(es): JMS [5540-5559],RMI [5520-5539],Database Control [5500-5519],EM Agent [3938] | [1830-1849]
at oracle.sysman.emcp.EMDBPreConfig.checkPorts(EMDBPreConfig.java:2266)
at oracle.sysman.emcp.EMDBPreConfig.performConfiguration(EMDBPreConfig.java:670)
at oracle.sysman.emcp.EMDBPreConfig.invoke(EMDBPreConfig.java:233)
at oracle.sysman.emcp.EMDBPreConfig.invoke(EMDBPreConfig.java:160)
at oracle.sysman.emcp.EMConfig.perform(EMConfig.java:141)
at oracle.sysman.assistants.util.em.EMConfiguration.run(EMConfiguration.java:426)
at java.lang.Thread.run(Thread.java:534)
后来发现是我的机器改过机器名,但/etc/hosts中没有改过来造成的
将/etc/hosts中改过来,并重新配置成功。
该错误,也有可能是端口被占用的原因,可指定其它端口并重新配置:
emca -config dbcontrol db -DBCONTROL_HTTP_PORT 5508 -AGENT_PORT 3940 -RMI_PORT 5524 -JMS_PORT 5545
再停用一次EM,再启动EM,就好了.
emctl stop dbconsole
emctl start dbconsole
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/618537/viewspace-690524/
,如需转载,请注明出处,否则将追究法律责任。