krypted.com

Tiny Deathstars of Foulness

SSH allows administrators to connect to another computer using a secure shell, or command line environment. ARD (Apple Remote Desktop) allows screen sharing, remote scripts and other administrative goodness. You can also connect to a server using the Server app running on a client computer. To enable any or all of these, open the Server app (Server 5.4 for High Sierra), click on the name of the server, click the Settings tab and then click on the checkbox for what you’d like to enter.

 
All of these can be enabled and managed from the command line as well. The traditional way to enable Apple Remote Desktop is using the kickstart command. But there’s a simpler way in macOS Server 5.4 for High Sierra. To do so, use the serveradmin command. To enable ARD using the serveradmin command, use the settings option, with info:enableARD to set the payload to yes:

sudo serveradmin settings info:enableARD = yes

Once run, open System Preferences and click on Sharing. The Remote Management box is then checked and the local administrative user has access to ARD into the host.


When you enable, you’ll be prompted for what permissions to provide access to:


There are also a few other commands that can be used to control settings. To enable SSH for administrators:

sudo serveradmin settings info:enableSSH = yes

When you enable SSH from the serveradmin command you will not see any additional checkboxes in the Sharing System Preferences; however, you will see the box checked in the Server app. To enable SNMP:

sudo serveradmin settings info:enableSNMP = yes

Once SNMP is enabled, use the /usr/bin/snmpconf interactive command line environment to configure SNMP so you can manage traps and other objects necessary. Note: You can’t have snmpd running while you configure SNMPv3. Once SNMPv3 is configured snmpd can be run.  To allow other computers to use the Server app to connect to the server, use the info:enableRemoteAdministration key from serveradmin:

sudo serveradmin settings info:enableRemoteAdministration = yes

To enable the dedication of resources to Server apps (aka Server Performance Mode):

sudo serveradmin settings info:enableServerPerformanceMode = yes

September 26th, 2017

Posted In: Mac OS X Server

Tags: , , , , , , ,

One of those annoying little things is when you ARD into a system and the Dock is nowhere to be seen. Why do we (or should I say they) autohide Docks on servers? Either way, when I ARD into a box and I don’t see a Dock I have this line saved as a Template: defaults write com.apple.dock autohide -bool false; killall Dock By writing an autohide key that is false into com.apple.dock for the currently logged in user, I don’t have to deal with the Dock disappearing any more. You need to kill the Dock and let it respawn, thus the killall as well. Once I’m done working with the box, I can show the dock again: defaults write com.apple.dock autohide -bool true; killall Dock Or, instead of all this, as diskutant once pointed out, just use Command-Option-d when you ARD in and then again when you log out!

August 30th, 2012

Posted In: Mac OS X

Tags: , , , , , , ,

The traditional way to enable Apple Remote Desktop is using the kickstart command. But there’s a simpler way in OS X Mountain Lion Server. To do so, use the serveradmin command. To enable ARD using the serveradmin command, use the settings option, with info:enableARD to set the payload to yes: sudo serveradmin settings info:enableARD = yes Once run, open System Preferences and click on Sharing. The Remote Management box is then checked and the local administrative user has access to ARD into the host. The Server app will also have the “Enable screen sharing and remote management” option checked. There are also a few other commands that can be used to control settings. To enable SSH for administrators: sudo serveradmin settings info:enableSSH = yes To enable SNMP: sudo serveradmin settings info:enableSNMP = yes To enable the dedication of resources to Server apps (aka Server Performance Mode): sudo serveradmin settings info:enableServerPerformanceMode = yes

August 14th, 2012

Posted In: Mac OS X Server, Mac Security, Mass Deployment

Tags: , , , , , , , , , ,

Let’s face it, connecting to Windows Servers is a must for many of us. And some of us want to do so programatically. I did look at populating the CoRD database in a previous article. But now, luckily CoRD has recently introduced a command line interface for managing just these types of connections on the fly as well. And, it is very straight forward. There are two ways to call CoRD from the command line. The first is similar to how we handled VNC in an earlier article. Simply leverage the open command and call the URL with a rdp in the beginning. For example, if you want to open a connection to a server called windows.krypted.com you would use the following command: open rdp://windows.krypted.com As with VNC you can also inject he user name and the password as well. To do so insert the username after the rdp:// and with an @ before the domain or IP. And to inject the password follow the username with a : and then the password followed by the @. For example, if our username were daneel and our password were seldon then the command would be: open rdp://daneel:seldon@windows.krypted.com There are other options as well, which you can find at the CoRD Wiki. You can also connect by calling the CoRD command, which is located in the /Applications/CoRD.app/Contents/MacOS directory. The CoRD command then has the following options: host – define the IP address or host name of the computer you are connecting to port – if a custom port (not 3389) is used then use that to connect to the computer u – define a username p – define a password d – Windows domain name a – set screen depth to 8, 16, 24 or 32 width – set the width of the resultant window height – set the height of the resultant window So if you would like to connect to windows.krypted.com with the same user and password as before, but now with a custom port of 3390 you would use the following command: /Applications/CoRD.app/Contents/MacOS/CoRD -host windows.krypted.com -port 3390 -u daneel -p seldon I guess next I’m going to have to build a Dashboard widget to fire up a connection on the fly… 😉

February 1st, 2010

Posted In: Mac OS X, Windows Server

Tags: , , , , , , , , ,

You can send Command keys (aka – Open Apple and Closed Apple) through Apple Remote Desktop (ARD), or not send the Command keys through ARD. Your call:
defaults write com.apple.RemoteDesktop DoNotSendSystemKeys 1
P.S. – Of course these are short, I’m on the road. Sorry for brevity but typing posts on the iPhone is not all it’s cracked up to be…

December 13th, 2009

Posted In: Mac OS X, Mac OS X Server, Mass Deployment

Tags: , , , ,

The following command can be used to disable reverse IP address lookups from within Remote Desktop:
defaults write com.apple.RemoteDesktop DisableReverseIPLookup -bool yes

October 1st, 2006

Posted In: Mac OS X, Mass Deployment

Tags: , , , ,