Open DigneZzZ opened 1 month ago
I fixed the script hanging issue during package installation by removing background execution and output redirection in the get_xray_core
function. I also modified the install_package
function to suppress installation logs using quiet mode flags and output redirection, while keeping errors visible for debugging.
Special for @iamtheted
Enhanced the usage
function in Marzban and Marzban-node CLI for improved readability and functionality.
Marzban:
edit
: Opens docker-compose.yml
for editing.edit-env
: Opens .env
for editing.Marzban-node: Enhanced visual layout of the help menu for easier navigation and readability.
These updates improve the user experience by adding new functionality and making CLI instructions clearer and more visually organized.
I really appreciate you! This will make things easier for sure.
بررسی نشد ؟؟
tnx!!!!!!!!!!!!!
عجیبه که چرا pr های به درد بخور دیر تایید میشه اصلا سینت انگار ول کرده رفته
امیدوارم زودتر بررسی بشه این pr
I hope so Marzban check and add this PR 🙏 as soon as possible Thanks to Marzban🌹 Thanks to Alexey🌹
خیلی کاربردی هست امیدوارم زودتر بیاد رو پنل ،✌️😎
I hope so Marzban check and add this PR 🙏 as soon as possible Thanks to Marzban Thanks to Alexey 😎✌️ you are best brooo
Надеюсь, Marzban проверит и добавит этот PR 🙏 как можно скорее Спасибо Marzban Спасибо Алексею 😎✌️ Ты лучший, братан
این خیلی کاربردی و مفید هست و امیدوارم زودتر مرج بشه 👍
After testing the script, we found out some points:
1.MySQL username is set to marzban while the default is root and that's what backup scripts use.
2.There's no PhpMyAdmin included, The default password is set to the word "password" so if user decides to setup PhpMyAdmin, he MUST change the password and if he forgets the default password will be the word "password". I believe the script must ask for a password in the first place, choosing a default one is not reasonable.
3.MySQL version is set to 8.3 while it has to be latest
I believe we need to include the default docker file in marzban's document and only add a step in the script to ask for a password. no need for the extra stuff which makes it super complex.
After testing the script, we found out some points:
1.MySQL username is set to marzban while the default is root and that's what backup scripts use.
2.There's no PhpMyAdmin included, The default password is set to the word "password" so if user decides to setup PhpMyAdmin, he MUST change the password and if he forgets the default password will be the word "password". I believe the script must ask for a password in the first place, choosing a default one is not reasonable.
3.MySQL version is set to 8.3 while it has to be latest
I believe we need to include the default docker file in marzban's document and only add a step in the script to ask for a password. no need for the extra stuff which makes it super complex.
The message above doesn’t quite match reality.
But I’ll make some adjustments.
Implemented Adjustments:
marzban
user.
marzban
user, one will be generated automatically.ROOT
user and MySQL ROOT PASSWORD
, but Marzban will interact with the database using the marzban user..env
file. command:
- --mysqlx=OFF # Disables MySQL X Plugin to save resources if X Protocol isn't used
- --bind-address=127.0.0.1 # Restricts access to localhost for increased security
- --character_set_server=utf8mb4 # Sets UTF-8 character set for full Unicode support
- --collation_server=utf8mb4_unicode_ci # Defines collation for Unicode
- --log-bin=mysql-bin # Enables binary logging for point-in-time recovery
- --binlog_expire_logs_seconds=1209600 # Sets binary log expiration to 14 days
- --host-cache-size=0 # Disables host cache to prevent DNS issues
- --innodb-open-files=1024 # Sets the limit for InnoDB open files
- --innodb-buffer-pool-size=256M # Allocates buffer pool size for InnoDB
- --innodb-log-file-size=64M # Sets InnoDB log file size to balance log retention and performance
- --innodb-log-files-in-group=2 # Uses two log files to balance recovery and disk I/O
- --general_log=0 # Disables general query log for lower disk usage
- --slow_query_log=1 # Enables slow query log for performance analysis
- --slow_query_log_file=/var/lib/mysql/slow.log # Logs slow queries for troubleshooting
- --long_query_time=2 # Defines slow query threshold as 2 seconds
command:
- --bind-address=127.0.0.1 # Restricts access to localhost for increased security
- --character_set_server=utf8mb4 # Sets UTF-8 character set for full Unicode support
- --collation_server=utf8mb4_unicode_ci # Defines collation for Unicode
- --host-cache-size=0 # Disables host cache to prevent DNS issues
- --innodb-open-files=1024 # Sets the limit for InnoDB open files
- --innodb-buffer-pool-size=256M # Allocates buffer pool size for InnoDB
- --binlog_expire_logs_seconds=1209600 # Sets binary log expiration to 14 days (2 weeks)
- --innodb-log-file-size=64M # Sets InnoDB log file size to balance log retention and performance
- --innodb-log-files-in-group=2 # Uses two log files to balance recovery and disk I/O
- --innodb-doublewrite=0 # Disables doublewrite buffer (reduces disk I/O; may increase data loss risk)
- --general_log=0 # Disables general query log to reduce disk usage
- --slow_query_log=1 # Enables slow query log for identifying performance issues
- --slow_query_log_file=/var/lib/mysql/slow.log # Logs slow queries for troubleshooting
- --long_query_time=2 # Defines slow query threshold as 2 seconds
I ran the script with the first command (installed marzban with mysql) and gave this error on Ubuntu 24.04 and 22.04. "Invalid version format. Please enter a valid version (e.g. v0.5.2)" Then I specified the version as well, but the same error.
I ran the script with the first command (installed marzban with mysql) and gave this error on Ubuntu 24.04 and 22.04.
"Invalid version format. Please enter a valid version (e.g. v0.5.2)"
Then I specified the version as well, but the same error.
Which command?
I ran the script with the first command (installed marzban with mysql) and gave this error on Ubuntu 24.04 and 22.04. "Invalid version format. Please enter a valid version (e.g. v0.5.2)" Then I specified the version as well, but the same error.
Which command?
sudo bash -c "$(curl -sL https://github.com/Gozargah/Marzban-scripts/raw/master/marzban.sh)" @ install --database mysql
I ran the script with the first command (installed marzban with mysql) and gave this error on Ubuntu 24.04 and 22.04.
"Invalid version format. Please enter a valid version (e.g. v0.5.2)"
Then I specified the version as well, but the same error.
Which command?
sudo bash -c "$(curl -sL https://github.com/Gozargah/Marzban-scripts/raw/master/marzban.sh)" @ install --database mysql
No wonder, this PR hasn’t been merged yet, so this command can’t work.
I ran the script with the first command (installed marzban with mysql) and gave this error on Ubuntu 24.04 and 22.04.
"Invalid version format. Please enter a valid version (e.g. v0.5.2)"
Then I specified the version as well, but the same error.
Which command?
sudo bash -c "$(curl -sL https://github.com/Gozargah/Marzban-scripts/raw/master/marzban.sh)" @ install --database mysql
No wonder, this PR hasn’t been merged yet, so this command can’t work.
Oh thanks, is there any way we can test it?
I ran the script with the first command (installed marzban with mysql) and gave this error on Ubuntu 24.04 and 22.04.
"Invalid version format. Please enter a valid version (e.g. v0.5.2)"
Then I specified the version as well, but the same error.
Which command?
sudo bash -c "$(curl -sL https://github.com/Gozargah/Marzban-scripts/raw/master/marzban.sh)" @ install --database mysql
No wonder, this PR hasn’t been merged yet, so this command can’t work.
Oh thanks, is there any way we can test it?
yes, test it from here commands https://github.com/DigneZzZ/Marzban-scripts-beta
I tested and found that phpMyAdmin is not getting installed which I believe should be the part of the instructions. Thank
I tested and found that phpMyAdmin is not getting installed which I believe should be the part of the instructions. Thank
I don’t agree with the practice of installing PMA directly with the script, as it creates an additional security risk for the server. You can install it yourself if needed.
I tested and found that phpMyAdmin is not getting installed which I believe should be the part of the instructions. Thank
I don’t agree with the practice of installing PMA directly with the script, as it creates an additional security risk for the server.
Yeah, it makes sense but if you make it optimal it would be nice, so users have choice. But anyway, thanks for your efforts and really appreciate your contribution
Everything is perfect! Thanks a lot!
Except for the docker sample for MySQL, which is still set to 8.3, shouldn't be latest or lts ?
Except for the docker sample for MySQL, which is still set to 8.3, shouldn't be latest or lts ?
..................
I'm significantly improved the original Marzban installation script.
Key Changes:
Added MySQL Support:
--database mysql
during installation.docker-compose.yml
with MySQL configuration and updates the.env
file accordingly.Enhanced Xray-core Version Selection Interface:
get_xray_core
function now features a user-friendly, colored menu.Suppressed Logs During Installation and Execution:
Brief Usage Instructions:
Install Marzban with MySQL:
Install Marzban with MariaDB:
Install Marzban with MariaDB and Dev branch:
Install Marzban with MariaDB and Manual version :
Update or Change Xray-core Version: