Can’t delete a sharepoint site that used to have a group attached to it, but the group has long since been deleted?
Apparently, the sharepoint admin center is unable to handle this scenario, and just throws a “could not be deleted” error. Using fiddler the only extra info I could get was an underlying 500 Internal Server Error Microsoft.Office.Server.Directory.DirectoryObjectNotFoundException was thrown
Obviously that directory object not found means the office 365 group. Fora seem to point to MS support for manual fixes, but since Microsoft Support has rarely been a pleasant experience for me I went over the PS module for SPO and found a MUCH faster fix, hope it also works for you!
start PowerShell 5 (don’t use a newer version until the module supports it)
install-module Microsoft.Online.SharePoint.PowerShell -force -scope currentuser (unless you already have the module installed)
A customer wanted to know how many hours on average their devices were being used, without modifying their configuration.
This to help target replacements, upgrades, #desks per location, #shared devices per location etc.
At first I figured it’d be a simple task, just getting the right event ID’s from the local eventlog, but no, that required additional auditing to be enabled and how would the data flow to PowerBI?
The next attempted data source was much better; Defender Advanced Hunting. Especially the DeviceLogonEvents table, which contains cached and interactive logons to all monitored devices.
Using logon events, we can get an idea of a device’s relative use in the fleet. It won’t be exact as measuring the time between pure lock/unlock/signin/signout events.
This was fine for the customer’s purpose and checking their data the number of daily logon events (7-9) was actually much higher than the expected 2-3 per device per day (at least on Windows 11, our target OS).
Getting that data into PowerBI turned out to be even easier 🙂