How to get all the links of a file?


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting How to get all the links of a file?
# 1  
Old 08-22-2006
How to get all the links of a file?

Hi all,
I have several links to a file. Is there any command or anyway to get all those links.

Thanks in advance

-Chanakya
# 2  
Old 08-22-2006
You can get only hard links, not symbolic
# 3  
Old 08-22-2006
ok that's fine. how to get?
# 4  
Old 08-22-2006
Login or Register to Ask a Question

Previous Thread | Next Thread

8 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Create tar file excluding all hard links

I have a problem with tar. Taring a folder with a lot of contents, causes the tar to contain hard links to some files, seen with the same name but 0 in size. The hard links don't exist in the first place. How can I prevent that from happening? I am using the -T option with either -n or... (2 Replies)
Discussion started by: Tribe
2 Replies

2. AIX

List all the soft links and hard links

Hi I'm logged in as root in an aix box Which command will list all the soft links and hard links present in the server ? (2 Replies)
Discussion started by: newtoaixos
2 Replies

3. Solaris

Hard Links and Soft or Sym links

When loooking at files in a directory using ls, how can I tell if I have a hard link or soft link? (11 Replies)
Discussion started by: Harleyrci
11 Replies

4. Shell Programming and Scripting

Using SED to print the links present in a file

i was trying to print the links present in a file using SED. sed -n 's/.*\(\(http\|ftp\|https\):\/\/\(*\).\(net\|html\)\).*/\1/gp' example content of example file is The URL for my site is: http://mysite.com/mydoc.html. You might also enjoy ftp://yoursite.com/index.net for a good... (5 Replies)
Discussion started by: Kesavan
5 Replies

5. UNIX for Dummies Questions & Answers

Showing a file's symbolic links

ls -l shows the number of links for each file. Is there a command that will show the link sources for a specific file? Running find on the entire filesystem and doing a little Perl "magic" is the only method I'm aware of. I'm running SunOS 5.8. Thanks. (6 Replies)
Discussion started by: effigy
6 Replies

6. Shell Programming and Scripting

finding links to a file

I am writing a shell script that needs to files that are links to on specific shell script. e.g. /usr/bin/a.sh /home/mydir/a.sh --> /usr/bin/a.sh /home/yourdir/a.sh --> /usr/bin/a.sh /home/hisdir/a.sh --> /usr/bin/a.sh /home/herdir/a.sh --> /usr/bin/a.sh I know I can set myself... (2 Replies)
Discussion started by: ohagar
2 Replies

7. UNIX for Dummies Questions & Answers

Listing all links in a file system

How would one find and list all links in a file system? My situation is that I built several servers for disaster recovery, mirror images of several servers in our main location. Instead of doing a "ls -l" on every file system down the /usr structor to verify that I have all the necessary links... (3 Replies)
Discussion started by: ruger14
3 Replies

8. UNIX for Dummies Questions & Answers

Symbolic Links for a File

how do i get the list of symbolic link names for a particular file programatically (4 Replies)
Discussion started by: b_u_n_1234
4 Replies
Login or Register to Ask a Question