Quantcast
Channel: VMware Communities : Discussion List - Automation Tools
Browsing all 9071 articles
Browse latest View live

Image may be NSFW.
Clik here to view.

how to get the first level of a tree when running get-folder

Dear All, Here is my Vcenter folder tree When I run Get-Folder -Type Datacenter, I am getting the following result :  Is there anyway to get the first level (Asia and Europe) only? Thks in advance JJC

View Article


Hardware Version Upgrade

I am looking for a script to schedule hardware version upgrades and will upgrade regardless if I reboot the VM from the vSphere console or the guest OS reboots on its own.  Any suggestions?

View Article


How to import offline bundle (zip format) into patch repository under vCenter...

Hi all Deployed vCenter Server v6.5 with Update manager.  I have another windows machine where VMware PowerCli v5.8  is deployed ,Now i want to import some 3rd party offline bundle which is in zip...

View Article

Image may be NSFW.
Clik here to view.

Script for attaching multiple existing disk to VM with specific scsi bus...

Hello,I was trying to attach multiple vmdk with specific scsi bus number and device number using import-csv method and onyx tools generated code, Looks like it keep failed and  don't able add scsi bus...

View Article

Modifying PowerCLI script to list VM disk usage status that is lessthan 15%...

Hi All, I wonder if anyone here can assist me in modifying the script below to also send which VMs is currently only using less than 15% of the allocated VM Disk space size?So the Output will be:...

View Article


Change Agent VM Settings using powercli

For a deployment using NSX we are using the Agent VM settings on our ESXi host. I tried to find how to set these values via powercli, but I can't find them anywhere. Could someone show me where I can...

View Article

need help script not working

Hello, i found this script on the web and want to use it in my environemnt which is vSphere 6.0 without DRS.Scripting a DRS Replacement Using PowerCLI | Scott Warren Unfortunatly it is not working for...

View Article

Datastore Orphaned Files

This one is for Luc, you made me a script to locate orphaned files and report them to me, but is there a way to ignore the following types: .hlog .vmx~ -ctr.vmdk .vmx.lck   function...

View Article


Combining VM inventory data

I have a report the needs to import VM inventory data from multiple csv's then combine it into a single csv.  All of the csv's are in one folder and nothing else is in that folder If you look at the...

View Article


Limiting the number of Clones while provisioning 20 VMs from CSV file

Hi All, $MaxClones = 3$CSV = "C:\users\$env:username\desktop\file1.csv"$nvm = Import-CSV $CSV -Useculture$idTab = @()$nvm | %{$idTab += New-VM -Name $_.Name`        -vm $(Get-Cluster $_.cluster |...

View Article

Adding multiple Annotations to a VM

Hi I have several Annotations I want to add to a VM using Powercli, and a csv In the csv I have CustomeAttribute,ValueCustomisation,Win10IP,192.168.0.1 In the script $attributes = Import-Csv...

View Article

Getting physical HDD information (size, number of disks) installed on ESXi...

Hi, I need to retrieve on a ESXi 6.0 host the HDD information (size in GB , numbers of disks installed...). How can I achieve that with POWERCLI  Thks JJC

View Article

Bug in Get-VMView - equals filter is using match comparison

So I was working on a PowerCLI script to pull out the SCSI information for vmdk drives, so I can do the matching into the Windows OS to drive letters.  Upon doing so, I came across a very odd bug that...

View Article


bulk add vmkernel to esxi

Hello I need to bulk add vmkernel ports to esxi csv file esxi mgmt ip /esxi-vmkernel-name/vmkernelIP  can someone help Thanks

View Article

Image may be NSFW.
Clik here to view.

How to create a VMDirectPath IO (Paththrough) device by using PowerCLI

Hi all, I would like to create a VMDirectPath IO (Paththrough) device by using CLI.Could you please provide me the command to achieve this through PowerCLI? Thank youMaaTaa

View Article


Shutdown-VMGuest return code

I need to get a return code or something like to test the result of the Shutdown-VMGuest command.I made a test by writing:$shutdown_rc = Shutdown-VMGuest -VM $myvm -Confirm:$false # >...

View Article

PowerCLI returning incorrect data via SRM API

Hi, The following script is being used to provide a daily report on the state of SRM Protection Groups and, the VM's they protect. Connect-viserver xxxxxxxxxxx$srm = Connect-SrmServer #|out-null$srmApi...

View Article


Image may be NSFW.
Clik here to view.

New-TagCategory : 5/2/2017 2:44:44 PM New-TagCategory The underlying...

Has anyone seen errors related to creating tags in the new powercli 6.5.1 New-TagCategory : 5/2/2017 2:44:44 PM   New-TagCategory         The underlying connection was closed: An unexpected error...

View Article

Powercli - Losing all VM Tags after a few months

Hi, I'm using a script to automatically tag new VMs so they get backed up if the user which provisioned the VM forgot about it. It works for a few months and then, I lose all my VM tags. It's already...

View Article

SDRS VM settings always set to fullyautomated with New-VM cmdlet

Hi,  Recently I have tried to deploy VM based on Template using PowerCLI and realized that if DataStore Cluster is used, VM is placed there in an Fully automated SDRS mode and with enabled intra-VM...

View Article
Browsing all 9071 articles
Browse latest View live


Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>