I'm getting the below error in the logs after a reboot, prior to the reboot everything was working perfectly. It's running on a Win 2008 server.
I've tried absolutely everything but just can't figure out what's going on, any help greatly appreciated?!
[Fri Nov 08 11:07:06.787392 2013] [mpm_winnt:notice] [pid 4916:tid 616] AH00418: Parent: Created child process 1704
PHP Warning: PHP Startup: Unable to load dynamic library 'c:/Program Files (x86)/PHP/ext/php_oci8_11g.dll' - The specified procedure could not be found.\r\n in Unknown on line 0
Found the answer, I've outlined it below.
If you've installed any other Oracle software on the same server, the instant client path has to be the first path in the environment PATH variable otherwise the OCI8 extension will use ORACLE_HOME as it is set by the first Oracle path it finds in the environment PATH variable.
You will need to reboot the machine after this to allow for PHP to pick-up the path changes.
Related
I'm having a problem with sql server drivers for a php project, I follow the instructions given by the documentation on github, I added the dll's on the ext directory, changed the php.ini file and added the extensions like:
extension=php_sqlsrv_7_ts.dll
extension=php_pdo_sqlsrv_7_ts.dll
I restarted the pc and the server.
Php environment path is set and working.
however every time I tried to execute the server I get this error:
[Mon Nov 21 14:23:30 2016] PHP Warning: PHP Startup: Unable to load
dynamic library 'C:\php_7\ext\php_sqlsrv_7_ts.dll' - The specified module
could not be found.
in Unknown on line 0
[Mon Nov 21 14:23:30 2016] PHP Warning: PHP Startup: Unable to load
dynamic library 'C:\php_7\ext\php_pdo_sqlsrv_7_ts.dll' - The specified
module could not be found. in Unknown on line 0
What I'm missing
I managed to make it worke by using the non thread safe nts, instead of the thread safe ts
extension=php_sqlsrv_7_nts.dll
extension=php_pdo_sqlsrv_7_nts.dll
So I downloaded the php_ibm_db2.dll 5.6 Non Thread Safe (NTS) x86 extension from https://pecl.php.net/package/ibm_db2/1.9.9/windows, added it to php.ini and was getting the exact same error. In my case all I had to do was to downlaod the thread safe version of the lib: 5.6 Thread Safe (TS) x86.
I followed This tutorial for installing Laravel 5 on a shared cpanel hosting. Everything went smooth, but I get an error when I open my website:
Internal Server Error
The server encountered an internal error or misconfiguration and was
unable to complete your request.
Please contact the server administrator at webmaster#naxon.co.il to
inform them of the time this error occurred, and the actions you
performed just before this error.
More information about this error may be available in the server error
log.
Additionally, a 500 Internal Server Error error was encountered while
trying to use an ErrorDocument to handle the request. Apache/2.4.18
(Unix) OpenSSL/1.0.1e-fips mod_bwlimited/1.4 Server at naxon.co.il
Port 80
This is how my log file looks like:
[Sat Apr 09 00:36:06 2016] [error] [client *] SoftException in Application.cpp:256: File "/home/naxond/laravel/public/index.php" is writeable by group
[Sat Apr 09 00:36:06 2016] [error] [client *] Premature end of script headers: index.php
Any ideas?
Change the file permissions from '0664' to '0644'. It's complaining because that file (or folder) is writable by group and needs corrected to more secure permissions.
Before upload your project, you must to be sure that the server match the following requirements:
PHP >= 5.5.9
OpenSSL PHP Extension
PDO PHP Extension
Mbstring PHP Extension
Tokenizer PHP Extension
As you can see in your logs, all the erros are related with the server requirements:
Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20131226/php_mbstring.dll' you don't have Mbstring PHP Extension installed.
Unable to load dynamic library '/usr/local/lib/php/extensions/no-debug-non-zts-20131226/php_openssl.dll, you don't have OpenSSL PHP Extension
and so on.
You can check all the laravel requirements in their documentation.
Laravel 5 DOC
Anyway, you can try to install the libraries if you have full access to the server.
Regards!
Change public/index.php file permissions from 0664 to 0644
I am just beginning with laravel. I followed all the steps mentioned in here: http://github.com/aimeos/aimeos-laravel and tried running the final project using this command:
php artisan serve
It is giving me an error:
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/20151012/php_mbstring.dll' - /usr/lib/php/20151012/php_mbstring.dll: cannot open shared object file: No such file or directory in Unknown on line 0
Laravel development server started on http://localhost:8000/
[Wed Apr 13 17:03:32 2016] PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/20151012/php_mbstring.dll' - /usr/lib/php/20151012/php_mbstring.dll: cannot open shared object file: No such file or directory in Unknown on line 0
[Wed Apr 13 17:03:43 2016] 127.0.0.1:39822 [200]: /favicon.ico
[Wed Apr 13 17:03:43 2016] 127.0.0.1:39823 [200]: /favicon.ico
What should I do to resolve this error? I have installed mbstring library so I think it should've been able to find it.
I am using laravel 5.2.29.
EDIT:
I had uncommented the line:
extension=php_mbstring.dll
in my php.ini file which shouldn't be done if platform is UNIX. Now, when I run php artisan serve on terminal, it doesn't give any error. But when I go to localhost:8000, it says : Whoops! looks like something went wrong.
EDIT2:
Did everything according to suggestion.
Now the error is: No supported encrypter found. The cipher and / or key length are invalid.
What I have already tried:
'cipher' => 'AES-256-CBC',
php artisan key:generate
What can be done to resolve it?
Got my last problem resolved too.
The problem was that as #Bordon suggested, I had created a .env file. But when I ran the command:
php artisan key:generate
It created another file called .env.example. Now since I am a user of composer, I needed to rename it to .env (and remove the prev one).
So finally I renamed it, ran the above mentioned command again and now it works like a charm. Thanks a lot #Bordon for helping me out.
Also I would like to note that as #ash suggested, using Vagrant is quite a lot easier to me than xampp.
I want to access the Telegram-CLI using PHP.
I'm compiled Telegram-CLI and loged in to my account, and its works like a charm.
I installed LAMP ([in Linux], Apache, MySQL, PHP) and i tested them works.
I even installed these [following] PHP packages one-by-one using "Composer" and tested the examples but i couldnt make them run...
Also it seems their forum are abandoned to get my questions answer.
php-client for telegram-cli
A wrapper for Telegram-CLI
PHP Wrapper and Drupal module using Telegram CLI
Could somebody tell me how to make one of them work in simple way.
All steps of building Telegram-cli, loging in for first time and run it as deamon has beed completed.
For Example:
This project has been installed on php project root dir using "Composer".
Example.php file has been moved to web server root directory.
But also unning it cause a 500 Internal server error.
The error line is:
$telegram = new \Zyberspace\Telegram\Cli\Client('unix:///tmp/tg.sck');
notices:
The file has been checked and is already there.
And the telegram-cli is running as a daemon on root user.
I added a telegramd group and telegramd user assigned to that group.
I detacted that php commands running under apache user account.
I changed the apache user group to telegramd.
But again nothing...
So, Please help me
Edit:
I changed the httpd.conf user and group parameters to run at the same (telegramd) account
User telegramd
Group telegramd
And i have restarted the apache and checked the username by
exec('whoami');
The Apache is running under "telegramd" user account.
But nothing again..
Edit 2:
error_log file:
[Wed Feb 10 11:02:04.251133 2016] [:error] [pid 1172] [client 10.0.1.24:49168] PHP Warning: stream_socket_client(): unable to connect to unix:///tmp/tg.sck (No such file or directory) in /var/www/html/vendor/zyberspace/telegram-cli-client/lib/Zyberspace/Telegram/Cli/RawClient.php on line 48
[Wed Feb 10 11:02:04.251332 2016] [:error] [pid 1172] [client 10.0.1.24:49168] PHP Fatal error: Uncaught exception 'Zyberspace\Telegram\Cli\ClientException' with message 'Could not connect to socket "unix:///tmp/tg.sck"' in /var/www/html/vendor/zyberspace/telegram-cli-client/lib/Zyberspace/Telegram/Cli/RawClient.php:51\nStack trace:\n#0 /var/www/html/example.php(10): Zyberspace\Telegram\Cli\RawClient->__construct('unix:///tmp/tg....')\n#1 {main}\n thrown in /var/www/html/vendor/zyberspace/telegram-cli-client/lib/Zyberspace/Telegram/Cli/RawClient.php on line 51
I am trying to install pdflib9.0.2 extension for my MAMP php5.5.10. I did the following steps.
Downloaded pdflib9.0.2 from http://www.pdflib.com/download/pdflib-family/pdflib-9/copied
created a folder "pdflib" in htdocs
found the extension_dir path from php.ini /Applications/MAMP/bin/php/php5.5.10/lib/php/extensions/no-debug-non-zts-20121212
copied /Applications/MAMP/htdocs/pdflib/bind/php/php-550/php_pdflib.so to /Applications/MAMP/bin/php/php5.5.10/lib/php/extensions/no-debug-non-zts-20121212
changed the permission to rw mode.
added extension=php_pdflib.so under "Dynamic Extensions" in php.ini
commented the following in /Applications/MAMP/Library/bin/envvars
#if test "x$DYLD_LIBRARY_PATH" != "x" ; then
# DYLD_LIBRARY_PATH="/Applications/MAMP/Library/lib:$DYLD_LIBRARY_PATH"
#else
# DYLD_LIBRARY_PATH="/Applications/MAMP/Library/lib"
#fi
#export DYLD_LIBRARY_PATH****
But I could not see pdflib in my phpinfo()
I tried to access /pdflib/hello.php and I see following message in my apache error log
client denied by server configuration: /Applications/MAMP/htdocs/pdflib/.DS_Store
client denied by server configuration: /Applications/MAMP/htdocs/pdflib/bind/.DS_Store, referer: http:///pdflib/
I dont know where is going wrong.
I saw this version map in the doc. So I dont think there is a version mismatch.
bind/php/php-530 for PHP 5.3.0 and above
bind/php/php-540 for PHP 5.4.0 and above
bind/php/php-550 for PHP 5.5.0 and above
Can anyone one find out the issue here. Any input will show me a new path to solve this issue.
Thanks in advance.
I have added my Apache2 error log and php_error_log and I guess either one or both of these may be the reason for my unsuccessful installation of pdflib. If I can get some information to move forward to fix the issue, it will be very useful. Apache Error log [Tue Apr 15 11:38:22 2014] [error] [client ::1] client denied by server configuration: /Applications/MAMP/htdocs/pdflib/.DS_Store
[Tue Apr 15 11:38:24 2014] [error] [client ::1] client denied by server configuration: /Applications/MAMP/htdocs/pdflib/bind/.DS_Store, referer: http:///pdflib/ php_error_log [15-Apr-2014 11:25:08 America/Los_Angeles] PHP Warning: PHP Startup: PDFlib: Unable to initialize module
Module compiled with build ID=API20121212,TS
PHP compiled with build ID=API20121212,NTS
These options need to match
Your php_error_log tells:
php_error_log [15-Apr-2014 11:25:08 America/Los_Angeles] PHP Warning: PHP Startup: PDFlib: Unable to initialize module
Module compiled with build ID=API20121212,TS
PHP compiled with build ID=API20121212,NTS
These options need to match
This means that the PHP you are using is compiled "non thread safe", the PDFlib module you use is the "thread safe" variant. In a "non thread safe" php you can only use "non thread safe extensions. Sou you need to install the extension from the "php-550-nozts_VS11" directory of the PDFlib package.