Hello gurus
Is it possible to check the status and report on the progress of a new-pssession when connecting to a very high number of machines ? At times I have a script that runs perfectly except there is a lag whilst it runs the initial opening of the sesessions due to the amount of machines being connected to. Im looking for something as basic as being able to say connecting to computer named xxxx or computer number x of x
I’m not aware of any mechanism for doing this. How many machines are you connecting to?
If its a very high number are you overriding the throttle limit.
About the only way I can see to do something like this would be to create multiple sessions and use write-progress to report on the creation of each session.
I haven’t adjusted any of the default throttle limit settings thus far. In general I was trying to limit it to around 100 or so computers at a time, but I delegated a task to a team member who didnt cap the number with a more refined ad filter so it was around 400 in this instance. The script did run successfully, but the team member mentioned he was unsure if something went wrong as it did appear to stop for quite a while as the sessions were opening. Given it could happen again I was looking for a basic way to provide feedback during the sessions opening
I would expect New-PSsession to balk at 400 computers - it will take a while to set up sessions to all of those machines. As stated earlier the only way I can think of to track the progress is to batch the computers into a number of sessions and use write-progress. Remember that you can send a command to multiple sessions at once so you wouldn’t be impacted on the actual task