Questions tagged [php.ini]

php.ini is the configuration file used by the PHP preprocessor to setup the default settings and certain security restrictions.

Filter by
Sorted by
Tagged with
-3 votes
1 answer
437 views

Prevent php script from overriding php.ini [duplicate]

How can I prevent php scripts from overriding max_execution_time value ? Someone found a way to inject malicious code on a server through wordpress... We are in the process of patching the ...
Phlocon's user avatar
6 votes
2 answers
35k views

Why is there no php.ini file when I install PHP in a docker container?

I'm using docker-compose to setup a minimal nginx + php-fpm application but for some reason there is no php.ini file on the docker container (I know because phpinfo() says Loaded Configuration File: (...
skb's user avatar
  • 93
0 votes
1 answer
794 views

php.ini is not read after upgrading to PHP 5.6.25 from RHSC on RHEL7 with SELinux. How to debug?

Configuration: I run a web server with RHEL7 with the SELinux kernel module and php-fpm. By default, RHEL7 ships with PHP 5.4. This version of PHP is too old for my software, so I've upgraded to PHP ...
Free Radical's user avatar
3 votes
2 answers
2k views

php session.save.path that is not from my ini file

I have set up a custom php.ini for a dev site (the production site will eventually be on the same server) - it sets the session.save path to a directory specific to the site. You can see the result ...
Richard Grevers's user avatar
3 votes
1 answer
14k views

Changing session.save_path in php.ini not working

Fedora 25 + PHP 7 + Apache 2.4.23 Hello, after I change session.save_path in php.ini and restart apache, I can successfully verify that it's modified with: $ php -i | grep session.save_path However,...
synkro's user avatar
  • 233
0 votes
1 answer
912 views

How to use PHP memcached for session storage with Auto Scaling?

