• Home
  • WordPress
  • web Hosting
    • Free hosting
    • Cheap Hosting
    • comparison cloud , vps, shared, wordpress
    • managed wordpress hosting
    • managed cloud hosting
  • page Speed
  • Deals
  • Services
  • About

RAaz Kumar .com

wordpress tutorials seo hosting etc


how to increase wordpress memory & file upload size

Q.where is php.ini file location wordpress?

Answer; located at same directory where your WordPress installed.

Allowed memory formats 32, 64, 128, 256, 512, 1024M or more in Mbs only not in GBs or G for a WordPress website.

Make sure to check your webmaster allocated memory, In shared hosting default, will be 1024Mb for your account but some shared hosting servers provide 512MB also 256 based on the quality of hosting.

How to check Allocated memory for a WordPress website /install?

generally, we can check server status by .php.info file available at official PHP website. but this may check all server info.
for my case newspaper theme suggested to change the memory and I increased 48MB to 256M to (before this I am getting 503 services limited reached error on 1and 1 hosting).
So I want to increase all of my WordPress install located different servers.
so all I need to know how to check WordPress allocated memory, and after configuring the extra memory to WordPress is there any change or not.
may be a plugin help this. also, WordPress is rich of plugins. if plugins not available then I have to use only newspaper theme.
don’t worry I will update it soon after I tested.
I have found the solution:
just create phpinfo.php

add this code ”

<?php

// Show all information, defaults to INFO_ALL
phpinfo();

 

?>
“
upload to server, and access
yourwebsite.com/phpinfo.php
and press CTRL+ F search for Memory
you can find memory limit: mine is tested install another shared hosting server is 128M
and there is other 2 WordPress installation in the same directory, I have to check both too.
I have checked the previous which I set 256M memory, that hosting provided allocated memory is 62914560 (may be in KB) 62914 Mbs or 62.3GB memory. I have to test it.
I have edited wp-config and added 62914M and I got 61GB in the request through newspaper system status.
that’s it we have to go for another servers
48M-256 to 61GB memory another server (but same problem facing 503 error resources limit reached for login.php I don’t know with web page  maybe with PHP max execution time limit)
Shared Server 2
1st install 120M in shared hosting account
2nd add-on website directory memory limit is 32M
3rd  32M
4th 32M
so I have to check this from root directory users name of shared account.
but this is not accessible because only documents in public/HTML folder can access them.
Now I need to increase limit through wp-config, I have added it up to 256M but not increase still 128M only,
also decreased to 64 but it still 128M in the main directory, so let me go to the subdirectory I will change 32 to 64M, no change I will ignore that server,
Next GoDaddy managed 
Deluxe  128M for wp install No change after configuring to 256M no change also after decreasing the memory so host allocated memory is 128M, let us go to starter plan
Starter:  128M no change after increasing/decreasing the memory.
Just test another provider: limit by default set to 128M no change after adding the memory.
But installed newspaper theme that showing 256MB as request I have to check further, increased 1024MB showing 1 GB, I have increased up to 4Tb
theme showing 4Tb request ok what about performance,
and their actual memory on server.for a shared they may use up to 20GB Memory and 4 CPUs for 150-300 shared accounts, 150*5=750 websites.
and they allocated 1 GB virtual memory to my account.
60GB memory server max execution time is 30 others are 120Seconds.
I have installed Server IP & Memory Usage Display plugin which display memory usage of WordPress and allocated memory with Ip address in admin footer.
That displaying Memory: 24.45 of 62914560 MB (0%) | WP LIMIT: 61 GB (wp config php added)| IP …… | PHP 7.0.0 @32BitOS
Actually allocated memory in that directory 63GB then all of the memory using by me. After updating that my WordPress website getting very fast..
I m lucky that hosting provider.
I have installed change memory limit plugin on another server which they allocated only 32MB Memory, default is is 40MB
I have changed memory limit using plugin, but that worked because host provider limited that only.
I have to contact them.
contacted and the chat support increased immediately by editing php.ni and .htaccess in shared server root account PHP.ni located home/username/PHP.ni
/home/username/public_html/.htaccess
now my memory is
268435456 MB  268435 GB y plugin and 128 before after 256M now by PHP info file
Shared server 2
 Memory: 26.46 of 4445096 MB (0%) | WP LIMIT: 4 TB
