Diego cells show the wrong IP address in vSphere VCenter
search cancel

Diego cells show the wrong IP address in vSphere VCenter

book

Article ID: 297863

calendar_today

Updated On:

Products

VMware Tanzu Application Service for VMs

Issue/Introduction

In the VCenter UI, the VM summary for Diego Cells shows a random IP address, often the container IP, instead of the Diego Cell IP in the bosh vms output. 



Environment

OS: Any

Resolution

This issue is caused by Open VMware Tools selecting a random interface to display and sometimes this leads to container IP to be reported instead of Diego Cell IP.

Workaround

Note: Please be aware that this is not persistent and the procedure has to be repeated after recreating the Diego Cell(s).


For TAS (small footprint)

1. Login to the BOSH CLI.

2. Backup the original file for all Diego Cells.
bosh -e <environment> -d <cf-deployment> ssh compute -c 'sudo /bin/cp /etc/vmware-tools/tools.conf /etc/vmware-tools/tools.conf.backup'
3. Run the following command in order to modify the Open VMware Tools config file for all Diego Cells at once:
bosh -e <environment> -d <cf-deployment> ssh compute -c 'sudo /bin/echo -e $"[guestinfo]\nexclude-nics=s*\nprimary-nics=eth0"| sudo /usr/bin/tee -a /etc/vmware-tools/tools.conf
4. Restart Open VMware Tools for all Diego Cells:
bosh -e <environment> -d <cf-deployment> ssh compute -c 'sudo /etc/init.d/open-vm-tools restart'
5. Open VCenter and verify if the correct IP is reported in the UI. 
 

For TAS (standard deployment)

1. Login to the BOSH CLI

2. Backup the original file for all Diego Cells:
bosh -e <environment> -d <cf-deployment> ssh diego_cell -c 'sudo /bin/cp /etc/vmware-tools/tools.conf /etc/vmware-tools/tools.conf.backup'
3. Run the following command in order to modify the Open VMware Tools config file for all Diego Cells at once:
bosh -e <environment> -d <cf-deployment> ssh diego_cell -c 'sudo /bin/echo -e $"[guestinfo]\nexclude-nics=s*\nprimary-nics=eth0"| sudo /usr/bin/tee -a /etc/vmware-tools/tools.conf
4. Restart Open VMware Tools for all Diego Cells:
bosh -e <environment> -d <cf-deployment> ssh diego_cell -c 'sudo /etc/init.d/open-vm-tools restart'
5. Open VCenter and verify if the correct IP is reported in UI. 

 

To revert changes in case of an issue, please do the following:

For TAS (small footprint)

1. Login to the BOSH CLI.

2. Replace the original file:
bosh -e <environment> -d <cf-deployment> ssh diego_cell -c 'sudo /bin/cp /etc/vmware-tools/tools.conf.backup /etc/vmware-tools/tools.conf'
3. Restart Open VMware Tools for all Diego Cells:
bosh -e <environment> -d <cf-deployment> ssh compute -c 'sudo /etc/init.d/open-vm-tools restart'

For TAS (standard deployment)

1. Login to the BOSH CLI.

2. Replace the original file:
bosh -e <environment> -d <cf-deployment> ssh diego_cell -c 'sudo /bin/cp /etc/vmware-tools/tools.conf.backup /etc/vmware-tools/tools.conf'
3. Restart Open VMware Tools for all Diego Cells:
bosh -e <environment> -d <cf-deployment> ssh diego_cell -c 'sudo /etc/init.d/open-vm-tools restart'
The following is an example of the desired result: