• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Zend problem after upgrade

J

jprice

Guest
hello,

after my upgrade to 8.0 Zend Optmizer no longer works on my server. I've found a couple threads on the forum, but nothing really seemed to answer my problem.

[root@sv01 ~]# php -v
PHP: Error parsing /etc/php.ini on line 2
PHP 4.3.9 (cgi) (built: Nov 4 2005 11:49:35)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies
with the ionCube PHP Loader v3.0.10, Copyright (c) 2002-2005, by ionCube Ltd.


I've tried to reinstall zend but it didn't fix the problem. Anyone know a solution?

Thanks
 
this is my entire /etc/phi.ini file

memory_limit = "32M"
include_path = "\".:\""
short_open_tag = "On"
file_uploads = "On"
safe_mode = "On"

safe_mode = Off




what the hell
 
Look for a backup php.ini that plesk would have made when it overwrote this one. This is a known problem where it overwrites your php.ini with a file like you have now.

I suggest doing:

mv /etc/php.ini /etc/php.ini.bad

and then

mv /etc/php.ini.bak (or whatever plesk backed it up as) /etc/php.ini

Look at the date to see which ini backup file was modified when you upgraded. It should be the most recently dated one.
 
Zend uses a symlink for php.ini.
the actual path should be /usr/local/Zend/etc/php.ini, which Plesk did not understand (go figure), so it deleted the symlink holder at /etc/php.ini and created a simplictic and useless one in it's place.
Simply recreate the symlink, and all should be well again. At least, it was for me.
 
well I semmed to fix the php.ini file I think, but zend still isn't working on my server


[root@sv01 /]# apachectl restart
[root@sv01 /]# php -v
PHP 4.3.9 (cgi) (built: Nov 4 2005 11:49:35)
Copyright (c) 1997-2004 The PHP Group
Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies
with the ionCube PHP Loader v3.0.10, Copyright (c) 2002-2005, by ionCube Ltd.
[root@sv01 /]#


but its still showing Zend 1.3.0 and I have tried to reinstall v3.0.0 again and again and nothing is changing. I even tried to install v2.6.2 and nothing :confused:
 
If you did a standard install, as NightStorm mentioned, your php.ini should be in /usr/local/Zend/etc/php.ini and /etc/php.ini should be a symlink to that file.

Confirm that that is the case first.

Check which php.ini file php is using.
# php -i | grep 'Configuration File'

Open that file and see what Zend Optimizer version and directory is being referenced.

They should likely be at the bottom of the file. If you are using vi(m) to edit the file you can type /\[Zend\] and hit enter which should take you to the area you want to be.

You probably will want to find all php.ini and backup files that exist on your system and remove the ones that you don't need anymore.
**NOTE** Don't remove the php.ini required for Plesk to run. /usr/local/psa/admin/conf/php.ini

As an example, I have the following on mine:
/etc/php.ini (symlink)
/usr/local/psa/admin/conf/php.ini (and .bak)
/usr/local/Zend/etc/php.ini (and .bak)
 
# php -i | grep 'Configuration File'
doesn't return anything


my /etc/php.ini file is a symlink to /usr/local/Zend/etc/php.ini
 
You didn't type in the # did you? That was just showing that I ran the command as root.

Did you look at your php.ini file in the Zend etc directory to see what version it had listed?
 
Back
Top