- Remove From My Forums
-
Вопрос
-
Добрый вечер!Не могу решить проблему.
Проблема в том,что не могу подключиться к MS SQL,выдаёт ошибку 18470.
Помогите решить проблему!!Не могу из-за этого закончить диплом ((
Ответы
-
если посмотреть текст ошибки, то
select * from sys.messages
where message_id=18470Пользователю «%1!» не удалось войти в систему. Причина: учетная запись отключена.%2!
говорит о том, что ваша УЗ отключена (disabled)
Войдите под другой УЗ и «включите» её если авторизация СКЛ, либо попросите вашу УЗ активизировать в АД (если Вин-авторизация)
http://www.t-sql.ru
-
Предложено в качестве ответа
27 мая 2010 г. 7:45
-
Помечено в качестве ответа
Daniil KhabarovModerator
8 июня 2010 г. 11:02
-
Предложено в качестве ответа
- Remove From My Forums
-
Вопрос
-
I always used Windows Authentication to login SSMS.
Today it shows error 18470, user ‘SERVERAdministrator’ account is disabled.
Although I still use the sa to login, but how does it comes? and how to enable it again?
Thanks.
Все ответы
-
and how to enable it again?
With
USE [master] GO ALTER LOGIN [SERVERAdministrator] ENABLE;
Olaf Helper
[ Blog] [ Xing] [ MVP]
-
Предложено в качестве ответа
23 июня 2020 г. 6:41
-
Отменено предложение в качестве ответа
MIAOYUXI
23 июня 2020 г. 6:42
-
Предложено в качестве ответа
-
Fail to enable the login SERVERAdministrator
Error: Cannot alter the login ‘SERVERAdministrator’, because it does not exist or you do not have permission.
I check the Logins as below
I create a new login SERVERAdministrator, but it shows: server principal ‘SERVERAdministrator’ already exists error 15025.
How to fix it?
does SQL being hacked? how can I check?
Thanks.
-
Hi UOG,
Administrator account has been disabled and other accounts do not have permission to enable it? for your case, backup your dbs and then
uninstall and
reinstall sqlserver.Best Regards.
m
MSDN Community Support
Please remember to click «Mark as Answer» the responses that resolved your issue, and to click «Unmark as Answer» if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to
MSDN Support, feel free to contact MSDNFSF@microsoft.com -
My computer name is SERVER, not DESKTOP-7BRJ60Q
-
Hi UOG Admin,
I think the most simple and helpful way is to uninstall and reinstall.
I have encountered this and try to use create a new windows administrator account and then try to use DAC method to create one new login and grant it admin permission, however it was fail so I I decisively choose to uninstall and then reinstall
after backup my useful dbs, or add another new instance. And this will not take much time.Best Regards.
m
MSDN Community Support
Please remember to click «Mark as Answer» the responses that resolved your issue, and to click «Unmark as Answer» if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to
MSDN Support, feel free to contact MSDNFSF@microsoft.com -
Hi UOG Admin,
Is the reply helpful?
Best Regards.
m
MSDN Community Support
Please remember to click «Mark as Answer» the responses that resolved your issue, and to click «Unmark as Answer» if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to
MSDN Support, feel free to contact MSDNFSF@microsoft.com -
Hi,
Is the issue solved?
BR
MIAOYUXI
MSDN Community Support Please remember to click «Mark as Answer» the responses that resolved your issue, and to click «Unmark as Answer» if not. This can be beneficial to other community members reading this thread. If you have any
compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com
I am new in SQL Server. Wrongly I disabled my instance when I’d worked with Logins. Now I can not connect to Database Engine.
Could you please help me?
oNare
3,1522 gold badges19 silver badges35 bronze badges
asked Aug 11, 2015 at 13:53
3
Download PSExec from Microsoft, then use it to launch Management Studio once you have it installed: PsExec -s -i «C:…Ssms.exe»
This will connect as NT AUTHORITYSYSTEM and will allow you to do things in Object Explore such as reset SA password. Thanks to user Aaron Bertrand for the information…
answered Aug 11, 2015 at 14:13
HectorHector
1,0121 gold badge8 silver badges22 bronze badges
7
ok looks like you have locked out your SQL login.
Hit the Windows key to bring up the Start menu along with the Search bar. Type «services.msc» in the Search bar. This will launch the Services MMC.
Now find your SQL Server and SQL Server Agent services and stop both of them. Right click the SQL Server service > Properties > Startup and add «-m» in the «Specify a startup parameter» box (without the double quotes). This will start it in single user mode. Now start the SQL Server service.
Next, bring up a command prompt and run this :
- sqlcmd -S your_server_name -E
The «-E» parameter is used to start in Windows Authentication. Now use this syntax to create a new powerful account :
- create login POWERFUL_USER with password=’Change@1000′
- go
- exec sp_addsrvrolemember [POWERFUL_USER], [sysadmin]
- go
- exit
This will now exit you from the command window. You can now connect to SQL Server (with SQL Authentication) by using the POWERFUL_USER username and password.
answered Aug 11, 2015 at 15:12
SQL Server has two types of authentication namely,
- Windows authentication
- Mixed mode (Windows and SQL Server authentication).
If the Mixed mode authentication is not enabled on the server, there will be some issues.
- could not connect using SQL Server Authentication
- The ‘sa’ account will be disabled.
For security reasons, the ‘sa’ account is usually disabled, as it is a well-known SQL server account and it’s often targeted by malicious users. And so, be thoughtful while enabling the ‘sa’ account. And it’s recommended that you use a strong password.
Enable mixed-mode authentication:
- Login into the server using Windows authentication.
- Right-click your server and go to Properties, then select Security.
- Under the Server Authentication section, you will find that the “Windows Authentication Mode” radio button is selected.
- So, your work is to select the “SQL Server and Windows Authentication Mode” radio button.
- Then click Ok.
- Right-click the server again and select “Restart”
- That is it! You have now enabled mixed-mode authentication on your server.
Enabling the disabled account.
- Login using Windows authentication.
- Go to Security, then log in. You will find the disabled account with the small red arrow beside them
- Right-click the login name and go to Properties.
- You should see something like this with the “Disabled” radio button checked.
You need to check the Enabled radio button like this
Restart the server.
Another easier way of enabling ‘sa’ account and setting a password using a query as shown below.
ALTER LOGIN sa ENABLE;
GO
ALTER LOGIN sa WITH PASSWORD = ‘you new strong password’;
GO
That’s it! You have Mixed mode authentication and account enabled.
Have questions? Contact the technology experts at InApp to learn more.
A user reported the error 18470 – when attempting to login to a SQL Server Instance
Login failed for user ‘testLogin’. Reason the account is disabled
They were logging on using SSMS , returning a pop up window similar to the below. They requested the DBA to investigate the error message
To check the current status of the Login use this query to establish whether enabled or disabled. The query is on the sys.server_principals, which contains a row for every server level principal.
select name,is_disabled from sys.server_principals where name = '' --is_disabled --1 = Login disabled --0 = Login enabled --Use ALTER LOGIN command to enable the login account ALTER LOGIN [testLogin] ENABLE
Read More
sp_password and ALTER LOGIN — SQL Server DBA
ALTER AUTHORIZATION sql to change owner of a — SQL Server DBA
SQL Server — List all SQL Server users — SQL Server DBA
Author: Tom Collins (http://www.sqlserver-dba.com)
Share:
Verify your Comment
Previewing your Comment
Posted by:
|
This is only a preview. Your comment has not yet been posted.
Your comment could not be posted. Error type:
Your comment has been posted. Post another comment
The letters and numbers you entered did not match the image. Please try again.
As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.
Having trouble reading this image? View an alternate.