中国DOS联盟论坛

China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --
Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
Guest | Log in | Register | Members | Search | China DOS Union
中国DOS联盟论坛
The time now is 2026-08-27 02:22
47,812 topics / 349,912 posts / today 2 new / 48,264 members
其它操作系统综合讨论区 » [Recommendation]NTFS Symbolic Link Creation Tool Junction [Virtual Directory][Convenient]
Printable Version  1,886 / 9
Floor1 airosp Posted 2007-04-13 09:01
初级用户 Posts 41 Credits 99
The old version of Sysinternals junction.exe found everywhere, the version before Microsoft acquired it, very classic~
http://zhenlove.com.cn/cndos/fileup/files/junction-1.04_sysinternals.zip

Usage:


[ Last edited by airosp on 2007-4-12 at 08:35 PM ]
Floor2 airosp Posted 2007-04-13 09:06
初级用户 Posts 41 Credits 99
It's something new. Let's explain:
Symbolic links are for facilitating file/directory operations. Simply put, it's like window glass, completely transparent, and software accesses the real directory through it.

For detailed explanations, please see here:
http://www.rainux.org/2004/12/22/18
http://windows-vista.highdiy.com/index.php/symbolic-link/
(Guaranteed to be the original release points)

=========================
Let's take a practical application example:
The official version of Firefox can only place configurations in %AppData%\Mozilla. It would be terrible if the system drive is destroyed~

Note that the FAT file system does not support symbolic links.

1. First, move the entire contents of %AppData%\Mozilla to the destination, such as D:\Browser\Firefox\settings.

2. Delete the directory %AppData%\Mozilla

3. Create a symbolic link using junction in the command line:

C:\>junction "%AppData%\Mozilla" "D:\Browser\Firefox\settings"

Junction v1.04 - Windows junction creator and reparse point viewer
Copyright (C) 2000-2005 Mark Russinovich
Systems Internals - http://www.sysinternals.com

Created: C:\Documents and Settings\Administrator\Application Data\Mozilla
Targetted at: D:\Browser\Firefox\settings

4. Done. Now, check the contents of %AppData%\Mozilla.
Is it exactly the same as the contents in D:\Browser\Firefox\settings? ^_^
=========================

Why look for the old version of Sysinternals?
Microsoft's so-called new version first requires people to agree to the license agreement + randomly writes to the registry:
http://www.microsoft.com/technet/sysinternals/FileAndDisk/Junction.mspx

What is %AppData%? An environment variable, referring to your application directory. For example:
"%AppData%" = "C:\Documents and Settings\Administrator\Application Data"

[ Last edited by airosp on 2007-4-12 at 08:27 PM ]
Floor3 0451lym Posted 2007-04-13 09:23
高级用户 Posts 357 Credits 760
What concept? Shortcuts under DOS? Or to put it another way: Virtual directory? Where can that be used?

[ Last edited by 0451lym on 2007-4-13 at 09:25 AM ]
Floor4 airosp Posted 2007-04-13 09:25
初级用户 Posts 41 Credits 99
Originally posted by 0451lym at 2007-4-12 20:23:
What concept? Shortcuts under DOS?
Where can they be used?

A virtual directory created for convenient folder operations.

To software, a symbolic link is just a real folder, actually a shell pointing to a real folder. Microsoft learned this from Linux and Unix file systems~

According to Microsoft, only Vista supports creating symbolic links for files.

[ Last edited by airosp on 2007-4-12 at 08:34 PM ]
Floor5 0451lym Posted 2007-04-13 09:26
高级用户 Posts 357 Credits 760
Floor6 airosp Posted 2007-04-13 09:37
初级用户 Posts 41 Credits 99
Hard link 硬链接
Symbolic link 符号链接
symlink 符号链接
Floor7 Climbing Posted 2007-04-13 21:49
铂金会员 Posts 2,753 Credits 6,962 From 河北保定
I came into contact with these things a long time ago, similar to the ln command under Unix. Unix fully supports various link methods. However, reminded by the landlord, I found that many stubborn directories of Microsoft can indeed be specified to other partitions through this method. But unfortunately, I don't like using the ntfs file system. It would be even more perfect if FAT partitions could be supported.
Floor8 Climbing Posted 2007-04-13 22:06
铂金会员 Posts 2,753 Credits 6,962 From 河北保定
Under the CMD of XP, I found a
fsutil hardlink create ln.exe junction.exe

Similar to the junction command, but I found that junction.exe cannot manage the hard link created by the above command.

And fsutil hardlink can only create hard links of files. By the way, what are the differences between hard links and symbolic links? Please the thread starter to explain.
Floor9 airosp Posted 2007-04-13 23:56
初级用户 Posts 41 Credits 99
·Hard links to directories were not supported before Vista.
·Hard links cannot cross partitions.
A hard link is multiple file names for the same content, almost indistinguishable from the original file name.
Hard links are written directly to the file table and are lower-level than symbolic links, so they cannot cross partitions.

·Symbolic links to files were not supported before Vista.
·Symbolic links can cross partitions.
Note: Before Vista, there was a major bug in Microsoft Explorer's operation of symbolic links; deleting a symbolic link would also delete the linked object together. Explorer has no such bug for hard links.

On Linux, symbolic links can cross out of the local machine.

[ Last edited by airosp on 2007-4-13 at 11:34 AM ]
Floor10 airosp Posted 2007-04-19 04:52
初级用户 Posts 41 Credits 99
Oh, is this really that niche...
[ Contact the Union admin team - 中国DOS联盟 - Standard version ]
Sponsored by ifanr Inc | © 2001–2023