Solid propelled rockets are the oldest type of rockets. In order for solid fueled rockets to work, the people that made the rocket had to find somthing that burned extremely fast but would not explode upon ignition. If the fuel exploded then the rocket would explode which would not produce a desirable result. You can use the same kind of ingredients as gun powder nitrate, carbon, and sulfur to make a simple rocket fuel. Since gunpowder explodes, you have to change the percentage of each ingredient in order to prevent the explosion. These are not the desired fuels for rockets any more. The fuels used today are a mixture of an oxidizer, fuel, and catalysts.
Picture provided by http;//howstuffworks.com/rocket.htm
The fuel is molded an then put into the rocket. The surface area of the fuel is in direct proportion to the thrust. The bigger the surface area the more thrust, but by maximizing the surface area the fuel is burned much quicker. The desired thrust of the rocket is to be a constant thrust which occurs after a large initial thrust. You do this by getting the surface area to a perfect proportion.
As you can see in the picture, once the rocket's fuel is ignited it will burn until the fuel is completly used up. The Space Shuttle contains somewhere in the range of million pounds of solid fuel which is burned up in about two minutes.