Symlinks Flashcards

(4 cards)

1
Q

What is the difference between hard links and symbolic links?

A

Hard links:
- are tied to specific psychical devices
- cannot reference folders
Symlinks can do all of above

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How to find what file is being linked to with hard links?

A

ls -i

prints inode identified of a file, which is same for original file and all links pointing to it

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

How to create hard link and symbolic link?

A

Hard link: ln file linkname

Symlink: ln -s file linkname

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

How to find if a file is a symbolic link?

A

ls -l
lrwxrwxrwx
l stands for symbolic link

How well did you know this?
1
Not at all
2
3
4
5
Perfectly