MySQL 8.0 OCP 1Z0-908 101-110題

Q101.which two queries are examples of successful SQL injection attacks?

A.SELECT id, name FROM backup_before WHERE name=‘; DROP TABLE injection; --’;
B. SELECT id, name FROM user WHERE id=23 oR id=32 OR 1=1;
C. SELECT id, name FROM user WHERE user.id= (SELECT members.id FROM members);
D.SELECT email, passwd FROM members
WHERE email= ‘INSERT INTO members (‘email’, ‘passwd’) VALUES
(‘bob@example.com’, ‘secret’);–’;
E. SELECT user,passwd FROM members WHERE user=‘?’;INSERT INTO members (‘user’,"passwd’) VALUES ("bob@example.com’, ‘secret’);–';
F. SELECT id, name FROM user WHERE id=23 oR id=32 AND 1=1;
Answer:BE

SQL注入我不懂
參考:https://blog.csdn.net/DBA_ChenJR/article/details/147816607

Q102.You must run multiple instances of MySQL Server on a single host.Which three methods are supported?
A)Use system tools to lock each instance to its own CPU.
B)Run MySQL Server docker containers.
C)Use systemd with different settings for each instance.
D)Start mysqld or mysqld safe using different option files for each instance.
E)Run mysqld with --datadir defined for each instance.
F)Use resource groups to lock different instances on separate CPUs.
Answer:CDE

Q103.Which statement enables all roles granted to all users automatically?
A) SET ROLE ALL;
B) SET DEFAULT ROLE ALL TO ‘*’@‘1’%';
C) SET PERSIST activate_all_roles_on_login=ON;
D) SET PERSIET mandatory_roles=ALL;
Answer:C

將 activate_all_roles_on_login 系統變量默認值為OFF,若設置為ON,服務器在登錄時將激活授予每個賬戶的角色。

Q104.Which two situations will cause the binary log to rotate?
A)FLUSH HOSTS executed
B)max_binlog_size exceeded
C)max_binlog_cache_size exceeded
D)SET sql_log_bin=1 executed
E)SET sync_binlog=1 executed
F)FLUSH LOGS executed
Answer:BF

選項A:FLUSH HOST語句用于清除主機緩存表,以便重新加載主機名和IP地址的映射。
選項B:max_binlog_size表示binlog的最大文件大小,日志寫入超過這個參數的設置的大小后,會關閉這個文件,然后重新創建一個新的binlog寫入,進行輪轉
選項C:max_binlog_cache_size 是一個 MySQL 系統變量,用于限制二進制日志(binlog)緩存的大小。,這個超出了會報錯
選項D:sql_log_bin參數控制在當前會話中是否寫binlog
選項E:sync_binlog控制binlog刷寫到磁盤的方式,比如sync_binlog=0,不將日志寫入磁盤,根據操作系統走,sync_binlog=1,每次提交都刷寫到磁盤,sync_binlog=N,N次提交刷寫到磁盤
F:FLUSH LOGS會新建一個日志,進行輪轉

Q105.Examine this statement, which executes successfully:
CREATE TABLE world.city (
ID int NOT NULL AUTO_INCREMENT,
Name char (35) NOT NULL DEFAULT ‘’,
CountryCode char (3) NOT NULL DEFAULT ‘’,
District char (20) NOT NULL DEFAULT ‘’,
Population int NOT NULL DEFAULT ‘0’,
PRIMARY KEY (ID),
KEY (CountryCode (CountryCode)) ENGINE InnoDB;

SELECT Name
FROM world. city
WHERE Population BETWEEN 1000000 AND 2000000;
Which change enables the query to succeed while accessing fewer rows?
A)ALTER TABLE world.city ADD INDEX (Name) ;
B)ALTER TABLE world.city ADD SPATIAL INDEX (Name);
C)ALTER TABLE world.city ADD FULLTEXT INDEX (Name);
D)ALTER TABLE world.city ADD SPATIAL INDEX (Population);
E)ALTER TABLE world.city ADD INDEX (Population);
F)ALTER TABLE world.city ADD FULLTEXT INDEX (Population);
Answer:E

選項ABC,跟本次查詢沒有關系,并且population為int類型,所以就普通的二級索引就可以,沒必要使用空間索引和全文索引

