Ylianst / MeshCentral

A complete web-based remote monitoring and management web site. Once setup you can install agents and perform remote desktop session to devices on the local network or over the Internet.
https://meshcentral.com
Apache License 2.0
4.08k stars 546 forks source link

Remote desktop does not work on Apple M1/ARM #4443

Open bbrendon opened 2 years ago

bbrendon commented 2 years ago

From my understanding Roesetta is required to get some functionality. Would be nice to have a native binary.

The Remote Desktop feature does not work at all on M1.

Ylianst commented 2 years ago

MeshCentral has a native Apple Silicon agent. When you first download the agent, you get a universal binary with both x86 and Apple Silicon in the same executable. When the agent is updated later (when needed), MeshCentral will serve the exact binary (x86 or Apple Silicon). You can see the blog on this here.

bbrendon commented 2 years ago

Ahh. Then it's just the Remote Desktop that doesn't work.

This appears but even if you enable screen recording it still doesn't work.

image
Ylianst commented 2 years ago

Can you indicate exactly what version of macOS and what device are you using?

bbrendon commented 2 years ago

M1 Pro 14. version 12.5.1

krayon007 commented 2 years ago

Interesting. My M1 Mac is running 11.0.1, and it works with the arm binary. Have you tried deleting all the permissions in security center, and then retrying to grant the permission?

bbrendon commented 2 years ago

Have you tried deleting all the permissions in security center, and then retrying to grant the permission?

How do you do that? A lot of clicking or is there a plist file or something to delete?

ghost commented 2 years ago

Hello, this is the same problem we have here, https://github.com/Ylianst/MeshCentral/issues/3397 Any updates on this? Thanks!

bbrendon commented 2 years ago

I think this issue is related to how the agent is installed. If you install it with the mpkg file, then it will not work. If you install it with the meshagent installer using the GUI, it works? Maybe. Haven't fully tested.

krayon007 commented 2 years ago

That is interesting. I'll do some testing with different installation methods. I typically mostly use the binary installer.

openncomp commented 1 year ago

Today I installed the agent on mac OS 12.4 via the WEB GUI and still couldn't access remote desktop management. A request for rights appeared on the PC. When using a remote mouse, I can see the cursor moving on the PC, but the remote desktop does not allow me to click anything. Also, what is happening on the remote desktop is not displayed if something is opened locally on the PC.

Current Core: Aug 22 2022, 797326018
Agent Time: 2022-10-11 10:58:50.087+03:00.
User Rights: 0xffffffff.
Platform: darwin.
Capabilities: 15.
Server URL: wss://my.mesh.com:443/agent.ashx.
OS: macOS 12.4.
Modules: linux-dhcp, monitor-border, sysinfo, util-agentlog, wifi-scanner-windows, wifi-scanner, filedist.
Server Connection: true, State: 1.
dinger1986 commented 1 year ago

Have you set the permissions in system preferences for screen recording and accessibility?

Also is it M1 or Intel?

bbrendon commented 1 year ago

as long as you don't use the mpkg version, this works. I'm closing it.

superbam commented 1 year ago

The problem with not using the mpkg version, and the reason I opened this, is that it is difficult to install the universal version due to Apple flagging it as unsigned. It can be done, but you first have to open it from Finder and allow the installer to run. Installing from the terminal is way easier with the mpkg version and would make it easier to deploy Mesh on MacOS using Intune. I get that there is a work around for this but the work around is not command line friendly.

On Dec 8, 2022, at 7:22 PM, bbrendon @.***> wrote:



as long as you don't use the mpkg version, this works. I'm closing it.

— Reply to this email directly, view it on GitHubhttps://github.com/Ylianst/MeshCentral/issues/4443#issuecomment-1343712103, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AJBHIW5UTTY5Y5ETS3MI7S3WMKCTPANCNFSM57QW3CNA. You are receiving this because you are subscribed to this thread.Message ID: @.***>

ottosman commented 1 year ago

I've the same issue here and due to your comments @bbrendon the problem could be solved as downloanding from terminal package installer but my issue is i've customized the system and i don't know how to provide terminal commands for each of my device groups can you give a hand? (i'm also new with macOs mysystem is macos Ventura m1)

