Notes about interesting problems that I've come across and their solutions. Focused on Virtualization and the accompanying technologies that make it all possible!
2017 vExpert
Get link
Facebook
X
Pinterest
Email
Other Apps
I'm proud to announce that I've been selected as a 2017 vExpert! Thanks for the recognition and congrats to all of the other vExperts, particularly my coworkers Jeff and Dennis!
One of my customers is standardizing the configurations on their HP C7000 enclosures (they've been set up at various sites by various administrators with varying involvement from the architecture team). As such, we need to stand up some temporary resources so that we can take down the main enclosure for reconfiguration. That's fine, we can easily ship a smaller enclosure to each site for temporary compute resources. Some of the sites are using Standard vSwitches, so we need to be able to quickly copy the networking configuration over from their existing blades to these new, slightly different blades. As I see it, we had 2 good options: 1) Capture a Host Profile with the desired vSwitch configuration. Delete every other component of the Host Profile so that only the networking section is applied; design the new ESXi hosts so that the vSwitches'll work with the old vmnic-to-vswitch configurations. 2) Write a script to clone the vSwitch from ones ESXi host to another.
PowerShell's Sort-Object cmdlet is super useful, especially when preparing output for human consumption. A few people have found my blog while looking for more information about its use, specifically while looking for how to sort by multiple columns (well, properties, technically). I've never done so (much less written about it), so I hope those folks found answers elsewhere. But, it got me curious... and it turns out that it's really easy. The Technet article on Sort-Object has the answer directly spelled out: just use commas to create a list of properties to sort by (in order to precedence). Let's look at some examples! First, prepare a variable with some good sortable data: $myData = get-eventlog System -newest 25 And then we can get to sorting! Say you want to sort primarily by EntryType (Warning, Information, Error) and then by Source. Easy-peasy: $myData | sort EntryType,Source How about if you want it to be in descending order? Yeah, there&
A problem that most Virtualization Administrators need to deal with is Orphaned VMDK files (or Zombie VMDK files, as some people call them). These are Virtual Machine hard drive files that are just hanging out, taking up storage, but are attached to no VMs. How can this happen? Well, the most common way is when an administrator needs to delete a VMDK but isn't quite ready to commit... so, after pressing "remove", they select "remove from virtual machine" rather than "remove and delete files". The intent is always good: "I want to be able to restore this if it turns out to be necessary... so I'll just come back and delete it next week if nothing breaks!" But, of course, next week something else happens and the file doesn't get deleted. After a little while, it turns into "which files did I rename, again?" and nothing seems to happen. So, how do you deal with these orphaned files? Well, a few years ago I found a scrip
Comments
Post a Comment
Sorry guys, I've been getting a lot of spam recently, so I've had to turn on comment moderation. I'll do my best to moderate them swiftly after they're submitted,