Get up steep slopes.
No matter how fit you are, better climbing technique will save you time and energy on those steep uphill sections.
As you approach a climb, change into an appropriate gear early to avoid forcing a gear change halfway up the slope. Most MTB gears don't like changing under power and usually require you to ease of for a couple of pedal strokes. This can cause your forward momentum to stall making getting off and pushing likely.
Climbing steep slopes on an mountainbike poses other problems, as the gradient increases the front of the bike gets higher putting more and more weight onto the rear wheel. If you don't compensate for this eventually the front wheel lifts off the ground with each pedalstroke. Shift your weight forward by moving to the tip of your saddle and lowering your upper body over the bars.
Some hills are steep enough that even this technique is not enough requiring you to get out of the saddle to move your weight further forward still. It is also about this time that due to the amount of force required to move you up the hill the rear wheel starts to struggle for enough grip when off-road.
If the rear wheel starts slipping, move your weight back a little to weight it a little. You will now find that you are having to constantly adjust forward and back in a balancing act between getting enough grip and keeping the front wheel down.
Don't rule out getting off and pushing as a legitimate option rather than struggling up at the limit of your strength. This is fine for XC racers but wastes a lot of energy if you are venturing on an all day ride. Pushing up steeper hills to save energy is often used by riders taking part in longer endurance events.