Unable to run the NSX-T Edge Node Virtual Machine Resizing script
search cancel

Unable to run the NSX-T Edge Node Virtual Machine Resizing script

book

Article ID: 402883

calendar_today

Updated On:

Products

VMware SDDC Manager

Issue/Introduction

  • Running the script reveals that the tool is unable to connect to the vCenter that manages the Edge cluster:

resize.sh -l -v --user administrator@######.local --password "##########" --edge-cluster <cluster_name>

(in this example we are running with the -l option which lists the form factor of a specified cluster)

  • Terminal output:


2025-03-10T13:08:22.423Z [DEBUG connectionpool.py::_make_request::433::MainThread] http://localhost:80 "GET /v1/credentials?resourceType=NSXT_MANAGER HTTP/1.1" 200 None
2025-03-10T13:08:22.424Z [INFO vcf_creds.py::init::446::MainThread] workload_name = sap-wcs-01
2025-03-10T13:08:22.424Z [INFO resize.py::_getServerCredentials::2138::MainThread] Credential retrieval completed.
2025-03-10T13:09:22.637Z [ERROR util_log.py::logException::42::MainThread] Exception: Unable to connect to vCenter ###.###.###.###
..............
2025-03-10T13:09:22.638Z [ERROR util_log.py::logException::48::MainThread]   bt:     self.vcConn = VcConnection(self.creds.vcCred.ipAddr,
2025-03-10T13:09:22.638Z [ERROR util_log.py::logException::48::MainThread]   bt:   File "/home/vcf/resizer/vcf_utils/vc_connection.py", line 103, in init
2025-03-10T13:09:22.638Z [ERROR util_log.py::logException::48::MainThread]   bt:     raise Exception("Unable to connect to vCenter %s" % vCenterAddr)
2025-03-10T13:09:22.638Z [ERROR resize.py::init::1983::MainThread] ! Did not complete requested operation
2025-03-10T13:09:22.638Z [ERROR resize.py::_stopNow::1456::MainThread] Resizing utility is stopping now.

 

 

  • A proxy WAS configured in the SDDC but is now disabled

 

  • Running a curl test from the SDDC shows that even though the proxy is disabled the SDDC is still trying to connect via the proxy IP:

curl -v https://<vCenter_FQDN>

root@########: /home/vcf/resizer #
Uses proxy env variable no_proxy = localhost, 127.0.0.1, domain.local
Trying <PROXY_IP:PROXY_PORT>...
Connected to <PROXY_IP:PROXY_PORT>
CONNECT tunnel: HTTP/1.1 negotiation
.................
CONNECT tunnel failed, response 503
closing connection
Failed to establish a tunnel to <VCENTER_FQDN>
HTTP/1.1 503 CONNECT tunnel failed, response 503
root@#########: /home/vcf/resizer #

 

Environment

VCF 5.x

Cause

  • This can be caused by the presence of PROXY VARIABLES on the SDDC. These values are configured in the /etc/sysconfig/proxy file and can persist even though the proxy has been disabled in the SDDC UI.
  • To confirm:

Run:  printenv | grep -i proxy

  • Output similar to below confirms the presence of proxy variables:

http_proxy=http://<proxy_IP>:<proxy_port> <---!
https_proxy=http://<proxy_IP>:<proxy_port> <---!
no_proxy=localhost,###.###.###.###,domain.local

 

Resolution

  • Run 'unset' commands to flush the variables:

unset https_proxy
unset http_proxy

  • You should now be able to use the resizer script.