Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] SSHD auto-disconnect
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Polskie forum (Polish) Polish OTW
View previous topic :: View next topic  
Author Message
soban_
l33t
l33t


Joined: 27 Aug 2008
Posts: 668
Location: /home/soban

PostPosted: Fri Feb 24, 2012 9:01 pm    Post subject: [SOLVED] SSHD auto-disconnect Reply with quote

Ehh juz troche googlowalem i tak jak w temacie - dosyc "glupio-denerwujacy" problem - mianowicie, gdy nic nie robie przez jakies 10 minut to zrywa mi polaczenie. Probowalem juz z opcjami w /etc/ssh/sshd_config ustawiac:
Code:
ClientAliveInterval 0
#na wieksze wartosc tez ustawialem
ClientAliveCountMax 3
#zakomentowywalem wszystko tez i ustawialem od 3-15
TCPKeepAlive yes
#na rozne sposoby juz tutaj kombinowalem
Moze ma ktos inny pomysl, co to moze powodowac? Denerwujace jest to dosyc - oczywiscie resetowalem juz /etc/conf.d/sshd.
_________________
gg: 525600


Last edited by soban_ on Tue Feb 28, 2012 11:54 pm; edited 1 time in total
Back to top
View user's profile Send private message
joi_
Apprentice
Apprentice


Joined: 28 Mar 2005
Posts: 171

PostPosted: Sat Feb 25, 2012 5:35 pm    Post subject: Reply with quote

1) nie masz czasem ustawionej zmiennej środowiskowej TMOUT?
2) pomiędzy maszynami jest jakiś router z NATem? może dropuje ci nieaktywne połączenia?
Back to top
View user's profile Send private message
soban_
l33t
l33t


Joined: 27 Aug 2008
Posts: 668
Location: /home/soban

PostPosted: Sat Feb 25, 2012 5:46 pm    Post subject: Reply with quote

Nata nie ma, a co do zmiennej srodowiskowej to niby nie ma (echo $TMOUT), a przynajmniej nic nie zwraca, chyba ze mam gdzies jej poszukac i zmienic? Czytalem tez o tym na googlach...
_________________
gg: 525600
Back to top
View user's profile Send private message
Jacekalex
Guru
Guru


Joined: 17 Sep 2009
Posts: 553

PostPosted: Tue Feb 28, 2012 11:00 am    Post subject: Reply with quote

A do dokumentacji zajrzał?
soban_ wrote:
Ehh juz troche googlowalem i tak jak w temacie - dosyc "glupio-denerwujacy" problem - mianowicie, gdy nic nie robie przez jakies 10 minut to zrywa mi polaczenie. Probowalem juz z opcjami w /etc/ssh/sshd_config ustawiac:[code]........

Dokumentacja wrote:
LoginGraceTime
The server disconnects after this time if the user has notsuccessfully logged in. If the value is 0, there is no time limit.The default is 600 (seconds).

Sznurek: http://www.onsight.com/faq/ssh/manpages/sshd1_man.html

To by było na tyle
8)
Back to top
View user's profile Send private message
soban_
l33t
l33t


Joined: 27 Aug 2008
Posts: 668
Location: /home/soban

PostPosted: Tue Feb 28, 2012 2:12 pm    Post subject: Reply with quote

Wiec, to by nie bylo na tyle : P
Jacekalex wrote:
A do dokumentacji zajrzał?
Nie, jade na pale ; ) <- to jest ironia, zeby pozniej nie bylo.
Ta opcje na drugim domowym "serwerze" mam zakomentowana i nie mam rozlaczen jak i na tym, przy ktory mam rozlaczenia. Jednak idac za Twoja rada sprobujemy, jesli cos da - to dam znac jeszcze w tej wypowiedzi. Dalem ja na wartosc 0.

No i tak jak mowilem, rozlacza - wiec nic to nie dalo. A i btw, robi sie to szybciej niz 600 sekund, moze to cos podpowie - jakies 6 minut wystarcza, aby zlapac disconnecta. Jakies inne pomysly? Dodam jeszcze konfig aktualny gdyby komus cos wpadlo w oko -> http://paste.pocoo.org/show/558074/ ale watpie zeby cos mialo na to wplyw... chyba ze jeszcze jakis plik konfiguracyjny potrzebny jest to prosze smialo pisac.
_________________
gg: 525600
Back to top
View user's profile Send private message
SlashBeast
Retired Dev
Retired Dev


Joined: 23 May 2006
Posts: 2922

PostPosted: Tue Feb 28, 2012 8:32 pm    Post subject: Reply with quote

@Jacekalex: wydaje mi sie, ze pomyliles sie tutaj. LoginGraceTime z opisu w dokumentacji mowi o rozlaczaniu klienta, jak sie polaczyl do serwera ale nie zalogowal, np. wisi na 'Password:'

a Ty soban ustaw keepalive jakos sensownie. Mozesz albo po stronie serwera ustawic, by np. co 30s odpytywal klienta i jest to "ClientAliveInterval 30" w sshd_config lub ustaw sobie na maszynie z ktorej sie laczysz by wysylac keepalive co 60s (ja tak robie), przyklad ~/.ssh/config
Code:
Host *
   Protocol 2
   TCPKeepAlive yes
   ServerAliveInterval 60


Ja mam taki wpis na koncu ~/.ssh/config i niektore polaczenia mam otwarte po kilka tygodni (nie wpisuje tam nic) i wszystko dziala.
Back to top
View user's profile Send private message
soban_
l33t
l33t


Joined: 27 Aug 2008
Posts: 668
Location: /home/soban

PostPosted: Tue Feb 28, 2012 11:53 pm    Post subject: Reply with quote

Co tu duzo mowic [SOLVED], dziekuje wszystkim za pomoc.
_________________
gg: 525600
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Polskie forum (Polish) Polish OTW All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum