[Solved] Find command hangs my terminal session

Thread Tools Search this Thread
Operating Systems AIX [Solved] Find command hangs my terminal session
# 1  
Old 03-07-2014
[Solved] Find command hangs my terminal session

Hello every one.

I know little to nothing about AIX. Recently I have been assigned to an AIX project.

For some reason or another the find command is hanging the server.
Well it does not hand server per say, it just freezes my terminal session.

after running find, I waited up to 40 min and did not receive any output.

i've tried using it for things i know exist. It does not matter what I try to find, it always hangs my terminal session. any ideas why?

find / -name ftp.

please help, i really need this find command to work. If i cant get it to work, i need an alternative to searching all directories for a specific file.

Last edited by Don Cragun; 03-07-2014 at 03:19 AM.. Reason: Add CODE tags.
# 2  
Old 03-07-2014
Searching every directory on every file system on a server running AIX may take a while.

Do you really expect to find a file named ftp.? (The argument to the find -name primary is a filename matching pattern; not a regular expression.)
# 3  
Old 03-07-2014
Originally Posted by busi386
i've tried using it for things i know exist. It does not matter what I try to find, it always hangs my terminal session. any ideas why?

find / -name ftp.

I can only second what Don Cragun has said: it may take a while to traversse the complete filesystem (this is what you do). Not because of AIX being AIX but because of huge amounts of data taking some while to sift though. Post the output of "df -g" to see how much disk space is mounted on the system (as an indication of how long it might take to traverse the FSs).

Or try something like

find /tmp -name file-known-to-be-in-tmp

because /tmp is usually small compared to the complete mounted filespace. If this still hangs the terminal we have to look for a different explanation.

I hope this helps.

# 4  
Old 03-07-2014
it looks like that was the issue. after talking to a coworker i found out there are a couple of huge file systems that may be slowing down the find command. thx.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

[Solved] Find command is not working

Hello Friends, I have a problem about a little script, when i run the following two lines one by one on CLI then they work well: /usr/bin/mkdir `perl -e 'use POSIX qw(strftime); print strftime "%Y-%m-%d",localtime(time() - 30*24*60*60);'` find . -type f -name "fuseesb.log.*" -mtime 30... (5 Replies)
Discussion started by: EAGL€
5 Replies

2. AIX

HMC login - Command line and terminal session

Hi Admins, Just a small question - Can we have multiple session for single user on HMC. e.g. Can I have a terminal session (via IE ) and command line (ssh) at same time ?? I am not sure whether it will impact HMC system or not. So want to make sure. let me know folks. Thanks (3 Replies)
Discussion started by: snchaudhari2
3 Replies

3. Shell Programming and Scripting

[Solved] Grep within find command

Platform: AIX 6.1/ksh Question1. I want to grep for the string "CUSTOM_PKMS" in all the files in server except those files with extensions .dbf , .ctl and .dmp I started running the following command but it is taking too long because there are lots of .dbf , .ctl and .dmp files in this... (6 Replies)
Discussion started by: John K
6 Replies

4. Shell Programming and Scripting

[Solved] The SCRIPT command - Can we see the log file of a running session?

Hello. This is my situation. script .anything ls -l . ---How can I see the content of .anything using (i.e) cat .anything? If not possible can someone suggest a sequence to simulate a console-recorder to "observ" from a RUNNING script session? Thanks Paolo Please use code tags... (3 Replies)
Discussion started by: paolfili
3 Replies

5. UNIX Desktop Questions & Answers

[SOLVED] find command match pattern

Hello, I would like to ask you, how to match directory names. I need to find only directories, which are created only from numbers and doesn't include any letters. I used command find $AC_WORKDIR/work_archive/test/$dirs_years -maxdepth 1 -name \\* -print If I have dirs like 12... (3 Replies)
Discussion started by: satin1321
3 Replies

6. UNIX for Dummies Questions & Answers

[Solved] weird in find -exec command

i feel weird with this 2 command find /tmp/*test* -user `whoami` -mtime +1 -type f -exec rm -f {}\; find /tmp/*test* -user `whoami` -mtime +1 -type f -exec ls -lrt {}\; the first one return correct which only delete those filename that consist *test* where second command it listed all the... (12 Replies)
Discussion started by: lsy
12 Replies

7. Shell Programming and Scripting

How to Capture a Unix Terminal Session?

Hi All, I want to capture all the operations performed in the terminal. So to achieve this I used “script” command. This works as I expected. But this command captures all the standard output which is redirected to terminal. For example if i “tail” a file, even the tail output is getting... (2 Replies)
Discussion started by: kalpeer
2 Replies

8. UNIX for Dummies Questions & Answers

[Solved] Assistance with find command please

Trying to locate files less than xx days old, throughout all directories/subdirectories, but excluding certain types of directories and files. The directories I want to search all contain the same characteristic (dbdef, pldef, ghdef, etc), and there are subdirectories within that I need to... (2 Replies)
Discussion started by: Condmach
2 Replies

9. Shell Programming and Scripting

Running a script without a terminal session

I'm trying to figure out how I can run a script "myScript.sh" in such a way that if my remote network connection gets disconnected, the script doesn't stop functioning. Right now I log in, run "./myScript.sh" and watch my output get pumped to a log file for about 10 hours. Only problem is that... (3 Replies)
Discussion started by: jjinno
3 Replies

10. UNIX for Advanced & Expert Users

terminal 8/ new Xwindows session

hi everyone... simple question,,, if I open a new Xwindows session on terminal 8 would it be possible to hook my laptop to a desktop computer platformed with linux and run an alternate session from the desktop on my laptop (on terminal 8 ) ......? is this impossible, impractical or too far... (1 Reply)
Discussion started by: moxxx68
1 Replies
Login or Register to Ask a Question