-
Hallo I have trouble writing a Script that gets a running Service called "Belvis Service Controller" It has to Stop de running services called "Belvis Service Controller" on more than one Server. The servers are listed in the file c:\servers.txt I want to stop the Service first than...
-
Hello everyone, I'm trying to retrieve some information from Event ID 1074. I need the following information Domain\User and Comment. I alread have the servername and uptime output to html. I have added the an example of the html output and a sample of the script, hope you can help. Example of event...
Posted to
PowerShell for Windows
(Forum)
by
aochoar
on
10-31-2011
Filed under: powershell, powershell Windows-programming, wmi, array, powerrshell, powerershell, powerershll, advancedlogging, powershell append to content
-
Hi, I am trying to establish an implicit session with a remote host from my machine from a C# code. I am using runspace API for that. the code snippet is provided below this code is expected to enter into an implicit session with machine TS-TEST-09 and invoke the script helper.ps1 existing on that machine...
-
Hi, I am trying to establish an implicit session with a remote host from my machine from a C# code. I am using runspace API for that. the code snippet is provided below Runspace runspace = RunspaceFactory.CreateRunspace(); runspace.Open(); //constructing the vmname parameter here vmname = useralias ...
Posted to
Ask Don Jones
(Forum)
by
manishjha
on
01-18-2012
Filed under: Test-Connection, Args, Parameter, scripts, PS Remoting, new-pssession, WMI, Remote PowerShell
-
Hi Don, Thanks a lot for the prompt response! Yes, I stand corrected on this usage of 'implicit' remoting. Thanks for pointing that out. $s is treated as a PSSession object in the script as 'enter-PSSession' expects this object and not the string as the parameter. As for your last scenario...
Posted to
Ask Don Jones
(Forum)
by
manishjha
on
01-18-2012
Filed under: Parameter, scripts, Passing arguments from batch file to powershell, PS Remoting, new-pssession, WMI, Remote PowerShell
-
Hello! I've been trying to develop a monitoring script for iSCSI connections in a Hyper-V environment. We are using MSiSCSI Initiator to map LUNs. So far I'm able to retrieve info about connected sessions using the class MSiSCSI_InitiatorSessionInfo. The problem with this is it only shows active...
-
HI everyone, I am new to Powershell. I am trying to call the powershell command of server machine through other machine which is not a part of any domain. So is it possible ? If yes, can anybody give some code snippet of how to call powershell through outside domain machine. Pleaseeeeeeeeeee it's...
-
Hi Expert, I am Sachin, new to powershell and Active directory. I am creating a web based application(asp.net, C#) which should create a new user/group in Active Directory. I want to run that application on my laptop which is not part of any domain. But, the server machine whose active directory i want...
-
I got the fallowing code but it doesnt do anything and I don't get any errors. Appreciate any help. $Srv = "."$print = ([WMICLASS]" \\$Srv\ROOT\cimv2:Win32_Printer").createInstance () $print.drivername = $drv32 $print.PortName = $PortName $print.Shared = $Shared $print.Sharename...
-
I am trying to find a way to use powershell to query a sql server and provide back the instance names with the port numbers used, then ideally get the port numbers and add them to specific rules I create for the Windows firewall. Currently I use the netsh commands for the firewall config and go to the...