Report this

What is the reason for this report?

Why does ubuntu set the both private and public Gateway to 0.0.0.0?

Posted on March 15, 2014

Hi, Today I was trying to mess around the private network in ny2 datacenter, here’s default route set up for Ubuntu 12: Destination Gateway Genmask Flags Metric Ref Use Iface 0.0.0.0 107.170.96.1 0.0.0.0 UG 100 0 0 eth0 10.128.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth1 107.170.96.0 0.0.0.0 255.255.240.0 U 0 0 0 eth0

Does it mean both 10.128..(private) and 107.179.96.*(public) go though the save gateway(107.170.96.1)?

how about map public and private traffic into different gateway as follow setup:

Destination Gateway Genmask Flags Metric Ref Use Iface 0.0.0.0 162.243.216.1 0.0.0.0 UG 0 0 0 eth0 10.128.0.0 10.128.1.1 255.255.255.255 UGH 0 0 0 enp0s4v1 162.243.216.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0



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.

Basically, the routes mean that since the private interface lives in that subnet, anything with a destination of 10.128.0.0/16 should be reachable just by throwing it on the interface, without going through a gateway as it will break/cause heavy packet loss on the droplet. <br>Public traffic goes through the gateway “107.170.96.1”.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.