I have a SQL Server 2008 R2 Standard instance in a "DMZ", so that it can be client-facing. I am trying to have it write its backups to a central location that is within the network. The engineers suggest that they can open a port for me. Hence the question: What port is used by SQL Server to write backups to a remote server?

  • 4
    It will use the port that is assigned. By default it is 1433 (which is not a good practice to use due to security). Also, take the backup locally and then use ROBOCOPY or powershell to move the backups to a remote server. Dont try to write directly to a remote server as a n/w glitch will corrupt your backup. – Kin Shah Jan 7 '14 at 15:44
  • 2
    @Kin "write backups to a remote server" would not occur over 1433. I'd of thought we were talking about SMB ports? – Mark Storey-Smith Jan 7 '14 at 17:45
  • @MarkStorey-Smith Yes, should have made it clear in my comment. It is the port on which sql server will listen the incoming client requests. – Kin Shah Jan 7 '14 at 17:55
  • are you able to copy backup done locally to your network share ? – Kuba Miazek Jan 9 '14 at 10:19

Remote file access occurs over SMB. Remote backups are just another form of remote file access. See File and Sharing Protocol Stack.

If you use SMB over TCP directly (ie. disable NetBIOS) then the port used is 445, both UDP and TCP. If you use NetBIOS then it requires 137 both UDP and TCP, 138 UDP and 139 TCP. See Directly Hosting SMB over TCP/IP:

NetBIOS over TCP traditionally uses the following ports:

nbname            137/UDP
nbname            137/TCP
nbdatagram        138/UDP
nbsession         139/TCP

Direct hosted "NetBIOS-less" SMB traffic uses port 445 (TCP and UDP).


I am doing remote backup by backing-up locally and then copying the bak files to remote storage file share.

I do not think it is much different if to backup directly. Anyway I've checked it with WireShark:

enter image description here

having shown that TCP port 445 was used. Though, depending on Windows version (it was not even clear if your backup will be stored on a device under Windows), TCP port 139 could have been used or whatever the backup application/device/OS is configured to use.

Another question is that a port as such is not sufficient for giving access since it is being "opened" in context of ports, protocols, applications/programs, accounts.

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.