SqlServer 2008 - Enable Net Named Pipes via command line

若如初见. 提交于 2019-12-11 13:23:02

问题


As part of our Integration build we are installing sql server 2008 on a machine then deploying various software on it. One piece of software requires that Net Named pipes is enabled for it to install.

As the server is built automatically as part of our continuous build process, we have to be able to do this via a non-interactive command line.

Does anyone know of a way to enable the named pipes within the "Sql Server Network Configuration" section without a gui? (I.e. Command line only)


回答1:


I think the cli tool sac will do, what you need to do.

http://blogs.technet.com/b/matthewms/archive/2005/10/13/412453.aspx

See the -N option.




回答2:


Turns out that the protocol information is stored in the registry at :

HKLM\Software\Microsoft\Microsoft SQL Server\MSSQL10_50.MSSQLSERVER\MSSQLServer\SuperSocketNetLib

There is also a powershell for Sql Server that is called sqlps.exe that is in the Binn directory of Sql server. That also offers programatic access to the configuration.

In my case, importing a previously exported registry key for the net named pipes works just as I want it too.



来源:https://stackoverflow.com/questions/9084510/sqlserver-2008-enable-net-named-pipes-via-command-line

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!