Part 1 can be seen here
It is important to realize that while the alliance with the Shah was used to further US and Israeli interests and Iran was relatively close to Israel, it did not change the fact that overall, Iran wanted to become a regional hegemon. This had always been Tehran's true goal and it had never changed. The Shah as well as the general population believed in Iranian greatness and that conflict in the region would cease only when it was under Iranian supremacy.
The Shah's economic reforms and increased military spending were all focused on realizing this goal. During the late '60s and into the '70s, Iran quickly surpassed the economic and military might of its neighbors, thus establishing itself as the major regional power. This was all due to the jump in oil prices that occurred at the time. This increase in revenue not only allowed for Tehran to become the regional power but to also spread its influence throughout the region via giving loans to Arab neighbors.
During this time, Iran's military grew greatly and was modernized as the Shah "went on an arms shopping spree," doubling Iran's military expenditures from 1973 to 1974 and by 1976, "Iran's military expenditures had tripled, reaching an astounding $18.07 billion."  However, this was a regional phenomenon as (with the exception of Israel, whose military spending remained constant) all Arab nations went and increased their defense spending. In addition to this, Iran was using its booming economy to gain leverage over the Arab states, with Tehran giving loans totaling approximately $1.4 billion to countries such as Egypt, Syria, Jordan, and Morocco in 1974 alone.
Yet, this increase in military spending didn't aid Iran very much in its quest for regional supremacy as the Shah was now in a situation where Iran's foreign policy had to be changed in order to win recognition from states that weren't on good terms with Iran as without this recognition, Iran would be unable to enjoy the benefits of its newly found regional position. Gaining recognition from its neighbors would enable Tehran to gain leadership positions in regional forums such as OPEC. Such a course of action would ensure that the Arab states took Iran's opinion into account and make sure that there was no challenge to Iran's regional authority. The economic aid also failed to greatly increased Iran's influence as those same countries could seek out assistance from oil-rich sheikdoms in the Persian Gulf.
This focus on influencing Arab states had a negative side effect: it created a situation where the Persian-Jewish alliance was put at risk due to the fact that as the Shah became more and more interested in making good friends with the Arab, he considered Israeli interests and concerns less and less. While such acts may have somewhat alienated Iran from Israel, the 1973 Yom Kippur war put the entire strategic alliance into question.
While Israel did win the 1973 war, the very fact that Israel was nearly defeated "prompted Middle Eastern nations to reassess their perceptions of the balance of power. The war damaged the perception of Israel's strength, which had significant impact on the political map of the region."  The Yom Kippur war itself worried Iran. They did not want an Arab victory as such an event would make Iran the only "outsider" in the region, leaving them isolated and subject to possible attacks from an Arab coalition. Israel recognized this as they attempted to undermine the improvement of Arab-Persian relations and that Iran benefitted from the existence of animosity between Israel and the Arab states.
There were other factors at play as well. If there was an Israeli victory, it could potentially lead to the fall of Sadat's government and the return of a pro-Soviet Union Egypt. In regards to the USSR, Tehran was concerned that the Soviets would take advantage of America's preoccupation with Vietnam to challenge Iran's regional supremacy. Such an action would put into question Iran's ability to control of flow of oil and subsequently its ability to determine internal and external economic growth. Tehran also did not want US involvement in the region either as the Shah "'wanted no restraints on his ambition to dominate the [Persian] Gulf, and he saw the U.S. Navy base in Bahrain as a rival to his own suzerainty.'"  Overall, the Shah wanted to maintain Iranian regional hegemony by playing virtually all sides.
With these interests in mind, Iran maintained neutrality during the war; however this was false as Iran played both sides during the entire war. In regards to the Arabs, the Shah gave oil to the Arabs during the war, thus weakening Israeli-Iranian relations further. The Shah further aided the Arabs in the form of medical aid, providing Saudi Arabia with Iranian pilots, helping Arab planes to resolve logistical problems, and at one point even sending planes to transport a Saudi battalion to the Syrian side of the Golan Heights in order to rescue wounded Syrian soldiers and bring them to Iran for treatment. Iran also allowed for the Soviets to aid the Arabs and refused to allow Australian Jewish volunteers to get to Israel via Tehran. In regards to Israel, the Shah continued to sell oil and weapons to the Jewish state.
This deceit and treachery caused Israel to feel betrayed by Iran and greatly strained the relationship between the two nations. The relationship was strained further following the war as Iran began trying to locate opportunities to reduce their reliance on the Eilat-Ashkelon pipeline as due to the rise of a pro-US government in Egypt, the pipeline had lost its strategic significance as there was no longer any reason to circumvent Egyptian-held territory. Additionally, when Washington started up disengagement talks between Egypt and Israel, Tehran consistently sided with the Arabs, arguing that Israel should return all conquered land in exchange for peace and pressured Tel Aviv by freezing all military cooperation and ceasing the purchase of Israeli weaponry.
During the war, Israeli officials urged Iran to end its aid to the Arabs, telling the Shah that he didn't know who Iran's real friends were. However, what Israel did not realize was that the foreign policies of both countries were very different. While there was no formal alliance between the two, Israel expected Iran to act as their ally due to their common geo-political interests and intelligence cooperation. Iran, on the other hand, was quite cold in regards to foreign policy, having no time to think of such concepts as 'friendship.'
The Yom Kippur war forced Israel to rethink its relationship with Iran as the Shah had not come to Israel's aid, rather they used to war as an opportunity to solidify their position in the region. There was a problem, though: due to Iraq's newfound military might (they had the ability to overrun Jordan and be at Israel's eastern front in 48 hours), Israel was in need of an alliance with Iran even more than before the war. In an attempt to restart relations with Iran, Israel sent over Ambassador Uri Lubrani to Iran in 1973. Lubrani had a deep respect for Iranian culture and national cohesiveness, which Israel attempted to use to bring Israel back into the Shah's view. This attempt failed as Lubrani was regularly ignored by the Shah. While this situation was dismal and caused the alliance to be in a state of near disrepair, the final break between the two regional outsiders occurred in 1979 with the Iranian revolution.
At the outset of the Iranian revolution, the Israelis were not as surprised as the rest of the world when it occurred due to their intelligence network in Iran. Iranian officials indirectly revealed that discontent with the Shah was high when they turned to Mossad to aid them with the interrogation of more and more opposition members.
Somewhat prior to the Revolution, Israel had become aware that the Shah was politically paralyzed and unable to make decisions. Thus, the Israelis began to think about how they could save the situation and secure the Shah's reign. A split developed within the Israeli government. There were those who favored persuading the Iranian military to launch a coup and "those who believed that the new regime would soon collapse and be replaced by a leadership that would adapt to Iran's geopolitical realities and recognize its need for Israel."  Leading the former group was Ariel Sharon who proposed sending in Israeli paratroopers to Tehran with the objective of saving the Shah. This was voted down.
Eventually the Israelis began to talk to high-ranking Iranian military officials, arguing that they a coup to save the regime. This failed, though, as the Iranian generals were too afraid to challenge the Shah's authority, much less tell him how hated he had become. While the generals did take action in 1979, it was only after the Shah had fled to the US, and even then after the Carter administration signaled that they wanted a democratic Iran, most generals saw no choice but to flee the country.
When the new Islamist regime was finally in power, it dealt a major strategic blow to Israel. Tel Aviv had been continuously guided by the periphery doctrine even after they had made peace with Egypt and
within that strategic framework, Iran's location at the perimeter of the Arab world, its economic and military ties to Israel, its oil, and its traditional enmity with Iraq and the Soviet Union made it next to irreplaceable. After twenty-five years of Israeli political investments in Iran, the ties to Tehran had become a crucial element of Israel's regional strategy. 
While the issues of nuclear proliferation and Islamic radicalism fuel the problems between the countries today, at the heart of the situation lays the fact that Israel wants Iran back, wants the Shah back. They no longer want to be to "outsider" in the region, they no longer want a shattered friendship.
1: Trita Parsi, Treacherous Alliance: The Secret Dealings of Israel, Iran, and the United States (Yale University Press, 2007), pg 40
2: Ibid, pg 44
3: Ibid, pg 46
4: Ibid, pg 91
5: Ibid, pg 90