Skip to content

FullCLR modules not compatible with PSCore6 #4062

Closed

Description

With the change to CoreCLR 2.0 which conforms with .Net Std 2.0 as well as the update to enable searching the GAC for assemblies, we need validation that PSCore6 is a viable replacement for Windows PowerShell 5.x. Please list modules you've tried that do not work here. Vote with 👍 for which modules you most care about to help us prioritize how we work with partners to enable support or have them port to target .Net Std 2.0.

Until #4056 gets resolved, you'll need to manually add Windows PowerShell PSModulePath to discover those modules:

PS > $env:psmodulepath += ";${env:userprofile}\Documents\WindowsPowerShell\Modules;${env:programfiles}\WindowsPowerShell\Modules;${env:windir}\system32\WindowsPowerShell\v1.0\Modules\"

PSSnapins:

  • ActiveDirectory

Failing due to Add-Type

  • RemoteDesktop

Basic tests work:

  • Hyper-V
  • SecureBoot

Needs to be ported:

  • ODataUtils

Not sure:

  • WindowsUpdate (I'm getting error about symsrv.dll also in Windows PowerShell)

Activity

  1. added
    Issue-Meta
    on Jun 20, 2017
  2. added this to the milestone on Jun 20, 2017
  3. SteveL-MSFT commented on Jun 21, 2017

    @SteveL-MSFT
    MemberAuthor

    Workflow is not something we're planning on supporting. Instead we're committed to improving the concurrency/parallel execution experience in PowerShell script which we believe is the primary reason people used Workflows. If there's other reasons, let me know.

    ConvertFrom-String relies on technology from Microsoft Research that currently isn't planned to be Open Source.

    I appreciate the feedback, though.

  4. SteveL-MSFT commented on Jun 21, 2017

    @SteveL-MSFT
    MemberAuthor

    Workflow and ConvertFrom-String are independent with different reasons why they are not in plan to be in PSCore6. I would agree that ConvertFrom-String would work great against existing text based native utils on Linux. Perhaps we can create a new cmdlet with similar, but simpler capability as ConvertFrom-String.

  5. RichardSiddaway commented on Jun 21, 2017

    @RichardSiddaway

    ConvertFrom-string, or similar functionality, would be extremely useful

  6. iSazonov commented on Jun 21, 2017

    @iSazonov
    Collaborator

    I checked the Windows PowerShell module load on Windows 10 ver 16215 with RSAT installed.
    Script and results (including errors) in attached file.
    4062a.txt
    4062b.txt - full list modules from PowerShell Core.

    In short.
    Total Core modules = 12.
    Total Windows and Core modules = 120.
    Total Windows modules = 108. ( In Windows Powershell Get-Module -ListAvailable).count = 109 )
    After PowerShell Core start - 3 modules is loaded.
    After attempting to load all modules - 71 modules is loaded.

    So 59 from 108 Windows modules is loaded.
    $error.count = 79

  7. SteveL-MSFT commented on Jun 21, 2017

    @SteveL-MSFT
    MemberAuthor

    Ilya (@iSazonov) thanks for getting those results.

    • The CDXML based cmdlet failures will be addressed once we move to newer dotnet core that has this fix.
    • A majority of the errors are due to conflicting aliases for DSC.
    • RemoteDesktop module is calling Add-Type which fails and we should investigate that
    • Workflow one is expected not to work
    • ISE one is expected not to work
    • ODataUtils is one my team owns that needs to be ported cc Andrew (@anmenaga)

    cc @PowerShell/powershell-committee

  8. iSazonov commented on Jun 22, 2017

    @iSazonov
    Collaborator

    Oh, ActiveDirectory module is PSSnapIn 😕 The main consumers of PowerShell Core (system administrators) are thrown overboard!

  9. SteveL-MSFT commented on Jun 22, 2017

    @SteveL-MSFT
    MemberAuthor

    We'll have to talk to that team about rewriting their cmdlet...

  10. iSazonov commented on Jun 22, 2017

    @iSazonov
    Collaborator

    Exchange Server 2013 EMS crushed PowerShell Core. Also it can not find Exchange assemblies.

  11. iSazonov commented on Jun 22, 2017

    @iSazonov
    Collaborator

    SCCM 2012 R2 module is not loaded - broken .Net dependences and not found assemblies in local (SCCM home) folder.

  12. iSazonov commented on Jun 22, 2017

    @iSazonov
    Collaborator

    Sharepoint 2013 module is PSSnapIn.

  13. 40 remaining items

  14. apetitjean commented on Feb 28, 2018

    @apetitjean

    Thank you Maximo Trinidad (@MaximoTrinidad). Posting here was exactly my intention. I hope Steve Lee (@SteveL-MSFT) will see my question here.

    Indeed see you soon! :)

  15. SteveL-MSFT commented on Feb 28, 2018

    @SteveL-MSFT
    MemberAuthor

    Arnaud Petitjean (@apetitjean) the plan is to be able to support Active Directory module via the Windows PowerShell Compatibility Pack. Most likely we'll use implicit remoting and perhaps with JEA.

  16. markekraus commented on Mar 1, 2018

    @markekraus
    Contributor

    Steve Lee (@SteveL-MSFT) Windows PowerShell Compatibility Pack will be windows only, correct? I don't think it is acceptable for an Active Directory module to work only on Windows. If the plan is to temporarily support support AD only on Windows until the required .NET Core APIs are made x-plat, than I'm ok with that. But, AD is used for more than just Windows environments and the ability to build automation in Linux (and macOS) using PowerShell should not require direct .NET manipulation or calling out to other shell/scripting languages which can support AD on Linux.

  17. apetitjean commented on Mar 1, 2018

    @apetitjean
  18. markekraus commented on Mar 1, 2018

    @markekraus
    Contributor

    The current AD module has PSSnapin requirements which wont work in PS Core anyway, unless we are adding some PSSnapin shim in the Windows PowerShell Compatibility Pack I am not aware of... the only way for an AD module would be a re-write. This is why I'm disturbed Steve Lee (@SteveL-MSFT) saying AD module (even though it is the OS team's responsibility, and not the PowerShell Team) would be supported by Windows PowerShell Compatibility Pack. There was already a critical need for refactoring the module for core, and if its future is in the Windows PowerShell Compatibility Pack, then that is the wrong direction.

  19. MaximoTrinidad commented on Mar 1, 2018

    @MaximoTrinidad

    I'm with Mark Kraus (@markekraus) opinion. I really not in favor of using Windows PowerShell Compatibility Pack and I think "... it should keep them separated!!".

    But that's my take!
    :)

  20. iSazonov commented on Mar 1, 2018

    @iSazonov
    Collaborator

    My understanding of Windows PowerShell Compatibility Pack was that it contains all that never will be ported.

  21. SteveL-MSFT commented on Mar 1, 2018

    @SteveL-MSFT
    MemberAuthor

    The intent of the Windows PowerShell Compatibility Pack is to temporarily help existing Windows PowerShell users move to PSCore6. The long term plan is to have modules natively run on PSCore6 as well as be cross platform. Some teams may decide they will never port to PSCore6 or they will, but not invest in making it cross platform compatible. The biggest influencer to help them make the right decision is customer feedback (not the PowerShell Team where we represent the customer).

  22. markekraus commented on Mar 1, 2018

    @markekraus
    Contributor
  23. dudeNumber4 commented on Jan 22, 2019

    @dudeNumber4

    If I have scripts that have dependencies on .Net framework dlls, I should look for a .Net core version of those dependencies via nuget and then try to port the script to PS6? There is no "wrapper" for these dependencies, correct?

  24. SteveL-MSFT commented on Jan 22, 2019

    @SteveL-MSFT
    MemberAuthor

    dudeNumber4 it depends. If it's an assembly PSCore6 already includes (and we include a lot), then you shouldn't need to make any change unless you refer to a specific dll via path. For example, if you were dependent on System.DirectoryServices.AccountManagement.dll previously using Add-Type to load, if you didn't specify a path, it should just work.

  25. dudeNumber4 commented on Jan 23, 2019

    @dudeNumber4

    dudeNumber4 it depends. If it's an assembly PSCore6 already includes (and we include a lot), then you shouldn't need to make any change unless you refer to a specific dll via path. For example, if you were dependent on System.DirectoryServices.AccountManagement.dll previously using Add-Type to load, if you didn't specify a path, it should just work.

    OK, just attempted New-Object System.Data.OleDb.OleDbConnection. Cannot find type. On nuget, I see some kind of port that claims support for .Net Standard 2.0. To port the script I'd have to add a nuget restore of that library, correct?

  26. SteveL-MSFT commented on Jan 23, 2019

    @SteveL-MSFT
    MemberAuthor

    dudeNumber4 we don't include that assembly as part of PSCore6 itself, so to use it, you should be able to use Install-Package to download that nupkg at runtime, or do it manually and just include that assembly with your script.

  27. IanKemp commented on Feb 1, 2019

    @IanKemp

    WebAdministration - is xWebAdministration the replacement, or will WebAdministration be ported?

  28. SteveL-MSFT commented on Feb 1, 2019

    @SteveL-MSFT
    MemberAuthor

    Ian Kemp (@IanKemp) that module is owned by the IIS team so I don't know their plans. However, last time my team looked at that module some of the necessary .Net Framework namespaces were not available in .Net Core, so until that happens it wouldn't work unless they rewrite it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Issue-MetaResolution-ExternalWG-Cmdlets

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions