afpc

control AFP discovery, FUSE mounts, and the stateless controller

SYNOPSIS

afpc discover [–verbose | –json] [–timeout milliseconds]
afpc sl status | exit
afpc fs mount [mount-options] server: volume mountpoint
afpc fs mount –service name [mount-options] [–volume volume] [mountpoint]
afpc fs unmount | suspend | resume mountpoint‌
afpc fs status [mountpoint]
afpc fs exit

DESCRIPTION

afpc is the client-control command. Commands that address a controller always use an explicit namespace, preventing a command from silently selecting the wrong controller in installations with both FUSE and stateless AFP operations.

discover does not contact either controller and is available in every build.

sl uses the public libafpsl API to communicate with afpsld(1). It accepts only status and exit.

fs communicates with afpfsd(1) and is present only when FUSE support was built. It provides structured mounting and FUSE mount lifecycle commands. The mount options are the same as the former AFP client mount command.

Unqualified controller commands such as “afpc status” or “afpc mount” are invalid. Use the appropriate fs or sl namespace.

FS MOUNT OPTIONS

The following options apply to afpc fs mount. They may be used with either a direct server: volume mount or a service-based mount unless noted otherwise.

-s name, –service name

Resolve the named AFP service advertised through DNS-SD or Avahi. Service names containing spaces should be quoted. When this option is used, the service’s advertised port is used unless -o is also supplied.

–volume volume

Select the volume to mount after resolving a service. This option is valid only with –service. If it is omitted, the command authenticates, lists the available volumes, and exits without mounting; a mountpoint is optional in that case.

-u username, –user username

Authenticate as username. If the password is omitted, the command prompts for it. Without a username, the default authentication methods may select guest access.

-p password, –pass password

Use password for AFP authentication. Use ‘-’ to request an interactive password prompt.

-P password, –volpass password

Use password as the AFP volume password. Use ‘-’ to request an interactive volume-password prompt.

-o port, –port port

Connect to TCP port instead of the default AFP port, 548.

-f version, –afpversion version

Limit the AFP protocol version used to connect. The version may be written with or without a decimal point, for example 3.1 or 31.

-a uam, –uam uam

Restrict authentication to the specified UAM. Supported shorthands are guest, clrtxt, randnum, randnum2, dhx, and dhx2.

-m map, –map map

Select the UID and GID mapping method. Valid values are common and loginids.

-O flags, –options flags

Pass a comma-separated set of FUSE mount options to the mount operation. Consult the FUSE documentation for supported flags.

For a direct mount, specify both server: volume and mountpoint. For example:

afpc fs mount --user myuser --afpversion 3.1 \
    afpserver.local:Files /home/myuser/fusemount

For a service-based mount, use –service and –volume:

afpc fs mount --service "Office File Server" --volume Files \
    /home/myuser/fusemount

COMPATIBILITY

When FUSE support is built, mount_afpfs(1) is installed as a symlink to afpc. Its exact program name selects the AFP-URL mount syntax; it does not accept afpc subcommands.

EXIT STATUS

The afpc utility exits 0 on success, and >0 if an error occurs.

SEE ALSO

afpfsd(1), afpsld(1), mount_afpfs(1)