# Pier — network drives in Explorer

Pier mounts WebDAV (Nextcloud, ownCloud, Synology, Apache), SFTP (any SSH
server) and NFSv3 storage as a real Windows drive letter. A block cache on the
local disk keeps large files fast, interrupted uploads and downloads resume
where they stopped, a broken connection is re-dialled on its own, and a drive
can be switched to offline mode and keep working from the cache.

Free edition: up to 5 drives, all protocols and features, an ad banner in the
settings window. Pro: unlimited drives and no ads — $19 per year, bought in
your iMobile account (https://new-imobile.com/en/pier/).

## Requirements

- Windows 10 or 11 (64-bit), Windows Server 2019 or newer.
- The Dokany file-system driver (open source, https://dokan-dev.github.io). Its
  installer `DokanSetup.exe` is included in the archive; one run, no reboot.
  Pier tells you if the driver is missing.
- Administrator rights for the installation of the service only.

## Installation

Run `Pier-<version>-Setup.exe`: it installs the Dokany driver when it is missing
and then Pier itself (service, Start Menu shortcut, tray). Removal: Apps &
features, "Pier"; Dokany stays and can be removed separately.

Portable alternative, `Pier-<version>.zip`:

1. Run `DokanSetup.exe` from the archive (skip if Dokany 2.x is already installed).
2. Unpack `Pier-<version>.zip` into a folder that stays put, for example
   `C:\Program Files\Pier`, and start `Pier.exe`.
3. Confirm the service installation when asked (a UAC prompt). The `Pier`
   service starts and a tray icon appears; it also starts at every logon.

To remove: `Pier.exe uninstall` as administrator, then delete the folder.
Dokany is uninstalled separately through Apps & features.

## Upgrading from 0.1.0

0.1.0 used the WinFsp driver; 0.2.0 uses Dokany. Run `DokanSetup.exe`, then stop
the service (`net stop Pier` as administrator or the tray menu), replace `Pier.exe`
and start it again (`net start Pier`). Drives, cache and settings are kept. WinFsp
can be uninstalled afterwards through Apps & features.

## First drive

1. Open Pier from the tray icon and press **Add**.
2. Pick the protocol, enter the server, the folder and the credentials, choose
   a drive letter.
3. Press **Check**: Pier connects, tests writes and renames, measures what the
   server can do (resume, timestamps, case sensitivity) and shows a report.
   Problems are listed here, not later as an unexplained error.
4. Press **OK**. The service mounts the letter for every user on the machine
   and keeps it across reboots.

### Connection pages

- **Connection** — protocol, server, port, root folder, user, password or an
  OpenSSH key file (Ed25519, ECDSA, RSA, with a passphrase).
- **Network** — timeouts, retries and back-off for bad links, the number of
  parallel connections, an upload/download bandwidth limit.
- **Cache** — cache size and location, block size, how long directory
  listings are trusted, write-back delay, offline mode.
- **Compatibility** — what the server check found, and overrides for servers
  that report their capabilities wrongly.

## Everyday use

- The tray menu shows every drive with mount/unmount, "Open in Explorer" and
  "Sync now".
- **Transfers** in the settings window lists running and queued uploads and
  downloads with their progress and retries.
- **Offline**: switch a drive to offline mode to work from the cache only;
  your changes are journaled and pushed when you go online again.
- **Auto-update** is on by default (tray menu). Pier checks for a new version
  a few times a day, downloads and verifies it, and installs it when no
  transfer is running. The drives go away for about a minute during the
  update.

## Command line

```
Pier.exe status | log [N] | set <mount.json> | mount <id> | unmount <id> |
         remove <id> | sync <id> | clearcache <id> | offline <id> | online <id> |
         probe <id|json> | update [apply] | install | uninstall | version
```

Configuration: `%ProgramData%\Pier\config.json` (credentials encrypted with
the machine's DPAPI key). Cache: `%ProgramData%\Pier\cache\<id>`. Service log:
`%ProgramData%\Pier\service.log`.

## Privacy

Pier talks only to the servers you configure. The iMobile account server
(accounts.new-imobile.com) is contacted only for the licence, the ad banner of
the free edition and update checks.

© iMobile. Pier uses Dokany (https://dokan-dev.github.io) and libssh2 (https://libssh2.org).
