Why don't you try like the following. Write a script and call it by cron.
ftp -i -n fserv << END
quote user raj
quote pass raj123
lcd user2
bin
cd chci
mput *.chci
bye
END
Note :
1. at raj123 you have to give the real password.
2. use absoulte path name at cd & lcd. Ex: lcd /home/user2...
The very simple method, I follow is
last shutdown | sed -n 1,1p
last reboot | sed -n 1,1p
execute the above two commands as script. Most of the time it works. ( I have to calculate the hours and minutes, Calculating inside a script is a big headache(!)
Raj.
I think this is not the answer for your query. Just a point. Use "Audit" facility of AIX. But I am sure that you'll be tired to monitor all the events.
hello,
use this script if you are comfortable.
ext=`date +%d%m%C%y`
for i in /home/*
do
fn=`echo $i | cut -f4 -d '/'`
mv $i /home/aaa/$fn.$ext
done
Note: it will move all the files from the home directory. If you want to move only specific files, give it in the "for loop" or store...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.