Red link

The Complete Guide to Creating Symbolic Links in Windows

In our current article we will try to explain Symbolic Links in Windows and give you a complete guide to their creation and usefulness.

symbolic link

Windows 10, 8, 7, and Vista support them Symbolic Links (or symbolic links in Greek), also known as shortcuts to a file or folder on your system. You can create them using the command line or a third-party tool such as Link Shell Extension.

What are Symbolic Links?
Symbolic Links are basically advanced shortcuts. By creating a symbolic link to a single file or folder in Windows, this link will appear as the file or folder itself, even if it is simply a link that directs you to the file or folder.

For example, let's say you have one που περιέχει τα αρχεία του στο C:\. Όμως εσείς θέλετε να αποθηκεύσετε αυτό το πρόγραμμα στον κατάλογο στο D:\Stuff, αλλά το ίδιο το πρόγραμμα απαιτεί τα αρχεία του είναι στο C:\Program. Θα μπορούσατε να μετακινήσετε το αρχικό κατάλογο από το C:\Program στο D:\Stuff, και στη συνέχεια να δημιουργήσετε ένα συμβολικό δεσμό στο C:\Program που να καταδεικνύει το D:\Stuff. Όταν θα εκκινεί το πρόγραμμα, θα προσπαθεί να αποκτήσει πρόσβαση στον κατάλογο του στο C:\Program. Τα Windows θα το ανακατευθύνουν αυτόματα στο D:\Stuff, και τα πάντα θα λειτουργήσουν ακριβώς σαν να ήταν στο C:\Program.

This trick can be used everywhere, including syncing to any folder with programs like Dropbox, Google Drive, and onedrive.

Υπάρχουν δύο ειδών symbolic links: Το hard και το soft. Συγχωρήστε μας την αγγλική ορολογία αλλά κάποια πράγματα έχουν πλέον διεθνώς καθιερωθεί και η Ελληνική μετάφρασή τους δεν ακούγεται εύηχη. Οι Soft συντομεύσεις λειτουργούν με παρόμοιο τρόπο με μία κανονική, τυπική συντόμευση. Όταν ανοίγετε μία soft συντόμευση προς ένα φάκελο, θα μεταφερθείτε στο φάκελο όπου είναι αποθηκευμένα τα αρχεία. Ωστόσο μία hard συντόμευση λειτουργεί και φαίνεται σαν το ίδιο το αρχείο ή ο φάκελος να υπάρχει πραγματικά στη θέση του συμβολικού δεσμού. Αυτή η makes hard shortcuts more useful in most cases.

Note that Windows does not use the terms "hard link" and "soft link". Instead, they use the terms “hard link” and “symbolic link”. In Windows, a "symbolic link" is the same as a "soft link". The mklink command can create both hard links and soft links (known as a "symbolic link" in Windows).

How to create a shortcut with mklink
You can create symbolic links using the mklink command from within an elevated command prompt window. To open such a window press the Win + X keys at the same time and from the popup select “Command Prompt (Admin)”.

Without any additional options, the mklink command creates a shortcut to a file. The following command creates a soft link to the file with the Target : mklink Link Target

Use the / D switch if you want to create a soft link that links to a directory. Like this: mklink / D Link Target

Using / H is done when you want to create a hard link that references a file: mklink / H
Link Target

Use the / J switch to create a hard link that references a directory, also known as the junction directory: mklink / J Link Target

For example, if you want to create a hard link in C: \ LinkToFolder to connect to C: \ Users \ Name \ OriginalFolder, you should run the following command:

mclink / JC: \ LinkToFolder C: \ Users \ Name \ OriginalFolder

You should enter quotation marks if the folder names are empty. For example, if folders are named C: \ Link to Folder and C: \ Users \ Name \ Original Folder, your command should be:

mklink / J "C: \ Link to Folder" "C: \ Users \ Name \ Original Folder"

If you see the message “You do not have sufficient privileges to of this mode”, You should restart the command prompt as an administrator.

How to Delete a Symbolic Link
To get rid of a symbolic link, you can just delete it as you would with any other file or directory. Just be careful to delete the shortcut itself rather than the regular file or directory that is linked.

iGuRu.gr The Best Technology Site in Greecefgns

Subscribe to Blog via

Subscribe to this blog and receive notifications of new posts by email.

Written by Dimitris

Dimitris hates on Mondays .....

Leave a reply

Your email address is not published. Required fields are mentioned with *

Your message will not be published if:
1. Contains insulting, defamatory, racist, offensive or inappropriate comments.
2. Causes harm to minors.
3. It interferes with the privacy and individual and social rights of other users.
4. Advertises products or services or websites.
5. Contains personal information (address, phone, etc.).