DIAGNOSIS Yes. Something is overheating. This is either a severe clog right before the motor, a failing motor bearing, or a worn drive belt.
FIX Unplug the vacuum immediately. Let it cool. Remove the dust cup and filters. Inspect the cavity where the pre-motor filter sits for debris. Check the hose and brushroll chamber for a major clog, especially near the motor inlet.
IF THAT DIDN'T WORK The burning smell could be the brushroll belt. Remove the brushroll. A glazed, shiny, or melted belt will produce a rubber burning smell. Replace it.
HEADS UP A persistent electrical burning smell after clearing clogs points to a failing motor. Stop using it. A motor can overheat to the point of melting internal components or becoming a fire hazard.