Server Management

This guide covers day-to-day administration of a running RemoteRF server, including setting up user groups and enrollment codes, managing accounts and reservations, running hardware self-tests, sharing access across deployment clusters, and backing up or resetting server state. For a complete lookup table of all serverrf and hostrf commands, see the CLI Reference.

Overview

serverrf uses a single unified command set across both the interactive console and the Linux shell:

  1. Attached Console (server@remoterf:): Start or re-attach to the server with serverrf -s (or serverrf --serve) and run commands directly at the prompt (for example, groups create, codes create, devices list, diag). Press Ctrl-C or type detach to leave the console without stopping the server.
  2. Linux Shell (serverrf <command>): Run any command directly from bash by prefixing serverrf (for example, serverrf groups list, serverrf devices add, serverrf db export). When the server is running, shell commands communicate with the live server process and automatically reload or restart the server when needed.

Always activate the remoterf-server environment before running serverrf:

conda activate remoterf-server
serverrf -s

User Groups & Enrollment Codes

For courses and research labs, manage access through user groups and enrollment codes rather than editing individual user accounts.

Creating a User Group (groups create)

A user group defines:

  • Devices whitelist: Comma-separated device IDs that group members are allowed to reserve.
  • Max reservation time: Maximum duration (in seconds) of a single reservation.
  • Max concurrent reservations: Maximum simultaneous active/upcoming bookings per user.
  • Group lifetime: Optional expiration window for the group (0 means no expiration).
  • Max booking horizon: How many days in advance a member may schedule a reservation (default 7 days; 0 means no limit).
  • Global reachability (Global Deployments only): Whether group members can connect over the internet through RemoteRF Global or are restricted to connecting directly from your local network/VPN. On a Local Deployment, all groups are local-network/VPN only.
  • Public visibility (Global Deployments only): Whether the group’s devices are openly bookable by anyone on RemoteRF Global (n keeps the group private to users who redeem your enrollment code; y makes the group’s devices publicly bookable without an enrollment code).

Tip — Sharing Devices Publicly on RemoteRF Global: To make a subset (or all) of your devices publicly bookable on RemoteRF Global, create a user group, enter the device IDs you wish to make public, and answer y to both Reachable from outside your network (via Global)? and Public: open to anyone on RemoteRF Global?. We recommend naming this user group "public" or "global".

  1. Run devices list to check the device IDs you want to include.
  2. Run groups create and follow the interactive prompts.
  3. Run groups list to confirm the new group and note its group_id.
Terminal
server@remoterf: groups create Available device IDs: 0, 1, 2 Enter group name (c to cancel): ee101-2026-spring Confirm group name 'ee101-2026-spring'? (y/n): y Devices whitelist (e.g. 0,1,2) (c to cancel): 0,1,2 Max reservation time (sec) [1800] (c to cancel): 3600 Max concurrent reservations [3] (c to cancel): 1 Group lifetime (sec) [0=forever] (c to cancel): 0 Max days ahead a reservation may start [7] (0=no limit) (c to cancel): 7 Reachable from outside your network (via Global)? (Y/n) (c to cancel): y Public: open to anyone on RemoteRF Global? (y/N) (c to cancel): n ◆ Group 'ee101-2026-spring' (group_id=1) created.
  • Editing a group (groups edit): Update a group’s device whitelist, reservation limits, or Global reachability in place. If a user belongs to multiple groups that include the same device, the server applies the highest reservation duration and concurrent limit among those groups.
  • Toggling public access (groups public): Toggle whether an existing group is publicly bookable on RemoteRF Global without recreating the group.
  • Exporting or removing groups (groups csv / groups remove): Export the groups table to ~/Downloads or remove a group interactively.

Generating Enrollment Codes (codes create)

Enrollment codes allow users to join a user group via remoterf --login (enroll <deployment>/<code> on a Global Deployment) or register a local account via remoterf -r --local-only (on a Local Deployment):

Terminal
server@remoterf: codes create How many enrollment codes? (c to cancel): 25 Attach a user group? (Y/n) (c to cancel): y Group ID to attach codes to? (c to cancel): 1 Characters per code name? [10] (c to cancel): 10 Use these codes? (y/n): y Uses per code? [1] (c to cancel): 1 Duration in seconds? [3600] (0=never expires) (c to cancel): 604800 ◆ Created 25 enrollment codes for group_id=1.
  • Single shared class code vs. one-per-student codes: Create 1 code with Uses per code set to your class size (for example, 50) to share a single <deployment>/<code> string on your syllabus, or create N codes with 1 use each and run codes csv to export individual codes to ~/Downloads.
  • Inspecting or revoking codes (codes list / codes remove): View remaining uses and expiration times, or remove specific codes or all codes for a group.

