Skip to content

Instantly share code, notes, and snippets.

View hurryman2212's full-sized avatar
πŸ‘¨β€πŸŽ“
Ph.D. Candidate

Jihong Min hurryman2212

πŸ‘¨β€πŸŽ“
Ph.D. Candidate
View GitHub Profile
@lukasnellen
lukasnellen / README.md
Last active December 19, 2025 09:18
Connect host and VM when using MACVTAP instead of TAP interfaces

Connect host and VM when using a MACVTAP interface

NB: The following is only of interest if you want to share the host network with your virtual machine. The most common way this gets implemented is by setting up a bridge which includes the physical interface. Using a [MACVTAP] inerface is suposed to be more efficient, since it avoids the additional bridge in the network setup.

In this gist, we extend the information provided in the documenation on linux virtual interfaces.

In the following, we assume you host interface is eth0. IP addresses used:

  • host: 198.51.100.50/24
  • virtual machine: 198.51.100.198/24
  • default gateway: 198.51.100.254
@nrdmn
nrdmn / vsock-notes.md
Last active March 30, 2026 04:00
vsock notes

vsock notes

about vsocks

Vsocks are a means of providing socket communication (either stream or datagram) directly between VMs and their host operating system. The host and each VM have a 32 bit CID (Context IDentifier) and may connect or bind to a 32 bit port number. Ports < 1024 are privileged ports.