June 23, 2017 at 5:26 am
Hello all,
I Have a Server with 2 network cards. One is 1Gb network and Other is 10Gb.
The installed SQL Server is using the 1Gb network but the DNS name its resolving to the 10Gb IP address.
Can anyone help me changing this?
June 26, 2017 at 8:42 am
What is it that you would like to change? Can you connect to the SQL Server? If not, then you can use SQL Configuration Manager to set the right IP address. Or alter the DNS entry to point to the correct IP address.
June 26, 2017 at 9:08 am
Hello,
I ve already enabled it (the Ip i wante) to "Yes".
Altought when i use netstat i cant see that IP listneing and i cant connect to it
My atual status is:
USE master
GO
xp_readerrorlog 0, 1, N'Server is listening on'
GO
TCP 127.0.0.1:49284 0.0.0.0 Listening 660
TCP [::1]:49284 [::]:0 Listening 660
I ve also add the name on the hosts file...
Regards,
Arestas
June 26, 2017 at 10:04 am
Did you check the IP bindings on your NICs by checking the TCP/IP properties?
Sue
June 26, 2017 at 11:09 am
I personally wouldn't recommend adding the name to the hosts file. Your DNS should handle that no problem.
As for changing the IP that SQL listens on, I'm not sure why you would need to do this. I would assume that the DNS entry for the server is pointing to the faster port, correct? If so, when you connect from your local machine, you should be connected on the fast port. If the DNS points to the slow port, then you will connect on the slow port.
The result of the command you typed in states that you are listening on IP 120.0.0.1 and ::1:, both of which map to localhost (one being IPv4 and the other being IPv6).
If those are the only 2 that are listed from that command, you will only be able to connect from localhost, not from your physical machine. You will need to go into SQL Server Configuration Manager (as crow1969 pointed out) and pick the IP's you want to listen on and set them to Active=Yes and Enabled=Yes and then configure the port as per your requirements. The alternate option is to assign a port under IPAll which means that it will listen on [ANY] for both IPv4 and IPv6 for a specific port. Where I work, we set the IPAll value and then let our IT staff deal with mapping the IP to the machine via DNS. I (being the DBA) have no permissions to the DNS server.
Presuming you can connect from your machine to the server, you could try pinging the server. If you get the slow link, then you need to update your DNS. If you get the fast link, then you should be good to go (unless you are not listening on that IP).
EDIT - adding a value to the hosts file on a machine just changes how that one particular machine maps an IP to a machine name. That is, if you add "127.0.0.1 ComputerName", it will override the DNS entry on ONLY that one machine and it will treat ComputerName as 127.0.0.1. So you change that on the server side, ping ComputerName from your local machine, you will get the DNS entry of the IP. But ping ComputerName from the server and you will get 127.0.0.1.
Modifying the HOSTs file is really only recommended if your DNS is reporting things back in a strange manner OR you have an odd requirement of mapping an IP to a computer name that you don't want to use DNS for. For example, if you have a computer on the network that you want to change the name of BUT you also have some application that looks for the old name and it only runs on a small set of computers. Then you'd update the HOSTs file on that small set so the application still runs even though the remote computer name changed. Or for VPN/RDP purposes to machines that don't have DNS entries you can provide a HOST entry for that. I had worked with a system where they had an IP for the VPN.
The above is all just my opinion on what you should do.
As with all advice you find on a random internet forum - you shouldn't blindly follow it. Always test on a test server to see if there is negative side effects before making changes to live!
I recommend you NEVER run "random code" you found online on any system you care about UNLESS you understand and can verify the code OR you don't care if the code trashes your system.
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply