FileZilla Server2: Install Options

From The Uniform Server Wiki
Jump to navigation Jump to search
Uniform Server 4.1-Mona
FileZilla FTPd (Server).

Install options and design

FileZilla plugin has three-installation options these correspond to Uniform Server's install options.

This page details each option and explains restrictions imposed on FileZilla in basic and disk-root mode.

The architecture is flexible allowing it to be tailored to your own requirements user modifications are explained in each section.

Basic (Portable)

A default installation adds the following batch files to folder UniServer providing independent control of FileZilla Server.

fz_start.bat - Start FileZilla server - Runs file UniServer\udrive\filezilla_server\basic\fz_basic_start.bat
fz_stop.bat - Stop FileZilla server – Runs file udrive\filezilla_server\filezilla_server_portable\zilla_stop.bat
fz_admin.bat – Start FileZilla admin – Runs file udrive\filezilla_server\filezilla_server_portable\zilla_admin.bat

Each of the above files runs a single line of code.

Top

basic - Folder

Contents of folder UniServer\udrive\filezilla_server\basic provides support files for FileZilla FTPd “basic-mode” (portable) operation.

fz_basic_start.bat Run by “fz_start.bat”

For portability a virtual drive is created this file checks its existence.

If the drive does not exist user is informed to start Uniform server and to run the script again.

On detecting a virtual drives existence the drive letter is passed as a parameter to change_drive.pl on returning FileZilla is started.

change_drive.pl This script receives a drive letter as parameter and replaces all drive letters in file

UniServer\udrive\filezilla_server\filezilla_server_portable\FileZilla Server.xml

Server_Start.bat Runs both Uniform Server and FileZilla Server - Replacement file
Stop.bat Stops both Uniform Server and FileZilla Server - Replacement file

Top

Start and stop both servers - Combined batch files

The two replacement files (Server_Start.bat and Stop.bat) provide single file control for starting and stopping both servers.

  1. Copy Server_Start.bat to folder UniServer overwrites original
  2. Copy Stop.bat to folder UniServer overwrites original
  3. Delete UniServer\fz_start.bat
  4. Delete UniServer\fz_stop.bat

Note: UniController is independent and does not use the batch files hence becomes redundant (cannot start or stop both servers). If you wish to use UniController you cannot use the replacement files.

Top

FileZilla restrictions

FileZilla allows you to assign any folder on any disk to a user. In addition when generating a FileZilla server certificate it can be saved to any location. This freedom is in conflict with portability hence the need to restrict paths to the virtual drive created.

The above explains why Uniform Server must be running before FileZilla. The drive letter assigned by UniServer is the first free drive available this can vary, file change_drive.pl updates FileZilla’s configuration file before starting the server.

Hence to maintain portability:

  1. All folders must be assigned from the virtual drive
  2. FileZilla server certificate must be saved to a folder on the virtual drive.

Note: This is the only option where you must run Uniform Server before using FileZilla Top

Disk Root

A default installation adds the following batch files to folder UniServer\udrive providing independent control of FileZilla Server.

fz_start_usb.bat - Start FileZilla server - Runs file \filezilla_server\disk_root\fz_disk_root_start.bat
fz_stop_usb.bat - Stop FileZilla server – Runs file \filezilla_server\filezilla_server_portable\zilla_stop.bat
fz_admin_usb.bat – Start FileZilla admin – Runs file \filezilla_server\filezilla_server_portable\zilla_admin.bat

Each of the above files runs a single line of code.

Top

disk_root - Folder

Contents of folder UniServer\udrive\filezilla_server\disk_root provides support files for FileZilla FTPd “disk-root mode” (portable/fixed) operation.

fz_disk_root_start.bat Run by “fz_start_usb.bat”

Picks-up the current drive letter. Reminds user of FileZilla restrictions.

Drive letter is passed as a parameter to change_drive.pl on returning FileZilla is started.

change_drive.pl This script receives a drive letter as parameter and replaces all drive letters in file

\filezilla_server\filezilla_server_portable\FileZilla Server.xml

usb_server_start.bat Runs both Uniform Server and FileZilla Server - Replacement file
usb_server_stop.bat Stops both Uniform Server and FileZilla Server - Replacement file

Top

Start and stop both servers - Combined batch files

The two replacement files (usb_server_start.bat and usb_server_stop.bat) provide single file control for starting and stopping both servers.

  1. Copy Server_usb_server_start.bat to folder UniServer\udrive overwrites original
  2. Copy usb_server_stop.bat to folder UniServer\udrive overwrites original
  3. Delete UniServer\fz_start_usb.bat
  4. Delete UniServer\fz_stop_usb.bat

Note: UniController is independent and does not use the batch files hence becomes redundant (cannot start or stop both servers). If you wish to use UniController you cannot use the replacement files.

Top

FileZilla restrictions

