This discussion is archived
4 Replies Latest reply: Jul 19, 2013 2:03 AM by Jimbo RSS

Unreachable host when trying to connect to OEM DB Control

Jimbo Explorer
Currently Being Moderated

Hi,

 

I have installed 11.2.0.3 onto an Oracle Linux 6.3 platform. I have just installed OEM DB Control and from the server console I can run Firefox on the server and logon to OEM.

 

However from my laptop ( on the same network ) I can ping lab1.nms from my laptop and I can do telnet lab1.nms 22 ( i.e. the SSH port - as Linux 6.3 does not use telnet but rather ssh )

 

So I know the local names resolution ( from my hosts file ) on my laptop is correct

 

However when I do both of the following :

 

telnet lab1.nms 1521

telnet lab1.nms 1158

 

Both times the host is unreachable ( yet when I check on the server, the Oracle Listener and OEM are running on the ports above )

It doesn't matter if I use the explicit ip address instead, the host is still unreachable on these port.

 

There is no firewall between my pc and server, I literally have a switch and the server and my laptop plugged into it ( so effectively all ports with a service on it, should be open ). Is this something with Windows pc to Linux server communication ? Is it something to do with port reservations on Linux ?

 

any help appreciated,

Jim

  • 1. Re: Unreachable host when trying to connect to OEM DB Control
    EdStevens Guru
    Currently Being Moderated

    Jimbo wrote:

     

    Hi,

     

    I have installed 11.2.0.3 onto an Oracle Linux 6.3 platform. I have just installed OEM DB Control and from the server console I can run Firefox on the server and logon to OEM.

     

    However from my laptop ( on the same network ) I can ping lab1.nms from my laptop and I can do telnet lab1.nms 22 ( i.e. the SSH port - as Linux 6.3 does not use telnet but rather ssh )

     

    So I know the local names resolution ( from my hosts file ) on my laptop is correct

     

    However when I do both of the following :

     

    telnet lab1.nms 1521

    telnet lab1.nms 1158

     

    Both times the host is unreachable ( yet when I check on the server, the Oracle Listener and OEM are running on the ports above )

    It doesn't matter if I use the explicit ip address instead, the host is still unreachable on these port.

     

    There is no firewall between my pc and server, I literally have a switch and the server and my laptop plugged into it ( so effectively all ports with a service on it, should be open ). Is this something with Windows pc to Linux server communication ? Is it something to do with port reservations on Linux ?

     

    any help appreciated,

    Jim

     

    That Linux 6.3 server is probably running its own firewall via iptables.

  • 2. Re: Unreachable host when trying to connect to OEM DB Control
    Jimbo Explorer
    Currently Being Moderated

    Yes unknown to me it does appear to be using iptables. therefore I entered the following

     

    iptables -A INPUT -m state --state NEW -m tcp -p tcp --dport 1521 -j ACCEPT

    iptables -A INPUT -m state --state NEW -m tcp -p tcp --dport 1158 -j ACCEPT

    service iptables save

    service iptables reload

     

    iptables -L INPUT -v -n | grep 1521

    iptables -L INPUT -v -n | grep 1158

     

    is now showing a rule for these ports

     

    However from my laptop

    telnet lab1.nms 1521

    telnet lab1.nms 1158

     

    Are still getting -

    Could not open connect to host on port <port>

     

    any ideas of what I am missing ?

    Jim

  • 3. Re: Unreachable host when trying to connect to OEM DB Control
    Dude! Guru
    Currently Being Moderated

    You cannot simply configure your IP firewall this way, because you need to take care of the correct order of all firewall entries. I suggest to simply disable the firewall to see if this helps:

     

    $ su - root

    # service iptables stop

     

    You might also verify that SELinux is disabled or set to permissive in /etc/selinux/config, and restart the system.


    Regarding DB control, note that Grid installer uses the IP address it finds in the first line of /etc/hosts unless you have the ORACLE$HOSTNAME environment variable configured.


    If you change the OS hostname, configure /etc/hosts, chances are that connecting will fail when you start the dbconsole (emctl start dbconsole). If you drop and reinstall the DB repository it will listen to different ports, e.g. 5500. You don't need to reinstall the console repository though:


    cd $ORACLE_HOME
    ln -s localhost_orcl db.example.com_orcl
    cd $ORACLE_HOME/oc4j/j2ee
    ln -s OC4J_DBConsole_localhost_orcl OC4J_DBConsole_db.example.com_orcl

     

    But hopefully your issue is just the Firewall or SELinux.

  • 4. Re: Unreachable host when trying to connect to OEM DB Control
    Jimbo Explorer
    Currently Being Moderated

    stopping the iptables resolved the problem. Thanks

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points