MeshCentral icon indicating copy to clipboard operation
MeshCentral copied to clipboard

Mesh ASSISTANT Does Not Launch

Open BDN-2020 opened this issue 10 months ago • 6 comments

First I'd like to say, VERY IMPRESSIVE WORK to Ylian. I say that having experience as a developer. In a few days I was able to stop using an expensive remote desktop sharing application that I've been using for about 10 years.

The Windows agents ARE working well. But when I create the ASSISTANT links and download the assistant, it asks for permission and runs but nothing happens. The tray icon doesn't appear.

I tried starting it from the command line hoping for some verbose output. But still nothing. A new line cursor appears but no error or status.

Server and clients are running Windows 10 LTSC and LTSB

Mesh Server version .21 WAN mode. Lets Encrypt: TRUE (working as expected). I'm using port 444. Node version 18.16.1 My DNS server has feature running on port 80. But I turned it off. Set the redir port to 80 and port to 443 and tried again. On startup it said it SIGNED the agents. But the results were the same. I tried turning on agentInviteCodes. But that doesn't seem to affect the issue.

 "settings": {
    "agentInviteCodes":true,
    "cert": "------",
    "WANonly": true,
    "port": 444,
    "_aliasPort": 443,
    "redirPort": 80,
    "redirAliasPort": 80,
    "postgres": {
      "host": "127.0.0.1",
      "user": "-----",
      "port": -----,
      "password": "----"
   }
  },
  "domains": {
    "": {
      "title": " Remote Service",
      "title2": "---------",
      "_minify": true,
      "newAccounts": true,
      "userNameIsEmail": true
    }
  },
  "letsencrypt": {
    "__comment__": "Requires NodeJS 8.x or better, Go to https://letsdebug.net/ first before trying Let's Encrypt.",
    "email": "--------,
    "names": "------------",
    "skipChallengeVerification": true,
    "production": true
  }

Thank you.

BDN-2020 avatar Apr 11 '24 22:04 BDN-2020

just tried it here and it works perfectly fine? when you download it, it runs in the taskbar with all the icons by the clock you can also set assstantTypeAgentInvite under your domains in config.json to specify a different type of download the default is 0 which is system tray icon only image

si458 avatar Apr 13 '24 22:04 si458

I'm sure it is NOT a real bug. I didn't find any other posts about issues with Assistant. It's probably related to something the installer (me) is doing incorrectly . :/

It does appear that the assistant background agent is running because I see a second agent in the Task Manager. But the tray icon doesn't appear.

I also found a series of entries in the Windows Application log. But I'm not certain what is causing them. The first appears to be .NET related. I do have some (not all) of the .NET Windows Features turned on. Here the log entries:

==================== WINDOWS APPLICATION LOG: #1: .NET RUNTIME

Application: MeshCentralAssistant-Assist (1).exe Framework Version: v4.0.30319 Description: The process was terminated due to an unhandled exception. Exception Info: System.MissingMethodException at MeshAssistant.MeshCentralAgent.LoadAgentCertificate() at MeshAssistant.MeshCentralAgent..ctor(MeshAssistant.MainForm, System.String, System.String, System.String, Boolean) at MeshAssistant.MainForm..ctor(System.String[]) at MeshAssistant.Program.Main(System.String[])

===================== FOLLOWED BY #2 APPLICATION ERROR

Faulting application name: MeshCentralAssistant-Assist (1).exe, version: 0.1.0.1, time stamp: 0x6287e52f Faulting module name: KERNELBASE.dll, version: 10.0.14393.0, time stamp: 0x57899809 Exception code: 0xe0434352 Fault offset: 0x0000000000017788 Faulting process id: 0x9eff0 Faulting application start time: 0x01da8e0e89b29e80 Faulting application path: C:\Users\Day3\Downloads\MeshCentralAssistant-Assist (1).exe Faulting module path: C:\Windows\System32\KERNELBASE.dll Report Id: ea018aea-7bd2-43d3-a398-d35bd308cc77 Faulting package full name: Faulting package-relative application ID:

================================== FOLLOWED BY 10 OR 20 ENTRIES SOURCE WINDOWS ERROR REPORTING

Fault bucket , type 0 Event Name: CLR20r3 Response: Not available Cab Id: 0

Problem signature: P1: MeshCentralAssistant-Assist (1) P2: 0.1.0.1 P3: 6287e52f P4: MeshCentralAssistant P5: 0.1.0.1 P6: 6287e52f P7: ad P8: 1a5 P9: System.MissingMethodException P10:

Attached files:

These files may be available here: C:\ProgramData\Microsoft\Windows\WER\ReportQueue\AppCrash_MeshCentralAssis_d7692075a23d119233a6c53e5040baf5f60d26d_4be6b66a_0fb3eab3

Analysis symbol: Rechecking for solution: 0 Report Id: ea018aea-7bd2-43d3-a398-d35bd308cc77 Report Status: 100 Hashed bucket:

=======================

Thanks.

BDN-2020 avatar Apr 14 '24 02:04 BDN-2020

have you made any modifications to the meshassistant.exe? as the logs above seem to show that it is crashing inide this function private X509Certificate2 LoadAgentCertificate()

si458 avatar Apr 14 '24 16:04 si458

Not that I'm aware of (intentionally). It did say 'signing agent' on startup one time when I was changing the ports so that Let's Encrypt would run properly. I am running it on port 444 because of my other https server on 443. But that wouldn't affect the exe certificate. (right?)

BDN-2020 avatar Apr 15 '24 05:04 BDN-2020

Should I re-install? If I do will I loose contact with my existing agents?

BDN-2020 avatar Apr 24 '24 20:04 BDN-2020

Meshcentralassistant isn't designed for permanent access to a remote device. For this you would install the meshagent. I would maybe try deleting the agents and signedagents folders inside meshcentral-data, restart meshcentral, let it resign the exes, then redownload and run the new exe u downloaded and see if it works

si458 avatar Apr 24 '24 22:04 si458

I did a clean install on a different server (running Windows 10 LTSB). I did a new domain and enabled Lets Encrypt. I tried the Mesh Assistant and it failed to launch. I didn't change anything except for setting the ports and domain in config.json.

This error was in the events: Application: MeshCentralAssistant-test.exe Framework Version: v4.0.30319 Description: The process was terminated due to an unhandled exception. Exception Info: System.MissingMethodException at MeshAssistant.MeshCentralAgent.LoadAgentCertificate() at MeshAssistant.MeshCentralAgent..ctor(MeshAssistant.MainForm, System.String, System.String, System.String, Boolean) at MeshAssistant.MainForm..ctor(System.String[]) at MeshAssistant.Program.Main(System.String[])

Is this a problem with the LE cert or the one it generated? Thanks.

BDN-2020 avatar May 27 '24 00:05 BDN-2020

Have u tried running the assistant on a totally different machine? Your machine might be missing updates/packages

si458 avatar May 27 '24 09:05 si458

I'm confident I tried 2 or 3 machines earlier to rule that out. However, to make sure I tried Assistant from the new install on a second pc and it worked! So I tried Assistant from the first server on the second pc and it worked also. I think there may have been 2 issues. Fist is the pc I was trying to connect. The second, maybe there was an issue with the signing of the agents and/or the certificates and ports. I did back those up and restarted MC yesterday on the first server while debugging.

Thankful to see it running.
Appreciate your help and Illian's work. Blessings.

BDN-2020 avatar May 27 '24 15:05 BDN-2020