<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??一站式輕松地調用各大LLM模型接口,支持GPT4、智譜、豆包、星火、月之暗面及文生圖、文生視頻 廣告
                **1. 概念** namenode 被格式化之后,將在{hadoop_home}/data/tmp/dfs/name/current 目錄中產生如下文件: ```xml edits_0000000000000000000 fsimage_0000000000000000000.md5 seen_txid VERSION ``` Fsimage 文件:HDFS 文件系統元數據的一個永久性的檢查點,其中包含 HDFS文件系統的所有目錄和文件 idnode 的序列化信息。 <br/> Edits 文件:存放 HDFS 文件系統的所有更新操作的路徑,文件系統客戶端執行的所有寫操作首先會被記錄到 edits 文件中。 <br/> seen_txid 文件:保存的是一個數字,就是最后一個 edits_的數字。<br /> 每次 NameNode <mark>啟動的時候</mark>都會將 fsimage 文件讀入內存,并從 00001 開始到 seen_txid 中記錄的數字依次執行每個 edits 里面的更新操作,保證內存中的元數據信息是最新的、同步的,可以看成 NameNode 啟動的時候就將 fsimage 和edits 文件進行了合并。 <br /> hdfs提供了`oiv`和`oev`命令來查看fsimage和edits文件。 <br /> **2. 使用 oiv 查看 fsimage 文件** (1)查看 oiv 和 oev 命令 ```sql [root@hadoop101 current]$ hdfs oiv apply the offline fsimage viewer to an fsimage oev apply the offline edits viewer to an edits file ``` (2)基本語法 ```sql hdfs oiv -p 文件類型 -i 鏡像文件 -o 轉換后文件輸出路徑 ``` (3)案例實操 ```sql [root@hadoop101 current]$ pwd /opt/install/hadoop/data/tmp/dfs/name/current [root@hadoop101 current]$ hdfs oiv -p XML -i \ fsimage_0000000000000000025 \ -o /opt/install/hadoop/fsimage.xml [root@hadoop101 current]$ cat /opt/install/hadoop/fsimage.xml ``` 將顯示的 xml 文件內容拷貝到 idea 中創建的 xml 文件,并格式化。部分顯示結果如下。注意:id,name 等屬性與自己環境一致. ```xml <inode> <id>15387</id> <type>DIRECTORY</type> <name>user</name> <mtime>1512722284477</mtime> <permission>kgc:supergroup:rwxr-xr-x</permission> <nsquota>-1</nsquota> <dsquota>-1</dsquota> </inode> ...... ``` <br/> **3. oev 查看 edits 文件** (1)基本語法 ```sql hdfs oev -p 文件類型 -i 編輯日志 -o 轉換后文件輸出路徑 ``` (2)案例實操 ```sql [root@hadoop101 current]$ hdfs oev -p XML -i \ edits_0000000000000000012-0000000000000000013 \ -o /opt/install/hadoop/edits.xml [root@hadoop101 current]$ cat /opt/install/hadoop/edits.xml ``` 將顯示的 xml 文件內容拷貝到 idea 中創建的 xml 文件中,并格式化。顯示結果如下。 ```xml <?xml version="1.0" encoding="UTF-8"?> <EDITS> <EDITS_VERSION>-63</EDITS_VERSION> <RECORD> <OPCODE>OP_START_LOG_SEGMENT</OPCODE> <DATA> <TXID>129</TXID> </DATA> </RECORD> ...... ```
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看