Unable to rename site – error DK0058

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 :wave:

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
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
root@f8942fc6e365:/www/kinsta/public# ulimit -S

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 :thinking:

Now, just wanted to know the result too, what if you try to perform copy and paste but from your Mac (GUI) file manager?

there, go inside the “mylivesite” folder, then select all files/folders within that folder (press Control A perhaps?) and then right click your mouse and choose “Copy

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.

CleanShot 2024-04-02 at 17.46.38

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.