ONTAPのtamperproof snapshotを設定してみる

ONTAP 9.12.1からtamperproof snapshot という機能が使えるようになったらしい

SnapLock and tamperproof snapshots for ransomware protection
Lock an ONTAP snapshot for protection against ransomware attacks

既存のボリュームに対しても設定出来るらしいので設定してみることにした

ONTAPライセンスとしては、SnapLockが使える必要があるため、「system license show」を実行して「SnapLock」が含まれているかを確認する

ボリュームに対する有効化の設定

ボリュームに対して tamperproof snapshot が設定されているかどうかは、volumeのsnapshot-locking-enabledのフラグを確認する

netapp::> volume show -vserver svm0 -fields snapshot-locking-enabled
vserver volume snapshot-locking-enabled
------- ------ ------------------------
svm0    hvmiso false
svm0    proxmox false
svm0    share  false
svm0    snaptest false
svm0    svm0_root false
5 entries were displayed.

netapp::>

上記のように「false」となっていると有効になっていない、ということ

volume modifyでsnapshot-locking-enabledをtrueに変更してみる

netapp::> volume modify -vserver svm0 -volume snaptest -snapshot-locking-enabled true

Warning: Snapshot locking is being enabled on volume "snaptest" in Vserver
         "svm0". It cannot be disabled until all locked snapshots are past
         their expiry time. A volume with unexpired locked snapshots cannot be
         deleted.
Do you want to continue? {y|n}: y

Error: command failed: Unable to set volume attribute
       "snapshot-locking-enabled" for volume "snaptest" on Vserver "svm0".
       Reason: Cannot perform this operation because the compliance clock is
       not running.

netapp::>

エラーとなる

書いてあるとおり「compliance clock」が動いてないためのエラーであるため「Initialize the ONTAP Compliance Clock」を参照して、開始する

まず、現状の状態を確認する

netapp::> snaplock compliance-clock show
Node                ComplianceClock Time
------------------- -----------------------------------
netapp-01           ComplianceClock is not configured.

netapp::>

compliance-clock はクラスタに対する設定、と

compliance clockサービスを開始

netapp::> snaplock compliance-clock initialize -node netapp-01

Warning: You are about to initialize the secure ComplianceClock of the node
         "netapp-01" to the current value of the node's system clock.
         ComplianceClock re-initialization requires all nodes in the cluster to
         be healthy, all volumes are in online state, no volumes are present in
         the volume recovery queue and there are no SnapLock volumes or volumes
         with "snapshot-locking-enabled" set to true or S3 buckets with object
         locking enabled. Ensure that the system time is set correctly before
         proceeding. The current node's system clock is: Fri Mar  6 17:51:36
         JST 2026

Do you want to continue? {y|n}: y

netapp::>

状態を確認

netapp::> snaplock compliance-clock show
Node                ComplianceClock Time
------------------- -----------------------------------
netapp-01           Fri Mar 06 17:52:11 JST 2026 +09:00

netapp::>

ドキュメントではcompliance lockをntpサーバに関連付ける設定をした方がよいみたいなので続きを実行

まず、CLIをadvanced権限に切り替え

netapp::> set adv

Warning: These advanced commands are potentially dangerous; use them only when
         directed to do so by NetApp personnel.
Do you want to continue? {y|n}: y

netapp::*>

続いて現状の確認

netapp::*> snaplock compliance-clock ntp show

Enable ComplianceClock sync to NTP system time: false

netapp::*>

いまは設定されていないので、有効にする

netapp::*> snaplock compliance-clock ntp modify -is-sync-enabled true

Warning: If ONTAP has been configured to use NTP server based system time, then
         this operation will make it possible for the SnapLock ComplianceClock
         to be synchronized to the system time. You must ensure that the
         configured NTP servers are trusted and the communication channel to
         them is secure. Failure to do this may result in SnapLock retention
         periods being compromised and compliance mandates being violated.
Do you want to continue? {y|n}: y

netapp::*>

変更されたことを確認

netapp::*> snaplock compliance-clock ntp show

Enable ComplianceClock sync to NTP system time: true

netapp::*>

権限を通常のadminに戻す

netapp::*> set admin

netapp::>

改めてボリュームに対してsnapshot-locking-enabled をtrueに変更するコマンドを実行

netapp::> volume modify -vserver svm0 -volume snaptest -snapshot-locking-enabled true

Warning: Snapshot locking is being enabled on volume "snaptest" in Vserver
         "svm0". It cannot be disabled until all locked snapshots are past
         their expiry time. A volume with unexpired locked snapshots cannot be
         deleted.
Do you want to continue? {y|n}: y
Volume modify successful on volume snaptest of Vserver svm0.

netapp::>

変更を確認

netapp::> volume show -vserver svm0 -fields snapshot-locking-enabled
vserver volume snapshot-locking-enabled
------- ------ ------------------------
svm0    hvmiso false
svm0    proxmox false
svm0    share  false
svm0    snaptest true
svm0    svm0_root false
5 entries were displayed.

netapp::>

実行したsnaptest ボリュームのみtrueになったことを確認

これで変更できた。

snapshot policyの設定

変更したボリュームに対して適切なsnapshotポリシーを設定しろ、とドキュメントの続きにある

Create a locked snapshot policy and apply retention

現状適用されているsnapshot policyを確認

netapp::> volume show -volume snaptest -fields snapshot-policy
vserver volume   snapshot-policy
------- -------- ---------------
svm0    snaptest default

netapp::>

「default」ポリシーの内容を確認

netapp::> volume snapshot policy show -policy default
Vserver: netapp
                         Number of Is
Policy Name              Schedules Enabled Comment
------------------------ --------- ------- ----------------------------------
default                          3 true    Default policy with hourly, daily & weekly schedules.
    Schedule       Count  Prefix        SnapMirror Label    Retention Period
    -------------- -----  ------------- ------------------  ------------------
    hourly             6  hourly        -                   0 seconds
    daily              2  daily         daily               0 seconds
    weekly             2  weekly        weekly              0 seconds


netapp::>

「Retention Period」の期間を過ぎるとsnapshotが削除できるようになる、という設定だが、標準値は「0秒」なので、取得後すぐに削除が可能になる、という設定となっている

このRetention Periodに必要な期間を設定した別のポリシーを作成するのが安全な対応となる。

