Skip to main content
Servers Are Up
Virtual Datacenter
PricingFree Tools
Sign inBrowse catalog
Servers Are Up
Virtual Datacenter
PricingFree Tools
Sign inBrowse catalog

Loading…

Servers Are Up

Your apps, automation and data on hardware we own. Build a private stack with predictable capacity and access through your dashboard, API or SSH.

SLA with service creditsOwned hardwareUS-based

Make room for your next idea

Explore the capacity, apps and access options that fit your workload. Check current availability and your total before you buy.

Sign up freeView Pricing

Products

  • Linux VPS
  • Windows VPS
  • Cloud & SaaS Services
  • Cloud Storage (Azure)
  • Virtual Datacenter
  • AI & Agent Hosting
  • Containers
  • Instant Apps
  • Software Platforms
  • Network builder
  • Game Servers
  • Free Game Servers
  • Pricing

Resources

  • Free Network Tools
  • 2026 Pricing Benchmark
  • Live SVG Badges
  • Latency & Speed Test
  • Guides & Tutorials
  • Documentation
  • API Reference
  • MCP Server
  • CLI & SDKs
  • OpenAPI & llms.txt
  • Use Cases
  • Free Migration
  • Uptime & Reliability
  • Datacenter
  • System Status
  • Network
  • Provider Comparisons Hub
  • Compare Providers

Company

  • About Us
  • Enterprise
  • Security Architecture
  • Trust Center
  • Blog
  • FAQ
  • Compliance
  • Startup Program
  • Open-Source Sponsorship
  • Press & Media Kit
  • Referral Program
  • Help Center
  • Contact Us
© Servers Are Up
TermsPrivacySLARefund PolicyDPAAcceptable Use
Service information
Docs
  • Documentation Hub
  • Technical Knowledge Library
    Runbooks & 187 Blueprints
  • Choose a Product
    VMs, Containers & Cloud
  • First Linux Server
    SSH, Firewall & Apps
  • Windows Server 2025
    BYOL & Remote Desktop
  • Remote Access
  • Troubleshooting
  • FAQ
  • All Product Guides
    29 Step-by-Step Guides
  • Cloud & SaaS Catalog
    112 Cloud & SaaS Offerings
  • Azure Cloud Storage
    Hot/Cool/Archive & WORM
  • Resource Manager & RBAC
    Groups, Tags & Locks
  • Multi-Model Cloud DB
    JSONB, SQL & pgvector
  • Cloud Identity & ZTNA
    OIDC, SCIM & PIM
  • Key Vault & KMS
    Secrets & Envelope Keys
  • Cloud SIEM, SOAR & DLP
    Posture & Threat Response
  • API Gateway & Cloud DNS
    Edge WAF & DNS Zones
  • Serverless, Workflows & IoT
    Functions, Queues & DAGs
  • SaaS, Governance & Vault
    Budgets & Off-Host GRS
  • Linux Systems & Kernel
    SSH, UFW, sysctl & OOM
  • Self-Hosted Apps & Stacks
    Caddy, Nextcloud & Auth
  • Build Web Apps with AI
  • Next.js and React
  • TypeScript and Node.js
  • npm and Tooling
  • Data and APIs
  • Deploy and Operate
  • Tutorials
  • Infrastructure
  • Automation & Regions
  • API Overview
  • API v1 Reference
    Endpoints & 23 Scopes
  • MCP Server
    129 AI Agent Tools
  • Swagger / OpenAPI 3.1
  • API Playground
  • Versioning & Sunset
  • API Token Security
    Authentication & Tokens
  • Instances API
    Compute Resources
  • Networking API
    Networks & Ports
  • Storage API Availability
    Volumes & Backups
  • Webhooks & Events
    Event Notifications
  • Rate Limits & Best Practices
    Throttling & Retries
  • sau CLI Reference
    34 Commands (v0.2)
  • Browser Web CLI
  • SDKs
  • Infrastructure as Code
    Terraform & Ansible
  • Code Examples
  • CLI & SDK Guides
  • Security Guides
  • Security at a Glance
  • Zero Trust Architecture
  • Live Trust Center
  • Compliance
