OK, these are just "thoughts", I have very little experience in these matters:
1. Are there two AC sources? In other words, is there an inverter on the batteries, converting the 12 Volts to high voltage AC AND an a separate AC source from the generator? And are these two sources, somehow, alternately switched in and out of the "house wiring"? If so, perhaps it has something to do with the quality of the AC. The AC produced by an inverter/generator can be as bad as a square wave, or it can be an approximation of a sinewave but still have a lot of harmonic content [i.e. a series of "square" steps], all the way to a pure sine wave. If your "genny" is basically a motor that turns a generator/alternator, then it very likely produces a pure sinewave, so when it's running, the power is clean enough to not cause interference in the network equipment.
2. Some kind of strange ground loop. As much as possible, all power commons should be connected together at or near the same point. And, at a point as close to the power source(s) as possible.
3. A bad [noisy] ground connection on the AC output of the battery array.
4. Have you measured the AC voltage being supplied to each piece of network equipment [such as DSL modem, router(s), etc.]? Measure the voltage when running on battery power alone, and when the generator is running. If there is a significant difference, that might be your problem. To troubleshoot, also measure the voltage at the sources. If the difference is no longer significant, then suspect voltage loss in the wiring [i.e. is there a longer current path from the batteries to your network equipment, than the path from the generator to the network equipment? Is part of the path from the batteries through smaller gauge wires, etc. If the voltages at the two sources are still significantly different, then perhaps there is a problem at one of the sources [i.e. not producing sufficient voltage].
5. If there is a difference in AC voltages, and if one or more pieces of network equipment has a broad voltage input [such as 100VAC to 240VAC], and if the voltage, when running on only batteries, is near one of those limits, perhaps, being on the edge of that range is causing problems in the power supply. Check the voltage requirements on each piece of equipment to make sure they comply with your setup.
6. Is there WiFi involved? Perhaps the battery inverter is generating RF noise that is interfering with the WiFi signal [rather unlikely, but who knows].
7. What about the AC frequencies? Are you sure the generator and the battery inverter, both produce the proper AC frequency for your area (and for your network equipment?).
8. Have an electrician look at your setup.
That's all I can think of from my limited knowledge.