Either by a rectangular single sail, or by oars, or both.
Rivers deep enough for their longboats to sail.
Viking longboats were rowed with oars till they caught wind in a single large square sail.
longboats
Unlike later ships of the Age of Sail, Viking longboats had many oars, as did the earlier ships of the Roman Empire. (see the drawing in the link below)
Longboats or Longships.
longboats
In longboats
"Longboats".
longboats
Having a shallow draught, Viking longboats allowed for sailing or rowing up shallow rivers.
vikings