ちなみにONTAP 9.11.1から9.17.1にアップデートした検証環境にある標準のsnapshot policyはこんな感じで、Retention Policyに意味がある設定となっているpolicyは作成されていなかった

netapp::> version
NetApp Release 9.17.1P3: Sun Dec 07 04:46:28 UTC 2025

netapp::> volume snapshot policy show
Vserver: netapp
                         Number of Is
Policy Name              Schedules Enabled Comment
------------------------ --------- ------- ----------------------------------
default                          3 true    Default policy with hourly, daily & weekly schedules.
    Schedule       Count  Prefix        SnapMirror Label    Retention Period
    -------------- -----  ------------- ------------------  ------------------
    hourly             6  hourly        -                   0 seconds
    daily              2  daily         daily               0 seconds
    weekly             2  weekly        weekly              0 seconds

default-1weekly                  3 true    Default policy with 6 hourly, 2 daily & 1 weekly schedule.
    Schedule       Count  Prefix        SnapMirror Label    Retention Period
    -------------- -----  ------------- ------------------  ------------------
    hourly             6  hourly        -                   0 seconds
    daily              2  daily         -                   0 seconds
    weekly             1  weekly        -                   0 seconds

none                             0 false   Policy for no automatic snapshots.
    Schedule       Count  Prefix        SnapMirror Label    Retention Period
    -------------- -----  ------------- ------------------  ------------------
    -                  -  -             -                   -

3 entries were displayed.

netapp::>

そんなわけで、defaultポリシーを流用した新しいポリシーを作成することにする

動作を確認するため、下記の微妙な設定にしてみる
 hourly 6個 Retention Period 1日
 daily 2個 Retention Period 1日
 weekly 2個 Retention Period 1日

hourly 6なのに、1日としているので、hourly が 24個作成されるはず、というものである

netapp::> volume snapshot policy create -policy snaptest -schedule1 hourly -count1 6 -prefix1 hourly -retention-period1 "1 days" -schedule2 daily -count2 2 -prefix2 daily -snapmirror-label2 daily -retention-period2 "1 days" -schedule3 weekly -count3 1 -prefix3 weekly -snapmirror-label3 weekly -retention-period3 "1 days"

Error: command failed: "enabled" is a required field

netapp::>

あ、「-enabled true」は必須でしたか

netapp::> volume snapshot policy create -policy snaptest -schedule1 hourly -count1 6 -prefix1 hourly -retention-period1 "1 days" -schedule2 daily -count2 2 -prefix2 daily -snapmirror-label2 daily -retention-period2 "1 days" -schedule3 weekly -count3 1 -prefix3 weekly -snapmirror-label3 weekly -retention-period3 "1 days" -enabled true

netapp::>

作成されたことを確認

netapp::> volume snapshot policy show -policy snaptest
Vserver: netapp
                         Number of Is
Policy Name              Schedules Enabled Comment
------------------------ --------- ------- ----------------------------------
snaptest                         3 true    -
    Schedule       Count  Prefix        SnapMirror Label    Retention Period
    -------------- -----  ------------- ------------------  ------------------
    hourly             6  hourly        -                   1 days
    daily              2  daily         daily               1 days
    weekly             1  weekly        weekly              1 days


netapp::>

現状のsnapshotの状態を確認

netapp::> volume snapshot show -vserver svm0 -volume snaptest
                                                                 ---Blocks---
Vserver  Volume   Snapshot                                  Size Total% Used%
-------- -------- ------------------------------------- -------- ------ -----
svm0     snaptest
                  hourly.2026-03-06_1805                   136KB     0%   24%

netapp::>

続いてsnapshot policyを変更

netapp::> volume show -vserver svm0 -volume snaptest -fields snapshot-policy
vserver volume   snapshot-policy
------- -------- ---------------
svm0    snaptest default

netapp::> volume modify -vserver svm0 -volume snaptest -snapshot-policy snaptest

Warning: You are changing the snapshot policy on volume "snaptest" to
         "snaptest". Snapshots on this volume that do not match any of the
         prefixes of the new snapshot policy will not be deleted. However, when
         the new snapshot policy takes effect, depending on the new retention
         count, any existing snapshots that continue to use the same prefixes
         might be deleted. See the "volume modify" man page for more
         information.
Do you want to continue? {y|n}: y
Volume modify successful on volume snaptest of Vserver svm0.
                                                                               enetapp::>

変更されたことを確認

netapp::> volume show -vserver svm0 -volume snaptest -fields snapshot-policy
vserver volume   snapshot-policy
------- -------- ---------------
svm0    snaptest snaptest

netapp::>

2つめのsnapshotが作成されるまで待機・・・

netapp::> volume snapshot show -vserver svm0 -volume snaptest
                                                                 ---Blocks---
Vserver  Volume   Snapshot                                  Size Total% Used%
-------- -------- ------------------------------------- -------- ------ -----
svm0     snaptest
                  hourly.2026-03-06_1805                   148KB     0%    6%
                  hourly.2026-03-06_1905                   140KB     0%    6%
2 entries were displayed.

netapp::>

詳細表示で比較

netapp::> volume snapshot show -vserver svm0 -volume snaptest -ins

                                   Vserver: svm0
                                    Volume: snaptest
                    cp Count (for sorting): 40
                                  Snapshot: hourly.2026-03-06_1805
                             Creation Time: Fri Mar 06 18:05:00 2026
                             Snapshot Busy: false
                            List of Owners: -
                             Snapshot Size: 148KB
                Percentage of Total Blocks: 0%
                 Percentage of Used Blocks: 6%
                                   Comment: -
                           7-Mode Snapshot: false
           Label for SnapMirror Operations: -
                            Snapshot State: -
                      Constituent Snapshot: false
                               Expiry Time: -
                      SnapLock Expiry Time: -
         Has the SnapLock Snapshot Expired: -
Seconds until the SnapLock Snapshot Expiry: -

                                   Vserver: svm0
                                    Volume: snaptest
                    cp Count (for sorting): 269
                                  Snapshot: hourly.2026-03-06_1905
                             Creation Time: Fri Mar 06 19:05:00 2026
                             Snapshot Busy: false
                            List of Owners: -
                             Snapshot Size: 140KB
                Percentage of Total Blocks: 0%
                 Percentage of Used Blocks: 6%
                                   Comment: -
                           7-Mode Snapshot: false
           Label for SnapMirror Operations: -
                            Snapshot State: -
                      Constituent Snapshot: false
                               Expiry Time: -
                      SnapLock Expiry Time: 3/7/2026 19:05:00 +09:00
         Has the SnapLock Snapshot Expired: false
