I "washed out" of a PhD CS with an MSCS, and I think most of the parent poster's advice is good. Definitely the bit about not changing after 30 or so. Especially if you get married (or whatever) and have kids, your priorities and possibilities will change radically towards finding one good position and staying there.
I got my BSCS from a department that happened to be outstanding at the moment I went through, even though you've never heard of it. I then foolishly searched for a great CS department to do a CS PhD, (i) without first verifying that I really wanted a PhD and that it would be useful in the kind of work I really enjoyed, and (ii) failing to realize that it's not the department that counts at the graduate level, it's all about the one or two mentors you will have. My grad school has a good enough rep that everyone recognizes it, but the general departmental strategy was "throw everyone in the water and see who doesn't drown". I'm sure that worked for some, but I was completely lost for several years. In retrospect, I'd have been much better off identifying one good person to learn from and studying with them, even if it's at BFE Tech.
Based on that, I'd say that first you should think long and hard about what kinds of positions you'd like to have. If you can pinpoint people who are doing what you'd like to be doing, try asking them for advice.
Second, as the parent said, try to be doing something serious now, and try to identify specific people you'd like to apprentice under at a graduate level.
Good luck.