Q106.Examine this configuration:
You have a corporate private network, which uses its own Certificate Authority (CA) using an industry standard
2048-bit RSA key length.
? All MySQL Server and client certificates are signed using the central corporate CA.
? All clients are known, controlled,and exist only on the private LAN.
? The private network uses its own private authoritative DNS.
? The private network also uses other nominal enterprise services.
? An end-to-end encrypted connection for a MySQL client to MySQL server has been established on this LAN.
How does the MySQL Servers’ self signed certificate compare to one that would be signed by a known public,third party trusted Certificate Authority?
A)The self-signed certificate is equally secure and equally trusted.
B)The self-signed certificate is more secure and less trusted.
C)The self-signed certificate is less secure and equally trusted.
D)The self-signed certificate is equally secure and less trusted.
E)The self -signed certificate is more secure and equally trusted.
F)The self-signed certificate is less secure and less trusted
Answer:F

自簽證書的安全性和信任度較低

Q107.Which two are valid uses for binary logs on a MySQL instance?
A)logging the duration and locks for all queries //記錄日志期間不產生鎖
B)replication
C)audit of all queries
D)point-in-time recovery
E)recording the order in which queries are issued
Answer:BD

選項A:不記錄SELECT和鎖信息
選項B:復制期間是需要binlog的
選項C:查詢的審計記錄在審計日志,跟binlog沒關系
選項D:基于時間點的恢復,是需要binlog支撐的
選項E:參考選項A

Q108.Which two are characteristics of snapshot based backups?
A)There is no need for InnoDB tables to perform its own recovery when restoring from the snapshot
backup.
B)Snapshot backups can be used only in virtual machines.
C)Snapshot based backups greatly reduce time during which the database and applications are unavailable.
D)The frozen file system can be cloned to another virtual machine immediately into active service.
E)A separate physical copy must be made before releasing the snapshot backup
Answer:AC

選項A:快照恢復完成后,啟動時會自己進行Crash Recovery
選項C:快照備份會減少數據庫和應用的不可用時間

Q109.Examine this output:
在這里插入圖片描述

You plan to add this parameter to the configuration:
innodb_ directories=’ /innodb_ extras ‘
Which statement is true?
A)It defines all innodb tablespace options relative to a starting parent directory.
B)It adds more temporary workspace in addition to the innodb_ tmpdir location.
c)It moves all innodb tablespaces to the 1 innodb_ extras directory to enable a new
innodb_ data_ home_ dir to be defined.
D)It is not necessary because innodb data_ home_ dir is already defined.
E)It allows scanning of other locations to discover more innodb tablespaces .
Answer:E

innoDB_directories變量,它定義了在啟動時掃描以查找表空間文件的目錄。innodb_directories默認設置為NULL,但當innodb構建啟動時要掃描的目錄列表時,innodb_data_home_dir、innodb_undo_directory和datadir定義的目錄總是附加到innodb_directories參數值之后。無論是否顯式指定了innodb_directories設置,都會附加這些目錄。
使用絕對路徑定義的表空間文件或位于附加到innodb_directories設置的目錄之外的表空間應添加到innodd_directories設置中。參考:
https://dev.mysql.com/doc/refman/8.0/en/innodb-moving-data-files-offline.html
https://blog.csdn.net/qq_29519041/article/details/139078303

Q110.Examine this command, which executes successfully:
mysqldump --user=root --password > full_ backup.sql
Which two databases will be excluded from this dump?
A)world
B)employee
C)information schema
D)mysql
E)sys
Answer:CE
在這里插入圖片描述

參考:https://dev.mysql.com/doc/refman/8.0/en/mysqldump.html

本文來自互聯網用戶投稿,該文觀點僅代表作者本人,不代表本站立場。本站僅提供信息存儲空間服務,不擁有所有權,不承擔相關法律責任。
如若轉載,請注明出處:http://www.pswp.cn/pingmian/81007.shtml
繁體地址,請注明出處:http://hk.pswp.cn/pingmian/81007.shtml
英文地址,請注明出處:http://en.pswp.cn/pingmian/81007.shtml

如若內容造成侵權/違法違規/事實不符,請聯系多彩編程網進行投訴反饋email:809451989@qq.com,一經查實,立即刪除!

相關文章

