59 openEuler 22.03-LTS 搭建MySQL數(shù)據(jù)庫服務(wù)器-軟件介紹和配置環(huán)境

59 openEuler 22.03-LTS 搭建MySQL數(shù)據(jù)庫服務(wù)器-軟件介紹和配置環(huán)境59.1 軟件介紹59.2 配置環(huán)境59.2.1 關(guān)閉防火墻并取消開機(jī)自啟動(dòng)59.2.2 修改SELINUX為disabled59.2.3 創(chuàng)建組和用戶59.2.4 創(chuàng)建數(shù)據(jù)盤59.2.4.1 方法一:在root權(quán)限下使用fdisk進(jìn)行磁盤管理59.2.4.1 方法二:在root權(quán)限下使用LVM進(jìn)行磁盤管理59.2.5 創(chuàng)建數(shù)據(jù)庫目錄并且授權(quán)

59 openEuler 22.03-LTS 搭建MySQL數(shù)據(jù)庫服務(wù)器-軟件介紹和配置環(huán)境

59.1 軟件介紹

MySQL是一個(gè)關(guān)系型數(shù)據(jù)庫管理系統(tǒng)洪乍,由瑞典MySQL AB公司開發(fā),目前屬于Oracle旗下產(chǎn)品夜焦。MySQL是業(yè)界最流行的RDBMS (Relational Database Management System壳澳,關(guān)系數(shù)據(jù)庫管理系統(tǒng))之一,尤其在WEB應(yīng)用方面茫经。

關(guān)系數(shù)據(jù)庫將數(shù)據(jù)保存在不同的表中巷波,而不是將所有數(shù)據(jù)放在一個(gè)大倉庫內(nèi),這樣就加快了速度并提高了靈活性卸伞。

MySQL所使用的SQL語言是用于訪問數(shù)據(jù)庫的最常用標(biāo)準(zhǔn)化語言抹镊。MySQL軟件采用了雙授權(quán)模式,分為社區(qū)版和商業(yè)版荤傲,由于其體積小髓考、速度快、總體擁有成本低弃酌,尤其是開放源碼這一特點(diǎn)氨菇,一般中小型網(wǎng)站的開發(fā)都選擇MySQL作為網(wǎng)站數(shù)據(jù)庫。

59.2 配置環(huán)境

[圖片上傳失敗...(image-357013-1682169715708)]

說明: 以下環(huán)境配置僅為參考示例妓湘,具體配置視實(shí)際需求做配置

59.2.1 關(guān)閉防火墻并取消開機(jī)自啟動(dòng)

[圖片上傳失敗...(image-a7f99a-1682169715708)]

說明: 測(cè)試環(huán)境下通常會(huì)關(guān)閉防火墻以避免部分網(wǎng)絡(luò)因素影響查蓉,視實(shí)際需求做配置。

  1. 在root權(quán)限下停止防火墻榜贴。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n18" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># systemctl stop firewalld</pre>

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n20" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# systemctl stop firewalld
    [root@superman-21 ~]# </pre>

  2. 在root權(quán)限下關(guān)閉防火墻豌研。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n23" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># systemctl disable firewalld</pre>

    [圖片上傳失敗...(image-29b2bc-1682169715704)]

    說明: 執(zhí)行disable命令關(guān)閉防火墻的同時(shí),也取消了開機(jī)自啟動(dòng)唬党。

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n27" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# systemctl disable firewalld
    Removed /etc/systemd/system/dbus-org.fedoraproject.FirewallD1.service.
    Removed /etc/systemd/system/multi-user.target.wants/firewalld.service.
    [root@superman-21 ~]# </pre>

