public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* /bin/ gets deleted on error
@ 2017-04-13 13:59 Felipe Vieira
  2017-04-13 14:02 ` Adam Dinwoodie
                   ` (3 more replies)
  0 siblings, 4 replies; 12+ messages in thread
From: Felipe Vieira @ 2017-04-13 13:59 UTC (permalink / raw)
  To: cygwin

Dear cygwin mailing list,

For the second time this week my /bin/ folder gets obliterated on an
error during normal usage. It is equivalent of doing the infamous "rm
-rf  /bin" .

1) I would like to know if there is a log for cygwin somewhere so I
can be more useful in specifying what happened.

2) My 'specs' are: windows 7 64 bits with cygwin64 . I wonder if
cygwin64 is considered 'stable'.

From what I recall the terminal was spamming messages containing the
words "fork" , "-1" and some others which I don't recall. And what I
did was trying to run a normal zsh script.

I am not able to tell exactly what I did on both occasions to trigger
this behavior.

Nevertheless thanks for the great software. If it were not for you
guys I don't know how I could cope with Windows.

Best,

Felipe Vieira.

--
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

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: /bin/ gets deleted on error
  2017-04-13 13:59 /bin/ gets deleted on error Felipe Vieira
@ 2017-04-13 14:02 ` Adam Dinwoodie
  2017-04-13 14:03 ` Marco Atzeri
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 12+ messages in thread
From: Adam Dinwoodie @ 2017-04-13 14:02 UTC (permalink / raw)
  To: cygwin

Hi Felipe,

On 13 April 2017 at 14:13, Felipe Vieira wrote:
> For the second time this week my /bin/ folder gets obliterated on an
> error during normal usage. It is equivalent of doing the infamous "rm
> -rf  /bin" .
>
> 1) I would like to know if there is a log for cygwin somewhere so I
> can be more useful in specifying what happened.

There is no general "log for cygwin"; it's up to individual applications to log
useful information.  In this case it'd be your zsh script logging the commands
it's running and/or the output it's producing.

>
> 2) My 'specs' are: windows 7 64 bits with cygwin64 . I wonder if
> cygwin64 is considered 'stable'.

Yes, Cygwin64 is stable.

> From what I recall the terminal was spamming messages containing the
> words "fork" , "-1" and some others which I don't recall. And what I
> did was trying to run a normal zsh script.

Sadly that doesn't tell us much.  You could take a look at the FAQ entry on
fork failures, and see if that gets you anywhere.

https://cygwin.com/faq.html#faq.using.fixing-fork-failures

> I am not able to tell exactly what I did on both occasions to trigger
> this behavior.

Can you provide something to narrow down the search?  Actually giving us the
zsh script you're trying to run would be a good start!

Adam

--
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

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: /bin/ gets deleted on error
  2017-04-13 13:59 /bin/ gets deleted on error Felipe Vieira
  2017-04-13 14:02 ` Adam Dinwoodie
@ 2017-04-13 14:03 ` Marco Atzeri
  2017-04-13 14:24   ` cyg Simple
  2017-04-13 18:43 ` L A Walsh
  2017-04-19 15:20 ` Gerrit Haase
  3 siblings, 1 reply; 12+ messages in thread
From: Marco Atzeri @ 2017-04-13 14:03 UTC (permalink / raw)
  To: cygwin



On 13/04/2017 15:13, Felipe Vieira wrote:
> Dear cygwin mailing list,
>
> For the second time this week my /bin/ folder gets obliterated on an
> error during normal usage. It is equivalent of doing the infamous "rm
> -rf  /bin" .
>
> 1) I would like to know if there is a log for cygwin somewhere so I
> can be more useful in specifying what happened.
>
> 2) My 'specs' are: windows 7 64 bits with cygwin64 . I wonder if
> cygwin64 is considered 'stable'.

extremely stable


> From what I recall the terminal was spamming messages containing the
> words "fork" , "-1" and some others which I don't recall. And what I
> did was trying to run a normal zsh script.
>
> I am not able to tell exactly what I did on both occasions to trigger
> this behavior.

any history file on your home directory ?



>
> Nevertheless thanks for the great software. If it were not for you
> guys I don't know how I could cope with Windows.
>
> Best,
>
> Felipe Vieira.
>

Regards
Marco


--
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

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: /bin/ gets deleted on error
  2017-04-13 14:03 ` Marco Atzeri
@ 2017-04-13 14:24   ` cyg Simple
  2017-04-13 15:47     ` cyg Simple
  0 siblings, 1 reply; 12+ messages in thread
From: cyg Simple @ 2017-04-13 14:24 UTC (permalink / raw)
  To: cygwin

