ShareGate Scheduled Tasks - timing out after several days due to Azure token expiry

Brass Contributor


Unsure if anyone else has used ShareGate however whilst we use it for migrations we've also utilised it for creating scheduled tasks to copy items from network drives and other sharepoint sites on a daily, weekly and monthly frequencies.

After several days these tasks stop working with the MU-058-162 error message which normally occur when connections that are done via the Browser authentication method when configuring a task.

SG Support said that what can occur is if the token has expired between the time of the setup and launching of the scheduled task, the connection will fail and an error message will be displays (same as above). Since reauthenticating acquires a new authentication token, this would explain why doing so resolves the above error.

Considering we have 30 of these tasks setup on schedule, its very time consuming having to re-authenticate these when they all expire - the Weekly/Monthly jobs never occur as the auth token expires by then.

It's worth noting that the account for this has been excluded from MFA via Conditional Access policies.

SG Support have suggested that I contact my Infrastructure team and request that the authentication token does not expire - once this has been done, the scheduled tasks shouldn't encounter the same behaviour.

I've asked our team and they are unsure how to extend the token limit based on the below:




It would be useful if anyone knows how to resolve this or can point me in the right direction.


0 Replies