VirtualBox

7 年 前 建立

7 年 前 結束

#16826 closed defect (fixed)

Wrong host-only netmask in Windows 10

回報者: rui.godinho.lopes 負責人:
元件: network/hostif 版本: VirtualBox 5.1.22
關鍵字: windows netmask hostonly 副本:
Guest type: other Host type: Windows

描述

host-only interfaces are being created with the wrong netmask. You can reproduce the problem by following the next steps.

Create a host-only interface:

    VBoxManage hostonlyif create
0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%
Interface 'VirtualBox Host-Only Ethernet Adapter #7' was successfully created

Assign it an IP and netmask:

    VBoxManage hostonlyif ipconfig "VirtualBox Host-Only Ethernet Adapter #7" --ip 10.123.0.33 --netmask 255.255.255.224

List host-only interfaces:

    VBoxManage list hostonlyifs
Name:            VirtualBox Host-Only Ethernet Adapter #7
GUID:            4028bf58-b908-47e1-a96a-0b2b9a0f6321
DHCP:            Disabled
IPAddress:       10.123.0.33
NetworkMask:     255.255.255.7
IPV6Address:     fe80:0000:0000:0000:c5ba:3657:c0a8:df00
IPV6NetworkMaskPrefixLength: 64
HardwareAddress: 0a:00:27:00:00:03
MediumType:      Ethernet
Status:          Up
VBoxNetworkName: HostInterfaceNetworking-VirtualBox Host-Only Ethernet Adapter #7

NB as you can see, NetworkMask is incorrectly returned as 255.255.255.7 instead of 255.255.255.224.

List the interface through Windows:

    netsh interface ip show addresses "VirtualBox Host-Only Network #7"
Configuration for interface "VirtualBox Host-Only Network #7"
    DHCP enabled:                         No
    IP Address:                           10.123.0.33
    Subnet Prefix:                        10.123.0.32/27 (mask 255.255.255.224)
    InterfaceMetric:                      25

NB as you can see, the network interface in Windows is correctly configured as 255.255.255.224.

更動歷史 (4)

comment:1 7 年 前Frank Mehnert 編輯

Thanks for this report. Actually the netmask was correctly set to the host-only adapter but when fetching the netmask back from the adapter, the prefix length was incorrectly converted to a netmask. Only Windows hosts affected. The most recent 5.1 Windows test build (>= 116114) has the fix.

回覆:  1 comment:2 7 年 前Socratis 編輯

Replying to frank:

The most recent 5.1 Windows test build (>= 116114) has the fix.

The test builds go only up to 116111. Is that a future promise? :D

comment:3 7 年 前Frank Mehnert 編輯

Of course :) New 5.1 Windows build now available.

comment:4 7 年 前Frank Mehnert 編輯

狀態: newclosed
處理結果: fixed

Fix is part of 5.1.24.

注意: 瀏覽 TracTickets 來幫助您使用待辦事項功能

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette