2

On Linux, how would I recursively traverse a variable number of shares?

  • 3
    What language. is "find . -type d" is a good start for shell scripting. –  Jul 22 '09 at 03:59
  • Are shares mounted? If not you can use smbclient. –  Jul 22 '09 at 04:33
  • You need to add more detail to the question so it actually means something :). We can guess what you mean and give you nik's answer but we don't actually know what you want yet. – James Jul 22 '09 at 15:43

1 Answers1

1

I just answered your other question.
The generic directory traversal from a point above the shares would be,

find . -type d -exec ls -ld {} \; 

This will enumerate all the directories under your base directory.

You could however, run this individually over a list of the shared directories to get separated results.

nik
  • 7,100
  • 2
  • 25
  • 30