Puncte:0

Debian 11 server not able to delete default gateway

drapel cn

I am not able to delete the default gateway from my debian 11 server:-

peter@discovery:~$ sudo route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         192.168.1.13    0.0.0.0         UG    0      0        0 enp6s0f0
0.0.0.0         0.0.0.0         0.0.0.0         U     1002   0        0 enp8s0
91.187.223.128  0.0.0.0         255.255.255.128 U     0      0        0 enp6s0f1
169.254.0.0     0.0.0.0         255.255.0.0     U     0      0        0 enp6s0f1
169.254.0.0     0.0.0.0         255.255.0.0     U     0      0        0 enp8s0
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 enp6s0f0
192.168.1.13    0.0.0.0         255.255.255.255 UH    0      0        0 enp6s0f0
peter@discovery:~$ sudo route del default gw 192.168.1.13
peter@discovery:~$ sudo route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         192.168.1.13    0.0.0.0         UG    0      0        0 enp6s0f0
0.0.0.0         0.0.0.0         0.0.0.0         U     1002   0        0 enp8s0
91.187.223.128  0.0.0.0         255.255.255.128 U     0      0        0 enp6s0f1
169.254.0.0     0.0.0.0         255.255.0.0     U     0      0        0 enp6s0f1
169.254.0.0     0.0.0.0         255.255.0.0     U     0      0        0 enp8s0
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 enp6s0f0
192.168.1.13    0.0.0.0         255.255.255.255 UH    0      0        0 enp6s0f0

and then also:-

peter@discovery:~$ sudo ip route del default via 192.168.1.13
peter@discovery:~$ sudo route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         192.168.1.13    0.0.0.0         UG    0      0        0 enp6s0f0
0.0.0.0         0.0.0.0         0.0.0.0         U     1002   0        0 enp8s0
91.187.223.128  0.0.0.0         255.255.255.128 U     0      0        0 enp6s0f1
169.254.0.0     0.0.0.0         255.255.0.0     U     0      0        0 enp6s0f1
169.254.0.0     0.0.0.0         255.255.0.0     U     0      0        0 enp8s0
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 enp6s0f0
192.168.1.13    0.0.0.0         255.255.255.255 UH    0      0        0 enp6s0f0
peter@discovery:~$

The default gateway 192.168.1.13 is being very stubborn and doesn't want to go. How do I get rid of it please. I have a Debian 11 Bullseye server.

Many thanks

Just to add this is the /etc/network/interfaces file:-

# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

auto enp6s0f0
iface enp6s0f0 inet static
  address 192.168.1.130
  netmask 255.255.255.0
  gateway 192.0.2.254

auto enp6s0f0:0
iface enp6s0f0:0 inet static
  address 192.168.1.131
  netmask 255.255.255.0

auto enp6s0f0:1
iface enp6s0f0:1 inet static
  address 192.168.1.132
  netmask 255.255.255.0

auto enp6s0f0:2
iface enp6s0f0:2 inet static
  address 192.168.1.133
  netmask 255.255.255.0

auto enp6s0f0:3
iface enp6s0f0:3 inet static
  address 192.168.1.134
  netmask 255.255.255.0

auto enp6s0f0:4
iface enp6s0f0:4 inet static
  address 192.168.1.135
  netmask 255.255.255.0

auto enp6s0f0:5
iface enp6s0f0:5 inet static
  address 192.168.1.136
  netmask 255.255.255.0

auto enp6s0f0:6
iface enp6s0f0:6 inet static
  address 192.168.1.136
  netmask 255.255.255.0

auto enp6s0f0:7
iface enp6s0f0:7 inet static
  address 192.168.1.137
  netmask 255.255.255.0

auto enp6s0f0:8
iface enp6s0f0:8 inet static
  address 192.168.1.138
  netmask 255.255.255.0

auto enp6s0f0:9
iface enp6s0f0:9 inet static
  address 192.168.1.139
  netmask 255.255.255.0

auto enp6s0f1
iface enp6s0f1 inet static
  address 91.187.223.129
  netmask 255.255.255.128

auto enp6s0f1:0
iface enp6s0f1:0 inet static
  address 91.187.223.134/25
  netmask 255.255.255.128

auto enp6s0f1:1
iface enp6s0f1:1 inet static
  address 91.187.223.210
  netmask 255.255.255.128

auto enp6s0f1:2
iface enp6s0f1:2 inet static
  address 91.187.223.211
  netmask 255.255.255.128

auto enp6s0f1:3
iface enp6s0f1:3 inet static
  address 91.187.223.212
  netmask 255.255.255.128

auto enp6s0f1:4
iface enp6s0f1:4 inet static
  address 91.187.223.213
  netmask 255.255.255.128

auto enp6s0f1:5
iface enp6s0f1:5 inet static
  address 91.187.223.214
  netmask 255.255.255.128

auto enp6s0f1:6
iface enp6s0f1:6 inet static
  address 91.187.223.215
  netmask 255.255.255.128

auto enp6s0f1:7
iface enp6s0f1:7 inet static
  address 91.187.223.216
  netmask 255.255.255.128

auto enp6s0f1:8
iface enp6s0f1:8 inet static
  address 91.187.223.217
  netmask 255.255.255.128

auto enp6s0f1:9
iface enp6s0f1:9 inet static
  address 91.187.223.218
  netmask 255.255.255.128

auto enp6s0f1:10
iface enp6s0f1:10 inet static
  address 91.187.223.219
  netmask 255.255.255.128
drapel in
Probabil că ai un diacon care îl adaugă înapoi, folosești DHCP?
Nikita Kipriyanov avatar
drapel za
Ce este acest sistem? Cum este configurată rețeaua? De ce are o rută redundantă dedicată către `192.168.1.13/32`, care este deja acoperită cu ruta către `192.168.1.0/24` (ceea ce este foarte neobișnuit)? De asemenea, utilizați `ip route` pentru configurarea rutelor, de ce nu îl folosiți întotdeauna? Vă rugăm să utilizați ieșirea `ip route` în loc de `route -n`.
drapel cn
Am configurat doar adrese IP statice
drapel cn
Se pare că Network Manager este mult mai ușor de configurat rețeaua. Voi încerca asta în curând.

Postează un răspuns

Majoritatea oamenilor nu înțeleg că a pune multe întrebări deblochează învățarea și îmbunătățește legătura interpersonală. În studiile lui Alison, de exemplu, deși oamenii își puteau aminti cu exactitate câte întrebări au fost puse în conversațiile lor, ei nu au intuit legătura dintre întrebări și apreciere. În patru studii, în care participanții au fost implicați în conversații ei înșiși sau au citit transcrieri ale conversațiilor altora, oamenii au avut tendința să nu realizeze că întrebarea ar influența – sau ar fi influențat – nivelul de prietenie dintre conversatori.