There are basically two methods and I tried both: You can create a “gold card” and turn S-OFF, then root manually, which will entail a lot of futzing around with your phone and an extra mini SD card, or you can do the heavy lifting by booting into a Linux Live CD (choose the latest 32-bit LTS version) and automating most of the process with a slick software package called Advanced Ace Hack Kit. I recommend using the latter technique, even if you’ve never used Linux before.
It’s not easy if you’re totally new to it, but if you’ve enough confidence to try installing a custom ROM on your phone, you can probably work it all out: Download Ubuntu, burn the .iso file to a CD, choose to try out Ubuntu from the CD instead of installing it when the option appears. Figure out how to open the Terminal application, and you’re ready to go. Follow the instructions in this handy guide, keeping a couple of things in mind: Although the guide states, “no ROM downgrade is needed prior to attempting to root,” I did in fact need to downgrade my ROM (Advanced Ace Hack Kit told me I had to) first. Also, “any 32 bit computer running Linux” probably means “any computer booted into a 32-bit version of Linux.” The important links in that document that have changed, I have linked to in this post. Lastly, I ran into a problem after downgrading the ROM, deleting the downgraded ROM, and trying to install CyanogenMod ROM with ClockworkMod Recovery: The automated installation stopped with an error, leaving me with no bootable ROM and the phone showing the white HTC loading screen in perpetuity. I solved this by holding down the Volume Down key and pressing the Power key to boot into ClockworkMod Recovery, then using it to choose the .zip file to flash (CyanogenMod 7 ROM in zip archive had already been downloaded to the mini SD card in a previous automated step). That was it.
Some other problems I encountered, such as the Hack Kit prompting for a password, were solved by RTFM (reading the effin manual for the kit).
The only backup I performed beforehand was my phone contacts, which I saved to my mini SD card (the SD card contents were not noticeably affected by any of these procedures), because I wanted to start totally fresh.