Seconds until the SnapLock Snapshot Expiry: 86351
2 entries were displayed.

netapp::>

これまでは設定されていなかった下記3項目が設定されるようになった

SnapLock Expiry Time: 3/7/2026 19:05:00 +09:00
Has the SnapLock Snapshot Expired: false
Seconds until the SnapLock Snapshot Expiry: 86351

試しに作成されたlockedなsnapshotの削除を試みる

netapp::> volume snapshot delete -vserver svm0 -volume snaptest -snapshot hourly.2026-03-06_1905

Warning: Deleting a snapshot permanently removes data that is stored only in
         that snapshot. Are you sure you want to delete snapshot
         "hourly.2026-03-06_1905" for volume "snaptest" in Vserver "svm0" ?
          {y|n}: y

Error: command failed: Failed to delete snapshot "hourly.2026-03-06_1905" of
       volume "snaptest" on Vserver "svm0". Reason: Illegal operation on
       snapshot locked by SnapLock.

netapp::> volume snapshot show -vserver svm0 -volume snaptest
                                                                 ---Blocks---
Vserver  Volume   Snapshot                                  Size Total% Used%
-------- -------- ------------------------------------- -------- ------ -----
svm0     snaptest
                  hourly.2026-03-06_1805                   148KB     0%    6%
                  hourly.2026-03-06_1905                   140KB     0%    6%
2 entries were displayed.

netapp::>

想定通り削除することができないことを確認

で・・・数日放置・・・


netapp::> date
Node      Date                     Time zone
--------- ------------------------ -------------------------
netapp-01 Mon Mar 09 21:06:09 2026 Japan

netapp::> volume snapshot show -vserver svm0 -volume snaptest
                                                                 ---Blocks---
Vserver  Volume   Snapshot                                  Size Total% Used%
-------- -------- ------------------------------------- -------- ------ -----
svm0     snaptest
                  weekly.2026-03-08_2021                   152KB     0%    7%
                  daily.2026-03-08_2021                    152KB     0%    7%
                  hourly.2026-03-08_2105                   152KB     0%    7%
                  hourly.2026-03-08_2205                   152KB     0%    7%
                  hourly.2026-03-08_2305                   152KB     0%    7%
                  hourly.2026-03-09_0005                   152KB     0%    7%
                  daily.2026-03-09_0010                    152KB     0%    7%
                  hourly.2026-03-09_0105                   152KB     0%    7%
                  hourly.2026-03-09_0205                   152KB     0%    7%
                  hourly.2026-03-09_0305                   156KB     0%    8%
                  hourly.2026-03-09_0405                   152KB     0%    7%
                  hourly.2026-03-09_0505                   156KB     0%    8%
                  hourly.2026-03-09_0605                   156KB     0%    8%
                  hourly.2026-03-09_0705                   156KB     0%    8%
                  hourly.2026-03-09_0805                   152KB     0%    7%
                  hourly.2026-03-09_0905                   152KB     0%    7%
                  hourly.2026-03-09_1005                   152KB     0%    7%
                  hourly.2026-03-09_1105                   152KB     0%    7%
                  hourly.2026-03-09_1205                   160KB     0%    8%
                  hourly.2026-03-09_1305                   152KB     0%    7%
                  hourly.2026-03-09_1405                   152KB     0%    7%
                  hourly.2026-03-09_1505                   152KB     0%    7%
                  hourly.2026-03-09_1605                   152KB     0%    7%
                  hourly.2026-03-09_1705                   152KB     0%    7%
                  hourly.2026-03-09_1805                   152KB     0%    7%
                  hourly.2026-03-09_1905                   152KB     0%    7%
                  hourly.2026-03-09_2005                 45.37MB     0%   96%
                  hourly.2026-03-09_2105                   164KB     0%    8%
28 entries were displayed.

netapp::>

設定上はhourlyは6にも関わらず、24時間以内のhourlyが残ってますね

作成時間(create-time)とsnaplockの解除時間(snaplock-expiry-time)を一覧化

netapp::> volume snapshot show -vserver svm0 -volume snaptest -fields snaplock-expiry-time,snaplock-snapshot-expired,create-time
vserver volume   snapshot               create-time              snaplock-expiry-time     snaplock-snapshot-expired
------- -------- ---------------------- ------------------------ ------------------------ -------------------------
svm0    snaptest weekly.2026-03-08_2021 Sun Mar 08 20:21:24 2026 3/7/2026 19:12:12 +09:00 true
svm0    snaptest daily.2026-03-08_2021  Sun Mar 08 20:21:25 2026 3/7/2026 19:12:13 +09:00 true
svm0    snaptest hourly.2026-03-08_2105 Sun Mar 08 21:05:00 2026 3/7/2026 19:55:48 +09:00 true
svm0    snaptest hourly.2026-03-08_2205 Sun Mar 08 22:05:00 2026 3/7/2026 20:55:47 +09:00 false
svm0    snaptest hourly.2026-03-08_2305 Sun Mar 08 23:05:00 2026 3/7/2026 21:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_0005 Mon Mar 09 00:05:00 2026 3/7/2026 22:55:47 +09:00 false
svm0    snaptest daily.2026-03-09_0010  Mon Mar 09 00:10:00 2026 3/7/2026 23:00:48 +09:00 false
svm0    snaptest hourly.2026-03-09_0105 Mon Mar 09 01:05:00 2026 3/7/2026 23:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_0205 Mon Mar 09 02:05:00 2026 3/8/2026 00:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_0305 Mon Mar 09 03:05:00 2026 3/8/2026 01:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_0405 Mon Mar 09 04:05:00 2026 3/8/2026 02:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_0505 Mon Mar 09 05:05:00 2026 3/8/2026 03:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_0605 Mon Mar 09 06:05:00 2026 3/8/2026 04:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_0705 Mon Mar 09 07:05:00 2026 3/8/2026 05:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_0805 Mon Mar 09 08:05:00 2026 3/8/2026 06:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_0905 Mon Mar 09 09:05:00 2026 3/8/2026 07:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1005 Mon Mar 09 10:05:00 2026 3/8/2026 08:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_1105 Mon Mar 09 11:05:00 2026 3/8/2026 09:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_1205 Mon Mar 09 12:05:00 2026 3/8/2026 10:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1305 Mon Mar 09 13:05:00 2026 3/8/2026 11:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1405 Mon Mar 09 14:05:00 2026 3/8/2026 12:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1505 Mon Mar 09 15:05:00 2026 3/8/2026 13:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_1605 Mon Mar 09 16:05:00 2026 3/8/2026 14:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_1705 Mon Mar 09 17:05:00 2026 3/8/2026 15:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1805 Mon Mar 09 18:05:00 2026 3/8/2026 16:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1905 Mon Mar 09 19:05:00 2026 3/8/2026 17:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_2005 Mon Mar 09 20:05:00 2026 3/8/2026 18:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_2105 Mon Mar 09 21:05:00 2026 3/8/2026 19:55:48 +09:00 false
28 entries were displayed.

