Updated

SSH from your phone is painful: troubleshoot your server from Telegram instead

You're on a train, at dinner, or half asleep, and something on your server is wrong. You could open an SSH app on your phone and start typing docker logs --since 30m --tail 200 … on a glass keyboard. This guide shows another way to fix server problems from your phone, or at least find out what's wrong: in OpsMate's Telegram bot, you describe the problem in a sentence, the AI runs the checks over SSH, and you approve anything risky yourself. It covers what you need to set up first, what happens to each command, what's reasonable to do from a phone, and when to put the phone down and go back to a real computer. Getting alerts into Telegram in the first place is a separate topic, covered in Server alerts in Telegram. This guide starts where that one leaves off: you know something is wrong, and all you have is your phone.

The bot replies in English or Chinese based on your OpsMate account language or, if you haven't set one, your Telegram language, and you can switch with /language. In AI chat, the AI replies in your current language. This guide uses the English labels.

Why SSH from your phone is painful

Phone SSH apps such as Termius or Blink Shell work, and for a single uptime they're fine. Real troubleshooting is where it gets painful:

If you're comfortable with all that, a phone SSH client is a perfectly good tool. The rest of this guide is for when you'd rather say what's wrong in one sentence and read a summary.

Before you start: alerts need no cloud credentials, remote SSH does

These are two separate things, and they have different requirements:

What you wantWhat it needs
Receive server alerts in a Telegram private chatA linked Telegram account and alert settings. No cloud credentials.
Run SSH on the server from Telegram (AI SSH mode)The server needs an SSH key stored in OpsMate's cloud. Without it, the bot tells you that no SSH key is configured and AI SSH mode can't be used.

This is the trade-off, stated plainly. By default, the OpsMate desktop app keeps your SSH credentials on your own machine. The Telegram bot runs in the cloud, so to reach your server from Telegram, the key for that server has to be stored in the cloud too. Decide per server whether that's acceptable. A few practical options:

Either way, you can still receive alerts in Telegram for every server. Only the remote SSH part needs the cloud key.

1. Enter AI SSH mode and describe the problem in one message

In your private chat with the OpsMate bot, send /servers, pick the server, and tap πŸ€– AI chat. That puts you in AI SSH mode. From then on, you don't type shell commands; you send ordinary messages to the AI. That's the difference from a plain Telegram SSH bot, which relays whatever you type straight to a shell: here you describe the problem, the AI picks the commands, and each command goes through a safety check first.

If you came from an alert, note that the alert card's πŸ“‹ View and handle button does not take you into AI SSH mode. It opens the issue's details (the issue, severity, server, status, evidence and when it was last updated) with the buttons Recollect, Snooze, Intervene, AI advice and Mark resolved. AI advice gives text suggestions only and runs no commands. Intervene is for describing the situation in your own words, and you finish it with /done or /cancel. Neither of them is AI SSH mode. The alert card is where you look at the issue; the AI chat you open from /servers is where commands run.

A good first message names the symptom, the service and roughly when it started, and says what you don't want done yet:

The API has been returning 502 since about 08:40. Check the app container and Nginx. Don't restart anything yet.

Short is fine; you're typing on a phone. "Site is slow since 9pm, check load, memory and disk" gives the AI enough to start.

2. What happens to each command: run directly, or wait for your approval

The AI decides which commands to run. Not every command needs your approval. Each one goes through a safety check first:

The command…What you seeWhat happens
passes the safety checkA separate πŸ“Ÿ Terminal output message with the raw outputIt runs directly, and the AI continues analysing the output on its own
doesn't pass the checkA ⚠️ Command pending confirmation (…) message, with the risk level in brackets, showing the command and the reason it was heldIt only runs after you tap βœ… Approve. The output then arrives as a separate πŸ“Ÿ Terminal output message, but the AI does not continue analysing on its own: the output is kept in the session, and the AI analyses it together with your next message.

To change a held command, tap ✏️ Edit. The edited command goes through the same safety check again:

A few rules that matter when you're deciding on the move:

The raw πŸ“Ÿ Terminal output messages are your evidence. The AI's summary is built from them, so when the summary says "the disk is full", scroll up and find the df -h line that shows it.

3. Read the evidence, then pick the next step

Each AI reply comes with next-step suggestion buttons such as ▢️ 1. …, listing what it would check or do next. Tap one to continue with that step instead of typing it out. A tap counts as a new message: the AI starts a new turn, the 3-round limit starts over, and it uses AI calls just like a message you type.

If you'd rather run a command yourself, tap ⏹ Exit AI mode to go back to manual SSH in the same chat. A few short commands are worth knowing by heart for exactly this situation:

uptime
df -h
free -h
docker ps -a

uptime shows load averages (compare them with the number of CPU cores), df -h shows whether a disk is full, free -h shows available memory (read the available column), and docker ps -a shows which containers are up, restarting or exited. None of them tells you why something broke; they tell you where to look next.

Can you fix a server from your phone?

Sometimes, if the fix is small and easy to undo. Reasonable from Telegram:

For anything bigger, the phone is the wrong tool, even when the AI suggests the step and the button is right there.

When to go back to a real computer

Put the phone down and open a laptop when:

On a computer, OpsMate's web app puts the SSH terminal and the AI on the same server page, so you can pick up where the phone left off; see AI and SSH commands in one workspace. If the whole site is down and you're on your own, the first-15-minutes order in Site down at 2 a.m. works from a phone as well as a laptop.

Boundaries

Illustrative examples

These three scenes are illustrative examples, not real customer cases. Names, services and times are made up.

On the train (indie developer). Leo runs a small SaaS on one VPS and is on a 40-minute commute when a user writes that the dashboard shows a 502. He sends /servers, picks the VPS, taps πŸ€– AI chat and sends: "dashboard 502 since 08:40, check the app container and nginx, don't restart anything." Round 1 runs docker ps -a and ss -ltnp together: the app container is Restarting, and nothing is listening on port 3000. Round 2 reads the app's recent logs: the first error is a refused connection to Redis. Round 3 shows the redis container exited. The AI's suggestion to restart redis arrives as a held ⚠️ Command pending confirmation message with its risk level and reason. Leo has already copied the log lines into his notes, so he taps βœ… Approve for that one container. The restart output arrives as a πŸ“Ÿ Terminal output message, and the AI waits for him, so he sends "restarted, check that app stays up now". The AI reads the restart output together with that message and runs a new round of checks. Why Redis exited is a question for his laptop that evening.

No laptop (founder). Mia, a non-technical founder, is at a family dinner when a customer says checkout is very slow. She doesn't know the commands, so she writes: "customers say checkout is very slow, what's going on? don't change anything." The checks that pass run on their own: load is normal and memory is fine, but df -h shows the data disk at 97%. The AI proposes deleting old files to free space, and that command arrives as held, with the reason. Mia doesn't understand what would be deleted, so she doesn't approve it; it simply expires after 30 minutes. She copies the summary and the df -h output, removes the server's address, and sends it to the contractor who set up the server. Not approving is a valid answer.

Woken at night (on-call teammate). Sam is on call for a five-person team and gets an alert at 3 a.m. that a background worker keeps dying. From bed, he opens the alert's πŸ“‹ View and handle to read the issue details, then goes to /servers, picks the server, taps πŸ€– AI chat and asks the AI to check the worker container and memory. Over three rounds, the evidence points to the worker being killed for running out of memory, with memory climbing since yesterday's deploy. The restart policy already brought the worker back and the queue is draining. The real fix, rolling back yesterday's deploy or raising the memory limit, is a big change that needs watching afterwards. So Sam writes three lines in the team chat (symptom, evidence, proposed change and how to undo it) and leaves the decision for the morning at a computer. He can't hand approvals in his session to the team lead anyway: only the person who started a session can approve its commands.

AI diagnostic prompt

Short enough to type on a phone:

Something's wrong with [service] since about [time]. Check it without changing anything: load, memory, disk, the service's status and its recent errors. Tell me what's confirmed and what's a guess. If a change is needed, suggest the smallest step and how to undo it, and wait for me.

Next checks

Try OpsMate

500 free AI calls per month and unlimited servers. The desktop app keeps your SSH credentials on your own machine by default; AI SSH mode in Telegram is the exception and needs an SSH key stored in the cloud for that server.

Need help interpreting the evidence?

OpsMate helps developers and operators investigate with AI. Review the evidence. Command output is sent to cloud AI for analysis; redact sensitive information first.

Start free Desktop with local credentials

Troubleshooting guides