Need help?

Loading documentation...

Documentation/linux systems

Administer Ubuntu, Debian, Rocky, and AlmaLinux servers cleanly

Manage APT and DNF packages, unattended security upgrades, sudo users, systemd services, and journald logs across Ubuntu, Debian, Rocky, and AlmaLinux.

Beginner
25 min
Updated 2026-11-23

Deploy Ready-to-Run Infrastructure in Seconds

Linux VMs from $6/mo · Pooled Virtual Datacenters from $12/mo · Use code WELCOME20 for 20% off your first order.

Browse ServersView Pricing

Commands checked on 2026-11-23 with Ubuntu 24.04 LTS, Debian 12, Rocky Linux 9, AlmaLinux 9.

What you will have at the end

A repeatable operational checklist and cross-distro command baseline for administering Debian-family (Ubuntu 24.04 LTS, Ubuntu 22.04 LTS, Debian 12) and Enterprise Linux (Rocky Linux 9, AlmaLinux 9) virtual servers without drift, stale security patches, or full system disks.

Before you start

  • A running Linux server with non-root sudo access or browser SSH console access; see First Linux server.
  • Awareness that newly provisioned cloud instances keep inbound SSH port 22 closed until enabled in Public Access or Network Builder.

Steps

1. Identify OS release, kernel, and package family

Always inspect the running distribution and uptime before running package or firewall changes.

cat /etc/os-release
uname -r
hostnamectl
uptime -p

Debian and Ubuntu use apt and systemd-journald with service names like ssh and apache2, whereas Rocky Linux 9 and AlmaLinux 9 use dnf, SELinux (sestatus), and service names like sshd and httpd.

2. Apply clean package and unattended security updates

On Ubuntu 24.04 / Debian 12:

sudo apt-get update && sudo apt-get upgrade -y
sudo apt-get install -y unattended-upgrades apt-listchanges curl jq ca-certificates
sudo dpkg-reconfigure -f noninteractive unattended-upgrades

On Rocky Linux 9 / AlmaLinux 9:

sudo dnf upgrade -y --refresh
sudo dnf install -y dnf-automatic curl jq ca-certificates
sudo sed -i 's/^apply_updates = no/apply_updates = yes/' /etc/dnf/automatic.conf
sudo systemctl enable --now dnf-automatic-timer

3. Manage sudo administrators and locked root accounts safely

Create a named operator user with explicit SSH key authorization before hardening root login:

sudo adduser deploy || sudo useradd -m -s /bin/bash deploy
sudo usermod -aG sudo deploy 2>/dev/null || sudo usermod -aG wheel deploy
sudo install -d -m 700 -o deploy -g deploy /home/deploy/.ssh
sudo install -m 600 -o deploy -g deploy /root/.ssh/authorized_keys /home/deploy/.ssh/authorized_keys
sudo visudo -cf /etc/sudoers

Verify key login in a separate terminal before closing your original shell session.

4. Inspect systemd units, journald logs, and disk consumption

Use structured systemd queries rather than parsing /var/log/syslog blindly:

systemctl --failed
systemctl list-units --type=service --state=running
journalctl -u ssh -u sshd -n 50 --no-pager
sudo journalctl --disk-usage
sudo journalctl --vacuum-time=14d --vacuum-size=500M
df -hT

Cap persistent journal size in /etc/systemd/journald.conf.d/size.conf so verbose crash loops cannot exhaust / and break SSH logins or PostgreSQL writes:

[Journal]
SystemMaxUse=500M
SystemKeepFree=2G
MaxRetentionSec=1month

Apply immediately with sudo systemctl restart systemd-journald.

5. Enforce Mandatory Access Control and baseline time sync

Check that time synchronization (chrony or systemd-timesyncd) and MAC enforcement (AppArmor on Ubuntu/Debian or SELinux on Rocky/AlmaLinux) are healthy:

