Attic ventilation is one component in a proper roof system. If the attic area doesn't have proper air flow your attic space will be prone to mold growth, shortened shingle lifespan and ice dams may form during winter cold snaps. In the following article I'll describe the most common way attics are ventilated today and a couple of ways to increase the airflow where necessary.
The most common way to vent attic space today is a system using a combination of ridge vent and soffit vent. A lot of older houses will have gable vents instead of ridge vents but these are not as efficient and can cause problems with air flow (the air in the middle of the attic isn't moved as efficiently as the air near the gables.) and gable vents can allow rain to enter during a windy storm. Some town codes will no longer allow gable vents to be installed.
Ridge vents are mounted just below the cap shingles on the ridge of the roof after cutting a slot for air to escape through the very top of the sheathing where it meets the ridge pole. This is the vent that allows warm air to escape. If an attic space is not venting properly it may not have enough ridge vent installed or the cutout slot may be too small. If there is room to add more ridge vent do it. The cutout slot should be made to the ridge vent manufacturers specs. If there isn't enough room to install more ridge vent another option is to install a roof fan. My favorite is the humble turbine fan. When the wind blows even a little the fan sucks air out of the attic space with no motors or electricity to hook up. If installed to manufacturers specs. these can usually draw out enough air.
Soffit vents are mounted under the eaves on the soffit boards. these allow air to enter the attic space without allowing rain water to enter as well. These can be as simple as cutouts with a piece if screening (installed between every rafter) to an aluminium vent strip running the entire length of the soffit. The most common problem with these is with attic insulation falling into the soffit area and preventing air flow. These will need to be inspected and cleaned out when necessary. Every space between rafters should be vented
One more thing, Intake vents and exhaust vents should both allow for the same volume of air to be moved. Air will only move at the rate the smallest vent will allow unless you are installing some kind of fan vent.