If all the fuel related responses do not solve your problem, you may have the some thing I experienced about 3 years ago. Same as yours, the generator would start and then die. Finally took it to Onan and found the engine temperature sensor had broken. Replaced and started up immediately! Sensor is at the right rear of the engine on top of the coolant manifold. Technician stated that Onan had experienced a lot of the same failure.
Jerry