Acessing console on a remote VM
-
I am unable to access a VM console on a remote network and after researching understand that this is not possible.
I have just found this and am not confused:
https://xen-orchestra.com/blog/xo-console-from-everywhere/Is it possible to access a remote VM console via NAT?
-
You (your browser) can access the console from everywhere IF your XO is within the same network than the host. Even if you NAT access to XO, this will work. That's very different from what you are doing (XO outside the network). It doesn't work if XO has to access a host behind a NAT.
In that case, you need a proxy. See this blog post for more details: https://xen-orchestra.com/blog/xo-proxy-a-concrete-guide/
-
Thanks again Oliver. Following this guide:
https://xen-orchestra.com/blog/xo-proxy-a-concrete-guide/Totally lost on what password to use when registering the xo-cli.
xo-cli --register http://localhost xoa
I am using the CE so not sure if this feature is blocked.
-
@McHenry You need to register with the same credentials you use to sign in the web UI.
-
Thanks Julien, I tried that without success:
root@xoavm:~# xo-cli --register http://localhost admin@admin.net `--register` is deprecated and will be removed in the future, use `register` subcommand instead Password: ****************************** ā AggregateError [ECONNREFUSED]: at internalConnectMultiple (node:net:1118:18) at afterConnectMultiple (node:net:1685:7) { [errors]: [ Error: connect ECONNREFUSED ::1:80 at createConnectionError (node:net:1648:14) at afterConnectMultiple (node:net:1678:16) { address: '::1', code: 'ECONNREFUSED', errno: -111, port: 80, syscall: 'connect' }, Error: connect ECONNREFUSED 127.0.0.1:80 at createConnectionError (node:net:1648:14) at afterConnectMultiple (node:net:1678:16) { address: '127.0.0.1', code: 'ECONNREFUSED', errno: -111, port: 80, syscall: 'connect' } ], code: 'ECONNREFUSED' } root@xoavm:~#
Using https produced a different error:
root@xoavm:~# xo-cli --register https://localhost admin@admin.net `--register` is deprecated and will be removed in the future, use `register` subcommand instead Password: ****************************** ā Error: self-signed certificate at TLSSocket.onConnectSecure (node:_tls_wrap:1685:34) at TLSSocket.emit (node:events:519:28) at TLSSocket._finishInit (node:_tls_wrap:1085:8) at ssl.onhandshakedone (node:_tls_wrap:871:12) { code: 'DEPTH_ZERO_SELF_SIGNED_CERT' } root@xoavm:~#
-
I think I have found how to resolve the SSL issue:
https://xen-orchestra.com/docs/configuration.html#https-and-certificates -
Thank you. I needed to get the certificates sorted. Done and working.
- xo-cli registered
- proxy registered
When registering the proxy I had to specify the IP address. Does that mean the proxy IP needs to be static?
-
If you proxy (or reverse proxy) any stuff, yes, you need to have a fixed address for the proxy.