django配置sqlserver出错
出现错误:
[^Could not connect because the maximum number of '1' dedicated administrator connections already exists. Before a new connection can be made, the existing dedicated administrator connection must be dropped, either by logging off or ending the process. [客户端: 127.0.0.1]]:
及错误:
[^Login failed for user 'python'. 原因: 基于登录名的服务器访问验证失败,出现基础结构错误。请检查以前的错误。 [客户端: 127.0.0.1]]:
这两个错误是因为 sqlserver没有运行在默认端口 1433上,有时还会抛出 TCP Provider:连接不可用 等错误。
解决办法是在 sqlserver配置管理器里打开当前使用的数据库实例的 TCP/IP服务,然后重启当前数据库实例。