Make a route from a track - error

Hi, when I create a route from a track it creates a straight line and does not follow the path created. Can you tell me how to solve it?