netapp::>

dailyとweeklyのsnaplock-expiry-timeも含めて全部1日で設定しているので、いま残っているdailyとweeklyのsnapshotについては snaplock-snapshot-expired:true となっているので、削除可能な状態になっている

・・・って、おや???なんで、作成時間より期限切れ時間の方が過去なんだ??

netapp::> volume snapshot show -vserver svm0 -volume snaptest -snapshot hourly.2026-03-09_2105

                                   Vserver: svm0
                                    Volume: snaptest
                    cp Count (for sorting): 5982
                                  Snapshot: hourly.2026-03-09_2105
                             Creation Time: Mon Mar 09 21:05:00 2026
                             Snapshot Busy: false
                            List of Owners: -
                             Snapshot Size: 164KB
                Percentage of Total Blocks: 0%
                 Percentage of Used Blocks: 8%
                                   Comment: -
                           7-Mode Snapshot: false
           Label for SnapMirror Operations: -
                            Snapshot State: -
                      Constituent Snapshot: false
                               Expiry Time: -
                      SnapLock Expiry Time: 3/8/2026 19:55:48 +09:00
         Has the SnapLock Snapshot Expired: false
Seconds until the SnapLock Snapshot Expiry: 85862

netapp::>

おかしいぞ、compliance-clockの値を確認

netapp::> date
Node Date Time zone


netapp-01 Mon Mar 09 21:14:14 2026 Japan

netapp::> set diag

Warning: These diagnostic commands are for use by NetApp personnel only.
Do you want to continue? {y|n}: y

netapp::*> snaplock compliance-clock sho
Node ComplianceClock Time Node ID ID


netapp-01 Sat Mar 07 20:05:28 JST 2026 +09:00 4082368507 1772787102399

netapp::*>

システムを2日ほど停止していたせいで、compliance-clock が止まっていた模様

netapp::*>  snaplock compliance-clock ntp show

Enable ComplianceClock sync to NTP system time: true

netapp::*>

ntpと同期を取るという設定にしていたので大丈夫だと思っていたのですが、なんとNetAppのNTP設定を忘れていたというやらかしでした・・・

netapp::*> cluster time-service ntp server show
This table is currently empty.

netapp::*> cluster time-service ntp server create -server ntp.jst.mfeed.ad.jp

netapp::*> cluster time-service ntp server show
                                    Is                     Is         Is Public
                                    Authentication         Preferred  Server
Server                     Version  Enabled        Key ID  Server     Default
-------------------------- -------  -------------- ------  ---------  ---------
ntp.jst.mfeed.ad.jp        auto     false          -       false      false

netapp::*> cluster time-service ntp status show

Node: netapp-01
Server                  Reachable  Selection State                Offset (ms)
----------------------- ---------  ------------------------------ ------------
ntp.jst.mfeed.ad.jp          true  Currently Selected Server              0.53

netapp::*>

NTPを設定してから、compliance-clockを確認・・・変化はなし

netapp::*> snaplock compliance-clock show
Node        ComplianceClock Time                Node ID    ID
----------- ----------------------------------- ---------- -------------
netapp-01   Sat Mar 07 20:14:03 JST 2026 +09:00 4082368507 1772787102399

netapp::*>

一回falseにしてからtrueにすれば同期されるかな?と試すも変わらず


netapp::*> snaplock compliance-clock ntp modify -is-sync-enabled false

netapp::*> snaplock compliance-clock ntp show

Enable ComplianceClock sync to NTP system time: false

netapp::*> snaplock compliance-clock show
Node        ComplianceClock Time                Node ID    ID
----------- ----------------------------------- ---------- -------------
netapp-01   Sat Mar 07 20:15:36 JST 2026 +09:00 4082368507 1772787102399

netapp::*> snaplock compliance-clock ntp modify -is-sync-enabled true

Warning: If ONTAP has been configured to use NTP server based system time, then this operation will make it possible for
         the SnapLock ComplianceClock to be synchronized to the system time. You must ensure that the configured NTP
         servers are trusted and the communication channel to them is secure. Failure to do this may result in SnapLock
         retention periods being compromised and compliance mandates being violated.
Do you want to continue? {y|n}: y

netapp::*> snaplock compliance-clock ntp show

Enable ComplianceClock sync to NTP system time: true

netapp::*> snaplock compliance-clock show
Node        ComplianceClock Time                Node ID    ID
----------- ----------------------------------- ---------- -------------
netapp-01   Sat Mar 07 20:15:46 JST 2026 +09:00 4082368507 1772787102399

netapp::*>

[Amazon FSx for NetApp ONTAP] SnapLockによるWORMを試してみた」の記事によると、1回設定したあとは、compliance clockはずれたとしても、システムクロックに合わせた時間に調整することはできない模様

それを踏まえて、現在のcompliance clockの時刻「Sat Mar 07 20:20:21 JST 2026 +09:00」と、各snapshotの「snaplock-expiry-time」を比較する、ということになるようだ

netapp::> date
Node      Date                     Time zone
--------- ------------------------ -------------------------
netapp-01 Mon Mar 09 21:29:22 2026 Japan

netapp::> snaplock compliance-clock show
Node                ComplianceClock Time
------------------- -----------------------------------
netapp-01           Sat Mar 07 20:20:21 JST 2026 +09:00

