Measure Redis key memory without running an unbounded key dump
MEMORY USAGE estimates bytes allocated for one key and can sample nested values, while aggregate overhead and allocator fragmentation appear elsewhere.
Test a Redis RDB restore without overwriting production
An RDB file is a point-in-time dataset snapshot loaded at server startup; a meaningful test uses a separate instance and validates data semantics.
Find large Redis keys without blocking the server with KEYS
SCAN incrementally iterates the keyspace with limited work per call but may return duplicates and does not provide a transactionally stable snapshot.
Use Redis SLOWLOG to find server-side command latency
SLOWLOG records commands whose execution time exceeds a threshold, excluding network I/O, so it identifies server work rather than total client latency.
Enable Redis TLS and verify every communication channel
Redis can protect client, replication, and cluster-bus traffic with TLS, but certificates, ports, trust, and client configuration must converge together.
Use Redis WAIT without claiming strong consistency
WAIT blocks a client until earlier writes are acknowledged by a requested number of replicas or timeout, but acknowledged copies can still be lost during failover.
Resize an ext4 filesystem after verifying the device boundary
Ext4 can grow online when its containing block device is already larger, but partition, LVM, encryption, and filesystem sizes must be distinguished.
Grow an XFS filesystem from its mount point, not a guessed device
Xfs_growfs operates on a mounted XFS filesystem and grows within the already expanded underlying device; XFS does not support shrinking.
Build a restic backup with reviewed excludes and searchable tags
Restic walks selected paths, applies exclude rules, chunks changed content, and records a snapshot with host, path, time, and optional tags.
Schedule restic repository checks that eventually read all data
Restic check validates repository structure and indexes; read-data or read-data-subset additionally downloads and verifies stored pack contents.
Copy restic snapshots between repositories and verify independence
Restic copy transfers snapshot metadata and referenced data to another repository, reusing destination data when possible while preserving separate encryption domains.
Preview a restic retention policy before forgetting snapshots
Restic forget groups snapshots by host, path, tags, and policy filters, then selects which snapshot records to remove; data remains until prune.
Restore restic data into an isolated directory before cutover
Restic reconstructs selected snapshot paths under a target directory, preserving stored metadata where the platform permits.
Use restic mount for read-only file discovery before restore
Restic mount exposes repository snapshots through a FUSE filesystem for browsing; it is a recovery view, not the application cutover target.
Run restic prune only after capacity and recovery checks
Prune repacks repository data and deletes unreferenced objects after forget, requiring temporary space, backend writes, and uninterrupted credential scope.
Initialize a restic repository and prove the backend identity
Restic init creates repository configuration and keys at one backend location; credentials and repository URL together select the target.
Select the exact restic snapshot before restore or retention
Restic filters snapshots by ID, host, path, tag, and time; latest is relative to those filters and repository visibility.
Remove a restic stale lock only after proving no writer is active
Restic creates repository locks to coordinate operations; unlock removes stale locks but cannot safely resolve a genuinely concurrent writer.
rsync --partial vs --inplace: choose by recovery and reader behavior
--partial retains an incomplete temporary transfer for reuse, while --inplace writes directly into the destination file and changes atomicity, snapshots, and reader visibility.
Repair SELinux file contexts persistently with semanage and restorecon
SELinux path labeling policy maps pathname patterns to expected contexts; restorecon applies that policy while chcon creates a local label that relabeling may erase.
Use SFTP batch mode with explicit failure and atomic-file behavior
Sftp -b reads commands from a file and aborts on selected command failures; remote application consistency and final-name publication remain separate concerns.
Build SLO burn-rate alerts from good and total events
Burn rate compares observed bad-event ratio to the error budget rate; multi-window alerts combine fast detection with evidence that impact persists.
Use ss to identify the process listening on a Linux port
Ss reads kernel socket state and can show local addresses, ports, processes, queues, and TCP details without probing the network path itself.
Use SSH BatchMode so automation fails instead of waiting for input
BatchMode disables interactive prompts, making missing credentials, host-key decisions, and keyboard-interactive requirements surface as bounded failures.