2 Samuel 16:1 When David had gone a short distance beyond the summit, there was Ziba, the steward of Mephibosheth, waiting to meet him. He had a string of donkeys saddled and loaded with two hundred loaves of bread, a hundred cakes of raisins, a hundred cakes of figs and a skin of wine.

2 The king asked Ziba, “Why have you brought these?”

Ziba answered, “The donkeys are for the king’s household to ride on, the bread and fruit are for the men to eat, and the wine is to refresh those who become exhausted in the wilderness.”

3 The king then asked, “Where is your master’s grandson?”

Ziba said to him, “He is staying in Jerusalem, because he thinks, ‘Today the Israelites will restore to me my grandfather’s kingdom.’”

4 Then the king said to Ziba, “All that belonged to Mephibosheth is now yours.”

“I humbly bow,” Ziba said. “May I find favor in your eyes, my lord the king.”

I'm thinking... now why would David give Mephibosheth's inheritance to Ziba? Let's get the characters right....

Mephibosheth was Jonathan's son. Jonathan was David's closest friend. Jonathan was also Saul's son. Saul was the first anointed king of Israel. David was the second anointed king of Israel.

Now David was in a period of "calamity". David had an affair with one of the wives of one of his troops. That was Bathsheba. When Bathsheba got pregnant... David tried to cover it up. He had Uriah, Bathsheba's husband, killed on the battlefield. But as we can imagine, God wasn't happy with the whole affair. God took Bathsheba's baby and brought calamity on David's house.

One of David's daughters, Tamar, was raped by one of his sons, Amnon. Tamar was Amon's step sister. Tamar's brother Absolom killed Amon. Apparently Absolom didn't like the way David handled the whole issue so he started a political campaign to replace David as king. After four years.... Absolom ran David out of town.

So... now it turns out... Ziba was a liar. Mephibosheth never said he was going to be king when Absolom and David killed each other off.

This is from blueletterbible.org.

He is in Jerusalem: Ziba told David that Mephibosheth was in Jerusalem, waiting to come to power after David and Absalom ruin each other. Ziba told David that Mephibosheth longed to restore the family of Saul to power (Today the house of Israel will restore the kingdom of my father to me).

Ziba lied to David and this will be revealed in 2 Samuel 19:24-30. In fact, Ziba left Mephibosheth behind to make it look like Mephibosheth did not support David.

All that belongs to Mephibosheth is yours: David - acting on the only information at hand - assumed that Ziba told the truth. Therefore he rewarded Ziba's loyalty and he punished Mephibosheth's reported disloyalty.

This was exactly the response Ziba wanted. Ziba is an example of someone who wickedly used a crisis for his own benefit.

This is from Bible.org.

David and his followers have just passed the summit of the Mount of Olives. There he is met by Ziba, the servant of Mephibosheth. We first met Ziba in 2 Samuel 9. Ziba was a servant of King Saul. In order for David to fulfill his covenant with Jonathan, he needed to find an heir of Saul to whom he could show favor for Jonathan's sake. He was told of Ziba, who was formerly Saul's servant. Ziba was summoned, and there he informed David about Mephibosheth. When David brought Mephibosheth into his home, to eat at his table, he also restored to Mephibosheth all that was his as the heir of Saul and Jonathan. David also appointed Ziba and his family to serve Mephibosheth as his servant, as they had done before Saul's death.

Now we meet Ziba again. This time, Ziba meets David with provisions for the journey ahead. David inquires of Ziba why he is bringing these supplies, and Ziba informs him that it is for the king and those with him, since the journey ahead will prove difficult. David then asked Ziba where his master, Mephibosheth, was. Ziba told David that Mephibosheth had gone to Jerusalem, hoping that his father Saul's kingdom would be restored to him. On the basis of Ziba's account, David gave to Ziba and his sons all that had been given to Mephibosheth.

David was crying when he left Jerusalem. Some of the commentaries called it the trail of tears.... [in deference to the Cherokees in my life I'm not going that route]. Now David learned that Jonathan may have turned on him too.... well I know his heart is broken.... but because of the calamity.... David accepted what that liar, Ziba, told him.