[-- Attachment #1: PGP/MIME version identification --]
[-- Type: application/pgp-encrypted, Size: 11 bytes --]

[-- Attachment #2: OpenPGP encrypted message --]
[-- Type: application/octet-stream, Size: 2619 bytes --]

-----BEGIN PGP MESSAGE-----
Version: GnuPG v2

hQEOAwrwmLWh23tcEAP7BMBPM7JQLjbZ+kRDxY1snXNRLSQdhDB2DFFpFW8mufu/
sp6AguFMzPaRDL+lI9sG7I7yzFgpD4k1ZT/KMG5rEy+auLB8JxIDwdqh1Pc9kURK
Htg7N+1o7u7p+Xqsnrhqpipvx007kCuw9Wh6zg42FfNpSN6S+GR0+AQfYW0jFsID
/iPIPd2oPKtM8Dp782FOi0Bnd90Lq5WiBSu51/lWd6haXp1taDoESTitGKsVvl2w
tZ8p6Yy07+i2jRU1M0iVWo2vU+NtryP6LVEJiqPkGrxRsapp+B3AIPaQi8i6/097
0ThRqw3hlMrTK55Z9wtFgI0/dziQ4l8jUAGxJY+mCbPVhQIMA2N7izaW4AgjAQ//
Zl6tE91p5/sdd/UWRLBUKWpbpovh41LX7JBPtyAt0ywNuIgpj3T/Gow3pKFUC1oF
dkMcZhOqi9gp4KmTMI3lJM63ulE07q2NYndpVQLqZwQuQPhqeGd42ZaLbfjRdA6s
ckhK60ykKYEbr+N+OenKbZsOFW2ha7YApNicDbsGXB9lwrzomlkPtjjGbIjR0KS8
oQWXI4xAcYOOxgdnttEn9jqyEmHVoi5j0KEA7Ye7Xn0wWl/zDHwvRCk+mcYb8xA7
G36pUFF31nXP1RumSoDxwmLUggZPDFOF88HWG4ph8rdNQQCv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eIouLpAird0AbL8hznXiVLxDA5w4kO3bCAXy08nrK
CqQmIL2nsRkfXPP17DduY6aR3yPjCIZQxDY8O/a4Jh436oK1XVte5q38aC3dfuXB
W16CvzJ63GFNJMpbtrsqU7U+9oGteyVz5sEQKHNMTkaBmrimnjLSaCd+kwCdtNnL
DvAHF56Z38MNIboRjhIfuCw30r4clVn0WfWuA4liqrXrjKWSb3XIDFN4t9QQB4KO
iQW6JyCVoNrgZbsP/z13k4JfBFXPOxeTXqPJOKOKPeEhAT0CDYOK5f+yozgMBiqh
SpVqLW5i5veemFnrixfZfqmdFXc6mvxt/dFAtOBEL7+OwoSpZA/fEhHH/A0AHvC0
c55uUniqJD9s6o7DOX+CxKLc200DLkLM3m5uJPvfu2gg3gqd06qV0N3SSL5ekRp+
vZotffeoAJAYiamsAm8X99Y+c9JT2TlJB4jaUpkHUboYO75dbAx4q+m4lyGn38t9
32Ch8BBPo8ZCpV687MAeK2xtAeKG9kvfYBUdob+pbbmPI2dTWDXlYxkNZQGDW/U3
9GSJT6chQLpP29UgOc3dr8fYXwXztHpLmRmadw/Y7peY4TmMyxePLCiBbQPH8aYo
rEsT1rMuVA83Z5UY9mH2q3waaCOgOuxkg248phNKJp2/9TPkLzV9r+qOVDbrUHmi
mdQwFe+BDQPjD7XlgFyAGzn5fhVQWctj7ZPfecRt8bnMRJOYfO1W/XTNj6ahe1Mi
uoBU
=he/T
-----END PGP MESSAGE-----

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: /bin/ gets deleted on error
  2017-04-13 14:24   ` cyg Simple
@ 2017-04-13 15:47     ` cyg Simple
  0 siblings, 0 replies; 12+ messages in thread
From: cyg Simple @ 2017-04-13 15:47 UTC (permalink / raw)
  To: cygwin

Decrypted message -

On 4/13/2017 10:02 AM, cyg Simple wrote:
> On 4/13/2017 9:29 AM, Marco Atzeri wrote:
>>
>>
>> On 13/04/2017 15:13, Felipe Vieira wrote:
>>> Dear cygwin mailing list,
>>>
>>> For the second time this week my /bin/ folder gets obliterated on an
>>> error during normal usage. It is equivalent of doing the infamous "rm
>>> -rf  /bin" .
>>>
>>> 1) I would like to know if there is a log for cygwin somewhere so I
>>> can be more useful in specifying what happened.
>>>
>>> 2) My 'specs' are: windows 7 64 bits with cygwin64 . I wonder if
>>> cygwin64 is considered 'stable'.
>>
>> extremely stable
>>
> 
> Yes, all that I use.
> 
>>
>>> From what I recall the terminal was spamming messages containing the
>>> words "fork" , "-1" and some others which I don't recall. And what I
>>> did was trying to run a normal zsh script.
>>>
>>> I am not able to tell exactly what I did on both occasions to trigger
>>> this behavior.
>>
>> any history file on your home directory ?
>>
> 
> Don't forget to check the BLODA on your system, e.g. virus protection
> software.
> 

