# Unable to rename site – error DK0058

**URL:** https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106
**Category:** Application Support
**Created:** [March 1, 2024, 7:16pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106 "2024-03-01T19:16:46Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 1, 2024, 7:16pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/1 "2024-03-01T19:16:46Z")

</div>

Every time I attempt to rename a site, I get the DK0058 error. I have tried what the support site says (delete the folder and retry) but I always get the DK0058 error no matter what.

This is what the log says about my latest attempt:

```auto
[2024-03-01 13:49:02.196] [info] [dockerUtil/getContainer] Get 'devkinsta_fpm' Docker container
[2024-03-01 13:49:02.244] [info] [ProgressIndicator] { isFailed: false, isOpen: false }
[2024-03-01 13:49:02.267] [info] [ProgressIndicator] { isFailed: false, isOpen: false }
[2024-03-01 13:49:03.630] [info] [ProgressIndicator] { isFailed: false, isOpen: true }
[2024-03-01 13:50:19.884] [info] [containerExec] Command 'cp -a /www/kinsta/public/mylivesite/. /www/kinsta/public/mystagingsite' on devkinsta_fpm finished with exit code 1
[2024-03-01 13:50:19.896] [info] [copyFiles] Source folder removed successfully.
[2024-03-01 13:50:19.897] [info] [copyFiles] Moving files completed successfully
[2024-03-01 13:50:19.902] [error] Error - DK0058: COPY_FILES: [copyFiles] Failed to copy files from /www/kinsta/public/mylivesite to /www/kinsta/public/mystagingsite
    at /Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:2:841401
    at tryCatch (/Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:8:1828882)
    at Generator.<anonymous> (/Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:8:1830531)
    at Generator.next (/Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:8:1829431)
    at asyncGeneratorStep (/Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:8:1820727)
    at _next (/Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:8:1821026)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
[2024-03-01 13:50:19.914] [error] [ipcMainStep] Error in operation RENAME_SITE, step copyFiles: Error - DK0058: COPY_FILES: [copyFiles] Failed to copy files from /www/kinsta/public/mylivesite to /www/kinsta/public/mystagingsite
    at /Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:2:841401
    at tryCatch (/Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:8:1828882)
    at Generator.<anonymous> (/Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:8:1830531)
    at Generator.next (/Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:8:1829431)
    at asyncGeneratorStep (/Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:8:1820727)
    at _next (/Applications/DevKinsta.app/Contents/Resources/app.asar/main.prod.js:8:1821026)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)

```

---

<div class="post-metadata">

### Author: ![Andrew](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/andrew/32/2792_2.png) [@Andrew](https://community.kinsta.com/u/Andrew)
#### Post date: [March 3, 2024, 10:55pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/2 "2024-03-03T22:55:08Z")

</div>

Hi @halshak! Welcome to the Kinsta community!

I’m sorry to hear that you are having difficulty with renaming your site. I understand seeing this type of error can be frustrating. We are happy to help and want to ensure that this error is resolved as soon as possible!

It looks like the “RENAME\_SITE” action is failing at the copyFiles step. Unfortunately, I’m not specifically seeing the reason for this failure in the log. I do want to verify a few things regarding your system environment however that will help us in our investigation.

Could you please answer the following questions?

**Q: DevKinsta Version**

**Q: OS Version**

**Q: Docker Desktop Version**

This information will help us in our investigation and possibly in determining the root cause of the issue.

We look forward to hearing from you!

---

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 4, 2024, 10:50pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/3 "2024-03-04T22:50:20Z")

</div>

Hi @Andrew:

DevKinsta 2.13.1 (2.13.1.8585)  
macOS 14.3.1  
Docker Desktop 4.28.0

Thanks.

---

<div class="post-metadata">

### Author: ![Adrian\_L](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/adrian_l/32/2810_2.png) [@Adrian\_L](https://community.kinsta.com/u/Adrian_L)
#### Post date: [March 5, 2024, 3:01am UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/4 "2024-03-05T03:01:18Z")

</div>

Hello @halshak 👋

If you haven’t already, please fully exit from DevKinsta and Docker Desktop. After doing so, re-launch DevKinsta and attempt to rename your site again. If the issue persists, I recommend increasing the virtual disk limit allocated for DevKinsta in your Docker Settings \> Resources page.

Let us know how it goes!

---

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 5, 2024, 1:42pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/5 "2024-03-05T13:42:19Z")

