Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

How to find all files with the same name?

New to Debian (Or Linux in general)? Ask your questions here!
Post Reply
Message
Author
quaxth
Posts: 7
Joined: 2013-09-27 13:16

How to find all files with the same name?

#1 Post by quaxth »

As the title say!

I like to get all files named php.ini listed with their locations. What command I've to use on Debian 8 and 9?

I was 'play' around with find and ls but that didn't give me any result. I've to admit, I'm not more than just a novice in Linux.

Thanks for any help.

User avatar
GarryRicketson
Posts: 5644
Joined: 2015-01-20 22:16
Location: Durango, Mexico

Re: How to find all files with the same name?

#2 Post by GarryRicketson »

Code: Select all

man locate

User avatar
acewiza
Posts: 357
Joined: 2013-05-28 12:38
Location: Out West

Re: How to find all files with the same name?

#3 Post by acewiza »

Alternatively, I might issue a command something like this starting in for example, the current directory(.):

Code: Select all

find . |grep flename
Nobody would ever ask questions If everyone possessed encyclopedic knowledge of the man pages.

User avatar
GarryRicketson
Posts: 5644
Joined: 2015-01-20 22:16
Location: Durango, Mexico

Re: How to find all files with the same name?

#4 Post by GarryRicketson »

That is a good alternative, in fact there are so many ways, if you want to explore
all of them, then decide what works best for your situation:
On a linux system How to find all files with the same name?

Post Reply