How to delete Windows NTFS hard link (mklink /h) while original is in use?



Windows NTFS Hard links, or “mklink /H”, are a way to create a pointer file that points to the original file. Hard links are useful for creating multiple links to the same file without creating a separate copy of the file, which makes them a useful tool for creating backup systems or sharing files between multiple users. However, in some cases, you may need to delete a hard link while the original file is in use.

In order to delete a Windows NTFS hard link while the original file is in use, you must first make sure that the original file is not open, as this will prevent the hard link from being deleted. If the original file is open, you will need to save it and close it before attempting to delete the hard link.

Once the original file is closed, you can delete the hard link by using the “del” command in the command prompt. To do this, open the command prompt, navigate to the directory containing the hard link, and type “del” followed by the name of the hard link. This will delete the hard link without deleting the original file.

It is also possible to delete a hard link while the original file is in use by using the “fsutil” command. This command can be used to delete a hard link without the need to close the original file. To use this command, open the command prompt, navigate to the directory containing the hard link, and type “fsutil hardlink delete” followed by the name of the hard link. This command will delete the hard link without deleting the original file.

Finally, it is also possible to delete a hard link while the original file is in use by using the “rm” command. This command can be used to delete a hard link without the need to close the original file. To use this command, open the command prompt, navigate to the directory containing the hard link, and type “rm” followed by the name of the hard link. This command will delete the hard link without deleting the original file.

In conclusion, it is possible to delete a Windows NTFS hard link while the original file is in use. To do this, you must first ensure that the original file is closed, and then you can use either the “del”, “fsutil”, or “rm” command to delete the hard link without deleting the original file.

Inquire Now

Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.
Find your next full or part-time role here

ScaleDesk can either help you find your next full time gig or a part time side gig where you can create extra income!

Onboard with us once
Skip HR screening and go to the final interview with with only your resume and a video interview you never have to redo
Get paid electronically every month for the hours you work
We will be your reference even if you work for us once

IT Teams: Use ScaleDesk to augment your team

Schedule Demo