netapp::> volume snapshot show -vserver svm0 -volume snaptest -fields snaplock-expiry-time,snaplock-snapshot-expired,create-time
vserver volume   snapshot               create-time              snaplock-expiry-time     snaplock-snapshot-expired
------- -------- ---------------------- ------------------------ ------------------------ -------------------------
svm0    snaptest weekly.2026-03-08_2021 Sun Mar 08 20:21:24 2026 3/7/2026 19:12:12 +09:00 true
svm0    snaptest daily.2026-03-08_2021  Sun Mar 08 20:21:25 2026 3/7/2026 19:12:13 +09:00 true
svm0    snaptest hourly.2026-03-08_2105 Sun Mar 08 21:05:00 2026 3/7/2026 19:55:48 +09:00 true
svm0    snaptest hourly.2026-03-08_2205 Sun Mar 08 22:05:00 2026 3/7/2026 20:55:47 +09:00 false
svm0    snaptest hourly.2026-03-08_2305 Sun Mar 08 23:05:00 2026 3/7/2026 21:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_0005 Mon Mar 09 00:05:00 2026 3/7/2026 22:55:47 +09:00 false
svm0    snaptest daily.2026-03-09_0010  Mon Mar 09 00:10:00 2026 3/7/2026 23:00:48 +09:00 false
svm0    snaptest hourly.2026-03-09_0105 Mon Mar 09 01:05:00 2026 3/7/2026 23:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_0205 Mon Mar 09 02:05:00 2026 3/8/2026 00:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_0305 Mon Mar 09 03:05:00 2026 3/8/2026 01:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_0405 Mon Mar 09 04:05:00 2026 3/8/2026 02:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_0505 Mon Mar 09 05:05:00 2026 3/8/2026 03:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_0605 Mon Mar 09 06:05:00 2026 3/8/2026 04:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_0705 Mon Mar 09 07:05:00 2026 3/8/2026 05:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_0805 Mon Mar 09 08:05:00 2026 3/8/2026 06:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_0905 Mon Mar 09 09:05:00 2026 3/8/2026 07:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1005 Mon Mar 09 10:05:00 2026 3/8/2026 08:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_1105 Mon Mar 09 11:05:00 2026 3/8/2026 09:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_1205 Mon Mar 09 12:05:00 2026 3/8/2026 10:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1305 Mon Mar 09 13:05:00 2026 3/8/2026 11:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1405 Mon Mar 09 14:05:00 2026 3/8/2026 12:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1505 Mon Mar 09 15:05:00 2026 3/8/2026 13:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_1605 Mon Mar 09 16:05:00 2026 3/8/2026 14:55:48 +09:00 false
svm0    snaptest hourly.2026-03-09_1705 Mon Mar 09 17:05:00 2026 3/8/2026 15:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1805 Mon Mar 09 18:05:00 2026 3/8/2026 16:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_1905 Mon Mar 09 19:05:00 2026 3/8/2026 17:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_2005 Mon Mar 09 20:05:00 2026 3/8/2026 18:55:47 +09:00 false
svm0    snaptest hourly.2026-03-09_2105 Mon Mar 09 21:05:00 2026 3/8/2026 19:55:48 +09:00 false
28 entries were displayed.

netapp::>

HPE VMEのクラスタ制御関連のメモ

HPE VMEクラスタを作った場合、実際にクラスタ状態を制御してるのはなんなのか、というメモ

問題があった時に遭遇したものを書いてるだけなので、他にも仕組みがあるかもしれない

GFS2ファイルシステム周り

複数サーバでGFS2ファイルシステムを使う場合、制御に pacemaker+corosyncを利用していた。

サーバ3台構成で組んだ場合に、GFS2構築後に、停止状態から起動させると、しばらくGFS2ファイルシステムがマウントされていない状態になっている

これはpacemaker+corosyncにより所属サーバの過半数から得票がとれなければ正常に動作していないと判断され、GFS2ファイルシステムをマウントしない、ということから来ている。

GFS2ファイルシステムのマウント制御について確認する場合、まずは「sudo pcs status」コマンドを実行して、確認をする。下記は3サーバ構成で全て起動している場合のもの

pcuser@hpevme1:~$ sudo pcs status
Cluster name: 2rouf0rh0q94m4i
Cluster Summary:
  * Stack: corosync (Pacemaker is running)
  * Current DC: hpevme2 (version 2.1.6-6fdc9deea29) - partition with quorum
  * Last updated: Wed Mar  4 10:57:03 2026 on hpevme1
  * Last change:  Fri Feb 27 17:56:49 2026 by root via cibadmin on hpevme3
  * 3 nodes configured
  * 7 resource instances configured

Node List:
  * Online: [ hpevme1 hpevme2 hpevme3 ]

Full List of Resources:
  * Clone Set: dlm-clone [dlm]:
    * Started: [ hpevme1 hpevme2 hpevme3 ]
  * hpevm_gfs2_scsi     (stonith:fence_scsi_hpevm):      Started hpevme1
  * Clone Set: gfs2datastore_1ffa9-clone [gfs2datastore_1ffa9]:
    * Started: [ hpevme1 hpevme2 hpevme3 ]

Daemon Status:
  corosync: active/enabled
  pacemaker: active/enabled
  pcsd: active/enabled
pcuser@hpevme1:~$

“Daemon Status”に表示されているようにcorosync, pacemakerが関連していることがわかる

「sudo pcs status –full」を実行すると詳細表示

pcuser@hpevme1:~$ sudo pcs status --full
Cluster name: 2rouf0rh0q94m4i
Cluster Summary:
  * Stack: corosync (Pacemaker is running)
  * Current DC: hpevme2 (2) (version 2.1.6-6fdc9deea29) - partition with quorum
  * Last updated: Wed Mar  4 10:57:07 2026 on hpevme1
  * Last change:  Fri Feb 27 17:56:49 2026 by root via cibadmin on hpevme3
  * 3 nodes configured
  * 7 resource instances configured

Node List:
  * Node hpevme1 (1): online, feature set 3.17.4
  * Node hpevme2 (2): online, feature set 3.17.4
  * Node hpevme3 (3): online, feature set 3.17.4

Full List of Resources:
  * Clone Set: dlm-clone [dlm]:
    * dlm       (ocf:pacemaker:controld):        Started hpevme2
    * dlm       (ocf:pacemaker:controld):        Started hpevme1
    * dlm       (ocf:pacemaker:controld):        Started hpevme3
  * hpevm_gfs2_scsi     (stonith:fence_scsi_hpevm):      Started hpevme1
  * Clone Set: gfs2datastore_1ffa9-clone [gfs2datastore_1ffa9]:
    * gfs2datastore_1ffa9       (ocf:heartbeat:Filesystem):      Started hpevme2
    * gfs2datastore_1ffa9       (ocf:heartbeat:Filesystem):      Started hpevme1
    * gfs2datastore_1ffa9       (ocf:heartbeat:Filesystem):      Started hpevme3

