Re: Help needed with '-e' operator



On Wed, Jul 8, 2009 at 6:57 PM, John Refior<jrefior@xxxxxxxxx> wrote:
On Wed, Jul 8, 2009 at 7:34 AM, Anu P <anurao_123@xxxxxxxxx> wrote:

I am trying to use the '-e' filetest operator and encountered some wired
behavior.
I have a tar.gz file which is around 2.6 G and this is the code...Tar.gz
file is in the same directory where script is executed.

unless (-e $file) {
print ("ERROR: $file does not exist\n");
exit(1);
}

This does not seem to work..I always get "File does not exist" message.
I also tried out with a small tar.gz file which is around 2K and that seems
to work. so I am not sure if the usage of '-e' operator has limitation with
file size.

It's a long shot, but I notice that you say "tar.gz" in one place, and
"Tar.gz" in another place. Maybe that's intended as a new sentence, and
that's why it's capitalized, I'm not sure with the three-dot ellipsis there.
The point is: make sure you have the right case. "tar.gz" is not "Tar.gz".

Good point. And also notice that the error message that you are
getting "File does not exist" is not the same as what is supposed to
print, "ERROR: foo.tar.gz does not exist", if $file="foo.tar.gz".

Good luck and do let the list know what you discover.

Regards,
- Robert
.



Relevant Pages

  • Re: Sound file
    ... Hey< checked that out without any luck. ... Click to select the Disable script debugging check box. ... >> click on the html file we get an error message and the wav file does ... the IE settings for all three ...
    (microsoft.public.windowsxp.accessibility)
  • Re: Script problems via GPO
    ... I have tried both on user and computer config but with no luck, ... > Are you deploying the script on the computers side or user side of the ... >> the same commands in the one script but with the same error message. ...
    (microsoft.public.win2000.group_policy)
  • Re: Form Security
    ... After all this, if no error message has been generated, the form contents are emailed to me. ... I'm no Linux guru, so I don't know what someone could do to cause problems with this script, other than spam me. ... What he's proposing is false security - which is worse than no security ...
    (comp.lang.php)
  • RE: Cannot Edit Logion Scripts
    ... remove the script that you would like to edit. ... Please capture a screenshot of the error message received on the client ... Microsoft Online Newsgroup Support ... This newsgroup only focuses on SBS technical issues. ...
    (microsoft.public.windows.server.sbs)
  • Re: Sound file
    ... There shouldn't be any problems in the limited user accounts. ... The only other problem just about has to be with the attaching of the .wav ... > Common script errors messages can be eliminated by Clicking: ... >> click on the html file we get an error message and the wav file does ...
    (microsoft.public.windowsxp.accessibility)