Monday, September 26, 2011

Required valid host name when logging FTP

Last week we had an issue with the users who were actually trying to get to our newly built FTP sites which were currently migrated from iis6 to iis7

user were getting they need to use the valid hostname inorder to login

Later found from the team that there is special way to login these

When you are using FTP virtual hosts you need to specify the host name as part of the login; for example:

c:\>ftp sitename.com|username

this should work.

List the PID tied to website in IIS

Today there was a website which was running with almost 99% of CPU , there were many websites running on the server. To list the PID along with the website . We got to use iisapp.vbs which is located on the system32 folder of the os . Executing the vb script from the command line tell all things about it

iisapp.vbs

ESX host commands

Shutdown -h now "will halt the system"
vmware-cmd -l "will list the virtual machines vmx path"
esxtop "will list the top process running on the esx host "

Thursday, September 22, 2011

msg.hbacommon.outofspace

I am getting an error msg on this server

msg.hbacommon.outofspace:There is no more space for virtual disk server_1-000008.vmdk. You may be able to continue this session by freeing disk space on the relevant partition, and clicking Retry

After investigating , the datastore got filled up coz of the snapshots of the virtual machine.
so we decided to delete it and After deleting the snap shot , the system doesn't boot up and was searching for the vmdk file which no longer exist.the failed.

After looking at the below found that the snapshots grow with its size on datastore with the changes that it has undergone


The server died and we got to point the vmx file to the old base disk .


Later found that from forums that

1.we can power down the VM and so that we will get get free space equal to the amount of RAM allocated to the VM. You can them do a storage vmotion to another Datastore with large enough space.

2. After powered down the VM, do a manual snapshot, then chose to "Delete All" snapshots. That cleared everything up for me.

3. Just clone VM to another storage using VMware Converter.


SNAPSHOT

What are snapshots:

Snapshots are the copy with latest data of the original base disk . We cant call rather a backup of the original base disk . When snapshots are taken , the original base disk no more receive any updates to the operating system disk and the snap shot disk creates a copy of the original base disk as a delta disk with vmname.00000x.vmdk. Deleting the snapshots here means the latest changes are commited to the original base disk.



Source : http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1007849

http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1015180


SNAPSHOT

A VMware ESX virtual machine disk consists of a descriptor (ends in .vmdk) and an extent (ends in -flat.vmdk). When a virtual machine has been snapshotted, the attached virtual hard disks (otherwise known as the base disks) no longer receive guest OS modifications or writes; they are stored in separate virtual machine delta disk files (ending in -delta.vmdk). There is one delta file per base disk that is snapshotted.

With exception to thin-provisioned virtual machine disks, virtual machine disks typically have a reserved or set space requirement on a datastore. Snapshots, however, require additional space and consideration. They increase in size as further modifications or writes are stored.

For example:

  1. If 10GB of changes were completed on one snapshotted virtual machine, its delta disk file size will increase proportionally by 10GB.
  2. Creating another snapshot causes the existing snapshot delta disk to retain its current size, however the next delta disk will begin to store all forthcoming modifications and writes. The base disk is still left unmodified since inception of the first snapshot.
  3. If another 15GB of changes were performed by the guest operating system, a total of 25GB of snapshot delta has now been recorded over the respective virtual machine's two snapshot delta disk files.
  4. For versions prior to VMware ESX 4.0 Update-2, the task of consolidating all snapshots (Remove All Snapshots task) causes unique changes stored only in the second snapshot delta disk to be copied upwards through the snapshot chain and into the first snapshot, or its "parent."
  5. This effect is recursive for each preceding parent file. As a result, the first snapshot delta disk file will grow by up to 15GB, accommodating all new blocks. Any common changes stored in both snapshot levels does not require additional space, however.
  6. The end result is a datastore requiring 40GB, or 25GB + 15GB.

Notes:

  • Additional space is required if the virtual machine is running during a Remove All Snapshots task. The amount of space consumed is dependent the amount of snapshot delta information the virtual machine has to temporarily store while its consolidation process completes.
  • If the same 10GB were changed in the second snapshot, and just 5GB of unique block changes occurred, then the first snapshot will increase by 5GB during the consolidation, not the complete 15GB.
  • Opting to save virtual machine memory contents with each Create Snapshot task requires additional space from the VMFS datastore. The amount of space required is equivalent to the amount of memory assigned to the virtual machine. This requirement can apply multiple times over, if multiple snapshots including virtual machine memory contents are created.

If a datastore fills up due to delta files accumulating too much space, or the datastore runs out of space during a snapshot consolidation effort, the symptoms outlined previously will occur. Migration or removal of stored data and snapshot consolidation will be required to resolve the issue.

Creating / removing the snapshot from the esx or esxi host

