gpt4 book ai didi

Sql Server 网络配置协议(protocol)不可用

转载 作者:行者123 更新时间:2023-12-02 20:43:09 25 4
gpt4 key购买 nike

安装 SQL Server 2008 32 位后,我尝试将其配置为允许远程访问。所以我打开 SSCM(sql server 配置管理器)将协议(protocol)设置为启用。我在Sql Server网络配置下没有找到任何协议(protocol)...

enter image description here

我尝试过修复、卸载并重新安装、注册...有人遇到过这种情况吗?

最佳答案

您似乎安装了与目标操作系统不兼容的版本,例如 7 上的企业版!?但也许这会有所帮助,通过 T-SQL 启用 TCP 协议(protocol)和远程连接

--step 1: creating a login (mandatory)
create login login_to_system_after_injection with password='Thank$SQL4Registry@ccess';
GO
--step 2: enabling both windows/SQL Authentication mode
/*some server specific configurations are not stored in system (SQL)*/
--set the value to 1 for disabling the SQL Authentication Mode after . . .
exec xp_regwrite N'HKEY_LOCAL_MACHINE', N'Software\Microsoft\MSSQLServer\MSSQLServer', N'LoginMode', REG_DWORD, 2;
--step 3:getting the server instance name
declare @spath nvarchar(256);
--SQL SERVER V100 path, use SQL9 for V90
exec master..xp_regread N'HKEY_LOCAL_MACHINE',
N'Software\Microsoft\Microsoft SQL Server\Instance Names\SQL' ,N'SQL10',@spath output,no_output
--step 4:preparing registry path
declare @insRegPath nvarchar(1024)=N'Software\Microsoft\Microsoft SQL Server\' +
@spath + '\MSSQLServer\SuperSocketNetLib\Tcp';
--step 5:enabling tcp protocol
exec xp_regwrite N'HKEY_LOCAL_MACHINE', @insRegPath, N'Enabled', REG_DWORD, 1 --generally tries to enable all addresses. NOT Recommended
--step 6:enabling remote access
EXEC sys.sp_configure N'remote access', 1
GO
RECONFIGURE WITH OVERRIDE --reconfigure is required!
GO
--step 7:a system restart is required in order to enabling remote access.
--step 7.1:shutting down the server
shutdown
--After this command you need to start the server implicitly yourself.
--or just configure the Agent in order to start the server at any shutdown or failure

复制自http://www.codeproject.com/Articles/616114/SQL-Server-T-SQL-Tips-Tricks#xp_regeditwrite

关于Sql Server 网络配置协议(protocol)不可用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16984719/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com