www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2010/02/06/00:20:28

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-2.0 required=5.0 tests=BAYES_00,SARE_MSGID_LONG40,SPF_PASS
X-Spam-Check-By: sourceware.org
MIME-Version: 1.0
In-Reply-To: <27474697.post@talk.nabble.com>
References: <27474697 DOT post AT talk DOT nabble DOT com>
Date: Fri, 5 Feb 2010 23:20:10 -0600
Message-ID: <6910a61002052120m64fa1e6erafbcaef7543e9f62@mail.gmail.com>
Subject: Re: Slow manipulation of network-shared files
From: Reini Urban <rurban AT x-ray DOT at>
To: cygwin AT cygwin DOT com
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

2010/2/5 Chap Harrison:
>
> This is wordy but I've tried to make it clear :-)

Its completely clear, thanks.

> I have a Perl app running in Cygwin 1.7.1, whose job is to monitor the log
> files being written by a Java program on another Windows Server 2003 box
> elsewhere on the LAN. =A0(I'm using the CPAN File::Tail module, which pro=
vides
> 'tail -f' functionality, to monitor the log.)
>
>
> The actual I/O is fine. =A0File::Tail responds very quickly to new data b=
eing
> written by the Java program to the log files in the shared folder on the
> LAN.
>
> The Perl app watches for log messages from the Java program that say, in
> effect, "I just closed file foo.txt". =A0It then moves foo.txt into anoth=
er
> directory.
>
> However, it is frequently the case that the Perl program cannot move
> (File::Move) the file - sometimes even after trying 5 times at one-second
> intervals. =A0My suspicion is that the file is slow to be seen as officia=
lly
> "closed" by all interested parties.

Correct. Closing or deleting a file is insanely from by the windows
kernel side,
compared to other systems.
I usually have to wait 30ms until I can move the file away.

> And even when the Java program has halted, and has presumably closed all =
the
> files it created, but has not yet been "Quit" from the GUI, the Perl prog=
ram
> is glacially slow to move the remaining files. =A0What's more, at this po=
int
> any other bash shells I'm running in Cygwin become almost completely
> unresponsive, even just moving the cursor.

5s looks more like a race. But I have no idea what could cause the race.
Could be that Java is still holding the handle until the gc frees it.
But I have
no idea about java, only lisp.

> When I quit the Java app from its GUI, everything instantly returns to
> normal.
>
> I'm guessing this has something to do with concurrency control over
> network-shared resources (the output files Java wrote and I'm trying to
> move).
>
> Just to add another layer of complexity, the Cygwin host OS (WinServer 20=
03)
> is running as a virtual machine hosted by a real box running WinServer 20=
03
> and Virtual Server 2005.
>
> Any explanations, solutions, or workarounds?
>
> Thanks,
> Chap
--=20
Reini Urban
http://phpwiki.org/           http://murbreak.at/

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019