When trying to create a host-only network on VirtualBox I get the same error listed in this post, and the listed solution is to use VirtualBox 5.0.14, but this is incompatible with Ubuntu 22.04. There doesn't seem to be any other solution or description of why it happens that I can find.
I get this error when attempting to create a host-only network using VirtualBox version 6.1.44 on Ubuntu release 22.04:
VBoxNetAdpCtl: Error while adding new interface: VBoxNetAdpCtl: ioctl failed for /dev/vboxnetctl: Inappropriate ioctl for devic.
Result Code: NS_ERROR_FAILURE (0x80004005)
Component: HostNetworkInterfaceWrap
Interface: IHostNetworkInterface {455f8c45-44a0-a470-ba20-27890b96dba9}
This is not due to inconsistent dependencies from using different VirtualBox versions as I re-flashed Ubuntu 22.04 fresh and only installed VirtualBox version 6.1.44 and the error persists.