Smell the trans fluid to see if it is burnt. Burnt trans fluid is a differnet fluid than regular trans fluid and can really screw with a way a trans works. If it's burnt, replace the trans filter and gasket 2-3 times within a month to flush all the fluid out and then see how quickly it burns. If it burns quick (within a week or two), then you're looking at a bad trans; if it doesn't burn, it was due for a change. Changing the fluid every few weeks can prolonge the life by keeping the metal bits from making the problem worse, but it will go when it's darn ready.
Another thing worth checking is insufficient engine torque output. The trans has to be spinning at the right speed before it can shift, and the engine often has to pick up the torque of both the gear, rod, and the (currently spinning but not fast enough) differential. Properly engineered cars in good working order have very little knock from this especially if accelerating slowly, but a trans that isn't getting sufficient torque will knock whenever you shift up and, on occasion, jump whenever you shift down if it shifts too soon (very unlikely). If you're accelerating at the rate, then the car will shift and you won't even notice it and that's the way you should drive it (although some ligher foreign cars like it fast and hard).