2.2. 起​​​​​​​始​​​​​​​設​​​​​​​定​​​​​​​工​​​​​​​作​​​​​​​

最​​​​​​​開​​​​​​​始​​​​​​​的​​​​​​​ GFS2 設​​​​​​​定​​​​​​​包​​​​​​​含​​​​​​​了​​​​​​​以​​​​​​​下​​​​​​​工​​​​​​​作​​​​​​​:
  1. 設​​​​​​​定​​​​​​​邏​​​​​​​輯​​​​​​​卷​​​​​​​冊​​​​​​​。​​​​​​​
  2. 製​​​​​​​作​​​​​​​ GFS2 檔​​​​​​​案​​​​​​​系​​​​​​​統​​​​​​​。​​​​​​​
  3. 掛​​​​​​​載​​​​​​​檔​​​​​​​案​​​​​​​系​​​​​​​統​​​​​​​。​​​​​​​
遵​​​​​​​循​​​​​​​以​​​​​​​下​​​​​​​步​​​​​​​驟​​​​​​​,設​​​​​​​定​​​​​​​初​​​​​​​始​​​​​​​階​​​​​​​段​​​​​​​的​​​​​​​ GFS2。​​​​​​​
  1. 使​​​​​​​用​​​​​​​ LVM,為​​​​​​​每​​​​​​​一​​​​​​​個​​​​​​​ Red Hat GFS2 檔​​​​​​​案​​​​​​​系​​​​​​​統​​​​​​​建​​​​​​​立​​​​​​​邏​​​​​​​輯​​​​​​​卷​​​​​​​冊​​​​​​​。​​​​​​​

    注意

    您​​​​​​​可​​​​​​​以​​​​​​​使​​​​​​​用​​​​​​​ Red Hat Cluster Suite 的​​​​​​​ init.d 程​​​​​​​序​​​​​​​檔​​​​​​​,來​​​​​​​自​​​​​​​動​​​​​​​啟​​​​​​​動​​​​​​​或​​​​​​​停​​​​​​​用​​​​​​​邏​​​​​​​輯​​​​​​​卷​​​​​​​冊​​​​​​​。​​​​​​​欲​​​​​​​知​​​​​​​更​​​​​​​多​​​​​​​關​​​​​​​於​​​​​​​ init.d 程​​​​​​​序​​​​​​​檔​​​​​​​的​​​​​​​詳​​​​​​​情​​​​​​​,請​​​​​​​參​​​​​​​閱​​​​​​​設​​​​​​​定​​​​​​​與​​​​​​​管​​​​​​​理​​​​​​​ Red Hat 叢​​​​​​​集​​​​​​​。​​​​​​​
  2. Create GFS2 file systems on logical volumes created in Step 1. Choose a unique name for each file system. For more information about creating a GFS2 file system, refer to 節 3.1, “製​​​​​​​作​​​​​​​檔​​​​​​​案​​​​​​​系​​​​​​​統​​​​​​​”.
    您​​​​​​​可​​​​​​​以​​​​​​​使​​​​​​​用​​​​​​​以​​​​​​​下​​​​​​​其​​​​​​​中​​​​​​​一​​​​​​​種​​​​​​​格​​​​​​​式​​​​​​​,建​​​​​​​立​​​​​​​叢​​​​​​​集​​​​​​​的​​​​​​​ GFS2 檔​​​​​​​案​​​​​​​系​​​​​​​統​​​​​​​:
    mkfs.gfs2 -p lock_dlm -t ClusterName:FSName -j NumberJournals BlockDevice
    mkfs -t gfs2 -p lock_dlm -t LockTableName -j NumberJournals BlockDevice
    您​​​​​​​可​​​​​​​以​​​​​​​使​​​​​​​用​​​​​​​以​​​​​​​下​​​​​​​格​​​​​​​式​​​​​​​之​​​​​​​一​​​​​​​,建​​​​​​​立​​​​​​​本​​​​​​​地​​​​​​​的​​​​​​​ GFS2 檔​​​​​​​案​​​​​​​系​​​​​​​統​​​​​​​:
    mkfs.gfs2 -p lock_nolock -j NumberJournals BlockDevice
    mkfs -t gfs2 -p lock_nolock -j NumberJournals BlockDevice
  3. 指​​​​​​​令​​​​​​​用​​​​​​​法​​​​​​​:
    mount BlockDevice MountPoint
    mount -o acl BlockDevice MountPoint
    掛​​​​​​​載​​​​​​​選​​​​​​​項​​​​​​​ -o acl 選​​​​​​​項​​​​​​​能​​​​​​​允​​​​​​​許​​​​​​​使​​​​​​​用​​​​​​​者​​​​​​​管​​​​​​​理​​​​​​​檔​​​​​​​案​​​​​​​的​​​​​​​ ACL(Access Control List,存​​​​​​​取​​​​​​​控​​​​​​​制​​​​​​​清​​​​​​​單​​​​​​​)。​​​​​​​如​​​​​​​果​​​​​​​檔​​​​​​​案​​​​​​​系​​​​​​​統​​​​​​​在​​​​​​​掛​​​​​​​載​​​​​​​時​​​​​​​,沒​​​​​​​有​​​​​​​使​​​​​​​用​​​​​​​ -o acl 掛​​​​​​​載​​​​​​​選​​​​​​​項​​​​​​​,使​​​​​​​用​​​​​​​者​​​​​​​就​​​​​​​可​​​​​​​以​​​​​​​檢​​​​​​​視​​​​​​​ ACL(利​​​​​​​用​​​​​​​ getfacl 指​​​​​​​令​​​​​​​);但​​​​​​​不​​​​​​​能​​​​​​​設​​​​​​​定​​​​​​​ ACL(利​​​​​​​用​​​​​​​ setfacl 指​​​​​​​令​​​​​​​)。​​​​​​​

    注意

    您​​​​​​​可​​​​​​​以​​​​​​​使​​​​​​​用​​​​​​​ Red Hat Cluster Suite 的​​​​​​​ init.d 程​​​​​​​序​​​​​​​檔​​​​​​​,來​​​​​​​自​​​​​​​動​​​​​​​啟​​​​​​​動​​​​​​​或​​​​​​​停​​​​​​​用​​​​​​​邏​​​​​​​輯​​​​​​​卷​​​​​​​冊​​​​​​​。​​​​​​​欲​​​​​​​知​​​​​​​更​​​​​​​多​​​​​​​關​​​​​​​於​​​​​​​ init.d 程​​​​​​​序​​​​​​​檔​​​​​​​的​​​​​​​詳​​​​​​​情​​​​​​​,請​​​​​​​參​​​​​​​閱​​​​​​​設​​​​​​​定​​​​​​​與​​​​​​​管​​​​​​​理​​​​​​​ Red Hat 叢​​​​​​​集​​​​​​​。​​​​​​​