Are the wheels still turning while the knocking sound is heard? If the linkage isn't adjusted to where the spring loaded parking pawl isn't able to fully seat into the notch which locks the
trans in park, you'll hear the pawl bounce against the notches. An adjustment should cure the problem unless the pawl is damaged or worn or its spring is broken to where it won't completely seat. There should be a spring resistance felt when the shift lever begins to enter the park position detent.
It's not unusual for the parking pawl to break or the assembly to experience damage. This is usually caused by engaging the park position while the car is still rolling.