gnius commented 1 year ago

I have the same issue. Also, after a few hours I lose the ability to view the desktop or access terminal and just see the system as being on, with no remote connection options. Would love some advice on how to troubleshoot.

blaine07 commented 1 year ago

I hate to chime in; I don't know what I can provide that would be more helpful but after I figured out in "Security and Privacy" under "Recording" tab I had to delete "meshagent_osx64" then have it prompt for access one more time I can get screen to display properly. I now can not get remote MAC Screen to accept any input - I click/I type and nothing.

Any ideas?

silversword411 commented 1 year ago

after a few hours I lose the ability to view the desktop or access terminal and just see the system as being on, with no remote connection options.

Restart the MeshCentral server. Can you then connect?

silversword411 commented 1 year ago

I now can not get remote MAC Screen to accept any input - I click/I type and nothing.

Any ideas?

Sounds like accessibility permissions haven't been manually granted after install?

blaine07 commented 1 year ago

I now can not get remote MAC Screen to accept any input - I click/I type and nothing. Any ideas?

Sounds like accessibility permissions haven't been manually granted after install?

It was a permissions issue. I had had them all granted but ended up unchcecking and delting ALL the permissions and starting over. It DOES work now; rather well actually, except I can NOT access my second screen on my Mac Mini. Making progress though however.

jonrupell commented 1 year ago

Has this issue been corrected yet? I am also having this same issue. Cannot figure out how to fix it.

ottosman commented 1 year ago

@jonrupell no it has not been fixed , you have to follow the flow and let the macos be free. Macos is a black mystery box and apple devs does not want us to open it..

b-hal commented 9 months ago

is fixed, see here: https://github.com/Ylianst/MeshCentral/issues/3397#issuecomment-1198706281

si458 commented 7 months ago

hey gang, just looking at all the mac issues now as somebody kindly donated an M1 to fix bugs! has anybody found a way to actually get the remote control working on M1 12.7.2 ? ive tried the mpkg and the binarys and they just dont wanna work? if i can find a way to get it working i can look into why it needs to be done that way

rallisf1 commented 7 months ago

I don't have a M1 to test but I know that Tactical RMM's agent works. So the problem is with how the agent makes the system calls on newer macos, not with the agent-server communication.

P.S. For anyone who doesn't know Tactical RMM uses meshcentral for remote connections but they ship their own agent which includes features for their RMM.

P.S.2. Maybe it is time to migrate the meshcentral agent to a more modern language in order to have more devs aboard.

si458 commented 7 months ago

i think ive found the issue, it appears the universal binarys arent playing nicely with screen recording.

so ive added the option under the 'binary install' so you can download either universal, x64, or arm binarys now for osx! if you download the arm binary and install, it works no problems!

im still not quite got the mpkg working yet but baby steps...

p.s yes i have rosetta installed cuz i installed the xcode-select and developer tools which needed it installed anyways

si458 commented 7 months ago

update. ive found a work around fix for others if intrested in trying install the binary as universal, then BEFORE you connect to the device the first time, run agentupdate from the console tab this will force the meshagent to redownload the arm version and use that instead of the universal one then when you connect, it will ask for screen record permission, so give it and it works! you sadly still have to disconnect and then reconnect for it to ask for control permission too, but working on a fix for that!

MDanihy commented 3 months ago

This is still not working. I have an M3 Mac, and while it lets me connect, I get a blank screen. All the fixes reported here has really messed up my install to the point the Mac doesn't even ask for permission anymore. Files and Terminal work fine, it is just the screen desktop that isn't working.

silversword411 commented 3 months ago

I have an M3 Mac, and while it lets me connect,

Works for me when you properly grant permissions to the agent. This is a requirement because of Apple's restrictive permission controls.

https://docs.tacticalrmm.com/install_agent/#mac-agent-permissions

MDanihy commented 2 months ago

Still not working correctly. If I run sudo ./mscentral -update, it will show as online again. After a reboot it is dead again until I run -update.

