How to Find Files in Linux | Learning Terminal

How to Find Files in Linux | Learning Terminal

Chris Titus Tech

5 лет назад

55,594 Просмотров

Ссылки и html тэги не поддерживаются


Комментарии:

Andrew Tate
Andrew Tate - 02.12.2022 02:29

Where to find the file?😞
After creating

Ответить
kotob
kotob - 31.10.2022 18:01

thanks Chris, I subscribed to you ;)

Ответить
Adekunle Adegbola
Adekunle Adegbola - 10.10.2022 15:36

This is fantastic. Please, I'm a beginner in the use of Linux. In my reserach, my Advisor wants me use Linux for my work. The LInux has journals database for Literatures. how do I find the database using command?

Ответить
Ed Dag
Ed Dag - 24.09.2022 14:34

Hello is Linux terminal refers to commands Prompt

Ответить
Hellscream Games
Hellscream Games - 08.08.2022 02:41

Good guide.

Ответить
J R
J R - 01.06.2022 17:30

"3-sheets to the wind" is a euphemism for being drunk. Nothing to do with not being able to find your files :-)

Ответить
Zelalem Mekonnen
Zelalem Mekonnen - 26.05.2022 04:13

cool!

Ответить
Alexander Werner Jr
Alexander Werner Jr - 16.02.2022 10:10

That's an extremely helpful and concise video, thank you!

Ответить
M!ke_y M
M!ke_y M - 14.11.2021 07:32

The terminal is awesome! :)

Ответить
TechFreak51
TechFreak51 - 17.07.2021 19:42

THANK YOU !!!

Ответить
Smelly Mala
Smelly Mala - 12.04.2021 18:37

“Till-day” as in I thought I would never find this .ttf inside my dusty old pocketchip until the day I found this channel! 🙃

Ответить
Button Man
Button Man - 12.02.2021 01:21

Thank you for the vid!

Ответить
veve rica
veve rica - 24.01.2021 15:32

how to open a folder in terminal when you do something like: /home/____/.minecraft

Ответить
Ronak Shetty
Ronak Shetty - 14.09.2020 11:12

hey all! I am looking for a csv file which I am unable to locate. Can someone please help? Thanks in advance!

Ответить
Mohammad Mostafa
Mohammad Mostafa - 28.05.2020 13:52

Very very useful commands. Thanks a lot

Ответить
Ricky Rodriguez
Ricky Rodriguez - 10.05.2020 20:45

Bro thanks so much for this info very helpful keep coming more videos

Ответить
Cuttlefish N.W.
Cuttlefish N.W. - 03.05.2020 10:22

For people who think the least amount of characters typed in terminal is best, enable globbing and use "ls **" with grep. Less optimized than find (probably, idk), but quick and useful if you're already somewhere deep in your filesystem (don't use it in root dir; it grabs every file from every subdirectory and will take hours to finish, or give up after 5 minutes).

Ответить
Cuttlefish N.W.
Cuttlefish N.W. - 03.05.2020 10:06

I've always preferred to enable globbing and use "ls ** | grep -i [stuff]" to find things, just cause I never got used to find. However, filtering by time and size does sound pretty powerful, but I'm not sure that I have a use for that. Reassuring to know that this video exists if I ever find myself needing this command! Great vid!

Edit: I realize that my preferred method probably isn't as efficient as whatever algorithms/methods the find command uses, and can probably do a full search without me having to think too hard about narrowing my search. Methods like using information directly from the system, rather than expanding my grep query into a massively clustered regex command.... I'll come back to this video the next time I lose something in my system!

Ответить
Mark G0usl
Mark G0usl - 19.08.2019 18:54

whereis DAMN! just brilliant. Never heard of that one before Very useful thanks

Ответить
Gary XH
Gary XH - 27.05.2019 23:18

Thank you, even after using Linux for 10 years and trying to puzzle out man pages (which are complete, detailed, factual, and often utterly useless), I'd given up on finding via terminal (except for executables when I can use whereis ) because I never got the command parameters right -- I'd either get no result, or the entire disk volume listed!

Ответить
Jurgen Blick
Jurgen Blick - 30.04.2019 04:17

Love your stuff

Ответить
deemon
deemon - 15.03.2019 11:48

What is the widget you use in your right bottom corner that shows core and disk usage?

Ответить
Shriniwas Kulkarni
Shriniwas Kulkarni - 20.02.2019 19:38

Awesome video on Linux "find" command. learned so much.
If you can, If possible can you make one video on Linux file system or file system hierarchy? and how it works?
Thanks for the video!

Ответить
footb 4all
footb 4all - 18.02.2019 07:24

Great,you should be mentioning mlocate command

Ответить
HewFreBie
HewFreBie - 15.02.2019 19:46

GNU/Linux or Unix-like joke:
sudo whereis cat?

Ответить
fourdotsYT
fourdotsYT - 15.02.2019 15:14

Also find a command with:
$ which <command>

e.g.
$ which mv
/bin/mv

Ответить
David Heremans
David Heremans - 15.02.2019 13:29

Chris, you should have used 'media*' between quotes.
If you had a file in your current directory named fi. 'media.jpg' then bash would have replaced your medi* with media.jpg and you would be looking only for that filename.
If you had two filenames starting with media, bash would have replaced media* with those 2 names and the find command would have thrown an error.

So I guess it is time for you to make a video talking about wildcards and globbing ;-)

Ответить
suT3
suT3 - 15.02.2019 08:40

Just wondering: why 46GB of swap?

Ответить
Anthony Rima
Anthony Rima - 15.02.2019 05:19

Congrats on 10k followers! Another great video, I'm loving these

Ответить
Theodoros Nicolaou
Theodoros Nicolaou - 15.02.2019 05:16

This is going to be so useful, thanks! Awesome video, as always.

Ответить
Sebastian
Sebastian - 15.02.2019 05:02

I see u reached 10k subs. congrats :)

Ответить
tim2060
tim2060 - 15.02.2019 03:13

Thank you! Thank you! Thank you! Thank you! Always wanted to learn this. Thank you!

Ответить
Solo B
Solo B - 15.02.2019 02:37

You're killing it Chris!! I love these kinds of videos. However, I'd like them to be a bit more detailed for beginners like me. Also, longer tutorial from you is always awesome!
Cheers.

Ответить
Lifeless web user
Lifeless web user - 15.02.2019 02:25

Can you do a video about what you think ov Richard Stallman?

Ответить
stuart
stuart - 15.02.2019 01:58

Wait. So the options only use 1 dash "-"?! I thought when the options used words it was 2 dashes "--"? Ex: `ls -h` == `ls --human-readable`

Ответить
Amelio
Amelio - 15.02.2019 00:57

Hey Chris,

From a Terminal beginners perspective i feel like you went really really fast in this video, id like to know what every bit of the command does and have time to comprehend that personally, like really overexplaining things would be helpful for it to stick in. Overall though its a wellmade video with great info, thanks :)

Ответить
Gary Williams
Gary Williams - 14.02.2019 21:37

May I ask what distro you are using for these examples? It has always been my experience that you must quote wildcarded file names to prevent the shell from expanding the wildcard (which produces unexpected results and/or errors) and allows find itself to operate on the wildcards. Are you using ~ as the starting directory because you are limiting the search to your home directory? Starting with ~ returns absolute path names relative to your home directory, starting the path name with / returns absolute path names relative to /, starting with dot (.) returns relative path names relative to current directory. This is how I learned to use find (-print is technically correct but redundant in later versions of find.)
- find all files in my home directory that start with the string 'media':
cd; find . -name 'media*' -print
find /home/user -name 'media*' -print
find ~ -name 'media*' -print
- find all files in my home directory that contain the string 'media' (use of grep is not necessary and also forks additional processes):
cd; find . -name '*media*' -print
- find all files in the file system that contain the string 'media' (you will be restricted from certain directories as an ordinary user):
cd /; find . -name '*media*' -print
find / -name '*media*' -print

If any part of my comment is incorrect or inappropriate, I apologize in advance.

Oops, to be clear ... the strings apply only to the actual file name and not to the content of the file.

Ответить
deltaskyhawk
deltaskyhawk - 14.02.2019 21:26

Thanks ... that was useful!

Ответить
Elf Bier
Elf Bier - 14.02.2019 21:18

To search for the word where in txt files.
find . -iname '*.txt' | xargs grep -i 'where' {}

Ответить
Mike McMullin
Mike McMullin - 14.02.2019 21:06

I'm assuming that find and whereis use an existing index, what is the indexer and how do you config it to grind the platters when you aren't normally using your computer?

Ответить
Ironica
Ironica - 14.02.2019 20:11

Not relative to this video but have a couple of Linux questions.


I am planning on rooting my Samsung Galaxy Tab E tablet and was wondering what Linux should I put on it (or should I keep the default and just get rid of the bloatwear)?


Also, when my daughter buys her aunt's laptop, I shall be having fun with her Chromebook and putting Linux on it. I was raised on computers and know basic programming (the logic behind programming but not the languages per say), which Linux should I install (realize it is a Chromebook so no heavy gaming on it)?

Ответить
Julian Lai
Julian Lai - 14.02.2019 19:32

Didn't you update your kernel? In Manjaro, it's 4.20.7 now.

Ответить
Patrick McLaughlin
Patrick McLaughlin - 14.02.2019 19:30

locate?


all gooy I like kfind

Ответить