+ Post New Thread
Results 1 to 5 of 5
Wireless Networks Thread, batch searching every hard drive... in Technical; Hi, Im looking to do something interesting here and i'm wondering if any of you guys can help me. Basically ...
  1. #1
    chrisdv98's Avatar
    Join Date
    Feb 2009
    Thank Post
    Thanked 0 Times in 0 Posts
    Rep Power

    batch searching every hard drive...


    Im looking to do something interesting here and i'm wondering if any of you guys can help me.

    Basically i have a user on our network that placed about 8gb of .tmp files on her roaming desktop. She wondered why everywhere she went it took around 20 mins to login!

    Anyway she had been putting up with it for ages thinking it was normal. Eventually she came to me - i deleted the .tmp files from the documents and settings folder on the local machine and on the server - i then deleted the files from every other client she could remember logging on to as it was syncing the profile back to the server.

    I have tried and failed three times now to get rid of the local profile on all the machines she 'thinks' she has been on.

    What im looking for is a way to scour every c: of every client on the network and return a list of results where her profile is located under documents and settings.

    Any ideas guys?



  2. #2

    LosOjos's Avatar
    Join Date
    Dec 2009
    West Midlands
    Thank Post
    Thanked 1,294 Times in 884 Posts
    Rep Power
    if you can search from the command line with something like this:

    dir "\\\C$\Documents and Settings"

    then try to get a list of connected PC's IP addresses and write a script to run through them and check for the users folder, returning IP addresses where that folder is found. You could do it easy enough in Excel with a little VBA (I think, never actually tried it though)

  3. #3
    leco's Avatar
    Join Date
    Nov 2006
    West Yorkshire
    Thank Post
    Thanked 125 Times in 119 Posts
    Rep Power
    Would it be possible (and perhaps quicker) to run delprof throughout the network?

  4. Thanks to leco from:

    ronanian (18th March 2010)

  5. #4
    waldronm2000's Avatar
    Join Date
    Dec 2009
    Thank Post
    Thanked 12 Times in 11 Posts
    Rep Power
    I think that rather than try to do it all from one PC, it'd be better to get each PC to check it's own hard drive.

    It shouldn't be to difficult to write either a VBS or CMD script that basically says "If C:\Documents and Settings\<username> exists, delete the folder and its contents"; only a couple of lines in either language.

    Then just use Group Policy to get all your desktops to run it at startup or shutdown. Leave the GPO on for a couple of weeks (or just a day as long as all desktops are restarted every day), then remove it.

  6. #5

    Join Date
    Nov 2009
    Thank Post
    Thanked 12 Times in 12 Posts
    Rep Power
    I use the following batch file on my pcs for weekly maintenance. You have to add it to the scheduled tasks on each pc if you have a windows 2k3 DC. If you have win2k8 you can add it to the scheduled tasks gpo.

    REM The next line clears out old temp folders
    FOR /F "tokens=1 delims= " %%a in ('dir /b "c:\documents and settings"') DO rmdir /s /q "c:\documents and settings\%%a\local settings\temp"
    FOR /F "tokens=1 delims= " %%a in ('dir /b "c:\documents and settings"') DO md "c:\documents and settings\%%a\local settings\Temp"
    FOR /F "tokens=1 delims= " %%a in ('dir /b "c:\documents and settings"') DO del /s /q "C:\Documents and Settings\%%a\Local Settings\Temporary Internet Files\*.*"
    del /s /q c:\windows\temp\*.*
    REM Main tools
    %SystemRoot%\System32\Defrag.exe %SystemDrive% 
    echo y|chkdsk c: /f /r
    echo y|gpupdate /force
    shutdown /r /f /t 0

  7. Thanks to Nixphoe from:

    ronanian (18th March 2010)

+ Post New Thread

Similar Threads

  1. [Wanted] Hard drive ...
    By mdking in forum Classified Adverts
    Replies: 4
    Last Post: 30th October 2009, 12:29 PM
  2. Batch file to map network drive
    By googlemad in forum Windows
    Replies: 4
    Last Post: 22nd October 2009, 03:07 PM
  3. Hard drive image of a netbook without CD/DVD drive
    By zx2012 in forum Netbooks, PDA and Phones
    Replies: 2
    Last Post: 30th August 2009, 03:27 PM
  4. Missing Hard Drive
    By Michael in forum Windows
    Replies: 5
    Last Post: 17th September 2008, 07:51 PM
  5. Hard Drive
    By Jackd in forum Hardware
    Replies: 3
    Last Post: 20th November 2007, 08:31 PM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts