Table of Contents
Installing Apache2 webserver, MySql or MariaDB server, and the latest PHP version, onto Linux Ubuntu Server 24.04 LTS
We start with a fresh installation of Linux Ubuntu Server 24.04 LTS. I installed Ubuntu on a RAID-1 Mirror of two Western Digital Gold 4TB SATA drives, and the Ubuntu installer helped me create the software Raid-1 Mirror of the two drives. That process is another story that I will skip here.
My ultimate goal is to install and run the latest version of NextCloud 30.0.4 (released December 12, 2024) running on Apache webserver alongside OnlyOffice Document Server running on Nginx webserver, all installed on the same Ubuntu 24.04 LTS server box, and OnlyOffice integrated and working with NextCloud for multiple users to display and collaboratively edit word processing documents. It will be necessary to run Nginx listening on a non-standard http port, like TCP port 81, and using Apache listening on standard ports 80 and 443 in order to web serve NextCloud and to proxy web serve the OnlyOffice Document Server from Nginx through Apache virtual host proxy. Also note that later we will need to install PostGre database server in order to support data to dynamically run OnlyOffice Document Server.
So NOW, let's SSH into the Ubuntu 24.04 server (since we already installed OpenSSH and have opened the uncomplicated firewall (ufw) to allow our SSH connections on standard TCP port 22 using the command 'sudo ufw allow ssh').
Next, let's update the repository and software packages on the server.
sudo apt update sudo apt list --upgradeable sudo apt upgrade
Install the Apache Webserver
Now, Install the Apache2 webserver.
sudo apt install apache2
You should see something like this explaining the additional packages that will be installed as well.
The following additional packages will be installed: apache2-bin apache2-data apache2-utils libapr1t64 libaprutil1-dbd-sqlite3 libaprutil1-ldap libaprutil1t64 liblua5.4-0 ssl-cert Suggested packages: apache2-doc apache2-suexec-pristine | apache2-suexec-custom www-browser The following NEW packages will be installed: apache2 apache2-bin apache2-data apache2-utils libapr1t64 libaprutil1-dbd-sqlite3 libaprutil1-ldap libaprutil1t64 liblua5.4-0 ssl-cert . . . Do you want to continue? [Y/n] Y
After Apache is installed, the apache2.service should have automatically started and be running. Check it's status using systemctl.
systemctl status apache2
You should see output like the following:
● apache2.service - The Apache HTTP Server Loaded: loaded (/usr/lib/systemd/system/apache2.service; enabled; preset: enabled) Active: active (running) since Mon 2024-12-30 01:27:25 UTC; 3min 34s ago Docs: https://httpd.apache.org/docs/2.4/ Main PID: 24438 (apache2) Tasks: 55 (limit: 19067) Memory: 5.6M (peak: 6.7M) CPU: 43ms CGroup: /system.slice/apache2.service ├─24438 /usr/sbin/apache2 -k start ├─24440 /usr/sbin/apache2 -k start └─24441 /usr/sbin/apache2 -k start
The above output shows apache2.service is running. You may need to type q to end the status reporting and return to the SSH terminal command prompt.
If the Apache service is not running, then try starting it with systemctl.
sudo systemctl start apache2
You should also enable Apache to automatically start during each system boot. Note, however, that when we later install Nginx webserver to serve OnlyOffice Document Server, then Apache service needs to be stopped until Nginx can be configured to listen on a non-standard port. Otherwise, Nginx won't start because both Apache and Nginx will try to listen on the same standard tcp port 80. If we reboot the system while configuring various services, the apache service will start and conflict with Nginx service until Nginx is configured to listen on a non-standard port.
sudo systemctl enable apache2
Expected Output:
Synchronizing state of apache2.service with SysV service script with /usr/lib/systemd/systemd-sysv-install. Executing: /usr/lib/systemd/systemd-sysv-install enable apache2
You can check your Apache version:
apache2 -v
Expected Output:
Server version: Apache/2.4.58 (Ubuntu) Server built: 2024-10-02T12:40:51
Now, Open a web browser (user-agent) and type in the public IP address that your router forwards to the Ubuntu server. You should see the Apache2 “It Works!” Default page.
Apache2 Default Page It works! This is the default welcome page used to test the correct operation of the Apache2 server after installation on Ubuntu systems. It is based on the equivalent page on Debian, from which the Ubuntu Apache packaging is derived. If you can read this page, it means that the Apache HTTP server installed at this site is working properly. You should replace this file (located at /var/www/html/index.html) before continuing to operate your HTTP server. If you are a normal user of this web site and don't know what this page is about, this probably means that the site is currently unavailable due to maintenance. If the problem persists, please contact the site's administrator.
If you have started and/or enabled the UFW firewall on Ubuntu and can't see the Apache2 Default Page, then you likely need to open standard webserver ports in the firewall for http (port 80) and https (port 443) requests. Run these commands.
sudo ufw allow http sudo ufw allow https
To list all currently loaded Apache modules managed by a2enmod on Ubuntu, use the command:
apache2ctl -M
Explanation:
- apache2ctl: This is the command used to control the Apache web server on Ubuntu.
- -M: This flag tells apache2ctl to display a list of all currently loaded modules.
Key points: To see only enabled modules, run apache2ctl -M. If you want to see a list of all available modules (both enabled and disabled), you can explore the files within the /etc/apache2/mods-available/ directory (see listed below).
How do we enable the mod_rewrite module that is supposedly already a part of apache2? Following is a list of modules in my /etc/apache2/mods-available/ subdirectory on this Ubuntu server with Apache2 installed. Notice “rewrite.load” which I assume is the rewrite module that must be enabled. It is not located in my sites-available subdirectory. It is not yet enabled in the /etc/apache2/mods-enabled/ subdirectory.
/etc/apache2/mods-available$ ls access_compat.load cache_disk.conf heartmonitor.load negotiation.conf rewrite.load actions.conf cache_disk.load http2.conf negotiation.load sed.load actions.load cache.load http2.load php8.4.conf session_cookie.load alias.conf cache_socache.load ident.load php8.4.load session_crypto.load alias.load cern_meta.load imagemap.load proxy_ajp.load session_dbd.load allowmethods.load cgid.conf include.load proxy_balancer.conf session.load asis.load cgid.load info.conf proxy_balancer.load setenvif.conf auth_basic.load cgi.load info.load proxy.conf setenvif.load auth_digest.load charset_lite.load lbmethod_bybusyness.load proxy_connect.load slotmem_plain.load auth_form.load data.load lbmethod_byrequests.load proxy_express.load slotmem_shm.load authn_anon.load dav_fs.conf lbmethod_bytraffic.load proxy_fcgi.load socache_dbm.load authn_core.load dav_fs.load lbmethod_heartbeat.load proxy_fdpass.load socache_memcache.load authn_dbd.load dav.load ldap.conf proxy_ftp.conf socache_redis.load authn_dbm.load dav_lock.load ldap.load proxy_ftp.load socache_shmcb.load authn_file.load dbd.load log_debug.load proxy_hcheck.load speling.load authn_socache.load deflate.conf log_forensic.load proxy_html.conf ssl.conf authnz_fcgi.load deflate.load lua.load proxy_html.load ssl.load authnz_ldap.load dialup.load macro.load proxy_http2.load status.conf authz_core.load dir.conf md.load proxy_http.load status.load authz_dbd.load dir.load mime.conf proxy.load substitute.load authz_dbm.load dump_io.load mime.load proxy_scgi.load suexec.load authz_groupfile.load echo.load mime_magic.conf proxy_uwsgi.load unique_id.load authz_host.load env.load mime_magic.load proxy_wstunnel.load userdir.conf authz_owner.load expires.load mpm_event.conf ratelimit.load userdir.load authz_user.load ext_filter.load mpm_event.load reflector.load usertrack.load autoindex.conf file_cache.load mpm_prefork.conf remoteip.load vhost_alias.load autoindex.load filter.load mpm_prefork.load reqtimeout.conf xml2enc.load brotli.load headers.load mpm_worker.conf reqtimeout.load buffer.load heartbeat.load mpm_worker.load request.load
Enable mod_rewrite and restart apache2.
sudo a2enmod rewrite
Output:
Enabling module rewrite. To activate the new configuration, you need to run: systemctl restart apache2
So restart apache2 as directed.
sudo systemctl restart apache2
Then re-check the modules that are loaded.
apache2ctl -M
The results shown next now include the rewrite_module.
Loaded Modules: core_module (static) so_module (static) watchdog_module (static) http_module (static) log_config_module (static) logio_module (static) version_module (static) unixd_module (static) access_compat_module (shared) alias_module (shared) auth_basic_module (shared) authn_core_module (shared) authn_file_module (shared) authz_core_module (shared) authz_host_module (shared) authz_user_module (shared) autoindex_module (shared) deflate_module (shared) dir_module (shared) env_module (shared) filter_module (shared) mime_module (shared) mpm_prefork_module (shared) negotiation_module (shared) php_module (shared) reqtimeout_module (shared) rewrite_module (shared) setenvif_module (shared) status_module (shared)
Install MariaDB
Install mariadb-server and mariadb-client: Install “mariadb-server” and “mariadb-client” on a Linux Ubuntu server to set up a fully functional MariaDB database system, allowing you to store and manage data on your server, with the “mariadb-server” providing the core database functionality and the “mariadb-client” enabling you to interact with the database using commands from your terminal or applications, essentially acting as a tool to access and manipulate data stored within the database.
Key points about installing both packages:
Database functionality:
“mariadb-server” is the core component that runs the database on your server, allowing applications to store and retrieve data.
User interaction:
“mariadb-client” provides a command-line interface to interact with the database, allowing you to execute SQL queries to manage data directly on the server.
MariaDB can be used in place of MySQL. Enter the following command to install MariaDB on Ubuntu Server 24.04 LTS.
sudo apt install mariadb-server mariadb-client
Interactive Output:
Reading package lists... Done Building dependency tree... Done Reading state information... Done The following additional packages will be installed: galera-4 libcgi-fast-perl libcgi-pm-perl libclone-perl libconfig-inifiles-perl libdbd-mysql-perl libdbi-perl libencode-locale-perl libfcgi-bin libfcgi-perl libfcgi0t64 libhtml-parser-perl libhtml-tagset-perl libhtml-template-perl libhttp-date-perl libhttp-message-perl libio-html-perl liblwp-mediatypes-perl libmariadb3 libmysqlclient21 libsnappy1v5 libtimedate-perl liburi-perl liburing2 mariadb-client-core mariadb-common mariadb-plugin-provider-bzip2 mariadb-plugin-provider-lz4 mariadb-plugin-provider-lzma mariadb-plugin-provider-lzo mariadb-plugin-provider-snappy mariadb-server-core mysql-common pv socat Suggested packages: libmldbm-perl libnet-daemon-perl libsql-statement-perl libdata-dump-perl libipc-sharedcache-perl libio-compress-brotli-perl libbusiness-isbn-perl libregexp-ipv6-perl libwww-perl mailx mariadb-test doc-base The following NEW packages will be installed: galera-4 libcgi-fast-perl libcgi-pm-perl libclone-perl libconfig-inifiles-perl libdbd-mysql-perl libdbi-perl libencode-locale-perl libfcgi-bin libfcgi-perl libfcgi0t64 libhtml-parser-perl libhtml-tagset-perl libhtml-template-perl libhttp-date-perl libhttp-message-perl libio-html-perl liblwp-mediatypes-perl libmariadb3 libmysqlclient21 libsnappy1v5 libtimedate-perl liburi-perl liburing2 mariadb-client mariadb-client-core mariadb-common mariadb-plugin-provider-bzip2 mariadb-plugin-provider-lz4 mariadb-plugin-provider-lzma mariadb-plugin-provider-lzo mariadb-plugin-provider-snappy mariadb-server mariadb-server-core mysql-common pv socat 0 upgraded, 37 newly installed, 0 to remove and 2 not upgraded. Need to get 19.0 MB of archives. After this operation, 197 MB of additional disk space will be used. Do you want to continue? [Y/n]
After it’s installed, MariaDB server should automatically be started and running. Let's check its status.
systemctl status mariadb
Some Output shows it running:
● mariadb.service - MariaDB 10.11.8 database server Loaded: loaded (/usr/lib/systemd/system/mariadb.service; enabled; preset: enabled) Active: active (running) . . . Started mariadb.service - MariaDB 10.11.8 database server.
If MariaDB service is not running, then you can start it with this command:
sudo systemctl start mariadb
To enable MariaDB service to start automatically when Ubuntu O/S is restarted or booted, then run this command:
sudo systemctl enable mariadb
Expected Output:
Synchronizing state of mariadb.service with SysV service script with /usr/lib/systemd/systemd-sysv-install. Executing: /usr/lib/systemd/systemd-sysv-install enable mariadb
It is important to run the post-installation security script for the database server.
sudo mysql_secure_installation
Interactive Output:
NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MariaDB SERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY! In order to log into MariaDB to secure it, we'll need the current password for the root user. If you've just installed MariaDB, and haven't set the root password yet, you should just press enter here. Enter current password for root (enter for none):
Since we just installed MariaDB and have not set the root password, we need to press Enter (for none).
OK, successfully used password, moving on... Setting the root password or using the unix_socket ensures that nobody can log into the MariaDB root user without the proper authorisation. You already have your root account protected, so you can safely answer 'n'. Switch to unix_socket authentication [Y/n] n
There is no need to switch to unix_socket authentication because MariaDB is already using unix_socket authentication. So answer “n” for no.
More Interactive Output:
... skipping. You already have your root account protected, so you can safely answer 'n'. Change the root password? [Y/n] n
We can set the password for root@localhost later when we need to login using PhyMyAdmin and create new databases and users with privileges on those databases.
However, I am going to violate my own suggestion here and click Y to enter a new root password. If I need to modify the root password, I believe I can change it later with the following:
To set a MariaDB root password, you can use the following command at the MySQL/MariaDB command prompt: ALTER USER 'root'@'localhost' IDENTIFIED BY ' new_password '; SET PASSWORD FOR 'root'@'localhost' = PASSWORD(' new_password ');
For Example, in the near future, configuring a default root password for MySQL/MariaDB: Use the following procedure to set a root password. To change the root password, type the following at the MySQL/MariaDB command prompt::
ALTER USER 'root'@'localhost' IDENTIFIED BY 'MyN3wP4ssw0rd'; flush privileges; exit;
Store the new password in a secure location.
So, going back to the mysql_secure-installation dialog, after I press Y [Enter] to Change the root password, I get the following output / prompt:
Change the root password? [Y/n] Y New password: Re-enter new password: Password updated successfully! Reloading privilege tables.. ... Success!
The next prompt in the script:
By default, a MariaDB installation has an anonymous user, allowing anyone to log into MariaDB without having to have a user account created for them. This is intended only for testing, and to make the installation go a bit smoother. You should remove them before moving into a production environment. Remove anonymous users? [Y/n] Y
Answer Y (enter) for Yes.
... Success! Normally, root should only be allowed to connect from 'localhost'. This ensures that someone cannot guess at the root password from the network. Disallow root login remotely? [Y/n] Y
My intuitive thoughts: I am answering this as Y. I do not think that answering Y will disable the ability for the root user to be able to use PhpMyAdmin with a complex root password from a web browser, as it will likely limit login to root@localhost. In other words, I believe that it just assures that the connection to interact with the MySQL / MariaDB database (through the web browser) will run from the localhost side (root@localhost). Write to tell me if I am wrong. Thanks.
Next series of questions and answers:
... Success! By default, MariaDB comes with a database named 'test' that anyone can access. This is also intended only for testing, and should be removed before moving into a production environment. Remove test database and access to it? [Y/n] Y - Dropping test database... ... Success! - Removing privileges on test database... ... Success! Reloading the privilege tables will ensure that all changes made so far will take effect immediately. Reload privilege tables now? [Y/n] Y ... Success! Cleaning up... All done! If you've completed all of the above steps, your MariaDB installation should now be secure. Thanks for using MariaDB!
Since the MaraiDB package on Ubuntu uses unix_socket to authenticate user login, you should be able to use the username and password of the OS to log into MariaDB console. The following command should be able to log in without providing MariaDB root password.
sudo mariadb -u root
I believe this is where we would have been able to setup the root@localhost user and password (as addressed above). But I “changed” the root password during the lockdown script. So, I will be able to test the privileges of root whenever PhpMyAdmin is installed.
To exit the MariaDB console, run the following command:
exit;
In order to check the MariaDB server version information, enter the following:
mariadb --version
Results as follows show that we installed distribution 10.11.8-MariaDB.
mariadb Ver 15.1 Distrib 10.11.8-MariaDB, for debian-linux-gnu (x86_64) using EditLine wrapper
Install the Latest PHP Version and Modules / Extensions
As of today (being 12/29/2024), the latest version of PHP is 8.4 which was released on November 21, 2024 (release date). We will soon see what is available for installation through the Ubuntu repository used by Ubuntu 24.04 LTS. NextCloud documentation recommends PHP8.3 but I want to try PHP8.4 even though some modules or extensions may be missing, or that PHP8.4-fpm (fast-cgi) might need tweaking for better performance.
BEGINNING OF THE INSERTED WARNING AND INSERTED FIX FOR SWITCHING PHP VERSIONS
WARNING: SAVE YOURSELF PLENTY OF TIME AND TROUBLE. PHP VERSION 8.4 IS NOT COMPATIBLE WITH NEXTCLOUD VERSION 30.0.4. I HAD INSTALLED PHP8.4 AND THEN EITHER HAD TO UNINSTALL PHP 8.4 AND INSTEAD INSTALL PHP8.3, OR I INSTALLED BOTH VERSIONS AND DISABLED THE MOD FOR PHP8.4 AND ENABLED THE MOD FOR PHP8.3. I DID NOT FIND THIS INCOMPATIBILITY FACT UNTIL I UNZIPPED NEXTCLOUD AND CONFIGURED THE DATABASE AND VIRTUAL HOST. WHEN I FIRST ACCESSED NEXTCLOUD FROM ITS DOMAIN, MY CHROME BROWSER WOULD NOT DISPLAY IT WITHOUT AN SSL CERTIFICATE (BECAUSE GOOGLE CHOOSES FOR CHROME TO BE CRIPPLED FOR THE MERE APPEARANCE OF SECURITY). [IMO, ENCRYPTION AND DECRYPTION OF WEBPAGES BEING REQUESTED AND DISPLAYED IS PRACTICALLY A USELESS ENDEAVOR AND SERVES LITTLE OR NO SECURITY PURPOSE WHATSOEVER. BUT THIS IS A CONVERSATION FOR ANOTHER DAY.] SO, I ACCESSED MY DOMAIN WEBSITE THAT IS HOSTING NEXTCLOUD WITH THE BROWSER KNOWN AS DUCK DUCK GO, WHICH RETURNED THE ERROR MESSAGE STATING THAT THIS VERSION OF NEXTCLOUD IS NOT COMPATIBLE WITH PHP VERSION 8.4. THE NEXTCLOUD DOCUMENTATION DOES NOT STATE THIS INCOMPATIBILITY ANYWHERE, OTHER THAN LISTING PREREQUISITES SAYING PHP8.1, PHP8.2, PHP8.3 (RECOMMENDED), PHP8.4. I WON'T WASTE ANYMORE WIKI TIME REVISING THE FOLLOWING PROCEDURE. PLEASE JUST ASSUME WE ARE INSTALLING PHP 8.3 FROM THE BEGINNING OR THAT WE INSTALLED BOTH AND DISABLED PHP8.4 (FOR NOW) AND ENABLED PHP8.3 SO THAT NEXTCLOUD WILL WORK.
If Both PHP8.3 and PHP8.4 Are Installed, then disable the module for PHP8.4 and enable the module for PHP8.3 for use by apache2 webserver.
sudo a2dismod php8.4 sudo a2enmod php8.3
THIS MARKS THE END OF THE INSERTED WARNING AND INSERTED FIX FOR SWITCHING PHP VERSIONS
Check the available PHP versions.
apt list --installed | grep php
Response:
WARNING: apt does not have a stable CLI interface. Use with caution in scripts.
Ubuntu 24.04 repository might not yet include PHP8.4, so we need to add another repository before installing PHP8.4.
sudo add-apt-repository ppa:ondrej/php
Resulting Output:
PPA publishes dbgsym, you may need to include 'main/debug' component Repository: 'Types: deb URIs: https://ppa.launchpadcontent.net/ondrej/php/ubuntu/ Suites: noble Components: main ' Description: Co-installable PHP versions: PHP 5.6, PHP 7.x, PHP 8.x and most requested extensions are included. Only Supported Ubuntu Releases (https://wiki.ubuntu.com/Releases) are provided. Debian oldstable and stable packages are provided as well: https://deb.sury.org/#debian-dpa You can get more information about the packages at https://deb.sury.org BUGS&FEATURES: This PPA now has a issue tracker: https://deb.sury.org/#bug-reporting CAVEATS: 1. If you are using php-gearman, you need to add ppa:ondrej/pkg-gearman 2. If you are using apache2, you are advised to add ppa:ondrej/apache2 3. If you are using nginx, you are advised to add ppa:ondrej/nginx-mainline or ppa:ondrej/nginx PLEASE READ: If you like my work and want to give me a little motivation, please consider donating regularly: https://donate.sury.org/ WARNING: add-apt-repository is broken with non-UTF-8 locales, see https://github.com/oerdnj/deb.sury.org/issues/56 for workaround: # LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php More info: https://launchpad.net/~ondrej/+archive/ubuntu/php Adding repository. Press [ENTER] to continue or Ctrl-c to cancel.
Press [ENTER] (We are going for the green with the 5-wood taking the short-cut over the trees at the bend and over the water hazard because, as my friend Daryl said, we didn't come here to lay-up!)
Resultant output:
# LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php More info: https://launchpad.net/~ondrej/+archive/ubuntu/php Adding repository. Press [ENTER] to continue or Ctrl-c to cancel. Get:1 http://security.ubuntu.com/ubuntu noble-security InRelease [126 kB] Get:2 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble InRelease [24.4 kB] Get:3 http://security.ubuntu.com/ubuntu noble-security/main amd64 Components [7,236 B] Get:4 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 Packages [126 kB] Get:5 http://security.ubuntu.com/ubuntu noble-security/restricted amd64 Components [212 B] Get:6 http://security.ubuntu.com/ubuntu noble-security/universe amd64 Components [52.0 kB] Get:7 http://security.ubuntu.com/ubuntu noble-security/multiverse amd64 Components [212 B] Get:8 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main Translation-en [39.0 kB] Hit:9 http://us.archive.ubuntu.com/ubuntu noble InRelease Get:10 http://us.archive.ubuntu.com/ubuntu noble-updates InRelease [126 kB] Get:11 http://us.archive.ubuntu.com/ubuntu noble-backports InRelease [126 kB] Get:12 http://us.archive.ubuntu.com/ubuntu noble-updates/main amd64 Components [151 kB] Get:13 http://us.archive.ubuntu.com/ubuntu noble-updates/restricted amd64 Components [212 B] Get:14 http://us.archive.ubuntu.com/ubuntu noble-updates/universe amd64 Components [309 kB] Get:15 http://us.archive.ubuntu.com/ubuntu noble-updates/multiverse amd64 Components [940 B] Get:16 http://us.archive.ubuntu.com/ubuntu noble-backports/main amd64 Components [208 B] Get:17 http://us.archive.ubuntu.com/ubuntu noble-backports/restricted amd64 Components [216 B] Get:18 http://us.archive.ubuntu.com/ubuntu noble-backports/universe amd64 Components [11.7 kB] Get:19 http://us.archive.ubuntu.com/ubuntu noble-backports/multiverse amd64 Components [212 B] Fetched 1,102 kB in 2s (534 kB/s) Reading package lists... Done
Question. Should we now add a repository for ppa:ondrej/apache2 and when we install Nginx to support running OnlyOffice in reverse proxy, should we then also add the repository for ppa:ondrej/nginx-mainline ???
Now, let's update from the new repository and then install PHP8.4.
sudo apt update
Resulting output:
Hit:1 http://us.archive.ubuntu.com/ubuntu noble InRelease Hit:2 http://us.archive.ubuntu.com/ubuntu noble-updates InRelease Hit:3 http://us.archive.ubuntu.com/ubuntu noble-backports InRelease Hit:4 http://security.ubuntu.com/ubuntu noble-security InRelease Hit:5 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble InRelease Reading package lists... Done Building dependency tree... Done Reading state information... Done 3 packages can be upgraded. Run 'apt list --upgradable' to see them.
Let's check –upgradeable :
sudo apt list --upgradable
Results don't include anything about PHP8.4
Listing... Done libgd3/noble 2.3.3-12+ubuntu24.04.1+deb.sury.org+1 amd64 [upgradable from: 2.3.3-9ubuntu5] python3-distupgrade/noble-updates 1:24.04.23 all [upgradable from: 1:24.04.22] ubuntu-release-upgrader-core/noble-updates 1:24.04.23 all [upgradable from: 1:24.04.22]
Well, let's see if we can now install PHP8.4 as follows:
sudo apt install php8.4 -y
Results (I left off the -y when I ran the apt install command):
Reading package lists... Done Building dependency tree... Done Reading state information... Done The following additional packages will be installed: debsuryorg-archive-keyring libapache2-mod-php8.4 php-common php8.4-cli php8.4-common php8.4-opcache php8.4-readline Suggested packages: php-pear The following NEW packages will be installed: debsuryorg-archive-keyring libapache2-mod-php8.4 php-common php8.4 php8.4-cli php8.4-common php8.4-opcache php8.4-readline 0 upgraded, 8 newly installed, 0 to remove and 3 not upgraded. Need to get 5,226 kB of archives. After this operation, 23.6 MB of additional disk space will be used. Do you want to continue? [Y/n]
I answered Y [Enter]
Selecting previously unselected package debsuryorg-archive-keyring.le from: 1:24.04.22] (Reading database ... 88678 files and directories currently installed.) Preparing to unpack .../0-debsuryorg-archive-keyring_2024.02.05+ubuntu24.04.1+deb.sury.org+1_all.deb ... Unpacking debsuryorg-archive-keyring (2024.02.05+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php-common. Preparing to unpack .../1-php-common_2%3a95+ubuntu24.04.1+deb.sury.org+1_all.deb ... Unpacking php-common (2:95+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php8.4-common. Preparing to unpack .../2-php8.4-common_8.4.2-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.4-common (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php8.4-opcache. Preparing to unpack .../3-php8.4-opcache_8.4.2-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.4-opcache (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php8.4-readline. Preparing to unpack .../4-php8.4-readline_8.4.2-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.4-readline (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php8.4-cli. Preparing to unpack .../5-php8.4-cli_8.4.2-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.4-cli (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package libapache2-mod-php8.4. Preparing to unpack .../6-libapache2-mod-php8.4_8.4.2-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking libapache2-mod-php8.4 (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php8.4. Preparing to unpack .../7-php8.4_8.4.2-1+ubuntu24.04.1+deb.sury.org+1_all.deb ... Unpacking php8.4 (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Setting up debsuryorg-archive-keyring (2024.02.05+ubuntu24.04.1+deb.sury.org+1) ... Setting up php-common (2:95+ubuntu24.04.1+deb.sury.org+1) ... Created symlink /etc/systemd/system/timers.target.wants/phpsessionclean.timer → /usr/lib/systemd/system/phpsessionclean.timer. Setting up php8.4-common (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.4/mods-available/calendar.ini with new version Creating config file /etc/php/8.4/mods-available/ctype.ini with new version Creating config file /etc/php/8.4/mods-available/exif.ini with new version Creating config file /etc/php/8.4/mods-available/fileinfo.ini with new version Creating config file /etc/php/8.4/mods-available/ffi.ini with new version Creating config file /etc/php/8.4/mods-available/ftp.ini with new version Creating config file /etc/php/8.4/mods-available/gettext.ini with new version Creating config file /etc/php/8.4/mods-available/iconv.ini with new version Creating config file /etc/php/8.4/mods-available/pdo.ini with new version Creating config file /etc/php/8.4/mods-available/phar.ini with new version Creating config file /etc/php/8.4/mods-available/posix.ini with new version Creating config file /etc/php/8.4/mods-available/shmop.ini with new version Creating config file /etc/php/8.4/mods-available/sockets.ini with new version Creating config file /etc/php/8.4/mods-available/sysvmsg.ini with new version Creating config file /etc/php/8.4/mods-available/sysvsem.ini with new version Creating config file /etc/php/8.4/mods-available/sysvshm.ini with new version Creating config file /etc/php/8.4/mods-available/tokenizer.ini with new version Setting up php8.4-opcache (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.4/mods-available/opcache.ini with new version Setting up php8.4-readline (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.4/mods-available/readline.ini with new version Setting up php8.4-cli (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... update-alternatives: using /usr/bin/php8.4 to provide /usr/bin/php (php) in auto mode update-alternatives: using /usr/bin/phar8.4 to provide /usr/bin/phar (phar) in auto mode update-alternatives: using /usr/bin/phar.phar8.4 to provide /usr/bin/phar.phar (phar.phar) in auto mode Creating config file /etc/php/8.4/cli/php.ini with new version Setting up libapache2-mod-php8.4 (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.4/apache2/php.ini with new version Module mpm_event disabled. Enabling module mpm_prefork. apache2_switch_mpm Switch to prefork apache2_invoke: Enable module php8.4 Setting up php8.4 (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Processing triggers for man-db (2.12.0-4build2) ... Processing triggers for php8.4-cli (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Processing triggers for libapache2-mod-php8.4 (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Scanning processes... Scanning candidates... Scanning processor microcode... Scanning linux images... Building dependency tree... Done Running kernel seems to be up-to-date. The following additional packages will be installed: The processor microcode seems to be up-to-date.8.4 php-common php8.4-cli php8.4-common php8.4-opcache php8.4-readline Restarting services... php-pear Service restarts being deferred:be installed: /etc/needrestart/restart.d/dbus.servicemod-php8.4 php-common php8.4 php8.4-cli php8.4-common php8.4-opcache systemctl restart systemd-logind.service 0 upgraded, 8 newly installed, 0 to remove and 3 not upgraded. No containers need to be restarted. After this operation, 23.6 MB of additional disk space will be used. User sessions running outdated binaries: frank @ session #2: login[1248]nt.net/ondrej/php/ubuntu noble/main amd64 debsuryorg-archive-keyring all 2024.02.05+u frank @ user manager service: systemd[1360] Get:2 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php-common all 2:95+ubuntu24.04.1+deb.sury. No VM guests are running outdated hypervisor (qemu) binaries on this host. eb.sury.org+1 [793 kB] Get:4 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.4-opcache amd64 8.4.2-1+ubuntu24.04.1+deb.sury.org+1 [467 kB] Get:5 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.4-readline amd64 8.4.2-1+ubuntu24.04.1+deb.sury.org+1 [13.7 kB] Get:6 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.4-cli amd64 8.4.2-1+ubuntu24.04.1+deb.sury.org+1 [1,986 kB] Get:7 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 libapache2-mod-php8.4 amd64 8.4.2-1+ubuntu24.04.1+deb.sury.org+1 [1,920 kB] Get:8 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.4 all 8.4.2-1+ubuntu24.04.1+deb.sury.org+1 [29.1 kB] Fetched 5,226 kB in 2s (2,642 kB/s)
Let's install some extra modules / extensions:
sudo apt install php8.4 libapache2-mod-php8.4 php8.4-fpm php8.4-mysql php8.4-xml php8.4-mbstring php8.4-curl -y
Results (for installing PHP8.4):
Reading package lists... Done Building dependency tree... Done Reading state information... Done php8.4 is already the newest version (8.4.2-1+ubuntu24.04.1+deb.sury.org+1). libapache2-mod-php8.4 is already the newest version (8.4.2-1+ubuntu24.04.1+deb.sury.org+1). libapache2-mod-php8.4 set to manually installed. Suggested packages: php-pear The following NEW packages will be installed: php8.4-curl php8.4-fpm php8.4-mbstring php8.4-mysql php8.4-xml 0 upgraded, 5 newly installed, 0 to remove and 3 not upgraded. Need to get 3,589 kB of archives. After this operation, 11.8 MB of additional disk space will be used. Get:1 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.4-curl amd64 8.4.2-1+ubuntu24.04.1+deb.sury.org+1 [43.2 kB] Get:2 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.4-fpm amd64 8.4.2-1+ubuntu24.04.1+deb.sury.org+1 [1,990 kB] Get:3 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.4-mbstring amd64 8.4.2-1+ubuntu24.04.1+deb.sury.org+1 [519 kB] Get:4 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.4-mysql amd64 8.4.2-1+ubuntu24.04.1+deb.sury.org+1 [129 kB] Get:5 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.4-xml amd64 8.4.2-1+ubuntu24.04.1+deb.sury.org+1 [908 kB] Fetched 3,589 kB in 2s (1,775 kB/s) Selecting previously unselected package php8.4-curl. (Reading database ... 88818 files and directories currently installed.) Preparing to unpack .../php8.4-curl_8.4.2-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.4-curl (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php8.4-fpm. Preparing to unpack .../php8.4-fpm_8.4.2-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.4-fpm (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php8.4-mbstring. Preparing to unpack .../php8.4-mbstring_8.4.2-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.4-mbstring (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php8.4-mysql. Preparing to unpack .../php8.4-mysql_8.4.2-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.4-mysql (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php8.4-xml. Preparing to unpack .../php8.4-xml_8.4.2-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.4-xml (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Setting up php8.4-mbstring (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.4/mods-available/mbstring.ini with new version Setting up php8.4-mysql (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.4/mods-available/mysqlnd.ini with new version Creating config file /etc/php/8.4/mods-available/mysqli.ini with new version Creating config file /etc/php/8.4/mods-available/pdo_mysql.ini with new version Setting up php8.4-curl (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.4/mods-available/curl.ini with new version Setting up php8.4-fpm (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.4/fpm/php.ini with new version NOTICE: Not enabling PHP 8.4 FPM by default. NOTICE: To enable PHP 8.4 FPM in Apache2 do: NOTICE: a2enmod proxy_fcgi setenvif NOTICE: a2enconf php8.4-fpm NOTICE: You are seeing this message because you have apache2 package installed. Created symlink /etc/systemd/system/multi-user.target.wants/php8.4-fpm.service → /usr/lib/systemd/system/php8.4-fpm.service. Setting up php8.4-xml (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.4/mods-available/dom.ini with new version Creating config file /etc/php/8.4/mods-available/simplexml.ini with new version Creating config file /etc/php/8.4/mods-available/xml.ini with new version Creating config file /etc/php/8.4/mods-available/xmlreader.ini with new version Creating config file /etc/php/8.4/mods-available/xmlwriter.ini with new version Creating config file /etc/php/8.4/mods-available/xsl.ini with new version Processing triggers for libapache2-mod-php8.4 (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Processing triggers for man-db (2.12.0-4build2) ... Processing triggers for php8.4-cli (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Processing triggers for php8.4-fpm (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... NOTICE: Not enabling PHP 8.4 FPM by default. NOTICE: To enable PHP 8.4 FPM in Apache2 do: NOTICE: a2enmod proxy_fcgi setenvif NOTICE: a2enconf php8.4-fpm NOTICE: You are seeing this message because you have apache2 package installed. Scanning processes... Scanning candidates... Scanning processor microcode... Scanning linux images... Running kernel seems to be up-to-date. The processor microcode seems to be up-to-date. Restarting services... Service restarts being deferred: /etc/needrestart/restart.d/dbus.service systemctl restart systemd-logind.service No containers need to be restarted.
THIS SUBSEQUENT REVISION IS BASED ON NEXTCLOUD BEING INCOMPATIBLE WITH PHP8.4. (WIKI REVISION)
For instead installing php8.3 and modules / extensions for php8.3, try the following:
sudo apt install php8.3 libapache2-mod-php8.3 php8.3-fpm php8.3-mysql php8.3-xml php8.3-mbstring php8.3-curl -y
END OF SUBSEQUENT REVISION BASED UPON NEXTCLOUD BEING INCOMPATIBLE WITH PHP8.4
THE FOLLOWING IS THE OUTPUT IF WE INSTALLED PHP8.3 AND THE PHP8.3 MODULES AND EXTENSIONS:
sudo apt install php8.3 libapache2-mod-php8.3 php8.3-fpm php8.3-mysql php8.3-xml php8.3-mbstring php8.3-curl Reading package lists... Done Building dependency tree... Done Reading state information... Done php8.3 is already the newest version (8.3.15-1+ubuntu24.04.1+deb.sury.org+1). libapache2-mod-php8.3 is already the newest version (8.3.15-1+ubuntu24.04.1+deb.sury.org+1). libapache2-mod-php8.3 set to manually installed. php8.3-mysql is already the newest version (8.3.15-1+ubuntu24.04.1+deb.sury.org+1). php8.3-mysql set to manually installed. php8.3-xml is already the newest version (8.3.15-1+ubuntu24.04.1+deb.sury.org+1). php8.3-mbstring is already the newest version (8.3.15-1+ubuntu24.04.1+deb.sury.org+1). php8.3-curl is already the newest version (8.3.15-1+ubuntu24.04.1+deb.sury.org+1). Suggested packages: php-pear The following NEW packages will be installed: php8.3-fpm 0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded. Need to get 1,927 kB of archives. After this operation, 5,875 kB of additional disk space will be used. Do you want to continue? [Y/n] Y Get:1 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.3-fpm amd64 8.3.15-1+ubuntu24.04.1+deb.sury.org+1 [1,927 kB] Fetched 1,927 kB in 2s (1,275 kB/s) Selecting previously unselected package php8.3-fpm. (Reading database ... 133656 files and directories currently installed.) Preparing to unpack .../php8.3-fpm_8.3.15-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.3-fpm (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Setting up php8.3-fpm (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.3/fpm/php.ini with new version NOTICE: Not enabling PHP 8.3 FPM by default. NOTICE: To enable PHP 8.3 FPM in Apache2 do: NOTICE: a2enmod proxy_fcgi setenvif NOTICE: a2enconf php8.3-fpm NOTICE: You are seeing this message because you have apache2 package installed. Created symlink /etc/systemd/system/multi-user.target.wants/php8.3-fpm.service → /usr/lib/systemd/system/php8.3-fpm.service. Processing triggers for man-db (2.12.0-4build2) ... Processing triggers for php8.3-fpm (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... NOTICE: Not enabling PHP 8.3 FPM by default. NOTICE: To enable PHP 8.3 FPM in Apache2 do: NOTICE: a2enmod proxy_fcgi setenvif NOTICE: a2enconf php8.3-fpm NOTICE: You are seeing this message because you have apache2 package installed. Scanning processes... Scanning processor microcode... Scanning linux images... Running kernel seems to be up-to-date. The processor microcode seems to be up-to-date. No services need to be restarted. No containers need to be restarted. No user sessions are running outdated binaries. No VM guests are running outdated hypervisor (qemu) binaries on this host.
Disabling and re-Enabling apache2 module for PHP83. Notice the “consider conflicts” output. I will look into that as well.
sudo a2dismod php8.3
Result:
Module php8.3 disabled. To activate the new configuration, you need to run: systemctl restart apache2 <code> sudo systemctl restart apache2
$ sudo a2enmod php8.3
Output
Considering dependency mpm_prefork for php8.3: Considering conflict mpm_event for mpm_prefork: Considering conflict mpm_worker for mpm_prefork: Module mpm_prefork already enabled Considering conflict php5 for php8.3: Enabling module php8.3. To activate the new configuration, you need to run: systemctl restart apache2
sudo systemctl restart apache2
Now, go check your browser to display the page /phpinfo.php and make sure php8.3 is enabled and active.
phpinfo.php shows that PHP8.3 is enabled.
The wild goose chase: There are apparently 3 Multithread processes (see the conflicts showing near the end of the above output). PhpInfo.php shows the module “prefork” is enabled. After checking the differences between each Multi-Processing Module (MPM), mpm_prefork, mpm_event, and mpm_worker, it would seem the best choice is to disable mpm_prefork and enable mpm_event. Apparently, Apache can only start with one Multi-Processing Module (MPM) selected at a time. To change the MPM, you must first “dismod” the current MPM and then “enmod” the desired MPM. However, php8.3 apparently favors mpm_prefork rather than the other two MPM modules. To make a long story short, I disabled (a2dismod) mpm_prefork and disabled (a2dismod) php_8.3 before enabling (a2enomd) mpm_event. When I tried to re-enable php8.3, then apache2 would not properly restart. So, I had to disable mpm_event, re-enable mpm_prefork, and re=enable php8.3 before apache2 would effectively restart.
END OF WIKI REVISION FOR OUTPUT IF WE INSTALLED PHP8.3 AND PHP8.3 MODULES ETC.
- - - - - - - - -
This Section was from an online blog: Or, optionally, install the desired PHP version (replace “8.x” with the specific version you want):
sudo apt install php8.x-fpm php8.x-cli php8.x-mysql
- - - - - - - - -
sudo systemctl reload apache2 sudo systemctl restart apache2
Now, I should check my PHP version that is enabled? Do I need to enable the apache module for PHP 8.4? Let's check the mods-enabled subdirectory:
cd /etc/apache2/mods-enabled ls
Notice that php8.4.conf php8.4.load setenvif.conf setenvif.load are all enabled with symlink in this mods-enabled subdirectory. There are many other modules in the /etc/apache2/mods-available/ subdirectory that are not enabled in the following list under /etc/apache2/mods-enabled/.
access_compat.load authz_core.load deflate.load mime.load php8.4.load status.load alias.conf authz_host.load dir.conf mpm_prefork.conf reqtimeout.conf alias.load authz_user.load dir.load mpm_prefork.load reqtimeout.load auth_basic.load autoindex.conf env.load negotiation.conf setenvif.conf authn_core.load autoindex.load filter.load negotiation.load setenvif.load authn_file.load deflate.conf mime.conf php8.4.conf status.conf
Create a phpinfo.php file in the default apache2 web directory.
cd /var/www/html ls index.html sudo vim phpinfo.php In the new file I press: i # for insert mode and enter the following php script in the new file: <?php phpinfo() ; ?> Esc (to leave insert mode) :w [Enter] (to save the script input) :q [Enter] (to quit editing the new file and return to SSH console
Now, using your browser, go access the new page
http://sever-public-IP-address/phpinfo.php
You should see all the Php Information for PHP Version 8.4.2
Here is a good article by Aaron Kili for installing php8.4 on Ubuntu Server 24.04 LTS: https://www.tecmint.com/install-php-ubuntu-24-04/
Install PhpMyAdmin
We already installed the “ondrej/php” PPA (Personal Package Archive) repository, which provides newer versions of PHP not available in the default Ubuntu repositories; you can then install phpMyAdmin using the standard apt command, after ensuring compatibility with the installed PHP version.
sudo apt update sudo apt list --upgradable sudo apt upgrade sudo systemctl restart apache2
sudo apt install phpmyadmin
Interactive output shows some modules of php8.3 as dependencies for phpmyadmin even though php8.4 is my installed version of PHP. Is it possible that php8.4 is missing those? Is it possible that phpmyadmin needs the php8.3 modules for compatibility? I don't know. But let's install. The first attempt to install I replied “n” to abort the install. The second time, I will proceed with the install. The latest version of phpMyAdmin is 5.2.1 and I would rather not install it manually.
Reading package lists... Done Building dependency tree... Done Reading state information... Done The following additional packages will be installed: dbconfig-common dbconfig-mysql icc-profiles-free javascript-common libjs-bootstrap5 libjs-codemirror libjs-jquery libjs-jquery-metadata libjs-jquery-mousewheel libjs-jquery-tablesorter libjs-jquery-timepicker libjs-jquery-ui libjs-popper.js libjs-sizzle libjs-sphinxdoc libjs-underscore libmcrypt4 libzip4t64 node-jquery php-bz2 php-composer-ca-bundle php-fig-http-message-util php-gd php-getallheaders php-google-recaptcha php-mariadb-mysql-kbs php-mcrypt php-mysql php-nikic-fast-route php-phpmyadmin-motranslator php-phpmyadmin-shapefile php-phpmyadmin-sql-parser php-psr-cache php-psr-container php-psr-http-factory php-psr-http-message php-psr-log php-slim-psr7 php-symfony-cache php-symfony-cache-contracts php-symfony-config php-symfony-dependency-injection php-symfony-deprecation-contracts php-symfony-expression-language php-symfony-filesystem php-symfony-polyfill-php80 php-symfony-service-contracts php-symfony-var-exporter php-tcpdf php-twig php-twig-i18n-extension php-webmozart-assert php-zip php8.3-bz2 php8.3-common php8.3-gd php8.3-mysql php8.3-zip php8.4-mcrypt Suggested packages: bootstrap-icons libjs-bootstrap5-doc libjs-requirejs libjs-jquery-ui-docs libmcrypt-dev mcrypt php-apcu php-dbase php-imagick php-twig-doc php-recode www-browser php-gd2 php-pragmarx-google2fa-qrcode php-bacon-qr-code php-code-lts-u2f-php-server The following NEW packages will be installed: dbconfig-common dbconfig-mysql icc-profiles-free javascript-common libjs-bootstrap5 libjs-codemirror libjs-jquery libjs-jquery-metadata libjs-jquery-mousewheel libjs-jquery-tablesorter libjs-jquery-timepicker libjs-jquery-ui libjs-popper.js libjs-sizzle libjs-sphinxdoc libjs-underscore libmcrypt4 libzip4t64 node-jquery php-bz2 php-composer-ca-bundle php-fig-http-message-util php-gd php-getallheaders php-google-recaptcha php-mariadb-mysql-kbs php-mcrypt php-mysql php-nikic-fast-route php-phpmyadmin-motranslator php-phpmyadmin-shapefile php-phpmyadmin-sql-parser php-psr-cache php-psr-container php-psr-http-factory php-psr-http-message php-psr-log php-slim-psr7 php-symfony-cache php-symfony-cache-contracts php-symfony-config php-symfony-dependency-injection php-symfony-deprecation-contracts php-symfony-expression-language php-symfony-filesystem php-symfony-polyfill-php80 php-symfony-service-contracts php-symfony-var-exporter php-tcpdf php-twig php-twig-i18n-extension php-webmozart-assert php-zip php8.3-bz2 php8.3-common php8.3-gd php8.3-mysql php8.3-zip php8.4-mcrypt phpmyadmin 0 upgraded, 60 newly installed, 0 to remove and 3 not upgraded. Need to get 18.0 MB of archives. After this operation, 93.6 MB of additional disk space will be used. Do you want to continue? [Y/n] n Abort.
Try the install again.
sudo apt install phpmyadmin Reading package lists... Done Building dependency tree... Done Reading state information... Done The following additional packages will be installed: dbconfig-common dbconfig-mysql icc-profiles-free javascript-common libjs-bootstrap5 libjs-codemirror libjs-jquery libjs-jquery-metadata libjs-jquery-mousewheel libjs-jquery-tablesorter libjs-jquery-timepicker libjs-jquery-ui libjs-popper.js libjs-sizzle libjs-sphinxdoc libjs-underscore libmcrypt4 libzip4t64 node-jquery php-bz2 php-composer-ca-bundle php-fig-http-message-util php-gd php-getallheaders php-google-recaptcha php-mariadb-mysql-kbs php-mcrypt php-mysql php-nikic-fast-route php-phpmyadmin-motranslator php-phpmyadmin-shapefile php-phpmyadmin-sql-parser php-psr-cache php-psr-container php-psr-http-factory php-psr-http-message php-psr-log php-slim-psr7 php-symfony-cache php-symfony-cache-contracts php-symfony-config php-symfony-dependency-injection php-symfony-deprecation-contracts php-symfony-expression-language php-symfony-filesystem php-symfony-polyfill-php80 php-symfony-service-contracts php-symfony-var-exporter php-tcpdf php-twig php-twig-i18n-extension php-webmozart-assert php-zip php8.3-bz2 php8.3-common php8.3-gd php8.3-mysql php8.3-zip php8.4-mcrypt Suggested packages: bootstrap-icons libjs-bootstrap5-doc libjs-requirejs libjs-jquery-ui-docs libmcrypt-dev mcrypt php-apcu php-dbase php-imagick php-twig-doc php-recode www-browser php-gd2 php-pragmarx-google2fa-qrcode php-bacon-qr-code php-code-lts-u2f-php-server The following NEW packages will be installed: dbconfig-common dbconfig-mysql icc-profiles-free javascript-common libjs-bootstrap5 libjs-codemirror libjs-jquery libjs-jquery-metadata libjs-jquery-mousewheel libjs-jquery-tablesorter libjs-jquery-timepicker libjs-jquery-ui libjs-popper.js libjs-sizzle libjs-sphinxdoc libjs-underscore libmcrypt4 libzip4t64 node-jquery php-bz2 php-composer-ca-bundle php-fig-http-message-util php-gd php-getallheaders php-google-recaptcha php-mariadb-mysql-kbs php-mcrypt php-mysql php-nikic-fast-route php-phpmyadmin-motranslator php-phpmyadmin-shapefile php-phpmyadmin-sql-parser php-psr-cache php-psr-container php-psr-http-factory php-psr-http-message php-psr-log php-slim-psr7 php-symfony-cache php-symfony-cache-contracts php-symfony-config php-symfony-dependency-injection php-symfony-deprecation-contracts php-symfony-expression-language php-symfony-filesystem php-symfony-polyfill-php80 php-symfony-service-contracts php-symfony-var-exporter php-tcpdf php-twig php-twig-i18n-extension php-webmozart-assert php-zip php8.3-bz2 php8.3-common php8.3-gd php8.3-mysql php8.3-zip php8.4-mcrypt phpmyadmin 0 upgraded, 60 newly installed, 0 to remove and 2 not upgraded. Need to get 18.0 MB of archives. After this operation, 93.6 MB of additional disk space will be used. Do you want to continue? [Y/n] Y [Enter]
Please choose the web server that should be automatically configured to run phpMyAdmin. │ │ │ │ Web server to reconfigure automatically: │ │ │ │ [X] apache2 │ │ [ ] lighttpd
Configuring phpmyadmin ├─────────────────────────────────────────────┐ │ │ │ The phpmyadmin package must have a database installed and configured before it can be used. This can be │ │ optionally handled with dbconfig-common. │ │ │ │ If you are an advanced database administrator and know that you want to perform this configuration manually, or │ │ if your database has already been installed and configured, you should refuse this option. Details on what needs │ │ to be done should most likely be provided in /usr/share/doc/phpmyadmin. │ │ │ │ Otherwise, you should probably choose this option. │ │ │ │ Configure database for phpmyadmin with dbconfig-common? │ │ │ │ <Yes> <No>
There may be some php8.4 packages to enable. See extensive output below.
Reading package lists... Done Building dependency tree... Done Reading state information... Done The following additional packages will be installed: dbconfig-common dbconfig-mysql icc-profiles-free javascript-common libjs-bootstrap5 libjs-codemirror libjs-jquery libjs-jquery-metadata libjs-jquery-mousewheel libjs-jquery-tablesorter libjs-jquery-timepicker libjs-jquery-ui libjs-popper.js libjs-sizzle libjs-sphinxdoc libjs-underscore libmcrypt4 libzip4t64 node-jquery php-bz2 php-composer-ca-bundle php-fig-http-message-util php-gd php-getallheaders php-google-recaptcha php-mariadb-mysql-kbs php-mcrypt php-mysql php-nikic-fast-route php-phpmyadmin-motranslator php-phpmyadmin-shapefile php-phpmyadmin-sql-parser php-psr-cache php-psr-container php-psr-http-factory php-psr-http-message php-psr-log php-slim-psr7 php-symfony-cache php-symfony-cache-contracts php-symfony-config php-symfony-dependency-injection php-symfony-deprecation-contracts php-symfony-expression-language php-symfony-filesystem php-symfony-polyfill-php80 php-symfony-service-contracts php-symfony-var-exporter php-tcpdf php-twig php-twig-i18n-extension php-webmozart-assert php-zip php8.3-bz2 php8.3-common php8.3-gd php8.3-mysql php8.3-zip php8.4-mcrypt Suggested packages: bootstrap-icons libjs-bootstrap5-doc libjs-requirejs libjs-jquery-ui-docs libmcrypt-dev mcrypt php-apcu php-dbase php-imagick php-twig-doc php-recode www-browser php-gd2 php-pragmarx-google2fa-qrcode php-bacon-qr-code php-code-lts-u2f-php-server The following NEW packages will be installed: dbconfig-common dbconfig-mysql icc-profiles-free javascript-common libjs-bootstrap5 libjs-codemirror libjs-jquery libjs-jquery-metadata libjs-jquery-mousewheel libjs-jquery-tablesorter libjs-jquery-timepicker libjs-jquery-ui libjs-popper.js libjs-sizzle libjs-sphinxdoc libjs-underscore libmcrypt4 libzip4t64 node-jquery php-bz2 php-composer-ca-bundle php-fig-http-message-util php-gd php-getallheaders php-google-recaptcha php-mariadb-mysql-kbs php-mcrypt php-mysql php-nikic-fast-route php-phpmyadmin-motranslator php-phpmyadmin-shapefile php-phpmyadmin-sql-parser php-psr-cache php-psr-container php-psr-http-factory php-psr-http-message php-psr-log php-slim-psr7 php-symfony-cache php-symfony-cache-contracts php-symfony-config php-symfony-dependency-injection php-symfony-deprecation-contracts php-symfony-expression-language php-symfony-filesystem php-symfony-polyfill-php80 php-symfony-service-contracts php-symfony-var-exporter php-tcpdf php-twig php-twig-i18n-extension php-webmozart-assert php-zip php8.3-bz2 php8.3-common php8.3-gd php8.3-mysql php8.3-zip php8.4-mcrypt phpmyadmin 0 upgraded, 60 newly installed, 0 to remove and 2 not upgraded. Need to get 18.0 MB of archives. After this operation, 93.6 MB of additional disk space will be used. Do you want to continue? [Y/n] Y Get:1 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.4-mcrypt amd64 3:1.0.7-5+ubuntu24.04.1+deb.sury.org+1 [18.0 kB] Get:2 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php-mcrypt all 3:1.0.7-5+ubuntu24.04.1+deb.sury.org+1 [3,830 B] Get:3 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.3-common amd64 8.3.15-1+ubuntu24.04.1+deb.sury.org+1 [760 kB] Get:4 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 libmcrypt4 amd64 2.5.8-7 [68.8 kB] Get:5 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 dbconfig-common all 2.0.24 [596 kB] Get:6 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 dbconfig-mysql all 2.0.24 [938 B] Get:7 http://us.archive.ubuntu.com/ubuntu noble/main amd64 icc-profiles-free all 2.0.1+dfsg-1.1 [214 kB] Get:8 http://us.archive.ubuntu.com/ubuntu noble/main amd64 javascript-common all 11+nmu1 [5,936 B] Get:9 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 libjs-popper.js all 1.16.1+ds-6 [54.1 kB] Get:10 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 libjs-bootstrap5 all 5.3.1+dfsg-1 [260 kB] Get:11 http://us.archive.ubuntu.com/ubuntu noble/main amd64 libjs-jquery all 3.6.1+dfsg+~3.5.14-1 [328 kB] Get:12 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 libjs-jquery-metadata all 12-4 [6,582 B] Get:13 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 libjs-jquery-mousewheel all 1:3.1.13-5 [6,324 B] Get:14 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 libjs-jquery-tablesorter all 1:2.31.3+dfsg1-3 [193 kB] Get:15 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 libjs-jquery-ui all 1.13.2+dfsg-1 [252 kB] Get:16 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 libjs-jquery-timepicker all 1.6.3-6 [50.2 kB] Get:17 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 libjs-sizzle all 2.3.10+ds+~2.3.6-1 [32.7 kB] Get:18 http://us.archive.ubuntu.com/ubuntu noble/main amd64 libjs-underscore all 1.13.4~dfsg+~1.11.4-3 [118 kB] Get:19 http://us.archive.ubuntu.com/ubuntu noble/main amd64 libjs-sphinxdoc all 7.2.6-6 [149 kB] Get:20 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 libzip4t64 amd64 1.7.3-1.1ubuntu2 [53.6 kB] Get:21 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 node-jquery all 3.6.1+dfsg+~3.5.14-1 [160 kB] Get:22 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-composer-ca-bundle all 1.4.1-1 [11.1 kB] Get:23 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-fig-http-message-util all 1.1.5-2 [4,410 B] Get:24 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-getallheaders all 3.0.3-3 [2,988 B] Get:25 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-google-recaptcha all 1.3.0-1 [18.2 kB] Get:26 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-mariadb-mysql-kbs all 1.2.14-1 [36.0 kB] Get:27 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-nikic-fast-route all 1.3.0-4 [13.7 kB] Get:28 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-symfony-deprecation-contracts all 3.4.1-4 [5,668 B] Get:29 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-psr-cache all 3.0.0-4 [5,834 B] Get:30 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-psr-log all 3.0.0-1 [6,862 B] Get:31 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-symfony-cache-contracts all 3.4.1-4 [8,162 B] Get:32 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-psr-container all 2.0.2-1 [3,878 B] Get:33 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-symfony-service-contracts all 3.4.1-4 [10.0 kB] Get:34 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-symfony-var-exporter all 6.4.5+dfsg-3ubuntu3 [34.7 kB] Get:35 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-symfony-cache all 6.4.5+dfsg-3ubuntu3 [69.0 kB] Get:36 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-symfony-expression-language all 6.4.5+dfsg-3ubuntu3 [23.3 kB] Get:37 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-phpmyadmin-motranslator all 5.3.1-1 [15.1 kB] Get:38 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-phpmyadmin-shapefile all 3.0.2-1 [53.0 kB] Get:39 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-symfony-polyfill-php80 all 1.28.0-1 [9,616 B] Get:40 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-phpmyadmin-sql-parser all 5.8.2-1 [86.7 kB] Get:41 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-psr-http-message all 1.1-2 [17.9 kB] Get:42 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-psr-http-factory all 1.0.2-1 [4,982 B] Get:43 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-slim-psr7 all 1.6.1-1 [18.3 kB] Get:44 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-symfony-filesystem all 6.4.5+dfsg-3ubuntu3 [30.7 kB] Get:45 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-symfony-config all 6.4.5+dfsg-3ubuntu3 [52.7 kB] Get:46 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-symfony-dependency-injection all 6.4.5+dfsg-3ubuntu3 [126 kB] Get:47 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-tcpdf all 6.7.5+dfsg-1 [8,002 kB] Get:48 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.3-bz2 amd64 8.3.15-1+ubuntu24.04.1+deb.sury.org+1 [11.5 kB] Get:49 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php-bz2 all 2:8.3+95+ubuntu24.04.1+deb.sury.org+1 [3,892 B] Get:50 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.3-gd amd64 8.3.15-1+ubuntu24.04.1+deb.sury.org+1 [31.4 kB] Get:51 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php-gd all 2:8.3+95+ubuntu24.04.1+deb.sury.org+1 [3,884 B] Get:52 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.3-mysql amd64 8.3.15-1+ubuntu24.04.1+deb.sury.org+1 [127 kB] Get:53 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-twig all 3.8.0-2 [86.8 kB] Get:54 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-twig-i18n-extension all 4.1.0-1 [9,440 B] Get:55 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 php-webmozart-assert all 1.11.0-1 [17.0 kB] Get:56 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 libjs-codemirror all 5.65.0+~cs5.83.9-3 [755 kB] Get:57 http://us.archive.ubuntu.com/ubuntu noble/universe amd64 phpmyadmin all 4:5.2.1+dfsg-3 [4,909 kB] Get:58 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php-mysql all 2:8.3+95+ubuntu24.04.1+deb.sury.org+1 [3,890 B] Get:59 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.3-zip amd64 8.3.15-1+ubuntu24.04.1+deb.sury.org+1 [29.5 kB] Get:60 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php-zip all 2:8.3+95+ubuntu24.04.1+deb.sury.org+1 [3,888 B] Fetched 18.0 MB in 4s (5,015 kB/s) Extracting templates from packages: 100% Preconfiguring packages ... Selecting previously unselected package libmcrypt4. (Reading database ... 89079 files and directories currently installed.) Preparing to unpack .../00-libmcrypt4_2.5.8-7_amd64.deb ... Unpacking libmcrypt4 (2.5.8-7) ... Selecting previously unselected package php8.4-mcrypt. Preparing to unpack .../01-php8.4-mcrypt_3%3a1.0.7-5+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.4-mcrypt (3:1.0.7-5+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php-mcrypt. Preparing to unpack .../02-php-mcrypt_3%3a1.0.7-5+ubuntu24.04.1+deb.sury.org+1_all.deb ... Unpacking php-mcrypt (3:1.0.7-5+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package dbconfig-common. Preparing to unpack .../03-dbconfig-common_2.0.24_all.deb ... Unpacking dbconfig-common (2.0.24) ... Selecting previously unselected package dbconfig-mysql. Preparing to unpack .../04-dbconfig-mysql_2.0.24_all.deb ... Unpacking dbconfig-mysql (2.0.24) ... Selecting previously unselected package icc-profiles-free. Preparing to unpack .../05-icc-profiles-free_2.0.1+dfsg-1.1_all.deb ... Unpacking icc-profiles-free (2.0.1+dfsg-1.1) ... Selecting previously unselected package javascript-common. Preparing to unpack .../06-javascript-common_11+nmu1_all.deb ... Unpacking javascript-common (11+nmu1) ... Selecting previously unselected package libjs-popper.js. Preparing to unpack .../07-libjs-popper.js_1.16.1+ds-6_all.deb ... Unpacking libjs-popper.js (1.16.1+ds-6) ... Selecting previously unselected package libjs-bootstrap5. Preparing to unpack .../08-libjs-bootstrap5_5.3.1+dfsg-1_all.deb ... Unpacking libjs-bootstrap5 (5.3.1+dfsg-1) ... Selecting previously unselected package libjs-jquery. Preparing to unpack .../09-libjs-jquery_3.6.1+dfsg+~3.5.14-1_all.deb ... Unpacking libjs-jquery (3.6.1+dfsg+~3.5.14-1) ... Selecting previously unselected package libjs-jquery-metadata. Preparing to unpack .../10-libjs-jquery-metadata_12-4_all.deb ... Unpacking libjs-jquery-metadata (12-4) ... Selecting previously unselected package libjs-jquery-mousewheel. Preparing to unpack .../11-libjs-jquery-mousewheel_1%3a3.1.13-5_all.deb ... Unpacking libjs-jquery-mousewheel (1:3.1.13-5) ... Selecting previously unselected package libjs-jquery-tablesorter. Preparing to unpack .../12-libjs-jquery-tablesorter_1%3a2.31.3+dfsg1-3_all.deb ... Unpacking libjs-jquery-tablesorter (1:2.31.3+dfsg1-3) ... Selecting previously unselected package libjs-jquery-ui. Preparing to unpack .../13-libjs-jquery-ui_1.13.2+dfsg-1_all.deb ... Unpacking libjs-jquery-ui (1.13.2+dfsg-1) ... Selecting previously unselected package libjs-jquery-timepicker. Preparing to unpack .../14-libjs-jquery-timepicker_1.6.3-6_all.deb ... Unpacking libjs-jquery-timepicker (1.6.3-6) ... Selecting previously unselected package libjs-sizzle. Preparing to unpack .../15-libjs-sizzle_2.3.10+ds+~2.3.6-1_all.deb ... Unpacking libjs-sizzle (2.3.10+ds+~2.3.6-1) ... Selecting previously unselected package libjs-underscore. Preparing to unpack .../16-libjs-underscore_1.13.4~dfsg+~1.11.4-3_all.deb ... Unpacking libjs-underscore (1.13.4~dfsg+~1.11.4-3) ... Selecting previously unselected package libjs-sphinxdoc. Preparing to unpack .../17-libjs-sphinxdoc_7.2.6-6_all.deb ... Unpacking libjs-sphinxdoc (7.2.6-6) ... Selecting previously unselected package libzip4t64:amd64. Preparing to unpack .../18-libzip4t64_1.7.3-1.1ubuntu2_amd64.deb ... Unpacking libzip4t64:amd64 (1.7.3-1.1ubuntu2) ... Selecting previously unselected package node-jquery. Preparing to unpack .../19-node-jquery_3.6.1+dfsg+~3.5.14-1_all.deb ... Unpacking node-jquery (3.6.1+dfsg+~3.5.14-1) ... Selecting previously unselected package php8.3-common. Preparing to unpack .../20-php8.3-common_8.3.15-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.3-common (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php8.3-bz2. Preparing to unpack .../21-php8.3-bz2_8.3.15-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.3-bz2 (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php-bz2. Preparing to unpack .../22-php-bz2_2%3a8.3+95+ubuntu24.04.1+deb.sury.org+1_all.deb ... Unpacking php-bz2 (2:8.3+95+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php-composer-ca-bundle. Preparing to unpack .../23-php-composer-ca-bundle_1.4.1-1_all.deb ... Unpacking php-composer-ca-bundle (1.4.1-1) ... Selecting previously unselected package php-fig-http-message-util. Preparing to unpack .../24-php-fig-http-message-util_1.1.5-2_all.deb ... Unpacking php-fig-http-message-util (1.1.5-2) ... Selecting previously unselected package php8.3-gd. Preparing to unpack .../25-php8.3-gd_8.3.15-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.3-gd (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php-gd. Preparing to unpack .../26-php-gd_2%3a8.3+95+ubuntu24.04.1+deb.sury.org+1_all.deb ... Unpacking php-gd (2:8.3+95+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php-getallheaders. Preparing to unpack .../27-php-getallheaders_3.0.3-3_all.deb ... Unpacking php-getallheaders (3.0.3-3) ... Selecting previously unselected package php-google-recaptcha. Preparing to unpack .../28-php-google-recaptcha_1.3.0-1_all.deb ... Unpacking php-google-recaptcha (1.3.0-1) ... Selecting previously unselected package php-mariadb-mysql-kbs. Preparing to unpack .../29-php-mariadb-mysql-kbs_1.2.14-1_all.deb ... Unpacking php-mariadb-mysql-kbs (1.2.14-1) ... Selecting previously unselected package php8.3-mysql. Preparing to unpack .../30-php8.3-mysql_8.3.15-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.3-mysql (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php-mysql. Preparing to unpack .../31-php-mysql_2%3a8.3+95+ubuntu24.04.1+deb.sury.org+1_all.deb ... Unpacking php-mysql (2:8.3+95+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php-nikic-fast-route. Preparing to unpack .../32-php-nikic-fast-route_1.3.0-4_all.deb ... Unpacking php-nikic-fast-route (1.3.0-4) ... Selecting previously unselected package php-symfony-deprecation-contracts. Preparing to unpack .../33-php-symfony-deprecation-contracts_3.4.1-4_all.deb ... Unpacking php-symfony-deprecation-contracts (3.4.1-4) ... Selecting previously unselected package php-psr-cache. Preparing to unpack .../34-php-psr-cache_3.0.0-4_all.deb ... Unpacking php-psr-cache (3.0.0-4) ... Selecting previously unselected package php-psr-log. Preparing to unpack .../35-php-psr-log_3.0.0-1_all.deb ... Unpacking php-psr-log (3.0.0-1) ... Selecting previously unselected package php-symfony-cache-contracts. Preparing to unpack .../36-php-symfony-cache-contracts_3.4.1-4_all.deb ... Unpacking php-symfony-cache-contracts (3.4.1-4) ... Selecting previously unselected package php-psr-container. Preparing to unpack .../37-php-psr-container_2.0.2-1_all.deb ... Unpacking php-psr-container (2.0.2-1) ... Selecting previously unselected package php-symfony-service-contracts. Preparing to unpack .../38-php-symfony-service-contracts_3.4.1-4_all.deb ... Unpacking php-symfony-service-contracts (3.4.1-4) ... Selecting previously unselected package php-symfony-var-exporter. Preparing to unpack .../39-php-symfony-var-exporter_6.4.5+dfsg-3ubuntu3_all.deb ... Unpacking php-symfony-var-exporter (6.4.5+dfsg-3ubuntu3) ... Selecting previously unselected package php-symfony-cache. Preparing to unpack .../40-php-symfony-cache_6.4.5+dfsg-3ubuntu3_all.deb ... Unpacking php-symfony-cache (6.4.5+dfsg-3ubuntu3) ... Selecting previously unselected package php-symfony-expression-language. Preparing to unpack .../41-php-symfony-expression-language_6.4.5+dfsg-3ubuntu3_all.deb ... Unpacking php-symfony-expression-language (6.4.5+dfsg-3ubuntu3) ... Selecting previously unselected package php-phpmyadmin-motranslator. Preparing to unpack .../42-php-phpmyadmin-motranslator_5.3.1-1_all.deb ... Unpacking php-phpmyadmin-motranslator (5.3.1-1) ... Selecting previously unselected package php-phpmyadmin-shapefile. Preparing to unpack .../43-php-phpmyadmin-shapefile_3.0.2-1_all.deb ... Unpacking php-phpmyadmin-shapefile (3.0.2-1) ... Selecting previously unselected package php-symfony-polyfill-php80. Preparing to unpack .../44-php-symfony-polyfill-php80_1.28.0-1_all.deb ... Unpacking php-symfony-polyfill-php80 (1.28.0-1) ... Selecting previously unselected package php-phpmyadmin-sql-parser. Preparing to unpack .../45-php-phpmyadmin-sql-parser_5.8.2-1_all.deb ... Unpacking php-phpmyadmin-sql-parser (5.8.2-1) ... Selecting previously unselected package php-psr-http-message. Preparing to unpack .../46-php-psr-http-message_1.1-2_all.deb ... Unpacking php-psr-http-message (1.1-2) ... Selecting previously unselected package php-psr-http-factory. Preparing to unpack .../47-php-psr-http-factory_1.0.2-1_all.deb ... Unpacking php-psr-http-factory (1.0.2-1) ... Selecting previously unselected package php-slim-psr7. Preparing to unpack .../48-php-slim-psr7_1.6.1-1_all.deb ... Unpacking php-slim-psr7 (1.6.1-1) ... Selecting previously unselected package php-symfony-filesystem. Preparing to unpack .../49-php-symfony-filesystem_6.4.5+dfsg-3ubuntu3_all.deb ... Unpacking php-symfony-filesystem (6.4.5+dfsg-3ubuntu3) ... Selecting previously unselected package php-symfony-config. Preparing to unpack .../50-php-symfony-config_6.4.5+dfsg-3ubuntu3_all.deb ... Unpacking php-symfony-config (6.4.5+dfsg-3ubuntu3) ... Selecting previously unselected package php-symfony-dependency-injection. Preparing to unpack .../51-php-symfony-dependency-injection_6.4.5+dfsg-3ubuntu3_all.deb ... Unpacking php-symfony-dependency-injection (6.4.5+dfsg-3ubuntu3) ... Selecting previously unselected package php-tcpdf. Preparing to unpack .../52-php-tcpdf_6.7.5+dfsg-1_all.deb ... Unpacking php-tcpdf (6.7.5+dfsg-1) ... Selecting previously unselected package php-twig. Preparing to unpack .../53-php-twig_3.8.0-2_all.deb ... Unpacking php-twig (3.8.0-2) ... Selecting previously unselected package php-twig-i18n-extension. Preparing to unpack .../54-php-twig-i18n-extension_4.1.0-1_all.deb ... Unpacking php-twig-i18n-extension (4.1.0-1) ... Selecting previously unselected package php-webmozart-assert. Preparing to unpack .../55-php-webmozart-assert_1.11.0-1_all.deb ... Unpacking php-webmozart-assert (1.11.0-1) ... Selecting previously unselected package php8.3-zip. Preparing to unpack .../56-php8.3-zip_8.3.15-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.3-zip (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package php-zip. Preparing to unpack .../57-php-zip_2%3a8.3+95+ubuntu24.04.1+deb.sury.org+1_all.deb ... Unpacking php-zip (2:8.3+95+ubuntu24.04.1+deb.sury.org+1) ... Selecting previously unselected package libjs-codemirror. Preparing to unpack .../58-libjs-codemirror_5.65.0+~cs5.83.9-3_all.deb ... Unpacking libjs-codemirror (5.65.0+~cs5.83.9-3) ... Selecting previously unselected package phpmyadmin. Preparing to unpack .../59-phpmyadmin_4%3a5.2.1+dfsg-3_all.deb ... Unpacking phpmyadmin (4:5.2.1+dfsg-3) ... Setting up javascript-common (11+nmu1) ... apache2_invoke: Enable configuration javascript-common Setting up libjs-popper.js (1.16.1+ds-6) ... Setting up php-phpmyadmin-shapefile (3.0.2-1) ... Setting up php-psr-container (2.0.2-1) ... Setting up libjs-jquery-mousewheel (1:3.1.13-5) ... Setting up php-symfony-service-contracts (3.4.1-4) ... Setting up php-getallheaders (3.0.3-3) ... Setting up dbconfig-common (2.0.24) ... Creating config file /etc/dbconfig-common/config with new version Setting up php8.3-common (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.3/mods-available/calendar.ini with new version Creating config file /etc/php/8.3/mods-available/ctype.ini with new version Creating config file /etc/php/8.3/mods-available/exif.ini with new version Creating config file /etc/php/8.3/mods-available/fileinfo.ini with new version Creating config file /etc/php/8.3/mods-available/ffi.ini with new version Creating config file /etc/php/8.3/mods-available/ftp.ini with new version Creating config file /etc/php/8.3/mods-available/gettext.ini with new version Creating config file /etc/php/8.3/mods-available/iconv.ini with new version Creating config file /etc/php/8.3/mods-available/pdo.ini with new version Creating config file /etc/php/8.3/mods-available/phar.ini with new version Creating config file /etc/php/8.3/mods-available/posix.ini with new version Creating config file /etc/php/8.3/mods-available/shmop.ini with new version Creating config file /etc/php/8.3/mods-available/sockets.ini with new version Creating config file /etc/php/8.3/mods-available/sysvmsg.ini with new version Creating config file /etc/php/8.3/mods-available/sysvsem.ini with new version Creating config file /etc/php/8.3/mods-available/sysvshm.ini with new version Creating config file /etc/php/8.3/mods-available/tokenizer.ini with new version Setting up php-fig-http-message-util (1.1.5-2) ... Setting up php-mariadb-mysql-kbs (1.2.14-1) ... Setting up libjs-sizzle (2.3.10+ds+~2.3.6-1) ... Setting up php8.3-mysql (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.3/mods-available/mysqlnd.ini with new version Creating config file /etc/php/8.3/mods-available/mysqli.ini with new version Creating config file /etc/php/8.3/mods-available/pdo_mysql.ini with new version Setting up php-composer-ca-bundle (1.4.1-1) ... Setting up libjs-codemirror (5.65.0+~cs5.83.9-3) ... Setting up icc-profiles-free (2.0.1+dfsg-1.1) ... Setting up php-symfony-filesystem (6.4.5+dfsg-3ubuntu3) ... Setting up php-psr-cache (3.0.0-4) ... Setting up php-webmozart-assert (1.11.0-1) ... Setting up php-twig (3.8.0-2) ... Setting up php-psr-log (3.0.0-1) ... Setting up php-nikic-fast-route (1.3.0-4) ... Setting up php-symfony-polyfill-php80 (1.28.0-1) ... Setting up php8.3-bz2 (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.3/mods-available/bz2.ini with new version Setting up php-google-recaptcha (1.3.0-1) ... Setting up libjs-jquery (3.6.1+dfsg+~3.5.14-1) ... Setting up libmcrypt4 (2.5.8-7) ... Setting up libzip4t64:amd64 (1.7.3-1.1ubuntu2) ... Setting up libjs-bootstrap5 (5.3.1+dfsg-1) ... Setting up php-psr-http-message (1.1-2) ... Setting up node-jquery (3.6.1+dfsg+~3.5.14-1) ... Setting up libjs-underscore (1.13.4~dfsg+~1.11.4-3) ... Setting up php8.3-gd (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.3/mods-available/gd.ini with new version Setting up php-symfony-deprecation-contracts (3.4.1-4) ... Setting up php-mysql (2:8.3+95+ubuntu24.04.1+deb.sury.org+1) ... Setting up php-twig-i18n-extension (4.1.0-1) ... Setting up php-symfony-cache-contracts (3.4.1-4) ... Setting up php-tcpdf (6.7.5+dfsg-1) ... Setting up php-bz2 (2:8.3+95+ubuntu24.04.1+deb.sury.org+1) ... Setting up dbconfig-mysql (2.0.24) ... Setting up php8.3-zip (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.3/mods-available/zip.ini with new version Setting up php8.4-mcrypt (3:1.0.7-5+ubuntu24.04.1+deb.sury.org+1) ... Setting up libjs-jquery-ui (1.13.2+dfsg-1) ... Setting up libjs-jquery-metadata (12-4) ... Setting up php-phpmyadmin-sql-parser (5.8.2-1) ... Setting up libjs-sphinxdoc (7.2.6-6) ... Setting up php-symfony-config (6.4.5+dfsg-3ubuntu3) ... Setting up libjs-jquery-tablesorter (1:2.31.3+dfsg1-3) ... Setting up php-zip (2:8.3+95+ubuntu24.04.1+deb.sury.org+1) ... Setting up libjs-jquery-timepicker (1.6.3-6) ... Setting up php-gd (2:8.3+95+ubuntu24.04.1+deb.sury.org+1) ... Setting up php-mcrypt (3:1.0.7-5+ubuntu24.04.1+deb.sury.org+1) ... Setting up php-psr-http-factory (1.0.2-1) ... Setting up php-symfony-var-exporter (6.4.5+dfsg-3ubuntu3) ... Setting up php-symfony-dependency-injection (6.4.5+dfsg-3ubuntu3) ... Setting up php-slim-psr7 (1.6.1-1) ... Setting up php-symfony-cache (6.4.5+dfsg-3ubuntu3) ... Setting up php-symfony-expression-language (6.4.5+dfsg-3ubuntu3) ... Setting up php-phpmyadmin-motranslator (5.3.1-1) ... Setting up phpmyadmin (4:5.2.1+dfsg-3) ... Determining localhost credentials from /etc/mysql/debian.cnf: Determining localhost credentials from /etc/mysql/debian.cnf: succeeded. dbconfig-common: writing config to /etc/dbconfig-common/phpmyadmin.conf Creating config file /etc/dbconfig-common/phpmyadmin.conf with new version Creating config file /etc/phpmyadmin/config-db.php with new version checking privileges on database phpmyadmin for phpmyadmin@localhost: user creation needed. granting access to database phpmyadmin for phpmyadmin@localhost: success. verifying access for phpmyadmin@localhost: success. creating database phpmyadmin: success. verifying database phpmyadmin exists: success. populating database via sql... done. dbconfig-common: flushing administrative password apache2_invoke: Enable configuration phpmyadmin Processing triggers for libc-bin (2.39-0ubuntu8.3) ... Processing triggers for man-db (2.12.0-4build2) ... Processing triggers for php8.4-cli (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Processing triggers for php8.4-fpm (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... NOTICE: Not enabling PHP 8.4 FPM by default. NOTICE: To enable PHP 8.4 FPM in Apache2 do: NOTICE: a2enmod proxy_fcgi setenvif NOTICE: a2enconf php8.4-fpm NOTICE: You are seeing this message because you have apache2 package installed. Processing triggers for libapache2-mod-php8.4 (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Scanning processes... Scanning candidates... Scanning processor microcode... Scanning linux images... Running kernel seems to be up-to-date. The processor microcode seems to be up-to-date. Restarting services... Service restarts being deferred: /etc/needrestart/restart.d/dbus.service systemctl restart systemd-logind.service No containers need to be restarted.
Let's test to see if it worked.
To access phpMyAdmin installed on Ubuntu, open your web browser and navigate to the URL “your_server_address/phpmyadmin” where “your_server_address” is the IP address or domain name of your Ubuntu server; you can usually access it locally using “localhost/phpmyadmin” if you're accessing from the same machine as the server.
URL format: “your_server_address/phpmyadmin” Local access: “localhost/phpmyadmin” Login credentials: Use the MySQL username and password that you configured during phpmyadmin installation.
I plan to login with username “phpmyadmin” and the password I entered and confirmed during installation.
Install NextCloud Server Version 30.0.4
Before downloading NextCloud version 30.0.1, we need to first install an unzip utility on Ubuntu.
sudo apt install unzip
Output
Reading package lists... Done Building dependency tree... Done Reading state information... Done Suggested packages: zip The following NEW packages will be installed: unzip 0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded. Need to get 174 kB of archives. After this operation, 384 kB of additional disk space will be used. Get:1 http://us.archive.ubuntu.com/ubuntu noble-updates/main amd64 unzip amd64 6.0-28ubuntu4.1 [174 kB] Fetched 174 kB in 2s (102 kB/s) Selecting previously unselected package unzip. (Reading database ... 95255 files and directories currently installed.) Preparing to unpack .../unzip_6.0-28ubuntu4.1_amd64.deb ... Unpacking unzip (6.0-28ubuntu4.1) ... Setting up unzip (6.0-28ubuntu4.1) ... Processing triggers for man-db (2.12.0-4build2) ... Scanning processes... Scanning candidates... Scanning processor microcode... Scanning linux images... Running kernel seems to be up-to-date. The processor microcode seems to be up-to-date. Restarting services... Service restarts being deferred: /etc/needrestart/restart.d/dbus.service systemctl restart systemd-logind.service No containers need to be restarted.
PHP Version 8.4 Is not supported by NextCloud Version 30.0.4. So disable and uninstall php8.4
Install and Enable PHP Version 8.3 including PHP8.3-CLI
Use Browser DUCK DUCK GO to load NextCloud for the first time. Chrome won't render anything without an SSL certificate installed on the server.
Here is what showed up on the first NextCloud page to display in my browser. Let me go track down all of these modules and see how to get them installed and/or enabled.
Error PHP module dom not installed. Please ask your server administrator to install the module. PHP module XMLWriter not installed. Please ask your server administrator to install the module. PHP module XMLReader not installed. Please ask your server administrator to install the module. PHP module libxml not installed. Please ask your server administrator to install the module. PHP module mbstring not installed. Please ask your server administrator to install the module. PHP module SimpleXML not installed. Please ask your server administrator to install the module. PHP module cURL not installed. Please ask your server administrator to install the module. PHP modules have been installed, but they are still listed as missing? Please ask your server administrator to restart the web server.
PHP MODULES CURRENTLY INSTALLED
php -m [command] [PHP Modules] bz2 calendar Core ctype date exif FFI fileinfo filter ftp gd gettext hash iconv json libxml mysqli mysqlnd openssl pcntl pcre PDO pdo_mysql Phar posix random readline Reflection session shmop sockets sodium SPL standard sysvmsg sysvsem sysvshm tokenizer Zend OPcache zip zlib [Zend Modules] Zend OPcache
sudo apt install php8.3-mbstring
Reading package lists... Done Building dependency tree... Done Reading state information... Done The following packages were automatically installed and are no longer required: libmcrypt4 php8.4-readline Use 'sudo apt autoremove' to remove them. The following NEW packages will be installed: php8.3-mbstring 0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded. Need to get 512 kB of archives. After this operation, 1,239 kB of additional disk space will be used. Get:1 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.3-mbstring amd64 8.3.15-1+ubuntu24.04.1+deb.sury.org+1 [512 kB] Fetched 512 kB in 1s (346 kB/s) Selecting previously unselected package php8.3-mbstring. (Reading database ... 95273 files and directories currently installed.) Preparing to unpack .../php8.3-mbstring_8.3.15-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.3-mbstring (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Setting up php8.3-mbstring (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.3/mods-available/mbstring.ini with new version Processing triggers for libapache2-mod-php8.3 (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Processing triggers for php8.3-cli (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Scanning processes... Scanning candidates... Scanning processor microcode... Scanning linux images... Running kernel seems to be up-to-date. The processor microcode seems to be up-to-date. Restarting services... Service restarts being deferred: /etc/needrestart/restart.d/dbus.service systemctl restart systemd-logind.service No containers need to be restarted.
sudo apt autoremove Reading package lists... Done Building dependency tree... Done Reading state information... Done The following packages will be REMOVED: libmcrypt4 php8.4-readline 0 upgraded, 0 newly installed, 2 to remove and 2 not upgraded. After this operation, 269 kB disk space will be freed. Do you want to continue? [Y/n] Y (Reading database ... 95282 files and directories currently installed.) Removing libmcrypt4 (2.5.8-7) ... Removing php8.4-readline (8.4.2-1+ubuntu24.04.1+deb.sury.org+1) ... Processing triggers for libc-bin (2.39-0ubuntu8.3) ...
sudo apt install php8.3-XMLWriter
Reading package lists... Done Building dependency tree... Done Reading state information... Done Note, selecting 'php8.3-xmlwriter' for glob 'php8.3-XMLWriter' Note, selecting 'php8.3-xml' instead of 'php8.3-xmlwriter' The following NEW packages will be installed: php8.3-xml 0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded. Need to get 128 kB of archives. After this operation, 509 kB of additional disk space will be used. Get:1 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.3-xml amd64 8.3.15-1+ubuntu24.04.1+deb.sury.org+1 [128 kB] Fetched 128 kB in 1s (127 kB/s) Selecting previously unselected package php8.3-xml. (Reading database ... 95268 files and directories currently installed.) Preparing to unpack .../php8.3-xml_8.3.15-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.3-xml (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Setting up php8.3-xml (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.3/mods-available/dom.ini with new version Creating config file /etc/php/8.3/mods-available/simplexml.ini with new version Creating config file /etc/php/8.3/mods-available/xml.ini with new version Creating config file /etc/php/8.3/mods-available/xmlreader.ini with new version Creating config file /etc/php/8.3/mods-available/xmlwriter.ini with new version Creating config file /etc/php/8.3/mods-available/xsl.ini with new version Processing triggers for libapache2-mod-php8.3 (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Processing triggers for php8.3-cli (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Scanning processes... Scanning candidates... Scanning processor microcode... Scanning linux images... Running kernel seems to be up-to-date. The processor microcode seems to be up-to-date. Restarting services... Service restarts being deferred: /etc/needrestart/restart.d/dbus.service systemctl restart systemd-logind.service No containers need to be restarted.
sudo apt install php8.3-XMLReader
Reading package lists... Done Building dependency tree... Done Reading state information... Done Note, selecting 'php8.3-xmlreader' for glob 'php8.3-XMLReader' Note, selecting 'php8.3-xml' instead of 'php8.3-xmlreader' php8.3-xml is already the newest version (8.3.15-1+ubuntu24.04.1+deb.sury.org+1). 0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
sudo apt install php8.3-SimpleXML Reading package lists... Done Building dependency tree... Done Reading state information... Done Note, selecting 'php8.3-simplexml' for glob 'php8.3-SimpleXML' Note, selecting 'php8.3-xml' instead of 'php8.3-simplexml' php8.3-xml is already the newest version (8.3.15-1+ubuntu24.04.1+deb.sury.org+1). 0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
sudo apt install php8.3-cURL Reading package lists... Done Building dependency tree... Done Reading state information... Done Note, selecting 'php8.3-curl' for glob 'php8.3-cURL' The following NEW packages will be installed: php8.3-curl 0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded. Need to get 40.7 kB of archives. After this operation, 160 kB of additional disk space will be used. Get:1 https://ppa.launchpadcontent.net/ondrej/php/ubuntu noble/main amd64 php8.3-curl amd64 8.3.15-1+ubuntu24.04.1+deb.sury.org+1 [40.7 kB] Fetched 40.7 kB in 1s (40.2 kB/s) Selecting previously unselected package php8.3-curl. (Reading database ... 95287 files and directories currently installed.) Preparing to unpack .../php8.3-curl_8.3.15-1+ubuntu24.04.1+deb.sury.org+1_amd64.deb ... Unpacking php8.3-curl (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Setting up php8.3-curl (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Creating config file /etc/php/8.3/mods-available/curl.ini with new version Processing triggers for libapache2-mod-php8.3 (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Processing triggers for php8.3-cli (8.3.15-1+ubuntu24.04.1+deb.sury.org+1) ... Scanning processes... Scanning candidates... Scanning processor microcode... Scanning linux images... Running kernel seems to be up-to-date. The processor microcode seems to be up-to-date. Restarting services... Service restarts being deferred: /etc/needrestart/restart.d/dbus.service systemctl restart systemd-logind.service No containers need to be restarted.
Installing Certbot and Requesting LetsEncrypt SSL Certificate
sudo systemctl stop apache2 user@svr:/var/lib$ sudo certbot certonly --standalone -d example.com -d www.example.com Saving debug log to /var/log/letsencrypt/letsencrypt.log Requesting a certificate for example.com and www.example.com Successfully received certificate. Certificate is saved at: /etc/letsencrypt/live/example.com/fullchain.pem Key is saved at: /etc/letsencrypt/live/example.com/privkey.pem This certificate expires on 2025-03-31. These files will be updated when the certificate renews. Certbot has set up a scheduled task to automatically renew this certificate in the background. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - If you like Certbot, please consider supporting our work by: * Donating to ISRG / Let's Encrypt: https://letsencrypt.org/donate * Donating to EFF: https://eff.org/donate-le
Virtual Host Files for Port 80 and LetsEncrypt Port 443
Example of Virtual Host for Domain Where NextCloud will be hosted on Apache2 Listening on Port 80.
<Virtualhost *:80> ServerName example.com ServerAlias www.example.com DocumentRoot "/var/www/nextcloud/public_html/example_com/nextcloud" Protocols h2 http/1.1 # log files ErrorLog ${APACHE_LOG_DIR}/examplecom.error CustomLog ${APACHE_LOG_DIR}/examplecom.access combined # HSTS <IfModule mod_headers.c> Header always set Strict-Transport-Security "max-age=15552000; includeSubDomains" </IfModule> <Directory /var/www/nextcloud/public_html/example_com/nextcloud/> Require all granted Options FollowSymLinks MultiViews AllowOverride All <IfModule mod_dav.c> Dav off </IfModule> SetEnv HOME /var/www/nextcloud/public_html/example_com/nextcloud SetEnv HTTP_HOME /var/www/nextcloud/public_html/example_com/nextcloud </Directory> RewriteEngine on RewriteCond %{SERVER_NAME} =www.example.com [OR] RewriteCond %{SERVER_NAME} =example.com RewriteRule ^ https://%{SERVER_NAME}%{REQUEST_URI} [END,NE,R=permanent] </VirtualHost>
Example of Virtual Host with path to LetsEncrypt SSL Certificates for the NextCloud Domain Listening on SSL Port 443
<IfModule mod_ssl.c> <VirtualHost *:443> ServerName example.com ServerAlias www.example.com ServerAdmin webmaster@localhost DocumentRoot /var/www/nextcloud/public_html/example_com/nextcloud ErrorLog ${APACHE_LOG_DIR}/example.com-error.log CustomLog ${APACHE_LOG_DIR}/example.com-access.log combined SSLEngine on # HSTS <IfModule mod_headers.c> Header always set Strict-Transport-Security "max-age=15552000; includeSubDomains" </IfModule> <Directory /var/www/nextcloud/public_html/example_com/nextcloud/> Options +FollowSymlinks AllowOverride All <IfModule mod_dav.c> Dav off </IfModule> SetEnv HOME /var/www/nextcloud/public_html/example_com/nextcloud SetEnv HTTP_HOME /var/www/nextcloud/public_html/example_com/nextcloud </Directory> SSLCertificateFile /etc/letsencrypt/live/example.com/fullchain.pem SSLCertificateKeyFile /etc/letsencrypt/live/example.com/privkey.pem <FilesMatch "\.(?:cgi|shtml|phtml|php)$"> SSLOptions +StdEnvVars </FilesMatch> <Directory /usr/lib/cgi-bin> SSLOptions +StdEnvVars </Directory> </VirtualHost> </IfModule>
Stay tuned! Work is still in progress.
Last Updated 12/30/2024 2:37 AM EST