</div>

I usually shut down DevKinsta and Docker after I’m done working on something, so I launched them and increased the virtual disk limit to 400 GB in Docker and I still get the error.

Comparing the new folder with the one I’m trying to rename, I see they are almost identical in size when the copy files step fails, save for missing one file (don’t know what it is).

![CleanShot 2024-03-05 at 08.40.48](https://us1.discourse-cdn.com/flex020/uploads/kinsta/original/2X/a/a130bf143b43212751e6cdd40c30bbd388c83460.png)

---

<div class="post-metadata">

### Author: ![Agus](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/agus/32/1515_2.png) [@Agus](https://community.kinsta.com/u/Agus)
#### Post date: [March 8, 2024, 3:13am UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/6 "2024-03-08T03:13:56Z")

</div>

Hi @halshak👋

I’ve never encountered this error/issue on my Linux Ubuntu O/S (I don’t have Mac machine here so can’t really test to replicate) 😅 .  
I also have just now re-tested to rename my local site(s) using _DevKinsta 2.13.1_ on my Linux Ubuntu 22.04, and so far all seemed to be working fine still (didn’t get that `Error - DK0058: COPY_FILES` error).

Now I’m wondering, what if you delete/remove it completely first, and then re-create the new site folder name ` mystagingsite` manually - that’s located under the `~/DevKinsta/public` folder  
so, from your Mac terminal - with your local user account, please create that new site folder with this command line: `mkdir mystagingsite` .

Once re-created manually, please fully shutdown both DevKinsta and Docker completely (not just minimized), and relaunch DevKinsta , and try to rename that `mylivesite` site to that new site name `mystagingsite` , and see if the source files/folders from that existing site can be copied properly to that new site’s folder?

Another thing, though I’m still unsure about this, but worth to check, if you can please run the following command line in your Mac Terminal (within the `~/DevKinsta/public/mylivesite/` sub-folder):  
`find . -xtype l -ls`  
(and if you can copy-paste the results too here), just curious if there’s any such _broken symlink_ file(s)/folder(s) inside that current local site’s folder - and if that’s the issue here - as from your last screenshot, looks like there’s 1 missing item (file or folder) 🤔

Please let us know the results for this test (and the error message too if any) 🙏

Best regards,  
Agus Utomo

---

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 8, 2024, 2:07pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/7 "2024-03-08T14:07:55Z")

</div>

Hi @Agus

I tried creating the new folder manually, then running the rename function on a freshly-launched DevKinsta and Docker, and I still get the same DK0058 error.

I tried that command in Terminal and got this: `find: -xtype: unknown primary or operator`.

---

<div class="post-metadata">

### Author: ![Andrew](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/andrew/32/2792_2.png) [@Andrew](https://community.kinsta.com/u/Andrew)
#### Post date: [March 10, 2024, 2:03am UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/11 "2024-03-10T02:03:37Z")

</div>

Hi @halshak! Thanks for your reply.

I’m sorry to hear that the error is continuing to occur even after creating the new folder. We are continuing to look into the cause of this error. We will be following up as soon as possible with an update.

Regarding the command to find broken symlinks, it appears there is a slight difference in the Mac version compared to the Linux version regarding which options it supports. Please try running the following command in the `~/DevKinsta/public/mylivesite/` subfolder:

`find -L . -type l -ls`

If you could please copy/paste the output of that command here it is appreciated and will help us in our investigation.

Best regards

---

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 11, 2024, 2:19am UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/12 "2024-03-11T02:19:18Z")

</div>

Hi,

I entered that command and got no output, so I’m guessing there are no symlink issues.

---

<div class="post-metadata">

### Author: ![VladimirM](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/vladimirm/32/2786_2.png) [@VladimirM](https://community.kinsta.com/u/VladimirM)
#### Post date: [March 11, 2024, 12:16pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/14 "2024-03-11T12:16:52Z")

</div>

Hi @halshak

This seems to be pretty complex and I do apologize for the back and forth, but after reviewing this there are other steps you can try.

1. Open the Devkinsta FPM terminal (you should be able to do this from the Docker)  

2. Make sure a folder `/www/kinsta/public/mystagingsite` exists there and it is empty.

3. Execute `cp ` `-` `a /www/kinsta/public/mylivesite/. /www/kinsta/` `public/` `mystagingsite`

4. Let me know if there’s an error and what the error is