Migration Summary:

Fencing History:
  * unfencing of hpevme2 successful: delegate=hpevme2, client=pacemaker-fenced.2051, origin=hpevme3, completed='2026-03-04 10:50:33.927998 +09:00'
  * unfencing of hpevme1 successful: delegate=hpevme1, client=pacemaker-controld.1993, origin=hpevme2, completed='2026-03-04 10:50:33.860998 +09:00'
  * unfencing of hpevme3 successful: delegate=hpevme3, client=pacemaker-controld.1993, origin=hpevme2, completed='2026-03-04 10:50:33.718998 +09:00'

Tickets:

PCSD Status:
  hpevme1: Online
  hpevme2: Online
  hpevme3: Online

Daemon Status:
  corosync: active/enabled
  pacemaker: active/enabled
  pcsd: active/enabled
pcuser@hpevme1:~$

pcsコマンドの下層に、corosyncがある、という構造になっているので、corosync側のステータスを確認することもできる

過半数をどうやって調査しているか、という部分はcorosyncのquorumで行っているので、そのステータスを確認するために「sudo corosync-quorumtool -s」を実行

pcuser@hpevme1:~$ sudo corosync-quorumtool -s
Quorum information
------------------
Date:             Wed Mar  4 11:04:48 2026
Quorum provider:  corosync_votequorum
Nodes:            3
Node ID:          1
Ring ID:          1.3d
Quorate:          Yes

Votequorum information
----------------------
Expected votes:   3
Highest expected: 3
Total votes:      3
Quorum:           2
Flags:            Quorate

Membership information
----------------------
    Nodeid      Votes Name
         1          1 hpevme1 (local)
         2          1 hpevme2
         3          1 hpevme3
pcuser@hpevme1:~$

corosyncで行う各サーバ間の通信がどのIPで行われているかは「sudo corosync-cfgtool -n」

pcuser@hpevme1:~$ sudo corosync-cfgtool -n
Local node ID 1, transport knet
nodeid: 2 reachable
   LINK: 0 udp (192.168.1.51->192.168.1.52) enabled connected mtu: 1397

nodeid: 3 reachable
   LINK: 0 udp (192.168.1.51->192.168.1.53) enabled connected mtu: 1397

pcuser@hpevme1:~$ sudo corosync-cfgtool -s
Local node ID 1, transport knet
LINK ID 0 udp
        addr    = 192.168.1.51
        status:
                nodeid:          1:     localhost
                nodeid:          2:     connected
                nodeid:          3:     connected
pcuser@hpevme1:~$

なお、上記例では「192.168.1.0/24」のネットワークを使っているが、このIPアドレス帯はマネージメント用として各物理サーバおよびHPE VME Managerサーバに使用しているものとなる。(Webアクセスや、sshアクセスで使うもの)

corosync用のネットワークを別のサブネットに設定する、といった設定GUIはv8.0.13でもなかったような・・・


サーバ1台止めた場合のコマンド出力

「sudo pcs status」

pcuser@hpevme2:~$ sudo pcs status
[sudo] password for pcuser:
Cluster name: 2rouf0rh0q94m4i
Cluster Summary:
  * Stack: corosync (Pacemaker is running)
  * Current DC: hpevme2 (version 2.1.6-6fdc9deea29) - partition with quorum
  * Last updated: Wed Mar  4 13:11:33 2026 on hpevme2
  * Last change:  Fri Feb 27 17:56:49 2026 by root via cibadmin on hpevme3
  * 3 nodes configured
  * 7 resource instances configured

Node List:
  * Online: [ hpevme2 hpevme3 ]
  * OFFLINE: [ hpevme1 ]

Full List of Resources:
  * Clone Set: dlm-clone [dlm]:
    * Started: [ hpevme2 hpevme3 ]
    * Stopped: [ hpevme1 ]
  * hpevm_gfs2_scsi     (stonith:fence_scsi_hpevm):      Started hpevme2
  * Clone Set: gfs2datastore_1ffa9-clone [gfs2datastore_1ffa9]:
    * Started: [ hpevme2 hpevme3 ]
    * Stopped: [ hpevme1 ]

Daemon Status:
  corosync: active/enabled
  pacemaker: active/enabled
  pcsd: active/enabled
pcuser@hpevme2:~$

「sudo pcs status –full」

pcuser@hpevme2:~$ sudo pcs status --full
Cluster name: 2rouf0rh0q94m4i
Cluster Summary:
  * Stack: corosync (Pacemaker is running)
  * Current DC: hpevme2 (2) (version 2.1.6-6fdc9deea29) - partition with quorum
  * Last updated: Wed Mar  4 13:12:26 2026 on hpevme2
  * Last change:  Fri Feb 27 17:56:49 2026 by root via cibadmin on hpevme3
  * 3 nodes configured
  * 7 resource instances configured

Node List:
  * Node hpevme1 (1): OFFLINE
  * Node hpevme2 (2): online, feature set 3.17.4
  * Node hpevme3 (3): online, feature set 3.17.4

Full List of Resources:
  * Clone Set: dlm-clone [dlm]:
    * dlm       (ocf:pacemaker:controld):        Started hpevme2
    * dlm       (ocf:pacemaker:controld):        Started hpevme3
    * dlm       (ocf:pacemaker:controld):        Stopped
  * hpevm_gfs2_scsi     (stonith:fence_scsi_hpevm):      Started hpevme2
  * Clone Set: gfs2datastore_1ffa9-clone [gfs2datastore_1ffa9]:
    * gfs2datastore_1ffa9       (ocf:heartbeat:Filesystem):      Started hpevme2
    * gfs2datastore_1ffa9       (ocf:heartbeat:Filesystem):      Started hpevme3
    * gfs2datastore_1ffa9       (ocf:heartbeat:Filesystem):      Stopped

Migration Summary:

