FileZilla Server2: Basic Configuration 2

From The Uniform Server Wiki
Revision as of 18:10, 13 April 2009 by Ric (talk | contribs) (New page: {{Uc nav FileZilla Server2}} '''FileZilla Server basic set-up Aliases''' This page looks at setting up Aliases on portable FileZilla. Although we are using portable mode the following are...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
Uniform Server 4.1-Mona
FileZilla FTPd (Server).

FileZilla Server basic set-up Aliases

This page looks at setting up Aliases on portable FileZilla. Although we are using portable mode the following are applicable to any of the installation modes. Portable operation allows you to explore and test configurations if you break anything just throw the servers away and start again.

Alias is a polite way of saying you are lying to a user. What they see displayed is not real additional thigs happen behind the scenes.

Top

Root folders

For both Apache and FileZilla a root folder is nothing more than a starting point. All folders and files above this root folder are not visible. While all folders, sub-folders and files in the root folder are.

Apache refers to this as the web-root folder while FileZilla refers to it as the home folder. Interestingly they both use the same symbol "/" to refer to root.

On the previous page FileZila's user root (home) was mapped to folder z:\www intentionally this corresponds with the Apache root mapping and allows a comparison of user addressees.

Top

Addresses

A user to find the information they wished served typically types the following address into a browser.

(what type of server to talk to)(where to find the server)(where to find what to serve )(what to serve)

A server is interested in the last two parts if these are not supplied root is assumed and something appropriate is served.

The following table shows what a user would type into a browser to access a page test.html

(what type of server to talk to) (where to find the server) (where to find what to serve) (what to serve)
http:// localhost / test.html
ftp:// localhost / test.html

where to find what to serve is important to the server because it needs to know where on a hard-drive or other media to find the information to serve.

A user provides the path "/" our server translates this to Z:\www

"/" is an alias to location Z:\www - Whats important a user sees only whats in that folder.

We known this folder contains real files and two real folders css and images to access these folders a user could type one of the following addresses into a browser:

  • ftp://localhost/ - Use displayed page links to access the folders
  • ftp://localhost/css/ - Direct access into folder
  • ftp://localhost/images/ - Direct access into folder

The first forward slash indicates root all other forward slashes indicate its a folder and not a file.

Top

Server's point of view

Server's point of view - for this address: ftp://localhost/images/

A server sees the first forward slash and knows it should start looking in the root folder located at z:\www.

Next part of the address is a folder named images/ the server asks a fundamental question is this a real folder if so display its content. If the folder is an alias locate the folder it points to and display it content.

Top

Alias

The above sentence is important it highlights a folder may not be a real folder at that location, however to a user it looks real because its visible.

An alias folder consists of two parts the name which is visible to a user and a full path to the real folder its this content that becomes visible to a user.

An alias name can be mapped to any folder on any hard-drive or other media.

Top

Alias Practical Example

The following examples restrict paths to our portable server, purly for exploring and testing. In the real world you can map any folder on any drive.

I started the page with "Alias is a polite way of saying you are lying to a user" To highlight this we will create three folders mp3, videos and films and serve the appropriate content from Uniform Server's folders.

Mapping

Mapping as follows:

  • Map folder name mp3 to folder Y:\docs
  • Map folder name videos to folder Y:\usr
  • Map folder name films to folder Y:\home\admin\programs

That's right we are lying there is no appropriate content to serve.

User FTP access and mapping

The following attempts to show the overall picture. How root folders fit with aliases, which map to absolute paths.

A user could access the
above folders using the
following addresses:

Remember a server is
interested in only the
last two parts giving:

A server starts in the
root folder / expending
this gives:

Folders are not real they are aliases hence
server uses path defined for alias to locate
the real folder and serves that folders content.

  • ftp://localhost/mp3
  • ftp://localhost/videos
  • ftp://localhost/films
  • /mp3
  • /videos
  • /films
  • Y:/www/mp3
  • Y:/www/videos
  • Y:/www/films
* Y:/www/mp3 >>   Y:\docs
* Y:/www/videos >>   Y:\usr
* Y:/www/films >>   Y:\home\admin\programs 

Alias folders are what you want a user to see they have no content.
An alias maps to a real folder defined by the absolute path associated with it.
Its this folders content that is displayed to a user or accessed by a user.

Top

Common folder mapping

Although we have mapped single folders into a users root folder these can equaliy be mapped to a single common folder.

Suppose we wish to display a folder named "all" in the root containing our three alias folders mp3, videos and films.

FileZilla needs to map aliases to real folders hence create a new folder all in the root folder www.

Our alias folders
currently look 
like this:

  • /mp3
  • /videos
  • /films

All that is required is to create paths
that match our requirement. In the root
folder we have a new folder named all
this contains three sub-folders hence
our alias folders now look like this:

  • /all/mp3
  • /all/videos
  • /all/films

Our new alias folders
still map to the same
real folders as shown:

  • Y:\docs
  • Y:\usr
  • Y:\home\admin\programs

Top

FileZilla configuration

We now have two examples to play with. There is no need to create a new user we already have a user fred (from part 1) and have set his root folder to Y:\www hence most of the work has been done.

Note: My server is now running on drive Y the FileZila configuration file was automatically updated to take into account the drive letter change.

Start servers and Zilla Admin

  1. Navigate to folder UniServer
  2. Start UniForm Server – Double click on Server_Start.bat - Note the virtual drive created (Normally Z).
  3. Start FileZilla server – Double click on fz_start.bat
  4. Double click on file fz_admin.bat
  5. A pop-up (Connect to server) is displayed, click OK - Starts admin window.
  6. From admin select Edit > Users

Top

Add shared folders

  1. Select page Shared folders - Selected by default A)
  2. Select user - Selected by default single user B)
  3. Under shared folders click Add C)
  4. In the pop-up navigate to folder Y:\home\admin\program click to highlight click OK.
    Note: Your virtual drive letter may differ
  5. Select file privileges you wish to allow D)
  6. Select directory privileges you wish to allow E)

Notes:

Repeat steps 9 to 12 for the remaining folders Y:\docs and Y:\usr substitute the appropriate folder at step 10 result as shown on the right.

Top

Add alias folders

  1. To the extreme right of folder Y:\docs double click - F1)
  2. In the pop-up enter the alias name /mp3 - G
  3. Click OK closes the pop-up - H)

Repeat steps 13 to 15 for the remaining folders Y:\home\admin\programs and Y:\usr adding the appropriate alias folder.

Finally click OK - Bottom left.

Note: At step 13 instead of double clicking an alternative is to right click on the folder (directory) name, choose Edit Aliases from the pop-up menu.

Top

Quick Test

Type the following into your browser:

ftp://localhost/ a pop-up is displayed enter name (fred) and password (fred123).

A page is displayed showing files and folders contained in your shared folder (www).

You will see three new folders mp3, videos and films check their contents.

Top

Modify alias folders

Our last example was to place the three alias folders into a single folder named all.

Edit the aliases as follows:

  1. From Zilla admin select Edit > Users
  2. Select page Shared folders
  3. Double click on each alias folder. At each pop-up insert new folder all as shown:
     /all/mp3
     /all/videos
     /all/films

Click OK - bottom left.

Test modified folders

Test as above, this time you will see a folder all containing mp3, videos and films.

Top

Summary

Setting up an alias is relatively easy the above examples allow you to explore this area on a portable server. If you make a mistake and the servers become irreparable, well just delete them and start again.

The examples covered so far have a real problem and that is one of security. Passwords and data are sent unencrypted the next page covers a secure FTP server.

Top