On our last camping trip, we discovered that the hot water heater would not stay lit. It is an all gas unit by Atwood. There are only two manufacturers that are producing the hot water units for the RVs, Suburban and Atwood.
After looking at ours and doing a Google search, it was pretty easy to determine the make.
First thing you should try is to thoroughly clean out the burner chamber and the gas orifice with compressed air. Dirt daubers and wasp, seem to have an affinity to creating their nest here. An obstruction can cause back pressure which could be causing a flame out. My unit was fairly clean with only a small dirt dauber nest in the exhaust chamber. :)
The gas units use a couple of sensors to determine the temperature of the water and whether or not the gas is lit. So the first step was to clean the connectors, by removing the wires, wiping with a little steel wool and replacing them. Mine were pretty difficult to remove. I had to use pliers and work them back and forth.
After these two steps, I tried to light the unit with no success. Okay one more thing to check before I start replacing sensors or the control board. The electronic ignitor provides a small resistance to the control board to determine whether the gas is burning or not. Sometimes the carbon deposits can prevent this from registering the correct amount. Carefully remove the ignitor. Have to be careful of the nut that sits almost inside the burner chamber. My unit only has a single bolt and nut. Once again "sand" lightly with a small piece of steel wool and reassemble. BINGO!! The unit fires right up and stays lit. Cool Beans!