为了允许流量通过网络路由到我的 KVM VM,我的托管公司想知道 MAC 地址。我设置的方式是我的 VM 使用与主机不同的 IP。我有网桥和 VM(使用我从托管公司获得的第二个 IP),它们似乎都有 mac 地址。那么托管公司会看到什么 MAC 地址(通过主机从我的 VM 出来)。第二个 IP 仅在 VM 上设置,其他地方不知道。
他们还想知道 IP,即我在虚拟机上设置的辅助 IP?
主机是CentOS,客户机是Ubuntu 16.04。
Fasthosts 支持有点差,所以无法从他们那里获得帮助。
我的虚拟机有一个 MAC 地址,并且具有以下内容:
$ /sbin/ifconfig -a
br0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet xxx.171.204.107 netmask 255.255.255.255 broadcast 213.171.204.107
inet6 fe80::2e4d:54ff:fe43:92df prefixlen 64 scopeid 0x20<link>
ether 2c:4d:54:43:92:df txqueuelen 1000 (Ethernet)
RX packets 4418472 bytes 3176695519 (2.9 GiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 1685001 bytes 3467150762 (3.2 GiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
br-369501bb177f: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
inet 172.18.0.1 netmask 255.255.0.0 broadcast 172.18.255.255
inet6 fe80::42:22ff:fe7c:d452 prefixlen 64 scopeid 0x20<link>
ether 02:42:22:7c:d4:52 txqueuelen 0 (Ethernet)
RX packets 4418472 bytes 3176695519 (2.9 GiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 1685005 bytes 3467151466 (3.2 GiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
enp7s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet xxx.171.204.107 netmask 255.255.252.0 broadcast 213.171.207.255
inet6 fe80::2e4d:54ff:fe43:92df prefixlen 64 scopeid 0x20<link>
ether 2c:4d:54:43:92:df txqueuelen 1000 (Ethernet)
RX packets 76116319 bytes 47205826581 (43.9 GiB)
RX errors 0 dropped 10 overruns 0 frame 0
TX packets 217240694 bytes 282949224905 (263.5 GiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device memory 0xfa200000-fa27ffff
enp8s0: flags=4098<BROADCAST,MULTICAST> mtu 1500
ether 2c:4d:54:43:92:e0 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device memory 0xfa100000-fa17ffff
lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 1000 (Local Loopback)
RX packets 1924639 bytes 230337577 (219.6 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 1924639 bytes 230337577 (219.6 MiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
virbr0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
inet 192.168.122.1 netmask 255.255.255.0 broadcast 192.168.122.255
ether 52:54:00:56:31:0e txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
virbr0-nic: flags=4098<BROADCAST,MULTICAST> mtu 1500
ether 52:54:00:56:31:0e txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
vnet0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet6 fe80::fc54:ff:fe3e:e407 prefixlen 64 scopeid 0x20<link>
ether fe:54:00:3e:e4:07 txqueuelen 1000 (Ethernet)
RX packets 5190 bytes 218916 (213.7 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 767907 bytes 194377408 (185.3 MiB)
TX errors 0 dropped 27442 overruns 0 carrier 0 collisions 0
答案1
我需要给他们的是虚拟机的 MAC 地址。他们实际上比平时更有帮助。