It's not an unsolved problem.
https://en.m.wikipedia.org/wiki/Elinor_Ostrom
Elinor Ostrom received a Nobel Prize for researching into how societies have develop structures to manage commons sustainably. Unfortunately her conclusion was there is no default solution.
https://en.m.wikipedia.org/wiki/Tragedy_of_the_commons