There is a server with two network cards. Two external IP cards (different subnets and masks) enter both cards.

How to make it possible to ping them from the outside at the same time?

I prescribe route route add -net 0.0.0.0 netmask 0.0.0.0 gw xxxx dev p1p1 , ping to the first network goes, to the second - no, and vice versa.

  • Are you sure you ping from an external resource? - borodatych
  • yes, pinging from here ping.eu/ping , also from a nearby computer - ArthurStark

1 answer 1

The first thing I would recommend is to remove the network-manager package: it facilitates network configuration in trivial situations and only makes it difficult for non-trivial ones.

The marshalling setup for various non-trivial cases is well described in a document known as lartc . There are also translations into Russian, for example, on opennet . in particular, about setting up routing for two providers is written in section 4.2 .

There is a good (seemingly) step-by-step instruction on how to set up balancing between two providers (in three different ways).

  • Network-manager was not installed, I have a Ubuntu server - ArthurStark
  • one
    A network-manager is, in fact, a daemon that receives information about changes in the state of network interfaces and produces their [re] configuration. you probably mean one of the many gui-wrappers to control this daemon. but it can be controlled from cli . / a ubuntu server differs from ubuntu-destop for the most part only in the number of packages unpacked during installation. - aleksandr barakin
  • network-manager, systemd, pulseaudio - a curved attempt by a certain L. P. to turn Linux into a branch of a vent. - gbg