I've been reading here about a some peoples problems with power failures, so I thought I'd post the method I used during the many power failures I had before I got a whole house generator.
I had a portable generator with enough capacity to run my lights and ceiling fans, fridge, freezer, microwave, toaster oven, well pump, and one small window AC. An easy way to do this is to buy a generator with enough capacity to have a dryer receptacle. Then you construct a cable with 10/4 portable cord with a male dryer plug at each end.
During a power failure you turn off the following breakers: main, dryer, water heater, central heat & AC, stove, water pump, and any other large loads. Plug one end of the temporary cord into the generator before it's started, run the other end of the cord into the laundry area and plug it into the dryer receptacle, start the generator, and close the main on the generator.
Then you close the dryer breaker at the main panel. If you have done every thing correctly you now have power to all the essentials, without having to run extension cords all over the place.
Keep in mind that you've only got about 30 amps available, and the more stuff you have powered on, the faster the generator will run out of fuel. Never turn on the central heat & AC breakers, as this would probably immediately trip the generator. Don't use more than one burner or the oven on the stove, unless you turn off the water heater, well pump breakers, and the window unit AC. IOW you have to actively manage the loads.
To test if the utility power has returned you only have to open the dryer breaker, and close the main. Make absolutely sure that both breakers are never closed at the same time until the generator is disconnected. With the newer electric meters, this test is not necessary. you can just look at the LC display on the meter. If it's back on, you have power.
If the power has returned, open the dryer breaker, and close the main and any other open breakers, shut down the generator and remove the temporary cable, plug the dryer back in, and then close the dryer breaker at the main panel.
Simple yes? I got so tired of doing the this in the middle of the night by flashlight, that after my portable generator was stolen, and I had gone through a 38 hour outage without it, I had a whole house generator installed. Expensive, but I was getting too old to stumble around in the dark with a flashlight anyway. It also has the advantage of using propane for fuel, and it came with a 250 gal tank.
The generator was installed three months ago, and we haven't had a power failure since. Just a few glitches that didn't last long enough for it to even start its warm up cycle.
See, my expensive new generator is working very well! :>)>