Originally posted by Black Book:
As long as you keep your iTunes Music Library found in ~Music/iTunes/ I imagine you should be OK.
Look for these two files in that location (unless you changed it):
iTunes 4 Music Library
iTunes Music Library.xml
As long as you have those files safely tucked away, you could move all of your music files to another drive and then back again and still retain your ratings, play counts, any any other data that isn't stored in the music files themselves.
Worst case scenario is iTunes will are you to locate each song manually, which while is super tedious, it will still keep your ratings.
Edit: As long as all of your music can fit on your iPod, you could erase all the music from your iPod, copy all of your music to it using the Finder along with the library database/index files, format your drive, copy all of your music back (make sure it's the same path like ~/Music/artistname), launch iTunes to make sure it reads the library files correctly, then sync up your iPod from iTunes and you'll be all set, exactly as it was before.