Wirenboard6:InstallingOnTheRemoteSite/en: различия между версиями

Новая страница: «The default gateway with metric 0 in the routing table is created for the eth0 interface, which we will consider to be the primary interface for Internet access.…»
(Новая страница: «To ensure failover of connections we need to provide for any procedure for raising and fall of the interfaces. The task is to provide communication regardless of…»)
(Новая страница: «The default gateway with metric 0 in the routing table is created for the eth0 interface, which we will consider to be the primary interface for Internet access.…»)
Строка 163: Строка 163:
To ensure failover of connections we need to provide for any procedure for raising and fall of the interfaces. The task is to provide communication regardless of the order of raising the interfaces and switching when one of them crushes.  
To ensure failover of connections we need to provide for any procedure for raising and fall of the interfaces. The task is to provide communication regardless of the order of raising the interfaces and switching when one of them crushes.  


Для интерфейса eth0, который мы будем считать основным для выхода в интернет, создается шлюз по умолчанию с метрикой 0 в таблице маршрутизации. Зададим для шлюза по умолчанию через интерфейс ppp0 метрику 100 (или любой, отличной от 0).
The default gateway with metric 0 in the routing table is created for the eth0 interface, which we will consider to be the primary interface for Internet access. Set the default gateway via the ppp0 interface to 100 metric (or any metric other than 0).
Для выполнения команд после инициализации любого ppp-интерфейса pppd демон использует директорию <code>/etc/ppp/ip-up.d</code>. В качестве параметров командной строки скрипту передается и имя ppp-интерфейса (в нашем случае такой интерфейс один это ppp0).
The daemon uses the <code>/etc/ppp/ip-up directory to execute commands after any ppp interface is initialized.d</code>. The name of the ppp interface is also passed to the script as command-line parameters (in our case, there is only one such interface — ppp0).


Создадим скрипт add_routes в директории <code>/etc/ppp/ip-up.d</code> и сделаем его исполняемым (<code>chmod +x /etc/ppp/ip-up.d/add_routes</code>):
Создадим скрипт add_routes в директории <code>/etc/ppp/ip-up.d</code> и сделаем его исполняемым (<code>chmod +x /etc/ppp/ip-up.d/add_routes</code>):
12 063

правки