Sudan and South Sudan have signed a non-aggression pact, the chief mediator at crisis talks between the two says.
Thabo Mbeki, the ex-president of South Africa, said both sides had agreed to respect each other's sovereignty and territorial integrity.
South Sudan became independent last July, but since then relations have deteriorated with numerous clashes along their disputed border.
It has also halted oil production amid a dispute over sharing revenues.
The South Sudanese opted to split from the north last year, following a peace deal in 2005 which ended decades of civil war in which some 1.5 million people died.
But the two never agreed on the transit fees that the South Sudanese government in Juba should pay Khartoum for pumping oil through its pipelines and using Sudan's oil export infrastructure.
The countries have also failed to reach agreement on borders and accuse each other of backing militia groups.
Mr Mbeki spoke to reporters after the first meeting in a fresh round of talks in Ethiopia's capital, Addis Ababa, to resolve some of these issues.
He said both sides had pledged to "refrain from launching any attack, including bombardment".
Earlier, UN Secretary General Ban Ki-moon had voiced his concern about the slow progress of the negotiations.
"The moment has come for the leaders of both countries to make the necessary compromises, once again, that will guarantee a peaceful and prosperous future for both nations," he said a statement.
Before halting production, South Sudan accused Sudan of stealing oil worth $815m (£518m).
Correspondents say the shutdown is hurting both economies - 98% of Juba's budget depends on oil while Khartoum needs transit fees to make up a 36% hole in its budget because of South Sudan's secession.
Friday's agreement aims to establish a monitoring mechanism to allow the two sides to lodge complaints if border disputes erupt.
The negotiations are expected to continue on Saturday, focusing on oil.