1. The KL34-170-90 has a black, red, and green wire. Green is Ground, White is +, Black is Common. I assume the white wire is Arm + (terminal 3)and black is Arm -(terminal 4). Where does the green ground wire go?Green ground should run back to your control cabinet's ground bus/point.
2. Are all 5 wires from the encoder used? Where does the green index wire go?You'll just need 4 wires for your Gecko servo loop, +/- power and a/b single ended signal. The index is not used for your Gecko servo loop. It can be used for a highly repeatable homing signal, but don't worry about that now.