New Virtualisation Website Launched!
Hi All, I have just launched my new website http://www.elasticsky.co.uk
Lots of info on the VCP, practice exam questions, video demos, and more to be added.
Please check it out!
Network Card information: ifconfigDisplay the network cards availible in ESX: esxcfg-nics -lDisplay the network card linked to service console: esxcfg-vswitch -lUnlink Vmnic from vswitch esxcfg-vswitch -U vmnic0 vSwitch0link a vmnic to vSwitch0 esxcfg-vswitch -L vmnic1 vSwitch0Change the Vlan ID of the console port in ESX: esxcfg-vswitch vSwitch0 -v 15 -p “Service Console” (where 15 is the Vlan ID)
I have been working with development teams for many years. One of the most common requests, especially with development and test servers is to automate the deleting of old log or temp file folders. Most of the time these files contain debug information, and do not need archiving, but tend to fill the drives to capacity if not maintained.
To Solve this issue, the following clean up powershell script is useful;
#powershell clean up script based on file write time
gci “e:\temp\*.*”|? {$_.lastwritetime -lt (get-date).adddays(-1)} |
remove-item
To run this script, set the powershell execution policy to RemoteSigned (run the command set-ExecutionPolicy RemoteSigned ) and save the powershell script in a .ps1 file.
To configure the script, change the directory path (e:\temp\*.* in this example) and the number of days required (-1).
To test the script add –whatif after the “remote-item” cmdlet. This will show the files that would be deleted and no data will be lost if errors exist.
Once tested, to schedule it create a batch file with the following (change the powershell file location).
powershell -command “& ‘c:\delete.ps1′ “
You can now schedule the script with the Windows task scheduler (point to the batchfile).
To confirm the Exchange 2007 server edition (ie standard or enterprise), run the following powershell one-liner from the Exchange Management shell
Get-ExchangeServer | fl name,edition,admindisplayversion
As the example output shows below, each exchange server in the organisation will be listed with name, edition, and build/patch level.


