Set the Lock State of a Site Collection

Scenario/Problem: You want to allow or prohibit access to the site collection.

Solution: Use the Set-SPSite cmdlet with the LockState parameter.

The Set-SPSite cmdlet has several parameter sets for configuring various settings on the site collection. Running Set-SPSite with the -? parameter displays each parameter set. The LockState parameter enables you to lock or unlock the site collection. The following are valid values for the LockState parameter:

Unlock

NoAdditions

ReadOnly

NoAccess

The Unlock state provides full availability to users (based on the normal permissions). NoAdditions enables you to lock the site collection so that no new content can be added. This does not lock down updates ...

Get PowerShell™ for SharePoint® 2013 How-To now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.