There is great power in the command line, especially with FileMaker Server. There are things you can't do easily
Remember that old movie War Games? A high school student, David Lightman hacks into The Pentagon and manages to find an AI that has gone bad and is about to destroy the human race. Much of what you see in the movie is David interacting with the computer via the command line. Now, the command line interface today hasn’t changed much since those days, if at all. Here’s what it looks like on windows:
At the end of the movie, the AI tries to kill everyone, so I get it, the command line can be scary. You’re not sure what exactly to do or type and there are no
Nonetheless, FileMaker Pro includes a great help
How do I find the command line?
If you’re like me, you can never remember where the command line is. So I tend to use the search tools available on the different platforms. On Windows, type “Command” into the search box – there are many places to do that – and you should see a program called “Command Prompt.” Once you have it open, pin it to the
On the Mac, open up your spotlight search and type in “Terminal” and you’ll get the Mac’s version of the command line interface.
Once you have the program up and running, it should look like this:
Now that you have the command line open, what do you do?
The way the command line works is you type something in, hit enter and then if whatever you typed was correct, something should happen. So, for example, if you type in "
Congratulations!! You just executed your first command line command. How do you feel? Is everyone still alive? Yes. Is your
Notice – for Filemaker server, EVERY single command starts out with “
The very next command you should try is "
This is a list of the commands you can run from the command line. You can see how this can be powerful. You can start the server, stop the server, start or stop JUST ONE component of the server, get a list of clients, etc. Lots of options. To find out what each command does, you can keep using the HELP command. Try "
What this should do is show you MORE information about the specific command you are looking at. Your screen should look like this:
It basically breaks down what your command should look like, and what OPTIONS you can specify for each command. So, for example, if you wanted to force a restart of the whole database server, you would type "
One thing I use this for on occasion is to restart the Admin Server. For one reason or another, sometimes the Admin Server can stop working. You know the database server is still running, because people are using the databases and you can still see the server when you click “open remote” on your client version of FileMaker Pro. But when you try to open up the Admin Console, nothing happens. Like with many things in the technology world, by simply restarting it you can sometimes fix something that has gone awry. So one thing I will try, instead of restarting the entire server, is to simply restart the Admin Server.
What this will do is simply restart the Admin Server process – the thing that manages the Admin Console. If you’re logged into the Admin Console, it will boot you out and make you log in again.
Another thing you can do is close and re-open databases, without having to log into the Admin console. Admittedly, it’s pretty easy to do this through the Admin Console, but it’s always good to have another way of doing things if you need to. As an example, I made 4 copies of the FMServer_Sample database on my local development
Now if I want to close them with the command line, I simply type "
It even helpfully tells you it’s closing them as it goes along and confirms when they are closed. And this is what it looks like after on the admin console.
Command Line Power
And that, dear readers, is where I’m going to leave you. I could tell you how to open the files back up with the command line – but where is the fun in that? You should be able to figure out how to do that on your own from here. Don’t be afraid! You can do it!