0

On my Ubuntu Hyper-V VM, the Network Adapter shows as having the link DOWN. I've tried doing a fresh install of Ubuntu 22.04 and also tried updating to 22.04.1. Adding a Legacy Network Adapter to the VM works OK but is severely speed limited, so I need to solve this.

Here is the output of ip address:

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
       valid_lft forever preferred_lft forever
2: enp0s10f0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN group default qlen 1000
    link/ether 00:15:5d:01:b0:10 brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.16/24 metric 100 brd 192.168.1.255 scope global dynamic enp0s10f0
       valid_lft 100469sec preferred_lft 100469sec
    inet6 fd5c:de09:9d49::c57/128 scope global dynamic noprefixroute
       valid_lft 100471sec preferred_lft 42871sec
    inet6 fd5c:de09:9d49:0:215:5dff:fe01:b010/64 scope global dynamic mngtmpaddr noprefixroute
       valid_lft 4294966966sec preferred_lft 4294966966sec
    inet6 fe80::215:5dff:fe01:b010/64 scope link
       valid_lft forever preferred_lft forever
3: eth0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 00:15:5d:01:b0:0f brd ff:ff:ff:ff:ff:ff

adapter 2, enp0s10f0, is the Legacy Network Adapter. Adapter 3 eth0 is the (normal) Network Adapter.

The adapter in the VM config is attached to my virtual switch, which I've verified is an external network (working fine with other VMs). I've even created a new vSwitch bound to a separate physical adapter to no avail.

My main network adapter is a Mellanox CX354a in ethernet mode. The other adapter I tried is a run of the mill Broadcom based gigabit port.

Thanks

8
  • Are you using (in Hyper-V) an internal (NAT) switch (default) or an external (Bridged) switch? Is the Ubuntu guest using the correct switch in Hyper-V? Make sure Hyper-V recognizes the different External Switch. I had issues with this, had to delete external switches and start over in Hyper-V.
    – John
    Dec 31, 2022 at 0:06
  • Yes it's set to external and a physical adapter has been selected.
    – Tangles
    Dec 31, 2022 at 0:20
  • I am not sure. I am looking at my Ubuntu VM in Hyper-V here. Try (consider) removing the external switch in Hyper-V. Restart the host OS after this. Make a new external switch for the adapter you want. Make sure Hyper-V accepts and recognizes your external switch name. Then start Ubuntu, remove the adapter there and set it up again. Read through and make sure of the steps before starting.
    – John
    Dec 31, 2022 at 0:29
  • FWIW. I put VMware Workstation on my Hyper-V machine. VMware new and Hyper-V coexist. The machine has been running. I closed VMware, opened Hyper-V and started Ubuntu. All well. I shut down Ubuntu and started Kali. No network. After a bit of fiddling, I shut everything down. restarted and Kali is fine. Make sure the external switch is working. Test with another VM even if you must spin one up.
    – John
    Dec 31, 2022 at 1:09
  • Are you using Server 2022?
    – Tangles
    Dec 31, 2022 at 1:43

1 Answer 1

1

My issue was that I had added the Network Adapter to Hyper-V after setting up the Ubuntu VM, so it was misconfigured. in /etc/netplan/00-installer-config.yaml I was missing the necessary lines to configure eth0.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .