Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

I'm trying to get FMServer 11 to execute SYSTEM SCRIPTS on Mac OS X 10.6.3.

In the first instance I can get simple commands to execute, such as 'ls' without problem, but what I really want to do is fire up a separate database and use an installed FileMaker Pro 11 to "save records as PDF" - this is an option not available within FMServer.

My simple scripts is:

#!/bin/bash

open '/users/stagebase/documents/file.fp7'

which execute correctly when initiated from a terminal session started from the Finder.

I have applied the changes to the /etc/sudoers file as recommended by the FMS Admin Console help, so that the script can execute under a local system account. The changes are:

Host_Alias FMSHOST = yourhostname

Defaults:fmserver targetpw, timestamp_timeout=0, passwd_tries=1

fmserver FMSHOST = (ALL) /Library/FileMaker Server/Data/Scripts/*, /bin/kill

and I substituted "yourhostname" with the real hostnmame as determined from the hostname command.

When the script is executed the following log entries are generated:

2010-06-09 09:51:00 Server Events Information Schedule "BashTest" running.

2010-06-09 09:51:00 Server Events Information Schedule "BashTest" has started system script "BashTest" with process ID 27732 using account "stagebase".

2010-06-09 09:51:00 Server Events Information Schedule "BashTest" aborted; aborted by user.

What's wrong with my setup? Is this even possible?

Many thanks.

Why not use chron for this?

A real user would have to logged-in for a fmp database to be opened.

  • Author

Thanks Vaughan

I have my FMServer permanently logged in so it's not a problem to use cron - but still I ask, why won't the system script execute to completion?

I should have mentioned that when I said the 'ls' command executed I cannot of course visualise it, but the FM log said all okay. When I tried 'ls > file' I get a failure.

  • Author

Any one else with an idea?

did you specify alternate credentials for your test "ls" script? If not then the "> file" would file if it is asked to produce the file somewhere that the fmsadmin user has no write privileges to. You can try specifying the FMS documents folder in that case.

As to what you're trying to achieve in general: I doubt it will work. It's really not a server's role to invoke user UI applications on its own box. And leaving your machine with a user logged in a bad idea from the security perspective.

You're probably better off with a dedicated FMP robot machine, or a CWP solution that can use a PDF library.

  • 1 month later...

I tumble on this thread looking for help in a Perl script.

Does someone know how to mount a smb folder with the fmserver user? The smb folder is on a Windows server linked to an active directory.

I tested my script using an account in the AD, but since fmserver is not member of the AD, the script doesn't work.

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.