Reader small image

You're reading from  Mastering PowerCLI

Product typeBook
Published inOct 2015
Reading LevelIntermediate
PublisherPackt
ISBN-139781785286858
Edition1st Edition
Languages
Right arrow
Author (1)
Sajal Debnath
Sajal Debnath
author image
Sajal Debnath

Sajal Debnath is a highly certified Cloud computing technocrat with more than 12 years of experience in virtualized data center design, Cloud computing, and BC/DR solutions. He is an EMCISA, VCAP-DCD/DCA, VCAP-CID/CIA, RHCE 4/5/6, RHCVA, Openstack, and ITIL certified person. He is presently associated with VMware Software India Pvt. Ltd. as a senior system engineer. Previously, he worked with France Telecom, Hewlett Packard, and many more in multiple roles. He is involved in prestigious Indian government projects, such as National Cloud, Digital Locker, and so on.
Read more about Sajal Debnath

Right arrow

Using the Get-View cmdlet to return .NET View objects


When we use any cmdlet, it does a lot of background work and provides us nice, formatted output. This has the positive effect of making our life easier and we can be blissfully ignorant of the underlying complexities. But, due to the same reason, it also runs a bit slower and hides a lot of information. If we want to get more information about objects, then we need to use the Get-View cmdlet. For example, let's look at the output of the following two cmdlets:

PS C:\> Get-VMHost -Name ESXi1.lab.com
PS C:\> Get-VMHost -Name ESXi1.lab.com | Get-View

The results of the preceding commands are shown in the following screenshot:

As you can see from the preceding screenshot, Get-View provides much more detailed information than the simple Get-VMHost cmdlet. We can further pinpoint the data that we are looking for by using the –ViewType and –Filter parameters. The ViewType parameter lets us select the data for a particular type of object...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Mastering PowerCLI
Published in: Oct 2015Publisher: PacktISBN-13: 9781785286858

Author (1)

author image
Sajal Debnath

Sajal Debnath is a highly certified Cloud computing technocrat with more than 12 years of experience in virtualized data center design, Cloud computing, and BC/DR solutions. He is an EMCISA, VCAP-DCD/DCA, VCAP-CID/CIA, RHCE 4/5/6, RHCVA, Openstack, and ITIL certified person. He is presently associated with VMware Software India Pvt. Ltd. as a senior system engineer. Previously, he worked with France Telecom, Hewlett Packard, and many more in multiple roles. He is involved in prestigious Indian government projects, such as National Cloud, Digital Locker, and so on.
Read more about Sajal Debnath