Start in Safeboot and remove the Terminal preferences. Don't launch terminal yet. Then see if you can enter the command in terminal, but after a normal restart.
Try $ defaults write com.apple.terminal NSQuitAlwaysKeepsWindows -bool false
This will cause Terminal to startup cleanly. If it works after a few launches of the terminal (until you are satisfied) try the -bool true to see what happens.
Try another user account.
Go into recovery mode and enter $ resetpassword and fix ACLs.
I am not sure if any of this will work but this is what I would do.
Failing everything, I would consider a reinstall of El Cap.
I would also go to Terminal>Preferences>General and set the shell to open with the Default login shell - See attached image.