cancel
Showing results for 
Search instead for 
Did you mean: 

SAPINST - Could not connect to <host> on port 21212

former_member229542
Active Participant
0 Kudos

Hi guys

let me introduce a little background of this error.

We are installing Solman on a RHEL 6.3, and using SAPINST for a Remote Installation.

On the Linux side i execute sapinst -nogui

With netstat you can see ports 21200 and 21212 are listening

Then from Windows I run SAPINSTGUI

D:\SM71SR1_IM_WINDOWS_I386>sapinstgui -host sapsolman -port 21212

But the following message appears stating Could not connect to host sapsolman on port 21212

No Route to Host: connect

On etc\host from linux side it was defined IP and host name

from my terminal host file i also defined <IP> <hostname> of SolMan server

This is a very restricted firewall policy so no telnet/ping is allowed

But communication to ports 21212 and 21200 were allowed from my Terminal to SolMan Server

Checking communication logs, you can see there is a communication from my terminal but linux server is not replying anything.


Regarding Java, since we are on RHEL 6.3, we have installed java version 1.7 since 1.4 is not available

Any idea?

Accepted Solutions (1)

Accepted Solutions (1)

gammarayburst
Explorer
0 Kudos

Hello Martin,

I had the same probleme, this is what I did.

Check your Iptables configuration, the basic RHEL 6.3 firewall configuration looks like this:

[root@esx-sapsol ~]# iptables -L --line-numbers
Chain INPUT (policy ACCEPT)
num  target     prot opt source               destination
1    ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED
2    ACCEPT     icmp --  anywhere             anywhere
3    ACCEPT     all  --  anywhere             anywhere
4    ACCEPT     tcp  --  anywhere             anywhere            state NEW tcp dpt:ssh
5    REJECT     all  --  anywhere             anywhere            reject-with icmp-host-prohibited
Chain FORWARD (policy ACCEPT)
num  target     prot opt source               destination
1    REJECT     all  --  anywhere             anywhere            reject-with icmp-host-prohibited
Chain OUTPUT (policy ACCEPT)
num  target     prot opt source               destination

Then, insert a new rule for incoming connections for the SAPINST SL Controller before rule number 5:

[root@esx-sapsol ~]# iptables -I INPUT 5 -p tcp --dport 21212 -j ACCEPT

Verify the changes:

[root@esx-sapsol ~]# iptables -L --line-numbers
Chain INPUT (policy ACCEPT)
num  target     prot opt source               destination
1    ACCEPT     all  --  anywhere             anywhere            state RELATED,ESTABLISHED
2    ACCEPT     icmp --  anywhere             anywhere
3    ACCEPT     all  --  anywhere             anywhere
4    ACCEPT     tcp  --  anywhere             anywhere            state NEW tcp dpt:ssh
5    ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:21212
6    REJECT     all  --  anywhere             anywhere            reject-with icmp-host-prohibited
Chain FORWARD (policy ACCEPT)
num  target     prot opt source               destination
1    REJECT     all  --  anywhere             anywhere            reject-with icmp-host-prohibited
Chain OUTPUT (policy ACCEPT)
num  target     prot opt source               destination

Hopefully, the connection already works now.

Save the firewall configuration for future system reboots:

[root@esx-sapsol ~]# service iptables save
iptables: Saving firewall rules to /etc/sysconfig/iptables:[  OK  ]

Of course, you can also stop the firewall completely, depending on your company's policies:

[root@esx-sapsol ~]# service iptables stop

and restart after you are finished:

[root@esx-sapsol ~]# service iptables start

You must add all the ports configured during the installation (instance ports etc.) in the same manner.

One more thing regarding Java.

The version 1.4 is only available via yum if you have configured RHEL over the RHEL Customer Portal

to use the SAP update channel (aka yum repository). See also https://service.sap.com/sap/support/notes/1495160

However, the extra installation is not required any more.

From Installation Guide SAP Solution Manager 7.1 SR1 on Linux : MaxDB

"You no longer have to download and install a Java Development Kit (JDK) from another software vendor as a prerequisite for the installation with SAPinst.The SAP JVM 4 is a Java Development Kit (JDK) provided and supported by SAP. The SAP JVM is fully compliant to the Java Platform Standard Edition (JDK) 1.4. It is available on the Installation Master DVD and is installed automatically by SAPinst when you start the installation.The diagnostics agent is installed automatically with SAP JVM 6."

I hope, this helps you

Best regards

Michael

former_member229542
Active Participant
0 Kudos

Thanks Michael

RHEL 6.3 Firewall configuration was blocking the ports

Answers (1)

Answers (1)

former_member264034
Active Contributor
0 Kudos

Hi,

The error "java.net.NoRouteToHostException: No
route to host: connect" indicates that the missing or unproper setting
in network or adaptor configuration.

Regards,

Aidan

Former Member
0 Kudos

Looks like issue with your network settings. Try with Fully qualified domain name. Just for testing purpose instaed of hostname, specify the IP and check it is working or not.

Also check your (PC's ) environmnet variable settings for JAVA_HOME and PATH variables. Include $JAVA_HOME/bin in your PATH environmnet variable.

Good luck.

Dipam