Windows Help Forum  

Windows Tips, Tutorials & Articles Submit & Discuss Windows 7 & Windows Vista Tips, Totorials & Articles.


Reply
 
Thread Tools Display Modes
  (#1 (permalink)) Old
eset_boy Offline
Windows Enthusiast
 
eset_boy's Avatar
 
Posts: 63
Join Date: Aug 2008
Location: Home
Default How to create symlinks in Vista - 08-16-2008, 11:33 PM

Symlinks or Symbolic Links are symbolic link ( also known as a soft link) consists of a special type of file that serves as a reference to another file or directory. This feature is availble finally in Windows Vista. You can create symlinks using the windows vista command line utility termed as “MKLINK”.

Syntax for Symlink in Vista

MKLINK [ /D] | [/H] | [/J] Link Target

where [] stands for optional and / is used as option

* /D - Create a directory symbolic link ( soft link ). Default is file symbolic link.
* /H - Creates a Hard link ( link to a file ) .
* /J - Creates a directory junction
* LINK - Specifies a new symbolic link name
* Target - Specifies the path that the new link will refer to.

Example of Creating a symbolic link to directory

On command prompt, first navigate to the directory you want. Then ( Here I am at C directory )

* C:\ > mklink /D mySymDir D:\MyBlogData

The above example makes all the data in “C” directory available in D:\Myblogdata. Juts make a Dir in DMyblogdata and You will see all the files of C directory.

Here we will see how we can make data of two directory available in one symlink.

Our Target

Take Directories d:\Blogdata and d:\Images . Now you want to see data of both the directory into a new place say d:\Blog. Now we will use MKLINK /J option to do it. /J stands for directory junction.

Steps to make a junction directory / symlink

* MKLINK /D c:\blog d:\BlogData
* The above steps create a hard link and all data under D:\blogdata directory can be seen in c:\blog.
* Now type MKLINK /J c:\blog d:\images
* Now your d:\images will be added to the symlink you have already create.
* Now when you browse c:\blog you will be able to see both directories data.


source1
source2


... Life is beautiful ...

Last edited by eset_boy; 08-16-2008 at 11:36 PM..
   
Reply With Quote
  (#2 (permalink)) Old
Pankaj Offline
Windows Enthusiast
 
Pankaj's Avatar
 
Posts: 114
Join Date: Nov 2008
Location: Pune
Default 02-01-2009, 07:08 PM

But what are symlinks? I mean give me some practical example. Or is it geek stuff...in that case forget it.
   
Reply With Quote
  (#3 (permalink)) Old
seti Offline
Gold Member
 
seti's Avatar
 
Posts: 1,550
Join Date: Nov 2008
Location: isle of Man
Default 02-01-2009, 07:29 PM

Quote:
Originally Posted by Pankaj View Post
But what are symlinks? I mean give me some practical example. Or is it geek stuff...in that case forget it.
well above my head too, please tell us in simple terms if possible


Love is the greatest gift of all. Give Generously, freely and daily to all
   
Reply With Quote
  (#4 (permalink)) Old
whs Offline
Gold Member
 
whs's Avatar
 
Posts: 745
Join Date: Oct 2008
Default 02-01-2009, 08:09 PM

It's a fancy shortcut. There are many of those in the system anyhow. Here is some reading ( Smart Software: Symbolic Links in Vista ).
   
Reply With Quote
  (#5 (permalink)) Old
seti Offline
Gold Member
 
seti's Avatar
 
Posts: 1,550
Join Date: Nov 2008
Location: isle of Man
Default 02-01-2009, 08:17 PM

Quote:
Originally Posted by whs View Post
It's a fancy shortcut. There are many of those in the system anyhow. Here is some reading ( Smart Software: Symbolic Links in Vista ).
thanks for that


Love is the greatest gift of all. Give Generously, freely and daily to all
   
Reply With Quote
  (#6 (permalink)) Old
dmudgal Offline
Windows Enthusiast
 
dmudgal's Avatar
 
Posts: 110
Join Date: Aug 2008
Default 02-02-2009, 08:38 AM

thanks for the stuff .....Eset_boy


www.animateindia.blogspot.com
   
Reply With Quote
  (#7 (permalink)) Old
iMav Offline
Microsoft MVP
 
iMav's Avatar
 
Posts: 789
Join Date: Jul 2008
Default 02-02-2009, 05:21 PM

Interesting, will have a look at how this helps, though the second source makes some sense. Thanks for this.
   
Reply With Quote
  (#8 (permalink)) Old
HappyAndyK Offline
Site Administrator
 
HappyAndyK's Avatar
 
Posts: 2,586
Join Date: Jun 2008
Default 02-02-2009, 06:06 PM

A nice read here :
Symbolic Links (Windows)
   
Reply With Quote
  (#9 (permalink)) Old
Pankaj Offline
Windows Enthusiast
 
Pankaj's Avatar
 
Posts: 114
Join Date: Nov 2008
Location: Pune
Default 02-03-2009, 02:55 PM

Okiz--thanks for all the explainations.
   
Reply With Quote
  (#10 (permalink)) Old
Gold Member
 
nitinagarwal1988's Avatar
 
Posts: 1,239
Join Date: Jan 2009
Location: Pilani, India
Default 02-03-2009, 05:41 PM

thanks for the link whs and thanks eset boy for informing us...

Last edited by nitinagarwal1988; 02-03-2009 at 05:44 PM..
   
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


 
Partner Links












Copyright © 2007 - 2009 The Windows Club

Search Engine Friendly URLs by vBSEO 3.3.0