Solved

Find all the executable files in unix inside the directory and all sub directories

Posted on 2010-11-08
4
389 Views
Last Modified: 2012-05-10
I need to Find all the executable files in unix inside the directory and all sub directories
0
Comment
Question by:sobeservices2
[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
  • 3
4 Comments
 

Author Comment

by:sobeservices2
ID: 34089556
Oh I then need to find the unique file names

0
 

Author Comment

by:sobeservices2
ID: 34089561
I was able to figure out ls -RF will give me the executable  that are denoted by a star.

Then I need to take the ones denoted by a star out and list them
how would I do this in a script

0
 

Accepted Solution

by:
sobeservices2 earned 0 total points
ID: 34089655
OK I figured the whole thing out on my own here is my solution

ls -iRF fileLab
ls -iRF fileLab | grep '*'
ls -iRF fileLab | grep '*' | sort -u
ls -iRF fileLab | grep '*' | sort -unk 1
ls -iRF fileLab | grep '*' | sort -unk 1 | awk '{print $2}' 
ls -iRF fileLab | grep '*' | sort -unk 1 | awk '{print $2}' |sort -u
ls -iRF fileLab | grep '*' | sort -unk 1 | awk '{print $2}' |sort -u | tr -d '*'

Open in new window

0
 
LVL 48

Expert Comment

by:Tintin
ID: 34090753
The more standard way of doing this is

find  fileLab -type f -perm /111 | awk -F/ '{print $NF}' | sort -u
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Introduction Regular patching is part of a system administrator's tasks. However, many patches require that the system be in single-user mode before they can be installed. A cluster patch in particular can take quite a while to apply if the machine…
Over the years I've spent many an hour playing on hardened, DMZ'd servers, with only a sub-set of the usual GNU toy's to keep me company; frequently I've needed to save and send log or data extracts from these server back to my PC, or to others, and…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

717 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