static network connection between two debians

1

I am having a big trouble in setting a simple static connection between two computers (two Debians, say A and B). I know, in principle, how to do it, and have done properly for computers B and C (all Debians). However, configuring A is the main goal. Whenever I connect A to my home router from my internet provider, the Network Manager finds connection perfectly fine, thus I know that Ethernet card is fine. I believe that this means that drivers are ok too. Below are the outputs of some commands. What I find odd (among other things) is that the "Supported ports" in ethtool doesn't show anything when plugging A to B (although it shows TP when connected directed to internet router). I didn't find such a case when looking on the web.

Does anyone have some suggestion or hint? I am fighting against this for months, and have already tried several hints from tutorials, forums, debian pages... I am considering installing cent OS and see if it is easier.

Thanks for any idea in advance.

$ update-rc.d -f dhcpd remove  # I have disabled dhcp, not sure if it is needed
$ systemctl disable NetworkManager.service  # also disabled the network manager


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

source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback


#auto enp2s0
allow-hotplug enp2s0
iface enp2s0 inet static
  address 192.168.10.101
  netmask 255.255.255.0
  gateway 192.169.10.100


$ cat /etc/resolv.conf
nameserver 192.169.10.100


$ ip a show eno1:

2: eno1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN group default qlen 1000
    link/ether 3c:ec:ef:10:32:42 brd ff:ff:ff:ff:ff:ff
    inet 192.168.10.101/24 brd 192.168.10.255 scope global eno1
       valid_lft forever preferred_lft forever

$ ip route show
default via 192.168.10.100 dev eno1 onlink linkdown 
192.168.10.0/24 dev eno1 proto kernel scope link src 192.168.10.101 linkdown 


$ ethtool eno1

Settings for eno1:
    Supported ports: [ ]
    Supported link modes:   1000baseT/Full 
    Supported pause frame use: Symmetric
    Supports auto-negotiation: Yes
    Supported FEC modes: Not reported
    Advertised link modes:  1000baseT/Full 
    Advertised pause frame use: No
    Advertised auto-negotiation: Yes
    Advertised FEC modes: Not reported
    Speed: Unknown!
    Duplex: Unknown! (255)
    Port: Other
    PHYAD: 0
    Transceiver: internal
    Auto-negotiation: off
    Supports Wake-on: g
    Wake-on: g
    Current message level: 0x0000000f (15)
                   drv probe link timer
    Link detected: no


$ iptables -L
Chain INPUT (policy ACCEPT)
target     prot opt source               destination         

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination         

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination         

And on my computer B:

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

source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback


#auto enp2s0
allow-hotplug enp2s0
iface enp2s0 inet static
  address 192.168.10.100
  netmask 255.255.255.0

$ cat /proc/sys/net/ipv4/ip_forward  # I have enabled ip forwarding
1

Finally, at A, if plugged directly to the Internet router:

Settings for eno1:
    Supported ports: [ TP ]
    Supported link modes:   1000baseT/Full 
    Supported pause frame use: Symmetric
    Supports auto-negotiation: Yes
    Supported FEC modes: Not reported
    Advertised link modes:  1000baseT/Full 
    Advertised pause frame use: No
    Advertised auto-negotiation: Yes
    Advertised FEC modes: Not reported
    Speed: 1000Mb/s
    Duplex: Full
    Port: Twisted Pair
    PHYAD: 0
    Transceiver: internal
    Auto-negotiation: on
    MDI-X: Unknown
    Supports Wake-on: g
    Wake-on: g
    Current message level: 0x0000000f (15)
                   drv probe link timer
    Link detected: yes

debian
static-ip
static-routes
asked on Super User Mar 9, 2021 by Yuri

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0