Hi everyone.
I'm using a lot of automated RVTools scripts to obtain a lot of information about our virtual environments.
Problem is, I got into the company long after many mistakes were when people didn't thing everything through. For that reason,
Many servers are in wrong folders, and many folders are misnamed and etc.
To get some of the information I need, I have to be able to identify the client. I added a global custom attribute called "Client"
Is there a way to bulk edit this folder according to the folder?
I have PowerCli enabled and installed but I don't know it well enough to construct such a script
What I got so far is this:
# Add the vmware snapin for powershellAdd-PSSnapin VMware.VimAutomation.Core# Your vcenter server and credentials$vcenter = <<>><<>>$username = <<>><<>>$password = <<>><<>># Establish Connectionconnect-viserver -server $vcenter -user $username -password $password# Folder in which the Machines that are to be renamed$Foldername = <<>><<>># get a list of servers from the sourceLocation$vmservers = Get-VM -Location $sourceLocation# Name of the client that has to be added$clientname = <<>><<>>
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
Thanks, I'll check that in a few minutes and will update you
David Sankovsky
ASKER
That solved it, thanks a lot.
Experts Exchange has (a) saved my job multiple times, (b) saved me hours, days, and even weeks of work, and often (c) makes me look like a superhero! This place is MAGIC!