{"id":531,"date":"2024-08-14T09:52:57","date_gmt":"2024-08-14T09:52:57","guid":{"rendered":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/?p=531"},"modified":"2024-08-14T09:56:55","modified_gmt":"2024-08-14T09:56:55","slug":"configure-sql-server-to-listen-on-a-specific-tcp-port","status":"publish","type":"post","link":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/configure-sql-server-to-listen-on-a-specific-tcp-port\/","title":{"rendered":"Configure SQL Server to listen on a specific TCP port"},"content":{"rendered":"<p>This article describes Configure SQL Server to listen on a specific TCP port and how to configure an instance of the SQL Server Database Engine to listen on a specific fixed port by using SQL Server Configuration Manager. If enabled, the default instance of the SQL Server Database Engine listens on TCP port 1433. Named instances of the Database Engine and SQL Server Compact are configured for dynamic ports. This means they select an available port when the SQL Server service is started. When you connect to a named instance through a <a href=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/firewalld-service-unit-is-masked\/\">firewall<\/a>, configure the Database Engine to listen on a specific port, so that the appropriate port can be opened in the firewall.<\/p>\n<p>The Database Engine begins listening on a new port when restarted. However the SQL Server Browser service monitors the registry and reports the new port number as soon as the configuration is changed, even though the Database Engine might not be using it. Restart the Database Engine to ensure consistency and avoid connection failures.<\/p>\n<div class=\"heading-wrapper\" data-heading-level=\"h2\">\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_83 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/configure-sql-server-to-listen-on-a-specific-tcp-port\/#Configure_SQL_Server_to_listen_on_a_specific_TCP_port\" >Configure SQL Server to listen on a specific TCP port<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/configure-sql-server-to-listen-on-a-specific-tcp-port\/#Use_SQL_Server_Configuration_Manager\" >Use SQL Server Configuration Manager<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/configure-sql-server-to-listen-on-a-specific-tcp-port\/#Assign_a_TCPIP_port_number_to_the_SQL_Server_Database_Engine\" >Assign a TCP\/IP port number to the SQL Server Database Engine<\/a><\/li><\/ul><\/li><\/ul><\/li><\/ul><\/nav><\/div>\n<h2 id=\"SSMSProcedure\" class=\"heading-anchor\"><span class=\"ez-toc-section\" id=\"Configure_SQL_Server_to_listen_on_a_specific_TCP_port\"><\/span>Configure SQL Server to listen on a specific TCP port<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<h4 class=\"heading-anchor\"><span class=\"ez-toc-section\" id=\"Use_SQL_Server_Configuration_Manager\"><\/span>Use SQL Server Configuration Manager<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<\/div>\n<div class=\"heading-wrapper\" data-heading-level=\"h4\">\n<h4 id=\"assign-a-tcpip-port-number-to-the-sql-server-database-engine\" class=\"heading-anchor\"><span class=\"ez-toc-section\" id=\"Assign_a_TCPIP_port_number_to_the_SQL_Server_Database_Engine\"><\/span>Assign a TCP\/IP port number to the SQL Server Database Engine<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<\/div>\n<ol>\n<li>In SQL Server Configuration Manager, in the console pane, expand <strong>SQL Server Network Configuration<\/strong>, select <strong>Protocols for &lt;instance name&gt;<\/strong>, and then in the right pane double-click <strong>TCP\/IP<\/strong>.<\/li>\n<li>In the <strong>TCP\/IP Properties<\/strong> dialog box, on the <strong>IP Addresses<\/strong> tab, several IP addresses appear in the format <strong>IP1<\/strong>, <strong>IP2<\/strong>, up to <strong>IPAll<\/strong>. One of these entries is for the IP address of the loopback adapter, <code>127.0.0.1<\/code>. Additional IP addresses appear for each IP address on the computer. (You might see both IP version 4 and IP version 6 addresses.) Right-click each address, and then select <strong>Properties<\/strong> to identify the IP address that you want to configure.<\/li>\n<li>If the <strong>TCP Dynamic Ports<\/strong> dialog box contains <code>0<\/code>, indicating the Database Engine is listening on dynamic ports, delete the <code>0<\/code>.<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-532 size-full\" src=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-content\/uploads\/2024\/08\/tcp-14333.png\" alt=\"Configure SQL Server to listen on a specific TCP port\" width=\"649\" height=\"810\" srcset=\"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-content\/uploads\/2024\/08\/tcp-14333.png 649w, https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-content\/uploads\/2024\/08\/tcp-14333-240x300.png 240w\" sizes=\"auto, (max-width: 649px) 100vw, 649px\" \/><\/li>\n<li>In the <strong>IP <em>n<\/em><\/strong> <strong>Properties<\/strong> area box, in the <strong>TCP Port<\/strong> box, type the port number you want this IP address to listen on, and then select <strong>OK<\/strong>. Multiple ports might be specified by separating them with a comma. Select <strong>OK<\/strong>.If the <strong>Listen All<\/strong> setting on the <strong>Protocol<\/strong> tab is set to <em>Yes<\/em>, then only <strong>TCP Port<\/strong> and <strong>TCP Dynamic Port<\/strong> values under the <strong>IPAll<\/strong> section are used, and individual <strong>IP <em>n<\/em><\/strong> sections are ignored in their entirety. If the <strong>Listen All<\/strong> setting is set to <em>No<\/em>, then the <strong>TCP Port<\/strong> and <strong>TCP Dynamic Port<\/strong> settings under the <strong>IPAll<\/strong> section are ignored, and the <strong>TCP Port<\/strong>, <strong>TCP Dynamic Port<\/strong>, and <strong>Enabled<\/strong> settings on the individual <strong>IP <em>n<\/em><\/strong> sections are used instead.Each <strong>IP <em>n<\/em><\/strong> section has an <strong>Enabled<\/strong> setting with a default value of &#8220;No&#8221; which causes SQL Server to ignore this IP address even if it has a port defined.<\/li>\n<li>In the console pane, select <strong>SQL Server Services<\/strong>.<\/li>\n<li>In the details pane, right-click <strong>SQL Server (<\/strong>&lt;instance name&gt;<strong>)<\/strong> and then select <strong>Restart<\/strong>, to stop and restart <a href=\"https:\/\/www.squarebrothers.com\/mssql-hosting-india\/\" target=\"_blank\" rel=\"noopener\">SQL Server.<\/a><\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>This article describes Configure SQL Server to listen on a specific TCP port and how to configure an instance of the SQL Server Database Engine to listen on a specific fixed port by using SQL Server Configuration Manager. If enabled, the default instance of the SQL Server Database Engine listens on TCP port 1433. Named [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[41,43],"tags":[93,92,91],"class_list":["post-531","post","type-post","status-publish","format-standard","hentry","category-control-panel","category-windows","tag-client","tag-sql","tag-tcp"],"_links":{"self":[{"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/posts\/531","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/comments?post=531"}],"version-history":[{"count":6,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/posts\/531\/revisions"}],"predecessor-version":[{"id":538,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/posts\/531\/revisions\/538"}],"wp:attachment":[{"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/media?parent=531"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/categories?post=531"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hyderabadwebhosting.co.in\/tutorials\/wp-json\/wp\/v2\/tags?post=531"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}