Hello @halshak
Please run ulimit -n unlimited
and then run the cp command again:
cp -a /www/kinsta/public/mylivesite/. /www/kinsta/public/mystagingsite
Let me know what the output is.
Kind regards
Hello @halshak
Please run ulimit -n unlimited
and then run the cp command again:
cp -a /www/kinsta/public/mylivesite/. /www/kinsta/public/mystagingsite
Let me know what the output is.
Kind regards
Looks like I’m not allowed to do that.
/bin/sh: 1: ulimit: error setting limit (Operation not permitted)
Hello again @halshak
I could replicate the same on my end (inside the devkinsta_fpm
docker’s container) even when using root
user:
root@f8942fc6e365:/www/kinsta/public# ulimit -n
1048576
root@f8942fc6e365:/www/kinsta/public# ulimit -n unlimited
bash: ulimit: open files: cannot modify limit: Operation not permitted
though as I could see, both Hard Limit and Soft limit have been set to “unlimited” already for ulimit :
root@f8942fc6e365:/www/kinsta/public# ulimit -H
unlimited
root@f8942fc6e365:/www/kinsta/public# ulimit -S
unlimited
I also tried to run the same cp -a
command line on my own test sites inside that same docker container (as root), and I could copy 1 of my local sites’ folder to a new folder just fine (see the screenshot below):
I’m still wondering though why you got that error “Too many open files in system” when you ran that cp -a
command line
Now, just wanted to know the result too, what if you try to perform copy and paste but from your Mac (GUI) file manager?
after that, go inside the “mystagingsite” folder that you just created (but try to delete any existing files/folders inside this folder first), then try to “Paste” those files/folders you just copied from the mylivesite folder - and see if the process could be completed properly?
Please inform us again with the results - if copy-paste the files/folders via GUI would make any difference or if there will be any errors?
Best regards,
Agus Utomo
A manual copy within the macOS Finder GUI works without an issue.
I also get the Too many open files in system
error if I try to perform a cp -a
command in the macOS Terminal.
As a test, I removed the “uploads” folder from my site and renaming or cloning works without a problem.
So it’s all a case of my site being too big due to the many files in my upload folder and Docker struggling with it.