Author Topic: Issue with soft links  (Read 1342 times)

Offline EddieA

  • Newbie
  • *
  • Posts: 19
  • Karma: +0/-0
    • View Profile
Issue with soft links
« on: August 21, 2012, 06:08:21 pm »
OK, so one of the directories on a disk that I included on a new Pooled Snapshot RAID had a structure that included a bunch of soft links.  After creating everything, I went to move that particular directory to a new location, outside the pool, using mv.  I know, I should have copied, and then deleted.  Now, the soft links pointed back to files in the parent directory, so when it came to copy them, the original file was now gone.  OK, so to cut my losses, I tried to delete both the new directory and the old one, and re-create from scratch outside the pool.  This worked, no problem.

Now, I'm trying to clean up what's left on the directory in the pool, however it won't let me.  Every attempt to rm the broken links returns a "No such file or directory" error.  The actual directory listing looks a little strange also, and not how I would expect it to look with broken soft links::
Code: [Select]
ls: cannot access com.plexapp.agents.themoviedb_801866ababdb153c30703f40217c4dc7badabb65: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_e91fbe46d92e9741ce5b26ff93bc65e80efaecfc: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_61b1856c3a57ce9f1ac4759153ec9a5910e436d1: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_f61bab03dc2e5823c18304467278108612f1a173: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_660771961e50e36ba3be9bd0c84c6c3f91257999: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_4198fa28747524025584f0dfc16cb27fa707f725: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_3f473df977225ded220683e99ebe0fe59ddeed41: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_2a3ea0dff51076095e9450f743a66cb3643865d7: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_d5b7e22159341cc9043bb1fb109e3e971cc9e765: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_391345e78c44d071c3100aa2ca3006f30275a764: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_30f44ba0db37c4e733370eb88347e746a0326fcb: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_f83b45a907ed3d3d9622e7d3fce154cd7e47760d: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_3b725e137fdd1cfa81ae82d084c60f6ad5478c90: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_23e86b0e88af22f97f3c7d31e82b7098eac7855c: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_b35b8fd62741d9508ccf29b728ce17469cfa793c: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_bf7862f96b0cdce1041a1e26023037413e6a51f9: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_38775a707b3df1ff509cdf2d5c33a86378e44083: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_ab137d80153f955ad80e0990661255f34c182bb8: No such file or directory
ls: cannot access com.plexapp.agents.themoviedb_7e42979f5b7126fdb056281e624a8bf61dd62bc9: No such file or directory
total 0
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_23e86b0e88af22f97f3c7d31e82b7098eac7855c[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_2a3ea0dff51076095e9450f743a66cb3643865d7[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_30f44ba0db37c4e733370eb88347e746a0326fcb[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_38775a707b3df1ff509cdf2d5c33a86378e44083[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_391345e78c44d071c3100aa2ca3006f30275a764[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_3b725e137fdd1cfa81ae82d084c60f6ad5478c90[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_3f473df977225ded220683e99ebe0fe59ddeed41[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_4198fa28747524025584f0dfc16cb27fa707f725[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_61b1856c3a57ce9f1ac4759153ec9a5910e436d1[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_660771961e50e36ba3be9bd0c84c6c3f91257999[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_7e42979f5b7126fdb056281e624a8bf61dd62bc9[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_801866ababdb153c30703f40217c4dc7badabb65[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_ab137d80153f955ad80e0990661255f34c182bb8[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_b35b8fd62741d9508ccf29b728ce17469cfa793c[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_bf7862f96b0cdce1041a1e26023037413e6a51f9[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_d5b7e22159341cc9043bb1fb109e3e971cc9e765[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_e91fbe46d92e9741ce5b26ff93bc65e80efaecfc[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_f61bab03dc2e5823c18304467278108612f1a173[/color]
?????????? ? ? ? ?                ? [color=red]com.plexapp.agents.themoviedb_f83b45a907ed3d3d9622e7d3fce154cd7e47760d[/color]

I also tried to replicate the issue, both inside the pool and on a regular disk to see what the issue could be.

On a regular disk, I see this:
Code: [Select]
flexraid@The-Vault:~$ cat > testfile
sd
asfd
asf
flexraid@The-Vault:~$ mkdir testdir
flexraid@The-Vault:~$ cd testdir
flexraid@The-Vault:~/testdir$ ln -s ../testfile testlink
flexraid@The-Vault:~/testdir$ ls -l
total 0
lrwxrwxrwx 1 flexraid __USERS__ 11 2012-08-21 15:24 [color=teal]testlink[/color] -> ../testfile
flexraid@The-Vault:~/testdir$ cd ..

flexraid@The-Vault:~$ rm testfile
flexraid@The-Vault:~$ cd testdir
flexraid@The-Vault:~/testdir$
flexraid@The-Vault:~/testdir$ ls -l
total 0
lrwxrwxrwx 1 flexraid __USERS__ 11 2012-08-21 15:24 [color=red]testlink[/color] -> [color=red]../testfile[/color]
flexraid@The-Vault:~/testdir$ rm testlink
flexraid@The-Vault:~/testdir$
Trying to do the same within the pool gives:
Code: [Select]
zentyal@The-Vault:/MyPool/Backup$ cat > testfile
ds
asdsa
dfas
zentyal@The-Vault:/MyPool/Backup$ mkdir testdir
zentyal@The-Vault:/MyPool/Backup$ cd testdir/
zentyal@The-Vault:/MyPool/Backup/testdir$ ln -s ../testfile testlink
ln: creating symbolic link `testlink': No such file or directory
zentyal@The-Vault:/MyPool/Backup/testdir$

Would there be any issue in stopping the pool, and deleting these broken links directly.

Cheers.