A special type of file that references an inexistent or existing file or directory. The contents of a symbolic link consist of an arbitrary string that is the path to the file that the symbolic link points to. When the symlink is encountered during pathname resolution, the string stored by the file ...

learn more… | top users | synonyms (1)

1
vote
0answers
144 views

A program doesn't work when invoked through a symbolic link

I have an executable paraview in the directory ~/software/Para/bin/ and I want to create a soft link in my home directory. I have tried like this but could not succeed. sudo ln -s ~/software/Para/bin/...
5
votes
2answers
159 views

Using ~ in symlink target or making a symlink with a variable

I would like to create a symlink to ~/foo/ but when I write that, ~ is always resolved to the absolute home path. I've used ../s in the past and they work fine, is ~ not allowed? The reason I'd like ...
3
votes
1answer
25 views

How can you group symlinks with directories in `ls` output but tell the difference?

In ls output, I'd like to group symlinks that point to directories along with the rest of the directories, but still have a way of telling that it's a symlink either with color or an appended symbol. ...
1
vote
1answer
65 views

du space more than the disk size [duplicate]

I have a disk size of 1TB. But when I do du -hx . on one of the folders it shows 1.4TB. and df -k . shows 60% full. I dont understand why is the size shown greater that disk size itself. Thanks, ...
2
votes
1answer
641 views

rsync complains about symlinks

I'm using the dry-run (-n) option of rsync to compare directories on two different systems. Everything works fine with standard files and directories. However, when I use a directory that includes ...
7
votes
4answers
574 views

Looking for POSIX utility to test whether filename is a symlink

I know that some shells at least support file test operators that detect when a filename names a symlink. Is there a POSIX utility1 that provides the same functionality? 1 I may not be using the ...
0
votes
0answers
82 views

Deleting of whole symbolic link folder when rpm -e is ran

I am currently building an rpm for RHEL 6.6. The installation of the rpm goes great the the command rpm -Uvh foo.rpm. However I run into a problem when I do the rpm -e foo command. The problem is ...
0
votes
0answers
72 views

Linux capabilities for java to resolve symbolic links

I run a java program by a non-root user. The program has to resolve a symlink to the real file name, but the link is owned by a different non-root user. I used setcap to set capabilities to open root-...
3
votes
2answers
3k views

tar command - skip symlinks

