To find the IP address of the servent. However, when the servent.props file is configured with a specific IP
address/hostname the call still returns localhost :-(
Edit the servent.props file and make sure the following appears:
watcher.period=30000
watcher.url= http://gaudi.techideas.es:2727
whatcher.start=start
This enables the IP watcher. The url provided is that of a node that is currently up and running. You can use any as long as it will see you with your correct IP.
That is, don't use the url of a node that is in the same private LAN as your node if what you want is to be able to guess your public IP.
HTH
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The issue is not to read the IP address as seen from external entities but to have the servent supply the IP/hostname specified in the servent.props file to the caller of the above method.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Logged In: YES
user_id=228477
Originator: NO
Edit the servent.props file and make sure the following appears:
watcher.period=30000
watcher.url= http://gaudi.techideas.es:2727
whatcher.start=start
This enables the IP watcher. The url provided is that of a node that is currently up and running. You can use any as long as it will see you with your correct IP.
That is, don't use the url of a node that is in the same private LAN as your node if what you want is to be able to guess your public IP.
HTH
Logged In: YES
user_id=1312564
Originator: YES
The issue is not to read the IP address as seen from external entities but to have the servent supply the IP/hostname specified in the servent.props file to the caller of the above method.