access to a VM that runs on Minikube, by vncviewer

964 views
Skip to first unread message

Leonardo Massei

unread,
Mar 3, 2021, 5:44:35 AM3/3/21
to kubevirt-dev

Hi to all,
I'm a newbie in Kubevirt world so I'm doing some experiences with Minikube plus the Kubevirt addon.
My scenario is: I created a Windows_VM on the Minikube node (the Minikube Linux machine is hosted under a Windows10 real machine); the Window_VM is running correctly because I see the following info:

PS C:\WINDOWS\system32> minikube kubectl -- get vmi
NAME          AGE   PHASE     IP            NODENAME
win2k12-iso   23m   Running   172.17.0.20   minikube

I tried two ways:

1) The Kubevirt command (vnc) but it fails
PS C:\WINDOWS\system32> minikube kubectl -- virt vnc win2k12-iso
{"component":"","level":"info","msg":"connection timeout: 1m0s","pos":"vnc.go:144","timestamp":"2021-03-03T11:34:29.805402Z"}
Error encountered: could not find remote-viewer or vncviewer binary in $PATH
Error: exit status 1

2) The interesting example @
but, also in this case, something not works. If I trie to acces with the browser with the
url "http://192.168.99.104:30971/" I see a white page only though the service virtvnc is active

PS C:\WINDOWS\system32> minikube service virtvnc --url -n kubevirt
http://192.168.99.104:30971

and

PS C:\WINDOWS\system32> minikube kubectl -- get service -n kubevirt
NAME                          TYPE        CLUSTER-IP       EXTERNAL-IP   PORT(S)          AGE
kubevirt-operator-webhook     ClusterIP   10.106.142.203   <none>        443/TCP          38h
kubevirt-prometheus-metrics   ClusterIP   10.108.9.17      <none>        443/TCP          38h
virt-api                      ClusterIP   10.100.79.249    <none>        443/TCP          38h
virtvnc                       NodePort    10.109.40.6      <none>        8001:30971/TCP   36h

Many thanks in advance
Best regards
Leonard

Mazzystr

unread,
Mar 3, 2021, 11:30:28 AM3/3/21
to Leonardo Massei, kubevirt-dev
Do you have the service port open in the firewall?


--
You received this message because you are subscribed to the Google Groups "kubevirt-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kubevirt-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kubevirt-dev/d47b5084-1972-4fc8-aa8f-2ee3f975b874n%40googlegroups.com.

dvo...@redhat.com

unread,
Mar 4, 2021, 10:36:12 AM3/4/21
to kubevirt-dev
On Wednesday, March 3, 2021 at 5:44:35 AM UTC-5 leonard...@gmail.com wrote:

Hi to all,
I'm a newbie in Kubevirt world so I'm doing some experiences with Minikube plus the Kubevirt addon.
My scenario is: I created a Windows_VM on the Minikube node (the Minikube Linux machine is hosted under a Windows10 real machine); the Window_VM is running correctly because I see the following info:

PS C:\WINDOWS\system32> minikube kubectl -- get vmi
NAME          AGE   PHASE     IP            NODENAME
win2k12-iso   23m   Running   172.17.0.20   minikube

I tried two ways:

1) The Kubevirt command (vnc) but it fails
PS C:\WINDOWS\system32> minikube kubectl -- virt vnc win2k12-iso
{"component":"","level":"info","msg":"connection timeout: 1m0s","pos":"vnc.go:144","timestamp":"2021-03-03T11:34:29.805402Z"}
Error encountered: could not find remote-viewer or vncviewer binary in $PATH
Error: exit status 1

hey, this didn't work because virtctl is attempting to open a linux tool "remote-viewer" as a vnc client. Since you're executing kubectl on a windows box as the client, that won't work.

Here's another option, run the client tool and have it simply open up a local vnc proxy connection for you.

PS C:\WINDOWS\system32> minikube kubectl -- virt vnc ---proxy-only win2k12-iso

The log output will display the local connection you can use with a VNC client to connect. Then pick any vnc client you can run locally on your windows box and point it to that local connection. 

Wenwei Lin

unread,
Sep 29, 2021, 8:37:42 AM9/29/21
to kubevirt-dev
hello

have any method let "kubectl -- virt vnc" command can automatically invoke windows version vnc client? 

David Vossel

unread,
Sep 29, 2021, 11:30:28 AM9/29/21
to Wenwei Lin, kubevirt-dev
On Wed, Sep 29, 2021 at 8:38 AM Wenwei Lin <we...@redhat.com> wrote:
hello

have any method let "kubectl -- virt vnc" command can automatically invoke windows version vnc client? 

nope, the best option for running vnc client from a windows host is to use the --proxy-only argument. 
 
--
You received this message because you are subscribed to a topic in the Google Groups "kubevirt-dev" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/kubevirt-dev/KPajH1nHB1g/unsubscribe.
To unsubscribe from this group and all its topics, send an email to kubevirt-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kubevirt-dev/0340370b-9d15-40cc-be65-b8cef6490d9fn%40googlegroups.com.

Wenwei Lin

unread,
Sep 29, 2021, 11:34:45 AM9/29/21
to David Vossel, kubevirt-dev
Thanks reply

发件人: kubevi...@googlegroups.com <kubevi...@googlegroups.com> 代表 David Vossel <dvo...@redhat.com>
发送时间: Wednesday, September 29, 2021 11:30:10 PM
收件人: Wenwei Lin <we...@redhat.com>
抄送: kubevirt-dev <kubevi...@googlegroups.com>
主题: Re: [kubevirt-dev] Re: access to a VM that runs on Minikube, by vncviewer
 
You received this message because you are subscribed to the Google Groups "kubevirt-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to kubevirt-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/kubevirt-dev/CAPjOJFu-T66kHOzcnZJWSJjuQUTCBDV7%2BaYeqxK53%2BXn_v07Dg%40mail.gmail.com.
Reply all
Reply to author
Forward
0 new messages