0

(more details/replicate from: https://superuser.com/questions/1612260)

Dear all,
I'm a total newbie in connecting 2 PCs and making them use the same SQL server DB from one computer ... so please support me.
At home, I have 2 PCs from my company (working from home due to Covid19; I don't have better windows images and I would prefer not changing them, or at least as possible):

PC Windows SQL server SSMS IP
1 7, version 6.1, build 7601 sp1 2014 (installation in progress) not yet 192.168.0.10
2 10, version1803, build17134.345 2017 18.1 192.168.0.105

The final goal: to have PC1 act as a db server and PC2 as a client (that can access the server's dbs). On both PCs I will install the same application which should be able (from any PC) to update the data from PC1/the db server.

I'd been told I would need a domain controller (DC) for this scenario, but I really don't have any clue what this means or how I should configure it:

  1. do I need a DC?
  2. is this DC something that comes with the windows images?
  3. is this DC something that comes with SQL Server?
  4. is this an application which I'll need to install separately? (I initially thought that if I'm installing sql server on PC1, I will have to insert the windows credentials from the PC2 and this will suffice)
  5. could you please give me step-by-step on how to make this work?

Thank you!
R

5
  • Hi, you'll likely have better luck asking this question on ServerFault. Domain Controller is a feature of Windows OS (not SQL Server). I don't believe you actually need to set it up to be able to connect to a SQL Server instance on PC1, as long as PC2 is on the same network as PC1. – J.D. Jan 14 at 12:04
  • 1
    Do your requirements include the users connecting using windows credentials or are SQL Server logins allowed? – bradbury9 Jan 14 at 13:39
  • @J.D. thank you! I'll re-post my question there. The PCs are on the same network (same router) – radui Jan 14 at 13:50
  • @bradbury9 I don't know. The thing is I'm going to install an application on both PCs and I'm hoping that if I'm adding/updateing/removing data using one PC the other PC will be able to see this (provided I give enough refreshes). I have no clue to answer your question, I'm only hopping that the easiest way (i.e. with windows credentials) will work. – radui Jan 14 at 13:53
  • 1
    @radui The easiest way likely is to create a SQL Login on the server (if you want to avoid needing to use a Domain Controller). Of course the more secure way would be to use Windows Credentials properly. But a dedicated SQL Login is easier to just hard-code into your application when it needs to connect to the SQL Server instead of dealing with setting up Windows Account permissions in SQL Server and authentication in the app. So to get yourself started (for a sec app) you should look into creating a dedicated SQL Login / User but for a production app you should look into proper permissioning. – J.D. Jan 14 at 15:02
2

do I need a DC?

No you can use SQL Authentication, or Windows Auth (NTLM) with "workgroup auth". And to use a DC you would have to join both of your boxes to the domain, so I wouldn't bother.

is this DC something that comes with the windows images? is this DC something that comes with SQL Server? is this an application which I'll need to install separately?

Domain Controller is a feature of Windows Server, and is not available on the client editions of Windows, like Windows 7 or Windows 10.

(I initially thought that if I'm installing sql server on PC1, I will have to insert the windows credentials from the PC2 and this will suffice) could you please give me step-by-step on how to make this work?

If you create a local user on both boxes that has the same password, you can use Windows Integrated Auth for SQL Server. This is the "workgroup auth", and it would enable accessing File Shares and other services between the computers.

0

Windows DC in a role for windows server that centralize windows authentication.

If SQL server is a server member (of the domain) it can relay on that centralized repository of users and groups making easy to share authentication and security across an organization.

I suggest you, in your case, to use sql authentication so login and passowrd are locally managed by the sql engine. In this way you spare the need of having a DC in your home environmet.

So in your application use for server name the ip address (followed by , 1433 that is the default port) and the sql authentication instead of windows integrated security.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.