distillium/remnawave-backup-restore
Sobre
Backup and restore script for Remnawave directory and database
Dados e análiseCrescimento medido de estrelas
- em 24 h
- +2
- em 7 dias
- +5
- em 15 dias
- +17
- em 1 mês
- Coletando histórico
Variações líquidas em períodos sobrepostos, não totais diários. Medições ausentes ficam em branco. Estrelas indicam interesse, não qualidade.
README.md
Original
Backup and restore for the Remnawave panel and your Telegram shop:
scheduled, to Telegram or S3, encrypted, with selective restore.
English · Русский
What the menu looks like

[!CAUTION] The script backs up only the Remnawave directory and database and, optionally, a Telegram shop. Other services are up to you.
[!IMPORTANT] Google Drive is not supported since 4.3.0: the script switches to Telegram on its own. For backups over 50 MB, connect S3.
Installation
curl -o ~/backup-restore.sh https://raw.githubusercontent.com/distillium/remnawave-backup-restore/main/backup-restore.sh && chmod +x ~/backup-restore.sh && ~/backup-restore.sh
Requires root. After installation, open the menu with rw-backup.
Details
Features
- manual or scheduled backups: panel and bot, panel only or bot only
- the panel's Docker database and external PostgreSQL
- upload to Telegram (direct chat or group topic) or to S3 storage, up to 5 at once
- retention on the server (days or hours) and in each S3 separately
- disk and S3 usage, with an optional S3 limit
- encryption with an age key
- selective restore: everything, database only or files only
- S3 and Telegram proxy tests with clear error diagnostics
- new version notices and auto-update
Menu
| # | Item | Inside |
|---|---|---|
| 1 | Create backup now | a backup with the current settings |
| 2 | Restore from backup | pick an archive and what to restore |
| 3 | What to back up | panel, bot, backup mode |
| 4 | Where to send | Telegram or S3, list of storages |
| 5 | Schedule and retention | schedule and retention periods |
| 6 | Settings | Telegram, encryption, language, auto-update |
| 7 | Logs | backup, restore, errors, cron |
Selective restore
If a backup has both a database and files, the script asks what to restore:
| Option | What happens |
|---|---|
| Everything | database and files |
| Database only | the DB volume is recreated, files are left as they are. The panel or bot must already be installed |
| Files only | files and settings are replaced, the database is left as it is |
Handy for rolling back only the database after a failed update.
Encryption
Turn it on in Settings → Encryption. Backups are encrypted with an age public key, and only that key is kept on the server. To restore, the script asks for the private key.
Important: without the private key an encrypted backup can't be restored. Keep it away from the server.
Supported bots
| Bot | Directory |
|---|---|
| Jesus Bot | remnawave-telegram-shop |
| Private Jesus Bot | rwp-shop |
| Machka Bot | remnawave-tg-shop |
| Snoups Bot | remnashop |
| Minishop Bot | remnawave-minishop |
Moving to another server
◦ Panel only: moving to a new server
- In Cloudflare, point the panel subdomain to the new IP. If other services move to the new server too, update their subdomains as well.
- Restore the directory and the database.
- Restore the domain certificates if needed.
- The access link and password stay the same as in the old panel the backup was made from.
- On every node, replace the rule for the service port (2222 by default) so the panel on the new IP can reach them. Run on each node, with your own
OLD_IPandNEW_IP:ufw delete allow from OLD_IP to any port 2222 && ufw allow from NEW_IP to any port 2222Done. All that's left is to install and set up the other services you need (e.g. kuma, beszel).
◦ Panel + node: moving to a new server
- In Cloudflare, point the subdomains of the panel and the "root" node (the one on the panel server) to the new IP. If other services move to the new server too, update their subdomains as well.
- Restore the domain certificates if needed.
- Restore the directory and the database.
- Open panel access via port 8443 (eGames script, "Panel access management").
- The access link and password stay the same as in the old panel the backup was made from.
- In node management, find the root node. It has the old server address: change it to the new one and the node comes up on its own.
- Close panel access via port 8443 the same way you opened it.
- On every external node, replace the rule for the service port (2222 by default). Run on each node, with your own
OLD_IPandNEW_IP:ufw delete allow from OLD_IP to any port 2222 && ufw allow from NEW_IP to any port 2222Done. All that's left is to install and set up the other services you need (e.g. kuma, beszel).
◦ Panel + node → "Panel only" on the current server
- Restore the directory and the database.
- The access link and password stay the same as in the old panel the backup was made from.
- Delete the old "root" node from the panel together with its inbound and host.
- Delete the
.env-nodefile from the panel server:rm /opt/remnawave/.env-nodeDone. All that's left is to install and set up the other services you need (e.g. kuma, beszel).
◦ Panel + node → "Panel only" on a new server
- In Cloudflare, point the panel subdomain to the new IP. If other services move to the new server too, update their subdomains as well.
- Restore the domain certificates if needed.
- Restore the directory and the database.
- The access link and password stay the same as in the old panel the backup was made from.
- Delete the old "root" node from the panel together with its inbound and host.
- Delete the
.env-nodefile from the panel server:rm /opt/remnawave/.env-node
- On every node, replace the rule for the service port (2222 by default). Run on each node, with your own
OLD_IPandNEW_IP:ufw delete allow from OLD_IP to any port 2222 && ufw allow from NEW_IP to any port 2222Done. All that's left is to install and set up the other services you need (e.g. kuma, beszel).
Commands and files
| Command | What it does |
|---|---|
rw-backup |
open the menu |
rw-backup backup |
back up without the menu (this is what the schedule runs) |
rw-backup restore |
restore |
rw-backup update |
update the script |
rw-backup remove |
remove the script |
Everything lives in /opt/rw-backup-restore: settings in config.env, backups in backup/, logs in logs/.
Explore projetos relacionados
Carregando…