Package: bash
Version: 5.0-1
Severity: normal
Dear Maintainer,
* What led up to the situation?
Yesterday I updated bash on several computers. In root's .profile I use the
following command to switch from bash to /usr/bin/tcsh:
exec /usr/bin/tcsh -l
After updating bash, when executing 'su -' the system responds with
'Suspended (signal)'.
The new shell (i.e., /usr/bin/tcsh) now is in the background and is
reactivated after issuing the command 'fg'
* What exactly did you do (or not do) that was effective (or
ineffective)?
I updated Bash using the command 'aptitude safe-upgrade'. On another computer
(still using bash 4.4.23(1)) the exec ends execution of .profile and continues
with the new shell.
On the updated computers, as a work-around, I removed the 'exec', and added
'exit 0' to .profile:
...
/usr/bin/tcsh -l
exit 0
This works, but the bash process continues to exist until eventually the tcsh
process ends.
As a side note: I could of course have specified /usr/bin/tcsh as root's shell
in /etc/password, but for various reasons that's not desirable.
In /etc/password root's shell is specified as /bin/bash:
root:x:0:0:root:/root:/bin/bash
Bash itself is indeed at /bin/bash:
-rwxr-xr-x 1 root root 1168776 Jan 14 16:27 /bin/bash*
reporting its version as:
$ bash --version
GNU bash, version 5.0.0(1)-release (x86_64-pc-linux-gnu)
As another test I specified in .profile
exec /usr/local/bin/pause
echo beyond exec
where `pause' expects the user to press a key. Pause's prompt is shown, but
there's no waiting for input, and the echo text `beyond exec' isn't displayed:
apparently exec *does* end .profile's execution, but the replaced process
loses access to stdin.
* What outcome did you expect instead?
I didn't find any entry about changes of the built-in exec command in either
the upstream changelog or the Debian changelog, and so I expected
exec /usr/bin/tcsh -l
to work as before: at login shells switching to using the tcsh.
If you need any further info, please let me know.
Kind regards,
Frank B. Brokken.
-- System Information:
Debian Release: buster/sid
APT prefers testing
APT policy: (500, 'testing'), (1, 'experimental')
Architecture: amd64 (x86_64)
Kernel: Linux 4.19.0-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8),
LANGUAGE=en_US:en (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
Versions of packages bash depends on:
ii base-files 10.1
ii debianutils 4.8.6
ii libc6 2.28-5
ii libtinfo6 6.1+20181013-1
Versions of packages bash recommends:
ii bash-completion 1:2.8-5
Versions of packages bash suggests:
pn bash-doc <none>
-- no debconf information