Solaris 9 安裝指南

驗證 custom_probes

在您能夠使用設定檔、rules 以及 custom_probes 檔之前,您必須執行 check 程序檔來驗證是否已正確設定該檔案。若是已正確地設定所有的設定檔、規則以及探測與比較函式,便會建立 rules.ok 以及custom_probes.ok 檔。表 25-1 將說明check 程序檔的功能

表 25-1 使用 check 程序檔的過程

用途 

說明 

check 會搜尋 custom_probes 檔。

若是該檔案存在,check 就會從 custom_probes 檔建立 custom_probes.ok 檔,並移除所有的註釋與空白行,而保留所有 Bourne shell 指令、變數與演算法。然後,check 便會在結尾處增加下列的註釋行:

# version=2 checksum=num

若要驗證 custom_probes 檔案

  1. 檢驗 check 程序檔是否位於 JumpStart 目錄中。


    註解 -

    check 程序檔是位於 Solaris 9 DVD 或是 Solaris 9 Software 2 之 2 CD 的 Solaris_9/Misc/jumpstart_sample 目錄中。


  2. 變更至 JumpStart 目錄。

  3. 執行 check 程序檔以驗證 rules 以及 custom_probes 檔案。


    $ ./check [[-p path -r file_name]]

    -p path

    驗證 custom_probes 檔案,要使用平台的 Solaris 9 軟體影像之 check 程序檔,而不是使用您正在用的系統之 check 程序檔。 path 是本機磁碟、裝載的 Solaris 9 DVD 或 Solaris 9 Software 2 之 2 光碟片上的影像。

    如果您的系統正在執行前一個版本的 Solaris,請使用這個選項來執行最新版本的 check

    -r file_name

    指定一個不同於命名為 custom_probes 的檔案名稱。您可以使用 -r 選項,在將函式整合至 custom_probes 檔案之前測試函式集合的有效性。

    執行 check 程序檔時,程序檔便會報告 rulescustom_probes 檔案以及每個設定檔的有效性。若是沒有遇到任何錯誤,程序檔會報告: "The custom JumpStart configuration is ok" 並在 JumpStart 目錄中建立 rules.ok custom_probes.ok 檔。

  4. 判定 custom_probes.ok 檔案是否可以執行。

    • 如果可以執行,請移至 步驟 5

    • 如果不能執行,請鍵入下列的指令:

      chmod +x custom_probes

  5. 確保 root 擁有 custom_probes.ok 檔案且許可權設定為 755。