I'm using Ubuntu 15.04 - 64 Bit with the following setup:
Apache
Server version: Apache/2.4.10 (Ubuntu), Server built: Jul 24 2015 17:25:18
PHP
PHP 5.6.4-4ubuntu6.2 (cli) (built: Jul 2 2015 15:29:28) Copyright, (c) 1997-2014 The PHP Group Zend Engine v2.6.0, Copyright (c), 1998-2014 Zend Technologies with Zend OPcache v7.0.4-dev, Copyright, (c) 1999-2014, by Zend Technologies
My php.ini (The last 5 lines)
; Local Variables:
; tab-width: 4
; End
zend.loader=1
zend_extension="/var/www/extensions/ZendGuardLoader_56.so"
And yeah, ZendGuardLoader won't be loaded (it's not mentioned in "php -v" and also not in "phpinfo()"). Thread safety is disabled! If you need other options, let me know.
What i've tried so far:
Also nice to know:
My Apache Error Log is also "clean". If i rename the .so file, my Apache logs that exception. But on the current setup, the file is readable.. Don't get me wrong, but i expect a message like "ZendGuardLoader can't be loaded because "..
Update1
After a few hours, i'm pretty scared! I've installed vagrant incl. "Debian 7.8" as well, started everything and so on. On my box i've installed PHP (5.4) and Apache, created the www folder to the same destination, and downloaded the 5.4 ZendGuard Loader. In my box setup i did the same, as on my main system like -> php.ini, last entry: "zend_extension=/vagrant/ZendGuardLoader.so"
The file exists, is readable as well, and so on. After creating a new "info.php" ("phpinfo()"), it's still without ZendGuardLoader Extension. The command php -v says mostly same, as main system (differences on version..).
Solution for php -v
Okay guys, my mind was broken - but it's not fixed! I told you, by checking php -v the output is pretty default (no ZendGuardLoader). BUT(!): php -v gets executed by commandline (cli) - so i've added the "zend_extension" inside php5\cli\php.ini -> works like a charm!
PHP 5.4.41-0+deb7u1 (cli) (built: May 22 2015 12:49:18) Copyright (c) 1997-2014 The PHP Group Zend Engine v2.4.0, Copyright (c) 1998-2014 Zend Technologies with Zend Guard Loader v3.3, Copyright (c) 1998-2013, by Zend Technologies
That's what i've wanted. So i've called the phpinfo file by using commandline - and save the output into a separated file. And as i can see, the ZendGuardLoader is given, too!
But there is still the Apache Problem. The zend_extension line matches exactly between apache2\php.ini and cli\php.ini.
So it's not a permission problem, because CLI has no problem. I think, apache is broken, because it won't load that less special extension..
A new day - new ideas
Okay guys, yesterday we got the point, why it won't work on CLI, but that's less the major problem. So i've integrated ioncube on CLI and also on apache. CLI works like a charm. Apache won't load ioncube, too. So what is wrong with this apache..?
I tried to provoke some errors by creating a new file in the php5\apache2\conf.d\ directory. The new file contains the same "zend_extension=/vagrant/ZendGuardLoader.so" snippet, as my php5\apache2\php.ini - so apache2 would try to load the .so twice, and throws the expected error:
PHP Fatal error: [Zend Guard Loader] Extension "Zend Guard Loader" cannot be loaded twice in Unknown on line 0
Apache tries to load both extensions. So i might be right, if i'm gonna say, apache2 load the extension, if it's only one! But it seems, that apache can't work with the extension. Remember - php cli ("php -v" / "php -m" ) can!
For all those people, who wanna to know the solution:
After debugging Apache for a while, i've found, that the include per apache2\php.ini won't work correctly for me. So i've created a new file inside apache2\conf.d\ - and deleted the entry inside apache2\php.ini.
After reloading apache2 nothing changed, but phpinfo() says, the extensions was loaded. I've reloaded again - and, finally!, everything works. I am not sure, what happens to me or apache2.
The curios thing at all: I've to reload apache2 twice after restarting VM. But after that process, everything works perfect. So guys..
TL;DR;
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With