59.2.2 修改SELINUX為disabled

  1. 永久關(guān)閉鹃共,在root權(quán)限下修改配置文件。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n32" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/sysconfig/selinux</pre>

    [圖片上傳失敗...(image-5414e7-1682169715704)]

    說明:

    重啟后生效驶拱。

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n37" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/sysconfig/selinux
    [root@superman-21 ~]#
    [root@superman-21 ~]# cat /etc/sysconfig/selinux

    This file controls the state of SELinux on the system.

    SELINUX= can take one of these three values:

    enforcing - SELinux security policy is enforced.

    permissive - SELinux prints warnings instead of enforcing.

    disabled - No SELinux policy is loaded.

    SELINUX=disabled

    SELINUXTYPE= can take one of these three values:

    targeted - Targeted processes are protected,

    minimum - Modification of targeted policy. Only selected processes are protected.

    mls - Multi Level Security protection.

    SELINUXTYPE=targeted

[root@superman-21 ~]#</pre>
  1. 臨時(shí)關(guān)閉

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n40" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># setenforce 0</pre>

    [圖片上傳失敗...(image-6f7dbe-1682169715704)]

    說明:

    即時(shí)生效霜浴,但重啟后會(huì)自動(dòng)開啟。

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n45" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# setenforce 0
    setenforce: SELinux is permissive
    [root@superman-21 ~]# </pre>

59.2.3 創(chuàng)建組和用戶

[圖片上傳失敗...(image-b4485-1682169715708)]

說明: 服務(wù)器環(huán)境下蓝纲,為了系統(tǒng)安全阴孟,通常會(huì)為進(jìn)程分配單獨(dú)的用戶晌纫,以實(shí)現(xiàn)權(quán)限隔離。本章節(jié)創(chuàng)建的組和用戶都是操作系統(tǒng)層面的永丝,不是數(shù)據(jù)庫層面的锹漱。

  1. 在root權(quán)限下創(chuàng)建MySQL用戶(組)。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n52" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># groupadd mysql

    useradd -g mysql mysql</pre>

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n54" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# groupadd mysql
    [root@superman-21 ~]#
    [root@superman-21 ~]# useradd -g mysql mysql
    [root@superman-21 ~]# </pre>

  2. 在root權(quán)限下設(shè)置MySQL用戶密碼慕嚷。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n57" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># passwd mysql</pre>

    需要重復(fù)輸入密碼(根據(jù)實(shí)際需求設(shè)置密碼)哥牍。

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n60" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# passwd mysql
    更改用戶 mysql 的密碼 。
    新的密碼:
    重新輸入新的密碼:
    passwd:所有的身份驗(yàn)證令牌已經(jīng)成功更新喝检。
    [root@superman-21 ~]# </pre>

59.2.4 創(chuàng)建數(shù)據(jù)盤

[圖片上傳失敗...(image-a46b13-1682169715708)]

說明:

  • 進(jìn)行性能測(cè)試時(shí)砂心,數(shù)據(jù)目錄使用單獨(dú)硬盤,需要對(duì)硬盤進(jìn)行格式化并掛載蛇耀,參考方法一或者方法二
  • 非性能測(cè)試時(shí)辩诞,在root權(quán)限下執(zhí)行以下命令,創(chuàng)建數(shù)據(jù)目錄即可纺涤。然后跳過本小節(jié): # mkdir /data
59.2.4.1 方法一:在root權(quán)限下使用fdisk進(jìn)行磁盤管理
  1. 創(chuàng)建分區(qū)(以/dev/sdb為例译暂,根據(jù)實(shí)際情況創(chuàng)建)

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n73" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># fdisk /dev/sdb</pre>

  2. 輸入n,按回車確認(rèn)撩炊。

  3. 輸入p外永,按回車確認(rèn)。

  4. 輸入1拧咳,按回車確認(rèn)伯顶。

  5. 采用默認(rèn)配置,按回車確認(rèn)骆膝。

  6. 采用默認(rèn)配置祭衩,按回車確認(rèn)。

  7. 輸入w阅签,按回車保存掐暮。

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n87" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# fdisk /dev/sdb

    歡迎使用 fdisk (util-linux 2.37.2)。
    更改將停留在內(nèi)存中政钟,直到您決定將更改寫入磁盤路克。
    使用寫入命令前請(qǐng)三思。

    設(shè)備不包含可識(shí)別的分區(qū)表养交。
    創(chuàng)建了一個(gè)磁盤標(biāo)識(shí)符為 0x9ac1f07b 的新 DOS 磁盤標(biāo)簽精算。

    命令(輸入 m 獲取幫助):n
    分區(qū)類型
    p 主分區(qū) (0 primary, 0 extended, 4 free)
    e 擴(kuò)展分區(qū) (邏輯分區(qū)容器)
    選擇 (默認(rèn) p):p
    分區(qū)號(hào) (1-4, 默認(rèn) 1): 1
    第一個(gè)扇區(qū) (2048-41943039, 默認(rèn) 2048):
    最后一個(gè)扇區(qū),+/-sectors 或 +size{K,M,G,T,P} (2048-41943039, 默認(rèn) 41943039):

    創(chuàng)建了一個(gè)新分區(qū) 1碎连,類型為“Linux”灰羽,大小為 20 GiB。

    命令(輸入 m 獲取幫助):w
    分區(qū)表已調(diào)整。
    將調(diào)用 ioctl() 來重新讀分區(qū)表谦趣。
    正在同步磁盤疲吸。

    [root@superman-21 ~]# </pre>

  8. 創(chuàng)建文件系統(tǒng)(以xfs為例座每,根據(jù)實(shí)際需求創(chuàng)建文件系統(tǒng))

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n90" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># mkfs.xfs /dev/sdb1</pre>

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n92" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# mkfs.xfs /dev/sdb1
    meta-data=/dev/sdb1 isize=512 agcount=4, agsize=1310656 blks
    = sectsz=512 attr=2, projid32bit=1
    = crc=1 finobt=1, sparse=1, rmapbt=0
    = reflink=1 bigtime=0 inobtcount=0
    data = bsize=4096 blocks=5242624, imaxpct=25
    = sunit=0 swidth=0 blks
    naming =version 2 bsize=4096 ascii-ci=0, ftype=1
    log =internal log bsize=4096 blocks=2560, version=2
    = sectsz=512 sunit=0 blks, lazy-count=1
    realtime =none extsz=4096 blocks=0, rtextents=0
    [root@superman-21 ~]# </pre>

  9. 創(chuàng)建“/data”文件夾以供操作系統(tǒng)掛載分區(qū)使用前鹅。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n95" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># mkdir /data</pre>

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n97" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# mkdir /data
    [root@superman-21 ~]# </pre>

  10. 執(zhí)行命令編輯“/etc/fstab”使重啟后自動(dòng)掛載數(shù)據(jù)盤。

<pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n100" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># echo "/dev/sdb1 /data                       xfs    defaults        1 1" >> /etc/fstab</pre>

例如示例命令如下:

<pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n102" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# cat /etc/fstab 

#
# /etc/fstab
# Created by anaconda on Mon Nov 28 13:29:03 2022
#
# Accessible filesystems, by reference, are maintained under '/dev/disk/'.
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info.
#
# After editing this file, run 'systemctl daemon-reload' to update systemd
# units generated from this file.
#
/dev/mapper/vg00-lv_root /                       ext4    defaults        1 1
UUID=70c4f6e0-20be-46f8-93ba-97c8083bc37a /boot                   ext4    defaults        1 2
/dev/mapper/vg00-lv_swap none                    swap    defaults        0 0
[root@superman-21 ~]# 
[root@superman-21 ~]# echo "/dev/sdb1 /data                       xfs    defaults        1 1" >> /etc/fstab
[root@superman-21 ~]# 
[root@superman-21 ~]# cat /etc/fstab 

#
# /etc/fstab
# Created by anaconda on Mon Nov 28 13:29:03 2022
#
# Accessible filesystems, by reference, are maintained under '/dev/disk/'.
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info.
#
# After editing this file, run 'systemctl daemon-reload' to update systemd
# units generated from this file.
#
/dev/mapper/vg00-lv_root /                       ext4    defaults        1 1
UUID=70c4f6e0-20be-46f8-93ba-97c8083bc37a /boot                   ext4    defaults        1 2
/dev/mapper/vg00-lv_swap none                    swap    defaults        0 0
/dev/sdb1 /data                       xfs    defaults        1 1
[root@superman-21 ~]# </pre>
  1. 掛載數(shù)據(jù)盤峭梳。
<pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n105" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># mount -a</pre>

例如示例命令如下:

<pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n107" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# df -h
文件系統(tǒng)                  容量  已用  可用 已用% 掛載點(diǎn)
devtmpfs                  4.0M     0  4.0M    0% /dev
tmpfs                     1.7G   12K  1.7G    1% /dev/shm
tmpfs                     677M  9.1M  668M    2% /run
tmpfs                     4.0M     0  4.0M    0% /sys/fs/cgroup
/dev/mapper/vg00-lv_root   41G  2.9G   36G    8% /
tmpfs                     1.7G     0  1.7G    0% /tmp
/dev/sda1                 974M  249M  659M   28% /boot
[root@superman-21 ~]# 
[root@superman-21 ~]# mount -a
[root@superman-21 ~]# 
[root@superman-21 ~]# df -h
文件系統(tǒng)                  容量  已用  可用 已用% 掛載點(diǎn)
devtmpfs                  4.0M     0  4.0M    0% /dev
tmpfs                     1.7G   12K  1.7G    1% /dev/shm
tmpfs                     677M  9.1M  668M    2% /run
tmpfs                     4.0M     0  4.0M    0% /sys/fs/cgroup
/dev/mapper/vg00-lv_root   41G  2.9G   36G    8% /
tmpfs                     1.7G     0  1.7G    0% /tmp
/dev/sda1                 974M  249M  659M   28% /boot
/dev/sdb1                  20G  175M   20G    1% /data
[root@superman-21 ~]#</pre>
59.2.4.1 方法二:在root權(quán)限下使用LVM進(jìn)行磁盤管理

[圖片上傳失敗...(image-71f8f8-1682169715707)]

