SQL Server DBA Tutorial 32- How to Shrink Database And Database Files in SQL Server

  Рет қаралды 119,316

TechBrothersIT

TechBrothersIT

Күн бұрын

Пікірлер: 26
@m.sprakash3851
@m.sprakash3851 5 жыл бұрын
Really Helpful tech Brothers
@TechBrothersIT
@TechBrothersIT 5 жыл бұрын
Thank you dear.
@ByronForrest2010
@ByronForrest2010 9 жыл бұрын
Thank you very much, your instruction was most helpful.
@TechBrothersIT
@TechBrothersIT 9 жыл бұрын
+Byron Forrest you are welcome and thanks for watching. Glad to hear you liked the video!
@roshanrafeek
@roshanrafeek 8 жыл бұрын
This is really helpful.. Thank you very much...
@jaswanthreddy3782
@jaswanthreddy3782 2 жыл бұрын
Hi, I've got ssms 2019 server, I'm trying to shrink the database but I didn't find the option Task, so how do we actually shrink without it showing the option?
@manatelugu3779
@manatelugu3779 3 жыл бұрын
TQ you for good explanation
@TechBrothersIT
@TechBrothersIT 3 жыл бұрын
So nice of you
@haithamelatrache1231
@haithamelatrache1231 3 жыл бұрын
Thanks for the video may I ask you what to check and why do I have the following error when I try to shrink the file Msg 3140, Level 16, State 5, Line 1
@migaelurk
@migaelurk 3 жыл бұрын
Should we "detach"/reattached , or "take offline"/make online on the database after we shrink the file? rather just only "refresh" the database? This is because i noticed that, free space available is getting lesser than before, which is weird.
@shrenikshah7552
@shrenikshah7552 3 жыл бұрын
How shrink database affect in production? will it create outage if we shrink database instead of database file?
@williamcspereira
@williamcspereira 3 жыл бұрын
Thank you for the help!
@draxler2941
@draxler2941 7 жыл бұрын
thanks A lot.... great and helpful toturial!!!
@TechBrothersIT
@TechBrothersIT 7 жыл бұрын
You are very welcome and thanks for watching.
@elbadrey
@elbadrey 6 жыл бұрын
what about notrancate and trancateonly t-sql, and so what is benefit of using empty when shrinking file!!!
@prashantmehra7380
@prashantmehra7380 6 жыл бұрын
What if we have mirroring enabled for the database what would be the steps
@andreigiubleanu
@andreigiubleanu 9 жыл бұрын
Very good sir.
@szp917
@szp917 7 жыл бұрын
Hello, I have a question regarding shrinking the t-log backups on Clustered environment. Scenario is we have 2 DB servers with same instance name say SQL1, SQL2. SQL1 primary and SQL2 is secondary. I have sceduled the T0log backups on primary server using maintenance Wizard, but I cant find any t-log backupsin the destination folder. If we take manual tlog backups we can see them in destination folder but its failing only when scheduled through Maintenance WIzard & clustered environment. Can you please make a video on taking t-log backups on clustered environment. Please let me know if you have any questions.
@TechBrothersIT
@TechBrothersIT 7 жыл бұрын
+Rakesh Joshi when you say it's clustered environment, do you mean sql server is installed in a cluster mode or is it AG (Availability Group) cluster? From your scenario it seems like you have setup AG as you described "primary" and "secondary" - please look at AG properties and see which is preferred replica for backups, when you use normal wizard, take a quick look at TSQL to see whether it is using function to follow AG setup rule? Don't modify existing in prod, just use new wizard until you reach a point where you can view TSQL, you don't have to click ok as it show you the function that it is using or not.
@drups87
@drups87 8 жыл бұрын
Hi, I have a question, I have a Win 2008 R2 SQL server that was never given a correct maintenance and now the transaction log file is about 500 GB. I've made a transaction log backup and now I was trying to shrink the log file it but it only free some little space (about 60 MB) each time I run the shrink task. I've tried both shrink actions ("release unused space" and "reogranize pages before releasing unused space") and the behavior is the same with both options. In the shrink file menu for the log is showing me "Currently allocated space: 492690,31 MB" and "Available free space: 472219,08 MB (95%)". Do you have any idea why Iam not being able to shrink my transaction logs? Thanks in advance! regards!
@TechBrothersIT
@TechBrothersIT 8 жыл бұрын
+Diego Draper (Drups) hi, what is the initial size you have for tran log?
@drups87
@drups87 8 жыл бұрын
Hi, thanks for replying. The initial size for the transaction logs is set to "492,691" as I can see in the database files properties. In autogrowth is set to "By 100 MB, restricted growth to 2,097,152". Thanks in advance. Regards!
@bahaaabouzahr2323
@bahaaabouzahr2323 9 жыл бұрын
thanks
@TechBrothersIT
@TechBrothersIT 9 жыл бұрын
+bahaa abou zahr you are welcome and thanks for watching!
@SalmanAli-ud1kc
@SalmanAli-ud1kc 9 жыл бұрын
if you make this video in hindi to kiya he bat thi
@gepliprl8558
@gepliprl8558 4 жыл бұрын
hmm... explanation unclear around those allocated mb
Мясо вегана? 🧐 @Whatthefshow
01:01
История одного вокалиста
Рет қаралды 7 МЛН
“Don’t stop the chances.”
00:44
ISSEI / いっせい
Рет қаралды 62 МЛН
SQL Server Log File is HUGE!
11:18
Kevin Hill
Рет қаралды 110 М.
SQL Server DBA Tutorial 77-How to Cleanup Old Backups in SQL Server
10:22
DBA Fundamentals: Maintenance: Shrinking Files
15:21
Brent Ozar Unlimited
Рет қаралды 17 М.
Shrinking a database in SQL Server | Shrink SQL server database
13:54
Training2SQL MSBI
Рет қаралды 21 М.
SQL DBA Mock Interview 3 for 4 Years experience
28:43
Solved Pages
Рет қаралды 8 М.
Detach and Attach a Database in SQL Server
10:21
SQL with Manoj
Рет қаралды 88 М.