If the account has successfully linked then it should happen instantly. You’ll need to make sure you have rolled back the ‘failed’ return before you submit the new return.
It may also be worth going through this guide to make sure that everything is set up correctly: HMRC Tax Accounts - MTD Returns