Solved

Search for specific file or text on an external mapped drive

Posted on 2013-12-06
7
419 Views
Last Modified: 2013-12-08
I am looking for a script or command to search for specific text which is either in a file name or within documents, however it's on a mapped external drive on a MAC.
0
Comment
Question by:100questions
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
7 Comments
 
LVL 30

Accepted Solution

by:
Britt Thompson earned 500 total points
ID: 39702440
You need to add the mounted drive to the search results list in your spotlight preferences so it will index the share. Then, you can search using Spotlight.

If you require a script you can just use grep -lir "search string" /path to search for files with the search string.
0
 

Author Comment

by:100questions
ID: 39702483
How do I find out what the path is of the mapped external drive?
0
 
LVL 30

Assisted Solution

by:Britt Thompson
Britt Thompson earned 500 total points
ID: 39702484
you can open the terminal and type ls /volumes and see a list of all the drives. Or, you can drag the volume into the terminal window for a correctly formatted path (you can also drag specific folders from the volume to search into the terminal window for the full correctly formatted path).
0
Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

 

Author Comment

by:100questions
ID: 39702503
This is an external drive connected wirelessly, and it's showing up under the SHARED heading in finder.

When I try to drag it to the Terminal Window nothing happens, and when I type ls/ volumes, that drive is not listed.
0
 
LVL 30

Assisted Solution

by:Britt Thompson
Britt Thompson earned 500 total points
ID: 39702511
Ah, i forget you always have to show the drive on the desktop. If your finder preferences and check to show connected servers you will have a drive that shows up on the desktop.

screen cap
Then, you must actually go the item that shows under the shared list and actually open the share before the disk will mount on the desktop. IE, go in there and look at the list of files.

Then, you can drag the disk from the desktop into the terminal window. As it stands now, you're not actually connected to the share on the device.
0
 

Author Comment

by:100questions
ID: 39702567
Thanks. I tried this, however how do I know it's searching?  Does it take a while?
0
 
LVL 30

Assisted Solution

by:Britt Thompson
Britt Thompson earned 500 total points
ID: 39702571
Yes, it will take some time and start listing files it finds. How long it takes depends on the speed of the connection and the number of files.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Thoughts on PC Doctor 11 87
looking for a used mac that has 32gb 8 57
Want to Create 3rd Operating System via Bootcamp 2 24
Merge Numbers file with CSV file 3 11
Syslogd is a utility that traps and logs messages sent by running processes. It is configured with the syslog.conf file, which consists of lines containing a pair of fields: "the selector field which specifies the types of messages and priorities to…
There is a security feature on iOS devices that is nearly impenetrable when it has been activated.  This article will provide some possible solutions as well as necessary steps to take to ensure you do not end up with a locked device.
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

759 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question