DOS question

brunswickite

Diamond Member
Jul 23, 2002
6,386
1
0
If i have a file that Windows cannot delete, that it does not allow me to delete. Its a Klez infected file on my computer. I went into safemode, and am at the command prompt, how do i change the file restrictions, that it will let me delete it, I am very shakey with dos

so i would really appreciate it if someone could help me out, also provide an example for me, i looked online but could not find anything.

thanks in advance
 

burnedout

Diamond Member
Oct 12, 1999
6,249
2
0
In DOS, try ATTRIB.

For example:

C:\> ATTRIB -R -A -S -H c:\windoze\system\klez.exe

You'll have to modify the path for your system.
 

brunswickite

Diamond Member
Jul 23, 2002
6,386
1
0
Originally posted by: burnedout
In DOS, try ATTRIB.

For example:

C:\> ATTRIB -R -A -S -H c:\windoze\system\klez.exe

You'll have to modify the path for your system.

THANKS! i will try i appreciate it.
 

Smilin

Diamond Member
Mar 4, 2002
7,357
0
0
If you find that it still won't let you delete in safemode because it's still 'in use' you can boot to recovery console and do it. However files with a system attribute won't let you modify their other attributes like read-only or hidden while in recovery console. You can use a little trick to delete it anyway (this is a clever way to delete your pagefile in case of corruption as well):

cd \<path to your file>
copy c:\boot.ini <name of file you want to delete>
del boot.ini <----Make sure you are in the right path!! if you did a typo in step 1 you're gonna fvckup the real boot.ini

 

burnedout

Diamond Member
Oct 12, 1999
6,249
2
0
Smilin: Yeah, you have a better solution that I never considered even though I perform essentially that comparable operation when working with linux all the time.

mv from one to another. Sometimes I need to kick myself in the rear.