Nothing in the gym will place the lateral stresses on your knees and ankles like the AT does. Hiking where you can place lateral stresses on your knees and ankles is your best training. Depending on where you live, and what trails are available to you. Living in Minneapolis, there are several trails to choose from, and I hiked many of them, however in preparation for the AT, I should have placed 35 pounds on my back & climbed up and down the rocky uneven river bank all day, because that more represents the AT then hiking several miles across relatively flat terrain. But more then the physical aspect, is the mental. Start pruning out modern comforts, get rid of the TV and the radio, and place yourself in relative isolation. Sleep on the hardest floor you can find with the heat turned down, or hang up your hammock somewhere.