Solved

Permission require to truncate transaction log

Posted on 2014-11-20
4
409 Views
Last Modified: 2014-12-05
Any advice what is the permission require to perform truncate transaction log (non sa equivalent)?
0
Comment
Question by:Keng0499
  • 2
4 Comments
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 500 total points
ID: 40454587
to perform truncate log, you need the backup log permission:
http://msdn.microsoft.com/en-us/library/ms179478.aspx
Security -  Permissions
BACKUP DATABASE and BACKUP LOG permissions default to members of the sysadmin fixed server role and the db_owner and db_backupoperator fixed database roles.
0
 

Author Comment

by:Keng0499
ID: 40454595
So, if the user has BACKUP DATABASE and BACKUP LOG permission, than it should truncate the log also.
0
 
LVL 142

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 40454605
the user could truncate the log

however, truncating the log is not a regular action to be executed, only if really needed
typically, if the log file has grown MUCH too large, and you need to bring back the size to a reasonable size
in which case to not is that if you expect the log file to SHRINK as a result of the truncate log statement, you did not yet understand fully how the transaction log file works, and you should do some readings on that subject
0
 
LVL 16

Expert Comment

by:Gerald Connolly
ID: 40459372
What is it you are trying to do? Is it to reclaim space?
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
AD 2008  to 2012/16 ? 3 34
table fragmentation 40 74
SQL server 2008 SP4 29 33
How to calculate iops? 12 27
In this article I will describe the Detach & Attach method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
This video discusses moving either the default database or any database to a new volume.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now