Bug #2320
closedForeman Proxy on Windows: Vendor Class not found Error
Description
Hi,
I'm currently setting up a new foreman infrastructure on our network. I used the instructions on the foreman website to installthe proxy under Windows. BTW I installed a proxy under Windows XP. This works fine as long as you add the dhcp option for netsh:
NETSH ADD HELPER DHCPMON.DLL
and install the ruby DEVKIT.
First problem is that the timeout in lib/proxy/dhcp/server/native_ms.rb is too low. It is set to 5 seconds and should be set to 10. Something I was able to fix myself for now.
But then I get this error when trying to import the subnets from the dhcp in foreman:
D, [2013-03-14T15:20:01.414954 #3564] DEBUG -- : Loading subnets for 172.28.20.14
D, [2013-03-14T15:20:01.430579 #3564] DEBUG -- : executing: c:\windows\system32\cmd.exe /c c:\Windows\System32\netsh.exe c dhcp server 172.28.20.14 show scope : Vendor class not found
I, [2013-03-14T15:20:08.946156 #3564] INFO -
E, [2013-03-14T15:20:08.946156 #3564] ERROR -- : Failed to enumerate the scopes on 172.28.20.14Vendor class not found
If using not the latest version of the smart-proxy under windows XP, this works just fine. I used the latest version of the smart-proxy as this was pointed out in the documentation.
Updated by Oliver Weinmann almost 12 years ago
Sorry this one should go under smart-proxy. Maybe one of the admins can move it? :)
Updated by Ohad Levy almost 12 years ago
- Project changed from Foreman to Smart Proxy
Updated by Ohad Levy almost 12 years ago
hmm.. in your dhcp server (e.g. via mmc) can you see the ability to add vendor options? we never tried it with WinXP only with 2000+ servers.
Updated by Oliver Weinmann almost 12 years ago
Hi Ohad,
the DHCP is running on windows server 2008 r2 and yes it supports Vendor Options. I just installed the smart-proxy under windows XP as we should not install any additional software on our Domain Controllers. The smart-proxy controlls the DHCP via the netsh commands. This works fine as long as I don't use the latest (development) version of smart-proxy.
Regards,
Oliver
Updated by Stefan Held over 11 years ago
Hi Oliver,
try adding the english Language pack.
Switch over to english as default display language and this error is gone.
Updated by Johan Sunnerstig over 10 years ago
While this is old, I figured I'd update it with a little FYI. I ran into this due to entering the DHCP server in settings.yml without the usual Windows souble-backslashes.
Changing it to ":dhcp_server: \\dhcp.mynetwork.com" fixed this right away. This can be seen in the original report as well, where the netsh-command being executed refers to the server by it's IP sans the double backslashes.
Perhaps this could be clarified in the comments in the settings.yml example file?
Updated by Matt Chesler almost 10 years ago
I ran into what seems like the same issue. In my logs, I saw entries like:
[2015-04-20T11:07:25.140098 #2344] ERROR -- : Failed to enumerate the scopes on 192.168.199.5Vendor class not found
I tried make the change suggested above, which just changed the error entries to:
[2015-04-20T11:35:25.454356 #2904] ERROR -- : Failed to enumerate the scopes on \\192.168.199.5Vendor class not found
After digging through the code an adding some gratuitous print statements, I discovered Proxy::SETTINGS.x86_64 being used in Proxy::DHCP::NativeMS#execute to choose between 'c:\windows\sysnative\cmd.exe' and 'c:\windows\system32\cmd.exe'. I haven't figured out why yet, but it somehow Proxy::SETTINGS.x86_64 was being set to true despite 'c:\windows\sysnative' not existing. When I add ':x86_64: false' to settings.yml and restart the smart proxy, it suddenly uses the correct interpreter path and functions as desired.
Updated by Anonymous almost 9 years ago
- Related to Bug #13129: Intermittent failures in native MS test_records_should_have_options tests added
Updated by Anonymous almost 9 years ago
- Description updated (diff)
- Status changed from New to Duplicate
This was resolved, see http://projects.theforeman.org/issues/13129 for details.