斬草除根 means killing a person and all his descendants so there is no chance for a revenge. Did it actually happen? Yes. It did happen and it's not the worst. 誅三族 means killing all of one's relatives of father's, mother's and wife's sides. In Qin dynasty, 李斯 received this savage punishment of 誅三族, which was ordered by 趙高, who, later, received the exact same punishment.
Worse than 誅三族 are 誅五族、誅七族、誅九族. The worst of all is 誅十族 which happened in Ming Dynasty to 方孝儒, a famous scholar。Besides all of his relatives, even his friends and students were killed. According to wikipedia, a total of 837 people were killed and thousands received other punishments.