Modifying CachingMode for SMBShare in Bulk


Sorry if this is too noob.

I would like to run the following command on all of the SMB shares on one of our file servers:

“Set-SMBShare -Name Testact1$ -CachingMode None -Confirm:$False”

I’ve manually ran this on a test share and confirmed it produced the desired result.

I don’t know how to for instance, run the command against every value that gets returned from the Get-SmbShare command. Please advise, thank you!

submitted by /u/vastarray1
[link] [comments]

Leave a Reply