說明: 此步驟需要安裝鏡像中的lvm2相關(guān)包舰绘,步驟如下:

  1. 配置本地yum源,詳細(xì)信息請(qǐng)參考《openEuler 22.03-LTS 搭建repo服務(wù)器》葱椭。如果已經(jīng)執(zhí)行捂寿,則可跳過此步。
  1. 在root權(quán)限下執(zhí)行命令安裝lvm2孵运。 # yum install lvm2
  1. 創(chuàng)建物理卷(sdb為硬盤名稱秦陋,具體名字以實(shí)際為準(zhǔn))。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n119" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># pvcreate /dev/sdb</pre>

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n121" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# pvcreate /dev/sdb
    Physical volume "/dev/sdb" successfully created.
    [root@superman-21 ~]# </pre>

  2. 創(chuàng)建物理卷組(其中vg_data為創(chuàng)建的卷組名稱治笨,具體名字以實(shí)際規(guī)劃為準(zhǔn))驳概。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n124" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># vgcreate vg_data /dev/sdb</pre>

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n126" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# vgcreate vg_data /dev/sdb
    Volume group "vg_data" successfully created
    [root@superman-21 ~]# </pre>

  3. 創(chuàng)建邏輯卷(其中20G為規(guī)劃的邏輯卷大小,具體大小以實(shí)際情況為準(zhǔn)旷赖;lv_data為創(chuàng)建的邏輯卷的名字顺又,具體名稱以實(shí)際規(guī)劃為準(zhǔn)。)等孵。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n129" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># lvcreate -L 20476M -n lv_data vg_data</pre>

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n131" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# lvcreate -L 20476M -n lv_data vg_data
    Logical volume "lv_data" created.
    [root@superman-21 ~]# </pre>

  4. 創(chuàng)建文件系統(tǒng)稚照。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n134" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># mkfs.xfs /dev/vg_data/lv_data</pre>

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n136" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# mkfs.xfs /dev/vg_data/lv_data
    meta-data=/dev/vg_data/lv_data isize=512 agcount=4, agsize=1310464 blks
    = sectsz=512 attr=2, projid32bit=1
    = crc=1 finobt=1, sparse=1, rmapbt=0
    = reflink=1 bigtime=0 inobtcount=0
    data = bsize=4096 blocks=5241856, imaxpct=25
    = sunit=0 swidth=0 blks
    naming =version 2 bsize=4096 ascii-ci=0, ftype=1
    log =internal log bsize=4096 blocks=2560, version=2
    = sectsz=512 sunit=0 blks, lazy-count=1
    realtime =none extsz=4096 blocks=0, rtextents=0
    [root@superman-21 ~]# </pre>

  5. 創(chuàng)建“/data”文件夾以供操作系統(tǒng)掛載分區(qū)使用。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n139" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># mkdir /data</pre>

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n141" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# mkdir /data
    [root@superman-21 ~]# </pre>

  6. 執(zhí)行命令編輯“/etc/fstab”使重啟后自動(dòng)掛載數(shù)據(jù)盤俯萌。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n144" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># echo "/dev/vg_data/lv_data /data xfs defaults 1 1" >> /etc/fstab</pre>

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n146" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# cat /etc/fstab

    /etc/fstab

    Created by anaconda on Mon Nov 28 13:29:03 2022

    Accessible filesystems, by reference, are maintained under '/dev/disk/'.

    See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info.

    After editing this file, run 'systemctl daemon-reload' to update systemd

    units generated from this file.

    /dev/mapper/vg00-lv_root / ext4 defaults 1 1
    UUID=70c4f6e0-20be-46f8-93ba-97c8083bc37a /boot ext4 defaults 1 2
    /dev/mapper/vg00-lv_swap none swap defaults 0 0
    [root@superman-21 ~]#
    [root@superman-21 ~]# echo "/dev/vg_data/lv_data /data xfs defaults 1 1" >> /etc/fstab
    [root@superman-21 ~]#
    [root@superman-21 ~]# cat /etc/fstab

    /etc/fstab

    Created by anaconda on Mon Nov 28 13:29:03 2022

    Accessible filesystems, by reference, are maintained under '/dev/disk/'.

    See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info.

    After editing this file, run 'systemctl daemon-reload' to update systemd

    units generated from this file.

    /dev/mapper/vg00-lv_root / ext4 defaults 1 1
    UUID=70c4f6e0-20be-46f8-93ba-97c8083bc37a /boot ext4 defaults 1 2
    /dev/mapper/vg00-lv_swap none swap defaults 0 0
    /dev/vg_data/lv_data /data xfs defaults 1 1
    [root@superman-21 ~]# </pre>

  7. 掛載數(shù)據(jù)盤果录。

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n149" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;"># mount -a</pre>

    例如示例命令如下:

    <pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n151" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit;">[root@superman-21 ~]# df -h
    文件系統(tǒng) 容量 已用 可用 已用% 掛載點(diǎn)
    devtmpfs 4.0M 0 4.0M 0% /dev
    tmpfs 1.7G 12K 1.7G 1% /dev/shm
    tmpfs 677M 9.1M 668M 2% /run
    tmpfs 4.0M 0 4.0M 0% /sys/fs/cgroup
    /dev/mapper/vg00-lv_root 41G 2.9G 36G 8% /
    tmpfs 1.7G 0 1.7G 0% /tmp
    /dev/sda1 974M 249M 659M 28% /boot
    [root@superman-21 ~]#
    [root@superman-21 ~]# mount -a
    [root@superman-21 ~]#
    [root@superman-21 ~]# df -h
    文件系統(tǒng) 容量 已用 可用 已用% 掛載點(diǎn)
    devtmpfs 4.0M 0 4.0M 0% /dev
    tmpfs 1.7G 12K 1.7G 1% /dev/shm
    tmpfs 677M 9.1M 668M 2% /run
    tmpfs 4.0M 0 4.0M 0% /sys/fs/cgroup
    /dev/mapper/vg00-lv_root 41G 2.9G 36G 8% /
    tmpfs 1.7G 0 1.7G 0% /tmp
    /dev/sda1 974M 249M 659M 28% /boot
    /dev/mapper/vg_data-lv_data 20G 175M 20G 1% /data
    [root@superman-21 ~]#</pre>

59.2.5 創(chuàng)建數(shù)據(jù)庫目錄并且授權(quán)

在已創(chuàng)建的數(shù)據(jù)目錄 /data 基礎(chǔ)上,使用root權(quán)限繼續(xù)創(chuàng)建進(jìn)程所需的相關(guān)目錄并授權(quán)MySQL用戶(組)咐熙。

<pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n154" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit; color: rgb(51, 51, 51); font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-indent: 0px; text-transform: none; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration-thickness: initial; text-decoration-style: initial; text-decoration-color: initial;"># mkdir -p /data/mysql

cd /data/mysql

mkdir data tmp run log

chown -R mysql:mysql /data</pre>

例如示例命令如下:

<pre class="md-fences md-end-block ty-contain-cm modeLoaded" spellcheck="false" lang="bash" cid="n156" mdtype="fences" style="box-sizing: border-box; overflow: visible; font-family: var(--monospace); font-size: 0.9em; display: block; break-inside: avoid; text-align: left; white-space: normal; background-image: inherit; background-position: inherit; background-size: inherit; background-repeat: inherit; background-attachment: inherit; background-origin: inherit; background-clip: inherit; background-color: rgb(248, 248, 248); position: relative !important; border: 1px solid rgb(231, 234, 237); border-radius: 3px; padding: 8px 4px 6px; margin-bottom: 15px; margin-top: 15px; width: inherit; color: rgb(51, 51, 51); font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-indent: 0px; text-transform: none; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; text-decoration-thickness: initial; text-decoration-style: initial; text-decoration-color: initial;">[root@superman-21 ~]# mkdir -p /data/mysql
[root@superman-21 ~]#
[root@superman-21 ~]# cd /data/mysql
[root@superman-21 mysql]#
[root@superman-21 mysql]# mkdir data tmp run log
[root@superman-21 mysql]#
[root@superman-21 mysql]# chown -R mysql:mysql /data
[root@superman-21 mysql]# </pre>

?? 點(diǎn)贊雕憔,你的認(rèn)可是我創(chuàng)作的動(dòng)力!

?? 收藏糖声,你的青睞是我努力的方向斤彼!

?? 評(píng)論,你的意見是我進(jìn)步的財(cái)富蘸泻!

