Feed on
Subscription

Technology of SQL Server database (102)

15.3.1 manages backup with SQL Server Enterprise Manager
No matter be a database,back up in SQL Server,Still be clerical log backup, difference backup, file or file group backup implement same measure.The move that use SQL Server Enterprise Manager has backing up is:
(1) the SQL Server Enterprise Manager that start,The database server that logins to appoint.
(2) open database folder,Right attack the database icon that should undertake backup,Playing an AllTasks of the choice on menu,Reelection choose Backup Database,Shoot a dialog box of SQL Server Backup next.Place of the 15-2 that be like a graph is shown.


(3) sheet chooses to choose pushbutton to choose to want to have which sort inside the column of Backup option of the page of General label of dialog box of SQL Server Backup model backup (examine graph 15-2) .
(4) will choose backup equipment through clicking Add pushbutton.Shoot a dialog box of Choose Backup Destination next,Place of the 15-3 that be like a graph is shown,Sheet of optional choose File Name chooses pushbutton and give out file name and road classics,Also can choose sheet of Backup Device to choose pushbutton,Choose backup equipment from inside setting draw a frame round next.


(5) in column of Overwrite option,If chose sheet of Append To Media to choose pushbutton,After adding backup content current backup;If chose sheet of Overwrite Existing Media to choose pushbutton,Enclothe former backup.
(6) Schedule answer choose casing,Can undertake installing to the schedule of backup,The timeline that the pushbutton that clicks the right side will come to change backup,When does set backup operation undertake in shooting a dialog box of Edit Schedule,Place of the 15-4 that be like a graph is shown.


(7) in name of task of arrangement of backup of the input in Name,Acquiesce is Schedule1.Aleatoric sheet is clicked to choose pushbutton in column of Schedule Type option (among them each option meaning sees SQL ServerAgent of the seventeenth chapter) .The backup time that can click Change pushbutton to change current acquiesce is installed.Can shoot a dialog box of Edit Recurring Job next,Place of the 15-5 that be like a graph is shown.


(8) the time that sets backup by his requirement in dialog box of Edit Recurring Job,Click OK next,The time that finish is installed.
(9) in dialog box of Database Backup label of choice Option undertakes 15-6 place is shown adding installing if pursue,choosing the dialog box after Option label.


(10) pass in column of Option option click answer choose casing to undertake choosing,If pitch on Verify Backup,State SQL Server can read all backup to check backup,Medium is readable,The integrality that assures medium;If pitch on a tape is played instantly after Backup Eject Tape states backup is finished;If pitch on the medium that Check Media Set Name and Backup Set Expiration represent to check make choice of and backup setting are invalid;If pitch on Backup Set Will Expire,Should choose Expires On,Will decide how to be opposite already some backup equipment undertake enclothing.
Among them:Expires After shows tape or the day before file coverture lid is counted.
The date that Expires On shows tape or the file is enclothed.
(11) click affirmatory pushbutton,Found backup.

15.3.2Transact-SQL commands backup database
In SQL Server command of use BACKUP undertakes backing up operating.
1 backs up integer occupies a library



The meaning of each parameter option explains as follows:DATABASE
Express to undertake the database backs up and not be clerical log backup.Database_name | @database_name_var
The database name that expresses to want to undertake backup or variable.BLOCKSIZE
Division of the each data inside backup medium piece it is an unit with Byte denotive size.If use disk medium,The size that backup will decide data division automatically;If use pipeline,And not the size of demonstrate data division,Acquiescent its are 64KB;If use tape,The BLOCKSIZE when using FORMAT option only ability is effective,Did not appoint its big hours,Criterion the system can choose proper data area size automatically.DESCRIPTION
The text that describes backup setting.Have 255 at most character.DIFFERENTIAL
Express to back up only since undertaking complete database backs up last,The change that database place produces,Undertake difference backs up namely.EXPIREDATE
The period of validity that expresses to withhold backup document,If exceed this reservation period,The data on backup medium can be enclothed.RETAINDAYS
The day that represents backup file to be able to be withheld in backup medium is counted,If exceed the data on medium of this days of number criterion,can be enclothed.When using INIT option only,This option ability is effective,If use SKIP,Criterion this option is invalid.FORMAT | NOFORMATF
FORMAT expresses to will back up medium head autotypes formerly,All data that get on former medium thereby are enclothed.If your backup medium is,comprise by many disk or tape,only should among them one chose FORMAT option,The data on whole backup medium will disable.If use NOFORMAT option,Unless assigned INIT option,Otherwise incorrect backup medium autotypes.INIT | NOINIT
All data that INIT represents backup medium to go up will be enclothed,Medium head will be withheld.But on the name of backup result market that if be in,gives out in BACKUP command and backup medium do not match,Back up medium won't be enclothed.NOINIT expresses to will back up result collect is added in current backup medium to go.MEDIADESCRIPTION
The text version that expresses to have a description to medium collect,Its length does not exceed 255 character.MEDIANAME
Represent medium name,Its length does not exceed 128 character.NAME
The name that represents backup result part,Its length does not exceed 128 character.NOSKIP | SKIP
When expressing to command in executive BACKUP,The name that whether checks part of result of the backup on medium period of efficacy or medium above all,Cover backup medium again next.NOUNLOAD | NULOAD
The magetic tape station is automatic after expressing to be finished in backup take and exit a magetic tape station,This option is used at tape equipment only.RESTART
The backup that states SQL Server begins to be interrupted afresh is operated,Use this option to be able to save time,Because backup will be broken from which,the dot undertakes then,is not to begin from the beginning.This option applies to tape medium only and need many tape.If you are using hank tape,Criterion this option is not usable.STATS
Express to be over in backup after data of some per cent,The information that place should show.TRUNCATE_ONLY
The blame activity share that represents daily record of cleared general affairs,is not to undertake clerical log backs up.Because do not have clerical daily record
Backup,When carrying out the BACKUP that contains this option to command so,Do not need to point out backup equipment.

Notice:If what you use backup strategy is:Be over into travel database portion of reorganize and outfit,And do not depend on clerical log back up and restore according to the library into linage,The BACKUP that is undertaking integer contain this option according to after the library backs up, be being carried out so commands,Keep clear of thereby part of activity of clerical log Central Africa.
Must undertake before use TRUNCATE_ONLY option complete database backs up,The is not mobile part work that will not restore to be eliminated otherwise.NO_LOG
The clerical log share that expresses to keep clear of to be not an activity,But the distinction of its and TRUNCATE_ONLY is in:When option of use TRUNCATE_ONLY,SQL Server still records BACKUP LOG to command,And use NO_LOG,SQL Server does not record BACKUP LOG to command.Because this is become clerical log by cram when,Can use NO_LOG option only,Because of the BACKUP of any other forms the command will bring about SQL Server to record BACKUP LOG to command,But clerical log already by cram.NO_TRUNCATE
Represent daily record of backup general affairs,And not cleared it.Using this option is to restore the database that is destroyed.When carrying out the BACKUP LOG that contains this option to command,Clerical log records all general affairs that from recently clerical log backs up database failure is nodded.But the backup device that uses this option to need to differ clerical log and database backup consist in
Go up,And Master database did not suffer destroy.


Related:

    收藏到网摘:

    Submit: