Password protected database backup : Setting backup media password are important and useful for securing misuse of data. If database backup is password protected then one will not be able to restore and see details from backup file using RESTOREFILELIST or HEADERONLY command.
How to take password protected database backup?
Create A Database
If DB_ID('DBS_Test') Is null
Create Database DBS_Test
Go
Backup Database Backup With Password
Backup Database DBS_Test To Disk ='D:\DBS_Test.BAK' With MediaPassword='password'
Go
Drop The Existing Database
Drop Database DBS_Test
Go
Try To Get FileList Info From Backup
Restore FILELISTONLY From Disk='D:\DBS_Test.BAK'
Output :
Msg 3279, Level 16, State 6, Line 1
Access is denied due to a password failure
Msg 3013, Level 16, State 1, Line 1
RESTORE FILELIST is terminating abnormally.
Throws error since no password has been supplied with query.
Try To Get DB Info From Backup
Restore HEADERONLY From Disk='D:\DBS_Test.BAK'
Output:
Msg 3279, Level 16, State 6, Line 1
Access is denied due to a password failure
Msg 3013, Level 16, State 1, Line 1
RESTORE HEADERONLY is terminating abnormally.
Same as above throws error since no password has been supplied with query.
Now Try To Restore Database With Backup File
Restore Database DBS_Test From Disk='D:\DBS_Test.BAK'
Output:
Msg 3279, Level 16, State 6, Line 1
Access is denied due to a password failure
Msg 3013, Level 16, State 1, Line 1
RESTORE DATABASE is terminating abnormally.
So, you have seen that no details or info can be taken from password protected database backup.
How to Get Info and Restore Password Protected Database Backup ?
Get File List Info From Password Protected Database Backup
Output: See Here
Restore FILELISTONLY From Disk='D:\DBS_Test.BAK'
With MEDIAPASSWORD='password'
Get Database Info From Password Protected Database Backup
Restore HEADERONLY From Disk='D:\DBS_Test.BAK'
With MEDIAPASSWORD='password'
Output : See Here
Restore Database From Password Protected Database Backup
Restore Database DBS_Test From Disk='D:\DBS_Test.BAK'
With MEDIAPASSWORD='password'
Output :
Processed 168 pages for database 'DBS_Test', file 'DBS_Test' on file 1.
Processed 2 pages for database 'DBS_Test', file 'DBS_Test_log' on file 1.
RESTORE DATABASE successfully processed 170 pages in 0.214 seconds (6.197 MB/sec).
Thanks for posting this info. I just want to let you know that I just check out your site and I find it very interesting and informative. I can't wait to read lots of your posts. Free Folder Lock Apps For PC - Don't Waste Moment Browsing, Study About Cellular Desktops In this article how to encrypt a backup
ReplyDeleteI am glad that I saw this post. It is informative blog for us and we need this type of blog thanks for share this blog, Keep posting such instructional blogs and I am looking forward for your future posts.
DeleteCyber Security Projects for Final Year
JavaScript Training in Chennai
Project Centers in Chennai
JavaScript Training in Chennai
PLEASE i need help
ReplyDeletei have protected db i don't know the PASSWORD how can i restore it ????
the db link https://goo.gl/gKBwWm
please FIX it and send it back
NOTE:you can read it with notepad and find this( user:sa password:hm12345678)
Hi! I just wanted to ask if you ever have any issues with hackers? My last blog (WordPress) was hacked and I ended up losing months of hard work due to no backup. Do you have any methods to protect against hackers? Get More Info: How To Password Protect Folder In 15 Minutes And Still Look Your Best
ReplyDeleteUnlocking different types of documents is a little more complex, but your VBA passwords may fit to unlock these documents as well, as according to statistics. reset windows 10 password
ReplyDeleteI am glad that I saw this post. It is informative blog for us and we need this type of blog thanks for share this blog, Keep posting such instructional blogs and I am looking forward for your future posts.
ReplyDeleteCyber Security Projects for Final Year
JavaScript Training in Chennai
Project Centers in Chennai
JavaScript Training in Chennai
Thank you for your great post and Keep updating...
ReplyDeleteUnix Training in Chennai
Unix Shell Scripting Training in Chennai
Embedded System Course Chennai
Linux Training in Chennai
Corporate Training in Chennai
Oracle DBA Training in Chennai
Tableau Training in Chennai
Pega Training in Chennai
Oracle Training in Chennai
Unix Training in OMR
Unix Training in Velachery
Excellent post and it is really useful for most of the freshers.
ReplyDeleteJapanese Classes in Chennai
learn Japanese in Chennai
German Courses in Chennai
Informatica MDM Training in Chennai
Hadoop Admin Training in Chennai
spoken english training in chennai
best english coaching centre in chennai
IoT Training in Chennai
content writing course in chennai
spanish language course in chennai
Japanese Classes in Tnagar
Japanese Classes in OMR
This is really an awesome post for all the people who wants information about this technology
ReplyDeletebest medical coding training in chennai
medical coding classes in chennai
cpc training center in chennai
cpc training institute in chennai
CIC Training in Chennai
CIC Coaching in Chennai
best medical coding training in chennai
medical coding classes in chennai
Thanks for sharing this post. it becomes easy to read and understand the information..
ReplyDeletemedical coding centers in chennai
best medical coding training institute in chennai
cpc certification training in chennai
cpc training center in chennai
CIC Training in Chennai
CIC Coaching in Chennai
medical coding centers in chennai
best medical coding training institute in chennai
It is amazing and wonderful to visit your site.Thanks for sharing this information,this is useful to me...
ReplyDeleteSelenium Training in chennai | Selenium Training in anna nagar | Selenium Training in omr | Selenium Training in porur | Selenium Training in tambaram | Selenium Training in velachery
ReplyDeleteHey what a brilliant post I have come across and believe me I have been searching out for this similar kind of post for past a week and hardly came across this. Thank you very much and will look for more postings from you Get for more information STEM Education
I am more curious to take an interest in some of them. I hope you will provide more information on these topics in your next articles.
ReplyDeleteBusiness Analytics Course in Bangalore
I will very much appreciate the writer's choice for choosing this excellent article suitable for my topic. Here is a detailed description of the topic of the article that helped me the most.
ReplyDeleteData Analytics Course in Bangalore
wonderful article contains lot of valuable information. Very interesting to read this article.I would like to thank you for the efforts you had made for writing this awesome article.
ReplyDeleteThis article resolved my all queries.good luck an best wishes to the team members.continue posting.learn digital marketing use these following link
Digital Marketing Course in Chennai