• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL



ftpd Internet File Transfer Protocol server.
ftpd [-AdDhlMSU] [-T <maxtimeout>] [-t <timeout>] [-u <mask>]

ftpd is the Internet File Transfer Protocol process. It uses the TCP protocol and runs on the port specified as ftp in services directory of the NetInfo database.
-A Permits only anonymous FTP connections. All others are refused.
-d Turns on debugging. Debugging information in written to the syslog using LOG_FTP.
-D Detaches and becomes a daemon. Accepts connections on the FTP port and forks child processes to handle them. This has a lower overhead than starting the service from inetd(8) and is useful on busy servers to reduce the load.
-h Uses data ports in the high port range (usually 40000–44999) for passive connections.
-l Each successful and failed ftp (1) session is logged to the syslog using LOG_FTP. If specified twice (-l -l), the logging of retrieve (get), store (put), append, delete, make directory, remove directory, and rename operations and their arguments also occurs.
-M Enables multihomed mode. Instead of using ~ftp for anonymous transfers, a directory matching the fully qualified domain name of the IP address of the connected client, located in ~ftp, is used instead.
-S Logs all anonymous transfers to /var/log/ftpd, if the file exists.
-U Logs each concurrent ftp (1) session to the file /var/log/ftpd, making them visible to commands such as who (1).
-T <maxtimeout> A client may also request a different timeout period. The maximum period may be set to <timeout> in seconds. Default is 2 hours.
-t <timeout> Sets the inactivity timeout period to <timeout> seconds. Default is 15 minutes.
-u <mask> Changes default umask from 027 to <mask>.
ftpd supports the following FTP requests, case ignored.
ABOR Aborts previous command.
ACCT Specifies account (ignored).
ALLO Allocates storage (vacuously).
APPE Appends to a file.
CDUP Changes to the parent directory of the current working directory.
CWD Changes current working directory.
DELE Deletes a file.
HELP Gives help information.
LIST Gives list files in a directory (ls -lgA).
MKD Makes a directory.
MDTM Shows last modification time of file.
MODE Specifies data transfer mode.
NLST Gives name list of files in directory.
NOOP Does nothing.
PASS Specifies password.
PASV Prepares for server-to-server transfer.
PORT Specifies data connection port.
PWD Prints current working directory.
QUIT Terminates session.
REST Restarts incomplete transfer session.
RETR Retrieves a file.
RMD Removes a directory.
RNFR Specifies rename-from filename.
RNTO Specifies rename-to filename.
SITE Nonstandard commands (see next section).
SIZE Returns size of file.
STAT Returns status of server.
STOR Stores a file.
STOU Stores a file with a unique name.
STRU Specifies data transfer structure.
SYST Shows operating system type of server system.
TYPE Specifies data transfer type.
USER Specifies username.
XCUP Changes to parent of current working directory (deprecated).
XCWD Changes working directory (deprecated).
XMKD Makes a directory (deprecated).
XPWD Prints the current working directory (deprecated)
XRMD Removes a directory (deprecated).
The following non-standard commands are supported by the SITE request:
UMASK Changes the umask; for example, SITE UMASK 002.
IDLE Sets the idle-timer; for example, SITE IDLE 60.
CHMOD Changes the mode of a file; for example, SITE CHMOD0 0CHMOD1 1CHMOD2.
HELP Gives help information.
The remaining ftp requests specified in Internet RFC 959 are recognized, but not implemented.
ftpd interprets filenames according to the globbing conventions by csh (1). This allows users to use the following metacharacters: *?[]{}~
ftpd authenticates users according to these rules:

1. Login name must be in the password database and not have a null password.

2. Login name must not appear in /etc/ftpusers.

3. User must have a standard shell returned by getusershell (3).

4. If the username appears in /etc/ftpchroot, the sessions root is changed to the user's home directory by chroot (2), as for an anonymous or ftp account. The user must still supply a password. This feature is a compromise between an anonymous account and a fully privileged account. This account should also be set up as for an anonymous account.

5. If the username is anonymous or ftp, an anonymous FTP account must be present in the password file for user ftp. The connecting user may specify any password, customarily an e-mail address.
Associated files:  
/etc/ftpusers List of unwelcome/restricted users.
/etc/ftpchroot List of normal users who should be chrooted.
/etc/ftpwelcome Welcome notice.



Not a subscriber?

Start A Free Trial

  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint