Solved

Need to delete same folder accross different web accounts in VPS?

Posted on 2015-02-20
4
124 Views
Last Modified: 2015-02-21
My hosting provider has found a few suspicious files which I have now removed.
Just wondering if there is a command that I can use to remove all bValidator folders from my VPS?

Thanks,


HEX}php.uploader.max.574 : /home/actions1/public_html/bValidator/test2.php
{HEX}gzbase64.inject.unclassed.15 : /home/bluepage/public_html/flash/stat.php
{HEX}php.uploader.max.574 : /home/kingspace/public_html/bValidator/test2.php
{HEX}php.uploader.max.574 : /home/metrofor/public_html/bValidator/test2.php
{HEX}php.uploader.max.574 : /home/mippcoss/public_html/bValidator/test2.php
{HEX}php.uploader.max.574 : /home/ourshop/public_html/bValidator/test2.php
{HEX}php.uploader.max.574 : /home/sevenths/public_html/bValidator/test2.php
0
Comment
Question by:sabecs
  • 2
4 Comments
 
LVL 9

Assisted Solution

by:Rob_Jeffrey
Rob_Jeffrey earned 200 total points
ID: 40622573
If you have shell access, you can use find.

find /home -name "bValidator" -exec rm -rf {} \;


Before you run the above, you can test to see what files would be deleted with:

find /home -name "bValidator"
0
 

Author Comment

by:sabecs
ID: 40622619
Thanks Rob, would that just remove the directory called bValidator and everything in it, or will it also remove other files that might named bValidator   ?
0
 
LVL 9

Expert Comment

by:Rob_Jeffrey
ID: 40622959
That would also remove files named bValidator too.
0
 
LVL 28

Accepted Solution

by:
serialband earned 300 total points
ID: 40623649
If they all follow the same order, these can be easier.
rm  /home/*/public_html/bValidator/test2.php
rmdir  /home/*/public_html/bValidator/
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
AWS RDS 3 68
Adding more CPU cores to a Linux VM 5 66
Penetration Testing home based work 3 55
linux(debian) mouse poor performance 4 16
Using 'screen' for session sharing, The Simple Edition Step 1: user starts session with command: screen Step 2: other user (logged in with same user account) connects with command: screen -x Done. Both users are connected to the same CLI sessio…
Little introduction about CP: CP is a command on linux that use to copy files and folder from one location to another location. Example usage of CP as follow: cp /myfoder /pathto/destination/folder/ cp abc.tar.gz /pathto/destination/folder/ab…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now