Problem:
- Product Name: BES-AppServer
- Product Version: 5.2.1
- Platform/OS Version: All
When BES starts up, it opens a number of random TCP and UDP ports. These ports are opened by ias, partition processes, and management or user osagent. For example, the following is a sample output of lsof utility on a Solaris platform.
# ./lsof_4.67 | egrep "(21232|21235|21234|21233).(.*UDP|.*TCP.*LISTEN)"
ias 21232 test 7u IPv6 0x3000f83d9b8 0t0 UDP *:15112 (Idle)
ias 21232 test 9u IPv6 0x3000f79a630 0t0 TCP *:15114->*:* (LISTEN)
ias 21232 test 19u IPv6 0x3000efe1e28 0t0 TCP *:33809->*:* (LISTEN)
osagent 21233 test 4u IPv4 0x3000f79a930 0t0 UDP *:33130 (Idle)
osagent 21233 test 5u IPv4 0x3000efe07a8 0t0 TCP *:33806 (LISTEN)
osagent 21233 test 6u IPv4 0x3000f79b830 0t0 UDP *:42424 (Idle)
osagent 21234 test 4u IPv4 0x3000efe1b28 0t0 UDP *:33132 (Idle)
osagent 21234 test 5u IPv4 0x3000efe0028 0t0 UDP *:14000 (Idle)
osagent 21234 test 6u IPv4 0x300021c4070 0t0 TCP *:33810 (LISTEN)
partition 21235 test 5u IPv6 0x30001f06068 0t0 UDP *:15110 (Idle)
partition 21235 test 7u IPv6 0x3000f79a4b0 0t0 TCP *:15005->*:* (LISTEN)
partition 21235 test 8u IPv6 0x3000efe04a8 0t0 UDP *:15111 (Idle)
partition 21235 test 13u IPv6 0x3000f79ac30 0t0 TCP *:33813->*:* (LISTEN)
partition 21235 test 15u IPv6 0x3000f83db38 0t0 TCP *:15002->*:* (LISTEN)
partition 21235 test 26u IPv6 0x3000f83dcb8 0t0 TCP *:8080->*:* (LISTEN)
partition 21235 test 27u IPv6 0x30001f07568 0t0 TCP *:15003->*:* (LISTEN)
partition 21235 test 35u IPv6 0x3000f83c038 0t0 TCP *:5001 (LISTEN)
Note: 21232,21233,21234 and 21235 represents pid of ias, management osagent, user osagent and partition processes)
This article shows how fixed ports can be assigned to BES.
Resolution:
The following detailed instructions will help us fix all of above random ports being open by processes of BES.
Note : replace xxxxx with a unique port number in following steps.
Configuring TCP and UDP ports used by ias and partition processes
- Add the following properties in management_vbroker.properties under folder BES-root\\var\\servers\\server-name\\adm\\properties
vbroker.agent.clientPort=xxxxx
vbroker.se.iiop_tp.scms=iiop_tp
vbroker.se.iiop_tp.scm.iiop_tp.listener.port=xxxxx - Edit BES-root\\var\\servers\\server-name\\adm\\properties\\partitions\\partition-name\\vbroker.properties
- Add the property
- vbroker.agent.clientPort=xxxxx
- Locate the following property and change its default value from 0 to xxxxx.
- vbroker.se.iiop_tp.scm.iiop_tp.listener.port=xxxxx
- If you have SSL enabled on the respective partition then locate the following property and change its default value from 0 to xxxxx.
- vbroker.se.iiop_tp.scm.ssl.listener.port=xxxxx
- Add the property
- Configure the port for Iiopconnector.
- Edit server.xml under BES-root\\var\\servers\\server-name\\adm\\properties\\partitions\\partition-name\\tomcat\\conf
- Locate the following entry
- Connector className="org.apache.catalina.connector.iiop.IiopConnector"....
- Add the port
- Connector className="org.apache.catalina.connector.iiop.IiopConnector"
name="tc_inst1" debug="0" port="xxxxx"
- Connector className="org.apache.catalina.connector.iiop.IiopConnector"
- Add the following properties in management_vbroker.properties under BES-root\\var\\servers\\server-name\\adm\\properties\\partitions\\partition-name
vbroker.agent.clientPort=xxxxx
vbroker.se.iiop_tp.scms=iiop_tp
vbroker.se.iiop_tp.scm.iiop_tp.listener.port=xxxxx
Configuring random UDP/TCP ports used by osagent and management osagent
- Edit BES-root\\var\\servers\\server-name\\adm\\properties\\services\\management_osagent\\nativeservice.properties
change:
nativeservice.environment=
to
nativeservice.environment=OSAGENT_CLIENT_HANDLER_PORT=xxxxx - Edit BES-root\\var\\servers\\server-name\\adm\\properties\\services\\osagent\\nativeservice.properties
change:
nativeservice.environment=
to
nativeservice.environment=OSAGENT_CLIENT_HANDLER_PORT=xxxxx
#Security
#ApplicationServer
#partition
#osagent
#AppServer
#BorlandApplicationServer
#VisiBroker
#ias