Hannah was deeply troubled about having no children. While praying to the Lord
she made a vow to give her first born to the Lord. When the child was weaned, she brought Samuel to Eli at the House of the
Lord in Shiloh. Later, ...Samuel said to the whole
house of Israel, If you are returning to the Lord with all your hearts, then
rid yourselves of the foreign gods and the Ashtoreths and commit yourselves to
the Lord and serve him only, and he will deliver you out of the hand of the
Philistines. So the Israelites
put away their Baals and Ashtoreths, and served the Lord only... ...the
Philistines drew near to engage Israel in battle. But that day the Lord thundered with loud thunder against the Philistines
and threw them into such a panic that they were routed before the Israelites.
(I Samuel 7:3-4, 10 ).
The Israelites ask for a king.* "And the Lord told him (Samuel): 'Listen to all that the people are saying to you; it is not you they have rejected as their king, but me.'" (8:7). This is what a king will do, see 8:11-22.
Saul becomes king of Israel in chapters 9 & 10. "...your kingdom will not endure...because you have not kept the Lord's command." (13:14). The Lord rejects Saul as king in chapter 15.
Samuel anoints David king in chapter 16. In chapter 17 David kills the giant Goliath. Even though David has been anointed king, he doesn't become king until after the death of Saul. David is one of the most interesting people in the Old Testament. It should be fun reading 1 & 2 Samuel!
*Note: Before king Saul, the people of Israel had no king. God was their king, but they didn't listen to Him. Now the office of king and priest will be separate, but will be combined again at a later date--in a future era.