VMware Cloud Community
jediller
Contributor
Contributor

Ways to enable ssh on ESXi

Is there a way to enable ssh on ESXi without attaching it to a VCenter    

Are there ways to do this without a browser, and if so what are they?

5 Replies
a_p_
Leadership
Leadership

You can enable SSH through either the vSphere Client, the DCUI (console), or even using e.g. PowerCLI?

André

jediller
Contributor
Contributor

Thanks, this helped. I was able to find a snippet on stackover that was somewhat close to what I needed.

    from pyVim.connect import SmartConnect, Disconnect

ImportError: No module named pyVim.connect

It however works fine, if I run it in python3

does pyVim require python3, or do I just need to correct my environment to run with python 2.7 ?

0 Kudos
TheBobkin
Champion
Champion

Hello jediller

Not sure if helps but different builds of ESXi have different python versions e.g.:

[root@localhost:~] vmware -vl

VMware ESXi 6.5.0 build-5969303

VMware ESXi 6.5.0 Update 1

[root@localhost:~] python --version

Python 3.5.3

What build/ESXi are you using these on? python 2.7 was ~6.0-6.2? I can't find a list...

Bob

0 Kudos
Jitu211003
Hot Shot
Hot Shot

Hi,

You can use one of below steps.

1. Take direct ilo console and from there go to troubleshooting option then you can enable ssh.

2. Connect via vsphere client and then enable the ssh.

thanks

Vmwarediary.com

jediller
Contributor
Contributor

vmware -vl

VMware ESXi 6.5.0 build-6765664

VMware ESXi 6.5.0 Update 1

python --version

Python 3.5.3

Is what I am using.

My problem appears to be at the originating end. The pyvmomi I have seems to have some features which require Python 3.

That is unlikely to be a show stopper, but since my project is likely to stay on python 2.7 my preference would be not to mix invoking Python 3.

I do appreciate your assistance. Thanks.

0 Kudos