Managing Users & Reservations

Use the users and reservations commands to inspect accounts, manage individual user permissions, or cancel a reservation:

  • users list: Prints all registered user accounts, permission tiers, email addresses, and creation timestamps.
  • users manage: Prompts for a username and opens an interactive menu to view, add, or cancel reservations for that user, change permission tiers, or delete the account.
  • users perms: Displays the default permission tier tables.
  • users prune-proxies [-y]: Removes stale visiting partner-deployment proxy accounts (rfg_*) that have no active or upcoming reservations.
  • reservations list & reservations cancel <id>: List all active and upcoming reservations across the server with reservation IDs, usernames, device IDs, and start/end times, or cancel a reservation by ID.

Devices, Diagnostics & Schemas

  • devices list: Check which local and host-attached SDRs are online, inspect their handles (Name@deployment), and see which host owns each device.
  • devices add / devices rename / devices remove: Add, rename, or remove devices in ~/.config/remoterf/devices.yml. Changes automatically trigger a live device reload on the running server.
  • diag [--force] [--copy]: Run automated hardware self-tests across all local and host-attached SDRs. Pass --force to test devices even if an active reservation is present, or --copy to copy the diagnostic report to your clipboard.
  • schema browse [text] & schema download <name|hash> [-y]: Search the RemoteRF Global approved driver schema registry and save verified interface JSON specs into ~/.config/remoterf/drivers/registry/.
  • hosts status & hosts token <host_id> [--force]: Inspect connected hostrf edge nodes and their advertised devices, or generate/rotate a host authentication token.

Global, Clusters & Remote Admin

RemoteRF Global (global)

Manage your server’s connection to RemoteRF Global:

  • global status: View registration status, assigned hostname (<deployment>.global.remoterf.net), SSH relay tunnel state, and heartbeat timestamps (run global status inside serverrf -s to inspect the live tunnel status up; from bash it shows assigned).
  • global join & global verify <code>: Submit a Global registration request (requested) and redeem the verification code sent to your administrator email.
  • global leave: Disconnect from RemoteRF Global and stop the outbound relay tunnel.

Clustering Between Deployments (cluster & groups share)

Multiple RemoteRF Global deployments can form a cluster to share specific user groups across institutions without making those devices public to everyone:

  1. Create a cluster with cluster create <name> and generate a single-use invite token with cluster invite <cluster>.
  2. Peer administrators join the cluster using cluster join <token>.
  3. Share or unshare a local user group with the cluster using groups share, and optionally cap concurrent peer reservations with cluster cap <cluster> <n>.
  4. Inspect clusters and peer deployments with cluster list, cluster info <cluster>, and cluster peers.

Remote Administration (admins)

You can authorize administrators to run serverrf commands remotely from the client CLI (remoterf --remote-admin) using Ed25519 key authentication:

  1. Run admins add <user> [--read-only] to authorize a user account for remote administration, and run admins code to generate a one-time pairing code.
  2. The administrator pairs their workstation with remoterf --remote-admin pair <deployment> using that one-time code, and connects with remoterf --remote-admin [deployment].
  3. Inspect or revoke enrolled administrator device keys with admins devices [user] and admins revoke <user> <fingerprint|all>, review the audit log with admins log [n], configure relay/new-device policies with admins policy [relay on|off] [new-device email|console], or terminate active sessions with admins kick [<user>].

Backups, Reset & Purge

Exporting a Live Database Backup (db export)

To create a hot backup of all server SQLite databases while the server is running, run:

serverrf db export

This writes a timestamped archive (~/Downloads/remoterf-export-<timestamp>.tgz, or into a custom directory passed to serverrf db export <dir>).

Reset & Purge Commands

Each destructive command below prompts for confirmation before deleting records (or accepts -y where noted):

Command Effect When to Use
reservations purge Deletes all active and upcoming reservation records. Clearing scheduled reservations between academic terms while keeping user accounts intact.
stats purge [-y] Deletes completed reservation history used for usage analytics. Resetting cumulative reservation statistics while preserving current accounts and active bookings.
users purge Deletes all registered user accounts. Removing all accounts after a course or deployment reset (export rosters with groups csv / codes csv first if needed).
hosts wipe [-y] Clears persisted host registry and live host tunnel state. Removing decommissioned hosts that are no longer connected. Connected hosts will re-register on their next heartbeat.
db purge Deletes all database-backed accounts, groups, codes, and reservations, then exits the server. Full reset of server database state while keeping server.env, certs/, and devices.yml.
wipe [-y] Deletes everything in ~/.config/remoterf/ (databases, certificates, ports, devices, and Global config). Complete factory reset before decommissioning or re-initializing a server from scratch.

Next Steps