Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
Difference between individual commands and putting them together in a script

2012-10-10
06:43 AM
2,862 Views
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi all,
When I run the below set of command from the CLI they work as expected. But when I run them in the script I do not get any information. Looking for comments on possible causes....
==On CLI==
PS C:\Users\mrinal\Documents\powershell> $vserver_listing = Get-NcVserver -Template
PS C:\Users\mrinal\Documents\powershell> $vserver_listing.VserverType = "data"
PS C:\Users\mrinal\Documents\powershell> $vserver_list = Get-NcVserver -Query $vserver_listing
PS C:\Users\mrinal\Documents\powershell> $vserver_list
Vserver State VserverType Comment
------- ----- ----------- -------
madden-vs1 running data
madden-vs2 running data
mrinal-vs02 running data
rfl_test running data
upper running data
UPPER running data
vs01 running data
vs1 running data
vs-esrf running data
==Via ps1 script==
PS C:\Users\mrinal\Documents\powershell> .\vserver_dr_collect.ps1
Cluster Name / IP : 10.10.10.10
Cluster Admin UserName : admin
Cluster Admin Password : *********
Name Credential HostUser
---- ---------- --------
10.10.10.10 System.Management.Automation.PSCrede... DOMAIN\dummy
Select Vserver : vs01 <<<<<<< The lines above this are blank on the console as well.
===================================================================
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Can you attach the script (or a subset that reproduces the problem)?
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
