How to Make or Create Symbolic Link in Unix or Linux如何使或創建符號鏈接在Unix或Linux
Symbolic link (also known as symlink or soft link) is a special type of file that has reference that points to another file or directory, in the form of an absolute or relative path.符號鏈接(也稱為符號鏈接或軟鏈接)是一種特殊類型的文件,參考點到另一文件或目錄的形式,絕對或相對路徑。 Symbolic link can be used just like the target original file or folder, as it merely contains a text string that is interpreted and followed by the operating system to another file or directory.符號鏈接可用於就像原始的目標文件或文件夾,因為它僅僅包含一個文本字符串是解釋和所遵循的操作系統,另一文件或目錄。
Symbolic link is supported on most Unix-like (including Linux) operating systems, Windows Vista (see符號鏈接是最支持類Unix (包括Linux )操作系統, Windows Vista中(見 Windows Vista symbolic link, hard link and junction point Windows Vista的符號鏈接,硬鏈接和交界點 ) and to some degree in Windows 2000 and Windows XP. ) ,並在一定程度上Windows 2000和Windows XP 。 Although symbolic link is pointing to a target, it operates independently of its target (deletion of symbolic link does not been affected), but allows program to behave as if operating directly on the target file.雖然符號鏈接指向一個目標,它獨立運作,其目標(刪除符號鏈接不會受到影響) ,但允許程序表現為,如果直接操作的目標文件。
So how to create or make a symbolic link?因此,如何創建或作出一個象徵性的鏈接? To create a symbolic, use the following command syntax:要創建一個象徵性的,使用下面的命令語法:
ln -s [target directory or file] [symlink shortcut]
For example, to link the /usr/local/lib/example directory to /example, use the following command:例如,如果要聯繫的/ usr / local / lib目錄/目錄,例如/例如,使用下面的命令:
ln -s /usr/local/lib/example /example
After creating the symbolic link above, /example will point to /usr/local/lib/example, and when user changes directory (CD) to /example, OS shell will automatically change it to /usr/local/lib/example directory.在創建符號鏈接上述情況, /例如將指向為/ usr / local / lib目錄/例如,當用戶更改目錄(光盤版) ,以/例如,操作系統殼會自動更改為/ usr / local / lib目錄/例如目錄。
IMPORTANT : This is a machine translated page which is provided "as is" without warranty. 重要說明:這是一台機器翻譯網頁這是“原樣”提供,無保修。 Machine translation may be difficult to understand.機器翻譯可能很難理解。 Please refer to請參閱 original English article英文原文的文章 whenever possible.只要有可能。
Share and contribute or get technical support and help at共享和貢獻或獲得技術支持和幫助 My Digital Life Forums 我的數字生活論壇 . 。
Related Articles相關文章
- Change Group Ownership of Symbolic Links in Unix or Linux漲跌集團擁有象徵性的聯繫在Unix或Linux
- How to Mount USB Disk Drive in UNIX or Linux如何安裝的USB磁盤驅動器在UNIX或Linux操作系統
- Refresh Linux or Unix Path Environmental Variables with rehash刷新Linux或Unix路徑環境變量與翻版
- How to Change or Spoof MAC Address in Windows XP, Vista, Server 2003/2008, Mac OS X, Unix and Linux如何更改或欺騙性MAC地址在Windows XP , Vista系統,服務器二千○八分之二千○三時, Mac OS X , Unix和Linux
- Create Symbolic Links, Hard Links and Directory Junctions in Vista with MKLINK創建符號鏈接,硬鏈接和目錄結在Vista與MKLINK
- Open, Extract and Convert DAA, ISO and BIN Files in Linux with Free PowerISO for Linux打開,提取和轉換的DAA ,國際標準化組織和本文件在Linux與自由PowerISO為Linux
- Find Files that are Modified Today (or Since Certain Time Ago) in Unix查找檔案,修飾今日(或自某一時間前)在Unix
- (Enhance) Concurrent Capable and Big vg Format Volume Group in AIX Unix (加強)並行能力和大蛋白格式卷組中的AIX Unix系統
- Create New Table by Selecting Data from Other Tables with CREATE TABLE AS創建新的表選取的數據來自其他表,創建表
- Cheapest Linux Box Ever最便宜的Linux方塊以往任何時候都

























