You don't state WHICH water heater
Here is Atwood WH guide....Pilot starts on pg 6 plus
http://www.atwoodmobile.com/dealer-m...atermanual.pdf
Here is Suburban WH guide....Pilot starts on pg 6 also
http://hometips.me/Mar/Suburban_Wate...ice_Manual.pdf
Pilot Flame heats thermocouple...thermocouple generates milivoltage that holds magnet open (which keeps pilot flame lit)
Main flame lighting and then going out.....dirty orifice, gas tube not aligned (gas bouncing down tube vs going straight down center results in incorrect air/fuel mixture, flame spreader not aligned etc
See pilot wh guide
FYI......
Both Atwood and Suburban combo (electric/propane) can be turned ON at same time........fastest recovery
Atwood (since 2004) use same set of t-stats...so both electric & propane turn on/off at same time
Suburban uses separate sets of t-stats so electric/propane MAY turn on/off at different times but will be close....within manufacturing allowances +/- few degrees