A normal Bash shell with exit the current session when pressing ^D (Ctrl+D), but this can be avoided by editing the ~/.bashrc file and adding the following line:
export IGNOREEOF=1
This command will set the $IGNOREEOF variable to true, preventing a single combination of ^D to exit. In order to close the session, you can still use exit or double ^D.
Source URL: http://ashesgarrett.blogspot.com/2009/08/tip-of-day-prevent-exiting-shell-with.html
Visit ashes garrett for Daily Updated Hairstyles Collection
export IGNOREEOF=1
This command will set the $IGNOREEOF variable to true, preventing a single combination of ^D to exit. In order to close the session, you can still use exit or double ^D.
Source URL: http://ashesgarrett.blogspot.com/2009/08/tip-of-day-prevent-exiting-shell-with.html
Visit ashes garrett for Daily Updated Hairstyles Collection