On an email thread I was participating in today, Caleb Ruth pointed out an easy fix to a common inconvenience when administering FileMaker Server from the cmd line on Windows. Last I looked, the FileMaker Server documentation did not cover updating the system environment PATH variable with the FileMaker Server path, but arguably it should. So perhaps at this point you’re saying, “huh?” Bottom line is, there’s an easy way and a hard way to call fmsadmin, and the hard way is the default. Which would you rather type each time you need to invoke the tool?
C:Program FilesFileMakerFileMaker Serverfmsadmin
fmsadmin: the hard way
fmsadmin: the easy way
So how do you set it up for the easy way?
You have to add the path to FileMaker Server to your environment path variable. On one of our servers running Microsoft Windows Server 2003 Standard Edition with PHP on it, the default values in the PATH variable were as follows:
C:PHP;%SystemRoot%system32;%SystemRoot%;%SystemRoot%System32WbemAs you can see, it doesn’t include “C:Program FilesFileMakerFileMaker Server”. Fortunately that’s easily remedied. The field for the variables is very small, so I don’t recommend trying to edit it directly. Copy the existing value first and keep it in a safe place in case anything goes wrong and you need to restore the previous values. Then all you need to do is add the path to FileMaker Server in a text editor and paste it back in. On our example system here, that path is the default location for FileMaker Server, but make sure you adjust accordingly if you need to. The paths are separated by semi-colons. Since FileMaker Server has spaces in the path, enclose it in quotes:
C:Program FilesFileMakerFileMaker Server";C:PHP;%SystemRoot%system32;%SystemRoot%;%SystemRoot%System32Wbem
Note: After you save this change, you will have to quit any instances of cmd.exe as any currently running instances will still have the old path variable.
So how to edit the path variable?
My Computer -> Properties -> Advanced -> Environment Variables -> System Variables -> Path -> Edit