Find Empty Folders with PowerShell

Sdílet
Vložit
  • čas přidán 8. 11. 2023
  • In this video, we will learn how to automate the process of finding empty folders and file shares on Windows servers using PowerShell. Administrators often face the challenge of locating these empty folders or file shares, but with PowerShell, it becomes much easier. We will walk through the step-by-step process, including opening PowerShell as admin, ensuring the necessary permissions, running the PowerShell script, and reviewing the results. Join us to streamline your file server cleanup and save time!
    PowerShell Cmdlets
    *********************
    $share = Get-ChildItem '\DESKTOP\d$' -Recurse | Where { $_.PsIsContainer -eq $true }
    $share | Where { $_.GetFiles().Count -eq 0 -and $_.GetDirectories().Count -eq 0 } | FT Name, FullName, Attribute
  • Věda a technologie

Komentáře • 1

  • @nobody-P
    @nobody-P Před 8 měsíci

    This is really cool❤❤❤