Any idea wether it's the diff, or the trans? I'd probably put it up on jack stands, and try to replicate the issue. Then try to isolate wether it's the trans. or the diff. Disconnect the cable on the differential, and gently try to engage the 4wd. by manually working the lever on the diff. All while working the wheels back and forth. The wheels should turn opposite direction. Then when locked they should go the same way. I'm counting on it being limited slip. You should be able to feel it go into 4wd, if it does. Maybe rock the back wheels a bit, see if it helps to massage it into 4wd. If you try to do it with the engine running then the key here is gently in all things that aren't under load. Tiny gears are delicate, and expensive, also requiring lots of labor to replace. My guess would be the differential, it seems more likely. But I wouldn't rule out anything at this point, even a snag in the linkage.