loans, and so defaulted on their debt in 1875. The Ottomans owed their loans to various European countries and their citizens, who were deeply upset at the failure of their investment and lobbied their governments to intervene. This effort became the Ottoman Public Debt Administration, which grew to become a major and independent arm of the Ottoman bureaucracy, whose sole goal was providing returns to European creditors. The stagnation and reform of the Ottoman Empire (1683–1827) ended with the dismemberment of Ottoman Classical Army. The issue during the decline and modernization of the Ottoman Empire (1828–1908) was to create a military (a security apparatus) that could win wars and bring security to its subjects. That goal took multiple Sultans with multiple reorganizations during this period. At the end of this period, with the Second Constitutional Era in 1908, Ottoman military became modernized and professionalized in the form of European Armies. Modernization 1808–1839 1808–1839 Mahmud II Mahmud II had to deal with multiple issues inherited from generations past. These issues lasted all through his reign. Shortly, the Eastern Question with Russia, England, and France, and military problems arising from mutinous Janissaries and factious Ulemas. He also faced numerous internal conflicts with Egyptians, Wahabbis, Serbians, Albanians, Greeks, and Syrians, and had administrative problems from rebellious Pashas, who would fain have founded new kingdoms on the ruins of the House of Osman. Mahmud understood the growing problems of the state and the approaching overthrow of the monarchy and began to deal with the problems as he saw them. For example, he closed the Court of Confiscations, and took away much of the power of the pashas. He personally set an example of reform by regularly attending the Divan, or state council. The practice of the sultan's avoiding the Divan had been introduced two centuries prior, during the reign of Suleiman I, and was considered to be one of the causes of the decline of the Empire. Mahmud II also addressed some of the worst abuses connected with the Vakifs, by placing their revenues under state administration. However, he did not venture to apply this vast mass of property to the general purposes of the government. Serbs, 1810s In 1804 the Serbian Revolution against Ottoman rule erupted in the Balkans, running in parallel with the Napoleonic invasion. By 1817, when the revolution ended, Serbia was raised to the status of self-governing monarchy under nominal