Oracle12c环境中,EM不需要单独安装配置了,创建数据库的时候勾选EM express即可。因为很多功能都转移到了SQL developer里,所以12c的EM叫EM express。
如果在安装数据库的时候未勾选EM express,则可以通过以下步骤手工配置(参考官方文档):
Step1.Configure and start the Oracle Net Listener (the listener).
Step2.init.ora(when the listener is running on a non standard port )
init.ora local_listener=inst1
where inst1 is a TNSNAMES entry defined in tnsnames.ora that points to the listener.
For example :tnsnames.ora
inst1= (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=host_name)(PORT=1234))(CONNECT_DATA=(SERVICE_NAME=service_name)(SERVER=DEDICATED)))
Step3. Enable the TCP dispatcher by adding the following entry to the init.ora file for the database you want to manage using EM Express:
dispatchers="(PROTOCOL=TCP)(SERVICE=XDB)"
例如:dispatchers="(PROTOCOL=TCP)(SERVICE=ORCLXDB)"For example:
Step4. Restart the database so that the changes made in the init.ora file take effect.
Configure 5500 for EM Express
netstat -aon|findstr "5500" --检查确定该端口没有被占用
SQL> show parameter dispatchers;
SQL> exec DBMS_XDB_CONFIG.SETHTTPSPORT(5500);
数据库安装后如何访问EM express:
执行:lsnrctl status
找到下面类似内容:
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcps)(HOST=hostname)(PORT=5500))(Security=.....这部分有对应的sid信息)
则该数据库的EM express的URL为:https://hostname:5500/em
如果PROTOCOL=tcps是tcp,就要把https换成http,URL最后不要忘了加上/em,否则会弹出一个“需要验证”的窗口,也会提示输入用户名和密码。
通过数据库查看em端口:
select dbms_xdb_config.gethttpsport() from dual;
select dbms_xdb_config.gethttpport() from dual;
设置em端口:
可以通过以下命令将em端口从5500更改为5502
exec dbms_xdb_config.setHTTPSport();
exec DBMS_XDB_CONFIG.setHTTPPort(5502);
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/31403259/viewspace-2141933/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/31403259/viewspace-2141933/