Virtual Host Directory already exists. [404]

One of my domain reached its disk quota limit. And the site showing 505 error. I modified the package but it had no result. I tried to delete the website from cyberpanel and deleted the virtual host.

Now the directory of the domain remain in my server and can’t delete the folder, even I can’t change user:group.

I tried so many thing rm -rf and chown and lsof

nothing worked for me. Can anyone help me to sort this out, I want to add that domain again.

rm -rf code when executed what it shown? Any error message?

[root@root public_html]# rm -rf index.php
rm: cannot remove ‘index.php’: Operation not permitted

If possible, PM me temporary login for me to check the same and find the cause of this issue.

Please check your inbox. credentials sent.

Solved.

If you face this issue again,

Login to SSH as root and

Navigate to /home/ folder by

cd /home/

Then, execute this command to remove the domain directory (change example.com to your domain name including the tld)

rm -rf example.com

3 Likes

Thank you so much for your time.

1 Like

I’m having the same problem, however, when trying this command I get the following message: (I changed the domain name to example.com)

rm: cannot remove 'example.com/logs': Operation not permitted
rm: cannot remove 'example.com/public_html/index.html': Operation not permitted

sudo rm -rf example.com

It’s a little scary to have mention it… be careful.

I am a Root user, I have sudo permission.

oh then it’s probably chattr, chattr -R -i example.com

edit : I didn’t even notice the ‘chattr -R +i /home/%s/’ in IncScheduler.py, very sneaky.

I tried “rm -rf example.com”, “sudo rm -rf example.com” & " chattr -R -i example.com" but none of these solve my issue.

Please help me.

Go to http://yourIP:7080 and look virtual hosts and delete duplicate one.

Can’t log in. I have used my VPS login, Cyber Panel admin login details but didn’t let me in. What is the login here?

SSH to server

cd /usr/local/lsws/admin/misc

Then execute

./admpass.sh

Then follow prompts

Thanks, I have reset the admin password by following your instruction. Then deleted the virtual host but still can’t create the website again. Do I have to do anything to clear the cache or restart the server? Please help.

1 Like

I have solved the issue by doing the steps bellow:

Step 1: Go to http://yourip:7080/ (Look for virtual hosts and delete the duplicate domain.com)

If the admin password doesn’t work then follow this: cd /usr/local/lsws/admin/misc & ./admpass.sh (Reset password)

Step 2: Login via SFTP and look for this path: /root/.acme.sh (Delete the duplicate domain.com).

Step 3: rm -rf /usr/local/lsws/conf/vhosts/domain.com
rm -rf /home/domain.com

Now try to add the website, it should work now. Cheers

I Have the Same Problem! Please help me.
rm: cannot remove ‘natunbanglanews.in’: Operation not permitted