> For the complete documentation index, see [llms.txt](https://docs.expandrive.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.expandrive.com/expandrive-server-edition/cli.md).

# 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
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

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

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
