Troubleshoot backup restore issues with trace flag 3004

Written by VidhyaSagar. Posted in Troubleshooting

I faced an issue during restoration of very large db in our development database server. Issue is restoration takes very long time even though we had latest hardware and recent version of SQL Server (it’s SQL 2008 Ent. Ed). So to troubleshoot it I have used the trace flag 3004 which print all internal things happen during backup and restoration operation.

VN:F [1.9.17_1161]
Rating: 5.0/5 (1 vote cast)
VN:F [1.9.17_1161]
Rating: +1 (from 1 vote)

Suppress Backup information in Errorlog

Written by VidhyaSagar. Posted in Troubleshooting

After a long gap Im writing a article. This article is all about suppressing successful backup information into errorlog. Let me explain my scenario, In my working environment we have a production SQL Server with 60+ databases, all the databases are set to full recovery and data loss is accepted only for 15 min. Yeah you got me, we are taking Full backup daily, differential every 4 hours and transaction log backup every 15 min, there is no problem with the backup. We have one thing that is messing our error log, whenever a backup is taken by default SQL Server will write the detail to the errorlog as shown below.

VN:F [1.9.17_1161]
Rating: 0.0/5 (0 votes cast)
VN:F [1.9.17_1161]
Rating: 0 (from 0 votes)

DotNet 3.5 on Windows 7 to Install SQL Server 2008

Written by VidhyaSagar. Posted in Troubleshooting

This is a quick post to install or enable .Net 3.5 on windows 7. Last couple of weeks Im seeing more questions on installing SQL Server 2008 in windows 7 and the users are unable to install SQL Server 2008 pre-requisite (.Net 3.5 ). To Install SQL Server 2008, windows installer 4.5 & .Net 3.5 is required. Windows installer 4.5 is installed and enabled by default, .Net 3.5 is included in windows features, so you can directly go there and turn on .Net 3.5, windows 7 will automatically install this. To turn on .Net 3.5 in Windows 7 just follow the steps below

VN:F [1.9.17_1161]
Rating: 0.0/5 (0 votes cast)
VN:F [1.9.17_1161]
Rating: +1 (from 1 vote)

Troubleshooting Login failed Error 18456

Written by Lekss. Posted in Troubleshooting

Input : select * from sys.sysmessages where error = 18456

Output: Login failed for user ‘%.*ls’.%.*ls%.*ls

This is one of the infamous error message (and number) that most of the DBAs and developers have come across while working on SQL server. This message simply denotes that the client call was able to reach the SQL server and then an ACCESS was denied to the particular login for a reason. To figure out the exact reason, this error number 18456 with its STATE number is logged into the SQL server error log file, if SQL server was allowed or configured to capture the failed logins.

VN:F [1.9.17_1161]
Rating: 3.8/5 (8 votes cast)
VN:F [1.9.17_1161]
Rating: +8 (from 8 votes)

Error: 7139, Severity: 16, State: 1

Written by VidhyaSagar. Posted in Troubleshooting

Last week in our company we have started facing some error while uploading documents to the table. We have an database in which we will be uploading all the documents related to the customers, when the user tries to upload the document he she gets the error message as shown below

VN:F [1.9.17_1161]
Rating: 0.0/5 (0 votes cast)
VN:F [1.9.17_1161]
Rating: 0 (from 0 votes)

Recent Comments

RA

|

Thanks for the script. I had database with space between the names.

I modified to use square brackets:

FROM [?].sys.database_principals a
LEFT OUTER JOIN [?].sys.database_role_members

and

from [?].sys.database_permissions join [?].sys.sysusers U
on grantee_principal_id = uid join [?].sys.sysobjects

Gangadhar NG

|

This tip is helpful enough for me.
thanks.

Zukunftsmusik

|

Thanks! That helped my a lot. But there’s a little mistake:
SQL_Latin1_General_CP1_CI_AS stands for “Latin1-General, case-insensitive, accent-sensitive [...]” therefore sort order 52.

If you want to set the sort order to 54 the correct collation would be “SQL_Latin1_General_CP1_CI_AI” ;)

Amit Bhatt

|

Hi Deepak,

Thanks for such a nice article.

You missed one thing to add in code:
@article = ‘all’,

Hence the script will be like this:
EXEC sp_addsubscription
@publication = ‘mypublication’,
@article = ‘ALL’,
@subscriber = ‘Subscriberservername’,
@destination_db = ‘mydestinationdbname’,
@reserved=’Internal’

Error 18486 | Platformblog

|

[...] SQL-Articles » Troubleshooting Login failed Error 18456This is one of the infamous error message (and number) that most of the DBAs …. 18486. Login failed for user ‘%.*ls’ because the account is currently locked out. [...]