I already have memcached installed in my servers and I've modified the default php.ini to: session.save_handler = memcached session.save_path = "127.0.0.1:11211" I'm using Amazon EC2 instances (...
Igor's user avatar
  • 135
6 votes
1 answer
5k views

Stop reusing PHP_VALUE for different sites with PHP-FPM

I noticed the following behavior or PHP-FPM: Take a look at these two Nginx configs: server { listen 80; server_name example.com; location / { fastcgi_pass 127.0.0.1:...
Oleg's user avatar
  • 286
0 votes
1 answer
308 views

Unicode characters in my PHP configuration

Earlier today I was having an issue where I couldn't setup my PHP7 remote interpreter on PhpStorm I ended up finding out that I have unicode characters in my PHP configuration: I have no idea how ...
Raph Petrini's user avatar
0 votes
1 answer
582 views

Determinate witch Php cache system is currently used

How can i find what php cache system is used by my server (APC/opcache/Zend...) ? If I run this command line, i've no information : php -v PHP 5.4.45-0+deb7u5 (cli) (built: Aug 30 2016 20:15:34) ...
NicoMinsk's user avatar
  • 125
0 votes
1 answer
3k views

pgsql is not loading (centOS 6.8)

*First of all don't answer "php.ini >> uncomment extension=pgsql.so and restart httpd". did that millions of times, did not solve my problem. *Tried hundreds of methods described in different sites ...
MD TAREQ HASSAN's user avatar
0 votes
1 answer
3k views

Adding multiple extensions to PHP.INI

I have two extensions I want to add. Do I add these separately like: extension=php_ftp.dll extension=php_openssl.dll Or are they added like an array? extension=php_ftp.dll,php_openssl.dll
Daniel Williams's user avatar
11 votes
2 answers
7k views

How can I create separate configuration files for php (cli) and php-fpm on an arch linux

Is it possible to create separate php.ini files for php (cli) and php-fpm, like it is possible on debian and ubuntu with two folders /etc/php/7.0/cli and /etc/php/7.0/fpm? I will be also cool if I ...
Fiete's user avatar
  • 331
0 votes
1 answer
6k views

Yet another request entity too large issue, Apache

When I try to upload any kind of file to my server/website I get an Request Entity Too Large error. (Trying to upload a 1.73mb picture produces a 413 error while a 25.6kb picture does not) I tried ...
PhysiOS's user avatar
  • 432
0 votes
1 answer
100 views

What is using php_error.log in /var/log on my Nginx server

On my Nginx server in /var/log there is php5-fpm.log and php_error.log The php_error.log has all kind of notices so that it's size grows to hundreds of Mb's. I tried to find which php.ini managed this ...
C.A. Vuyk's user avatar
  • 632
0 votes
1 answer
4k views

php.ini exists but is not loaded

I know this gets asked a lot here but I've done my homework and cant seem to solve my particular problem. It doesn't seem like my php.ini file is being loaded, even though php -i and php --ini say it ...
Michael's user avatar
  • 105
-1 votes
1 answer
9k views

How can I change the path of my php.ini conf?

A few days ago, I compiled PHP 5.5 from sources and installed it on my Debian 8.5 server but I got some issues. I decided to remove it and re-install PHP through package. But I still got issues ...
kevin-ta's user avatar
4 votes
3 answers
4k views

php 7 ignores ini files, but claims to load

Ubuntu 16.04, Lighty 1.4.35, PHP 7.0.4-7ubuntu2 (in a Hyper-V VM) I browsed all (or at least many) of the other questions about php.ini. No matter what value I set for any of the directives; ini_get ...
Titus's user avatar
  • 261
-2 votes
1 answer
190 views

Apache Extended Logs of php files

I am using apache and I want to log each php or any script file with its location which runs for more than 30 seconds or so. I tried to find solutions extensively, but no luck has come true. Is this ...
Hashmi's user avatar
  • 143
3 votes
1 answer
14k views

php.ini not being loaded [closed]

I have been trying to configure my Apache server all day, however I am having major issues with getting a php.ini file to be loaded. When I try to connect to my database I get this error: Call to ...
Lain's user avatar
  • 131
0 votes
1 answer
184 views

How to override the previous defined PHP value via Ansible PHP role?

I'm trying to apply override PHP's opcache.max_accelerated_files setting via geerlingguy's Ansible Role for PHP onto geerlingguy/centos6's VM using the following lines (as part of provisioning script):...
kenorb's user avatar
  • 6,777
0 votes
1 answer
1k views

nginx seems to use wrong php service

i wanted to increase my max. upload file size and install cURL to php5-fpm today. I have installed a LAMP stack on my Ubuntu 14.04. But the changes doesn't take any effect after reloading/restarting ...
nipeco's user avatar
  • 101
0 votes
1 answer
2k views

Cloudlinux + CageFS + PHP Selector - how to update default php.ini for each PHP version or for each domain account? [closed]

My server runs Cloudlinux 5.11 with CageFS and PHP Selector. Default PHP version is 5.3. I have one account using PHP 5.3, one account using PHP 5.5, and one account using PHP 5.6. I'm trying to ...
Shawn's user avatar
  • 101
0 votes
2 answers
2k views

Installing libevent extension for php on Centos

How to install the libevent extension for php on Centos 7? I spent many many hours trying this, googling many times and really really struggled, so I'm going to document my own answer to this in the ...
Jonathan Clark's user avatar
2 votes
3 answers
1k views

How can I get my mediawiki to stop thinking I have cookies disabled?

I've searched half a day for how to resolve this issue, and can't figure it out. Shortly after I made my wiki a simple private wiki according to the instructions at Mediawiki's website, it started ...
PakG1's user avatar
  • 31
0 votes
1 answer
2k views

Configure Linux and PHP to send email via script instead of SMTP

I have a server with a static IP and also a domain pointing to it. Because it is behind a firewall that blocks SMTP (ingoing and outgoing), I am not able to send any EMail from it. To be able to send ...
paolo's user avatar
  • 397
0 votes
1 answer
136 views

Php can't find hash function

I'm using apache with php on amazon linux. I've updated php from 5.3 to 5.5 and apache from 2.2 to 2.4. Now calling echo hash('sha256','wtf'); is behaving in a strange way. It works for a while and ...
clorz's user avatar
  • 279
-3 votes
2 answers
134 views

Server not recognizing that wget is installed on OS X Yosemite [closed]

I'm trying to install some software (called Prohits, used for mass spectrometry data management) on a localhost server I set up. One of the requirements for the install is that I have wget installed. ...
covfefe's user avatar
  • 113
0 votes
1 answer
671 views

Can you set multiple mbstring.language in php.ini?

Can I set multiple mbstring.language in php.ini for multi-language websites? Or I have to set only one. mbstring.language = English mbstring.language = Japanese mbstring.language = Korean
shin's user avatar
  • 333
1 vote
2 answers
2k views

413 - request entity too large in lighthttpd

When saving configuration settings in Magento I get "413 - request entity too large". We are running lighttpd. In php.ini memory_limit = -1 In lighttpd.conf server.max-request-size = 1000000 I have ...
Andreas's user avatar
  • 11
0 votes
1 answer
663 views

Get PHP extension APC not running on Ubuntu 14.04.3 - undefined symbol: php_pcre_exec

I installed the PHP extension APC on the server but I get it not running. It gets not listed in phpinfo(). After activating the php error log I get the following error: PHP Startup: Unable to load ...
megloff's user avatar
  • 413
2 votes
2 answers
6k views

How to disable PHP mail function on one apache virtualhost?

I want to disable PHP function mail via Apache2 virtual host configuration file. I want to do it for one virtual host, not for all virtual hosts, and I don't want disable this function in php.ini How ...
darkw1nd's user avatar
  • 137
1 vote
1 answer
2k views

php/php-fpm can't find php.ini

I'm having an issue where php and php-fpm can't find php.ini. I installed 5.6.13 from source. The question PHP doesn't load php.ini is very similar but the solutions there haven't helped me. ...
DrBojingle's user avatar
1 vote
1 answer
3k views

php open_basedir not working as expected on synology nas

I'm trying to install gitlist on my synology NAS (DSM 5.2). I downloaded and configured gitlist in config.ini and pointed it to my repositories folder (/var/services/homes/git/repo). But when I try ...
Joan's user avatar
  • 11
-1 votes
1 answer
389 views

php.ini 500 error when register_globals = On

i am using PHP Version 5.4.44 and have a setting in my php.ini as register_globals = Off i am trying to set it as register_globals = On but it is not working and through me an error as 500 please ...
Tufail's user avatar
  • 1
0 votes
0 answers
1k views

E: Unable to locate package php5-apcu

trying to install APCu on Ubuntu: apt-get install php5-apcu Getting an error: E: Unable to locate package php5-apcu Following someone's suggestion I added: deb http://packages.dotdeb.org wheezy-...
VladaP's user avatar
  • 1
0 votes
0 answers
1k views

php.d/*.ini files loading for root but not other users (CLI)

Using PHP from the commandline, as root, everything in the php.d/ directory is loaded as expected: root@tlsv2-eepweb-01:/home/web>php --ini Configuration File (php.ini) Path: /etc Loaded ...
Harry Slaughter's user avatar
0 votes
1 answer
2k views

centos 6.6, sh: zip: command not found [closed]

Centos 6.6 64bit on OpenVZ VPS. I tried a phpinfo.php file using only the following code: <?php var_dump( exec('zip -r domains.zip "domains"') ); // phpinfo(); ?> . The php error log is now: ...
Cazzette's user avatar
5 votes
1 answer
4k views

Reverting PHP-CLI back to default path on Ubuntu, NGINX, HHVM

While experimenting with optimizations on my brand new LEMH (Linux, Nginx, MariaDB, HHVM) stack; I changed the PHP-CLI config to use HHVM for /usr/bin/php by using the following command: $ sudo /...
Perp1exed's user avatar
1 vote
1 answer
606 views

PHP timeout is zero and memory limit is 1024M and script timeout?

on my work server i set PHP settings to be 1024M memory limit and max execution time to zero after all this the script still timeout !! what are other options to make script runs forever if i want ...
Macnux's user avatar
  • 149
0 votes
1 answer
2k views

Do I require setting the full path to files in php.ini?

I have "merged" php with apache bin directory, however for years I have been hardcoding the path to files as follows : curl.cainfo = d:/server/bin/cacert.pem - browscap = d:/server/bin/browscap.ini ...
Kraang Prime's user avatar
-3 votes
1 answer
2k views

PHP Fatal error: Call to undefined function mysql_pconnect() [closed]

I'm Having same Problem. PHP Fatal error: Call to undefined function mysql_pconnect() in I gone through PHP Fatal error: Call to undefined function mysql_pconnect() in. i have same problem. but ...
Ningappa's user avatar
  • 111
1 vote
0 answers
223 views

Possible have 2 php.ini file or 2 extension_dir in php.ini?

i got Fatal error: Class 'mysqli' not found in C:\apache2triad\htdocs\index.php on line 8 error. I checked php.ini file and saw extension=php_mysql.dll is uncommented.Everything is normal. But in php....
Joe People's user avatar
0 votes
2 answers
3k views

iis 7.5 laravel 3.2 app log failed to open stream: Permission denied

I've been given a Laravel 3.2 app that is working on production to move over to an IIS 7.5 server. I've set the production php.ini so that it works with 5.4.37 and can't get past a 500 error so that I ...
sam452's user avatar
  • 269
0 votes
1 answer
66 views

changing max upload limit doesn't affect

A drupal website i run gets an error that says the php limit is 2Mb. i changed it to 10 from /etc/php5/apache2/php.ini. This doesn't make any change (im using a phpinfo to look if any change to ...
Arun Anson's user avatar
0 votes
2 answers
10k views

PHP session handler using redis not work

I was sets 3 servers : 192.168.7.147:6379 <-- redis server 192.168.7.162 <-- web server 1 (using phpredis, with local devdomain jttest.com ) 192.168.7.218 <-- web server 1 (using phpredis, ...
Lezir Opav's user avatar
-1 votes
1 answer
762 views

Accidently removed all PHP dynamic libraries [closed]

I was trying to remove a startup module folder(ioncube) and accidently removed the PHP startup modules/extensions folder (debian) Now I'm getting this PHP Warning: PHP Startup: Unable to load ...
Osa's user avatar
  • 131
3 votes
1 answer
6k views

How can I specify which php.ini file to use in my nginx conf file?

I'm running 2 PHP sites on the same server. I would like to use 2 different php.ini files for them. I've googled this issue with no luck. Here is what my php location looks like: location ~ \.php$ { ...
Aust's user avatar
  • 161
1 vote
1 answer
2k views

How to generate a php.ini file out of current environment? [closed]

For some of my running PHP-FPM web applications, I need to set up cronjobs. Currently they are using the CLI default php.ini. Is there an easy way (e.g. script) to generate a new php.ini from the ...
burnersk's user avatar
  • 2,096
0 votes
1 answer
150 views

WHM - php.ini in public_html stops default php.ini [closed]

I have a server with WHM panel. OS is CentOS. When I put a php.ini in public_html PHP stops reading /usr/local/lib/php.ini. When I compare results of phpinfo() what I see is; error_log error_log ...
borayeris's user avatar
  • 213
0 votes
1 answer
1k views

Enable curl_exec() in a sub-folder

Curl is enabled on the server but curl_exec function is disabled for security reasons. disable_functions = exec,passthru,shell_exec,system,proc_open,popen, curl_exec,curl_multi_exec,parse_ini_file,...
vv_vv's user avatar
  • 105