Lots of people seem to have issues with their 1998-2004 rear locker. Here's a brief write up, with 4 links.
If your rear differential lock is not working, and you have ruled out other issues (such as bad fuses) try this.
The following is a write up of what I did. Below that are links to pages with more details.
1) Remove actuator from diff housing.
2) Your actuator is in the unlocked position; mark on the gear and the housing the 12 o'clock position, so you can get it oriented back on the right way.
3) Remove snap ring and gear on actuator; set aside these two parts.
4) Remove aluminum plate that makes contact with the differential. There are 3 screws if I remember right. This plate may take some coaxing to get off.
5) Remove the rest of internal components, making sure you know how to reassemble it.
6) Hit the base of the shank (the part you took things off of in step 3) with PB blaster. Let it set, and then grab ahold of the shank with vise grips and try to twist it. Add more PB blaster and repeat until free.
7) Check contact points and make sure they are clean. Use dielectric grease (Marine grade works) to coat parts.
8) Do not remove the other housing on the outside of the actuator - the part that sticks up and is black, held on by three smaller screws. This reveals the motor; no need to get into that, at least not yet.
9) Reassemble, using RTV sensor safe sealant when you mate the aluminum plate back onto the rest of the differential housing. Make sure the gear you marked earlier is in the same position.
10) Hook the electronic hook up to the actuator, but do not mount the actuator.
11) Cycle the actuator from the cab (with the button). Leave it in the locked position.
12) Raise rear axle up on to jack stands, and chock the front wheels. With the emergency brake off, use a flat head screwdriver to move the rack gear inside of the diff to the left, to the locked position. You make need to move the drivers side left wheel some to get the rack gear to move. It is in the locked position if both wheels spin the same direction when you rotate the wheel by hand.
13) Now that it is in the locked position, reinstall the actuator. Put the vehicle back down.
14) Test it out.
I AM NOT LIABLE FOR ANY ISSUES THAT MAY ARISE CAUSED BY FAILURE TO FOLLOW DIRECTIONS. IF YOU DON'T THINK THIS IS A GOOD IDEA TO ATTEMPT, THEN DON'T DO IT.