ssh以root用户登入服务器 执行以下命令

    # yum install libmcrypt libmcrypt-devel mcrypt mhash
    
    # wget  http://pecl.php.net/get/mcrypt-1.0.1.tgz
    
    # tar xf mcrypt-1.0.1.tgz
    
    # cd mcrypt-1.0.1
    
    # /www/server/php/72/bin/phpize
    
    # ./configure --with-php-config=/www/server/php/72/bin/php-config  && make && make install

将下方代码放入php.ini配置文件中

    extension=mcrypt.so