President Reagan yesterday ordered 2,000 U.S. Marines to move into the eastern Mediterranean just off the coast of Lebanon to serve as a backup force if the 1,200 Marines on the ground in Beirut are attacked again.

The White House also announced that Reagan will end his California vacation three days early and return here today to confer with administration officials and congressional leaders about the situation in Lebanon and the shooting down of a South Korean airliner by the Soviet Union.

Administration officials stressed that there are no plans at present for the new force to go ashore from the three ships in which they will sail to Lebanon. Instead, the Marines will join 600 others now in reserve aboard five U.S. warships near Beirut.

This will bring the total of Marines on the ground in Beirut and offshore in reserve to 3,800. The 1,200 in Beirut are serving in the multinational peace-keeping force that also includes French, Italian and British troops.

Pentagon officials said the Marines will be armed heavily with tanks, amphibious personnel carriers, artillery, antitank missiles, machine guns, six vertical takeoff fighter planes, attack helicopters and cargo helicopters. The three ships carrying the new contingent will be manned by 1,100 naval personnel, while the reserve force already off Beirut has five ships and about 2,000 naval personnel.

White House spokesman Larry Speakes said in Santa Barbara that Reagan was determined "that all necessary measures be taken to assure the safety of the Marines in Beirut, including the deployment of an additional naval amphibious force in the Mediterranean."

In addition, Speakes said, the president directed the aircraft carrier USS Dwight D. Eisenhower, which already is near the Lebanon coast, "to remain in the area for an undetermined period of time ready to assist our forces as needed."

Administration officials, elaborating privately on the move, said it did not conflict with Secretary of State George P. Shultz's assurance Wednesday that there is "no plan under consideration at the moment to change the size or the role or the mission of the multinational force or the Marine component of it."

The officials, who declined to be identified, said the new force was intended to warn the feuding Lebanese factions in Beirut not to repeat the attacks that killed two Marines and wounded 14 others on Monday. If the Marines on land do come under fire again, the new force will be able to move in and help them repel attacks, the officials added.

The arrival of the additional 2,000 Marines will put a sizable U.S. military force in or near Lebanon that could be brought into play quickly if the administration decides to intervene more directly in Lebanon's civil strife.

Concern that the United States might become bogged down in a Lebanese civil war has caused some congressional leaders of both parties to call for Reagan to invoke the provision of the War Powers Resolution that would bar the president from keeping forces abroad in hostile situations for more than 60 days unless Congress gives permission.

Until now, the administration has been reluctant to do that because it fears a divisive congressional debate that could shackle its freedom of action in Lebanon. Administration officials said that part of Reagan's reason for returning to Washington early is to dramatize the crisis nature of the situation and to permit him to seek an accommodation with Congress.

Speakes said the president dispatched the second task force on the recommendation of the special Middle East situation group chaired by Vice President Bush and including Shultz, Defense Secretary Caspar W. Weinberger and Gen. John W. Vessey Jr., chairman of the Joint Chiefs of Staff. Bush relayed the recommendation by telephone following a meeting yesterday in Washington.

The new Marine force is being transferred to the eastern Mediterranean from Mombassa in Kenya, where it recently completed offshore exercises.The White House initially said it included 1,600 Marines, but the Pentagon later said the number is 2,000.

Speakes said the president's advisers also had "recommended continued strong support for Lebanese President Gemayel's call for key Lebanese leaders to join in a dialogue aimed at constituting a new national approach to reconciliation and unity."

Gemayel appealed Wednesday for a dialogue that would include leaders of Lebanon's four principal religious groups: Maronite Christians and the Moslem Sunni, Shiite and Druze sects. Administration officials said Gemayel's aim is to explore a possible redistribution of governmental power among these groups in exchange for their recognizing his government's authority.

Walid Jumblatt, whose Druze militia has been fighting Christian forces in the Chouf Mountains, rejected the idea. However, U.S. officials said yesterday that they were hopeful that the other three groups will be more cooperative and that Gemayel will be able to begin working out with them a resolution of the religious tensions dividing the country.

The officials said they believed that Gemayel's hand had been strengthened by the Lebanese army's apparent success in routing the Shiite and Druze forces that triggered this week's violent fighting in Beirut.

However, they also conceded that Jumblatt's rejection of Gemayel's offer had left big doubts about whether it will be possible to achieve agreement for interposing the army between the warring Druze and Christian militas in the Chouf when Israeli forces stage their withdrawal from the area in the next few days.