To maintain the vacuum that a rotary pump could achieve, you have to keep the pump on. Be aware of that no vacuum seal is 100% perfect. If you need to keep samples for short period of time in a vacuum, switching off the pump may be fine for your application purpose.
A rotary pump is a "natural block" between ambient pressure and vacuum, but only down to the vapour pressure of the used oil.
Thus, if you turn off your pump, the vacuum side pressure will rise to that (assuming you don't have leaks). However, that's a bad way to preserve your vacuum since oil vapout in the main chamber will slow down the next pumpdown and contaminate everything inside. So, if you turn off the pump, I highly recommend (having and) closing a valve between the pump and the chamber (or the turbo pump, if that's what the rotary pump is backing).
Recommendation for electrical blackouts: You can install automated pneumatic valves between pump and chamber that will keep at least parts of the vacuum intact if a blackout occurs.
Most rotary pumps can be rotated back by the atmosphere pressure when powered off. To prevent contamination of the pumped volume either an electromagnetic or a pneumatic NC valve should be placed as close as possible to the pump's inlet. The power (or air) supply of the valve should be the same as for the pump itself so that the valve closes automatically as soon as a blackout occurs.
For oil sealed pumps it is also recommended to vent the inlet of the pump when it is powered down so no oil can be sucked from the pump by the vacuum. This can be automatically done by a NO valve connected to the pump's power supply.