He formed a sort of military school, where the boys practiced all the discipline necessary in camp. He himself set to work to learn to use different tools, and in general he studied the trades of his people. He managed to get teachers who could instruct the boys in history and geography, and as a result instead of being good for nothing the circle of boys in the little palace became unusually energetic and active-minded. When he finally left the palace it had become a well-organized military school, and continued to be run as such for a long time afterward.
When the Princess Sophia realized that these plans of hers were failing, she decided on a more desperate measure. On the night of August 7, 1689, Peter was suddenly waked in the middle of night by fugitive soldiers coming from the Kremlin, who warned him that Sophia had gathered a band of soldiers to come out to his palace and kill him. The boy, realizing his extreme peril, jumped out of bed, and throwing on a few clothes ran to the stables, where he found his favorite horse and set out with some comrades into the neighboring forest.
There they stayed practically in hiding until officers came from the palace bringing him food and clothing, and gradually gathering about him until he had quite a small body-guard. By this time he had made up his mind what to do.
Feeling sufficiently strong with his friends, he finally set out for a monastery, thinking to find safe refuge there until the storm should pass. Here more friends came to join him, and as the news of Sophia's plot to kill the boy Czar was spread through the country, a new enthusiasm for the youthful Peter sprang up, and the very troops that had formerly sided with the Princess now denounced her as a traitor to Russia. Peter wrote to his stepsister asking for explanations about the plot at the Kremlin, but the Princess could make no satisfactory reply.
The monastery was now crowded with officers of the court who had come to realize that Sophia's power was gone and that the boy Czar's strength was rising rapidly. The time had come when he was strong enough to strike. He marched on the Kremlin and captured Sophia and those who had been in the conspiracy with her. Some of the Streltsi Guard who had taken part against him were tried and executed, and the Princess Sophia was shut up in a convent for the remainder of her life.
Such events did not tend to make the boy a merciful ruler, but surrounded as he was by traitors and spies he was compelled to rule with an iron hand if he was to rule at all.
From this time dates the beginning of his real influence in Russia. The army had been poorly organized. Now the young King set to work to drill it as effectively as he had drilled his playmates. He learned how cannon were built, and studied the manufacture of all kinds of firearms. About the same time he became deeply interested in ship-building, and determined to build a fleet of war-vessels on Lake Plestchéief.
He took some young men of his own age with him to the bank of the lake and there built a one-storied wooden house, a very primitive building, the windows filled with mica instead of glass, and set a double-headed eagle with a gilt wooden crown over the door to show it was the Czar's residence. Here he worked hard all one winter, he himself taking a hand in all the building that was done, laboring like any carpenter and enjoying the work far more than the state ceremonies he was obliged to go through with at the Kremlin.
But even when he was so far from Moscow and so actively engaged, he sent continual messages to the mother who had so often shielded him from harm. Once he wrote to her as follows:
"To my best beloved, and, while bodily life endures, my dearest little mother, the Lady Czarina and Grand Duchess Natalia Kirílovna. Thy little son, now here at work, Petrúshka, asks thy blessing and wishes news of thy health. We, through thy prayers, are all well, and the lake has been cleared of ice to-day, and all the boats, except the big ship, are finished, only we have to wait for ropes. Therefore I beg thy kindness that these ropes, seven hundred fathoms long, be sent from the artillery department without delay, for our work is waiting for them, and our stay here is so much prolonged."