COMPUTERNAME Environment Variable Under Mac OS X

We use ScreenConnect to provide remote support for our users. It has clients for Windows and Mac, which you can pre-install on the machines. When you create the clients, you can specify the client to retrieve COMPUTERNAME when run. That way, you can easily identify the machine when you work with ScreenConnect’s Host page.

While this works pretty well for Windows machines, I was never able to get the Mac clients to work. I think the reason is that there is no COMPUTERNAME environment variable under OS X. I tried to contact ScreenConnect’s support, but they were not helpful. They only referred me to a Mac technical article that did not tell me what to do.

Later, I learned how to set environment variables under Mac OS X by reading this article. I followed the instructions to edit this file /etc/launchd.conf and added this line.

setenv COMPUTERNAME mycomputer

After I restarted the machine and ran ScreenConnect client, I was able to see the computer name shown under the ScreenConnect’s  Host page.

This post may contain affiliated links. When you click on the link and purchase a product, we receive a small commision to keep us running. Thanks.

Be the first to comment

Leave a Reply