PHP Post Max Size for selected site

tarta

Verified User
Joined
Jan 31, 2018
Messages
83
Hi,
One of the WordPress sites running on VPS requires setting up PHP Post Max Size to 256M.

Questions:
1) can I set the value for this site only?
2) where can I change beyond 128M limit available in PHP settings:
Zrzut ekranu 2024-02-19 115528.png


Regards
 

Attachments

  • 1708340190068.png
    1708340190068.png
    30.8 KB · Views: 61
You have to manually adjust the php.ini file for that version of php you are running on that site.

Example: /usr/local/php73/lib/php.ini
 
1) ok, ini updated
post_max_size = 256M

2) php-fpm80 restarted (via DA panel)

3) yet, it still shows me 128M which must be coming from a global override that I need for other settings.

1708343054444.png



4) should I need set 256M for each ini separately? Is there a way to add 256M value for global drop-downs?

1708343141761.png
 
I don't know. I have never used that form. But yes you do have to edit for each version of php.
 
Where do you find that form, I would have used

User>Account Manager>PHP Settings

I dont think I've ever seen that form before.
 
create dir if not exist: /usr/local/directadmin/data/templates/custom/
copy /usr/local/directadmin/data/templates/php_settings.json to this dir
modify/extend range for needed parameters
19-02-2024 14-21-37.jpg
 
you can also change ranges to list of values:

Example: change range from

"max_input_vars" : {
"default" : 10000,
"type": "int",
"range" : [ 1, 100000 ]
},

to a list of values:

"max_input_vars" : {
"default" : 10000,
"type": "list",
"values" : [
"8000",
"12000",
"16000",
"20000",
] },
 
1) ok, ini updated
post_max_size = 256M

2) php-fpm80 restarted (via DA panel)

3) yet, it still shows me 128M which must be coming from a global override that I need for other settings.

View attachment 7708


4) should I need set 256M for each ini separately? Is there a way to add 256M value for global drop-downs?

View attachment 7709

Please try to rebuild PHP
Code:
cd /usr/local/directadmin/custombuild
da build php
da build rewrite_confs
 
#note: For php-fpm, that's form is global config for the user.

if you want per-site setting, just create file at your domain site.

#domain.com/public_html/.user.ini
Code:
post_max_size = 256M

I don't know if you already have setting in that's form, maybe ".user.ini' won't work anymore.
 
Back
Top