ã¯ããã«
Debian GNU/Linux 11.2ä¸ã§ã½ããã¦ã§ã¢ã®æ´æ°ï¼apt upgradeï¼ã¨WordPress 5.9ã¸ã®æ´æ°ãã»ã¼åæã«è¡ã£ãããã使ãã®ãµã¼ãã¼ã® PHP ã§ã¯ WordPress ã«å¿ è¦ãª MySQL æ¡å¼µãå©ç¨ã§ããªãããã§ãããã¨ããã¡ãã»ã¼ã¸ãã§ã¦åããªããªã£ã¦ãã¾ã£ãã
åå ã¯apt upgradeæã«PHPã8.0ç³»ãã8.1ç³»ã¸åãæ¿ãã£ããããWordPressã¯é¢ä¿ãªãã¨ã©ã¼ã ã£ãããWordPressãPHP 8.1ã§ãåãã¦ããä¾ã¨ãã¦è¨é²ãã¦ããã
ç°å¢
% cat /etc/debian_version 11.2 % mysql --version mysql Ver 15.1 Distrib 10.5.12-MariaDB, for debian-linux-gnu (x86_64) using EditLine wrapper % php -v PHP 8.1.3 (cli) (built: Feb 23 2022 16:07:16) (NTS) Copyright (c) The PHP Group Zend Engine v4.1.3, Copyright (c) Zend Technologies with Zend OPcache v8.1.3, Copyright (c), by Zend Technologies % apache2ctl -v Server version: Apache/2.4.52 (Debian) Server built: 2022-01-03T21:27:14
ç¾è±¡
ã½ããã¦ã§ã¢ã®å®æã¢ããã°ã¬ã¼ããããããWordPressã§ãã使ãã®ãµã¼ãã¼ã® PHP ã§ã¯ WordPress ã«å¿ è¦ãª MySQL æ¡å¼µãå©ç¨ã§ããªãããã§ãããã¨ããã¡ãã»ã¼ã¸ãã§ã¦ãã°ã¤ã³ã§ããªããªã£ã¦ãã¾ã£ãã
å®æã¢ããã°ã¬ã¼ãã¯ä»¥ä¸ã®éãã
% sudo apt update % sudo apt upgrade -y
åå
Apache 2.4ã§PHP8.1ã®ã¢ã¸ã¥ã¼ã«ï¼libapache2-mod-php8.1ï¼ãæå¹åããå¿ è¦ããã£ãã以ä¸ã®ããã«ãã¦PHP 8.1ã®ã¢ã¸ã¥ã¼ã«ãæå¹åããPHP 8.0ã®ã¢ã¸ã¥ã¼ã«ãç¡å¹åããã
ï¼ã¤ã³ã¹ãã¼ã«æ¸ã¿ãªã®ã確èªï¼ % dpkg -l | grep libapache2-mod-php8 ii libapache2-mod-php8.0 8.0.16-1+0~20220221.30+debian11~1.gbp8b91a5 amd64 server-side, HTML-embedded scripting language (Apache 2 module) ii libapache2-mod-php8.1 8.1.3-1+0~20220223.13+debian11~1.gbp7757b9 amd64 server-side, HTML-embedded scripting language (Apache 2 module) % sudo a2enmod php8.1 % sudo a2dismod php8.0 % sudo systemctl restart apache2
WordPress5.9ã¸ã®æ´æ°ã«ã¨ããªã追å ã¤ã³ã¹ãã¼ã«
WordPressã®ãµã¤ããã«ã¹ã¹ãã¼ã¿ã¹ã®æ©è½ã§ããã¤ãã®æ¨å¥¨PHPã¢ã¸ã¥ã¼ã«ã足ããªãã¨ããã¡ãã»ã¼ã¸ãã§ã¦ããã®ã§è¿½å ããã
- curl
- dom
- imagick
- zip
- intl
以ä¸ã®ã³ãã³ãã§ã¤ã³ã¹ãã¼ã«ã§ãããã¤ã³ã¹ãã¼ã«å¾ã«Apacheãåèµ·åãããµã¤ããã«ã¹ã¹ãã¼ã¿ã¹ã®æ©è½ã§å½è©²ã¢ã¸ã¥ã¼ã«ãã¤ã³ã¹ãã¼ã«ã§ãã¦ããï¼è¶³ããªãã¨ããã¡ãã»ã¼ã¸ãã§ã¦ããªãï¼ãã¨ã確èªããã
% apt install php-curl % apt install php-dom (注ï¼php8.1-xmlãã¤ã³ã¹ãã¼ã«ãããï¼ % apt install php-imagick % apt install php-zip % apt install php-intl % sudo systemctl restart apache2