Actually, it really depends on what is meant by "old times" and in which countries.
In some European counties, for instance, the use of a constant family was necessary to enforce one's claims on a fiefdom or land use.
Take for instance my family. In the 13th century, they owned a farm called "Hentlare" - the (male) owner was called Everhard Offensone von Henthlere
["E.O. of Henthlere" = from the place Henthlere]. One of his relatives signed the below shown document from 1286 as one of the witnesses with his name, which was Dithmar von Hinthlere
From the 15th century onwards, all used "Hinteler" as name, without the "von" but with "Schulte" as prefix, meaning that they were the "officials" in that hamlet 'Hinteler'.
To stay in this position, over the centuries three males had to chance their own family name - because they married a female heir and there were no sons - to 'Hinteler'.
(All that ended in 18th century, when that farm went bankrupt.)