SharePoint Migration tool CMDLets (SPMT) is not working as a job (or a non-console) anymore...

Uwe Abdulhag 0 Reputation points
2025-11-25T09:20:28.7266667+00:00

Starting v 4.2.192.2 I'm facing a Console error problem with previously perfectly working workflow with SPMT (register-spmtMigration, Add-SPMTTask, start-spmtMigration ...) , Namely that the tool now refuses to work in a "non-console", which is easily reproducable in PowerShell ISE ... (or running it as a job for example). The error will occur with a register migration, which uses in my case a certificate so that I do not need to Authenticate and use MFA ... This was wokring like a charm, but Now I cannot use my existing migration workflow to teams and sharepoint and I do not see why this even be a relevant "requriement" not to mention a need ... apart from the graphical interface, the PowerShell commandlets are expected to run in a scritpting context, to be able to trigger them and handle the output in so called non-console!

So this is a new regressive behaviour ... I really hope it would be removed in the next release or so ...

But for now, How to avoid this issue ? how to avoid/turn-off this new regression/requirement, currently I can only turn off spmt updates and hope that the older version works as long as possible... OR what options other than do I have to interact/add/trigger/stop migrations to Teams or sharepoint and OneDrive that can be used in PowerShell easily ?

Microsoft 365 and Office | SharePoint Server | For business
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Kudos-Ng 10,385 Reputation points Microsoft External Staff Moderator
    2025-11-25T11:48:06.9033333+00:00

    Hi Uwe Abdulhag,

    Thank you for posting your question in the Microsoft Q&A forum. 

    From what I understand, the behavior you described indicates that after updating to version 4.2.192.2, the SharePoint Migration Tool (SPMT) PowerShell cmdlets no longer run successfully in workflows executed through PowerShell ISE or when running as a background job. This impacts your automation flow, and you are asking whether there is a way to prevent this or if alternative approaches exist.

    First, I would like to clarify that I am a forum moderator and do not have access to a SharePoint Server environment to reproduce this behavior. My input is based on publicly available documentation and community discussions. At this time, I have not found official reports or documentation addressing this specific issue. However, here are some insights I can share:

    • You mentioned updating to 4.2.192.2, but according to the official release notes here: New and improved features in the SharePoint Migration Tool, the latest publicly documented version remains in the 4.1.x range, and the article was last updated on March 3, 2025. This suggests that your version may be a newer build or a preview release not yet reflected in GA documentation.
    • The official SPMT PowerShell documentation specifies that the tool requires Windows PowerShell 5.x and .NET Framework 4.6.2 or later. If you have upgraded to PowerShell 6 or 7, please note that these versions (PowerShell Core) are not supported by SPMT. Additionally, PowerShell ISE behaves differently from the standard PowerShell console—it does not fully emulate an interactive console environment, which can cause issues for cmdlets that require session interaction. For this reason, I recommend testing your script in the standard PowerShell console to confirm whether the behavior persists.

    Currently, there is no documented option or feature to disable this requirement. The workaround you mentioned—rolling back to an older version and disabling auto-update—is the most practical solution for now. I also recommend following the General Availability (GA) versions listed in the official release notes to avoid unexpected behavior from preview builds.

    If you are looking for additional insights or alternative approaches, I highly suggest posting your scenario on: https://github.com/orgs/community/discussions There, developers who could have encountered similar situations may provide further guidance or share workarounds.

    I hope these insights help clarify the situation. Please let me know if you need further assistance or additional resources.


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.