but phpinfo.php displaying 128M
 Godaddy managed wordpress starter plan 
11.06 of 128 MB (9%) | WP LIMIT: 40 MB
After i increasing the 40MB to 1024M igot this results  Memory: 10.89 of 1024 MB (1%) | WP LIMIT: 1 GB | phpinfo file 128M only.
Godaddy managed deluxe  Memory: 14.65 of 268435456 MB (0%) | WP LIMIT: 256 MB (limit set of by me otherwise it will be 40MB
After increasing the wp-config to 2048 M results is Memory: 14.41 of 2048 MB (1%) | WP LIMIT: 2 GB PHP info file results remains same as 128M.
we only have to trust PHP info results only.
All of my websites memory usage is 25MB Average,
How much a WordPress website Memory cnsumes?
32M to 48 94M 12
define( ‘WP_MEMORY_LIMIT’, ’96M’ );
define( ‘WP_MEMORY_LIMIT’, ‘256M’ );
define( ‘WP_MEMORY_LIMIT’, ‘1024M’ );
define( ‘WP_MEMORY_LIMIT’, ‘2048M’ );
/* That’s all, stop editing! Happy blogging. */
Setting max exectuion time & variable
edit php.ini in WordPress directory and add this

 increase wordpress memory & file upload size with php.ini

max_input_vars = 5000
max_execution_time = 300
memory_limit = 64M
post_max_size = 50M  (fie size 50Mb i doneed i except this)
suhosin.request.max_vars = 5000
suhosin.post.max_vars = 5000
Added to php.ini not worked, so I have to use Htacess.
Suhosin not installed so I can’t modify the Suhosin settings
.htacess
php_value max_input_vars 5000
php_value max_execution_time 300
php_value post_max_size 50M
php_value suhosin.post.max_vars 5000
php_value suhosin.request.max_vars 5000

 increase WordPress memory limit & file upload size  through .htaccess

<IfModule mod_php5.c>
php_value post_max_size 5M
php_value upload_max_filesize 5M
php_value memory_limit 128M
php_value max_execution_time 300
php_value max_input_time 300
php_value session.gc_maxlifetime 1200
</IfModule>
<IfModule mod_php5.c>
php_value max_execution_time 300
php_value max_input_vars 5000
</IfModule>
not worked, so i go for plugin
https://wordpress.org/plugins/wp-maximum-execution-time-exceeded/
installed the plugin but no change but that below code to .htacess
# WP Maximum Execution Time Exceeded
    <IfModule mod_php5.c>
        php_value max_execution_time 300
    </IfModule>
in my phpni kisted below.
safe_mode=false;
upload_max_filesize=41943040;
post_max_size=52428800;
max_input_vars = 5000;
max_execution_time = 300;
memory_limit=62914560;
extension_dir=/usr/lib/php7.0/extensions;
zend_extension=/usr/lib/php7.0/extensions/opcache.so;
opcache.enable=1;
opcache.memory_consumption=32;
opcache.interned_strings_buffer=8;
opcache.max_accelerated_files=3000;
opcache.revalidate_freq=180;
opcache.fast_shutdown=0;
opcache.enable_cli=0;
opcache.revalidate_path=0;
opcache.validate_timestamps=2;
opcache.max_file_size=0;
opcache.file_cache=/kunden/homepages/28/d605205351/htdocs/.opcache;
opcache.file_cache_only=1;
Increasing file Size upload limit
in hosting raja there is 2 MB max file upload. I have tried htaccess and php.ni nothing changed. php.ni configuration file is loaded from their main server. we can see in phpinfo.php
asked the support and they increased upto 64MB. also increased memory limit from 128M to 386M.
Conclusion: This a Brainstorm of me while increasing the WordPress PHP memory limit. So I have added here to help others who are in the same situation. Make sure to check my next post about shared server resource limits by company,

Related topics:

  1. OPcache enable / configuration settings for wordpress nginx php-fpm ubuntu (How to enable)
  2. redis install ubuntu 20.04 with wordpress php redis mysql configuration
  3. change wordpress site url
  4. Perfect robots.txt file for WordPress, blogger [Rules explained]
  5. improve mysql performance wordpress my.cnf file configuration

wordpress tutorials for beginners advanced complete guide to run WordPress

  • Rules to get 100/100 in Google pagespeed web core vitalsscore
  • How to add adsense amp ads to wordpress
  • wordpress password reset in 3 ways mail, phpmyadmin, mysql command
  • how i recovered hacked website site 5 times ft wordpress?
  • enable browser caching in wordpress apache nginx caching headers explained
  • W3TC w3 total cache plugin setup guide review comparison with wp rocket and wp super cache
  • Wordpress database optimization (don't neglect) plugins & phpmyadmin manually
  • Optimize css delivery inline critical css, remove unused css, render blocking css
  • Converting WordPress into static website speed after 1 second dynamic 3 seconds
  • Wordpress errors and fix
  • website cache best caching plugins wordpress w3tc cloudflare
  • Install xamp & wordpress on localhost windows
  • favicon ico Change / Add / Disable favicon in wordpress Ft Genesis Theme or any theme
  • increase wordpress memory limit (how to ) 40MB , 64 MB 128 MB or 512 MB maybe 1024MB
  • wp cron job check working or not disable enable change schedule
  • google analytics plugins for wordpress #sitekit #monsterinsights gadwp back as gainwp
  • Lazy Load Adsense to improve core web vitals - Vs revenue
  • xmlrpc php wordpress uses, disable without 403 error log message
  • wordpress change post date programmatically (auto on update like blogger
  • wordpress plugins that slow down your site and its alternatives
  • best wordpress plugins social, seo, Backup, speed up your blog
  • TOP 10 Wordpress Themes Premium/ Free & providers
  • Wordpress Adsense Plugins & Manually
  • Social share buttons for website Wordpress Blogger
  • How to bulk delete in wordpress posts, pages, Media Images, tags and categories
  • TOP 5 Best wordpress comment plugins 2020 (disable pingback, replytocom, customize form)
  • all in one seo pack vs yoast seo pressor
  • Auto post to Facebook, twitter, Google Plus Wordpress Posts 2019
  • wordpress speed optimization Speed up wordpress Score on Google pagespeed
  • How to use wordpress tags and categories
  • Wordpress duplicate thin content Issues {FIXED}
  • how to increase wordpress memory & file upload size
  • combine rss feeds wordpress
  • Reduce the impact of third-party code ,optimize JS delivery, Minify, remove unused js, pre connect, inline, lazy load etc
  • change wordpress site url
  • install wordpress on ubuntu apache nginx debian command line
  • Wordpress Security Plugins 2021 (Brute force, Login lockdown, Malware scanner etc)

 

 

wordpress Pagespeed optimization

Digitalocean free $100 Credit

Cloudways Review pricing promo codes

Siteground cpu limits Pricing

Shared Hosting

Managed wordpress Hosting

Managed Hosting Cloud server

VPS Hosting

Cloud Hosting – Unmanaged

Google cloud Pricing

Aws Pricing

Azure pricing

nginx server tutorials

apache server tutorials

linux sysadmin tutorials

mysql Commands list pdf

LEMP Install Ubuntu

Mysql Performance Tuning

Nginx Performance tuning

Linux Performance tuning

Php -fpm performance tuning

Redis Performance tuning

linux server security

nginx security best practices

wordpress security plugins

 

 

wordpress

 

Top 5  WP Google Analytics Plugins

WP Backup Plugins

Wp Comment Plugins

Top wordpress Security Plugins

WP Seo Plugins

WP Caching Plugins

Best Adsense Plugins for WordPress

Wp social Sharing Plugins

autoshare social media plugins

WP speed Optimization Plugins

Speedup WordPress google Score

More Wp tuts

Server Admin Cloud

 

Installing Nginx LEMP On ubuntu

Installing apache Lamp ubuntu

nginx fastcgi cache enable

php – fpm install  & Configuration

Opcache install & Configure

php -fpm pool manager explained

Mysql Install & Configuration

Redis Object cache install & configure

 

Nginx as Reverse Proxy and Load balancer

Load Balance / auto scaling in google cloud

Linux Commands PDF

Mysql Commands Pdf

Letsencrypt tutorial

mysqldump export & import 

Pagespeed Module install & configure

nginx.conf best file

mysql.conf best file

upgrade ubuntu

© 2023 - All Rights Reserved Disclaimer & Privacy Policy