Dynamic mode requires gateway parameter
plandevida opened this issue · 3 comments
I just download the module with the web-installer and git, but I got some errors trying to install it.
The documentation specifies for the dynamic mode I can use the command:
Install-WslIpHandler Ubuntu
But it gives an error requiring extra parameters:
PS C:\Users\default\Documents\PowerShell\Modules\Wsl-IpHandler> Install-WslIpHandler Ubuntu-20.04 PowerShell installing Wsl-IpHandler to Ubuntu-20.04... PowerShell finished installation of Wsl-IpHandler to Ubuntu-20.04 with Errors: Gateway IP Address is not specified neither as parameter nor in .wslconfig. WSL Hyper-V Network Adapter cannot be setup without Gateway IP Address!
Adding the required parameter I got a timeout:
PS C:\Users\default\Documents\PowerShell\Modules\Wsl-IpHandler> Install-WslIpHandler -WslInstanceName Ubuntu-20.04 -GatewayIpAddress 192.168.188.1 PowerShell installing Wsl-IpHandler to Ubuntu-20.04... Set-WslNetworkAdapter: vEthernet (WSL) Network Connection Setup did not succeed after [30] seconds. Try increasing timeout with '-Timeout' parameter.
And, If I try to increase the timeout value that parameter does not exist:
PS C:\Users\default\Documents\PowerShell\Modules\Wsl-IpHandler> Install-WslIpHandler -WslInstanceName Ubuntu-20.04 -GatewayIpAddress 192.168.188.1 -Timeout 300 Install-WslIpHandler: A parameter cannot be found that matches parameter name 'Timeout'.
Ending in this error starting the wsl ditro:
Remove-HostFromRecords: C:\Users\default\Documents\PowerShell\Modules\Wsl-IpHandler\Scripts\Powershell\FunctionsHostsFi le.ps1:326 Line | 326 | Remove-HostFromRecords -Record $_ -HostName $HostName -Mo … | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | The property 'Count' cannot be found on this object. Verify that the property exists.
Thanks for reporting this.
Sorry about the error - I have pushed the commit with Version 0.14.6
which should fix it.
@wikiped thanks!, I'll tray it tomorrow