manage.flexfs
manage.flexfs is the host management utility for flexFS. It manages systemd services, downloads and installs binary updates, and provides log monitoring. All subcommands except init creds, deinit creds, version, and license require root.
It works with both Enterprise and Community editions.
Subcommands
Section titled “Subcommands”| Subcommand | Description |
|---|---|
init creds | Initialize credentials (custom download server) |
deinit creds | Remove credentials file |
start | Start flexFS systemd services |
stop | Stop flexFS systemd services |
restart | Stop and start services |
status | Show status of flexFS services |
clean | Remove temporary files and caches |
download | Download flexFS binaries to /tmp |
install | Install binaries from /tmp to /sbin |
deploy | Deploy mount client binaries to staging/production channels |
upgrade | Full upgrade: clean, download, install, then restart the upgraded services |
watch | Follow journal logs for a service |
version | Print the build version |
license | Print license information |
Credential Initialization
Section titled “Credential Initialization”By default, manage.flexfs downloads binaries from get.flexfs.io. To use a custom download server, initialize a credentials file:
manage.flexfs init creds --downloadAddr download.internal:443See manage.flexfs init creds for its flags and their defaults.
The credentials file is a TOML file written with 0600 permissions:
downloadAddr = "download.internal:443"Commands that download binaries (download, deploy, upgrade, install) read this file automatically. Command-line flags override the file value.
deinit creds
Section titled “deinit creds”manage.flexfs deinit credsRemoves the credentials file. After removal, download commands fall back to get.flexfs.io.
Service Management
Section titled “Service Management”Service Order
Section titled “Service Order”manage.flexfs manages six flexFS systemd services. Services are started in this order and stopped in reverse order, ensuring that dependents are torn down before the services they depend on:
error(flexfs-error.service)stat(flexfs-stat.service)admin(flexfs-admin.service)free(flexfs-free.service)proxy(flexfs-proxy.service)meta(flexfs-meta.service)
The error service starts first and stops last, so it is available to receive reports for the entire lifetime of the other services.
When no service names are specified, commands operate on all services that have unit files installed. Only services with existing systemd units are acted upon.
Start flexFS systemd services.
sudo manage.flexfs start # Start all installed servicessudo manage.flexfs start meta proxy # Start specific servicesStop flexFS systemd services. Services are stopped in reverse order.
sudo manage.flexfs stop # Stop all installed servicessudo manage.flexfs stop proxy # Stop a specific servicerestart
Section titled “restart”Stop and start services again. Pass --vacuum to also vacuum the system journal logs between the stop and start.
sudo manage.flexfs restartsudo manage.flexfs restart --vacuum # Also vacuum journal logssudo manage.flexfs restart meta # Restart a specific serviceSee manage.flexfs restart for its flags and their defaults.
status
Section titled “status”Show the status and uptime of flexFS services.
sudo manage.flexfs statusOutput shows each installed service with its systemd active state and uptime:
admin active 2d 14h meta active 2d 14h proxy active 2d 14hRemove flexFS temporary files (/tmp/*.flexfs) and optionally vacuum journal logs.
sudo manage.flexfs cleansudo manage.flexfs clean --vacuumSee manage.flexfs clean for its flags and their defaults.
When --vacuum is used, the command runs journalctl --rotate followed by journalctl --vacuum-time=1s to reclaim journal disk space.
Binary Management
Section titled “Binary Management”download
Section titled “download”Download flexFS binaries to /tmp. Uses the download server address from the credentials file, or get.flexfs.io by default.
sudo manage.flexfs download admin meta proxy mountsudo manage.flexfs download mount --version v1.9.x --arch amd64sudo manage.flexfs download mount --install # Download and install in one stepSee manage.flexfs download for its flags and their defaults.
Valid binary names: admin, analyze, configure, dedup, error, find, free, license, manage, meta, mount, proxy, stat, update.
install
Section titled “install”Install flexFS binaries from /tmp to /sbin. When binary names are given as arguments, any that are missing from /tmp are downloaded automatically.
sudo manage.flexfs install # Install all /tmp/*.flexfssudo manage.flexfs install mount meta proxy # Install specific binaries (downloads missing ones)See manage.flexfs install for its flags and their defaults.
Only binaries owned by root are installed. The install process removes the existing binary at /sbin before replacing it to avoid “text file busy” errors on running processes. SELinux contexts are set automatically where chcon is available.
deploy
Section titled “deploy”Deploy the latest mount.flexfs binaries to staging and/or production channels within the admin server’s deploy folder. Mount clients poll the admin server for updates from these channels.
sudo manage.flexfs deploy # Deploy to both channelssudo manage.flexfs deploy --channel staging # Deploy to staging onlysudo manage.flexfs deploy --channel production # Deploy to production onlySee manage.flexfs deploy for its flags and their defaults.
The deploy process downloads both amd64 and aarch64 mount client binaries along with the version file, and atomically swaps them into the channel directory.
upgrade
Section titled “upgrade”Full upgrade sequence: clean temporary state, download binaries, install them to /sbin, then stop and start only the services whose binaries were upgraded.
sudo manage.flexfs upgrade # Upgrade all installed binariessudo manage.flexfs upgrade mount meta proxy # Upgrade specific binariessudo manage.flexfs upgrade --deploy # Upgrade, then deploy mount.flexfsSee manage.flexfs upgrade for its flags and their defaults.
When no binary names are specified, upgrade scans /sbin for existing flexFS binaries and upgrades all of them.
With --deploy, upgrade runs the equivalent of deploy once the upgrade completes, deploying mount.flexfs for the same --version it just installed. The --channel and --adminPath flags control that deploy step.
Log Monitoring
Section titled “Log Monitoring”Follow the systemd journal logs for a flexFS service in real time.
sudo manage.flexfs watch metasudo manage.flexfs watch admin --lines 50 --catSee manage.flexfs watch for its flags and their defaults.
Valid service names: admin, error, free, meta, proxy, stat.
version
Section titled “version”Print the build version.
manage.flexfs version