Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save Bryant-Yang/758d0371061574b0997fa2513340a869 to your computer and use it in GitHub Desktop.
Save Bryant-Yang/758d0371061574b0997fa2513340a869 to your computer and use it in GitHub Desktop.
prolong ssh login timeout
#!/bin/bash
echo export TMOUT=1000000 >> /root/.bash_profile
cat /root/.bash_profile
source .bash_profile
cp /etc/ssh/sshd_config /etc/ssh/sshd_config_bak
echo ClientAliveInterval=60 >> /etc/ssh/sshd_config
service sshd restart
cat /etc/ssh/sshd_config
service sshd restart
exit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment