The Austrian Empire had long been declining. This was due to a number of reasons. Most important were the different nationalities within the Empire. The Germans were the minority however they were in control of the government and all other important political positions. The Magyars, or the Hungarians, were powerless, and they were the larger group of disenfranchised people. The Italians in the west had become ceded after the war with Prussia and Italy. The Slavic groups in the north and south were very unorganized, and still didn't have any rights.
The principle political figure in Austria was Prince Klemens von Metternich. He worked to crush all revolutionaries. He failed, and a revolution still occurs in 1848. Austria would have disappeared except for the divisions in the revolutionary peoples. They each wanted much different goals.
At the end of this, Emperor Francis Joseph came to power. Under his reign, Austria lost Lombardy in 1859, and lost Venetia and control of the German States after the Seven Weeks War with Prussia.
After this war, the Magyars were very close to dividing. To stop this Joseph met with Francis Deak, a Hungarian leader.
In their Ausgleich, or compromise, Austria set up a new type of government, a dual monarchy. Joseph controlled Austria as an Emperor, and he controlled Hungary as a king. This eased a lot of the troubles from the more organized Hungarians, but it still left 3/5 of the people disenfranchised, or without voting rights. Austria and Hungary would have different politics, but they would have the same military and advisors.
Ottoman Empire was known as the Powder Keg in the Balkans because it was made of very different groups including Europeans, Africans, and Muslims. They lost Greece in 1829, and by 1850 Moldavia and Wallachia were lost to Russia, and Egypt Arabia and other Balkan areas had gained their autonomy. The empire was just waiting for its demise.
In The Crimean War, from 1854 to 1856 Russia fought Turkish forces to win access to the Mediterranean Sea. The British helped the Turks to keep the current trade routes, and the French fought to keep a balance in the already shaky Balkan area. During this war, Serbia, Bulgaria, and Romania fought for their freedom from their oppressors. There were not enough Turkish troops to suppress all of these revolutions, so the people were massacred.
Soon after, in 1877 The Russo-Turkish War was waged. Russia claimed to fight for the behalf of the Slavic people however they went for the land. Russia was able to annihilate the weak empire. This was ended in The Treaty of San Stefano, which created a large Russian controlled state in Europe, allowing plenty of access to Mediterranean. This was too favorable to the Russians, and the world had a problem with it.
The problems eventually forced the Russians to have the Congress of Berlin, to revise the treaty. This was revised so that Ottomans kept one third of the area, Serbia, Montenegro, and Romania won independence. Britain gained Cyprus, and Austria-Hungary gained Bosnia and Herzegovine. This satisfied few, including Ottomans, Balkans, and Russians.
Now, the unsatisfied Balkan people formed a group dedicated to destroying the Ottomans power in Europe, called the Balkan League. They beat the crap of Ottomans, and screwed them out of what little they had in Europe left. They won and all that was left of the empire was Turkey, and Istanbul, not Constantinople. This was horrible to the Ottomans, but the victory soon made the League break up and fight another war for the spoils of the first Balkan conflict. These conflicts only led the way for a world war.
The Austrians and Ottomans were similar in the fact that they both were old countries that had existed for quite some time, and were formally strong. They both were ready for demise. They had lost wars and land, mostly because of the divisions of their people's in the empires. The fact that the people in the empires saw other nations gaining independence only hurt them. The people had many other nations that wanted them gone for land, trade, and just for the destruction of them.
They were different because of the routes that they chose. The Austrians, chose the better path. They decided that it would be best if they would make compromises to keep their nation. They knew that they had to go to the bargaining table sometime, so they still exist. Ottomans, on the other hand, took the worse path. They decided that it was all or nothing, and they ended up with nothing. There is no Ottoman empire, and very few people who haven't learned of it know about it like France or England or Germany.