
phpMyAdmin error “Error: Undefined constant "SODIUM_CRYPTO_SECRETBOX_KEYBYTES"” (SOLVED)
October 20, 2022
On Arch Linux, when trying to use the phpMyAdmin 5.3 pre-release, I encountered an error:
Error: Undefined constant "SODIUM_CRYPTO_SECRETBOX_KEYBYTES"
Checking in Debian showed that there is no such problem with phpMyAdmin 5.3.
The reason for the error is that sodium support is not enabled.
How to enable sodium on Arch Linux (Manjaro, BlackArch)
To enable sodium support in Arch Linux and derivative distributions (Manjaro, BlackArch) follow these steps.
Install the php-sodium package:
sudo pacman -S php-sodium
Open the /etc/php/php.ini file:
sudo gedit /etc/php/php.ini
Find the line in it
;extension=sodium
and uncomment it to get:
extension=sodium
Restart the web server for the changes to take effect:
sudo systemctl restart httpd.service
This will enable sodium support and the error in phpMyAdmin 5.3 will disappear.
Related articles:
- Error “No such file or directory: AH02454: FCGI: attempt to connect to Unix domain socket /run/php/php8.1-fpm.sock (*:80) failed” (SOLVED) (73.2%)
- How to install and use pikaur and makepkg on a server (72.9%)
- How to reboot a server in DigitalOcean (69.6%)
- How to install Python as a CGI module in Apache on Linux (59.6%)
- How to set up Python as a CGI module in Apache on Arch Linux (Manjaro, BlackArch) (59.6%)
- bash: finger: command not found in Arch Linux (RESOLVED) (RANDOM - 50.5%)