All Questions

Tagged with
Filter by
Sorted by
Tagged with
3
votes
5answers
133 views

Restore a database with a different name on the same server

I need a copy of a live database called Carers on the same server for testing purposes. The test database name will be Carers_Test. I took a backup of Carers using SSMS. And tried to restore it using ...
1
vote
1answer
76 views

problem with the restored database

I have a database storing user login credentials of my application in a Table. When I backed up and restored my database to another server, the restore is successful but the login is timing out (SQL ...
1
vote
2answers
30 views

restoring to new db putting old db into restore

The image below says it all. I need to get some data out of a back-up that's two weeks old, so I restored to a new db called ETLFix. However, when I started the restore my production DB, ETL went ...
3
votes
2answers
107 views

Restore from SQL Server 2008 to 2014

When a full-backup is restored by the DBA, does the DBA need to restore permissions, users, and roles separately? Or does it all come with the full restore? I am from the dev team. We are migrating ...
0
votes
1answer
34 views

Restoring a Database Using Full Backup and Transaction Logs in SSMS

I have a full backup file (.bak file) of a database for the 25/10/2019. However I want to restore the database to the 21/10/2019. My problem is that I do not have the full backup files for the 21/10/...
0
votes
5answers
109 views

Restore DB Backup with limited amount of disk space

I want to restore a SQL Server database using a backup (.bak) of about 60GB. Is it possible to do this on a machine with only 100GB of free disk space? Or do I need at least the 60GB for the .bak ...
1
vote
1answer
45 views

Restore plan cache and buffer pool after database restore? [duplicate]

When restoring a database, is there a way to restore the plan cache so it doesn't have to be re-created during production use? Similar question: is there a way to pro-actively restore the buffer ...
0
votes
0answers
37 views

DB Maintainance Job Fails Single User Mode

we have a stored proc where we rebuild indexes and also take Backup of filegroups.Following is part of the code. But this job is failing since few weeks for error message : Error : Executing the ...
1
vote
1answer
58 views

Backup too big to restore

I have a backup which in file explorer is roughly 160GB. If I run select sum((size*8)/1024) From sys.database_files where type=0 I get a result of 169493, fine. When I try to restore this ...
1
vote
0answers
29 views

How to force SQL Studio not to use copy-only backups to build database restore script?

How to force SQL Studio not to use copy-only backups to build database restore script? I want to ommit copy-only backup (because it's not longer available) and force studio to use last full backup (I ...
0
votes
1answer
39 views

Restore database with Availability Groups

I have high availability enabled with two servers and when trying to restore a database I realised I had to un-synchronize the database and then remove it from the availability group. I use Ola ...
1
vote
1answer
24 views

Can you Identify the sql server name from sql backup file(.bak)?

I have a backup file from an SQL 2016 server and I need to identify which SQL server the file was created on. Is there a way to identify the original SQL server where the file originated at? Thank ...
2
votes
1answer
222 views

SQL Server Restore Failing with Error Read on “M:\MSSQL\My_FULL_Backup_20190924_010558.bak” failed: 1101(A tape access reached a filemark

I have been trying to restore one of our db for the past few days without any luck. I keep getting the below error. I tried the restore during peak hours, off peak hours both by accessing the backup ...
13
votes
1answer
2k views

Temporarily moving a SQL Server 2016 database to SQL Server 2017 and then moving back. Is it possible?

If I take a backup of a database from a SQL Server 2016 instance and then restore it to a 2017 instance to do some work on it. Can I then turn around and back up that database from the 2017 instance ...
1
vote
2answers
73 views

Does restoring a database in Microsoft SQL Server add objects to Resource Database?

As far as I know the resource database contains information on all objects in its server instance, so I would think it's only natural that when you restore a database from a backup file, part of the ...
1
vote
2answers
83 views

Sql Server Restoring Process Time Takes Too Long Time

I have 7 databases on my reporting server. I restore those databases every night with differetial backups. Normally, the differential restore time was taking about 1 or 1.5 hour for each databases. ...
1
vote
1answer
66 views

What is the purpose of keeping filegroup or filestream backup in MSSQL?

I'm a new DBA for SQL SERVER. Currently I'm learning about filestream on SQL server. So I tried to restore only filegroup of filestream to other database, but I get an error message: An exception ...
3
votes
0answers
234 views

No backupset selected to restore

I have 2 cloud SQL Servers, one in Azure, one in AWS (I don't think the cloud platforms matter here but including them just to be thorough). I'm unable to restore a database from the Azure server to ...
1
vote
1answer
109 views

RESTORE database now in Emergency

We have a database that was basically used for application purposes but it was using "master" - bad indeed. We created a new database called school that is now being used (same structure as how master ...
1
vote
1answer
52 views

Incremental backup between now and backup taken one week ago

We do a full backup of our SQL Server 2012 database every night. A new developer needs an incremental (or differential) backup of a backup we took one week ago. The reason is that for them, ...
5
votes
1answer
171 views

Restore stuck in ASYNC_IO_COMPLETION

Very frequently when I restore databases the restore operation gets stuck and the wait type is ASYNC_IO_COMPLETION. It can be in such state for 10-20-30 minutes untill it proceeds to ...
3
votes
2answers
99 views

How to query data in backups?

I have an ASP.NET app using SQL Server 2017. There's a bug somewhere that's causing some records to be deleted, and I'm trying to recover the data and find the cause of the bug. We take daily backups, ...
-2
votes
2answers
67 views

get data from express edition db to developer edition [closed]

How to get database in new created SSMS sql server developer edition but I don't have back up of database but mdf file and ldf file are available.
0
votes
2answers
241 views

SQL Server Backup Database not .bak file format

I've been using SQL Server 2012 for as long as I can remember. When I do a backup it's always saved as .bak file format. However, there's this other server that has SQL Server 2012 and when I do a ...
4
votes
2answers
152 views

Finding out who changed the owner of a database when performing a restore

A coworker who worked on restoring a backup changed the database owner from his name to 'sa' (rightly so) last night. While I had seen the his name in a SQL Server Management Studio window, I did not ...
1
vote
1answer
76 views

Restore of a database failed - Table does not contain an identity column

I've created a local SQL Server instance (using SQL Server 2017). I'm trying to restore a backup of a database created on a SQL Server 2012 server, for testing purposes. The problem is that it ...
0
votes
1answer
53 views

How to check there is enough disk space before overwriting a DB with restore command

I need to automate the restore of a database each night from a backup but I want to first check if there is enough disk space. In the below Microsoft link it says the verifyonly command is able to do ...
9
votes
1answer
172 views

How do I find the FamilyGUID of an exsting database

When executing a RESTORE command, I understand that SQL Server ensures that an existing database is not being overwritten by a different database. This check can be bypassed using REPLACE. I ...
0
votes
0answers
71 views

End of file reached. Error 38 in SQL. Passes verification checks

Having issues restoring a database in SSMS, error 38. The databases are transferred up to google via their Drive API. Download it on my side and has error. If I transfer it through teamviewer ...
1
vote
2answers
44 views

How to verify the restored MS SQL DB from Backup matches with the source?

Once you restore the backup, how do you verify that the source and destination are in sync (schema, datatypes, number of records etc)? assuming that the source has not change. Appreciate your insights....
0
votes
1answer
130 views

SQL Server Agent Job - Unable to open Step output file. The step succeeded

I have seen many posts with "Unable to open Step output file.", but can't find any references where the step succeeded. I have my output file location set to: $(ESCAPE_SQUOTE(SQLLOGDIR))\$(...
2
votes
1answer
82 views

How to check if backups are reliable?

I generally have to restore databases to different servers after important data imports or other important and delicate database operations. I need to be sure that my backups up to that point in time ...
1
vote
1answer
34 views

Legacy data migration to Always on Availability group database

In our application there is a data conversion process that brings all the legacy data to the production database. Since our database is on availability group and the migration might bring 100GB + ...
0
votes
0answers
19 views

Migrating AWS RDS SQL Server to a smaller RDS instance

I am in the process of migrating an AWS RDS SQL Server to another instance of AWS RDS SQL Server with lesser storage. AWS folks suggested using the native backup/restore option instead of DMS. Steps ...
6
votes
2answers
1k views

How can I restore a master database from its bak file?

During a penetration test I found multiple .bak-files for an MSSQL database. I want to restore them all. In a Windows VM I installed SQL Server 2017. For restoring the master database, I put the ...
2
votes
1answer
51 views

How to attach a sql db with blobs using a shared folder?

I use the following query for attaching a sql db: CREATE DATABASE [myDb] ON (FILENAME=N'C:\myDb\myDb.mdf'), (FILENAME=N'C:\myDb\myDb_log.ldf'), (FILENAME=N'C:\myDb\FILESTORE') FOR ATTACH In ...
1
vote
1answer
90 views

Having a backup of the master key, how can I restore a database that was encrypted by master key?

while setting up AlwaysOn - Availability Group on a test system, I generated all the restores from live and restored them to this new server. then I backup all these databases to a network share to ...
7
votes
1answer
203 views

After Restoring Log Shipping to Secondary Server, First Stored Procedure Execution is Slow

We've set up log shipping to a secondary SQL server on Standby/ Read-Only to offload all SSRS report generation. This works fine within the restrictions imposed by: Kicking out the user during the ...
-1
votes
1answer
37 views

Database in restoring state and transaction duplicates

I use following PS script to restore database: $sqlScript = @" USE master GO ALTER DATABASE mydatabase SET SINGLE_USER WITH ROLLBACK IMMEDIATE GO RESTORE DATABASE mydatabase FROM DISK = '\\...
4
votes
1answer
84 views

Point in time Restore failed - Error 3456 'Could not redo log record'

I have a database from which all tables got deleted by accident. Unfortunately we do not have a 'perfect' backup and now my problem comes in: FULL Backup is from yesterday, 18:00 LOG Backup wasn't ...
2
votes
2answers
34 views

Database Merging / Re-integration

I am a SQL Server DBA. I recently had the misfortune of losing a database due to drive failure. I was able to restore the data but for whatever reason, it stopped at a certain time and not all of the ...
0
votes
2answers
303 views

User and login mapping after an SQL Server restore

I need to restore a DB from an SQL Server instance to another and I am well aware that the DB users will be transferred but the logins won't. I have created a script to be able to create the logins on ...
1
vote
1answer
103 views

Having the backup file, how to work out the total disk space required to do the restore?

I have a nice query that gives me the date of last full backup, size and location, even when I backup to multiple backup files. what I don't have is an estimate of the total backup size (for each of ...
0
votes
2answers
90 views

Recover all databases to a new server

I need to copy an entire SQL Server instance, with all databases from one server to another server in my test lab. I am aware that this can be done the "cold way", by stopping/pausing the databases ...
1
vote
1answer
46 views

Piecemeal restore, filegroup and file extension

As per my understanding (so far) any given user database contains three types of files - mdf, ndf and ldf. MDF stands for meta data file and stores data definition as well as data (in case of small ...
-1
votes
1answer
591 views

Restore database - Operating system error 5(Access is denied.) on Linux

I try to restore SQL Server 2017 Express database using sqlcmd tool on Ubuntu 16 Server. My SQL command is: RESTORE DATABASE [xxxxx] FROM DISK = N'/home/xxxxxx/DBBackups/xxxx.bak' WITH NORECOVERY, ...
4
votes
1answer
272 views

Does restoring a database break external synonyms targeting objects in that database?

If one has a database where synonyms in another database refer to objects in that database, does restoring a backup into that database invalidate the synonyms? To be specific, imagine this situation: ...
2
votes
1answer
58 views

Creating encrypted backups inhouse to be restored at client

I am trying to understand the mechanics of database backup encryptions, but there are some issues, which I can't seem to wrap my head around. I have 2 requirements: I need to be able to create and ...
0
votes
1answer
113 views

How can I restore a backup without overwriting ALL of the tables?

I have a SQL Server database with 3 tables. I need to restore a backup that contains 4 tables, while still keeping the old data in the original 3 tables. Is this possible?
2
votes
1answer
57 views

How to find out the oldest full backup still existing on disk?

one of the things I like to find out is what is the oldest full backup file still living in my servers. it is the custom to delete or move those files to a different place after a number of days. How ...