Troubleshooting bot crashes, memory and backups
AxHost team · Updated 5 November 2026
On a small hosting plan, find the cause of a crash before restarting. This guide helps distinguish configuration errors, missing libraries and exhausted resources. It does not guarantee that every project will fit the free plan: usage depends on libraries, community size and data processing.
What 128 MB RAM and 25% CPU mean
RAM is used by your process, runtime and loaded libraries. It is not disk space. A project with only a few kilobytes of custom code can need more than 128 MB once its libraries load. Exceeding the memory limit may terminate the process. A 25% CPU limit refers to one core, not one quarter of the entire physical server.
Only run the features you need. Voice playback, browser automation, image processing and large models are unsuitable for this plan. If your project needs more resources at startup, choose suitable hosting; renaming the service will not change its limits.
The process stops immediately after startup
Start with the first specific error, rather than the final generic shutdown message. Cannot find module or ModuleNotFoundError usually means a missing dependency, incorrect module name or wrong directory. SyntaxError points to source code or an incompatible runtime. Platform login errors may indicate an invalid token or missing configuration.
If there is no application error, check memory usage and process termination events. Exit code 137 alone is not a complete diagnosis: it indicates SIGKILL, and insufficient memory is only one possible cause. Compare it with resource charts and panel information.
Memory grows while the bot is running
Watch usage after startup and after repeating the same action. If every message adds entries to a global array that are never removed, more frequent restarts are not the solution. Limit cache sizes, set expiry times and avoid loading the entire message history when you only need a few recent entries.
Process large files incrementally. Downloading a full file into memory, converting it and creating another copy can multiply peak usage. Register repeating timers only once, and release connections and temporary objects when finished. Measure changes using the same scenario so you can compare results.
The bot keeps reconnecting
Check that a second copy of your project is not running on your computer. With Telegram long polling, two instances using the same token can conflict. Do not retry network failures in an endless loop without waiting: respect platform rate limits and increase the delay between attempts.
If only one command fails, check its permissions for the relevant channel or chat. An unavailable panel-to-node connection and a bot authentication error are different problems. Do not blindly change tokens or reinstall your project during a node connection outage.
Back up before making changes
Download source files, dependency lists, a configuration example without secrets, and data your application creates. Back up a database by exporting its contents; source code alone does not include database records. Keep credentials separate and private.
For a file-based database, stop writes first or use its supported backup process. Copying a file while it is being written can produce an inconsistent backup. Occasionally test a restore in a test environment. A backup is useful only when you know it can be restored.
What to send to support
On the community Discord, include the time of the problem, your Node.js or Python runtime, the last relevant error and the most recent change. Omit tokens, passwords, access keys and database credentials. Explain whether the error occurs at startup or after a particular action. For an initial project check, also follow the bot deployment guide.