Create an automated backup plan with SQL Server R2

Source: Internet
Author: User
Tags microsoft sql server management studio sql management studio

This article uses the SQL Server R2 's own maintenance plan to create a task that automatically backs up data.

First, start ? SQL Management Studio, make sure that SQL Server agent is in the startup state. If not, you can right-click to select start .

second , expand Management---Maintenance plan, and right-click Maintenance plan to select New maintenance plan, where you can fill in a meaningful name.

After clicking "OK", the following screen will open, the two places in the red box are the places we need to be aware of.

The third step , click on the right side of the calendar icon of the red box, you can configure your own "job schedule Properties", I configured here: Every day 4 o'clock in the morning repeat, click "OK" after completion.

Fourth Step : Drag and drop the "Back Up Database" task in the red box on the left in the second step to the right, and put it in the appropriate location.

Fifth , double-click the left icon in the Backup database task that you dragged and dropped. Here I select a database to be backed up in the database, where the backup is saved:

D:\Program Files\Microsoft SQL Server\mssql10_50.mssqlserver\mssql\backup, the backup extension is bak. Click "OK" when you are done.

Then click the Save icon on the toolbar.

What if the task we configured is tested successfully? Is it hard to wait till tomorrow? Of course not, you can right-click on your "maintenance plan" and select "Execute".

However, there is a problem, we configure the daily implementation of the backup plan, so the accumulation of the month, not the disk will be blown out? Don't worry, we can then configure a "cleanup maintenance" schedule to delete the earlier backup files.

If your maintenance Plan Design window is closed, right-click and select "Modify" to reopen the design interface.

In the first step , drag and drop the Purge maintenance task from the toolbox on the left to the right and put it in the right place.

Step two : Double-click the icon in the Purge maintenance task and I choose to delete the backup 4 weeks ago. Note that the folder and file extension Here is the location you specified when you selected the backup task above.

This completes the task of cleaning up the early backups. It's a comforting smile,J .

If it helps you, give it a break. J, remember, my name cents ~

?

Create an automated backup plan with SQL Server R2

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.