There aren't too many industries than can claim to be as brutal for sheer number of hours worked than the production industry. Apart from people who work in TV, movies, touring, recording and a few other specialties, you've got the armed forces, doctors, and some of the more insane areas of construction. But I don't want this to turn into a pissing match as to who works more hours, the idea is to look at what it does to your body and how you can deal with the effects if an all nighter can't be avoided.
The tour industry tends to be populated with a lot of young guys and a few salty old road dogs. The reason for this is that young bodies can handle the brutal hours and then they either get out and do something more sane, or learn how to minimize the stress and survive to be the old dogs.
Pulling all nighters can be just as hard on somebody sitting in a studio as they are for someone working a load out. A guy pushing boxes is keeping his blood circulating, probably getting thirsty and drinking water, and taking a breather when he gets a chance. If you're in the captain's chair in a studio, your metabolism is slowing down, you may not realize you're getting dehydrated, and you're not as likely to take a break.
The first and most important thing is to just try and minimize the stress levels. If you're super stressed you can go into fight or flight mode where you body is churning out chemicals to get you pumped up. That can be a pretty bad thing if it goes on for a long time with your blood sugar all out of whack and adrenaline making your hands shake, not just for the work you're trying to do but in terms of your health. It's a tough trick to learn but to be able to disconnect yourself from the extraneous elements like the producer or tour manager breathing down your neck and just do your work is what separates the men from the boys.
Next down the line is storing up energy. I used to do things like hang drywall all day, then load in a gig, mix, and then strike in the middle of the night and drive home. There had to be enough of me left to not drive into a pole at the end of it all so I got pretty good at hoarding my energy. I would make sure I didn't over do it and try to just keep still and relax as much as possible. (I may have even shut my eyes a few times during the second set.)
Adding to your store of energy is important too. If it's going on midnight and you haven't had anything to eat in six hours, you're going to start feeling it pretty soon. Get some calories down your neck, whatever you can manage and you'll feel a lot better. Plan on eating again if it really is an all nighter, even if you're not usually a breakfast person, downing a few more calories before you finally crash at 6am will set you up to feel better when you get up again.
And last and probably the most important is to watch your caffeine intake and especially your water intake. Even if you're not sweating, conditioned air can suck the moisture right out of you, and it's way harder to re-hydrate than it is to pre-hydrate. In my college days I often had to drive all night for one reason or another and I would always feel better if I started out with water or juice the first couple hours and then sparingly got into some coffee or cola while still downing water. I would always feel better and more alert with just a trickle of caffeine coming in than when I pounded it in advance.
If you're starting to feel thirsty it may already be too late and you'll be trying in vain to play catch-up. If you're starting to get a headache from dehydration then you're really in the soup and it can be nearly impossible to drink enough to get back to your full potential so you can focus on your work. Keep in mind that you're loosing minerals as you're sweating or pissing out all that coffee. Meals will help restore those and there's always sports drinks.
Beyond that, it's super important to pay attention to any warning signs your body is giving you. If your heart rate is over 200 or you're having chest pains, for gosh sakes get some medical attention. It's not all that common, but guys in their 20s and 30s do occasionally drop dead of heart attacks. Repetitive stress injuries can take you out too, proper posture and even good shoe inserts can help you avoid a back blow-out. If your wrists and shoulders hurt, take a look at the way you do things. Sitting in a chair in a studio can lay you low too, get someone who knows what they're doing, even someone who's just in medical school to check out the ergonomics for you. Laying on your back with vertebrae out of place isn't the time to look at these things, and carpal tunnel surgery is good these days, but do you really need that in your life?
So stay chill my Brethren of the Knob and Fader. Those deep breaths and tall glasses of water could be the difference between a long and happy career and leaving the gig early when you have a heart attack. Learn to pay attention to your body just like you do to your equipment.