Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
X-Authentication-Warning: slinky.cs.nyu.edu: pechtcha owned process doing -bs
Date: Thu, 9 Oct 2003 09:01:22 -0400 (EDT)
From: Igor Pechtchanski <pechtcha@cs.nyu.edu>
Reply-To: cygwin@cygwin.com
To: "Pensa, Pascal" <pascal.pensa@hp.com>
cc: cygwin@cygwin.com
Subject: RE: Bash extremely slow when started via task scheduler
In-Reply-To: <06CAA4D3753C53408D2CE6340B68444201D9454B@vbeexc02.emea.cpqcorp.net>
Message-ID: <Pine.GSO.4.56.0310090900330.15176@slinky.cs.nyu.edu>
References: <06CAA4D3753C53408D2CE6340B68444201D9454B@vbeexc02.emea.cpqcorp.net>
Importance: Normal
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII

On Thu, 9 Oct 2003, Pensa, Pascal wrote:

> From: Jason Tishler [mailto:jason@tishler.net]
> >Why not use cron instead?
> >
> >Jason
>
> Thank you for suggestion but it's an application server managed by
> non-UNIX 'mouse users' which may manually start the task, so it should
> be simple for them.
>
> It seems that not having an output window slows down the script
> dramatically on each 'echo'.
>
> As workaround I started the script with another bash (to access cygwin
> /dev/null) , it work just fine now but it's a bit ugly (bash forking
> bash...) so any better idea will be appreciated:
>
> Before:
>
>         bash myscript
>
> Has been replaced by:
>
>         bash -c "bash myscript >/dev/null </dev/null"
>
> I really don't know why 'echo' is behaving like this.
>
> Pascal

You could put an "exec >/dev/null 2>&1 </dev/null" at the top of the
script instead.
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha@cs.nyu.edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor@watson.ibm.com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski, Ph.D.
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"I have since come to realize that being between your mentor and his route
to the bathroom is a major career booster."  -- Patrick Naughton

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

