public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* login shell binary outside of /bin
@ 2021-07-01  6:53 Basin Ilya
  2021-07-01  7:49 ` Adam Dinwoodie
  0 siblings, 1 reply; 2+ messages in thread
From: Basin Ilya @ 2021-07-01  6:53 UTC (permalink / raw)
  To: cygwin

Hi
I compiled bash 5.1 and installed it to /usr/local

If I try to use it as a login shell it fails to launch programs while sourcing /etc/profile. If I copy the binary to /bin it works. If after successful login I launch `/usr/local/bin/bash5 -login` again it works. If I copy the official bash4 to /usr/local/bin and try to do the initial login it fails just like bash5.

Bad:

    C:\cygwin\bin>C:\cygwin\usr\local\bin\bash5 -login
          0 [main] bash5 674 dofork: child -1 - forked process 20540 died unexpectedly, retry 0, exit code 0xC0000135, errno 11
    bash5: fork: retry: Resource temporarily unavailable
    1023667 [main] bash5 674 dofork: child -1 - forked process 35708 died unexpectedly, retry 0, exit code 0xC0000135, errno 11
    bash5: fork: retry: Resource temporarily unavailable
    3053548 [main] bash5 674 dofork: child -1 - forked process 28664 died unexpectedly, retry 0, exit code 0xC0000135, errno 11
    bash5: fork: retry: Resource temporarily unavailable
    7078151 [main] bash5 674 dofork: child -1 - forked process 59624 died unexpectedly, retry 0, exit code 0xC0000135, errno 11
    bash5: fork: retry: Resource temporarily unavailable
    15108745 [main] bash5 674 dofork: child -1 - forked process 51456 died unexpectedly, retry 0, exit code 0xC0000135, errno 11
    bash5: fork: Resource temporarily unavailable
    bash5-5.1$ /usr/bin/hostname
    23539687 [main] bash5 674 dofork: child -1 - forked process 55544 died unexpectedly, retry 0, exit code 0xC0000135, errno 11
    bash5: fork: retry: Resource temporarily unavailable
    24564456 [main] bash5 674 dofork: child -1 - forked process 67084 died unexpectedly, retry 0, exit code 0xC0000135, errno 11
    bash5: fork: retry: Resource temporarily unavailable
    26592885 [main] bash5 674 dofork: child -1 - forked process 16288 died unexpectedly, retry 0, exit code 0xC0000135, errno 11
    bash5: fork: retry: Resource temporarily unavailable
    30618645 [main] bash5 674 dofork: child -1 - forked process 28416 died unexpectedly, retry 0, exit code 0xC0000135, errno 11
    bash5: fork: retry: Resource temporarily unavailable
    38648818 [main] bash5 674 dofork: child -1 - forked process 26696 died unexpectedly, retry 0, exit code 0xC0000135, errno 11
    bash5: fork: Resource temporarily unavailable
    bash5-5.1$ echo "PATH=$PATH"
    PATH=/usr/local/bin:/usr/bin:/cygdrive/c/Program Files/BellSoft/LibericaJRE-8/bin:/cygdrive/c/Program Files/Documentum/Shared:/cygacl/v/goodfs/bin:/cygdrive/c/WINDOWS/system32:/cygdrive/c/WINDOWS:/cygdrive/c/WINDOWS/System32/Wbem:/cygdrive/c/WINDOWS/System32/WindowsPowerShell/v1.0:/cygdrive/c/WINDOWS/System32/OpenSSH:/cygdrive/c/Program Files (x86)/Intel/Intel(R) Management Engine Components/DAL:/cygdrive/c/Program Files/Intel/Intel(R) Management Engine Components/DAL:/cygdrive/c/Program Files/nodejs:/cygdrive/c/progs/apache-maven-3/bin:/cygdrive/c/Program Files/Cloud Foundry:/cygdrive/c/progs/git-for-windows/cmd:/cygdrive/c/Program Files/Docker/Docker/resources/bin:/cygdrive/c/ProgramData/DockerDesktop/version-bin:/cygdrive/c/Users/basin/AppData/Local/Microsoft/WindowsApps:/cygdrive/c/Users/basin/AppData/Roaming/npm
    bash5-5.1$ pwd
    /home/basin
    bash5-5.1$

Good:

    C:\cygwin\bin>C:\cygwin\bin\bash5 -login
    
    basin@basin ~
    $ /usr/bin/hostname
    basin
    
    basin@basin ~
    $ echo "PATH=$PATH"
    PATH=/home/basin/.local/bin:/opt/wrappers/bin:/home/basin/perl5/bin:/usr/local/bin:/usr/bin:/cygdrive/c/Program Files/BellSoft/LibericaJRE-8/bin:/cygdrive/c/Program Files/Documentum/Shared:/cygacl/v/goodfs/bin:/cygdrive/c/WINDOWS/system32:/cygdrive/c/WINDOWS:/cygdrive/c/WINDOWS/System32/Wbem:/cygdrive/c/WINDOWS/System32/WindowsPowerShell/v1.0:/cygdrive/c/WINDOWS/System32/OpenSSH:/cygdrive/c/Program Files (x86)/Intel/Intel(R) Management Engine Components/DAL:/cygdrive/c/Program Files/Intel/Intel(R) Management Engine Components/DAL:/cygdrive/c/Program Files/nodejs:/cygdrive/c/progs/apache-maven-3/bin:/cygdrive/c/Program Files/Cloud Foundry:/cygdrive/c/progs/git-for-windows/cmd:/cygdrive/c/Program Files/Docker/Docker/resources/bin:/cygdrive/c/ProgramData/DockerDesktop/version-bin:/cygdrive/c/Users/basin/AppData/Local/Microsoft/WindowsApps:/cygdrive/c/Users/basin/AppData/Roaming/npm
    
    basin@basin ~
    $ pwd
    /home/basin
    
    basin@basin ~



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

* Re: login shell binary outside of /bin
  2021-07-01  6:53 login shell binary outside of /bin Basin Ilya
@ 2021-07-01  7:49 ` Adam Dinwoodie
  0 siblings, 0 replies; 2+ messages in thread
