Solved

I am getting an error trying to backup my SQL database

Posted on 2008-10-07
18
840 Views
Last Modified: 2011-10-19
I am getting an error when I try to use the SQL Server Management Studio.  There are two files beginning with the letters sm that I need to backup so that I can restore to a new server.  I highlight the file and click on backup.  The backup desination and file name show as \sm.bak.  If I try try to execute the backup it errors and talks about the backup destination setting.  I am attaching a copy of the error.  I am on a Windows XP station and a computer administrator with no security set.
Property BackupDirectory is not available for Settings 'Microsoft.SqlServer.Management.Smo.Settings'. This property may not exist for this object, or may not be retrievable due to insufficient access rights.  (Microsoft.SqlServer.Express.Smo)

Open in new window

0
Comment
Question by:captjcret
  • 6
  • 5
  • 5
  • +1
18 Comments
 
LVL 41

Expert Comment

by:graye
Comment Utility
So, what exactly are you trying to do?    
If you need to backup a database, then you'd use the SQL's BACKUP command.   If you're trying to backup some file, then you'd use the OS's NTBACKUP command
0
 

Author Comment

by:captjcret
Comment Utility
Where would I find a list of syntax's of SQL backup commands that I can run.  I have a strong DOS background but no very little about SQL except that it is a database manager/server.
0
 
LVL 75

Expert Comment

by:Anthony Perkins
Comment Utility
Look it up in SQL Server Books Online.
0
 
LVL 41

Expert Comment

by:graye
Comment Utility
Most folks just use the SQL Management Studio... you'd just navigate to the database, do a right click, and select backup
0
 

Author Comment

by:captjcret
Comment Utility
I do navigate to the database and select backup.  When I try to execute it is when I get the error message I attached.
Property BackupDirectory is not available for Settings 'Microsoft.SqlServer.Management.Smo.Settings'. This property may not exist for this object, or may not be retrievable due to insufficient access rights.  (Microsoft.SqlServer.Express.Smo)

Open in new window

0
 
LVL 41

Expert Comment

by:graye
Comment Utility
Spooky.... OK, well it certainly looks like your version of SQL Server is a little messed up.   I'd recommend a complete uninstall followed by an install
0
 

Author Comment

by:captjcret
Comment Utility
What happens to the database if I do a complete uninstall?
0
 
LVL 38

Expert Comment

by:Jim P.
Comment Utility
Do a Help --> About and make sure you have the current service packs for the Management Studio.

Then are you seeing something like below when you are trying to backup?
Q-23795470-View.jpg
0
Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

 
LVL 41

Expert Comment

by:graye
Comment Utility
The database files themselves are not removed during an uninstall.    However, if you want to be one the safe side, you can shutdown the SQL Server service and copy the database files to somewhere safe
0
 
LVL 38

Expert Comment

by:Jim P.
Comment Utility
>> you can shutdown the SQL Server service and
>> copy the database files to somewhere safe

That is provided it is an actual separate DB from the system DB.

I'd suggest that he hold off on that until we can get a better description of what is going on.

0
 

Author Comment

by:captjcret
Comment Utility
Jimpen,  I am seeing a tree simular to the one in your example.  When I expand the folder databases I can see two database files that I have been told I need to backup.  They begin with the letters "sm"
When I right click on either one I can go to tasks and then under tasks, backup.  With the backup screen up,  I execute and that is when I get the error message.  The destination for the backup says \sm.bak.
I have tried to remove the destination file and location and when I click on add for a new location I get the attached error.
Property BackupDirectory is not available for Settings 'Microsoft.SqlServer.Management.Smo.Settings'. This property may not exist for this object, or may not be retrievable due to insufficient access rights.  (Microsoft.SqlServer.Express.Smo)

Open in new window

0
 
LVL 38

Expert Comment

by:Jim P.
Comment Utility
Ok, that clarifies it a bunch.

You need to fully qualify the destination path such as "C:\MyPath\SM.bak". You can't use a UNC or a non-local drive to save to.

Something like the images below. Note that you want to save them to 2 different files. It is much easier that way.
Backup-DB-Screen.jpg
Backup-Destination-Screen.jpg
0
 
LVL 41

Expert Comment

by:graye
Comment Utility
It still sounds to me like a corrupted install...   but give it a whirl and let us know
0
 

Author Comment

by:captjcret
Comment Utility
Hi Jimpen,  I am unable to change the destination backup directory.  It is grayed out.  I realized that when I am logging into the SQL server managment program by default I am logging in with Windows Authentication and I have notice that there is an option for logging in with SQL server authentication.  I am thinking that it might make a difference with the backup tools.  I am not the one who origionally installed this software so I don't know what the SQL server authentication would be.  Is there a default admin password that comes with SQL?
0
 
LVL 38

Accepted Solution

by:
Jim P. earned 250 total points
Comment Utility
>> I am unable to change the destination backup directory.  It is grayed out.

That sounds like your permissions aren't sufficient to do backups.

>> I realized that when I am logging into the SQL server management ....

There is Windows Authentication or Mixed mode (which is SQL Authentication or Windows Authentication).

>> I am thinking that it might make a difference with the backup tools.

The SA is the default SQL login that has full permissions to do anything. The other way is to have your login (MyDomain\UserID) added to the Sysadmin role in the SQL Server security.

>> Is there a default admin password that comes with SQL?

There isn't a default password but SQL 2005 requires that a password be set for SA even if the mixed mode is turned off.

-----------------------------------
Below is the way to run the backups from a Query Window. You still may not be able to do it from the security viewpoint for your userid.
BACKUP DATABASE [AdventureWorks] 

        TO  DISK = 'D:\MyPath\AdventureWorks.bak' 

        WITH NAME = 'AdventureWorks-Full Database Backup', 

        STATS = 5

GO

RESTORE VERIFYONLY FROM  DISK = N'D:\MyPath\AdventureWorks.bak' WITH  

GO

----------------------------------------------------

restore filelistonly 

        from disk='D:\MyPath\AdventureWorks.bak' 

 

 

/************ Remove the slash and asterisks to uncomment this text

 

RESTORE DATABASE [AdventureWorks] FROM  

        DISK = 'D:\MyPath\AdventureWorks.bak' 

        WITH  

        MOVE 'Logical_FileName_Data' TO 'E:\MyPath\AdventureWorks.mdf',  

        MOVE 'Logical_FileName_log' TO 'E:\MyPath\AdventureWorks.ldf',  

        NOUNLOAD,  REPLACE,  STATS = 5

GO

*****************/

Open in new window

0
 
LVL 38

Expert Comment

by:Jim P.
Comment Utility
Can I ask why a B grade?

What's the right grade to give?

Grading at Experts Exchange is not like school. It's more like the "10-point Must" system in professional boxing; in other words, an answer is worth an A, unless it doesn't resolve your issue. If it requires you to do a little more research, or figure out one more piece of code, then it's worth a B. If you think it's not worth a B, the custom is to offer the Experts an opportunity to earn a better grade.

Giving a higher grade has no impact on your Available Points.
0
 

Author Comment

by:captjcret
Comment Utility
I apologize for the "B" grade.  You guys were actually great!  I am afraid it turns out that the database is corrupt and there is no backup.  I shouldn't take that out on you guys.  I didn't realize it was such a sensitive thing and will remember it when scoring in the future.  Again, Thanks
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
Shadow IT is coming out of the shadows as more businesses are choosing cloud-based applications. It is now a multi-cloud world for most organizations. Simultaneously, most businesses have yet to consolidate with one cloud provider or define an offic…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

762 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

9 Experts available now in Live!

Get 1:1 Help Now