Vue ElementUI原生upload修改字體大小和區域寬度

Vue ElementUI原生upload修改字體大小和區域寬度 修改后 代碼 新增的修改樣式代碼 .upload-demo /deep/ .el-upload-dragger{width: 700px;height: 300px; }原有拖拽組件代碼 <!-- 拖拽上傳組件 --><el-uploadclass"upload-demo"dragaction"":m…

React和Vue在前端開發中, 通常選擇哪一個

React和Vue的選擇需結合具體需求&#xff1a; 選React的場景 大型企業級應用&#xff0c;需處理復雜狀態&#xff08;如電商、社交平臺&#xff09;團隊熟悉JavaScript&#xff0c;已有React技術棧積累需要高度靈活的架構&#xff08;React僅專注視圖層&#xff0c;可自由搭配…

Python爬蟲實戰:研究源碼還原技術,實現逆向解密

1. 引言 在網絡爬蟲技術實際應用中,目標網站常采用各種加密手段保護數據傳輸和業務邏輯。傳統逆向解密方法依賴人工分析和調試,效率低下且易出錯。隨著 Web 應用復雜度提升,特別是 JavaScript 混淆技術廣泛應用,傳統方法面臨更大挑戰。 本文提出基于源碼還原的逆向解密方法…

什么是alpaca 或 sharegpt 格式的數據集?

環境&#xff1a; LLaMA-Factory 問題描述&#xff1a; alpaca 或 sharegpt 格式的數據集&#xff1f; 解決方案&#xff1a; “Alpaca”和“ShareGPT”格式的數據集&#xff0c;是近年來在開源大語言模型微調和對話數據構建領域比較流行的兩種格式。它們主要用于訓練和微調…

OpenCV CUDA模塊中矩陣操作------矩陣元素求和

操作系統&#xff1a;ubuntu22.04 OpenCV版本&#xff1a;OpenCV4.9 IDE:Visual Studio Code 編程語言&#xff1a;C11 算法描述 在OpenCV的CUDA模塊中&#xff0c;矩陣元素求和類函數主要用于計算矩陣元素的總和、絕對值之和以及平方和。這些操作對于圖像處理中的特征提取、…

給視頻加一個動畫。

為什么要給視頻加一個動畫&#xff1f; 很完整的視頻也就是從短動畫開始的。遮蓋住LOG用。 C:\Users\Sam\Desktop\desktop\startup\workpython\ocr Lottie.py import subprocessdef run_ffmpeg(cmd):print("Running:", " ".join(cmd))subprocess.run(cm…

15:00開始面試,15:06就出來了,問的問題有點變態。。。

從小廠出來&#xff0c;沒想到在另一家公司又寄了。 到這家公司開始上班&#xff0c;加班是每天必不可少的&#xff0c;看在錢給的比較多的份上&#xff0c;就不太計較了。沒想到4月一紙通知&#xff0c;所有人不準加班&#xff0c;加班費不僅沒有了&#xff0c;薪資還要降40%…

使用命令行拉取 Git 倉庫

1. 克隆遠程倉庫&#xff08;首次獲取&#xff09; # 克隆倉庫到當前目錄&#xff08;默認使用 HTTPS 協議&#xff09; git clone https://github.com/用戶名/倉庫名.git# 克隆倉庫到指定目錄 git clone https://github.com/用戶名/倉庫名.git 自定義目錄名# 使用 SSH 協議克隆…

如何禁止chrome自動更新

百度了一下 下面這個方法實測有效 目錄 1、WINR 輸入 services.msc 2、在Services彈窗中找到下面兩個service并disable 3、驗證是否禁止更新成功&#xff1a; 1、WINR 輸入 services.msc 2、在Services彈窗中找到下面兩個service并disable GoogleUpdater InternalService…

數據庫事務以及JDBC實現事務

一、數據庫事務 數據庫事務&#xff08;Database Transaction&#xff09;是數據庫管理系統中的一個核心概念&#xff0c;它代表一組操作的集合&#xff0c;這些操作要么全部執行成功&#xff0c;要么全部不執行&#xff0c;即操作數據的最小執行單元&#xff0c;保證數據庫的…

【vue】【環境配置】項目無法npm run serve,顯示node版本過低

解決方案&#xff1a;安裝高版本node&#xff0c;并且啟用高版本node 步驟&#xff1a; 1、查看當前版本 node -v2、配置nvm下載鏡像源 1&#xff09;查看配置文件位置 npm root2&#xff09;找到settings.txt文件 修改鏡像源為&#xff1a; node_mirror: https://npmmirro…

WPF之INotifyPropertyChanged實現

文章目錄 引言INotifyPropertyChanged接口基礎接口定義工作原理 基本實現方式標準實現示例CallerMemberName特性 高級實現技術基類實現通知多個屬性變化使用PropertyChanging事件 MVVM框架中的實現MVVM模式簡介MVVM框架中的實現Prism框架MVVM Light框架自定義MVVM基類 性能優化…

【MCP教程系列】SpringBoot 搭建基于 Spring AI 的 SSE 模式 MCP 服務

原文地址&#xff1a;https://developer.aliyun.com/article/1662946 在當今快速發展的AI技術背景下&#xff0c;如何高效地集成模型能力成為開發者關注的重點。本文將手把手教你如何基于 Spring AI 搭建支持 SSE&#xff08;Server-Sent Events&#xff09;模式的 MCP 服務 相…

springboot集成langchain4j實現票務助手實戰

前言 看此篇的前置知識為langchain4j整合springboot&#xff0c;以及springboot集成langchain4j記憶對話。 Function-Calls介紹 langchain4j 中的 Function Calls&#xff08;函數調用&#xff09;是一種讓大語言模型&#xff08;LLM&#xff09;與外部工具&#xff08;如 A…

MySQL-數據庫分布式XA事務

準備 innodb存儲引擎開啟支持分布式事務 set global innodb_support_axonMySQL數據庫XA事務的SQL語法如下&#xff1a; XA {START| BEGIN} xid {JOIN | RESUME} XA END xid {SUSPEND [ FOR MIGRATE]} XA PREPARE xid XA COMMIT xid [ONE PHASE] XA ROLLBACK xid XA RECOVER 完…

SAP 運維-冷門問題解決辦法

1.SAP Fiori幫助菜單鏈接如何配置&#xff1f; 答&#xff1a; 執行事務代碼HELP_CONFIG&#xff0c;選擇對應的Fiori部署模式&#xff0c;配置幫助菜單下的URL鏈接。 檢查配置的幫助菜單&#xff0c;執行事務代碼/N//UI2/FLP_CUS_CONF 或者SR13進行查看配置狀態與修改。

新型智慧園區技術架構深度解析:數字孿生與零碳科技的融合實踐

&#x1f3ed;在杭州亞運村零碳園區&#xff0c;光伏板與氫燃料大巴構成的能源網絡&#xff0c;正通過數字孿生技術實現智能調度。這不僅是格力電器與龍源電力在新能源領域的創新實踐&#xff0c;更是智慧園區4.0時代的標桿案例。當AI算法開始接管能源調度&#xff0c;當BIM建模…

Java轉Go日記(三十六):簡單的分布式

1.1.1. 簡單的分布式server 目前分布式系統已經很流行了&#xff0c;一些開源框架也被廣泛應用&#xff0c;如dubbo、Motan等。對于一個分布式服務&#xff0c;最基本的一項功能就是服務的注冊和發現&#xff0c;而利用zk的EPHEMERAL節點則可以很方便的實現該功能。EPHEMERAL節…

機器學習筆記——特征工程

大家好&#xff0c;這里是好評筆記&#xff0c;公主號&#xff1a;Goodnote&#xff0c;專欄文章私信限時Free。本筆記介紹機器學習中常見的特征工程方法、正則化方法和簡要介紹強化學習。 文章目錄 特征工程&#xff08;Fzeature Engineering&#xff09;1. 特征提取&#xff…

在 Ubuntu 20.04.6 LTS 中將 SCons 從 3.1.2 升級到 4.9.1

在 Ubuntu 20.04.6 LTS 中將 SCons 從 3.1.2 升級到 4.9.1&#xff0c;可以通過以下步驟完成&#xff1a; 方法 1&#xff1a;使用 pip 安裝&#xff08;推薦&#xff09; 步驟 1&#xff1a;卸載舊版本 SCons # 如果通過 apt 安裝的舊版本&#xff0c;先卸載 sudo apt remov…