LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-17-2005, 09:00 PM   #1
cdnsupra
LQ Newbie
 
Registered: Dec 2005
Posts: 5

Rep: Reputation: 0
`find' command


Hi guys, This is my first post, so obviously, the question is going to be very noobish.

i was trying to locate if MySQL is installed on a new server i am in the process of setting up. I typed

find `*mysql*'

thinking it would return all files matching that criteria. instead, all i got was a "<" less than sign for a command prompt. I have tried typing in exit, and quit, but it just returns with another "<" less than sign.

My question is how to escape this "<" less than environment and get back to my [root@------ /] command prompt.

Thanks in advance.
Ben a.k.a. CdnSupra
 
Old 12-17-2005, 09:13 PM   #2
edcutis
Member
 
Registered: Jun 2003
Location: USA, Missouri
Distribution: mandriva , Kubuntu, MEPIS
Posts: 140

Rep: Reputation: 15
ctrl c will end it.
 
Old 12-17-2005, 09:24 PM   #3
cdnsupra
LQ Newbie
 
Registered: Dec 2005
Posts: 5

Original Poster
Rep: Reputation: 0
thanks. that's how new i am to this, but i am not afraid......or should i be.

BTW, what was that ">" telling me? Is that linux's way of saying it is thinking/working/processing?
 
Old 12-17-2005, 09:45 PM   #4
Dark_Helmet
Senior Member
 
Registered: Jan 2003
Posts: 2,786

Rep: Reputation: 374Reputation: 374Reputation: 374Reputation: 374
The '>' character is the prompt for a multi-line command. If you typed your command in exactly as you posted it in your message, you confused the shell. The backtick (`) and the single quote (') both have different meaning, and are not interchangeable. For what you were trying to do, you want to use two single quotes or two double quotes. You were also missing an option to find. You should try this:
Code:
find -iname "*mysql*"
That command will look in the current directory and all subdirectories for any file/directory that contains "mysql" in the name (in any combination of lower or upper case characters). You could also do:
Code:
find / -iname "*mysql*"
That command does the same thing except the starting directory is specified (the root directory in this case: / )

Use this command to read about what find can do (some of it will probably be a little overwhelming if you aren't familiar with man pages):
Code:
man find
Now, if you're really interested, here's the reason the shell got confused. When you used an opening single quote character without a matching closing one, the shell assumes you plan to enter more text and eventually provide the closing single quote. So when you hit enter, it gave you another line to finish the command. That would continue until you supplied the expected closing single quote.

The backtick character has special meaning that isn't necessary to go into right now It's probably not what you need at the moment.

Last edited by Dark_Helmet; 12-17-2005 at 09:46 PM.
 
Old 12-18-2005, 11:13 AM   #5
cdnsupra
LQ Newbie
 
Registered: Dec 2005
Posts: 5

Original Poster
Rep: Reputation: 0
thanks.
i have been using the info command quite a lot. i will check out some of he manuals as well.

in several examples in the find command, i saw the use of the backtick with the single quote, and figured that was proper syntax, when, i guess, it is how the info files are created so they are not interpreted as quotes.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Find/grep command to find matching files, print filename, then print matching content stefanlasiewski Programming 9 06-30-2016 05:30 PM
What is the FIND command Mic Q SUSE / openSUSE 1 04-07-2005 09:08 AM
Help with FIND command please C-Royd Linux - Newbie 3 06-17-2004 03:43 PM
find command palmmjsg23 Linux - General 9 01-30-2004 10:45 PM
find command talkinggoat Linux - Newbie 4 10-05-2003 02:04 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:53 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration