If your vacuum cleaner smells like burning rubber when running it could be that the belt is stuck and not turning along with the motor.
When you turn the vacuum cleaner on look to see if the motor is turning the brush and if the brush isn't spinning then the brush could be stuck and causing the motor shaft to spin around in the inside of the belt which is a cause for a burning smell.
If that is not the problem then the burning smell could be caused by the motor overheating due to the motor wearing out.
But usually the burning smell coming from a vacuum cleaner when it's on is the belt especially if it is smelling like burned rubber.