From: Adam Dinwoodie @ 2021-07-01  7:49 UTC (permalink / raw)
  To: Cygwin (cygwin@cygwin.com)

On Thu, 1 Jul 2021 at 08:30, Basin Ilya via Cygwin <cygwin@cygwin.com> wrote:
> Hi
> I compiled bash 5.1 and installed it to /usr/local
>
> If I try to use it as a login shell it fails to launch programs while sourcing /etc/profile. If I copy the binary to /bin it works. If after successful login I launch `/usr/local/bin/bash5 -login` again it works. If I copy the official bash4 to /usr/local/bin and try to do the initial login it fails just like bash5.
>
> Bad:
>
>     C:\cygwin\bin>C:\cygwin\usr\local\bin\bash5 -login
>           0 [main] bash5 674 dofork: child -1 - forked process 20540 died unexpectedly, retry 0, exit code 0xC0000135, errno 11
>     bash5: fork: retry: Resource temporarily unavailable
> <snip>

Hello! First of all, have you tried working through the section on
fork problems in the FAQ below? That is normally the way to sort these
issues.

> FAQ:                  https://cygwin.com/faq/

If you've gone through all those steps, it would be useful to know
exactly how you compiled Bash, including where you got the source code
and what commands and tools you used to do the compilation, as well as
the cygcheck output specified in the Problem reports documentation as
below:

> Problem reports:      https://cygwin.com/problems.html

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

end of thread, other threads:[~2021-07-01  7:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-01  6:53 login shell binary outside of /bin Basin Ilya
2021-07-01  7:49 ` Adam Dinwoodie

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