Skip to main content


Showing posts from 2022

Connect-NsxtServer shows "Unable to connect to the remote server"

When you run Connect-NsxtServer in the PowerCLI, it may show "Unable to connect to the remote server".  Because the error message is a little bit confusing with other login issues. It's not easy to troubleshoot. The actual reason is the NSX-T uses a self-signed certificate, and the PowerCLI cannot accept the certificate automatically. The fix is super easy. You need to set the PowerCLI to ignore the invalid certificate with the following command: Set-PowerCLIConfiguration -Scope User -InvalidCertificateAction:Ignore -Confirm:$false

Move Terraform Providers to Other Folders

Create a new control file with the name .terraformrc or terraform.rc in your profile folder. Add the following line: plugin_cache_dir = "$HOME/.terraform.d/plugin-cache" Create the folder .terraform.d/plugin-cache in your profile folder. The providers will be downloaded to the cache folder when you run terraform init . If you don't want to create the control file in the profile folder. The alternative is to create an environment variable. export TF_PLUGIN_CACHE_DIR="$HOME/.terraform.d/plugin-cache"

How to Use Proxy on WSL 2

1. Install cntlm.sudo   apt-get install cntlm 2. Configure the permission for cntlm.conf file. sudo chmod 644 /etc/cntlm.conf 3. Configure proxy settings.  sudo vi /etc/cntlm.conf 4. Make sure the following parameters are configured. Domain XXX Username XXX Proxy NoProxy localhost, 127.0.0., 10. Listen 3128 5. Test connectivity. (Hit enter key if it asks a password) cntlm -M 6. Generate hashed passwords. cntlm -H 7. Paste the generated passwords to the cntlm configuration file. 8. Configure proxy. export http_proxy=http://localhost:3128/ export https_proxy=http://localhost:3128 9. Start cntlm sudo cntlm -v -c /etc/cntlm.conf

Setup Terraform and Ansible for Windows provisionon CentOS

Provisioning Windows machines with Terraform is easy. Configuring Windows machines with Ansible is also not complex. However, it's a little bit challenging to combine them. The following steps are some ideas about handling a Windows machine from provisioning to post configuration without modifying the winrm configuration on the guest operating system. Install required repos for yum. yum -y install yum -y install yum -y install yum -y install epel-release yum -y install yum-utils yum-config-manager --add-repo Install  Terraform . sudo yum -y install terraform Install  Ansible . sudo yum -y install ansible Install  Kerberos . yum -y install gcc python-devel krb5-devel krb5-libs krb5-workstation

vSphere Web Client stuck on the loading screen

It’s been a while since my last post. I got an exciting issue a few days ago. I was trying to log in to a vCenter Server in Chrome. I can see the login screen and enter the credential. However, I was not able to get into the main page. vSphere Web Client was stuck on the “loading.” The reason is the Chrome version was 50. It’s incompatible with the vSphere Web Client version. Here are the vSphere Client requirements for your convenience.