# CLI

`exfs` is the ExpanDrive Server Edition executable. While it normally runs as a background service, it also accepts command-line invocations for scripted or headless environments. Each of the following is a separate command invocation.

## Help and Configuration

`exfs --help` Print help.

`exfs --config` Launch the web-based configuration interface on port 28080.

## Server Activation

`exfs --register <server_token>` Activate Server Edition using a [server token](/expandrive-server-edition/setup.md#license-activation).

## Drive Management

On Windows, admin rights are required for mount and unmount operations.

`exfs --list` List all configured connections.

`exfs --mount <drive_name>` Mount a drive by name.

`exfs --unmount <drive_name>` Unmount a drive by name.

`exfs --unmount-all` Unmount all drives.

## Service Behavior

`exfs --foreground` Keep exfs in the foreground rather than running as a background service.

`exfs --sync` Enable sync write operations. Use this when it is important that operations like delete, rename, and write do not complete until they have been propagated to remote storage. This is generally much slower since there is no opportunity to aggregate and parallelize multiple requests.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.expandrive.com/expandrive-server-edition/cli.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
