LoginSignup
3
1

More than 5 years have passed since last update.

Laravel動作時にmcrypt関係のエラーが出る

Posted at

環境

  • Ubuntu 14.10 (VMWare)
  • Laravel Framework version 5.0.31
  • php5.5

事象

Laraveでビルドインサーバ実行時に以下のようなMCRYPT関係のエラーが出る。また、ブラウザで確認しようとしても、画像のようなエラーが出る。

root@ubuntu:~/sample# php artisan serve
PHP Notice:  Use of undefined constant MCRYPT_RIJNDAEL_128 - assumed 'MCRYPT_RIJNDAEL_128' in /root/sample/config/app.php on line 83
Laravel development server started on http://localhost:8000/
[Sat May 30 19:38:36 2015] PHP Notice:  Use of undefined constant MCRYPT_RIJNDAEL_128 - assumed 'MCRYPT_RIJNDAEL_128' in /root/sample/config/app.php on line 83
[Sat May 30 19:38:36 2015] PHP Fatal error:  Call to undefined function Illuminate\Encryption\mcrypt_get_iv_size() in /root/sample/vendor/compiled.php on line 12184

ScreenClip.png

対処方法

mcryptをインストール/有効化して、再度実行する

# apt-get install php5-mcrypt
# php5enmod mcrypt
# php artisan serve
Laravel development server started on http://localhost:8000/

3
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
1