[UNIX][Linux]

Starting an MFT agent at UNIX and Linux system startup

A Managed File Transfer Agent can be configured to start at system startup on UNIX. When you log off a UNIX system your agent continues running and can receive file transfers.

When you have created and configured an agent using one of these Managed File Transfer commands; fteCreateAgent, fteCreateCDAgent, or fteCreateBridgeAgent, you can configure it to start automatically during a reboot on UNIX machines by using a script file that simply executes:

su -l mqmft_user -c mq_install_root/bin/fteStartAgent agent_name
Where mq_install_root is the root directory of the required Managed File Transfer installation, the default is: /opt/mqm and agent_name is the name of the Managed File Transfer Agent to be started. The usage of this script file varies depending on the specific UNIX operating system.
[Solaris]

Solaris

On Solaris, follow these steps:
  1. Run the following command, and keep track of the path returned:
    which sh
    For example, the path might be /usr/bin/sh
  2. As the system root user ID, create your own /etc/init.d/startmqmft file.
  3. Edit this file and add the script lines to it, using the returned path from step 1 as the first line in the script:
    #!/usr/bin/sh
    su mqmft_user mq_install_root/bin/fteStartAgent agent_name
  4. Make the file executable, for example:
    chmod 755 /etc/init.d/startmqmft
  5. Symlink the file to the rc3.d directory:
    ln -s /etc/init.d/startmqmft /etc/rc3.d/S98startmqmft
    
    The prefix S means default state Started for Solaris. 98 is a sequence number. The suffix is the filename from init.d
[Linux]

Linux

For Linux® systems there are multiple ways that you can start applications during the system boot process. In general, consider following these steps:
  1. Create a file called /etc/rc.mqmft with contents:
    #!/bin/sh
    su -l mqmft_user"-c mq_install_root/bin/fteStartAgent agent_name"
    Where mqmft_user is the user ID under which the agent process is to run. This user ID must be a member of the mqm group.
  2. Make the file executable, for example:
    chmod 755 /etc/rc.mqmft 
  3. Next add the following line to /etc/inittab:
    mqmft:5:boot:/etc/rc.mqmft

Other ways to start an agent during boot on Linux include adding the script lines to the /etc/rc.d/rc.local file, or on Linux SuSe, adding the script lines to the /etc/init.d/boot.local file. You should select the method that works best for your environment. Here is some more information on other ways to start an agent during startup on specific Linux distributions that are supported:

SLES 10 and 11
For SUSE Linux Enterprise Server (SLES) 10 and 11 systems, follow these steps:
  1. As the system root user ID, create your own /etc/init.d/rc.rclocal file.
  2. Add the following lines to the rc.rclocal file:
    #!/bin/sh
    ### BEGIN INIT INFO
    # Provides: rc.rclocal
    # Required-Start: $network $syslog
    # Required-Stop: $network $syslog
    # Default-Stop: 0 1 2 6
    # Description: MQMFT agent startup
    ### END INIT INFO
    su -l mqmft_user"-c mq_install_root/bin/fteStartAgent agent_name"
  3. Run the following commands:
    chmod 755 rc.rclocal
    
    chkconfig --add rc.rclocal