gnumed-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnumed-devel] Problems dumping database (Mac limitation on su -c)


From: Karsten Hilbert
Subject: Re: [Gnumed-devel] Problems dumping database (Mac limitation on su -c)
Date: Sun, 29 May 2011 23:29:23 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

On Fri, May 27, 2011 at 08:27:06PM -0700, Jim Busser wrote:

> >>    Initiating a postgres db user step…
> >>    < here there may, or may not, come a prompt>
> >> 
> >>    Initiating a GNUmed db owner (e.g. gm-dbo) step…
> >>    < here there may, or may not, come a prompt>
> >> 
> >>    Initiating a GNUmed db owner (e.g. gm-dbo) step…
> >>    < here there may, or may not, come a prompt>
> >> 
> >> because by the above method, when no prompt is received, the user attends 
> >> only to the last line.
> > 
> > This would render the script less useful to cron/anacron.
> 
> I am not sure I understand. Echos would, to my understanding, not interrupt 
> cron or anacron … 

Oh, whenever a script run by cron/anacron echos something a
mail will be sent to the user.

> Consider that, as currently written, the script will already in some 
> situations echo to stdout for example
> 
>       echo "Backing up database ${GM_DATABASE}."
>       echo "However, a newer database seems to exist:"
>       sudo -u postgres psql -l -p ${GM_PORT} | grep gnumed_v
>       echo "Make sure you really want to backup the older database !" 
> 
> so we are maybe just talking your (more-useful?) versus my proposed 
> (less-justifiable?) echos?

I think your suggestion is entirely justifiable. However,
the script is intended to be run by cron.

I do want to see the above when the script is running automated.

The way the script is written now we cannot differentiate
the steps at which which prompt may appear.

> When you wrote
> 
> >     we are getting into the realms of telling doctors to
> >     consider pain killers should the patient be in pain.
> 
> it maybe betrays a bias for the level of user for whom any
> echos are being writen. We are here talking, in the absence
> of .pgpass, up to four password prompts, only *one* of which
> informs what is being asked for. We know these confuse
> people who bother to email. If people like me with marginal
> IT are of value to the project, we should reduce where easy
> (and what I suggested was easy) so that I and others can
> more easily avoid a dozen + unnecessary efforts and lost
> time to figure out where I was going wrong.
> 
> If the above was sufficient to cause reconsideration, I
> can pull out from this thread (and resupply) your
> clarifications for these things which – to you – seem
> not worth the trouble but which, to me and others like me,
> a re very much worth those echos.

We can surely add those echos, say commented out, so they
can easily be activated for debugging.

However, we'd have to rewrite the script to *allow* us to do
so. And I honestly don't even know how to do that !

Karsten
-- 
GPG key ID E4071346 @ gpg-keyserver.de
E167 67FD A291 2BEA 73BD  4537 78B9 A9F9 E407 1346



reply via email to

[Prev in Thread] Current Thread [Next in Thread]