![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| check if remote file exists | hcclnoodles | Shell Programming and Scripting | 2 | 08-27-2008 05:53 PM |
| check if file exists in a mounted windows shared folder | jul | Shell Programming and Scripting | 2 | 05-14-2008 01:50 AM |
| Check File Exists and compare to previous day file script | rbknisely | Shell Programming and Scripting | 3 | 02-07-2008 11:53 AM |
| check if file exists on remote system ? | hcclnoodles | Shell Programming and Scripting | 2 | 10-26-2006 04:08 AM |
| check if exists a .ZIP file and unzip it using ftp | DebianJ | Shell Programming and Scripting | 1 | 05-05-2005 04:46 PM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
I have a perl script that ftp's to an NT server, checks if the file is growing, gets the file, does some more size checking after the get on the unix box. My question, is there a good way to check if the file exists on the NT when I know the exact file to check for? I thought about doing an "ls file.dat" and passing the return code to a variable and then checking the varible, but that seems kinda messay. Thanks in advance for any suggestions.
|
|
||||
|
Thanks for the info. I came up with this as I continued to pound away at it.
next if (($fsize = $ftp->size($ntfile)) == undef); I have to check the file size anyway, if the file does not exists return value of size is undefined. The "next" is used to take me back to the previous loop before executing any commands that may follow this statement. |
| Sponsored Links | ||
|
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|