The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
.
google unix.com



UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
while loop and delay asadlone Shell Programming and Scripting 5 06-22-2007 02:05 PM
Delay a process. ugp High Level Programming 2 03-08-2006 11:00 AM
end-end packet delay? yogesh_powar IP Networking 4 12-13-2005 01:21 PM
Introducing Delay less then a second. S.Vishwanath High Level Programming 3 06-14-2004 06:10 AM
Login Delay SmartJuniorUnix UNIX for Dummies Questions & Answers 1 03-27-2001 12:38 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 01-04-2002
buRst
Guest
  
 

Posts: n/a
Bits: 0 [Banking]
Delay in mv

Working on AIX 4.3
I have an active exe that accepts files for processing on our RS6000. Day to day i store these files in a secure place and at the end of the day I mv them one by one. After some reading and ofcourse trial and error i figured out that this helps...

mv `ls -l |head -l | awk '{print$9}'` /dir1/dir2

Did not realize that by doing this I clogged my input to the exe to a great extent.

Q is , is there a way that i can put a 5 minute delay between moving each file?

wud appreciate any input

thnx
  #2 (permalink)  
Old 01-06-2002
TioTony's Avatar
TioTony TioTony is offline Forum Advisor  
Bit Pusher
  
 

Join Date: Oct 2001
Location: Southern California
Posts: 332
You could try something like this:

#!/bin/sh
files=`ls -l |head -l | awk '{print$9}'`
for i in $files
do
mv $i /dir1/dir2
sleep 600
done
  #3 (permalink)  
Old 01-13-2002
buRst
Guest
  
 

Posts: n/a
Bits: 0 [Banking]
Thnx TToni,
I did have to change it a bit since all the hidden files were being moved too.. but the general layout helped..
thnx once again
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 02:17 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0