Here's the second thing -- the military may not let you out at the end of your active duty tour. Under a program called "Stop Loss," the military is allowed to prevent you from separating, during times of conflict, if they need your particular warm body. During the first Gulf War (1990), all of the services implemented "Stop Loss,"preventing pretty much anyone from separating, for an entire year. During the Kosovo Campaign, the Air Force instituted "Stop Loss" for those in certain "Shortage" jobs. During Iraq and Afghanistan, The Army, Air Force, and Marines instituted "Stop Loss," again, directed at specific individuals with shortage jobs, or (in the case of the Army), sometimes directed at specific units. The key is, once you join, if there are any conflicts going on, the military can hold you past your normal separation or retirement date.
Up until October 2003, the Army and Navy were the only services that offered active duty enlistments for periods of less than four years. However, as part of the FY 2003 Military Appropriations Act, Congress passed the National Call To Service Plan, which mandated that all of the services create an enlistment program which offered a two year active duty enlistment option, followed by four years in the Active Guard/Reserves, followed by two years in the Inactive Reserves (still the total eight year service commitment).
But, let's talk reality here -- While Congress mandated this plan, they gave the services wide lattitude in implementation. The Army and Navy already had two year active duty enlistment plans that they were happy with, and the Air Force and Marines had no recruiter problems, and weren't really interested in shorter-term enlistments.
However, because of enlistment shortages, the Army has dramatically expanded slots under this program in 2005 and 2006. The Air Force and Marine Corps still have little interest in a two-year active duty program. So, they implemented the very basics and applied many restrictions -- you probably have a better chance of hitting the lottery than getting one of the very few National Call to Service slots in these two branches. For example, under the Air Force Plan, the program is limited to one percent of all enlistments (about 370 total recruits, out of 37,000), and the program is limited to 29 Air Force jobs. The Marine Corps limit their National Call to Service enlistments to only 11 MOSs (jobs).
The Army and the Navy are the only services which have active duty enlistment options of less than four years, which are not part of the National Call to Service program. The Army offers enlistment contracts of two years, three years, four years, five years, and six years. Only a few Army jobs are available for two and three year enlistees (mainly those jobs that don't require much training time, and that the Army is having a hard time getting enough recruits). Most Army jobs require a minimum enlistment period of four years, and some Army jobs require a minimum enlistment period of five years. Additionally, under the Army's 2-year enlistment option, the two years of required active duty don't start until after basic training and job-school, so it's actually longer than two years.
The Navy offers a very few two year and three year contracts, where the recruit spends two or three years on active duty, followed by six years in the Active Reserves.
The other services offer four, five, and six year enlistment options (The Air Force only offers four and six year enlistments). All Air Force enlisted jobs are available for four-year enlistees. However, the Air Force will give accelerated promotions for individuals who agree to enlist for six years. Such individuals enlist in the grade of E-1 (Airman Basic), or E-2 (Airman), if they have sufficient college credits or JROTC. They are then promoted to the grade of E-3 (Airman First Class) upon completion of technical training, or after 20 weeks after basic training graduation (whichever occurs first). Six year enlistment options are not open to all jobs, at all times.
Most Navy jobs are available for four-year enlistees, but some special programs (such as Nuclear Field) require a five year enlistment. These special programs usually offer increased training opportunities, and accelerated promotion.
All of the services offer programs called "enlistment incentives," which are designed to attract recruits, especially to jobs that are traditionally hard-to-fill. As I said above, each of the below incentives needs to be included on the enlistment contract or an annex to the contract -- otherwise they are not likely to be valid.