Forum Discussion

trevorsi's avatar
trevorsi
Copper Contributor
Jun 04, 2019

Cannot access Sharepoint site

Our organization has Office 365 subscriptions, including Sharepoint Online.  We have lost all access to our sharepoint and onedrive sites.  

When I run the following command

get-sposite -Identity https://<<mytenant>>.sharepoint.com | select LockState

I get this result

 

LockState
---------
NoAccess

When I try to unlock it using this command

set-sposite -Identity https://<<mytenant>>.sharepoint.com -lockstate "Unlock"

I get this

set-sposite : Lockstate is not a settable property on site: https://<<mytenant>>.sharepoint.com/.
At line:1 char:1
+ set-sposite -Identity https://<<mytenant>>.sharepoint.com -lockstate "Unl ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Set-SPOSite], ServerException
+ FullyQualifiedErrorId : Microsoft.SharePoint.Client.ServerException,Microsoft.Online.SharePoint.PowerShell.SetSite

 

Any help you can give me would be greatly appreciated!

 




 

2 Replies

  • Dean_Gross's avatar
    Dean_Gross
    Silver Contributor
    what kind of error are you getting? is it all users in all locations? can you access any other O365 applications?
    • trevorsi's avatar
      trevorsi
      Copper Contributor

      Dean_Gross   The problem is with all users in all locations.  When I go to our sharepoint (https://<<mytenant>>.sharepoint.com/_layouts/15/sharepoint.aspx) or onedrive website I get a "403 FORBIDDEN" message.

      If I go to a site page I get this message.

      Server Error in '/' Application.
      Runtime Error
      Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.

      Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off".


      <!-- Web.Config Configuration File -->

      <configuration>
      <system.web>
      <customErrors mode="Off"/>
      </system.web>
      </configuration>

      Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customErrors> configuration tag to point to a custom error page URL.


      <!-- Web.Config Configuration File -->

      <configuration>
      <system.web>
      <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
      </system.web>
      </configuration>