Wednesday, February 5, 2014

getaddrinfo(localhost, NULL, 1) failed (Name or service not known): No such file or directory -- When attempting to startup the R12 middle tier services

Recently i came across through below scenario after the R12 installation. During the startup of middle tier services opmn was failed to start with the below error.

When attempting to startup the R12 middle tier services,
the following error occurs.

ERROR

getaddrinfo(localhost, NULL, 1) failed (Name or service not known): No such file or directory
getaddrinfo(localhost, NULL, 1) failed (Name or service not known): No such file or directory
getaddrinfo(localhost, NULL, 1) failed (Name or service not known): No such file or directory
opmnctl: opmn start failed.


The issue can be reproduced at will with the following steps:
1. Apply R12 prerequisites
2. Install R12 using Rapid wizard
3. Startup middle tier services.



CAUSE.

The hosts file does not contain the localhost entry needed for loopback
127.0.0.1 localhost.localdomain


SOLUTION.

Validate System Configuration Errors Out (Post Installation) (Doc ID 454878.1)

To implement the solution, please execute the following steps:

1. Modify hosts file and add localhost entry to look like below (example for Linux):


127.0.0.1 localhost.localdomain localhost

Note: For other platforms please check how the hosts entries should look like in the platform specific "Oracle Applications Installation and Upgrade Notes Release 12" note.
Note: Restart apps server (optional)

2. Start middle tier services.



It worked for me... !