I have several boxen running Debian Wheezy. They appear to have the highly annoying problem that pressing ctrl+c in a shell that has been su:d to root will kill su, not whatever is running in the root shell. This makes working with e.g. ping or tcpdump near impossible. As I understand it, the issue is debated at length in Debian bug #628843 but there seems to be no consensus.
[20:38] alias zsu='su root -p -c $SHELL' [20:38] zsu Password: zsh compinit: insecure directories and files, run compaudit for list. Ignore insecure directories and files and continue [y] or abort compinit [n]? y [20:38] <- I simply pressed ctrl+c Session terminated, terminating shell... [20:38] ...killed.
I need to find a fix for this. Can I execute su differently or is there a replacement I can use instead? (Preferably no sudo and I would prefer not to allow ssh root login.)