how to fix Out of memory in wordpress - wordpress

I experience a problem with memory limit in wordpress :
When I try to uplod an image, the site crashes and I find that in the logs :
[31-Oct-2020 16:28:45 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 65536 bytes) in /var/www/webroot/ROOT/wp-content/plugins/jetpack/class.jetpack-plan.php on line 233
[31-Oct-2020 16:28:45 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 65536 bytes) in /var/www/webroot/ROOT/wp-content/plugins/woocommerce/includes/admin/class-wc-admin-settings.php on line 54
[31-Oct-2020 16:28:45 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 65536 bytes) in /var/www/webroot/ROOT/wp-content/plugins/jetpack/class.jetpack-plan.php on line 233
[31-Oct-2020 16:28:52 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 20480 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/mo.php on line 323
[31-Oct-2020 16:28:52 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 135168 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/streams.php on line 118
[31-Oct-2020 16:28:57 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 4096 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/mo.php on line 315
[31-Oct-2020 16:28:57 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 135168 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/streams.php on line 118
[31-Oct-2020 16:28:59 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 20480 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/mo.php on line 323
[31-Oct-2020 16:28:59 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 135168 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/streams.php on line 118
[31-Oct-2020 16:29:04 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 20480 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/mo.php on line 323
[31-Oct-2020 16:29:04 UTC] PHP Fatal error: Out of memory (allocated 2097152) (tried to allocate 135168 bytes) in /var/www/webroot/ROOT/wp-includes/pomo/streams.php on line 118
I've put 1024 as max memory in php.ini, in .htaccess and wp-config. php info says that there is 1024 mb in max memory usage but the problem persists.
What can I do to fix that?

Related

I am running into this error when attempting to create an XLSX in RStudio

install.packages("xlsx")
trying URL 'https://cran.rstudio.com/bin/macosx/contrib/4.2/xlsx_0.6.5.tgz'
Content type 'application/x-gzip' length 370371 bytes (361 KB)
==================================================
downloaded 361 KB
The downloaded binary packages are in
/var/folders/0g/h70b_3hx4hn10c2hybzy_4l40000gp/T//RtmpzUFLGT/downloaded_packages
library("xlsx")
The operation couldn’t be completed. Unable to locate a Java Runtime.
Please visit http://www.java.com for information on installing Java.
Error: package or namespace load failed for ‘xlsx’:
.onLoad failed in loadNamespace() for 'rJava', details:
call: fun(libname, pkgname)
error: JVM could not be found
In addition: Warning messages:
1: In system("/usr/libexec/java_home", intern = TRUE) :
running command '/usr/libexec/java_home' had status 1
2: In fun(libname, pkgname) :
Cannot find JVM library 'NA/lib/server/libjvm.dylib'
Install Java and/or check JAVA_HOME (if in doubt, do NOT set it, it will be detected)
write.xlsx(start_no_data)
Error in write.xlsx(start_no_data) : could not find function "write.xlsx"
uhh so apparently I needed to actually download Java first!!

Installing TensorRT gives "Packages File not found" error

While installing TensorRT, the below error occurred. I have already installed cuda 9.0 and cudnn 7.0.5. How do I avoid this error?
Err:5 file:/var/cuda-repo-9-0-local Packages File not found - /var/cuda-repo-9-0-local/Packages (2: No such file or directory)

Linux locale? R Error: object 'en' not found

Whenever I start R (from the terminal), I get:
Error: object 'en' not found
This causes all kinds of problems, most notably that I cannot install packages:
> install.packages("rmarkdown")
Installing package into ‘/home/eric/R/x86_64-pc-linux-gnu-library/3.4’
(as ‘lib’ is unspecified)
also installing the dependencies ‘backports’, ‘htmltools’, ‘base64enc’, ‘rprojroot’
trying URL 'https://ftp.cixug.es/CRAN/src/contrib/backports_1.1.2.tar.gz'
Content type 'application/x-gzip' length 10900 bytes (10 KB)
==================================================
downloaded 10 KB
trying URL 'https://ftp.cixug.es/CRAN/src/contrib/htmltools_0.3.6.tar.gz'
Content type 'application/x-gzip' length 45408 bytes (44 KB)
==================================================
downloaded 44 KB
trying URL 'https://ftp.cixug.es/CRAN/src/contrib/base64enc_0.1-3.tar.gz'
Content type 'application/x-gzip' length 7833 bytes
==================================================
downloaded 7833 bytes
trying URL 'https://ftp.cixug.es/CRAN/src/contrib/rprojroot_1.3-2.tar.gz'
Content type 'application/x-gzip' length 50414 bytes (49 KB)
==================================================
downloaded 49 KB
trying URL 'https://ftp.cixug.es/CRAN/src/contrib/rmarkdown_1.8.tar.gz'
Content type 'application/x-gzip' length 2093181 bytes (2.0 MB)
==================================================
downloaded 2.0 MB
Error: object 'en' not found
Execution halted
Error: object 'en' not found
Execution halted
Error: object 'en' not found
Execution halted
Error: object 'en' not found
Execution halted
Error: object 'en' not found
Execution halted
The downloaded source packages are in
‘/tmp/RtmpjxEc33/downloaded_packages’
Warning messages:
1: In install.packages("rmarkdown") :
installation of package ‘backports’ had non-zero exit status
2: In install.packages("rmarkdown") :
installation of package ‘htmltools’ had non-zero exit status
3: In install.packages("rmarkdown") :
installation of package ‘base64enc’ had non-zero exit status
4: In install.packages("rmarkdown") :
installation of package ‘rprojroot’ had non-zero exit status
5: In install.packages("rmarkdown") :
installation of package ‘rmarkdown’ had non-zero exit status
Edit: I initially thought that this could be a problem related to locale, but as per comments below, I had a look at the Rprofile.site and Renviron.site files. The
Error: object 'en' not found
was caused by "language = en" inserted into the Rprofile.site-file. It should have been in the Renviron.site-file instead. See also this post about locale issues in the console.
Thanks to the comments, it is clear that the
Error: object 'en' not found
was caused by "language = en" inserted into the Rprofile.site-file instead of in the Renviron.site-file instead. See also this post about locale issues in the console.

Install R packages on Ubuntu error

I have R and Rstudio installed on an Ubuntu server (14), when I tried to install packages, I get these errors:
>install.packages("nnet")
Installing package into ‘/home/zhge/R/x86_64-pc-linux-gnu-library/3.0’
(as ‘lib’ is unspecified)
--2015-09-08 02:43:31-- https://cran.rstudio.com/src/contrib/nnet_7.3-11.tar.gz Resolving
cran.rstudio.com (cran.rstudio.com)... 54.230.140.42 Connecting to
cran.rstudio.com (cran.rstudio.com)|54.230.140.42|:443... connected.
HTTP request sent, awaiting response... 200 OK Length: 28455 (28K)
[application/x-gzip] Saving to:
‘/tmp/RtmpBT7yHE/downloaded_packages/nnet_7.3-11.tar.gz’
0K .......... .......... ....... 100% 1.20M=0.02s
2015-09-08 02:43:31 (1.20 MB/s) -
‘/tmp/RtmpBT7yHE/downloaded_packages/nnet_7.3-11.tar.gz’ saved
[28455/28455]
/usr/lib/R/bin/R: line 140: /usr/lib/R/etc/ldpaths: Permission denied
/usr/lib/R/bin/R: line 236: /usr/lib/R/etc/ldpaths: Permission denied
Error in file(con, "r") : cannot open the connection Calls:
<Anonymous> -> sub -> grep -> readLines -> file In addition: Warning
message: In file(con, "r") : cannot open file
'/usr/lib/R/etc/Makeconf': Permission denied Warning in
install.packages : installation of package ‘nnet’ had non-zero exit
status
The downloaded source packages are in
‘/tmp/RtmpBT7yHE/downloaded_packages’
UPDATE:
It was just permission issue, all i needed is just:
$ sudo chmod -R 0777 /usr/lib/R/etc/ldpaths
and for the other directories: /usr/lib/R/etc/Makeconf and /usr/lib/R/bin/. I never had this issue before, so it didn't come to me as the problem immediately.

Error: memory exhausted (limit reached?)

Does any one know how to resolve this error ? I am using R in macbook pro.
I am using a clustering package calld rsgcc
thm <- gcc.tsheatmap(b[2:5264,], cpus = 1, cormethod = "GCC", distancemethod = "Raw", clustermethod = "complete")
Dimension information for clustered GE matrix: 5263 9
R(18015,0xac5c3a28) malloc: *** mmap(size=16777216) failed (error code=12)
*** error: can't allocate region
*** set a breakpoint in malloc_error_break to debug
R(18015,0xac5c3a28) malloc: *** mmap(size=16777216) failed (error code=12)
*** error: can't allocate region
*** set a breakpoint in malloc_error_break to debug
R(18015,0xac5c3a28) malloc: *** mmap(size=16777216) failed (error code=12)
*** error: can't allocate region
*** set a breakpoint in malloc_error_break to debug
Error: memory exhausted (limit reached?)
My session Info is
> sessionInfo()
R version 2.15.2 (2012-10-26)
Platform: i386-apple-darwin9.8.0/i386 (32-bit)
locale:
[1] C/UTF-8/C/C/C/C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
Like #arun commented, you need to start using 64 bit R to be able to use the full potential of the 16 gigabytes o of RAM you have. Right now, R can use about 3 gb...

Resources