Empty the cabinets and take off everything from the counter top. Empty the kitchen floor and move out chairs and tables so that you have free space to work. Tape plastic sheets over the areas close to the cabinets like counter top, walls and floor.
Sand the cabinets:
Use a 100 grit sand paper to sand the cabinets and cabinet boxes. Move the sand paper along the lay of the grain. You need to provide a rough surface so that the paint sticks well. Vacuum up all the dust that has accumulated after it.
After you are done with sanding and have cleared the dust, apply primer on your cabinets. Go against the grain first and than with it. Let the primer dry thoroughly before proceeding.
When the primer gets dry, sand your cabinets again to cover up any bumps created by the primer. Vacuum the dust again.
Apply primer again on the cabinets. When it gets dry, sand the surface and vacuum up. Repeat this process 2-3 times to have the perfect surface for paint.
Dip your brush into the paint and brush the cabinets in the direction of the grain. The first layer should be a thin one. Let it dry. Apply a second layer only after it dries. Some people paint the base color in a lighter shade and the second layer in the final one.
Allow the second layer to dry overnight. Check if your cabinets need a third coat. Re-install the cabinets with the metal fixtures when they go completely dry.