-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hyperv: Method invocation is supported only on core types in this language mode. #7990
Comments
This seems to be an issue with the permissions in your terminal:
Although I was not able to reproduce this issue (I was able to build minikube in a elevated powershell in ContrainedLanguage mode), I believe that's the source of the error. Have you tried using a regular admin terminal? |
Hi,
Thank you for your reply.
I have changed the registry value of PSLockDown to 8 and it is working fine
now. There is another issue registry value is keep changing to 4 now. is
there any way to fix the registry value to 8
Regards,
Gaurav Naik
…On Tue, 5 May, 2020, 9:48 PM Sharif Elgamal, ***@***.***> wrote:
This seems to be an issue with the permissions in your terminal:
I0504 08:44:26.844755 5860 main.go:110] libmachine: [stderr =====>] : Cannot invoke method. Method invocation is supported only on core types in this language mode.
At line:1 char:1
@([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIde ...
+ CategoryInfo : InvalidOperation: (:) [], RuntimeException
+ FullyQualifiedErrorId : MethodInvocationNotSupportedInConstrainedLanguage
Although I was not able to reproduce this issue (I was able to build
minikube in a elevated powershell in ContrainedLanguage mode), I believe
that's the source of the error. Have you tried using a regular admin
terminal?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#7990 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGOP2FOD4KNIERJMSG3QYVDRQA36NANCNFSM4MYNKZDA>
.
|
@Jack881 do u mind trying with out latest version v1.0.1 ? |
Yes I am still facing issue
…On Wed, 3 Jun, 2020, 11:41 PM priyawadhwa, ***@***.***> wrote:
Hey @Jack881 <https://github.com/Jack881> are you still seeing this issue
with the latest version v1.11.0
<https://github.com/kubernetes/minikube/releases/tag/v1.11.0>?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#7990 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGOP2FPRVTL4VEKXBPJ5QP3RU2G53ANCNFSM4MYNKZDA>
.
|
have you tried with administrative powershell ? |
Yes I am trying with admin privileges and after every reboot I have to
change the registry value
On Thu, 4 Jun, 2020, 4:47 AM Medya Ghazizadeh, <notifications@github.com>
wrote:
… Yes I am still facing issue
… <#m_-7538877095679038270_>
On Wed, 3 Jun, 2020, 11:41 PM priyawadhwa, *@*.***> wrote: Hey @Jack881
<https://github.com/Jack881> https://github.com/Jack881 are you still
seeing this issue with the latest version v1.11.0
https://github.com/kubernetes/minikube/releases/tag/v1.11.0? — You are
receiving this because you were mentioned. Reply to this email directly,
view it on GitHub <#7990 (comment)
<#7990 (comment)>>,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AGOP2FPRVTL4VEKXBPJ5QP3RU2G53ANCNFSM4MYNKZDA
.
have you tried with administrative powershell ?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#7990 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGOP2FJAV3NQUCFGXGHZQQDRU3KYVANCNFSM4MYNKZDA>
.
|
@Jack881 for more information on the docker driver checkout: |
This happens if PSLockDown is set: https://devblogs.microsoft.com/powershell/powershell-constrained-language-mode/ The Hyper-V driver currently requires PowerShell scripting to work. We should give this error message a solution which mentions how to adjust PSLockDown. |
I would be happy to review any PR that detects this and suggests to the user in powershell to do the solution mentioned in #7990 (comment) |
A better error message would be helpful here. |
Steps to reproduce the issue:
1.minikube start
2.
3.
Full output of failed command:
C:\windows\system32>minikube start --alsologtostderr -v=1
I0504 08:44:24.795853 5860 start.go:259] hostinfo: {"hostname":"PUN-GNAIK02","uptime":3738,"bootTime":1588558326,"procs":263,"os":"windows","platform":"Microsoft Windows 10 Enterprise","platformFamily":"Standalone Workstation","platformVersion":"10.0.18362 Build 18362","kernelVersion":"","virtualizationSystem":"","virtualizationRole":"","hostid":"754650a7-4a07-48a5-8830-1c1aff7e24db"}
W0504 08:44:24.796844 5860 start.go:267] gopshost.Virtualization returned error: not implemented yet
I0504 08:44:24.805806 5860 driver.go:226] Setting default libvirt URI to qemu:///system
W0504 08:44:24.805806 5860 start.go:547] selectDriver api.Load: filestore "minikube": Docker machine "minikube" does not exist. Use "docker-machine ls" to list machines. Use "docker-machine create" to add a new one.
I0504 08:44:26.185815 5860 start.go:307] selected driver: hyperv
I0504 08:44:26.186789 5860 start.go:596] validating driver "hyperv" against &{Name:minikube KeepContext:false EmbedCerts:false MinikubeISO:https://storage.googleapis.com/minikube/iso/minikube-v1.9.0.iso Memory:4000 CPUs:2 DiskSize:20000 Driver:hyperv HyperkitVpnKitSock: HyperkitVSockPorts:[] DockerEnv:[] InsecureRegistry:[] RegistryMirror:[] HostOnlyCIDR:192.168.99.1/24 HypervVirtualSwitch: HypervUseExternalSwitch:false HypervExternalAdapter: KVMNetwork:default KVMQemuURI:qemu:///system KVMGPU:false KVMHidden:false DockerOpt:[] DisableDriverMounts:false NFSShare:[] NFSSharesRoot:/nfsshares UUID: NoVTXCheck:false DNSProxy:false HostDNSResolver:true HostOnlyNicType:virtio NatNicType:virtio KubernetesConfig:{KubernetesVersion:v1.18.0 ClusterName:minikube APIServerName:minikubeCA APIServerNames:[] APIServerIPs:[] DNSDomain:cluster.local ContainerRuntime:docker CRISocket: NetworkPlugin: FeatureGates: ServiceCIDR:10.96.0.0/12 ImageRepository: ExtraOptions:[] ShouldLoadCachedImages:true EnableDefaultCNI:false NodeIP: NodePort:0 NodeName:} Nodes:[{Name:m01 IP: Port:8443 KubernetesVersion:v1.18.0 ControlPlane:true Worker:true}] Addons:map[]}
I0504 08:44:26.186789 5860 start.go:602] status for hyperv: {Installed:true Healthy:true Error: Fix: Doc:}
I0504 08:44:26.187790 5860 start.go:946] Using suggested 4000MB memory alloc based on sys=16263MB, container=0MB
I0504 08:44:26.187790 5860 iso.go:119] acquiring lock: {Name:mka7d949eb3e5814bbf3c27fa46f8ef5c69d2355 Clock:{} Delay:500ms Timeout:10m0s Cancel:}
I0504 08:44:26.188808 5860 preload.go:81] Checking if preload exists for k8s version v1.18.0 and runtime docker
I0504 08:44:26.188808 5860 preload.go:97] Found local preload: C:\Users\gaurav.naik.minikube\cache\preloaded-tarball\preloaded-images-k8s-v2-v1.18.0-docker-overlay2-amd64.tar.lz4
I0504 08:44:26.188808 5860 cache.go:46] Caching tarball of preloaded images
I0504 08:44:26.189817 5860 preload.go:123] Found C:\Users\gaurav.naik.minikube\cache\preloaded-tarball\preloaded-images-k8s-v2-v1.18.0-docker-overlay2-amd64.tar.lz4 in cache, skipping download
I0504 08:44:26.189817 5860 cache.go:49] Finished downloading the preloaded tar for v1.18.0 on docker
I0504 08:44:26.189817 5860 profile.go:138] Saving config to C:\Users\gaurav.naik.minikube\profiles\minikube\config.json ...
I0504 08:44:26.192815 5860 cache.go:117] Successfully downloaded all kic artifacts
I0504 08:44:26.192815 5860 start.go:260] acquiring machines lock for minikube: {Name:mk9247ecc4d9f263aa04a4c3cc12607cdf59a575 Clock:{} Delay:500ms Timeout:15m0s Cancel:}
I0504 08:44:26.192815 5860 start.go:264] acquired machines lock for "minikube" in 0s
I0504 08:44:26.194041 5860 start.go:86] Provisioning new machine with config: {Name:minikube KeepContext:false EmbedCerts:false MinikubeISO:https://storage.googleapis.com/minikube/iso/minikube-v1.9.0.iso Memory:4000 CPUs:2 DiskSize:20000 Driver:hyperv HyperkitVpnKitSock: HyperkitVSockPorts:[] DockerEnv:[] InsecureRegistry:[] RegistryMirror:[] HostOnlyCIDR:192.168.99.1/24 HypervVirtualSwitch: HypervUseExternalSwitch:false HypervExternalAdapter: KVMNetwork:default KVMQemuURI:qemu:///system KVMGPU:false KVMHidden:false DockerOpt:[] DisableDriverMounts:false NFSShare:[] NFSSharesRoot:/nfsshares UUID: NoVTXCheck:false DNSProxy:false HostDNSResolver:true HostOnlyNicType:virtio NatNicType:virtio KubernetesConfig:{KubernetesVersion:v1.18.0 ClusterName:minikube APIServerName:minikubeCA APIServerNames:[] APIServerIPs:[] DNSDomain:cluster.local ContainerRuntime:docker CRISocket: NetworkPlugin: FeatureGates: ServiceCIDR:10.96.0.0/12 ImageRepository: ExtraOptions:[] ShouldLoadCachedImages:true EnableDefaultCNI:false NodeIP: NodePort:0 NodeName:} Nodes:[{Name:m01 IP: Port:8443 KubernetesVersion:v1.18.0 ControlPlane:true Worker:true}] Addons:map[]} {Name:m01 IP: Port:8443 KubernetesVersion:v1.18.0 ControlPlane:true Worker:true}
I0504 08:44:26.194102 5860 start.go:107] createHost starting for "m01" (driver="hyperv")
I0504 08:44:26.197790 5860 start.go:143] libmachine.API.Create for "minikube" (driver="hyperv")
I0504 08:44:26.197790 5860 client.go:169] LocalClient.Create starting
I0504 08:44:26.197790 5860 main.go:110] libmachine: Reading certificate data from C:\Users\gaurav.naik.minikube\certs\ca.pem
I0504 08:44:26.198800 5860 main.go:110] libmachine: Decoding PEM data...
I0504 08:44:26.198800 5860 main.go:110] libmachine: Parsing certificate...
I0504 08:44:26.199801 5860 main.go:110] libmachine: Reading certificate data from C:\Users\gaurav.naik.minikube\certs\cert.pem
I0504 08:44:26.199801 5860 main.go:110] libmachine: Decoding PEM data...
I0504 08:44:26.200793 5860 main.go:110] libmachine: Parsing certificate...
I0504 08:44:26.200793 5860 main.go:110] libmachine: [executing ==>] : C:\windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive @(Get-Module -ListAvailable hyper-v).Name | Get-Unique
I0504 08:44:26.573815 5860 main.go:110] libmachine: [stdout =====>] : Hyper-V
I0504 08:44:26.573815 5860 main.go:110] libmachine: [stderr =====>] :
I0504 08:44:26.574792 5860 main.go:110] libmachine: [executing ==>] : C:\windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive @([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole(([System.Security.Principal.SecurityIdentifier]::new("S-1-5-32-578")))
I0504 08:44:26.844755 5860 main.go:110] libmachine: [stdout =====>] :
I0504 08:44:26.844755 5860 main.go:110] libmachine: [stderr =====>] : Cannot invoke method. Method invocation is supported only on core types in this language mode.
At line:1 char:1
I0504 08:44:26.845757 5860 main.go:110] libmachine: exit status 1
I0504 08:44:26.845757 5860 main.go:110] libmachine: [executing ==>] : C:\windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive @([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole] "Administrator")
I0504 08:44:27.110982 5860 main.go:110] libmachine: [stdout =====>] :
I0504 08:44:27.110982 5860 main.go:110] libmachine: [stderr =====>] : Cannot invoke method. Method invocation is supported only on core types in this language mode.
At line:1 char:1
I0504 08:44:27.112237 5860 client.go:172] LocalClient.Create took 914.4474ms
I0504 08:44:29.113540 5860 start.go:110] createHost completed in 2.919439s
I0504 08:44:29.113540 5860 start.go:77] releasing machines lock for "minikube", held for 2.9197522s
! StartHost failed, but will try again: creating host: create: precreate: exit status 1
I0504 08:44:30.816387 5860 delete.go:45] couldn't inspect container "minikube" before deleting, docker-daemon might needs a restart!: inspecting container: output
Error: No such object: minikube
: exit status 1
I0504 08:44:30.830287 5860 delete.go:45] couldn't inspect container "minikube" before deleting, podman-daemon might needs a restart!: inspecting container: output : exec: "podman": executable file not found in %PATH%
W0504 08:44:30.830577 5860 start.go:335] delete host: Docker machine "minikube" does not exist. Use "docker-machine ls" to list machines. Use "docker-machine create" to add a new one.
I0504 08:44:35.831162 5860 start.go:260] acquiring machines lock for minikube: {Name:mk9247ecc4d9f263aa04a4c3cc12607cdf59a575 Clock:{} Delay:500ms Timeout:15m0s Cancel:}
I0504 08:44:35.832008 5860 start.go:264] acquired machines lock for "minikube" in 845.8µs
I0504 08:44:35.834997 5860 start.go:86] Provisioning new machine with config: {Name:minikube KeepContext:false EmbedCerts:false MinikubeISO:https://storage.googleapis.com/minikube/iso/minikube-v1.9.0.iso Memory:4000 CPUs:2 DiskSize:20000 Driver:hyperv HyperkitVpnKitSock: HyperkitVSockPorts:[] DockerEnv:[] InsecureRegistry:[] RegistryMirror:[] HostOnlyCIDR:192.168.99.1/24 HypervVirtualSwitch: HypervUseExternalSwitch:false HypervExternalAdapter: KVMNetwork:default KVMQemuURI:qemu:///system KVMGPU:false KVMHidden:false DockerOpt:[] DisableDriverMounts:false NFSShare:[] NFSSharesRoot:/nfsshares UUID: NoVTXCheck:false DNSProxy:false HostDNSResolver:true HostOnlyNicType:virtio NatNicType:virtio KubernetesConfig:{KubernetesVersion:v1.18.0 ClusterName:minikube APIServerName:minikubeCA APIServerNames:[] APIServerIPs:[] DNSDomain:cluster.local ContainerRuntime:docker CRISocket: NetworkPlugin: FeatureGates: ServiceCIDR:10.96.0.0/12 ImageRepository: ExtraOptions:[] ShouldLoadCachedImages:true EnableDefaultCNI:false NodeIP: NodePort:0 NodeName:} Nodes:[{Name:m01 IP: Port:8443 KubernetesVersion:v1.18.0 ControlPlane:true Worker:true}] Addons:map[]} {Name:m01 IP: Port:8443 KubernetesVersion:v1.18.0 ControlPlane:true Worker:true}
I0504 08:44:35.834997 5860 start.go:107] createHost starting for "m01" (driver="hyperv")
I0504 08:44:35.838190 5860 start.go:143] libmachine.API.Create for "minikube" (driver="hyperv")
I0504 08:44:35.838190 5860 client.go:169] LocalClient.Create starting
I0504 08:44:35.838995 5860 main.go:110] libmachine: Reading certificate data from C:\Users\gaurav.naik.minikube\certs\ca.pem
I0504 08:44:35.838995 5860 main.go:110] libmachine: Decoding PEM data...
I0504 08:44:35.838995 5860 main.go:110] libmachine: Parsing certificate...
I0504 08:44:35.840002 5860 main.go:110] libmachine: Reading certificate data from C:\Users\gaurav.naik.minikube\certs\cert.pem
I0504 08:44:35.840002 5860 main.go:110] libmachine: Decoding PEM data...
I0504 08:44:35.840002 5860 main.go:110] libmachine: Parsing certificate...
I0504 08:44:35.840995 5860 main.go:110] libmachine: [executing ==>] : C:\windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive @(Get-Module -ListAvailable hyper-v).Name | Get-Unique
I0504 08:44:36.231995 5860 main.go:110] libmachine: [stdout =====>] : Hyper-V
I0504 08:44:36.231995 5860 main.go:110] libmachine: [stderr =====>] :
I0504 08:44:36.232997 5860 main.go:110] libmachine: [executing ==>] : C:\windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive @([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole(([System.Security.Principal.SecurityIdentifier]::new("S-1-5-32-578")))
I0504 08:44:36.513996 5860 main.go:110] libmachine: [stdout =====>] :
I0504 08:44:36.513996 5860 main.go:110] libmachine: [stderr =====>] : Cannot invoke method. Method invocation is supported only on core types in this language mode.
At line:1 char:1
I0504 08:44:36.514996 5860 main.go:110] libmachine: exit status 1
I0504 08:44:36.514996 5860 main.go:110] libmachine: [executing ==>] : C:\windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NonInteractive @([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole] "Administrator")
I0504 08:44:36.788452 5860 main.go:110] libmachine: [stdout =====>] :
I0504 08:44:36.788452 5860 main.go:110] libmachine: [stderr =====>] : Cannot invoke method. Method invocation is supported only on core types in this language mode.
At line:1 char:1
I0504 08:44:36.789452 5860 client.go:172] LocalClient.Create took 950.4582ms
I0504 08:44:38.790093 5860 start.go:110] createHost completed in 2.955098s
I0504 08:44:38.790093 5860 start.go:77] releasing machines lock for "minikube", held for 2.955098s
E0504 08:44:38.793086 5860 style.go:173] unable to parse "X Unable to start VM after repeated tries. Please try {{'minikube delete' if possible\n": template: X Unable to start VM after repeated tries. Please try {{'minikube delete' if possible
:1: malformed character constant: 'minikube delete' - returning raw string.
X Unable to start VM after repeated tries. Please try {{'minikube delete' if possible
C:\windows\system32>
Full output of
minikube start
command used, if not already included:C:\windows\system32>minikube start
! StartHost failed, but will try again: creating host: create: precreate: exit status 1
Optional: Full output of
minikube logs
command:The text was updated successfully, but these errors were encountered: