Bed and opiates, pretty much, yep.
If you were a member of a prehistoric nomadic tribal group, I suppose whether they found a way to take you with them would depend on their tribal ethos, and how valuable you were to them. Archeologists have found Neolithic skeletons with indications that a badly broken bone was allowed to heal, which says that somebody, somewhere, nursed that person back to health.
Up until just a few generations ago (the Harrison Narcotic Act of 1914, which also addressed cocaine), an assortment of opiates were widely and freely available for pain. People basically used those. So if you lived in the U.S., had chronic back pain, and could afford it, up till 1914 you could just go down to the store and buy some laudanum. After that, you’d have to get a doctor to prescribe it for you.
And I would assume that in ancient times, folks in Eurasia made liberal use of opiates as soon as the uses of the sap of the opium poppy became known, which quite possibly could have been 10,000 years ago. Homo sapiens is the great experimenter, and it wouldn’t have taken long for some more adventurous eater to discover the interesting effects of ingesting papaver somniferum.
And they’ve found evidence of poppy use in ancient Sumer.
Willow bark is also a painkiller, and is available worldwide.
South America had the coca plant.
And, yanno, people just lived with pain, a lot of the time. Depending on your mindset, you could also think of it as “your cross to bear”, or a trial sent by whatever god or gods you worshiped. Or the Neolithic tribesmen might have chalked it up to someone’s having put a curse on them, or they must have offended a god, or, heck, maybe they just hurt themselves hacking apart a mammoth carcass, and life sucks, yanno? or something. Either way, the pain wasn’t viewed as something that was fixable, unless they could figure out how to undo the hex or propitiate the god…So they just lived with it.