Elon Musk has countersued Twitter, escalating his legal fight against the social media company over his bid to walk away from the $44bn purchase.Musk’s lawsuit was filed on Friday, hours after chancellor Kathaleen McCormick of the Delaware court of chancery ordered a five-day trial beginning 17 October to determine if Musk can walk away from the deal.The entrepreneur’s 164-page document was not publicly available, however under court rules a redacted version could soon be published.Twitter did not immediately respond to a request for comment.Also on Friday, Musk was sued by a Twitter shareholder who asked the court to order the billionaire to close the deal, find that he breached his fiduciary duty to Twitter shareholders and award damages for losses caused.The lawsuit, which seeks class status, alleges Musk owes a fiduciary duty to Twitter’s shareholders because of his 9.6% stake in the company and because the takeover agreement gives him a veto of many of the company’s decisions. The lawsuit was filed by Luigi Crispo, who owns 5,500 Twitter shares, in the court of chancery.Musk, the world’s richest person and chief executive of Tesla, said on 8July he was abandoning the takeover and blamed Twitter for breaching the agreement by misrepresenting the number of fake accounts on its platform.Twitter sued days later, calling the fake account claims a distraction and saying Musk was bound by the merger contract to close the deal at $54.20 per share. The company’s shares ended on Friday at $41.61, the highest close since Musk abandoned the deal.McCormick fast-tracked the case to trial last week, saying she wanted to limit the potential harm to Twitter caused by the uncertainty of the deal.Twitter has blamed the court fight for slumping revenue and causing chaos within the company.The two sides had basically agreed to a 17 October trial, but were at odds over the limits of discovery, or access to internal documents and other evidence.Musk accused Twitter this week of dragging its feet in response to his discovery requests, and Twitter accused him of seeking huge amounts of data irrelevant to the main issue in the case: whether Musk had violated the deal contract.The chief judge in her order on Friday appeared to anticipate discovery disputes to come. “This order does not resolve any specific discovery disputes, including the propriety of any requests for large data sets,” said McCormick.Musk also faces a week-long trial in Wilmington, Delaware, beginning 24 October. A Tesla shareholder is seeking to void as corporate waste and unjust enrichment the CEO’s record-breaking $56bn pay package from the electric vehicle maker.