?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請(qǐng)聯(lián)系作者
  • 序言:七十年代末琉苇,一起剝皮案震驚了整個(gè)濱河市,隨后出現(xiàn)的幾起案子悦施,更是在濱河造成了極大的恐慌并扇,老刑警劉巖,帶你破解...
    沈念sama閱讀 216,544評(píng)論 6 501
  • 序言:濱河連續(xù)發(fā)生了三起死亡事件抡诞,死亡現(xiàn)場(chǎng)離奇詭異穷蛹,居然都是意外死亡土陪,警方通過查閱死者的電腦和手機(jī),發(fā)現(xiàn)死者居然都...
    沈念sama閱讀 92,430評(píng)論 3 392
  • 文/潘曉璐 我一進(jìn)店門肴熏,熙熙樓的掌柜王于貴愁眉苦臉地迎上來鬼雀,“玉大人,你說我怎么就攤上這事蛙吏≡戳ǎ” “怎么了?”我有些...
    開封第一講書人閱讀 162,764評(píng)論 0 353
  • 文/不壞的土叔 我叫張陵鸦做,是天一觀的道長(zhǎng)励烦。 經(jīng)常有香客問我,道長(zhǎng)泼诱,這世上最難降的妖魔是什么坛掠? 我笑而不...
    開封第一講書人閱讀 58,193評(píng)論 1 292
  • 正文 為了忘掉前任,我火速辦了婚禮治筒,結(jié)果婚禮上屉栓,老公的妹妹穿的比我還像新娘。我一直安慰自己矢炼,他們只是感情好系瓢,可當(dāng)我...
    茶點(diǎn)故事閱讀 67,216評(píng)論 6 388
  • 文/花漫 我一把揭開白布。 她就那樣靜靜地躺著句灌,像睡著了一般夷陋。 火紅的嫁衣襯著肌膚如雪。 梳的紋絲不亂的頭發(fā)上胰锌,一...
    開封第一講書人閱讀 51,182評(píng)論 1 299
  • 那天骗绕,我揣著相機(jī)與錄音,去河邊找鬼资昧。 笑死酬土,一個(gè)胖子當(dāng)著我的面吹牛,可吹牛的內(nèi)容都是我干的格带。 我是一名探鬼主播撤缴,決...
    沈念sama閱讀 40,063評(píng)論 3 418
  • 文/蒼蘭香墨 我猛地睜開眼,長(zhǎng)吁一口氣:“原來是場(chǎng)噩夢(mèng)啊……” “哼叽唱!你這毒婦竟也來了屈呕?” 一聲冷哼從身側(cè)響起,我...
    開封第一講書人閱讀 38,917評(píng)論 0 274
  • 序言:老撾萬榮一對(duì)情侶失蹤棺亭,失蹤者是張志新(化名)和其女友劉穎虎眨,沒想到半個(gè)月后,有當(dāng)?shù)厝嗽跇淞掷锇l(fā)現(xiàn)了一具尸體,經(jīng)...
    沈念sama閱讀 45,329評(píng)論 1 310
  • 正文 獨(dú)居荒郊野嶺守林人離奇死亡嗽桩,尸身上長(zhǎng)有42處帶血的膿包…… 初始之章·張勛 以下內(nèi)容為張勛視角 年9月15日...
    茶點(diǎn)故事閱讀 37,543評(píng)論 2 332
  • 正文 我和宋清朗相戀三年岳守,在試婚紗的時(shí)候發(fā)現(xiàn)自己被綠了。 大學(xué)時(shí)的朋友給我發(fā)了我未婚夫和他白月光在一起吃飯的照片碌冶。...
    茶點(diǎn)故事閱讀 39,722評(píng)論 1 348
  • 序言:一個(gè)原本活蹦亂跳的男人離奇死亡湿痢,死狀恐怖,靈堂內(nèi)的尸體忽然破棺而出种樱,到底是詐尸還是另有隱情蒙袍,我是刑警寧澤俊卤,帶...
    沈念sama閱讀 35,425評(píng)論 5 343
  • 正文 年R本政府宣布嫩挤,位于F島的核電站,受9級(jí)特大地震影響消恍,放射性物質(zhì)發(fā)生泄漏岂昭。R本人自食惡果不足惜,卻給世界環(huán)境...
    茶點(diǎn)故事閱讀 41,019評(píng)論 3 326
  • 文/蒙蒙 一狠怨、第九天 我趴在偏房一處隱蔽的房頂上張望约啊。 院中可真熱鬧,春花似錦佣赖、人聲如沸恰矩。這莊子的主人今日做“春日...
    開封第一講書人閱讀 31,671評(píng)論 0 22
  • 文/蒼蘭香墨 我抬頭看了看天上的太陽外傅。三九已至,卻和暖如春俩檬,著一層夾襖步出監(jiān)牢的瞬間萎胰,已是汗流浹背。 一陣腳步聲響...
    開封第一講書人閱讀 32,825評(píng)論 1 269
  • 我被黑心中介騙來泰國(guó)打工棚辽, 沒想到剛下飛機(jī)就差點(diǎn)兒被人妖公主榨干…… 1. 我叫王不留技竟,地道東北人。 一個(gè)月前我還...
    沈念sama閱讀 47,729評(píng)論 2 368
  • 正文 我出身青樓屈藐,卻偏偏與公主長(zhǎng)得像榔组,于是被迫代替她去往敵國(guó)和親。 傳聞我的和親對(duì)象是個(gè)殘疾皇子联逻,可洞房花燭夜當(dāng)晚...
    茶點(diǎn)故事閱讀 44,614評(píng)論 2 353

推薦閱讀更多精彩內(nèi)容