As a native San Franciscan, sourdough got into my blood at an early age. I have kept a sourdough pot in the fridge for years. I'm no expert but there are some basic do's and don'ts. Here are some iron-clad rules for starting and keeping sourdough.
To start, there should only be THREE (3) ingredients: Flour, water, and yeast. Anything else will eventually spoil the pot. To begin, combine one cup of flour, one cup of warm water and one package of dry yeast. Let it sit out on the counter, loosely covered, for about 3 days. Make sure your container is large enough (at least 3 times the volume of the starter mixture) or you may get an overflow as the mixture activates.
When it gets good and rank-smelling, you can refrigerate it in a tightly covered container. It will eventually separate with a clear liquid on the top that is variously known as "liquor," "beewack" or "hooch." Yes it is alcohol and that is what gives the sourdough its distinctive tang. Native Americans used to make sourdough mostly to skim off the alcohol since that is the by-product of yeast consuming the flour.
When you want to use sourdough to make a recipe, bring out the pot, stir in the liquor and remove what you need. NEVER-NEVER put unused sourdough tainted with any other ingredients back into the storage pot!! Add back about as much flour and water as was removed, let it sit out again for 2-3 days to enhance the tang, then put it back into the fridge.
As long as your sourdough pot is not tainted with anything else but flour and water, it will keep indefinitely.
When I want to make primitive sourdough bread, I'll bring out a cup of sourdough, then add the flour and water the recipe calls for, let it sit out and get really rank for about 2-3 days, than add fresh flour to make a workable sponge to knead and let rise. HINT: I never-ever add any baking soda or baking powder to primitive sourdough bread because that alkalinity reduces the acidic tangy sourdough flavor. It's the active sourdough that causes the bread to rise.
A primate sourdough loaf baked in this way is crusty, dense, firm and not a good vehicle for making sandwiches. It is best enjoyed as an accompaniment to a good Italian meal, seafood, or spicy soup/stew wine and cheese. It also makes the world's best toast. When it goes stale (and I don't often have that problem because it is so irresistible that we eat it all up quickly) it makes fantastic French toast and even better salad croutons.
The BEST reference to anything sourdough is contained in this fantastic little book which I believe is out of print. Anyone else ever heard of it? It's my sourdough Bible.
SOURDOUGH JACK'S COOKERY And Other Things: Sourdough Jack Mabee: Amazon.com: Books