rharvey Posted June 28, 2009 Share Posted June 28, 2009 Looks like I did not fully understand the mover function and split level within a share. As a result many of my DVD rips got spread over serveral drives, crap. I only discovered this attempting to trouble shoot a freezing problem where movie playback would halt for about 20 seconds then resume like normal. Well that was when the player was looking for the next VOB file and the drive it was on had spun down. So now that I have it figured out I need to move a bunch of files around to get ALL the files for each movie in the same folder and on the same drive. I have nearly 1000 movies so finding the movies that got split up like this is no easy task. So is there a Unix command that I can enter that will scan all my drives and show me duplicate folders....? That would sure make this faster... Quote Link to comment
jupilerman Posted June 28, 2009 Share Posted June 28, 2009 I had that problem and I solve it by only ripping my DVD in ISO file. You can also make a share (let's name it "DVDrip") that will use only one disk for such purpose. That way, all your files will be on the same disk. Quote Link to comment
rharvey Posted June 28, 2009 Author Share Posted June 28, 2009 Well I solved the problem by setting the split level for the share called "Movies" to 2. Now when the mover kicks in and pushes the filles into the array and off the cache drive they end up all in the same folder and on the same drive. Any thoughts on an easy way to find duplicate folder names on 11 drives....? Quote Link to comment
Joe L. Posted June 29, 2009 Share Posted June 29, 2009 Any thoughts on an easy way to find duplicate folder names on 11 drives....? Try this (cut and paste it to a telnet prompt): find /mnt/disk* -type d -print | sed -e "s/\/mnt\/disk[0-9]\+//" | sort | uniq -c | grep -v "^ 1" The "find -type d" will print the names of all the directories on each of the /mnt/disk* disks. The "sed" script will remove the leading /mnt/diskNN from each of the resulting directories, leaving the remainder of the directory path. The "sort" will sort the resulting lines (at that point, if a folder exist on multiple disks, it will be listed twice or more in succession in the list.) The "uniq -c" will print unique lines, but with a "count" of the occurrences in the first 7 character positions in the output. The "grep -v "^ 1" will print those lines that do not start with six spaces followed by the digit 1. Those folders only occur on one disk. What will print are those that exist on more than one. Simple, yes? Joe L. Quote Link to comment
rharvey Posted June 29, 2009 Author Share Posted June 29, 2009 Holy crap Joe, you're not only one of the best UNIX guys on the planet but you're also so willing to share information and in such detail that it's beyond compare. You rock... Quote Link to comment
nate1749 Posted July 4, 2009 Share Posted July 4, 2009 Very impressive, thanks for breaking out the specific functions of the command as well =) Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.