-
Notifications
You must be signed in to change notification settings - Fork 86
Description
Hello,
I have been trying to install XUI.one on a fresh installation of Ubuntu Server 24.04 for 2 days now and I have noticed many errors:
To start, I think it is better to use sudo because this distribution has a default user and nothing is executed as root anymore but that does not prevent the script from working.
For install_dep.sh:
The -y --force-yes option is deprecated, this means that it will not work later.
The --allow- option followed by the correct command:
--allow-change-held-packages ; --allow-downgrades ; --allow-insecure-repositories ; --allow-remove-essential or --allow-unauthenticated.
Source.list :
Adding repositories is not compliant and creates errors, 404 in particular.
Ubuntu no longer uses /etc/apt/sources.list but /etc/apt/sources.list.d/repo_name.sources.
In the case of the Ubuntu repository, it is /etc/apt/sources.list.d/ubuntu.sources.
The syntax is different and simplified:
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
## Ubuntu distribution repository
##
## The following settings can be adjusted to configure which packages to use from Ubuntu.
## Mirror your choices (except for URIs and Suites) in the security section below to
## ensure timely security updates.
##
## Types: Append deb-src to enable the fetching of source package.
## URIs: A URL to the repository (you may add multiple URLs)
## Suites: The following additional suites can be configured
## <name>-updates - Major bug fix updates produced after the final release of the
## distribution.
## <name>-backports - software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
## Components: Aside from main, the following components can be added to the list
## restricted - Software that may not be under a free license, or protected by patents.
## universe - Community maintained packages. Software in this repository receives maintenance
## from volunteers in the Ubuntu community, or a 10 year security maintenance
## commitment from Canonical when an Ubuntu Pro subscription is attached.
## multiverse - Community maintained of restricted. Software from this repository is
## ENTIRELY UNSUPPORTED by the Ubuntu team, and may not be under a free
## license. Please satisfy yourself as to your rights to use the software.
## Also, please note that software in multiverse WILL NOT receive any
## review or updates from the Ubuntu security team.
##
## See the sources.list(5) manual page for further settings.
Type: deb
URIs: http://archive.ubuntu.com/ubuntu/
Suites: noble noble-updates noble-backports
Components: main universe restricted multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg
## Ubuntu security updates. Aside from URIs and Suites,
## this should mirror your choices in the previous section.
Types: deb
URIs: http://security.ubuntu.com/ubuntu/
Suites: noble-security
Components: main universe restricted multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg
If you want to add the source repository, just modify the first line Types: by adding deb-src; same for suites and Components :
Types: deb deb-src
URIs: http://security.ubuntu.com/ubuntu/
Suites: noble noble-security noble-backports noble-updates
Components: main universe restricted multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg
Finally, regarding the sources, unless I'm mistaken, the partner repository was removed some time ago (20.04? 18.04?).
Missing dependencies and dups :
Still adding repositories, the podman repository does not have a stable version, at least for now, of ubuntu 24.04, which gives a 404 error, just like mariadb 10.6.
And I refer you to my remark above concerning the file syntax, it is no longer necessary to specify the architecture.
starting from line 735, there are many duplicates of software, non-existent software for "Noble":
duplicates:
MARIADB-COMMON
DEBHELPER
CDBS
LINTIAN
BUILD-ESSENTIAL
FAKEROOT
DEVSCRIPTS
DH-MAKE
WGET
LIBMARIADBD-DEV
BUILD-ESSENTIAL
UNZIP
ZIP
LIBGEOIP-DEV
CURL
WGET
GIT
MCRYPT
LIBGEOIP-DEV
non-existent software for Noble:
sqlite3-dev
oniguruma
oniguruma-dev
liboniguruma
liboniguruma-dev
apache2-threaded-dev
firebird1.5-dev
firebird1.5-dev
firebird1.6-dev
firebird1.6-dev
firebird1.7-dev
firebird1.7-dev
firebird1.8-dev
firebird1.8-dev
firebird1.9-dev
firebird1.9-dev
firebird2.0-dev
firebird2.0-dev
firebird2.1-dev
firebird2.2-dev
firebird2.2-dev
firebird2.3-dev
firebird2.3-dev
firebird2.4-dev
firebird2.4-dev
firebird2.5-dev
python
python2
python33
python-paramiko
python2-paramiko
python-pip
python2-pip
dist-upgrade
build-dep
alibgnutls28-dev
alibx264-dev
alibbz2-dev
pcre3
libpcre
libpcre-dev
pcre
libpcre2
pcre2
mcrypt-dev
libmcrypt-devel
mcrypt-devel
libgeoip-devel
geoip-devel
python-software-properties
Python2 is no longer supported under Ubuntu 24.04, there are solutions like 2to3 that allow the transition.
We can always try to compile it to install it but knowing that libncursesw5-dev is missing, it does not work correctly as is.
Syntax errors and optimizations :
The syntax for the installation slows down the script, it is better to run the command:
sudo apt install software1 software2 software3 ...or
softlist="software1 software2 software3"
sudo apt install $softlistLine 829, there is a space missing :
apt-get -y --force-yesinstall git-coreLine 833; 852 and 861, there is a double "a" in apt:
aapt-get -y --force-yes install libgnutls28-dev
aapt-get -y --force-yes install libx264-dev
aapt-get -y --force-yes install libbz2-devLine 872, there is a space missing and there is a duplicate command (a forgotten dependencies?)
apt-get -y --force-yesapt-get -y install pcre3Installing apache and php can be shorter starting from line 906:
sudo apt install libapache2-mod-php7.* php7.0 php7.1 php7.2 php7.3 php7.4 php7.*-common php7.*-fpm php7.*-cli php7.*-mysql php7.*-gd php7.*-mcrypt php7.*-curl php7.*-imap php7.*-xmlrpc php7.*-xsl php7.*-intl php7.*-dev php7.*-mbstring
sudo apt install libapache2-mod-php8.* php8.0 php8.1 php8.2 php8.3 php8.4 php8.*-common php8.*-fpm php8.*-cli php8.*-mysql php8.*-gd php8.*-mcrypt php8.*-curl php8.*-imap php8.*-xmlrpc php8.*-xsl php8.*-intl php8.*-dev php8.*-mbstringFatals errors :
And finally, the last commands crash the scripts:
chkconfig is not an ubuntu 24.04 command :
chkconfig mariadb onthe service command is misused :
service start mariadbthe correct syntax would be:
service mariadb startBut given, still unless I'm mistaken, it's useless since we use systemctl which is a wrapper for systemd as a service.
Install.python3
On the other hand, for install.python3 I don't understand why running bash in python, it's a bit nonsense and a (big?) loss of performance, right?
It's also a way to accumulate errors if a python dependency is missing for example.
Especially since the entire script, with a few exceptions, is in bash executed by python.
Same remark as for install_dep.sh some packages are not found on ubuntu 24.04 such as curl4, replaced by libcurl4t64, php-ssh2 and of course python2 (and other but i can't remember) :
rPackages = ["cpufrequtils", "iproute2", "python", "net-tools", "dirmngr", "gpg-agent", "software-properties-common", "libmaxminddb0", "libmaxminddb-dev", "mmdb-bin", "libcurl4", "libgeoip-dev", "libxslt1-dev", "libonig-dev", "e2fsprogs", "wget", "mariadb-server", "sysstat", "alsa-utils", "v4l-utils", "mcrypt", "certbot", "iptables-persistent", "libjpeg-dev", "libpng-dev", "php-ssh2", "xz-utils", "zip", "unzip"]Install.sh
Finally, regarding install.sh I would advise you to use a checksum (MD5 for example, because it is one of the fastest) and the -c option for wget, if the script crashes we can continue without re-downloading the files and creating possible errors, even if the file is overwritten.
Just like the link, I advise you to put a version file on your github repository, this way the link used by wget is dynamic and it represents less work.
GH="https://github.com/amidevous/xui.one"
latest_version=$(curl -sL "$GH/raw/refs/heads/master/version")
latest_file="$GH/raw/refs/heads/master/latest_version"
wget -c "$latest_file" -O "$latest_version"All these errors break Ubuntu 24.04, in 2 days I managed to make the server work locally 4/5 hours BUT it crashed and restarted at each entry/exit.
A configuration change, error 502; I launch a direct streaming: error 502; I do nothing... 502... I change the configuration page... yes, error 502.
Since then impossible to restart it, I reinstalled completely but impossible to restart anything.
Best regards.
Edit :
I managed to reinstall, I haven't tested it yet but it's definitely install-dep.sh that crashes the installation because of chkconfig mariadb on and service start mariadb.
I'm currently working on a fork to resolve and optimize these issues.
I've noticed more issues with install.python3 but I haven't had time to see the error properly or check if I have any traces in the logs.