-- 
cyg Simple

--
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

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: /bin/ gets deleted on error
  2017-04-13 13:59 /bin/ gets deleted on error Felipe Vieira
  2017-04-13 14:02 ` Adam Dinwoodie
  2017-04-13 14:03 ` Marco Atzeri
@ 2017-04-13 18:43 ` L A Walsh
  2017-04-13 18:48   ` Dan Kegel
  2017-04-19 15:20 ` Gerrit Haase
  3 siblings, 1 reply; 12+ messages in thread
From: L A Walsh @ 2017-04-13 18:43 UTC (permalink / raw)
  To: cygwin

Felipe Vieira wrote:
> Dear cygwin mailing list,
>
> For the second time this week my /bin/ folder gets obliterated on an
> error during normal usage. It is equivalent of doing the infamous "rm
> -rf  /bin" .
>   
----
    That's different.  I take it trying to restore previous copies
from the windows menu was "greyed out" and nothing was in the
recyclebin?  While it isn't likely that files deleted by
cygwin would be in the Recyclebin, you might find it in the
previous versions unless you have system protection turned off
for the disk it was on (its on a tab under "System Properties"
called "System Protection"). 


    (i.e.) in explorer browse to root & right click on /bin (if
it isn't there, create it first, either in explorer or in cmd.exe).

    If you're lucky you should see "Restore previous versions"
as an option -- which can easily allow you to restore entire
directories. (my cygwin bin is < 1GB, so it would easily fit in my 
protection-space setting of 3% (~28G).

    Even if restoring from a restore point doesn't work due to
Winbugs, the "previous versions" feature often will, as it only
targets the directories or files that you've selected and not
all system files.

    A way of, perhaps, saving some grief in the future --
create a 2nd dir "/.bin" and in it create hard-links to all of your
files in /bin.  Only downside is to keep it updated, but if it
happens again, should make restoring /bin easier...(and doesn't
use extra disk space!)






--
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

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: /bin/ gets deleted on error
  2017-04-13 18:43 ` L A Walsh
@ 2017-04-13 18:48   ` Dan Kegel
  2017-04-13 23:00     ` Brian Inglis
  0 siblings, 1 reply; 12+ messages in thread
From: Dan Kegel @ 2017-04-13 18:48 UTC (permalink / raw)
  To: cygwin

>> For the second time this week my /bin/ folder gets obliterated on an
>> error during normal usage. It is equivalent of doing the infamous "rm
>> -rf  /bin" .

What were you doing immediately before the directory disappeared?

I have only had things like this happen from user error,
e.g. scripting mistakes.

(The first time I saw somebody rm -rf / was in 1980 :-) )

--
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

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: /bin/ gets deleted on error
  2017-04-13 18:48   ` Dan Kegel
@ 2017-04-13 23:00     ` Brian Inglis
  2017-04-14 15:49       ` cyg Simple
  0 siblings, 1 reply; 12+ messages in thread
From: Brian Inglis @ 2017-04-13 23:00 UTC (permalink / raw)
  To: cygwin

On 2017-04-13 12:01, Dan Kegel wrote:
>>> For the second time this week my /bin/ folder gets obliterated on an
>>> error during normal usage. It is equivalent of doing the infamous "rm
>>> -rf  /bin" .
> 
> What were you doing immediately before the directory disappeared?
> 
> I have only had things like this happen from user error,
> e.g. scripting mistakes.
> 
> (The first time I saw somebody rm -rf / was in 1980 :-) )

BTDT a few times! 
Easy to do with a typo in a script variable name e.g. 
	rm -fR $fopdir/ 
or running a script with a typo that leaves a variable undefined; 
defensive coding is your friend to avoid disasters: 
	if [ -n "$foodir" ] && [ -d $foodir/ ]; then
	  /bin/rm -fR -- $foodir || exit
	else
	  echo "Can't find directory '$foodir'"
	  exit 2
	fi

-- 
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

--
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

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: /bin/ gets deleted on error
  2017-04-13 23:00     ` Brian Inglis
@ 2017-04-14 15:49       ` cyg Simple
  2017-04-15  2:45         ` Norton Allen
  0 siblings, 1 reply; 12+ messages in thread
From: cyg Simple @ 2017-04-14 15:49 UTC (permalink / raw)
  To: cygwin

On 4/13/2017 2:43 PM, Brian Inglis wrote:

> defensive coding is your friend to avoid disasters: 
> 	if [ -n "$foodir" ] && [ -d $foodir/ ]; then
> 	  /bin/rm -fR -- $foodir || exit
> 	else
> 	  echo "Can't find directory '$foodir'"
> 	  exit 2
> 	fi
> 

And even this can be troublesome if you mistype a variable name anywhere
in this code.

-- 
cyg Simple

--
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

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: /bin/ gets deleted on error
  2017-04-14 15:49       ` cyg Simple
@ 2017-04-15  2:45         ` Norton Allen
  0 siblings, 0 replies; 12+ messages in thread
From: Norton Allen @ 2017-04-15  2:45 UTC (permalink / raw)
  To: cygwin

On 4/14/2017 8:42 AM, cyg Simple wrote:
> On 4/13/2017 2:43 PM, Brian Inglis wrote:
>
>> defensive coding is your friend to avoid disasters:
>> 	if [ -n "$foodir" ] && [ -d $foodir/ ]; then
>> 	  /bin/rm -fR -- $foodir || exit
>> 	else
>> 	  echo "Can't find directory '$foodir'"
>> 	  exit 2
>> 	fi
>>
> And even this can be troublesome if you mistype a variable name anywhere
> in this code.
>
Or there are spaces in $foodir


--
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

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: /bin/ gets deleted on error
  2017-04-13 13:59 /bin/ gets deleted on error Felipe Vieira
                   ` (2 preceding siblings ...)
  2017-04-13 18:43 ` L A Walsh
@ 2017-04-19 15:20 ` Gerrit Haase
  3 siblings, 0 replies; 12+ messages in thread
From: Gerrit Haase @ 2017-04-19 15:20 UTC (permalink / raw)
  To: cygwin

2017-04-13 15:13 GMT+02:00 Felipe Vieira says:
>
> For the second time this week my /bin/ folder gets obliterated on an
> error during normal usage. It is equivalent of doing the infamous "rm
> -rf  /bin" .
>
...
> From what I recall the terminal was spamming messages containing the
> words "fork" , "-1" and some others which I don't recall. And what I
> did was trying to run a normal zsh script.

Define "normal".


Regards,
Gerrit

--
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

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: /bin/ gets deleted on error
@ 2017-04-18 12:37 Felipe Vieira
  0 siblings, 0 replies; 12+ messages in thread
From: Felipe Vieira @ 2017-04-18 12:37 UTC (permalink / raw)
  To: cygwin

On Thu, Apr 13, 2017 at 10:13 AM, Felipe Vieira <fmv1992@gmail.com> wrote:
> Dear cygwin mailing list,
>
> For the second time this week my /bin/ folder gets obliterated on an
> error during normal usage. It is equivalent of doing the infamous "rm
> -rf  /bin" .
>
> 1) I would like to know if there is a log for cygwin somewhere so I
> can be more useful in specifying what happened.
>
> 2) My 'specs' are: windows 7 64 bits with cygwin64 . I wonder if
> cygwin64 is considered 'stable'.
>
> From what I recall the terminal was spamming messages containing the
> words "fork" , "-1" and some others which I don't recall. And what I
> did was trying to run a normal zsh script.
>
> I am not able to tell exactly what I did on both occasions to trigger
> this behavior.
>
> Nevertheless thanks for the great software. If it were not for you
> guys I don't know how I could cope with Windows.
>
> Best,
>
> Felipe Vieira.

Guys I am not able to provide more information on this issue.

I'll be more cautious in copying the exact error message next time
this happens. Thanks for all of your help!

Best,

Felipe Vieira.

--
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

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2017-04-19 11:49 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-13 13:59 /bin/ gets deleted on error Felipe Vieira
2017-04-13 14:02 ` Adam Dinwoodie
2017-04-13 14:03 ` Marco Atzeri
2017-04-13 14:24   ` cyg Simple
2017-04-13 15:47     ` cyg Simple
2017-04-13 18:43 ` L A Walsh
2017-04-13 18:48   ` Dan Kegel
2017-04-13 23:00     ` Brian Inglis
2017-04-14 15:49       ` cyg Simple
2017-04-15  2:45         ` Norton Allen
2017-04-19 15:20 ` Gerrit Haase
2017-04-18 12:37 Felipe Vieira

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).