Because of his position of leadership, Moses is judged extremely harshly when he sins.
The following article is reprinted with permission from Kolel: The Adult Centre for Liberal Jewish Learning.
In parashat Hukkat, we find an overwhelming concern with death. At the beginning we find the mysterious laws of the Red Heifer, a very rare animal which is burnt in a special fire outside the camp. Its ashes are then used to ritually purify those who have become impure due to contact with a dead body.
The portion then jumps 38 years to the end of the Israelite's wandering in the desert. We read the brief description of the death of Miriam, the prophetess who was the older sister of Moses and Aaron, and then an incident about the people's need for water. These two events are in fact connected by the Rabbis, who notice that stories with Miriam are always associated with water.
The people complain about thirst, and Moses is instructed by God to speak to a rock, which will then produce water. Seemingly frustrated and saddened by his sister's death, Moses strikes the rock instead of speaking to it. Water does flow, but Moses is chastised by God for his lack of trust, and he is told that he will not be allowed to lead the people into the Promised Land.
We then read of Aaron's death, and the people's mourning for him for 30 days. The portion ends describing a number of battles the Israelites must fight as they travel through the wilderness.
And Moses raised his hand and struck the rock twice with his rod. Out came copious water, and the community and their beasts drank (Numbers 20:11).
This is really one of the saddest passages in the Torah. Moses, the long time leader of the Israelites and the greatest teacher and prophet our tradition has ever known, loses control of himself, and is punished in a particularly harsh way (from his point of view) by God.
The Israelites are camped at Kadesh, in the wilderness of Zin, when Miriam, Moses's sister and one of the leaders of the people, suddenly dies. The text then tells us immediately afterwards that the people are without water (this is the basis for the strong tradition that teaches that it was because of Miriam's merit that water was provided to the Israelites in the wilderness).
The people start complaining profusely to Moses and Aaron, who go to the Tent of Meeting to confer with God. God instructs them both to take a rod and, in full view of the entire community, they are to order the rock to give water. Moses and Aaron do as they are told, gathering the people together, but then chastise the people, and demand, "shall WE get water for you out of this rock?" Then, rather then speaking to the rock, Moses hits it twice with the rod. As God promised, water flows from the rock, but Moses and Aaron are taken to task by God for not doing exactly as God instructed.