Register Login

NIEHOST_UNKNOWN: Cannot connect to Message Server

Updated May 18, 2018

Hello SAP Experts,

The Java server cannot be started as it cannot get connected to the message server.

The log contains following entries:

  • ERROR => cannot connect to Message Server.
  • LOG => connecting to Message Server.
  • ERROR => MsIAttachEx: NiBufConnect to sapxxxxx01/3901 failed (rc=NIEHOST_UNKNOWN)
  • LOG => Run level 0 completed.
  • LOG => Instance state is "Instance terminated"

Please help me resolve the error.


  • 06 Feb 2017 3:30 pm Abhijeet Mudgal Helpful Answer

    In order to resolve the error please do the following:

    • Check the value of parameter j2ee/scs/host in the Default profile. 
    • Now you can find the default profile path  usr/sap/<sid>/sys/profile/DEFAULT.PFL 
    • Please change the parameter to the correct value.
    • Now at last restart the whole cluster including the central services instance.
  • 06 Feb 2017 3:31 pm Romil Tripathi

    The error mentioned above must be caused due to JAVA trying to connect to the wrong host for the message server.