You are here: Home » Reply » Reply To: Scanning outside of the specified directories?

Reply To: Scanning outside of the specified directories?


@EVILRipper wrote:

find /media/sda9 -type l

This should find all symbolic links within /media/sda9.
When results were found, go to the directory containing that file/folder.

ls -l

Will show where the symbolic links points at.

I know that. What I am trying to point out, EVILRipper, is the fact that no symbolic link in the directories specified as “mp3_dir” points to my home directory (“/home/alex”).


[email protected]:/tmp# grep mp3_dir /etc/mt-daapd.conf
mp3_dir = /media/storage,/media/sda9

So now let’s take a look at those two partitions.

[email protected]:/tmp# for mp3dir in storage sda9 ; do find "/media/${mp3dir}" -type l -exec ls -l {} ; >> symlinks_${mp3dir}.txt ; echo "$mp3dir: " ; grep "/home/alex" symlinks_${mp3dir}.txt ; done
lrwxrwxrwx 1 alex alex 39 2007-10-14 18:44 /media/sda9/other/___non-metal_-_non-ambient___/Vangelis -> /media/sda6/home/alex/Desktop/Vangelis/

I think it’s pretty straightforward. What I did was to create two files called symlinks_storage.txt and symlinks_sda9.txt which contain the output of that `find’ command. That `find’ finds all symbolic links in those directories and does a `ls -l’ on them. The next thing I did was to grep through the text files to search for any occurrence of “/home/alex” which is my home partition and which should NOT get scanned.

The symlink you see there, in sda9, pointing to /media/sda6/home/alex/Desktop/Vangelis, is an old and broken symbolic link. There is no /media/sda6 location on my system.

So then, why does mt-daapd scan in “/home/alex” after all?