[SOLVED] confusion about linux guest internet connection

doomiiniikk

New Member
May 26, 2024
3
0
1
I have, not much, prior experience with networking and linux and no prior experience with proxmox.
During set up of my ubuntu guest I was able to update fine no issues, indicating that I had access to the internet.
After that I have not been able to access the internet, I do have a LAN ip and I can ssh into the guest, I can ping it, no problem.
I have tried searching the forum but came to no concrete fix.
What am I missing and how do I fix this?

Code:
# from the guest
$ ping 8.8.8.8
ping: connect: Network is unreachable

I can ping my gateway as well

In the guest, I have changed some things to get a static IP but I doubt this is the reason as I had the same issue on another system which I installed proxmox on first.
I disabled the cloud-init thingy by adding config:disable to a network cfg, it is now disabled.

Code:
$ cat /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg.disabled
network: {config:disabled}

I added this because I still got a DHCP address
Code:
$ cat /etc/netplan/99_config.yaml
network:
    version:
        2
    ethernets:
        ens18:
            addresses:
                - 10.1.1.60/24
            routes:
                - to: 10.1.1.1
                  via: 10.1.1.1
            nameservers:
                search: [hoponto]
                addresses: [10.1.1.60]

I deleted the config file that enabled dhcp in netplan, filename started with `50-`
Code:
$ ls /etc/netplan/
99_config.yaml

I don't know if vmbr0 should be visible from the guest, but at least the network device is visible.

Code:
$ lspci
00:00.0 Host bridge: Intel Corporation 440FX - 82441FX PMC [Natoma] (rev 02)
00:01.0 ISA bridge: Intel Corporation 82371SB PIIX3 ISA [Natoma/Triton II]
00:01.1 IDE interface: Intel Corporation 82371SB PIIX3 IDE [Natoma/Triton II]
00:01.2 USB controller: Intel Corporation 82371SB PIIX3 USB [Natoma/Triton II] (rev 01)
00:01.3 Bridge: Intel Corporation 82371AB/EB/MB PIIX4 ACPI (rev 03)
00:02.0 VGA compatible controller: Device 1234:1111 (rev 02)
00:03.0 Unclassified device [00ff]: Red Hat, Inc. Virtio memory balloon
00:05.0 PCI bridge: Red Hat, Inc. QEMU PCI-PCI bridge
00:12.0 Ethernet controller: Red Hat, Inc. Virtio network device
00:1e.0 PCI bridge: Red Hat, Inc. QEMU PCI-PCI bridge
00:1f.0 PCI bridge: Red Hat, Inc. QEMU PCI-PCI bridge
01:01.0 SCSI storage controller: Red Hat, Inc. Virtio SCSI

Code:
$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host noprefixroute
       valid_lft forever preferred_lft forever
2: ens18: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether bc:24:11:07:e5:bc brd ff:ff:ff:ff:ff:ff
    altname enp0s18
    inet 10.1.1.60/24 brd 10.1.1.255 scope global ens18
       valid_lft forever preferred_lft forever
    inet6 fe80::be24:11ff:fe07:e5bc/64 scope link
       valid_lft forever preferred_lft forever

interfaces does not exist in the guest..
Code:
$ ls /etc/network/interfaces
ls: cannot access '/etc/network/interfaces': No such file or directory
 
would that be the routes: - to: 10.1.1.1?
I did end up just creating a new VM and setting up the network connection properly in the install which ended me with this config
Code:
network:
    ethernets:
        ens18:
            addresses:
            - 10.1.1.60/24
            nameservers:
                addresses:
                - 8.8.8.8
                - 1.1.1.1
                search: []
            routes:
            -   to: default
                via: 10.1.1.1
    version: 2
which I now can access the internet with
Code:
$ ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data.
64 bytes from 8.8.8.8: icmp_seq=1 ttl=57 time=37.6 ms
64 bytes from 8.8.8.8: icmp_seq=2 ttl=57 time=35.8 ms
...
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!