si458 commented 2 months ago

@MDanihy the issue is because of the launchagent/launchdaemons have the same name! Will update comment/post when I find link to what u need to do to fix it

Edit. Link to fix https://github.com/Ylianst/MeshAgent/issues/161#issuecomment-2002163963

MDanihy commented 2 months ago

@MDanihy the issue is because of the launchagent/launchdaemons have the same name! Will update comment/post when I find link to what u need to do to fix it

Edit. Link to fix Ylianst/MeshAgent#161 (comment)

Does not work. In fact, I am having issues with all my Macs. I have one that only receives input if you hold the shift key. The M3 Mac is a blank screen, never asking for security changes, if I run the installer as an update, it works again, until a reboot.

si458 commented 2 months ago

@MDanihy Yes, there is a bug where the installer/executables where not asking u for permissions, so u have to add them manually https://ylianst.github.io/MeshCentral/meshcentral/faq/#mac-clients

This has been fixed already. We just need to build new agents and then get people to test them before we update the repo with the new agents and everyone's devices get autoupdated

MDanihy commented 2 months ago

@MDanihy Yes, there is a bug where the installer/executables where not asking u for permissions, so u have to add them manually https://ylianst.github.io/MeshCentral/meshcentral/faq/#mac-clients

This has been fixed already. We just need to build new agents and then get people to test them before we update the repo with the new agents and everyone's devices get autoupdated

Still doesn't explain why it acts weird on my other Mac, I cannot click on some menu items, I have to hold the shift key to type anything. A reboot allows me to type again, but there are some programs that do not react to clicks. The App store for one doesn't allow me to click on my name or categories.

It seems to work perfectly fine on the older OSs though. Anything from Catalina and newer has problems.

si458 commented 2 months ago

@MDanihy, yes, I do agree that is a weird bug?

Sadly, development is slow because there are no longer full-time people working on the project and no big sponsorships

I myself only help out part-time, and people kindly sponsor me to help the community out and try keep the project alive as best i can!

If u are happy to donate a Mac to myself that's having the issue, I'd be happy to look into it for you!

I do have an M1 Mac mini, which was kindly donated, but I don't see any of the issues you are having?

MDanihy commented 2 months ago

Yep, Just rebooted a Mac Mini Catalina and nothing but a black screen. I may just give up on MeshCentral, it was a fun toy for a while but we cannot continue to use it as it is right now. Good luck trying to keep up with the Apple changes.

si458 commented 2 months ago

@MDanihy if u open up a new issue with all the details, I can try and have a look at it. As explained, I have an m1 mac mini, but I also have an old macbook pro which runs catalina and again no issues there but I might be missing something

MDanihy commented 2 months ago

This is all from remote from my office to my house for the Mac Mini Catalina. The M3 is in the office, but that one just keeps not working with MeshCentral. The M3 is different from the M1, so you guys may have to wait till someone gets one to test. There were quite a few programs that do not operate correctly on the M3 platform. I have an Air with an M2 that I will try and test with as well, but I am not holding my breath.

silversword411 commented 2 months ago

There's hardware: intel (x86) and arm (M1/2/3/4)

There's an OS: Catalina (old), Big Sur (and newer) Pretty significant changes on OS between Catalina and Big Sur If you want to diagnose you need to know hardware and OS to know what to test against.

Generally speaking any arm hardware with Big Sur+ is going to work the same. If you're having issues, it's usually permissions/launch bug with arm+big sur or later.

https://en.wikipedia.org/wiki/MacOS_version_history

MDanihy commented 2 months ago

More info, you can get it to work following the instruction here, once the screen saver goes into effect MeshCentral goes down.

si458 commented 2 months ago

@MDanihy we have released 1.1.25 which includes a fix in the mpkg to hopefully install correctly! the fix for the permissions still isnt included tho, so you should get one permission, which u allow, then when you connect over n over you will get multiple permission prompts to allow

si458 commented 2 months ago

@MDanihy also you might have to run agentupdate after you install the agent on arm macs to make sure it redownloads the ARM version of the app to work correctly :)