I've only read some popular science books on particle physics so my understanding is pretty basic. There are three colors and three anticolors. 3 x 3 will give us 9 gluons. Subtracting the red-antired and the other two leaves us with 6 gluons. Those science books only explain the first part but they don't explain how we wind up with 8.