Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Creating a symbolic link to another drive 1

Status
Not open for further replies.

bazil2

Technical User
Feb 15, 2010
148
0
0
DE
(Elementary user)

I have a programme that caches large amounts of data before moving it elsewhere.

I would like to move the cache to a larger driver by using a symbolic link.

Is my syntax correct?

ln -s /path/to/current/cache /large drive

Best regards
 
Hmmm. That would be a valid link but I don't think it would give you the desired result. In this case it would create symlink in the directory you are currently in. It would create a directory link named /large drive that would send you to /path/to/current/cache. If I understand what you want to do correctly, what you want to do is go to the directory where you want the link. For example, let's say cache is the file name that gets created and /path/to/current/ is the sub-directory it gets created in. Go to /path/to/ and create a symlink directory called /current and /large drive/curent as it target. It would look something like this:

ln -s /large drive/current /current

If all goes well, when the program goes to write the file called cache in /path/to/current, it will be actually writing it to /large drive/current.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top