• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 231
  • Last Modified:

SQL database simple copy backup needed.

Hello, I am attempting to help a friend do a daily copy of a single SQL database.  The server is running Windows server 2008 and SQL server 2008.  Apparently the SQL server is express as there is no management plan option (as I was told).
There is a regular backup being done (I am told).  What is needed is a copy backup to a USB stick to be taken offsite.  It is not a large database. For added protection, they want to keep current data offsite.  FTP is an option down the road but for now, they just want to keep a quick copy of the days data on a USB stick.
I have tried using Windows backup, but ran into problems.  I looked at SQL management, but can't see how to do it.

I am not a server admin, but do know how to do basic server functions (very basic!)
Thank you for your assistance.
0
isitcomputers
Asked:
isitcomputers
  • 2
  • 2
1 Solution
 
lcohanDatabase AnalystCommented:
You can run a SQL command to full BACKUP DATABASE first onto a folder residing on that Server then copy the backup from the same cmd file to the desired path where the usb is.
0
 
lcohanDatabase AnalystCommented:
0
 
isitcomputersAuthor Commented:
Sorry, haven't had a moment to try the advice.  Will try the cmd line option on Monday.
0
 
isitcomputersAuthor Commented:
From this command line:
"C:\Program Files\Microsoft SQL Server\90\Tools\Binn\osql.exe"
    -E -Q "BACKUP DATABASE mydatabase TO DISK='C:\tmp\db.bak' WITH FORMAT"

Being a novice with this stuff (and I do apologize) I have the following questions:

1) Can I or should I change the osql,exe to sqlcmd.exe ?  I see both on the server.

2) Is "mydatabase" the database name that I am backing up?  Do I need the path in the statement?

3) What does "WITH FORMAT" mean ?

4) Can I put this into a script that will run nightly?
0

Featured Post

Veeam Disaster Recovery in Microsoft Azure

Veeam PN for Microsoft Azure is a FREE solution designed to simplify and automate the setup of a DR site in Microsoft Azure using lightweight software-defined networking. It reduces the complexity of VPN deployments and is designed for businesses of ALL sizes.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now