RMAN的delete命令delete backupset 102;//删除102号备份集delete noprompt expired backup of tablespace xxwz_data;//无提示删
配置retention(保留)策略
不符合策略的备份集被标记为过期,,可查看可删除。
3种配置
rman>configure retention policy to后面可以加如下的3种方式:
1.recovery window of 7 days;时间窗口
保留恢复从今天开始往前7天的数据所需要保留的备份集
2.redundancy 2;冗余度
保留同一数据文件的2份备份集
3.none:手工
cross checking交叉检查:检查rman备份信息和实际是否同步
rman>list backup;
然后操作系统层面手工删除数据文件的备份集;
再次rman>list backup;依然可以查到已删除的备份集的信息;
rman>delete backupset 47;//删除该备份集时出错,说找不到该备份集。
rman>crosscheck backup;//检查
rman>list backup;//该备份集状态为过期。
obsolete VS expired
obsolete是不符合保留策略的状态,意为not needed。
expired是进行交叉检查时不找到的状态,意为not found。
RMAN的delete命令
delete backupset 102;//删除102号备份集
delete noprompt expired backup of tablespace xxwz_data;//无提示删除表空间的expired备份信息。
delete obsolete;//删除不需要的备份集
//备份时删除原来的备份
backup archivelog all delete input;
backup archivelog sequence between 99 and 199 thread 1 delete input;
修改RMAN的备份状态
rman>change backupset 49 unavailable;
rman>change backupset 49 available;
从保留策略中豁免(即不受保留策略的限制)
rman>change backupset 49 keep forever nologs;//永不限制
rman>change datafilecopy 'd:\copy\xxx.dbf' keep until 'sysdate+60';//不限制60天
catalog(登记)手动备份信息到RMAN存储里(可作为0级备份的基础)
登记数据文件
rman>catalog datafilecopy 'd:\backup\xxwz_data.dbf';
登记归档日志文件
rman>catalog archivelog 'd:\arch\arch_12.arc','d:\arch\arch_13.arc';
rman>catalog start with 'd:\arch' noprompt;//登记这个目录的所有归档日志文件信息
取消登记信息
rman>change backuppiece 51 uncatalog;
rman>change datafilecopy 'd:\backup\xxwz_data.dbf' uncatalog;
rman>change archivelog ... uncatalog

mySqlStringTypesimpactStorageAndPerformanCeaseAsfollows:1)長度,始終使用theSamestoragespace,whatcanbefasterbutlessspace-felfficity.2)varCharisvariable varcharisvariable length,morespace-morespace-morespace-effficitybuteftife buteftife butfority butfority textifforlyslower.3)

mysqlStringTypesIncludeVarChar,文本,char,Enum和set.1)varCharisVersAtileForvariable-lengthStringStringSuptoPuptOuptoPepePecifiedLimit.2)textisidealforlargetStortStorStoverStoverStorageWithoutAutAdefinedLength.3)charlisfixed-lenftenge,for forConsistentDatalikeCodes.4)

MySQLoffersvariousstringdatatypes:1)CHARforfixed-lengthstrings,2)VARCHARforvariable-lengthtext,3)BINARYandVARBINARYforbinarydata,4)BLOBandTEXTforlargedata,and5)ENUMandSETforcontrolledinput.Eachtypehasspecificusesandperformancecharacteristics,sochoose

TograntpermissionstonewMySQLusers,followthesesteps:1)AccessMySQLasauserwithsufficientprivileges,2)CreateanewuserwiththeCREATEUSERcommand,3)UsetheGRANTcommandtospecifypermissionslikeSELECT,INSERT,UPDATE,orALLPRIVILEGESonspecificdatabasesortables,and4)

toadduserInmysqleffect和securly,跟隨台詞:1)USEtheCreateUserStattoDaneWuser,指定thehostandastrongpassword.2)GrantNecterAryAryaryPrivilegesSustherthing privilegesgeStatement,usifementStatement,adheringtotheprinciplelastprefilegege.3)

toaddanewuserwithcomplexpermissionsinmysql,loldtheSesteps:1)創建eTheEserWithCreateuser'newuser'newuser'@''localhost'Indedify'pa ssword';。 2)GrantreadAccesstoalltablesin'mydatabase'withGrantSelectOnMyDatabase.to'newuser'@'localhost';。 3)GrantWriteAccessto'

MySQL中的字符串數據類型包括CHAR、VARCHAR、BINARY、VARBINARY、BLOB、TEXT,排序規則(Collations)決定了字符串的比較和排序方式。 1.CHAR適合固定長度字符串,VARCHAR適合可變長度字符串。 2.BINARY和VARBINARY用於二進制數據,BLOB和TEXT用於大對像數據。 3.排序規則如utf8mb4_unicode_ci忽略大小寫,適合用戶名;utf8mb4_bin區分大小寫,適合需要精確比較的字段。

最佳的MySQLVARCHAR列長度選擇應基於數據分析、考慮未來增長、評估性能影響及字符集需求。 1)分析數據以確定典型長度;2)預留未來擴展空間;3)注意大長度對性能的影響;4)考慮字符集對存儲的影響。通過這些步驟,可以優化數據庫的效率和擴展性。


熱AI工具

Undresser.AI Undress
人工智慧驅動的應用程序,用於創建逼真的裸體照片

AI Clothes Remover
用於從照片中去除衣服的線上人工智慧工具。

Undress AI Tool
免費脫衣圖片

Clothoff.io
AI脫衣器

Video Face Swap
使用我們完全免費的人工智慧換臉工具,輕鬆在任何影片中換臉!

熱門文章

熱工具

Dreamweaver CS6
視覺化網頁開發工具

VSCode Windows 64位元 下載
微軟推出的免費、功能強大的一款IDE編輯器

SublimeText3 Linux新版
SublimeText3 Linux最新版

禪工作室 13.0.1
強大的PHP整合開發環境

Safe Exam Browser
Safe Exam Browser是一個安全的瀏覽器環境,安全地進行線上考試。該軟體將任何電腦變成一個安全的工作站。它控制對任何實用工具的訪問,並防止學生使用未經授權的資源。