How to remove an unused network bridge?

dsclaimer: complete LXD novice here.

LXD 2.12 on an ubuntu 16.04 host (which lives in a VirtualBox VM on a laptop)

probably due to running lxd init more the once while playing around I have 2 network bridges (virbr0 & lxdbr0 [shown as networks by lxc network list])

I am trying to get rid of virbr0 (which is unused) and try lxc network delete virbr0 which returns an

error: not found

I got the suspicion network delete may not be the right command to begin with?

If you run lxc network list, you get

$ lxc network list
|  NAME   |   TYPE   | MANAGED | USED BY |
| enp0s12 | physical | NO      | 0       |
| lxdbr0  | bridge   | YES     | 4       |
| virbr0  | bridge   | NO      | 0       |

which shows that virbr0 is not managed by LXD. Therefore, LXD cannot remove it.
Actually, virbr0 is related to KVM so you do not need to do something here.

(Some hints: you could delete virbr0 through NetworkManager. See the nmcli device command. Still, do not remove this unless you are aware how it is used along Virtualbox).

As @simos said, “virbr0” usually comes with libvirtd. If you don’t need libvirt, uninstalling it should cause the bridge to go away.

If you do need libvirt but not its bridge, you can run this:

sudo virsh net-stop default
sudo virsh net-undefine default

Which should get you completely rid of that bridge.

ok, thanks everybody. clearing the fog quite a bit for a novice like me.

I wasn’t aware that there is KVM running on my host to begin with.

So for now I may just ignore it and test the sudo virsh net-stop default && sudo virsh net-undefine default routine suggested by Stephane sometime

i’m facing same kind of issue, there is network named lxcbr0,which is not managed by LXD, i tried deleting it using command
“lxc network delete lxcbr0”
but it gives;
error: not found.

can you help how can i remove it from list?
thanking in advance.

That lxcbr0 is not managed by LXD, therefore LXD cannot delete it.

lxdbr0 is LXD, lxcbr0 is from LXC 1.0. Use lxc-net to deal with the lxcbr0 network interface.