On an ESXi host, to commit all snapshots using the command line:

  1. Log in to the ESXi host as root via the console or an SSH session. For more information about SSH, see see Tech Support Mode for Emergency Support (1003677) or Using Tech Support Mode in ESXi 4.1 (1017910).

    Note: The following commands can also be executed remotely using the vSphere Command Line for both ESX and ESXi hosts. For more information, see vSphere Command Line Interface documentation.
  2. Run this command to get a list of virtual machines and the VMID for each virtual machine:
    vim-cmd vmsvc/getallvms

    Output similar to the following is displayed:

    Vmid Name File Guest OS Version Annotation
    1 vm1 [datastore1] vm1/vm1.vmx windows7Server64Guest vmx-08
    3 testvm [iscsi1] testvm/testvm.vmx winNetDatacenterGuest vmx-08

    Make a note of the VMID for the specific virtual machine.
  3. To verify if the snapshot exists, run this command and check the Snapshot Name, Snapshot Created On, and Snapshot State:

    vim-cmd vmsvc/snapshot.get [VMID]

    You see an output similar to:

    Get Snapshot:
    |-ROOT
    --Snapshot Name : Test
    --Snapshot Desciption :
    --Snapshot Created On : 7/27/2011 13:49:55
    --Snapshot State : powered on
  4. Run this command to create a new snapshot:
    vim-cmd vmsvc/snapshot.create [VmId] [snapshotName] [snapshotDescription] [includeMemory] [quiesced]

    For example, to create a snapshot on VM testvm:
    vim-cmd vmsvc/snapshot.create 3 snapshot1 snapshot 0 0

    Note: You can use any name you like. The name appears in the snapshot manager.
  5. Run this command to remove all snapshots:
    vim-cmd vmsvc/snapshot.removeall [VMID]

On an ESX host, to commit all snapshots by using the command line:

1. Log in to the ESX host as root via the console or an SSH session. For more information about SSH, see Unable to connect to an ESX host using Secure Shell (SSH) (1003807).

Note: The following commands can also be executed remotely using the vSphere Command Line for both ESX and ESXi hosts. For more information, see vSphere Command Line Interface documentation.

2. Type vmware-cmd -l and press Enter.

The output appears similar to:

/vmfs/volumes/UUID/VMNAME/VMNAME.vmx

3. Type vmware-cmd /vmfs/volumes/UUID/VMNAME/VMNAME.vmx hassnapshot and press Enter to confirm that there is a snapshot. If the output displays a value of 1, a snapshot is present. If the output displays a value of 0, there is no snapshot present.

4. Type vmware-cmd /vmfs/volumes/UUID/VMNAME/VMNAME.vmx createsnapshot and press Enter to create a new snapshot.

For example, the command
vmware-cmd /vmfs/volumes/UUID/VMNAME/VMNAME.vmx createsnapshot "test" "" 0 0 makes a snapshot without memory, quiescing, or a description called test .

Note: You can use any name you like. The name appears in the snapshot manager. For more information about the syntax of the vmware-cmd command, see vSphere Command Line Interface documentation.

5. Type vmware-cmd /vmfs/volumes/UUID/VMNAME/VMNAME.vmx removesnapshots and press Enter to remove the snapshot.





The disk chain in a snap shot process.

Generally, when you create a snapshot for the first time, the first child disk is created from the parent disk. Successive snapshots generate new child disks from the last child disk on the chain. The relationship can change if you have multiple branches in the snapshot chain.

This diagram is an example of a snapshot chain. Each square represents a block of data or a grain as described above:






Wednesday, September 21, 2011

unable to edit the template or migrate them

This error happend to me a day back. when moving the virtual templates to other host of a cluster.

Call "PropertyCollector.RetrieveContents" for object "propertyCollector" on vCenter Server "" failed


These setting keeps failing when trying to edit or convert these Virtual templates. After searching it in VMware knowledge base it seems to be an issue Virtual center which they will fix in future release.

Resolution

Go to the Virtual center console and select the ESX / ESXi host and select the VM or the Template.

  1. Power off the virtual machine and note the ESX/ESXi host on which the virtual machine resides.
  2. Right-click the virtual machine and click Remove from Inventory.

    Note: If the VM is removed from inventory using a vSphere client connected directly to the ESX host, it may still appear in the inventory view within vCenter Server as an orphaned VM. If this is the case, remove this orphaned VM from the vCenter Server inventory .
  3. Browse the datastore and locate the virtual machine.
  4. Right-click the .vmx file and click Add to Inventory.
  5. If you are unable to add the virtual machine, close the vSphere Client from vCenter Server.
  6. Log in directly to the ESX/ESXi host on which the virtual machine resides using the vSphere Client. To do this, you must know the root password.
  7. Browse the datastore and locate the virtual machine.
  8. Right-click the .vmx file and click Add to Inventory.
  9. Log in to vCenter Server using the vSphere Client.

Note: You can also use this procedure for a template virtual machine. To do this, convert the template into a virtual machine, remove the virtual machine from inventory, re-register the virtual machine, and then convert it back to a template.





source : http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1025367

Tuesday, September 20, 2011

Architectures Compared - ESX and ESXI

VMware ESX [~ 2 GB] VMware ESXi [< 150 MB]


  • VMware agents run in Console OS
  • Nearly all other management functionality provided by agents running in the Console OS
  • Users must log into Console OS in order to run commands for configuration and diagnostics
VMware ESXi [< 150 MB]



  • VMware agents ported to run directly on VMkernel
  • Authorized 3rd party modules can also run in Vmkernel. These provide specific functionality
    • Hardware monitoring
    • Hardware drivers
  • VMware components and third party components can be updated independently
  • The “dual-image” approach lets you revert to prior image if desired
  • Other capabilities necessary for integration into an enterprise datacenter are provided natively
  • No other arbitrary code is allowed on the system


source : http://www.vmware.com/products/vsphere/esxi-and-esx/compare.html#understand