Skip to content

AdsServer Connect System.PlatformNotSupportedException: ServiceController enables manipulating and accessing Windows services and it is not applicable for other operating systems #75

@Stiwa-PohG

Description

@Stiwa-PohG

Hi,
i got the following exception message when i tried to start the AdsServer

[ERROR] AdsServer Connect System.PlatformNotSupportedException: ServiceController enables manipulating and accessing Windows services and it is not applicable for other operating systems. at System.ServiceProcess.ServiceController..ctor(String name) at TwinCAT.Ads.Server.AmsServer.isTwinCATServiceRunning() at TwinCAT.Ads.Server.AmsServer.CheckPInvokeAvailable(ILogger logger) at TwinCAT.Ads.Server.AmsServer.createRouterSocketImplementation(ChannelPortType requestedPortType) at TwinCAT.Ads.Server.AmsServer.createServerImplementation(ChannelProtocol requestedProtocol, ChannelPortType requestedPortType) at TwinCAT.Ads.Server.AmsServer.ConnectServerAndWaitAsync(CancellationToken cancel) at TwinCAT.Ads.Server.AdsServer.ConnectServerAndWaitAsync(CancellationToken cancel)

Test setup

  • Windows 11
  • Beckhoff.TwinCAT.Ads 6.2.347
  • AdsServer runs in a .NET Core 8 application

Error has only occurred once so far and could not be readjusted. Restarting the application solved the problem!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions