In order to view the full column output in PowerCLI we need to format table appropriately e.x.
PS C:\> Get-VM | Format-Table -AutoSize -Wrap
Formats the output as a table.
Adjusts the column size and number of columns based on the width of the data. By default, the column size and number are determined by the view.
Displays text that exceeds the column width on the next line. By default, text that exceeds the column width is truncated.
After adding a separate disk run to verify if the space was added:
- fdisk -l
- create a new partition fdisk /dev/sdb
- p – to print current partition table
- n – to create a new partition
- p – for primary
- 1 – depending on the output of the partition table output
- press return two times to accept the defaults (first and last sector)
- t – to change the system’s partition ID
- 8e – to change to Linux LVM
- w – to write the changes
- restart VM
- fdisk -l – to verify that partition was successfully created
- convert a partition to physical volume
$ pvcreate /dev/sdb1
Physical volume “/dev/sdb1” successfully created
- Extend current volume group
vgextend rhel /dev/sdb1
Volume group “rhel” successfully extended
- Run vgdisplay to verify if free space was added
vgdisplay rhel | grep “Free”
Free PE / Size 4095 / 16.00 GiB
- extend logical volume with free space
lvextend -l +100%FREE /dev/rhel/root
Extending logical volume root to 66.00 GiB
Logical volume root successfully resized
- Expand ext3 file system online inside of Logical Volume
xfs_growfs /dev/rhel/root – Red Hat 7
To setup proxy manually in VCSA 5.5 login as root and look into the following file:
HTTP_PROXY=”http://<IP address or FQDN>:<port_number>”
HTTPS_PROXY=”http://<IP address or FQDN>:<port_number>”
FTP_PROXY=”http://<IP address or FQDN>:<port_number>”
If you need to authenticate via proxy
Create a file in your home directory,
/root/.curlrc with permissions 644
and contain the following:
# Proxy credentials
proxy-user = “<username>:<password>”
source the file to apply the changes
Even when launching VMware PowerShell CLI with administrator privileges you are still unable to start it.
Moreover, you are unable to change execution policy for the machine.
Try the following it only changes policy for current user.
Set-ExecutionPolicy Unrestricted -Scope CurrentUser
Windows 8, Windows 8.1, Windows 10 get suspended or go to standby mode when are inactive for more than 5 mins. The issue is related to mobile devices which OSes were designed for and battery savings which disable some of the services such as RDP and users cannot login to machines.
In order to address the issue in VMware, a machine needs to be powered down and .vmx file needs to be modified. There are two ways of doing it:
- Directly via ssh and using text editor to append the following to <vm_name>.vmx file: suspend.disabled=”TRUE” save changes and exit file.
- Using vSphere Client by right clicking the machine and edit settings. Navigating to Options -> Advanced -> General and clicking ‘Configuration Parameters’ button. \
- Select ‘Add Row’ button.
- Name: suspend.disabled, Value: True
- Save settings and power the mahcine back on.
To updated VMware tools on Windows without reboot:
- Right click on a virtual machine
- Select ‘Guest’ -> Install/Upgrade VMware Tools
- In the pop-up dialog select ‘Automatic Tools Upgrade’ in ‘Advanced Options’ enter the following:
/S /v"/qn REBOOT=R"
- Installation can take up to 10 mins depending on your data storage performance
ESXi has its own firewall implementation which may block some of incoming/outcoming traffic e.x. netcat
In order to disable the firewall:
- Ssh to the machine
- Execute the following command: esxcli network firewall set –enabled 0
While cloning one of my templates received the following error: “
Incompatible device backing specified for device '12'.”
VMWare tools were updated to the newest version and machine was powering on no problem.
To resolve the issue make sure that CD-ROM properties are set correctly.
“Edit the settings” of the virtual machine:
1) Remove the CD-ROM assigned as the device is probably pointing to some non-existing location,
2) If the device is set to Host Device change it to Client Device,
3) You may also want to try to point the device to some local ISO file if you find it easier.
You can set the length of Tasks & Events list between 10 and 1000 records to be displayed in your vSphere Client.
1. Open vSphere Client application and connect to your server.
2. Navigate to Edit on the menu bar.
3. Select Client Settings
4. A new dialog will pop-up, select List tab.
5. Enter a value between 10 and 1000.
To connect to a server:
To get a list of of the last 10 errror events on the virutal machines
Get-VIEvent -Entity VM -Type error -MaxSamples 10