Get state from Mnesia if applicable.