Kind regards

---

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 11, 2024, 2:25pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/15 "2024-03-11T14:25:37Z")

</div>

Hi,

After I run that command in Docker I get this error:

```auto
cp: target 'mystagingsite' is not a directory

```

---

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 11, 2024, 2:28pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/16 "2024-03-11T14:28:45Z")

</div>

I also want to note that if I add a site (using “New Wordpress site”), I can rename that without an issue. It seems to only happen with the import from our live or staging environment.

---

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 11, 2024, 2:36pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/17 "2024-03-11T14:36:06Z")

</div>

Another thing I tried was removing anything we added to the root folder (favicons, folders) and that seemed to copy all files (size and file count are identical) but then it still fails.

And when I cancel and it deletes all the files, but leaves the folder behind with wp-content/uploads inside.

---

<div class="post-metadata">

### Author: ![andre](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/andre/32/2785_2.png) [@andre](https://community.kinsta.com/u/andre)
#### Post date: [March 13, 2024, 2:11pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/19 "2024-03-13T14:11:17Z")

</div>

Hi @halshak,

Thank you for your response!  
It looks like the folder you’re trying to use doesn’t exist, which is why you get that error, which is expected to occur.

A quick command to create the folder through SSH/Terminal would be:  
`mkdir /www/kinsta/public/mystagingsite`

That will create the folder, and from that point on, the path will be valid, so in theory the previous operation should work.

Please do let us how it goes.  
Thank you in advance!

Sincerely,  
Andre F.

---

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 26, 2024, 2:40pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/20 "2024-03-26T14:40:55Z")

</div>

![CleanShot 2024-03-26 at 10.39.20@2x](https://us1.discourse-cdn.com/flex020/uploads/kinsta/original/2X/b/b6966251444ca3a87f7b2b0e5448cc50e3d7c9a8.png)

---

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 26, 2024, 2:41pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/21 "2024-03-26T14:41:28Z")

</div>

![CleanShot 2024-03-26 at 10.40.03@2x](https://us1.discourse-cdn.com/flex020/uploads/kinsta/original/2X/6/66749d19f5ebb7b0a24693b2b830db7966e3ddea.png)

I am very confused.

---

<div class="post-metadata">

### Author: ![VladimirM](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/vladimirm/32/2786_2.png) [@VladimirM](https://community.kinsta.com/u/VladimirM)
#### Post date: [March 27, 2024, 10:02am UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/22 "2024-03-27T10:02:28Z")

</div>

Hello @halshak

This might be a glitch in the screenshot but it seems as if there’s a blank space in the other part of the command. I also see that’s how I suggested it above, it’s a mistake on my end.

Can you try running this:

cp -a /www/kinsta/public/mylivesite/. /www/kinsta/public/mystagingsite

I apologize for the back and forth.

Kind regards,

---

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 27, 2024, 1:59pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/23 "2024-03-27T13:59:06Z")

</div>

This helped, I now see some more useful errors.

Three errors in relation to three specific files that look like this:

```auto
cp: cannot create regular file '/www/kinsta/public/mystagingsite/./wp-content/uploads/2016/08/Internal-Control-Resolver-300x157.png': Too many open files in system

```

And one like this:

```auto
cp: cannot stat '/www/kinsta/public/mylivesite/./wp-content/themes/resolver/assets/js/resolver-source-js/js/_resolver-homepage.js': No such file or directory

```

If I run the command again, it produces the same errors but with other files.

---

<div class="post-metadata">

### Author: ![VladimirM](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/vladimirm/32/2786_2.png) [@VladimirM](https://community.kinsta.com/u/VladimirM)
#### Post date: [March 28, 2024, 1:24pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/25 "2024-03-28T13:24:23Z")

</div>

Hey again @halshak

What do you get if you run `ulimit -n`?

Please let me know what’s the output. Thank you!

---

<div class="post-metadata">

### Author: ![halshak](https://sea2.discourse-cdn.com/flex020/user_avatar/community.kinsta.com/halshak/32/2751_2.png) [@halshak](https://community.kinsta.com/u/halshak)
#### Post date: [March 28, 2024, 1:40pm UTC](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106/26 "2024-03-28T13:40:19Z")

</div>

```auto
# ulimit -n   
1048576

```

[Next page](https://community.kinsta.com/t/unable-to-rename-site-error-dk0058/3106.md?page=2)
