This saying deals with the role of the servant and punishment for misdeeds. God is the master, and we are the servants.
1. If the servant knows what the master wants and then deliberately fails to do so he is punished, i.e. "will be beaten with many blows". Clearly this indicates that the punishment will be harsh. Presumably this mirrors the teaching that serious sin (mortal sin = something gravely wrong is willingly done by one who knows it is wrong) results in grave punishment (hell).
"1858 Grave matter is specified by the Ten Commandments, corresponding to the answer of Jesus to the rich young man: "Do not kill, Do not commit adultery, Do not steal, Do not bear false witness, Do not defraud, Honor your father and your mother." The gravity of sins is more or less great: murder is graver than theft. One must also take into account who is wronged: violence against parents is in itself graver than violence against a stranger.
1859 Mortal sin requires full knowledge and complete consent. It presupposes knowledge of the sinful character of the act, of its opposition to God's law. It also implies a consent sufficiently deliberate to be a personal choice."
2. If the servant does not do his master's will out of ignorance of that will he too will be punished but not as harshly, i.e. he will be "beaten with few blows". One may question why a person would be punished if he is ignorant to the wrongness of his actions. Church teaching provides explanation.
1850 "Feigned ignorance and hardness of heart do not diminish, but rather increase, the voluntary character of a sin. "
"1860 Unintentional ignorance can diminish or even remove the imputability of a grave offense. But no one is deemed to be ignorant of the principles of the moral law, which are written in the conscience of every man. The promptings of feelings and passions can also diminish the voluntary and free character of the offense, as can external pressures or pathological disorders. Sin committed through malice, by deliberate choice of evil, is the gravest.
1862 One commits venial sin when, in a less serious matter, he does not observe the standard prescribed by the moral law, or when he disobeys the moral law in a grave matter, but without full knowledge or without complete consent. "
For more on mortal and venial sin see that section of the Catechism.
There is a further implication of the gospel and catechism, that being ignorant of what the master commands is foolish and dangerous. People need to make a conscious effort to inform themselves and their consciences concerning what God commands.
"1798 A well-formed conscience is upright and truthful. It formulates its judgments according to reason, in conformity with the true good willed by the wisdom of the Creator. Everyone must avail himself of the means to form his conscience.
1801 Conscience can remain in ignorance or make erroneous judgments. Such ignorance and errors are not always free of guilt.
1802 The Word of God is a light for our path. We must assimilate it in faith and prayer and put it into practice. This is how moral conscience is formed."
For more on avoiding ignorance of truth see the section on MORAL CONSCIENCE.