You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by GitBox <gi...@apache.org> on 2020/03/17 03:56:51 UTC

[GitHub] [skywalking] gameover453 commented on issue #4520: Enhanced Agent Hostname detection function

gameover453 commented on issue #4520: Enhanced Agent Hostname detection function
URL: https://github.com/apache/skywalking/issues/4520#issuecomment-599865184
 
 
   Thanks for the quick reply.
   
   Yes, usually we don't specify a bound network device for the program (such as when it runs in a pod, such as when it is deployed in Aliyun ECI).
   At this time, the program usually obtains the IP address "127.0.0.1" and obtains the "localhost" host name through reverse analysis(in /etc/hosts first hostname).
   
   There is a related discussion in openjdk-jira, see:
   [JDK-8062840](https://bugs.openjdk.java.net/browse/JDK-8062840)
   
   We don't think modifying /etc/hosts is a good option (though it works, but it is tedious and unreliable), so we try to modify the implementation of getHostName() to solve the problem.
   
   In fact, this is not a design issue.
   But I think we might be able to help improve the problem of apm-agent not displaying the correct hostname.
   
   Checking again when the hostname is "localhost", or omitting "127.0.0.1" if not specified, should help solve the problem.
   
   expecting reply  : )

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services