cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

This product reached the end of support date on March 31, 2021.

Did anybody experience this issue with NGINX?

mark_medley
Organizer

I'm getting nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use) when doing the LD_PRELOAD=/tmp/dynatrace-6.3/agent/lib64/libdtagent.so nginx process,

I don't know what it means. We using version 6.3.

13 REPLIES 13

sean_mcconville
Organizer

Sounds like another process is already running on port 80 and nginx cant start because of it.

what do you see when running:

netstat -pln | grep :80

mark_medley
Organizer

tcp 0 0 127.0.0.1:8080 0.0.0.0:* LISTEN 6159/starman worker
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 25792/nginx
tcp 0 0 127.0.0.1:8081 0.0.0.0:* LISTEN 44631/json-proxy
tcp 0 0 127.0.0.1:8082 0.0.0.0:* LISTEN 26311/starman maste
tcp 0 0 127.0.0.1:8083 0.0.0.0:* LISTEN 26163/st-pushd
tcp 0 0 127.0.0.1:8084 0.0.0.0:* LISTEN 26283/st-userd
tcp 0 0 127.0.0.1:8085 0.0.0.0:* LISTEN 26171/node
tcp 0 0 127.0.0.1:8087 0.0.0.0:* LISTEN 1770/mono
tcp 0 0 127.0.0.1:8091 0.0.0.0:* LISTEN 26276/node
tcp 0 0 127.0.0.1:8093 0.0.0.0:* LISTEN 34053/node
tcp 0 0 0.0.0.0:8096 0.0.0.0:* LISTEN 64054/node
udp 0 0 127.0.0.1:8001 0.0.0.0:* 15422/dtwsagent

david_n
Inactive

Hello Mark,

Are you still receiving that NGINX error? Could you try running the LD_PRELOAD process once more? If you get the same error then you could try the following:

Kill the process on port 80: sudo fuser -k 80/tcp

Start the NGINX process: service nginx start

If that doesn't work then you could try running the process on a diffferent port.

Thanks,

David Nicholls

mark_medley
Organizer

Try running DT or are you talking NGINX? Because I think it would harder to switch the Port on the process(meaning NGINX)

Could you try running DT for me?

Thanks,

David

mark_medley
Organizer

Sorry for delay, now are you talking about the LD_Preload piece? because the Web Agent runs on port 8001. Is there way to change the LD_PRELOAD to different Port? or is there a file that I should be look at to do a manual LD_PRELOAD

Hello Mark,

In the list of processes that you shared, there is a starman worker process that is currently running on port 80. That process is preventing your NGINX from starting correctly. Changing the DT process will not resolve the root cause of the issue since it runs on port 8001. You would have to kill that starman process or find a way to change the NGINX port. You could try stopping the starman process and starting the web agent.

Thanks,

David Nicholls

mark_medley
Organizer

Actually NGINX is running on Port 80 , not Starman, that's running on 8080. Since i don't think changing NGINX to a different port will happen, what is my alternative?

mark_medley
Organizer

Harald Z. Did you want to review and give me suggestion?

mark_medley
Organizer

This a Triai DT license, so I need to get the Web Server for NGINX running to produce data. I wanted to show Mgmt what data DT could produce. Our NGINX runs on PORT 80 and isn't going to switched according Ops. So we need to come up with another Alternative to do the LD_PRELOAD step, rather quickly.

harald_zeitlhof
Inactive

Mark, yes, Nginx is already running when you try to start it.
before you start Nginx in combination with the LD_PRELOAD option, you have to make sure that no other instances of Nginx are already running. And also no other processes are listening on ports used by the Nginx config! Try to kill all running Nginx processes or use
/etc/init.d/nginx stop
then start Nginx with the LD_PRELOAD option.
let me know if it worked!
best,
Harald

chintan_suhagiy
Participant

We are trying to configure an agent in Nginx Web Server.

Going through the documentation,we did all the necessary steps it is still not getting configured,we even have gone through the forum for the answer but it didn't worked.

We tried putting the LD_PRELOAD in conf file and also in the nginx.service file but it is not working.

We dont know the exact location where to put this LD_PRELOAD.

Kindly need help on this issue.

eric_dechelle
Newcomer

Followed the instructions here and it worked

https://answers.dynatrace.com/spaces/148/uem-open-q-a_2/questions/182552/tip-so-you-want-to-monitor-nginx-on-linux-but-how.html

Mine is stored on /lib/systemd/system/nginx.service