Add multiple hosts to vCenter and license them using PowerCLI

If you are going to add multiple hosts to vCenter and license them, it will take a while if you do it manually. Instead you can PowerCLI script it.

Open vSphere PowerCLI console and connect to the vCenter.

Connect-VIServer -Server  $vCenterServerName

Next run the following commands for each host which add them to vCenter and then license them.

Add-VMHost $hostname  -location $cluster -user root -password $root_password  -force:$true
Set-VMHost -VMHost $hostname -LicenseKey $license_key

Continue reading


Network service troubleshooting and port scanning

At a former workplace, the DB2 team were furious because they couldn’t connect to the database remotely. They have been constantly trying to telnet into a port on the server and they couldn’t. They server wasn’t listening on the port they were trying to telnet into. They have rebooted the server twice and nobody thought of checking the listening ports. The solution was a simple restart of the DB service.

Ping the server. If the server does not respond to ping, access the server locally by way of RDP, IMM , RSA ,CIMC or UCS Manager KVM Console and troubleshoot from there. If the server does reply to ping, scan the port. Continue reading

Emulex 10G OneConnect NIC doesn’t work after ESXi upgrade

After upgrading to ESXi 5.5 or 6, Emulex 10G nic does not work. If you run esxcfg-nics -l, the NICs still have link. If you check the module, it is loaded but it won’t work. It won’t pass traffic.

For 5.5, we found a workaround in the community forum by way of disabling elxnet and enabling be2net driver followed by a reboot. Prior to upgrade, in 5.1, be2net was the driver but upon upgrading to 5.5 or 6, the driver changes to elxnet.
Continue reading

Cannot connect to CIMC

We cannot reach the CIMC of a C series Cisco server. It was working perfectly before. We couldn’t ping it. Soft reboot, physical power cycle did not help. There are no errors on the switch ports. The ports are the server and switch do not have link. A colleague was able to reach the CIMC by directly connecting his laptop to the CIMC NIC port. This proves the CIMC is working fine. He set the CIMC NIC to auto negotiate which fixed the issue. We are still at lost why it worked before as there has been no change in the switch.

Auto-negotiate is our standard configuration. This server being one of the first we deployed, we might have missed this step.

This is our standard CIMC network configuration.

scope cimc
scope network
set mode dedicated
set redundancy none
set auto-negotiate yes