Fencing History:
  * reboot of hpevme1 successful: delegate=hpevme2, client=stonith-api.30408, origin=hpevme2, completed='2026-03-04 13:05:43.082713 +09:00'
  * unfencing of hpevme2 successful: delegate=hpevme2, client=pacemaker-fenced.2051, origin=hpevme3, completed='2026-03-04 10:50:33.986998 +09:00'
  * unfencing of hpevme1 successful: delegate=hpevme1, client=pacemaker-controld.1993, origin=hpevme2, completed='2026-03-04 10:50:33.916998 +09:00'
  * unfencing of hpevme3 successful: delegate=hpevme3, client=pacemaker-controld.1993, origin=hpevme2, completed='2026-03-04 10:50:33.773998 +09:00'

Tickets:

PCSD Status:
  hpevme1: Offline
  hpevme2: Online
  hpevme3: Online

Daemon Status:
  corosync: active/enabled
  pacemaker: active/enabled
  pcsd: active/enabled
pcuser@hpevme2:~$

「sudo corosync-quorumtool -s」

pcuser@hpevme2:~$ sudo corosync-quorumtool -s
Quorum information
------------------
Date:             Wed Mar  4 13:13:02 2026
Quorum provider:  corosync_votequorum
Nodes:            2
Node ID:          2
Ring ID:          2.41
Quorate:          Yes

Votequorum information
----------------------
Expected votes:   3
Highest expected: 3
Total votes:      2
Quorum:           2
Flags:            Quorate

Membership information
----------------------
    Nodeid      Votes Name
         2          1 hpevme2 (local)
         3          1 hpevme3
pcuser@hpevme2:~$

「sudo corosync-cfgtool -n」

pcuser@hpevme2:~$ sudo corosync-cfgtool -n
Local node ID 2, transport knet
nodeid: 3 reachable
   LINK: 0 udp (192.168.1.52->192.168.1.53) enabled connected mtu: 1397

pcuser@hpevme2:~$ sudo corosync-cfgtool -s
Local node ID 2, transport knet
LINK ID 0 udp
        addr    = 192.168.1.52
        status:
                nodeid:          1:     disconnected
                nodeid:          2:     localhost
                nodeid:          3:     connected
pcuser@hpevme2:~$

HPE VMEでのiSCSIストレージ登録とGFS2データストア作成

HPE VME ver 8.0.13環境を作ってみたところ、以前と比べてGFS2データストア作成プロセスが改善されていたのでメモ

(1) HPE VME側でiSCSIターゲットIP登録

[インフラストラクチャ]-[クラスター]で該当クラスタを選択し、[ストレージ]-[iSCSI]にてiSCSIストレージのターゲットIPアドレスを登録

これを行うと、しばらくすると各サーバの /etc/iscsi/initiatorname.iscsi  の InitiatorName に設定されている名前で、iSCSIストレージに対してアクセスが実施される

(2) iSCSIストレージ側でInitiatorNameを登録

iSCSIストレージ側で、各サーバの /etc/iscsi/initiatorname.iscsi  の InitiatorName の名前を登録し、アクセスを許可する

NetAppの例

しばらく待っても接続ステータスが変更されない場合は、該当のVMEサーバにログインして「sudo iscsiadm -m session –rescan」を実行してスキャンを行う

pcuser@hpevme1:~$ sudo iscsiadm -m session --rescan
Rescanning session [sid: 1, target: iqn.1992-08.com.netapp:sn.588844e7ec3411f0a4bd000c292a75e7:vs.8, portal: 192.168.3.35,3260]
Rescanning session [sid: 2, target: iqn.1992-08.com.netapp:sn.588844e7ec3411f0a4bd000c292a75e7:vs.8, portal: 192.168.2.35,3260]
pcuser@hpevme1:~$

(3) HPE VME側でディスクが認識されているか確認

[インフラストラクチャ]-[クラスター]で該当クラスタを選択し、[ストレージ]-[データストア]にて「追加」をクリックして表示される「データストアの追加」にて

「Type:GFS2 Pool (Global File System 2)」を選択し、「BLOCK DEVICE」の選択を確認する

上記の様に「/dev/mapper/~」というディスクが認識されていれば、マルチパスで認識されているiSCSIディスクとなる。

mapperというデバイスが認識されていない場合、iSCSIマルチパスが動作しているかを確認する

まずはディスクデバイスが認識されているかを「sudo iscsiadm -m session -P 3」を実行して、「Attached SCSI devices:」の後に「scsi ??? Channel 00 ID 0 Lun :1」といった形でディスクが認識されていることを確認

pcuser@hpevme1:~$ sudo iscsiadm -m session -P 3
iSCSI Transport Class version 2.0-870
version 2.1.9
Target: iqn.1992-08.com.netapp:sn.588844e7ec3411f0a4bd000c292a75e7:vs.8 (non-flash)
        Current Portal: 192.168.3.35:3260,1028
        Persistent Portal: 192.168.3.35:3260,1028
                **********
                Interface:
                **********
                Iface Name: default
                Iface Transport: tcp
                Iface Initiatorname: iqn.2024-12.com.hpe:hpevme1:42939
                Iface IPaddress: 192.168.3.51
                Iface HWaddress: default
                Iface Netdev: default
                SID: 1
                iSCSI Connection State: LOGGED IN
                iSCSI Session State: LOGGED_IN
                Internal iscsid Session State: NO CHANGE
                *********
                Timeouts:
                *********
                Recovery Timeout: 5
                Target Reset Timeout: 30
                LUN Reset Timeout: 30
                Abort Timeout: 15
                *****
                CHAP:
                *****
                username: <empty>
                password: ********
                username_in: <empty>
                password_in: ********
                ************************
                Negotiated iSCSI params:
                ************************
                HeaderDigest: None
                DataDigest: None
                MaxRecvDataSegmentLength: 262144
                MaxXmitDataSegmentLength: 65536
                FirstBurstLength: 65536
                MaxBurstLength: 1048576
                ImmediateData: Yes
                InitialR2T: Yes
                MaxOutstandingR2T: 1
                ************************
                Attached SCSI devices:
                ************************
                Host Number: 33 State: running
                scsi33 Channel 00 Id 0 Lun: 1
                        Attached scsi disk sdc          State: running
        Current Portal: 192.168.2.35:3260,1027
        Persistent Portal: 192.168.2.35:3260,1027
                **********
                Interface:
                **********
                Iface Name: default
                Iface Transport: tcp
                Iface Initiatorname: iqn.2024-12.com.hpe:hpevme1:42939
                Iface IPaddress: 192.168.2.51
                Iface HWaddress: default
                Iface Netdev: default
                SID: 2
                iSCSI Connection State: LOGGED IN
                iSCSI Session State: LOGGED_IN
                Internal iscsid Session State: NO CHANGE
                *********
                Timeouts:
                *********
                Recovery Timeout: 5
                Target Reset Timeout: 30
                LUN Reset Timeout: 30
                Abort Timeout: 15
                *****
                CHAP:
                *****
                username: <empty>
                password: ********
                username_in: <empty>
                password_in: ********
                ************************
                Negotiated iSCSI params:
                ************************
                HeaderDigest: None
                DataDigest: None
                MaxRecvDataSegmentLength: 262144
                MaxXmitDataSegmentLength: 65536
                FirstBurstLength: 65536
                MaxBurstLength: 1048576
                ImmediateData: Yes
                InitialR2T: Yes
                MaxOutstandingR2T: 1
                ************************
                Attached SCSI devices:
                ************************
                Host Number: 34 State: running
                scsi34 Channel 00 Id 0 Lun: 1
                        Attached scsi disk sdb          State: running
