WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud Foundation
  • VKS
  • Homelab
    • Hardware Options
    • Hardware Reviews
    • Lab Deployment Scripts
    • Nested Virtualization
    • Homelab Podcasts
  • VMware Nostalgia
  • Apple

Ghetto Reflections 2011

12.24.2011 by William Lam // 14 Comments

I can not believe it is that time of the year again! 2011 was a great year for myself and looking back, a lot has changed both in my professional and personal life. As 2011 starts to wind down, here are some interesting stats for this past year.

Total number of posts on virtuallyGhetto in 2011: 103

Total ghettoVCB pageviews: 600,000k (almost 300k more than 2010)

Here were the top 10 blog posts of 2011 by page views:

  1. Automating ESXi 4.1 Kickstart Tips & Tricks
  2. Getting started with vMA 
  3. New vSphere Health Check 5.0 & ghettoVCB Script
  4. How to Enable Support for Nested 64bit & Hyper-V VMs in vSphere 5
  5. How to Run Windows 8 on vSphere 5
  6. Automating ESXi 5 Kickstart Tips & Tricks 
  7. How to Enable Nested vFT (virtual Fault Tolerance) in vSphere 5
  8. When Can I Run Apple OSX on vSphere 5?
  9. How to inject custom drivers into an ESXi 4.1 image using vibddi?
  10. vSphere Tagging Feature Not So Invisible

Here were the top 10 ghetto scripts of 2011 by page views: 

  1. ghettoVCB.sh 
  2. ghettoVCBg2.pl  
  3. vmwarevSphereHealthCheck.pl 
  4. ghettoVCB-restore.sh
  5. vmwarevSphereSecurityHardeningReportCheck.pl
  6. ghettoUPSHostShutdown.pl 
  7. generateHostConfigurationWorksheet.pl
  8. ghetto-esxi-linked-clones.sh
  9. datastoreClusterManagement.pl
  10. guestOpsManagement.pl

Lastly, I want to take this time to thank all our readers for all of your support! If you already gotten this far into the post, you are in for a surprise. I will be giving away a free copy of Duncan Epping & Frank Denneman's VMware vSphere 5 Clustering Technical Deepdive colored copy. I received a signed copy from the gurus themselves for an article I wrote awhile back and ended up with two copies. To qualify, you just need to leave a comment with a valid email address. I will randomly select a winner on Dec 30th, 2011.

Happy Holidays and have a Happy New Year! See you in 2012.

UPDATE: Please take a look at this blog post for the winner The Winner Is ...

Categories // Uncategorized Tags // ghetto

Retrieving Information from a Distributed vSwitch

12.22.2011 by William Lam // 30 Comments

There was a question on the VMTN community forums about retrieving the security policies: promiscuous, forged transmits and MAC Address change from a distributed vSwitch and distributed portgroup and I realized my getdvSwitchInfo.pl script that I wrote awhile back only included basic information about the dvSwitch.

I spent some time updating my vSphere SDK for Perl script to include additional information such as the high level summary, configuration of the dvSwitch, network resource pools, dvportgroups, hosts attached to dvSwitch and virtual machines attached to the dvSwitch. The script also includes information about many of the new features in vSphere 5.0 networking such as netflow, port mirror, LLDP, NIOC to just name a few. You can take a look at the What's New in vSphere 5 Networking whitepaper for more details.

The script allows for the following type of "list" operations: summary, config, networkpool, portgroup, host and vm. In addition, you can display all information by specifying the "all" operation and you can specify a specific dvSwitch by using the --dvswitch flag and providing the name of a dvSwitch.

Here is an example output for the list "summary" operation for all dvSwitches:

Here is an example output for the list "config" operation on a specific dvSwitch:

Here is an example output for the list "networkpool" operation on a specific dvSwitch:

Here is an example output for the list "portgroup" operation on a specific dvSwitch:

Here is an example output for the list "host" operation on a specific dvSwitch:

Here is an example output for the list "vm" operation on a specific dvSwitch:

Hopefully this script will be helpful if you need to quickly get information about your dvSwitches.

Categories // Uncategorized Tags // distributed virtual switch, dvs, vsphere sdk for perl

Identifying Idle vCenter Sessions

12.20.2011 by William Lam // 4 Comments

I recently received a question on how to identify idle vCenter sessions that may stem from a non-active vSphere Client or vSphere API connection. Properly managing sessions to your vCenter Server is as important as knowing who is logging in. If you exhaust the maximum number of connections, you can easily deny login access to other users and/or services that are needed to connect to vCenter Server which can lead to very bad things. In the worse case, you can even prevent administrators from logging into a new session to help terminate any stale/idle connections.

The vSphere API provides a sessionManagement manager to help you manage all sessions, including checking whether a session is still active and terminating a session. I wrote a quick vSphere SDK for Perl script called sessionManagement.pl which allows you to list all sessions for a given vCenter and terminating a a specific session. Every session has a unique sessionKey that the vCenter Server uses to track and it provides information such username, login time and last active which can be used to create an unattended script to automatically terminate sessions that have gone beyond a certain threshold.

Here is an example script output of performing the "list" operation:

Note: There maybe vCenter Plugins/Extensions that creates sessions such as CapacityIQ, those will be denoted by "vCenter Ext Session" field. These should not be terminated as it can negatively impact 3rd party applications.

Here is an example script output of terminating a specific session using the "disconnect" operation which you will need to specify sessionkey provided in the previous command:

For those of you that are interested in creating your own script to terminate idle sessions, you can use the DateTime Perl module to help with calculating the amount of idle time and comparing that to a pre-defined timeout value.

Categories // Uncategorized Tags // idle, session, vsphere sdk for perl

  • « Previous Page
  • 1
  • …
  • 504
  • 505
  • 506
  • 507
  • 508
  • …
  • 565
  • Next Page »

Search

Thank Author

Author

William is Distinguished Platform Engineering Architect in the VMware Cloud Foundation (VCF) Division at Broadcom. His primary focus is helping customers and partners build, run and operate a modern Private Cloud using the VMware Cloud Foundation (VCF) platform.

Connect

  • Bluesky
  • Email
  • GitHub
  • LinkedIn
  • Mastodon
  • Reddit
  • RSS
  • Twitter
  • Vimeo

Recent

  • PowerCLI remediation script for running NSX Edge on AMD Ryzen for VCF 9.0 06/20/2025
  • Failed to locate kickstart on Nested ESXi VM CD-ROM in VCF 9.0 06/20/2025
  • NVMe Tiering with Nested Virtualization in VCF 9.0 06/20/2025
  • VCF 9.0 Installer workaround for ESXi hosts with different vendor 06/19/2025
  • NVMe Tiering with AMD Ryzen CPU workaround for VCF 9.0 06/19/2025

Advertisment

Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy

Copyright WilliamLam.com © 2025