jportela: (avatar)jportela ([personal profile] jportela) wrote in [site community profile] dw_dev_training,
@ 2010-04-04 08:22 pm UTC
  • Previous Entry
  • Add to Memories
  • Tell someone about this!
  • Next Entry
Entry tags:dreamhacks
When I connected to my dreamhack account via ssh (in ubuntu terminal), sometimes the terminal froze after some minutes of innactivity. I discovered this solution (works in ubuntu but probably works in any linux distribution with openssh. Windows users have putty, which may or may not have the same problem, but different configuration anyway).

You should only try this command in your *nix based computer (*not* on the ssh connection to the dreamhack account, as it won't work):

echo -e "ServerAliveInterval 15\nServerAliveCountMax 3" >> ~/.ssh/config 
 
If you are likely to use different machines to access your dreamhack account, then you can set it on the dreamhack server as this:

echo -e "KeepAlive yes\nClientAliveInterval 60" >> ~/.ssh/config 

And in Putty you have to change the parameter:

Seconds between keepalives, in the Connection Setup tab, to 15

For credits on the solutions, just browse the replies below :)



(9 comments) - (Post a new comment)
(Flat) (Top-level comments only)

exor674: Computer Science is my girlfriend (cs is gf)


[personal profile] exor674
2010-04-04 07:36 pm UTC (link)
You shouldn't even need to do "cp /etc/ssh/ssh_config ~/.ssh/config" -- ~/.ssh/config should add *to* the global file anyway

(Reply to this


jportela: (avatar)


[personal profile] jportela
2010-04-04 08:32 pm UTC (link)
You're right, I already edited the post

(Reply to this


sophie: A cartoon-like representation of a girl standing on a hill, with brown hair, blue eyes, a flowery top, and blue skirt. ☀ (skype, sophie, weemee)


[personal profile] sophie
2010-04-04 10:24 pm UTC (link)
I should note for anybody wanting to try this - this assumes that the computer you're connecting *from* (ie. your computer) is Linux-based; you shouldn't do it on the Dreamhack maching itself as it won't work.

(Reply to this)  (Thread


jportela: (avatar)


[personal profile] jportela
2010-04-04 11:09 pm UTC (link)
Correction done!

(Reply to this)  (Thread from start)  (Parent


pauamma: Cartooney crab holding drink ("Cartooney crab holding drink")


[personal profile] pauamma
2010-04-05 01:01 am UTC (link)
s/Linux/*nix/ :-)

(Reply to this)  (Thread from start)  (Parent


hypatia: (pink)


[personal profile] hypatia
2010-04-05 06:53 am UTC (link)
if you want to set it on the server side:

add the following to the /etc/ssh/sshd_config file on your server:

KeepAlive yes
ClientAliveInterval 60

works great if you're likely to ssh in from different machines.

(Reply to this)  (Thread from start)  (Parent


afuna: Cat under a blanket. Text: "Cats are just little people with Fur and Fangs" (afuna, cats)


[personal profile] afuna
2010-04-05 01:08 am UTC (link)
I use this as well (I thought I was the only one who needed it because of a bad connection!) -- it works like a charm :)

(Reply to this


pauamma: Cartooney crab holding drink ("Cartooney crab holding drink")


[personal profile] pauamma
2010-04-05 01:11 am UTC (link)
For PuTTY, the parameter to set is: Seconds between keepalives (in the Connection setup tab)

(Reply to this)  (Thread


jportela: (avatar)


[personal profile] jportela
2010-04-05 05:32 pm UTC (link)
Done, done and done :)

(Reply to this)  (Thread from start)  (Parent



(9 comments) - (Post a new comment)
(Flat) (Top-level comments only)