GoAnywhere MFT Linux: Configure as a Service on Systemd

If you have a new question you’d like our support staff to post a response to, please visit our customer community, Data Security Insiders, to pose the question in our Discussion Boards. We have a thread “Ask Our Tech Experts” that our support team monitors on a regular basis, or you can start a new discussion where other GoAnywhere users and support staff can weigh in. Log in or create your new account at https://insiders.helpsystems.com/sign_in.

If you need an immediate response, please create a support ticket or contact our support team by email at [email protected].
2 posts Page 1 of 1


Posts: 4
Joined: Thu Dec 01, 2016 10:34 am

Post by dbeckman » Thu Apr 06, 2017 3:51 pm
The Linux version of GoAnywhere MFT is packaged as a shell script. The installation manual leaves you with a terse instruction:
You can setup GoAnywhere so it starts automatically when the Linux system is booted. Please refer to your operating system manual for more details on setting up auto-start services. You can execute goanywhere.sh from your startup scripts.
You're then left to your own devices. I figured out how to setup a service unit file for automatically starting GoAnywhere MFT 5.4.3 at system startup on a RHEL7 OS. This will certainly work on Centos 7 and Oracle Linux 7 systems, and should work (with minor modifications?) on any distribution using Systemd.
There is probably room for improvement and I'd love to hear any suggestions, but this has worked well for me.

Create your Systemd unit file. (The name is arbitrary and can be anything ending with .service.):
Code: Select all
touch /etc/systemd/system/goanywhere.service
Apply correct permissions:
Code: Select all
chmod 664 /etc/systemd/system/goanywhere.service
Edit /etc/systemd/system/goanywhere.service as follows:
Code: Select all
Description=GoAnywhere Service

# Modify user/group according to whichever user you have setup to run GoAnywhere MFT
# My executable is a shell rather than the actual shell script, goanywhere.sh.
# This is a workaround for the way goanywhere.sh is written, expecting to be run from the installation directory,
# using a relative path. The executable in a systemd unit file has to include an absolute path. I wanted to avoid
# modifying the shell script to make unit file upgrade-friendly. 
ExecStart=/bin/sh goanywhere.sh start
ExecStop=/bin/sh goanywhere.sh stop

# goanywhere.sh is just starting a Tomcat application; this gives you correct exit status

Notify systemd that a new unit file exists by running this:
Code: Select all
systemctl daemon-reload
(You also need to run this after making subsequent changes to the file.)

Enable automatic startup:
Code: Select all
systemctl enable goanywhere.service
Start the service:
Code: Select all
systemctl start goanywhere.service
Check status:
Code: Select all
systemctl status goanywhere.service


Posts: 1
Joined: Mon Jan 29, 2018 6:56 am

Post by piotr » Thu Feb 01, 2018 9:26 am
On Ubuntu 16.04 LTS it also required to enable tomcat.pid for correct shutdown sequence to be triggered. The service Start sequence worked out-of-box.
2 posts Page 1 of 1