Tagged Questions

The tag has no wiki summary.

learn more… | top users | synonyms

1
vote
1answer
55 views

symlink /home/username/Documenten tot 2nd partition?

I am trying to make a symlink so all documents are on a different harddisk drive. I learned how to make a symlink and tried to create the desired symlink. this is the command I used in terminal: ln ...
1
vote
1answer
42 views

How do I execute a command in each subdirectory? [duplicate]

I'm using Puppet and I need to create symlinks between two folders. I have around 10 folders with the same structure and I always want to execute my link command in xx/yy/zz. Something like this: ln ...
1
vote
1answer
64 views

Why ln -s creates relative broken links? [duplicate]

I have an issue with ln -s on Ubuntu 14.04, while using it in the following scenario: $ cd ~/programming/tmux/ $ ln -s tmux ~/bin/tmux $ ls -l ~/bin/tmux lrwxrwxrwx 1 USER USER 4 sie 31 11:02 ...
2
votes
3answers
71 views

Creating symbolic links

When creating a softlink how do add the path, I did the following: ln -s file1.txt /home/user9000/Desktop/SymbolicLink.txt When I see the softlink on the desktop it marks that the doc doesn't ...
3
votes
1answer
76 views

Is there a difference between hardlinking with cp -l or ln?

I am implementing a backup scheme using rsync and hardlinks. I know I can use link-dest with rsync to do the hardlinks, but I saw mention of using "cp -l" before "link-dest" was implemented in rsync. ...
2
votes
1answer
64 views

understand the designation of symbolic links

I have a number of files in /etc/rc3.d/ directory which all are symbolic links and point to files in /etc/init.d/ directory using ../init.d/ designation. For example file S18rsyslog in /etc/rc3.d/ ...
1
vote
2answers
282 views

Symlink from one workstation to another without mount

I am trying to create a symlink of a file on one linux workstation to another linux workstation, without having to 'mount' any network shares. Here's what I am trying to do, but can't get it to work. ...
2
votes
1answer
5k views

Too many levels of symbolic links

I created this file structure: test/src test/firefox When I run this command: ln -s test/src test/firefox I would expect a symbolic link test/firefox/src to be created pointing to test/src, ...
1
vote
2answers
96 views

Do Links to /tmp files get deleted?

I have a script that creates a temp directory using mktemp -d. A folder generated in the temp directory is the output of the script that will be copied to another part of the machine. I was ...
5
votes
1answer
110 views

Is `ln` atomic and reliable on NFS? Could NFS replace GFS in this use case?

I have a cluster with a bunch of servers with a shared disk containing a GFS global file system that all nodes access simultaneously. Each node in the cluster run the same program (a shell script is ...
0
votes
2answers
228 views

ln -s with a path relative to pwd

I'm trying to create a bunch of symbolic links, but I can't figure out why this is working ln -s /Users/niels/something/foo ~/bin/foo_link while this cd /Users/niels/something ln -s foo ...
1
vote
3answers
151 views

Seemingly Inconsistent Behavior for “ln” & “ln -s”

As we all know, the ln command creates a link, with the default being a hard link and the -s option creating a symlink. The general syntax is ln [-s] OLD NEW, where OLD is the file you are linking to ...
3
votes
1answer
147 views

setgid binary doesn't have permission, mount's right, I'm missing something, but what, please?

I'm sorry, I know this has to be something simple but I've checked the manpages, the mount, the permissions ... (edit: combined history into one sequence as requested. Starting to seem a not-simple ...
2
votes
2answers
41 views

alias for 'emacs /usr/local/nagios/etc/objects'

I'm trying to get the following working: alias banana='emacs /usr/local/nagios/etc/objects/' So i want to just type "banana firewall.cfg" to edit this ...
3
votes
2answers
154 views

Is there way to replace value of symbolic link? [duplicate]

Is there way to replace value of symbolic link? For example I want to replace symbolic link like this: first -> /home/username/foo/very/long/directories/that/I/do/not/want/to/type/again to ...
16
votes
1answer
36k views

Create a symbolic link relative to the current directory

I'm trying to create a symbolic link in my home directory that points to a directory on my external HDD. It works fine when I specify it like this: cd ~ ln -s /run/media/name/exhdd/Data/ Data ...
2
votes
1answer
316 views

Why does ln -sf silently fail?

ln -sf source_file target_file succeeds even when source_file does not exist. ln -f source_file target_file on the other hand fail, as expected. How can it be tuned to give error on the first case ...
14
votes
1answer
2k views

What does ln stand for?

In Linux you can use the ln command to make links. $ touch foo $ ln -s foo foo_link $ ls -l lrwxrwxrwx 1 cklein cklein 3 May 29 16:11 foo_link -> foo I assume that the 'l' in ln stands ...
15
votes
1answer
2k views

Why are reboot, shutdown and poweroff symlinks to systemctl?

In Arch Linux, if I do ls -l in /sbin, I can see that reboot, shutdown and poweroff are all symlinks to /usr/bin/systemctl. But issuing reboot, shutdown and systemctl commands obviously does not all ...
2
votes
3answers
374 views

Forcibly create directory hard link(s)?

I understand the reasoning why nearly every unix version doesn't allow hard-linking of directories (in fact HFS+ on OS X is the only one I know, but even that isn't made easy to do yourself). However, ...
4
votes
1answer
113 views

How do I batch-export all the content contained in symbolic links? (and then delete them all)

So as an alternative to Recursive scp without following links or creating a giant tar file? (this could be an emergency since the remote files could be deleted any time soon), I'm thinking of deleting ...
5
votes
1answer
203 views

How can I synchronize all PDFs from one directory with Dropbox?

I want to synchronize all the PDFs from one directory (my Zotero library) to Dropbox. Finally, I want to have a list of all the PDFs, not the directory names. I successfully synchronized all my PDFs ...
5
votes
3answers
3k views

Why doesn't ln -s tell that it fails when creating a symlink to an existing symlinked directory?

When running (on linux different ubuntu variations): >ln -s dir_1 symlink_dir >ln -s dir_2 symlink_dir It fails without telling that it fails. But if you do the same thing on a file instead ...
2
votes
2answers
3k views

Create symbolic links with wildcards

I have multiple hard drives with the same directory hierarchy, for example: /media/sda/dir1 /media/sda/dir2 ... /media/sdb/dir1 /media/sdb/dir2 Two hard drives with similar names and similar ...
3
votes
2answers
2k views

Use `ln` to create a missing directory

So I'm writing a small package manager, and a problem I've run into is making the symbolic links to files. It installs the package to /usr/pkg/name-version, and then reads a file to determine what ...
5
votes
1answer
307 views

How to replace a symbolic link with an equivalent hard link?

Having a (single, no batch filesystem processing needed) symlink, what a command line to use to turn it into a hard link to the same file?
8
votes
3answers
2k views

How to make a symbolic link to /usr/bin/vim but with start-up parameters?

After I make&make install vim from source, I found many symbolic links of vim in /usr/local/bin, such as evim, rvim, view... The vim(1) man page said that "rvim" is equivalent to "vim -Z" and so ...
1
vote
2answers
7k views

Executable symbolic link results in “command not found”

I created a symbolic link (yesterday) like this: sudo ln -s bin/python /usr/bin/prj-python When I run: prj-python file.py I get: prj-python: command not found When I try creating the link ...