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

find -name problem

Posted on 2007-12-03
Last Modified: 2010-04-20
When I do:

find -name FileName.txt

from the root of my box, I get output like this:

find: ./fld1/fld2/fld3/fld4/fd: Permission denied
find: ./fld5/fld6/fld7/fld8/fd: Permission denied

There are a lof of lines like this. How do I get information only on folders to which I have permission?
Question by:mfarid1
LVL 45

Accepted Solution

Kent Olsen earned 50 total points
ID: 20397784
Hi mfarid1,

redirect the errors to null..

find / -name FileName.txt 2>/dev/null

Good Luck,
LVL 40

Expert Comment

ID: 20400613

You may:

1- run the find command as root (if you are the administrator of the m/c)



find / -name FileName.txt > /tmp/results.$$ 2>&1
grep -v "Permission denied" /tmp/results.$$ | more

Expert Comment

ID: 20401505
its quite better if u run the command with administrative priviledges or run the command with current directory option after moving into directory

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

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

SSH (Secure Shell) - Tips and Tricks As you all know SSH(Secure Shell) is a network protocol, which we use to access/transfer files securely between two networked devices. SSH was actually designed as a replacement for insecure protocols that sen…
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

860 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