I use the tar command as, tar -cvf protTests.tar protTests/* to tar all files inside the folder, protTests. But this is including the symbolic links inside the folder, which is not a desired one. ...
0
votes
3answers
36 views

How to make a symlink from /A to /B, from running in /C

If I'm currently in location C, can you make a symlink from /A to /B, from running in /C? Seems like I need to be in the dir I am creating the ln -s
1
vote
2answers
470 views

How to use ln -s to create a command line shortcut?

I have an sh file that I would like to be able to open from the terminal at any time. I would like to type "studio" into the terminal, and have android studio open I recall using ln -s to do this, ...
1
vote
1answer
54 views

Should I use hardlinks for my “sites-enabled” folder instead of softlinks?

Every article I find about web servers suggest creating a sites-available and sites-enabled directory within apache/nginx/etc. Then, using symbolic (soft) links, create a link from the available to ...
0
votes
0answers
13 views

Darwin acl_get_file vs acl_get_link_np

On Darwin, there are two related functions - acl_get_file, and acl_get_link_np, which both query ACL information for a file. The difference is that, a) acl_get_link_np won't follow symlinks and, b) ...
2
votes
0answers
646 views

What exactly files whose names' prefix is “AT.postflight.” are needed for?

I am not sure if this question should be asked here, since I am on an OS X, but since I am using bash, and I am asking about the meaning and the purposes of some files. I am trying to understand why ...
1
vote
1answer
66 views

linux how to cd to parent folder if navigated through a symlink [duplicate]

I have following symlink in my home directory. lrwxrwxrwx 1 mtk mtk 43 Aug 8 20:35 tripple-bit -> /media/mtk/study/Collage/docs I use the symlink to navigate to the docs folder directly. But ...
1
vote
1answer
142 views

Symlinks to directories not rendering properly through Samba

I maintain many projects at a time, and keep them all organized within a single directory, Projects. Now, keeping myself somewhat oriented necessitates the use of symlinks so as to associate useful ...
1
vote
1answer
221 views

nemo: Context Menu Action Triggering a Script that Forces the Selected Symbolic Link to be Relative

My goal is to be able to right-click a symbolic link in nemo, triggering a custom script that forces the link to be re-written as a relative path, should it happen to possess an absolute path upon the ...
0
votes
1answer
24 views

Symlinked folder cannot be opened

Can someone explain this? ls displays the symlink $ ls -l .config/blender lrwxrwxrwx 1 rain rain 29 Aug 7 13:48 .config/blender -> SpiderOakHive/config/blender/ but this fails $ ls -l .config/...
1
vote
1answer
29 views

Deny permission to move a soft link

I have a soft link that was accidentally moved as a result of a user drag/drop operation in a Filezilla UI. Is there a way to prevent a user from moving the link but leaving all other permissions ...
0
votes
0answers
29 views

ln -srf is alternating between two different linking behaviors

I'm currently working on putting my dotfiles under version control, and I'm running into a weird behavior with ln -srf. My setup consists of a directory /home/agentwiggles/Code/dotfiles, which ...
2
votes
2answers
83 views

Can files with different inum be hard linked?

I am a new Linux user learning from Arch Linux and recently Linux From Scratch (7.7). I set up a new installation of AL to be my LFS host; I manually (and also with the provided bash script) checked ...
1
vote
2answers
154 views

Unix equivalent of smart folders

What I want to do is present a directory, the contents of which are sourced from a series of other directories on the file system. It would be like a soft-link, only a link to multiple directories at ...
25
votes
2answers
1k views

Why does ln -s accept a single argument

> cd /tmp > ln -s foo > ls -alhF /tmp lrwxrwxrwx 1 user user 3 Jul 29 14:00 foo -> foo Is this a bug in ln or is there a use case for symlinking a file to itself? This is with ...
0
votes
1answer
249 views

Elegant Way To Store Dotfiles on GitHub

I need an elegant solution to store my dotfiles on GitHub for easy access. I tried to create a dotfiles directory and symlink all the dotfiles into there. Then I tried adding the symlinks to git and ...
3
votes
3answers
2k views

Symbolic link creation failing: change ownership issue

I am facing some issue with creating soft links. Following is the original file. $ ls -l /etc/init.d/jboss -rwxr-xr-x 1 askar admin 4972 Mar 11 2014 /etc/init.d/jboss Link creation is failing with ...
3
votes
1answer
57 views

Use symlink to move directory created by .deb package - will anything break?

Sometimes it seems useful to shift package's directories around between tmpfs / flash memory or ssd / hard disk. To manage flash lifetime, disk spin-up, or just free space. If you replace a ...
0
votes
1answer
53 views

Does Linux have any symlinks by default? [closed]

I have written a program that performs health checks on servers. One of its functions is that it can check whether or not a symlink exists. I am currently in the process of writing unit tests (for use ...
0
votes
2answers
44 views

Best practice to mount directory in /home to directory in /media?

I have 4 drives on my home server. 3 external drives mounted in fstab to three individual directories in /media. The fourth drive contains a headless debian os install. I want to mount a directory in ...
3
votes
0answers
222 views

Debian: How to resolve relocation error?

I am running Debian 7.1. I tried to apt-get install -f, and messed up. All command line returns ln: relocation error: /lib/arm-linux-gnueabihf/libc.so.6: symbol _dl_find_dso_for_object, version ...
-2
votes
2answers
48 views

How to find only the name of a link? [closed]

Specifically, I need to write a C program where I put inside the pathname of a symbolic link and on output I print only the name of that symbolic link(not the name of the file pointed by the link). ...
0
votes
1answer
421 views

sym link for android-studio/bin/studio.sh

I tried creating a symbolic link for android studio as such sudo ln -s android-studio/bin/studio.sh /usr/bin/asw I chose asw as the keyword to hopefully launch the executable studio.sh from anywhere ...
2
votes
1answer
90 views

Can see file in /usr/local/bin with ls, but attempting to run it yields file not found?

I'm on OS X, but since this is terminal work I figured this was the best place to ask. I'm trying to get Sublime Text to work at the command line via subl and having no luck. I ran ln -s <location ...
1
vote
2answers
1k views

Is it possible to create a virtual directory in Linux?

Like this way in Windows mklink /D Virtual_Folder_Here Real_Folder_Here. I was unable make work alias in Apache virtual sites in Windows so I made a virtual directory. Is this possible in Linux too?
0
votes
1answer
67 views

Creating an symbolic link in /bin automatically creates a second link in /usr/bin and the which command chooses /usr/bin

I just created an executable: ln -s /path/to/script.sh /bin/script then I check if everything succeeds and it does(/bin/script is created) but this has also created: /usr/bin/script and if I ...
5
votes
2answers
202 views

What is the difference in file size between Symbolic and Hard links?

I plan to keep all my movies in one giant folder, and then create other folders for the genres, while creating links for all the movies in the genre folder. This way I can organize movies into ...
0
votes
2answers
57 views

Asterisk behaviour in creating links

I am trying to create symbolic links for a set of files. Suppose I want to link all the files with the pdf extension from an origin_directory to my present directory. Up to now I have this command: ...
2
votes
1answer
73 views

Creating deep symlink

Some python packages has the following structure: python code in /usr/shared/pyshared/lib_name and symlinks on python sources in /usr/lib/python2.x/dist-packages/lib_name. However, lib_name in /usr/...
3
votes
2answers
723 views

How do you add a bash script to your PATH variable using symlinks?

I run a gaming server called PocketMine. So basically I have a folder in my home directory that has a bash script to run the server: ~/PocketMine/start.sh Everytime I want to run the server I either ...
0
votes
2answers
643 views

Adding a new directory to PATH vs. a symlink for directory already in PATH

In setting it up so I could execute Sublime Text from bash, I discovered two methods of doing this via different tutorials: Method 1) Create a symlink from /usr/local/bin/subl to Sublime's bin dir: ...
1
vote
1answer
38 views

Creation of symlinks

I am following the tutorial http://www.olindata.com/blog/2013/12/building-ha-cluster-openvz-drbd-heartbeat-and-pacemaker. I got up to here: symlink folders in /var/lib/vz to /etc/vz The /etc/vz has ...
2
votes
1answer
629 views

Samba does not show symlinks

I am using samba under ubuntu 14.04 and I try to share a folder which includes a symlink to a directory that lies on an external drive. If I access the samba share from other devices (like android ...
2
votes
1answer
185 views

Duplicity include/exclude directories & symlinks

I'm trying to configure Duplicity to perform a system-wide settings backup. Among other things, I'd like to backup settings in /etc/portage/, the file /usr/src/linux/.config and the KDE autostart ...
9
votes
1answer
8k views

Create symlink - overwrite if one exists

I want to take down data in /path/to/data/folder/month/date/hour/minute/file and symlink it to /path/to/recent/file and do this automatically every time a file is created. Assuming I will not know ...
1
vote
2answers
59 views

Moving 4 system folders to 1 separated partition

Some background: I have installed Linux Mint 17 Cinnamon on my laptop SSD on a 10GB formatted partition and i have another HDD with 75GB, both ext4 formatted. The question part: I have two partitions ...
1
vote
1answer
37 views

Strangeness with Symlinks and Relative Paths

Could someone please explain this to me? I'm having trouble understanding how this is set up and why it behaves the way it does. I wanted to see where zsh is actually installed on a machine that I ...
3
votes
1answer
1k views

'Docker' File System - Compatibility with Symbolic Links

The question is marked in bold if you wish to skip the explanation of our situation. I work as a developer for a server network. We deploy multiple instances of our servers. we have 5 types of server ...
3
votes
2answers
96 views

List direct symbolic links (links that don't point to another symlink)

I need to make a list of all direct symbolic links in a directory, i.e. symbolic links that point to another file which is not a symbolic link. I tried to do it this way: for i in $(ls -1A); do ...
11
votes
2answers
1k views

How does the /proc/<pid>/exe symlink differ from ordinary symlinks?

If I start a process and then delete the binary of it, I can still recover it from /proc/<pid>/exe: $ cp `which sleep` . $ ./sleep 10m & [1] 13728 $ rm sleep $ readlink /proc/13728/exe ...
3
votes
1answer
2k views

Getting “Protocol Error” when trying to create a symlink in Docker

I'm trying to setup a symlink, using the command ln -s /var/www/data/cache/widget/overlay/ /var/www/public_html/images/overlay but it outputs ln: failed to create symbolic link '/var/www/...
1
vote
1answer
42 views

Map Home to External Drive

Whereas I have my OS (in this case, Elementary OS Freya) installed on my non-partitioned internal hard drive, I have an external hard drive with /Documents, /Downloads, /Movies etc. where I store all ...