Locate long file paths on external drive with terminal I need to move a large volume to a new raid server that's PC formatted. However I have a couple paths and filenames that are interrupting this process.

I would just like to know how to use the terminal to:


Locate the targeted external drive
Then search that drive for paths/files that are over 130 characters


Can anyone help?

I know how to search for long paths find " . -type f -name '?????...*' ", just not sure how to target my external drive.
The following command will print out all files that have more than 130 characters

find -E . -type f -regex '.*[^/]{130}'


The Terminal (bash) command to list the disks attached to the system is diskutil.  The command diskutil list will output all disks - just select the identifier that matches your external device.  

For example:

/dev/disk3 (external, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *500.1 GB   disk3
   1:                        EFI EFI                     209.7 MB   disk3s1
   2:                  Apple_HFS FreeAgent Go            499.8 GB   disk3s2
/dev/disk4 (external, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *1.0 TB     disk4
   1:                        EFI EFI                     209.7 MB   disk4s1
   2:                  Apple_HFS My Passport for Mac     999.8 GB   disk4s2


disk0, disk1, and disk2 are in a CoreStorage volume.  disk3 and disk4 are my external drivers

To access the drive (assuming it's mounted), look in the /Volumes directory for the appropriate mount point.

Assuming you wanted to search "My Passport for Mac" you would enter the command:

find -E /Volumes/My\ Passport\ for\ Mac/ -type f -regex '.*[^/]{130}'