timedatectl status
sudo aa-status 2>/dev/null || getenforce 2>/dev/null

Check that it works

Run this single validation block and confirm zero failed services, active time sync, and enabled unattended security updates:

systemctl is-system-running
timedatectl show -p NTPSynchronized --value
systemctl is-enabled unattended-upgrades 2>/dev/null || systemctl is-enabled dnf-automatic-timer

You should see running (or degraded resolved to running), yes, and enabled.

What can go wrong

  • apt-get fails with Could not get lock /var/lib/dpkg/lock-frontend. An unattended background upgrade is active at boot. Confirm with ps aux | grep -E 'apt|dpkg|dnf' and wait 30–60 seconds rather than deleting lock files mid-transaction.
  • Permission denied (publickey) after adding a new user. SELinux context or file mode mismatch on Rocky/AlmaLinux. Fix permissions and restore context: chmod 700 ~/.ssh && chmod 600 ~/.ssh/authorized_keys && sudo restorecon -Rv /home/deploy/.ssh.
  • Services fail to start with No space left on device. Check both blocks (df -h) and inodes (df -i), then locate huge directories with sudo du -xhd 1 /var | sort -h.

Good practice

  • Separate data volumes and Docker storage from small root filesystems whenever possible, and keep SystemKeepFree=2G in journald.
  • Never install both firewalld and ufw on the same Linux host; keep each distribution's native firewall stack clean.
  • Snapshot before major kernel, PostgreSQL, or distro upgrades using Backups and snapshots.
  • Track service reboots after kernel security patches via test -f /var/run/reboot-required (Debian/Ubuntu) or sudo dnf needs-restarting -r (Rocky/AlmaLinux).

Where to go next

  • Harden OpenSSH and sandbox systemd services
  • Fix Docker UFW bypasses with DOCKER-USER and nftables
  • Diagnose Linux OOM kills, sysctl limits, and disk spikes

Related Articles

Fix Docker UFW bypasses with DOCKER-USER and nftables

Read more

Diagnose Linux OOM kills, sysctl limits, and disk spikes

Read more

Harden OpenSSH and sandbox systemd services cleanly

Read more

Frequently Asked Questions

What does the Administer Ubuntu, Debian, Rocky, and AlmaLinux servers cleanly documentation guide cover?
Manage APT and DNF packages, unattended security upgrades, sudo users, systemd services, and journald logs across Ubuntu, Debian, Rocky, and AlmaLinux. It is rated beginner difficulty (25 min) and applies to Servers Are Up infrastructure and workflows.
Can I manage or automate these steps through the Servers Are Up dashboard, REST API v1, or MCP server?
Yes. Every Servers Are Up server includes browser-based SSH, WebRDP, and VNC console access in the dashboard, plus programmatic control via the REST API v1 (/api/v1) and hosted Model Context Protocol server (/api/mcp/v1) using a scoped Personal Access Token.

Need hands-on help with Administer Ubuntu, Debian, Rocky, and AlmaLinux servers cleanly?

Every Servers Are Up virtual machine and container includes an integrated HTML5 browser-based SSH, RDP, and VNC console in your dashboard, default-off inbound firewall rules with per-IP allow-lists, and full programmatic control via REST API v1 and Model Context Protocol (MCP). Explore our Virtual Datacenter Plans or reach out to Servers Are Up Support.

Was this article helpful?

On this page

What you will have at the endBefore you startSteps1. Identify OS release, kernel, and package family2. Apply clean package and unattended security updates3. Manage sudo administrators and locked root accounts safely4. Inspect systemd units, journald logs, and disk consumption5. Enforce Mandatory Access Control and baseline time syncCheck that it worksWhat can go wrongGood practiceWhere to go next
Need Live Commands?

Open Aria in Wide Engineering Mode for distro-specific commands, compose tweaks, and isolated environment troubleshooting.

Knowledge Library