Via Rail and the union representing some of its workers reached a tentative deal ahead of a midnight strike deadline, the Canadian Auto Workers said.
The union did not release details of the tentative settlement and said ratification votes were being scheduled.
"We're very pleased to have reached a tentative deal with Via Rail," said Bob Orr, assistant to the union president.
"This has been a long and emotional process for our master bargaining committee. We've spent days engaged in very tense bargaining on issues most important to members and we're happy to have settled this contract without a labour disruption."
Earlier Thursday, the union said talks had stalled because Via attempted to circumvent the negotiation process by communicating directly with its employees.
And Orr had said there was "no chance" to reach an agreement by the deadline.
But later in the evening, the union confirmed that negotiations had resumed but said the two sides were still far apart on a number of major issues.
Union represents 2,000 employees
The union represents about 2,000 of Via's customer service employees, as well as on-board service and maintenance workers at the passenger rail company.
Via Rail presented its latest proposal on Wednesday, offering wage increases of two per cent every year for three years.
However, the offer also included higher employee contributions to the pension plan that the union said would result in members taking home less money, not more.
"What the company wants to do is increase employees' pension contributions substantially over the next three years," Orr said.
The union also objected to plans that would slash pension benefits for new Via employees and the rolling back of income protections for seasonal workers.
Via said its employees need to contribute more to the pension because it currently faces a $419-million deficit.
"There are no major concessions that are being asked of current full-time employees, except to have them help maintain the current pension plan by increasing their contributions," said Via spokeswoman Mylene Belanger.
Via president and chief executive Marc Laliberte said the company's pension deficit is putting pressure on its bottom line.
Via Rail laid out a contingency plan last week in the event of a strike. Management were to have offered basic railway services, including daily trips in the morning and at the end of the day on the Quebec City to Windsor, Ont., corridor.
Long-distance trips and service to remote locations would have been provided once a week.