[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
port-i386/51476: vmt can't send long hostnames to VMware host
>Synopsis: vmt can't send long hostnames to VMware host
>Arrival-Date: Wed Sep 14 11:25:00 +0000 2016
>Originator: Francis Rounds
>Release: -current 7.99.37 201609140250Z
NetBSD aaaaaaa.aaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaa.aaaaaaaab.domain.local 7.99.37 NetBSD 7.99.37 (GENERIC.201609140250Z) amd64
When a long hostname is set (240 characters or longer), the vmt driver is unable to send the hostname to the VMware/ESXi host.
dmesg shows the following errors:
vmt0: rpci command didn't fit in buffer
vmt0: unable to set hostname
Set a hostname of 240 characters or longer, either using /etc/rc.conf and rebooting or using the hostname(1) command and waiting until the vmt0 errors appear on the console. In either case, dmesg should show the error.
That is, either set the following in /etc/rc.conf:
In src/sys/arch/x86/x86/vmt.c, VMT_RPC_BUFLEN (the maximum size of the buffer used to communicate over the RPCI channel) is set to 256, which is also the value of MAXHOSTNAMELEN, the maximum length of a fully-qualified domain name.
Since the command to be sent is "SetGuestInfo 1 hostname" (where "hostname" is obviously the hostname to send to the host) and the "SetGuestInfo 1" prefix is 16 bytes long, adding at least 16 bytes to VMT_RPC_BUFLEN fixes the issue.
This was apparently also an issue in the original vmt from OpenBSD, but the buffer length was recently increased and so it's no longer an issue there: http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/sys/dev/pv/vmt.c?rev=1.8&content-type=text/x-cvsweb-markup
Main Index |
Thread Index |