LarVPS
Getting Started
Getting Started Ubuntu VPS Agent

How to Connect an Ubuntu 22.04 or 24.04 VPS to LarVPS

By LarVPS Team 6 min read
GS
LarVPS
Getting Started

If you can connect a server cleanly, the rest of the platform becomes much easier.

That is why LarVPS is designed around a simple flow:

  1. Open the cloud dashboard.
  2. Add a server.
  3. Run one connect command as root.
  4. Let the agent report inventory and heartbeat back to the dashboard.

This guide shows the safest path for Ubuntu 22.04 and Ubuntu 24.04, explains what the installer checks before it touches the machine, and helps you avoid the most common reasons a VPS fails to connect.

Who this guide is for

This is the right guide if you:

  • just bought a fresh VPS from Hetzner, Linode, Vultr, DigitalOcean, OVH, or another provider
  • want to use LarVPS without a heavy control panel
  • need a predictable install flow for Laravel, WordPress, PHP apps, or small Node workloads
  • prefer managing sites from cloud.larvps.com instead of living in SSH all day

What LarVPS expects from the server

LarVPS is intentionally narrow about support.

At the moment, the best-supported install targets are:

  • Ubuntu 22.04 LTS
  • Ubuntu 24.04 LTS

That constraint is a good thing. It keeps the install flow more stable and reduces the “works on one image, breaks on another” chaos that happens when a product tries to support every Linux flavor too early.

For a clean install, your server should also have:

  • root SSH access
  • outbound internet access
  • enough free disk for package installs and runtime files
  • a working APT configuration
  • no broken firewall state left over from a previous panel

Start in the dashboard, not in the terminal

LarVPS is built around a dashboard-first flow.

Open cloud.larvps.com, sign in, and create a new server entry. The UI gives you the connection command and keeps the team context, token, and API endpoint consistent.

That matters more than it sounds. It prevents common mistakes like:

  • linking the VPS to the wrong team
  • copying an expired or partial token
  • using an old API endpoint
  • forgetting which environment the machine belongs to

Run a preflight check before installation

Before you install anything, run the LarVPS preflight.

The preflight is there to answer one question:

“Is this VPS healthy enough to install LarVPS safely?”

It checks things like:

  • supported Ubuntu version
  • root privileges
  • CPU architecture
  • available RAM and disk headroom
  • systemd availability
  • APT lock issues
  • DNS reachability
  • outbound HTTPS connectivity
  • current UFW state

If you want a human-readable summary:

Terminal window
larvps system:preflight --short

If you want structured output for tooling:

Terminal window
larvps system:preflight --json

On a brand-new VPS, the best outcome is a clear “ready” result. If you get warnings, fix them first instead of hoping the installer will power through.

Run the connect command as root

After the server entry is created in the dashboard, LarVPS gives you a single connection command.

Run it as root over SSH.

The exact command can change over time, but the pattern is always the same:

  • fetch installer
  • validate environment
  • install the agent
  • store remote API/token
  • begin heartbeat reporting

You do not need to manually stitch together local config files or create your own token layout. The dashboard already knows what team and control plane the server should belong to.

What happens during installation

The install flow is intentionally conservative.

For a supported Ubuntu VPS, LarVPS will:

  • check the operating system version
  • update package metadata
  • install required system packages
  • prepare the runtime needed by the agent and hosted sites
  • configure firewall behavior safely
  • register the server with the cloud control plane
  • start the agent daemon

The important part is that the installer now behaves more honestly than a lot of older server scripts.

If something critical fails, it should stop and tell you why instead of pretending the machine is “done” while background pieces are still broken.

How to know the connection worked

After the installer finishes, go back to the Servers page in the dashboard.

A healthy server should move through a very clear sequence:

  • Connecting
  • Heartbeat live
  • Connected

The server row should then start showing basic inventory such as:

  • operating system
  • server IP
  • agent version
  • heartbeat recency

Once that is visible, you are ready to move into the normal LarVPS path:

  1. create a site
  2. connect DNS
  3. issue SSL
  4. configure backups

The most common reasons a VPS fails to connect

Most failed installs are not random. They usually fall into a short list.

1. The image is not a clean Ubuntu 22.04 or 24.04 install

If the VPS was provisioned from a customized image with half-configured packages, old firewall rules, or a previous panel, the installer may run into inconsistent system state.

Best fix:

  • start from a clean Ubuntu image
  • run preflight again

2. APT is locked or broken

This usually happens when:

  • unattended upgrades are still running
  • another package process is open
  • the server image has a half-finished package transaction

Best fix:

  • wait for the package process to finish
  • verify APT is healthy
  • rerun preflight before retrying install

3. Outbound network restrictions

Some VPS templates or cloud firewalls can block package mirrors or HTTPS traffic in unexpected ways.

Best fix:

  • verify the server can reach Ubuntu package sources
  • verify it can reach LarVPS download and API endpoints

4. UFW or firewall state is already in a strange condition

This is one of the classic “works on some servers, breaks on others” problems.

One server has no firewall at all. Another has UFW installed but inactive. Another has a cloud-init image with existing rules. Another has an old panel’s rule set still attached.

LarVPS now handles UFW more safely than before, but a messy pre-existing firewall state can still make any install less predictable.

Best fix:

  • prefer fresh images
  • let preflight tell you about firewall state before install

5. The command was copied with shell syntax mistakes

This sounds basic, but it happens all the time with long install or connect commands.

Common examples:

  • extra spaces after =
  • broken line continuations
  • copying only half the command

If you are copying flags manually, be exact.

Why this dashboard-first flow matters

A lot of VPS tools assume the terminal is the product.

LarVPS treats the terminal as a necessary step, not the main experience.

That is a big difference when you are managing:

  • multiple client servers
  • team-level integrations
  • site-first workflows
  • repeated tasks like SSL, backups, DB exports, and DNS changes

Once the server is connected, you should be able to do most normal work in the dashboard instead of juggling one-off shell history on every box.

After the heartbeat is healthy, do this in order:

  1. Create your first site.
  2. Decide whether DNS will be Auto via Cloudflare or Manual DNS.
  3. Point the domain and wait for propagation.
  4. Issue SSL once DNS is correct.
  5. Set up backups before traffic grows.

If you are starting with Laravel specifically, read the deployment guide next:

How to Deploy a Laravel App on a VPS Without Docker

If your next step is domain setup, go here:

Cloudflare DNS Setup for VPS Sites: Auto vs Manual

Final takeaway

The fastest way to get LarVPS working is also the safest:

  • use a clean Ubuntu 22.04 or 24.04 VPS
  • start from the dashboard
  • run preflight first
  • connect as root
  • wait for heartbeat before moving on to sites

That flow avoids most installation drama and gives you a predictable base for everything that comes after.

Stop wrestling with your servers

Use the dashboard-first flow to connect Ubuntu servers, then manage sites, DNS, SSL, and backups without panel bloat.

Keep reading

View all articles