mdelete power


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting mdelete power
# 1  
Old 02-17-2008
mdelete power

hi to all!

im using hp-ux 10.2

is it posible for the mdelete command to execute on the root directory if it did not find any file on the specified sub-directory?

this is my sample script

USER=root
PASSWD=root
cd /u01/app/oralog/arch
ftp -n 192.119.10.3
user $USER $PASSWD
prompt
binary
cd /u01/app/oracle/product/10.2.0/dbs/arch
mdelete *
mput *
quit


Thanks...
# 2  
Old 02-17-2008
Yep, if /u01/app/oralog/arch does not exist, the ftp script will remove all files it found in root's home dir (often /)
Safer would be to run mdelete /u01/app/oralog/arch/*
# 3  
Old 02-17-2008
the directory exist. what i mean is if it doesnt find any files in the specified directory, does this means it will automatically go to the root and delete every file inside it? (based from the script provided)
Login or Register to Ask a Question

Previous Thread | Next Thread

7 More Discussions You Might Find Interesting

1. Red Hat

Power Cut

Dear All I am using a redhat server for cdr billing and mediation device on a remote network. I am experiencing problem that I am suspicious it comes from main supply power cut at the remote site. The power supply to the remote site comes from battery charger that will be automatically switched in... (1 Reply)
Discussion started by: hadimotamedi
1 Replies

2. Shell Programming and Scripting

Help with FTP mdelete

Hi, I have some backup scripts running. They allocate the files in separated folders, according to the current day. (01, 02, 03...., 31) After 1 month, the "cycle" starts again, and the files are uploaded to the folder 01, 02... When that happens, I want the previous files to be deleted, so... (4 Replies)
Discussion started by: rafaces
4 Replies

3. UNIX for Dummies Questions & Answers

mdelete command in FTP

What I need to do is ftp some files on a remote server, but before postong the file need to delete any existing file from the path on the remote dir. I am using the mdelete command for the same as follows : open server_name user_id password prompt off ascii cd /test mdelete * IF the... (3 Replies)
Discussion started by: rohini
3 Replies

4. AIX

How to tell Power 4/5/6

I'm looking for a way - from the command line - to tell whether a given AIX system I have is a Power5, Power4 or Power6 machine - it seems like there would be an option to 'uname' but I couldn't find one. Thanks! (3 Replies)
Discussion started by: thomn8r
3 Replies

5. Shell Programming and Scripting

mdelete

Hello, I have a big problem with mdelete and I don't know further. In my shell script mdelete filename1 filename2 filename3 etc. does not delete alle files. Here's the log: -rw-r--r-- 1 root root 1 Mar 7 14:40 corrado -rw-r--r-- 1 root root 1 Mar 7 14:40... (1 Reply)
Discussion started by: killmatic
1 Replies

6. Solaris

Failed to power up

Dear expert, I have one server,in /var/adm/messages everyday present these messages: Jan 3 06:01:30 SERVERGINTING genunix: WARNING: Device /pci@1d,700000/pci@1/scsi@2,1/sd@5,0 failed to power up. Jan 3 06:01:31 SERVERGINTING scsi: WARNING: /pci@1d,700000/pci@1/scsi@2,1/sd@5,0 (sd45):... (2 Replies)
Discussion started by: fredginting
2 Replies

7. UNIX for Dummies Questions & Answers

Power Cycling

Hello Friends , I have been reading some of the Sys Admin notes when i came across a term "Power Cycling" Can anybody please explain what this means Thank You (1 Reply)
Discussion started by: DPAI
1 Replies
Login or Register to Ask a Question