Suggestion: Warn for delete with junctions
Moderators: white, Hacker, petermad, Stefan2
Suggestion: Warn for delete with junctions
Ruined a windows installation once when trying to delete the Windows.Old folder because it had wrong junctions to outside active windows folders (ie: "C:\Windows.Old\Archivos de Programa" pointed to "C:\Program Files" instead of the inner " "C:\Windows.Old\Program Files"). Total Commander started deleting files outside the intended target.
An extra warning should be showed whenever deleting (and maybe when moving) files that are placed outside selected target...
An extra warning should be showed whenever deleting (and maybe when moving) files that are placed outside selected target...
- ghisler(Author)
- Site Admin
- Posts: 48138
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Re: Suggestion: Warn for delete with junctions
Total Commander does not follow junctions when deleting, it just deletes the junctions themselves.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Re: Suggestion: Warn for delete with junctions
The Windows Cleanmgr.exe is responsible for deleting Windows.old.isidro wrote: ↑2019-01-17, 14:05 UTC Ruined a windows installation once when trying to delete the Windows.Old folder because it had wrong junctions to outside active windows folders (ie: "C:\Windows.Old\Archivos de Programa" pointed to "C:\Program Files" instead of the inner " "C:\Windows.Old\Program Files"). Total Commander started deleting files outside the intended target.
An extra warning should be showed whenever deleting (and maybe when moving) files that are placed outside selected target...
Using this tool is the normal way to delete old Windows installations.
But I did it once in the past with TC and it didn't destroy anything outside of it.
Windows 11 Home x64 Version 23H2 (OS Build 22631.3593)
TC 11.03 x64 / x86
Everything 1.5.0.1376a (x64), Everything Toolbar 1.3.3, Listary Pro 6.3.0.78
QAP 11.6.3.3 x64
TC 11.03 x64 / x86
Everything 1.5.0.1376a (x64), Everything Toolbar 1.3.3, Listary Pro 6.3.0.78
QAP 11.6.3.3 x64
Re: Suggestion: Warn for delete with junctions
I've tried to delete a folder with a junction in it when the folder requires admin rights, but TC 9.21a for some reason was unable to delete it via 'As Administrator' button... When I've deleted the junction manually via the same 'As Administrator' button, TC could remove the folder.
Last edited by MVV on 2019-01-22, 06:52 UTC, edited 1 time in total.
Re: Suggestion: Warn for delete with junctions
So I don't know how or what happened then. Maybe it was coincidence. Thanks.
Re: Suggestion: Warn for delete with junctions
Been able to reproduce HUGE issue, when entering on a HD (to fix) "G:\Users\All Users" it actually takes you to local HD: "C:\ProgramData", but windows title states you are on "g:\Users\All Users\" so anything one deletes there it's being deleted on C: drive instead of G:
I think in that way I might destroyed a working OS.
I think in that way I might destroyed a working OS.
- ghisler(Author)
- Site Admin
- Posts: 48138
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Re: Suggestion: Warn for delete with junctions
This can happen when the hard link (junction / Reparse point) only allows to be opened / followed, but the target name cannot be read. Then TC cannot know where it points.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Re: Suggestion: Warn for delete with junctions
Why does TC remove anything behind a reparse point if it is being able to detect that it is a reparse point? It just should never delete anything behind any reparse point, but just delete the reparse point itself.ghisler(Author) wrote: ↑2019-01-24, 10:41 UTC This can happen when the hard link (junction / Reparse point) only allows to be opened / followed, but the target name cannot be read. Then TC cannot know where it points.
- ghisler(Author)
- Site Admin
- Posts: 48138
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Re: Suggestion: Warn for delete with junctions
It doesn't, except if it doesn't detect that it is a reparse point.Why does TC remove anything behind a reparse point if it is being able to detect that it is a reparse point?
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
Re: Suggestion: Warn for delete with junctions
Ok, but I think that such items should be non-listable, correct? If a folder can be listed in dir, its reparse point flag may be get via WIN32_FIND_DATA structure.
-
- Junior Member
- Posts: 26
- Joined: 2011-04-01, 21:11 UTC
Re: Suggestion: Warn for delete with junctions
I too, deleted my files in my drive C deleting folders from external USB (a disk with windows from another computer, with standard win7 junction point like "\Users\All users" pointing to "c:\ProgramData", etc.)
Total Commander should not follow junction points, instead it often follows them
Total Commander should not follow junction points, instead it often follows them
- ghisler(Author)
- Site Admin
- Posts: 48138
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
Re: Suggestion: Warn for delete with junctions
When deleting, TC only deletes the junction itself, not the target, except when Windows reports it as a directory and not as a junction.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
-
- Junior Member
- Posts: 26
- Joined: 2011-04-01, 21:11 UTC
Re: Suggestion: Warn for delete with junctions
So maybe the way windows is interrogated, or the way it responds, is not reliable, because more than once at me TC has deleted the data, not the junctionghisler(Author) wrote: ↑2020-02-16, 11:47 UTC When deleting, TC only deletes the junction itself, not the target, except when Windows reports it as a directory and not as a junction.
Re: Suggestion: Warn for delete with junctions
2zupermario
What Windows version do you use?
What Windows version do you use?
Andrzej P. Wozniak
Polish subforum moderator
Polish subforum moderator
-
- Junior Member
- Posts: 26
- Joined: 2011-04-01, 21:11 UTC