Submit a ticketCall us

Have You Auto Renewed? If not, you're missing out.
The SolarWinds Renewal Program comes with a host of benefits including the most recent product updates, 24/7 technical support, virtual instructor-led training and more. Experience all of this with the convenience of Auto Renewal, and never worry about missing any of these great benefits. Learn More.

Home > Success Center > Serv-U Managed File Transfer & Serv-U FTP Server > Serv-U behavior in passing command line parameters to external applications

Serv-U behavior in passing command line parameters to external applications

Table of contents

Updated April 17, 2017

Overview

This article explains how configured parameters are passed to external applications in Serv-U 15.1. In previous versions, Serv-U events on Linux that triggered an external application passed the configured command line parameters to the external application as a single argument. Because of this behavior, an external shell script only works if the script is modified so that it could parse the parameters correctly.

Environment

Serv-U 15.1

Detail

Note: This only affects Linux events that are configured this way.

 

Serv-U 15.1 provides a fix for the original issue and the configured parameters are now passed to external applications separately. However, if you previously used a workaround in your scripts, the scripts need to be updated or the event parameters modified for them to work in Serv-U 15.1. If the scripts are not modified, the events triggering external applications with multiple parameters that worked before the upgrade will now be missing parameters in the external application.

 

The behavior is demonstrated in the following examples using this test script:

#!/bin/bash
# printout the variables passed into us
echo var1 is "$1", var2 is "$2", var3 is "$3" > ./test.log
# exit the script
exit 

 

The following image shows a Serv-U event where the command line parameters are enclosed within quotation marks.

"one~two~three"

In this case, only one parameter is passed to the script, and running the script returns the following result: var1 is "one~two~three", var2 is empty, var3 is empty. This was the behavior before Serv-U 15.1.

 

The following image shows a Serv-U event configured with command line parameters separated by spaces.

one two three

Each parameter is passed to the script separately, and running the script returns the following result: var1 is one, var2 is two, var3 is three. This is the current Serv-U behavior.

 

 

Last modified

Tags

Classifications

Public