I’m trying to set up Nginx on my server. In the initial set up I have to do ip -4 addr show scope global
So I do that and I get:
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000 inet 18.104.22.168/20 brd 22.214.171.124 scope global eth0 valid_lft forever preferred_lft forever inet 10.17.0.5/16 brd 10.17.255.255 scope global eth0 valid_lft forever preferred_lft forever 3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000 inet 10.108.0.2/20 brd 10.108.15.255 scope global eth1 valid_lft forever preferred_lft forever
for eth0: which IP address do I need to use?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Click below to sign up and get $200 of credit to try our products over 60 days!
You can see the IP address in the eth0 line. As has already been mentioned it’s 126.96.36.199, the /20 part is what range this IP is from. Usually, you should be able to see the Droplet’s IP with
command as well.
Based on the output that you’ve shared, the following should be the public IPv4 address of your Droplet:
Hope that this helps!