Solved

Powershell very slow in recursing through directory listing

Posted on 2013-01-30
4
1,417 Views
Last Modified: 2013-02-01
When I execute a recursive directory listing in CMD shell it zips along speedily.

dir /s

However, when I do the same with Powershell the result is much slower

get-childitem -recurse

Is there a way to improve the speed of output?
0
Comment
Question by:johndarby
  • 2
4 Comments
 
LVL 42

Accepted Solution

by:
sedgwick earned 500 total points
ID: 38837365
you can use FileSystem.GetFiles which is faster and can be run via powershell:
How to speed up Powershell Get-Childitem over UNC
0
 
LVL 1

Author Closing Comment

by:johndarby
ID: 38837407
Thank you for the pointer! :)
0
 
LVL 39

Expert Comment

by:footech
ID: 38845254
Just to add, supposedly PS 3.0 is much faster in this regard.
0
 
LVL 1

Author Comment

by:johndarby
ID: 38845358
I sure look forward to that! :)
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Why would I want to create a function for tracking messages? I am glad you asked. As with most monotonous/routine tasks, human error tends to creep in after doing the same task over and over again. By creating a function, you load the function once…
"Migrate" an SMTP relay receive connector to a new server using info from an old server.
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now