pcuser@hpevme1:~$

これが認識されていないようであればiSCSIストレージ側のLUNマッピング設定やイニシエータのマッピング設定を見直す

マルチパスが動作しているかを確認する場合は「sudo multipath -ll」を実行して確認

pcuser@hpevme1:~$ sudo multipath -ll
3600a09807770457a795d5a554c634a58 dm-1 NETAPP,LUN C-Mode
size=100G features='3 queue_if_no_path pg_init_retries 50' hwhandler='1 alua' wp=rw
`-+- policy='service-time 0' prio=50 status=active
  |- 34:0:0:1 sdb 8:16 active ready running
  `- 33:0:0:1 sdc 8:32 active ready running
pcuser@hpevme1:~$

上記の様に、ツリーが表示されていればマルチパスが動作している

以前のバージョンではmultipathの設定を手動で行っていたが、ver 8.0.13では不要だった。

(4) HPE VME側でGFS2ファイルシステムの作成

[インフラストラクチャ]-[クラスター]で該当クラスタを選択し、[ストレージ]-[データストア]にて「追加」をクリックして表示される「データストアの追加」にて

「Type:GFS2 Pool (Global File System 2)」を選択し、「BLOCK DEVICE」の選択/dev/mapper/で始まるマルチパスデバイスを指定

しばらくファイルシステム作成が実施される

ver8.0.13時点ではファイルシステムが完成しても通知はなかったので、リロードなどして表示を更新する

これでGFS2データストアは作成できた。

sambaで作ったActive DirectoryではGet-ADDomainコマンドなどはエラーになる

sambaで作ったActive Directoryサーバ環境で、Windows ServerからPowerShellのGet-ADDomainコマンドを実行してみたところエラーとなった

PS C:\Users\administrator.ADSAMPLE> Get-ADDomain
Get-ADDomain : Active Directory Web サービスが実行されている状態で既定のサーバーを検索することはできません。
発生場所 行:1 文字:1
+ Get-ADDomain
+ ~~~~~~~~~~~~
    + CategoryInfo          : ResourceUnavailable: (ADSAMPLE:ADDomain) [Get-ADDomain], ADServerDownException
    + FullyQualifiedErrorId : ActiveDirectoryServer:1355,Microsoft.ActiveDirectory.Management.Commands.GetADDomain

PS C:\Users\administrator.ADSAMPLE>

サーバ名を指定すればいけるかな?と「Get-ADDomain -Server サーバ名」にしてもエラー

PS C:\Users\administrator.ADSAMPLE> Get-ADDomain -Server adsample.local
Get-ADDomain : サーバーと通信できません。サーバーが存在しないか、現在ダウンしているか、サーバー上で Active Directory Web サービスが実行されていない可能性があります。
発生場所 行:1 文字:1
+ Get-ADDomain -Server adsample.local
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ResourceUnavailable: (:) [Get-ADDomain], ADServerDownException
    + FullyQualifiedErrorId : ActiveDirectoryServer:0,Microsoft.ActiveDirectory.Management.Commands.GetADDomain

PS C:\Users\administrator.ADSAMPLE>

今度は「Active Directory Web サービスが実行されていない」ことがエラーの原因とされている。

Active Directory Web サービス について確認すると、どうやらsamba では提供されていないようだ。

2021年4月13日に作成されたsamba wikiのページ「ADWS / AD Powershell compatibility」に、「Samba does not support many of the AD PowerShell commands that manipulate AD objects,」とある

そこによると、2016年頃に「samba-adws」というPowerShellコマンドを使えるようにするプロジェクトが立ち上がって、開発中とのこと。

masterブランチの最終更新は2018年12月であるが、「garming-main」ブランチを見ると、2024年9月頃までなんかやっていたようで、それは https://github.com/GSam/samba-adws にておもに開発してたようで、それは https://github.com/GSam/samba で公開されているパッチ版で利用できるようだ

ただ、どちらにせよ、1年以上更新はされていないようだ

このため、PowerShellのActive Directory関連のコマンドレット群はsamba環境で使用できない、ということになるようだ

Ryzen 5 3500U環境でnested esxiを作ろうとしたらディスクが見えない

GMKtec NucBox G10 mini にESXi8 Freeをインストールして使っているんだけど、ESXi 7からESXi 8へのバージョンアップ手順を確認したくて、nested esxi環境を作ろうとした・・・

仮想マシンを[その他]-[VMware ESXi 7.x]で作成して

仮想マシンのCPU設定は詳細を開いて「ハードウェア仮想化」「IOMMU」「パフォーマンスカウンター」にチェックを入れて

SCSIコントローラは「VMware Paravirtual(PVSCSI)」で、ディスクはscsi0 で接続して作成

これでインストールを進めると選択できるディスクがない

この状態で、AlmaLinux 9.7のISOで起動すると普通にインストールできて起動してくる。

いろいろ悩んだ結果・・・

「IOMMU」と「パフォーマンスカウンター」のチェックを外してみたところ

ディスクが見えるようになりました

Intel N97環境でNested ESXiをインストールした際は、IOMMIとパフォーマンスカウンターにチェックが入っていてもディスクを認識してくれたのに、Ryzen 5 3500U環境ではダメなようです。