Skip to Main Content
  • Questions
  • Can't connect to Enterprise Manager, receive message "Connection reset by peer"

Breadcrumb

Question and Answer

Connor McDonald

Thanks for the question, Dima.

Asked: March 03, 2020 - 12:43 pm UTC

Last updated: March 31, 2020 - 12:46 am UTC

Version: 12C R2

Viewed 1000+ times

You Asked

Hello Tom,

I have been straggling a few days with issue of connecting to Oracle Enterprise Manager.

Please see my configurations:

OS: Oracle Linux 7
Database: Oracle Base 12C R2

product/12.2.0/dbhome_1/network/admin/tnsnames.ora

LISTENER_ORCL =
  (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))

ORCL =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = orcl)
    )
  )

ORCLPDB =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = orclpdb)
    )
  )




product/12.2.0/dbhome_1/network/admin/listener.ora

LISTENER =
  (DESCRIPTION_LIST =

    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = 127.0.0.1)(PORT = 1521))
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
      (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.0.11)(PORT = 1521))
    )

    #(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=5500))(Presentation=HTTP)(Session=RAW))
    #(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.0.11)(PORT=5500))(Presentation=HTTP)(Session=RAW))
    #(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost)(PORT=5501))(Presentation=HTTPS)(Session=RAW))
    #(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.0.11)(PORT=5501))(Presentation=HTTPS)(Session=RAW))
  )





$ lsnrctl status

LSNRCTL for Linux: Version 12.2.0.1.0 - Production on 03-MAR-2020 00:13:40

Copyright (c) 1991, 2016, Oracle.  All rights reserved.

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=127.0.0.1)(PORT=1521)))
STATUS of the LISTENER
------------------------
Alias                     LISTENER
Version                   TNSLSNR for Linux: Version 12.2.0.1.0 - Production
Start Date                02-MAR-2020 23:50:59
Uptime                    0 days 0 hr. 22 min. 41 sec
Trace Level               off
Security                  ON: Local OS Authentication
SNMP                      OFF
Listener Parameter File   /home/dima/app/dima/product/12.2.0/dbhome_1/network/admin/listener.ora
Listener Log File         /home/dima/app/dima/diag/tnslsnr/server/listener/alert/log.xml
Listening Endpoints Summary...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.0.11)(PORT=1521)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=5500))(Presentation=HTTP)(Session=RAW))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcps)(HOST=server.router3ba458.com)(PORT=5501))(Security=(my_wallet_directory=/home/dima/app/dima/product/12.2.0/dbhome_1/admin/orcl/xdb_wallet))(Presentation=HTTP)(Session=RAW))
Services Summary...
Service "7f2253409fff7340e055000000000001" has 1 instance(s).
  Instance "orcl", status READY, has 1 handler(s) for this service...
Service "orcl" has 1 instance(s).
  Instance "orcl", status READY, has 1 handler(s) for this service...
Service "orclXDB" has 1 instance(s).
  Instance "orcl", status READY, has 1 handler(s) for this service...
Service "orclpdb" has 1 instance(s).
  Instance "orcl", status READY, has 1 handler(s) for this service...
The command completed successfully





SQL> select dbms_xdb_config.gethttpport() from dual;

DBMS_XDB_CONFIG.GETHTTPPORT()
-----------------------------
    5500





SQL> show parameters dispatcher

NAME         TYPE  VALUE
------------------------------------ ----------- ------------------------------
dispatchers        string  (PROTOCOL=TCP) (SERVICE=orclXD
       B)
enable_dnfs_dispatcher       boolean  FALSE
max_dispatchers        integer






SQL> select value from v$parameter where name='local_listener';

VALUE
--------------------------------------------------------------------------------
LISTENER_ORCL






Everything seems okay, but for same reason I got connection error:

$ curl http://127.0.0.1:5500/em
curl: (56) Recv failure: Connection reset by peer





I have tried to connect to EM for all possible IPs and domains:

http://server.loc:5500/em/login
http://localhost:5500/em/login
http://127.0.0.1:5500/em/login
http://192.168.0.11:5500/em/login

But no luck.

Please help me solve this issue as I have no idea why EM doesn't work.
I'm not sure if issue in EM or somewhere in connection.

Firewall is turned off. I can successfully connect to Oracle database and WebLogic that installed on the same server.

$ netstat -lnt | grep 5500
tcp        0      0 127.0.0.1:5500          0.0.0.0:*               LISTEN


$ nmap localhost -p 5500

Starting Nmap 6.40 ( http://nmap.org ) at 2020-03-03 12:45 GMT
Nmap scan report for localhost (127.0.0.1)
Host is up (0.000056s latency).
Other addresses for localhost (not scanned): 127.0.0.1
PORT     STATE SERVICE
5500/tcp open  hotline

Nmap done: 1 IP address (1 host up) scanned in 0.03 seconds


Thank you.

and Connor said...

Change http to https and you should be OK

[oracle@db122 bin]$ curl -k http://localhost:5500/em
curl: (56) Recv failure: Connection reset by peer
[oracle@db122 bin]$ curl -k https://localhost:5500/em
HTTP/1.1 200 OK
MS-Author-Via: DAV
DAV: 1,2,<http://www.oracle.com/xdb/webdav/props>
Server: Oracle XML DB/Oracle Database
Location: /em/login



Rating

  (1 rating)

Is this answer out of date? If it is, please let us know via a Comment

Comments

A reader, March 30, 2020 - 2:07 pm UTC

Thank you for your time to answer.

I have tried use HTTPS but it wasn't successfully.

Solution that helps me is attache Ethernet cable to another Ethernet port. I'm running Oracle on bare metal server with 4 Ethernet ports.
When cable was accidentally attached to another port EM got work.

However, I have no idea where was an issue...
My network settings were pretty straightforward.
Firewall is turned off.

Thank you.
Connor McDonald
March 31, 2020 - 12:46 am UTC

glad you got to the bottom of it

More to Explore

Administration

Need more information on Administration? Check out the Administrators guide for the Oracle Database