I'm not military, but I was always under the impression that barring a dishonorable discharge (via court martial or the like), officers in the US military (at the very least) maintain their highest rank attained and, if reactivated, return at that rank. It's part of the lifetime commission thing. And retired US Army officers are subject to recall at their prior rank whenever the Reserves choose to activate them.
I'd say an Officer that goes from active service to civilian and back to active service keeps their Rank regardless of the inability to make prereqs. Enlisted folks wouldn't necessarily have the same situation, but I'd guess that the military, if reactivating or re-enlisting someone, would likely do their best to leverage prior skills/rank whenever possible.
This is generally the case, but recall is limited to age 65 except for certain general and flag officers. However, if the officer is REFRADed*, they may have to revert to an enlisted grade (the most junior one if they never served as an enlistedman), if they want to come back on their own.
Generally in the US, if you get recalled or you come back after retiring, it's at your previous grade. If you want to come back and you're enlisted, you may lose rank on reenlisting.
*ie, "cordially invited" to request RElease FRom Active Duty. aka, fired