FileZilla allows you to assign any folder on any disk to a user. In addition when generating a FileZilla server certificate it can be saved to any location. This freedom is in conflict with portability hence the need to restrict paths to the current drive (where the servers are installed).

The drive letter detected can vary (moving the servers to a different hard drive or letter assigned to USB memory stick), file change_drive.pl updates FileZilla’s configuration file before starting the server.

Hence to maintain portability:

  1. All folders must be assigned from the current drive
  2. FileZilla server certificate must be saved to a folder on the current drive.

Top

Remove restrictions - Hard drive

If you intend to permanently install servers on a disk-root the above restrictions are draconian and limit the functionality of FileZilla.

To remove these restrictions edit the following file: UniServer\udrive\filezilla_server\disk_root\fz_disk_root_start.bat Locate this line:

rem goto :END

Remove the “rem” as shown below

goto :END

This bypasses FileZilla’s configuration file update and removes the nag screen. You can now assign any file on any drive to a user in addition save the certificate file to any folder of your choice.

Top

Run as a service

This process could have been automated however it is possible that Uniform Server has already been installed as a service and the default location changed. These unknowns make it difficult to automate hence a semi-automated and manual method are described. Use the one that best fits your current installation of Uniform Server.

Top

Clean install of UniServer

This method assumes a clean install of Uniform server (extracted to any folder) and FileZilla has been saved to folder UniServer and extracted ( see intro page).

  1. Navigate to folder UniServer\udrive\plugins\Services
  2. Double click on Run.bat – Installs Uniform Server as a service. All files are copied to folder c:\UniServer
  3. Navigate to folder c:\UniServer and delete these files:
    1. fz_start_usb.bat
    2. fz_stop_usb.bat
    3. fz_admin_usb.bat
  4. Navigate to folder C:\UniServer\filezilla_server and copy the three files to folder c:\UniServer
    1. fz_service_install.bat - Installs and runs FileZilla service
    2. fz_service_uninstall.bat – Stops and unintalls FileZilla service
    3. fz_service_admin.bat – Runs FileZilla admin.
  5. Note: Install.bat and Uninstall.bat installs/runs stops/unistalls UniServer respectively

The above along with Install.bat and Uninstall.bat provides separate control of UniServer and FileZilla.

Top

Combined services

Separate control of UniServer and FileZilla may be undesirable the two control files can be combined as follows:

  • Stop servers (run fz_service_uninstall.bat and Uninstall.bat)
  • Edit Install.bat Add the three lines just above "rem === Get ..." as shown below.
echo Installing FileZilla Service ...
start filezilla_server\filezilla_server_portable\zilla_service_start.bat
echo.

rem === Get Apache executable file name
  • Edit Uninstall.bat Add the three lines just below "pushd %~dp0" as shown below.
pushd %~dp0

echo.
echo Uninstalling FileZilla server
start filezilla_server\filezilla_server_portable\zilla_service_stop.bat

Delete files fz_service_install.bat and fz_service_uninstall.bat

Test:

  1. Run Install.bat - Installs/starts FileZilla and Installs/starts UniServer - Apanel displayed
  2. Run fz_service_admin.bat - Click OK - Logged on indicates correct operation
  3. Run Uninstall.bat Stops/Unistalls FileZilla server and Stops/Uninstalls Uniserver
  4. Note: FileZilla icon changes to a question mark. Error could not connect displayed. Close Admin

Top

UniServer already installed as service

If you wish to run FileZilla alongside an already installed Uniform Server service use the following method to install FileZilla service. (Assumes Uniform Server service was installed to default folder c:\UniServer)

  1. Save uniserver_filezilla_ftpd.exe to anyfolder
  2. Double click uniserver_filezilla_ftpd.exe – Extracts all folders and files
  3. Copy folder anyfolder\udrive\filezilla_server and its content to folder c:\UniServer
  4. Navigate to folder anyfolder\udrive\filezilla_server and copy the three files to folder c:\UniServer
    1. fz_service_install.bat - Installs and runs FileZilla service
    2. fz_service_uninstall.bat – Stops and unintalls FileZilla service
    3. fz_service_admin.bat – Runs FileZilla admin.
  5. If you wish to save space delete anyfolder

Top

Combined services - same as above

The two control files can be combined as explained above allowing both servers to be either installed or unistalled at the same time.

Top

Core – alternative

FileZilla FTPd is a server in its own right; the core contents of folder filezilla_server_portable were designed to be independent of Uniform Server.

Eextract the files as explained above and copy folder filezilla_server_portable to your preferred location and either run server as a standard program or service using the integral batch files.

Note: There are no restrictions you can assign any folder on any drive to a user. Server certificate can be as to any folder.

Top

Summary

I have shown in reality there are four installation options three associated with Uniform Server and an independent option. FileZillacan be run either as a service or standard program matching the flexibility of Uniform Server.

Remainder of this series shows how to set-up and run FileZilla the next page covers a basic configuration with no SSL.

Top