Operating System - HP-UX
1834137 Members
2278 Online
110064 Solutions
New Discussion

Re: Update of /etc/services

 
SOLVED
Go to solution
Yogeeraj
Advisor

Update of /etc/services

Dear HP Experts,

Please advise.
We have setup a suite of Oracle Products recently.
We had been advise to enter the details of all port numbers used in the operating system file: /etc/services.

Could you please advise on how to enter the details.
For example,
Oracle Management server accepting requests on port numbers 7771, 7772, 7773
Oracle Enterprise Java Engine TNS Listener accepting TCP/IP requests on port 1521 and IIOP: 2481
Oracle HTTP Server (apache, which is also listening on port80) - 7777


thank you for a reply

Kind regards
Yogeeraj
5 REPLIES 5
Santosh Nair_1
Honored Contributor

Re: Update of /etc/services

The /etc/services file is a mapping of port numbers to service name and as such, if the application does not use the port name, i.e. do a getserv*() system calls, then there is no need to update the /etc/services file.

That said, typical services entries are of the form:

SERVNAME PORT/PROTO

where SERVNAME is the service name, could be anything you want. For example the service name for 80 is http, and for 23 is telnet.
PORT is the port number and PROTO is the protocol being used, i.e. tcp or udp.

Btw, port 80 should already be defined in the services file.

Hope this helps.

-Santosh
Life is what's happening while you're busy making other plans
Stefan Farrelly
Honored Contributor
Solution

Re: Update of /etc/services

I would simply add them in as thus;

OMS 7771/tcp # Oracle Management Server
OMS 7772/tcp # Oracle Management Server
OMS 7773/tcp # Oracle Management Server
OEJE 1521/tcp # Oracle Enterprise Java Engine
IIOP 2481/tcp # Oracle Enterprise Java Engine
Oracle_http 7777/tcp # Oracle HTTP Server
Apache 80/tcp # Apache http server

Im from Palmerston North, New Zealand, but somehow ended up in London...
Stefan Farrelly
Honored Contributor

Re: Update of /etc/services


Oops, you shouldnt have duplicates, change the first 3 lines to;
OMS1 ...
OMS2....
OMS3....
Im from Palmerston North, New Zealand, but somehow ended up in London...
Yogeeraj
Advisor

Re: Update of /etc/services

thank you very much for the quick responses.
Best Regards
Yogeeraj
Hamdy Al-Sebaey
Regular Advisor

Re: Update of /etc/services

Hi cmt,
I agree with Stefan, U can add a new port through using vi /etc/services.
Regards,
Hamdy
Thanks for sharing knowledge