On reading Graeber’s The Dawn of Everthing, it becomes clear that “we” (humanity in most places we’ve lived on earth) have made what approximates socialism (broadly construed), work, at scale, for probably most of our existence. In addition to many other forms of society. The question is more what do we need to make work to prevent a catastrophic extinction event for our species? We can probably make anything work that we need to.
I'm reading that Graeber book now, it's good. I enjoyed his Debt book too.
I recommend "Ministry for the Future" by Kim Stanley Robinson as a specific attempt to answer the question "what do we need to make work to prevent a catastrophic extinction event for our species." Whether what KSR describes is actually realistic is something you'll have to decide for yourself.
For much of our existence, primitive human groups operated on something more like a gift economy rather than socialism. Those systems are quite different both in theory and practice.