Welcome to Sign in | Help
in Search

help... nr. maxim de conexiuni a fost atins

Last post 09-30-2007, 3:58 PM by xmldeveloper. 8 replies.
Sort Posts: Previous Next
  •  09-25-2007, 3:50 PM 2768

    help... nr. maxim de conexiuni a fost atins

    Am o aplicatie ce foloseste SQL Server 2005. I-am facut deploymentul, insa primesc o eroare de genu:

    A connection was successfully established with the server, but then an error occurred during the login process. (provider: TCP Provider, error: 0 - An established connection was aborted by the software in your host machine.)

    Mergand mai departe am observat ca si celelalte aplicatii care se foloseau de serveru meu nu mai functioneaza.

    Am ajuns sa ma uit in log sa vad care ar putea fi problema. Asta am reusit sa aflu de acolo:

    2007-09-25 15:30:32.14 Logon       Could not connect because the maximum number of '3' user connections has already been reached. The system administrator can use sp_configure to increase the maximum value. The connection has been closed. [CLIENT: <local machine>]
    2007-09-25 15:30:32.14 Logon       Error: 17809, Severity: 20, State: 3.

    Am citit in unele locuri ca pot scapa de problema aceasta daca folosesc sp_configure ca sa cresc nr. de conexiuni.

    Si am vrut sa intru, dar nu ma mai pot conecta la server prin SSMSE din cauza erorii de mai sus.

    Cum sa folosesc eu query analyser si comanda sp_configure daca nu ma pot conecta la server? Ce pot sa fac? Si in primul rand ce genereaza problema mea? Am aflat ca sunt 3 conexiuni la serverul meu. Cum pot sa le opresc?

    Mentionez ca folosesc SQL Server 2005 si ca protocoalele pt. named pipes, tcp/ip si shared memory sunt enabled.

    Calin Drimbau 

  •  09-25-2007, 5:04 PM 2771 in reply to 2768

    Re: help... nr. maxim de conexiuni a fost atins

    Daca este posibil incearca sa reinstalezi SQL Server.
  •  09-25-2007, 5:45 PM 2772 in reply to 2768

    Re: help... nr. maxim de conexiuni a fost atins

    Incercati sa va connectati cu SQLCMD si DAC: http://sqlserver.ro/forums/post/262.aspx
    Cristian Andrei Lefter, SQL Server MVP
    MCT, MCSA, MCDBA, MCAD, MCSD .NET,
    MCTS, MCITP - Database Administrator SQL Server 2005
    http://sqlserver.ro
  •  09-25-2007, 5:51 PM 2773 in reply to 2771

    Re: help... nr. maxim de conexiuni a fost atins

    Nu pot. Nu imi permite infrastructura. :(
  •  09-25-2007, 6:13 PM 2774 in reply to 2768

    Re: help... nr. maxim de conexiuni a fost atins

    DAC se poate folosi si din SSMS! Vedeti tot http://sqlserver.ro/forums/post/262.aspx sau http://sqlserver.ro/forums/post/91.aspx.
    Cristian Andrei Lefter, SQL Server MVP
    MCT, MCSA, MCDBA, MCAD, MCSD .NET,
    MCTS, MCITP - Database Administrator SQL Server 2005
    http://sqlserver.ro
  •  09-25-2007, 8:00 PM 2776 in reply to 2774

    Re: help... nr. maxim de conexiuni a fost atins

    Am rezolvat problema. Folosind Conexiunea Dedicata pentru Administrator (DAC) am reusit sa ma conectez la sever. Si de acolo folosind sintaxa:

    sp_configure 'user connections', 10
    go
    reconfigure

    am resetat numarul de conexiuni maxim la 10. (dintr-un maxim de 32,767 permise)

    Sfat legat de setarea nr. de conexiuni:

    If you must use this option, do not set the value too high, because each connection takes approximately 28 kilobytes (KB) of overhead regardless of whether the connection is being used. If you exceed the maximum number of user connections, you receive an error message and are not able to connect until another connection becomes available.

    Mai am o intrebare legat de:

    Did I mention that DAC won’t timeout?  So don’t forget to close it!

    Exista ceva sintaxa pt. inchidere? Sau se inchide automat cand inchid consola?

  •  09-25-2007, 8:22 PM 2777 in reply to 2776

    Re: help... nr. maxim de conexiuni a fost atins

    Se inchide automat la inchiderea sqlcmd (sau tastand exit)! Smile
    Cristian Andrei Lefter, SQL Server MVP
    MCT, MCSA, MCDBA, MCAD, MCSD .NET,
    MCTS, MCITP - Database Administrator SQL Server 2005
    http://sqlserver.ro
  •  09-27-2007, 3:50 PM 2796 in reply to 2776

    Re: help... nr. maxim de conexiuni a fost atins

    Încă un sfat legat de setarea nr. de conexiuni (tot din Books Online):

    Because user connections is a dynamic (self-configuring) option, SQL Server adjusts the maximum number of user connections automatically as needed, up to the maximum value allowable. [...] In most cases, you need not change the value for this option.

    Aşa că eu îţi recomand să o laşi pe 0 (valoarea implicită), ceea ce înseamnă că SQL Server nu va limita numărul maxim de conexiuni. Cred că această configurare este utilă foarte rar, de exemplu atunci când memoria server-ului este limitată, iar server-ul este accesat de o aplicaţie web care poate genera sute sau mii de conexiuni simultane, şi vrem să interzicem accesul mai multor utilizatori în cazul în care performanţa s-ar degrada peste o limită acceptabilă. În cazul în care vorbim despre un server accesat doar de aplicaţii din interiorul firmei, eu nu aş limita numărul de conexiuni.

    Răzvan

  •  09-30-2007, 3:58 PM 2799 in reply to 2796

    Re: help... nr. maxim de conexiuni a fost atins

    Pana la urma asta a fost rezolvarea Razvan Smile, valoarea implicita 0.


    Cristian Andrei Lefter, SQL Server MVP
    MCT, MCSA, MCDBA, MCAD, MCSD .NET,
    MCTS, MCITP - Database Administrator SQL Server 2005
    http://sqlserver.ro
View as RSS news feed in XML
Powered by Community Server (Commercial Edition), by Telligent Systems