やきにくとくにきや

WEBサービスとイベントに夢見るエンジニアの技術メモ、チラシの裏。そして焼肉たべたい

PHP5.3からPHP5.5にアップデート

      2016/04/04

今更だけどメモ

[shell]
rpm -ivh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm

# yum info php --enablerepo=remi-php55,remi
Loaded plugins: downloadonly, fastestmirror, priorities, security
Loading mirror speeds from cached hostfile
* base: www.ftp.ne.jp
* epel: ftp.kddilabs.jp
* extras: www.ftp.ne.jp
* remi: remi.kazukioishi.net
* remi-php55: remi.kazukioishi.net
* updates: www.ftp.ne.jp
base | 3.7 kB 00:00
extras | 3.4 kB 00:00
remi | 2.9 kB 00:00
remi/primary_db | 696 kB 00:00
remi-php55 | 2.9 kB 00:00
remi-php55/primary_db | 150 kB 00:00
updates | 3.4 kB 00:00
531 packages excluded due to repository priority protections
Installed Packages
Name : php
Arch : x86_64
Version : 5.3.3
Release : 27.el6_5
Size : 3.5 M
Repo : installed
From repo : updates
Summary : PHP scripting language for creating dynamic web sites
URL : http://www.php.net/
License : PHP
Description : PHP is an HTML-embedded scripting language. PHP attempts to make it
: easy for developers to write dynamically generated webpages. PHP also
: offers built-in database integration for several commercial and
: non-commercial database management systems, so writing a
: database-enabled webpage with PHP is fairly simple. The most common
: use of PHP coding is probably as a replacement for CGI scripts.
:
: The php package contains the module which adds support for the PHP
: language to Apache HTTP Server.

Available Packages
Name : php
Arch : x86_64
Version : 5.5.13
Release : 1.el6.remi
Size : 2.6 M
Repo : remi-php55
Summary : PHP scripting language for creating dynamic web sites
URL : http://www.php.net/
License : PHP and Zend and BSD
Description : PHP is an HTML-embedded scripting language. PHP attempts to make it
: easy for developers to write dynamically generated web pages. PHP also
: offers built-in database integration for several commercial and
: non-commercial database management systems, so writing a
: database-enabled webpage with PHP is fairly simple. The most common
: use of PHP coding is probably as a replacement for CGI scripts.
:
: The php package contains the module (often referred to as mod_php)
: which adds support for the PHP language to Apache HTTP Server.
[/shell]

■更新
[shell]
yum update php --enablerepo=remi-php55,remi
[/shell]

■OPCACHE入れる
[shell]
yum install php-opcache --enablerepo=remi-php55,remi
[/shell]

[shell]
vim /etc/php.d/opcache.ini で
[/shell]

opcache.enable=1
であることを確認する。

[shell]
service httpd restart

# php -r 'phpinfo();' | grep opcache
/etc/php.d/opcache.ini,
opcache.blacklist_filename => /etc/php.d/opcache*.blacklist => /etc/php.d/opcache*.blacklist
opcache.consistency_checks => 0 => 0
opcache.dups_fix => Off => Off
opcache.enable => On => On
opcache.enable_cli => Off => Off
opcache.enable_file_override => Off => Off
opcache.error_log => no value => no value
opcache.fast_shutdown => 1 => 1
opcache.file_update_protection => 2 => 2
opcache.force_restart_timeout => 180 => 180
opcache.inherited_hack => On => On
opcache.interned_strings_buffer => 8 => 8
opcache.load_comments => 1 => 1
opcache.log_verbosity_level => 1 => 1
opcache.max_accelerated_files => 4000 => 4000
opcache.max_file_size => 0 => 0
opcache.max_wasted_percentage => 5 => 5
opcache.memory_consumption => 128 => 128
opcache.optimization_level => 0xFFFFFFFF => 0xFFFFFFFF
opcache.preferred_memory_model => no value => no value
opcache.protect_memory => 0 => 0
opcache.restrict_api => no value => no value
opcache.revalidate_freq => 2 => 2
opcache.revalidate_path => Off => Off
opcache.save_comments => 1 => 1
opcache.use_cwd => On => On
opcache.validate_timestamps => On => On
[/shell]

opcache.enableがOnになってればOK

そしてphpMyAdminがログインできなくなった

調べたところ古い暗号方式が非推奨になっているためだとか
パスワードを再設定して解決

 - PHP, シェルスクリプト ,