CmDiag DevelopmentMode -On
CmDiag Debug -On -Net
Cmdiag Enumerate
91adbbb2-8b19-4f35-9a31-8c97c1d66b9c , Madrid , CmsContainerTypeVirtualMachine , CmsContainerStateRunning
- hvsics
Usage: CmDiag [command] [options]
Commands:
Help - Shows this help message.
Enumerate - Enumerates the existing containers.
Debug - Configures container debugging options.
TestSign - Configures test signing.
-hostip 172.20.240.1 是物理网卡不是虚拟交换机Default Switch
CmDiag Debug -On -Net -HostIP 10.75.80.199 -Port 50000 -KEY 2ytsvwjw68b0t.pw0p4bjp0zba.2l325jzoj9ptj.xn462v3g1w3v
Debugging successfully enabled. Connection string: -k net:port=50000,key=2ytsvwjw68b0t.pw0p4bjp0zba.2l325jzoj9ptj.xn462v3g1w3v -v
CmDiag Debug -Off
C:\Windows\System32>CmDiag Debug -On -Net
Configures container debugging options.
Options:
-On - Enables container debugging.
-(Serial|Net) - Selects the type of debugging to configure. At least one of '-PipeName' and '-SkPipeName' must be supplied.
If both are supplied, both pipe names must be different.
[-PipeName n] - If serial debugging, specifies the name of the pipe through which the guest's kernel will be debugged. If
not supplied, the guest's kernel will not be debugged.
[-SkPipeName n] - If serial debugging, specifies the name of the pipe through which the guest's Secure Kernel will be
- debugged. This option requires Virtualization Based Security to be enabled on the host. If not supplied,
the guest's Secure Kernel will not be debugged.
[-Port p] - If net debugging, specifies the port that will be used (by default, port is 60000).
[-Key k] - If net debugging, specifies the key that will be used (by default, key is cl.ea.rt.ext).
[-HostIP h] - Required. If net debugging, specifies the IP address of the debugger host.
[-NoTestSign] - Disables test signing.
[-NoBootDebug] - Disables boot debugging.
[-AllowDirectMap] - Allows direct mapped binaries (by default, direct map is disabled).
-Off - Disables container debugging.
-LayerId - Provides the Id of the layer to be debugged. A user can specify a friendly name like "Professional".
-StorageId - Provides the Id of the storage to be debugged.
-Global - Indicates to enable/disable debugging globally. This is the default.
Examples:
CmDiag Debug -On -Net -Port 90000 -HostIP 123.456.134.145 -LayerId Win2
CmDiag Debug -Off -StorageId 76c1c3aa-5c10-489a-b84c-5e8fe8a3d086
C:\Windows\System32>CmDiag Debug -On -Net -hostip 10.75.80.127 -port 50000
Debugging successfully enabled.
Connection string: -k net:port=50000,key=cl.ea.rt.ext -v
C:\Windows\System32>cmdiag
Container Manager Diagnostics Tool
Usage: CmDiag [command] [options]
Commands:
Help - Shows this help message.
Enumerate - Enumerates the existing containers.
Exec - Executes a process in a container.
Console - Executes a console process in a container.
Map - Maps a host folder into a container.
Unmap - Unmaps a folder from a container.
MapPipe - Maps a host pipe into a container.
UnmapPipe - Unmaps a pipe from a container.
AddNetwork - Adds a network to the container.
RemoveNetwork - Removes a network from the container.
Shutdown - Gracefully shuts down a persisted container.
Terminate - Forcefully terminates a container.
Crash - Crashes the container.
StartActivity - Starts an activity on a container.
QueryActivities - Queries the list of activities associated with a container.
CreateContainer - Creates and boots a container.
DevelopmentMode - Configures the container manager for development mode.
Debug - Configures container debugging options.
TestSign - Configures test signing.
Copy - Copies a private to the container's base image.
CreateStorage - Creates a container storage.
MapStorage - Maps a storage inside a container.
UnmapStorage - Unmaps a storage inside a container.
SetupViewOfMappedStorage - Sets up a view of a mapped storage.
DebugResource - Configures a container resource for debugging.
C:\Windows\System32>
C:\Windows\System32>cmdiag TestSign /?
Configures test signing.
Options:
-On - Enables test signing. Note that enabling debugging will also, by default, enable test signing.
[-Force] - Kills any running containers (test signing can't be applied with running containers).
-Off - Disables test signing. Note that disabling debugging will also disable test signing.
[-Force] - Kills any running containers (test signing can't be applied with running containers).
Examples:
CmDiag TestSign -on
CmDiag TestSign -off -force
C:\Windows\System32>cmdiag TestSign -ON
In order to use this command, development mode must first be enabled by running:
CmDiag DevelopmentMode -on
CmDiag failed with error code: 0x8007139F
C:\Windows\System32>CmDiag DevelopmentMode -on
Development mode was successfully enabled. You can disable it by running:
CmDiag DevelopmentMode -off
沙盒加载驱动方法
CmDiag DevelopmentMode -on
CmDiag TestSign -on