github.com/vmware/govmomi@v0.37.1/simulator/esx/event_manager.go (about) 1 /* 2 Copyright (c) 2018-2023 VMware, Inc. All Rights Reserved. 3 4 Licensed under the Apache License, Version 2.0 (the "License"); 5 you may not use this file except in compliance with the License. 6 You may obtain a copy of the License at 7 8 http://www.apache.org/licenses/LICENSE-2.0 9 10 Unless required by applicable law or agreed to in writing, software 11 distributed under the License is distributed on an "AS IS" BASIS, 12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 See the License for the specific language governing permissions and 14 limitations under the License. 15 */ 16 17 package esx 18 19 import "github.com/vmware/govmomi/vim25/types" 20 21 // EventInfo is the default template for the EventManager description.eventInfo property. 22 // Capture method: 23 // govc object.collect -s -dump EventManager:ha-eventmgr description.eventInfo 24 // The captured list has been manually pruned and FullFormat fields changed to use Go's template variable syntax. 25 var EventInfo = []types.EventDescriptionEventDetail{ 26 { 27 Key: "UserLoginSessionEvent", 28 Description: "User login", 29 Category: "info", 30 FullFormat: "User {{.UserName}}@{{.IpAddress}} logged in as {{.UserAgent}}", 31 }, 32 { 33 Key: "UserLogoutSessionEvent", 34 Description: "User logout", 35 Category: "info", 36 FullFormat: "User {{.UserName}}@{{.IpAddress}} logged out (login time: {{.LoginTime}}, number of API invocations: {{.CallCount}}, user agent: {{.UserAgent}})", 37 }, 38 { 39 Key: "DatacenterCreatedEvent", 40 Description: "Datacenter created", 41 Category: "info", 42 FullFormat: "Created datacenter {{.Datacenter.Name}} in folder {{.Parent.Name}}", 43 }, 44 { 45 Key: "DatastoreFileMovedEvent", 46 Description: "File or directory moved to datastore", 47 Category: "info", 48 FullFormat: "Move of file or directory {{.SourceFile}} from {{.SourceDatastore.Name}} to {{.Datastore.Name}} as {{.TargetFile}}", 49 }, 50 { 51 Key: "DatastoreFileCopiedEvent", 52 Description: "File or directory copied to datastore", 53 Category: "info", 54 FullFormat: "Copy of file or directory {{.SourceFile}} from {{.SourceDatastore.Name}} to {{.Datastore.Name}} as {{.TargetFile}}", 55 }, 56 { 57 Key: "DatastoreFileDeletedEvent", 58 Description: "File or directory deleted", 59 Category: "info", 60 FullFormat: "Deletion of file or directory {{.TargetFile}} from {{.Datastore.Name}} was initiated", 61 }, 62 { 63 Key: "EnteringMaintenanceModeEvent", 64 Description: "Entering maintenance mode", 65 Category: "info", 66 FullFormat: "Host {{.Host.Name}} in {{.Datacenter.Name}} has started to enter maintenance mode", 67 }, 68 { 69 Key: "EnteredMaintenanceModeEvent", 70 Description: "Entered maintenance mode", 71 Category: "info", 72 FullFormat: "Host {{.Host.Name}} in {{.Datacenter.Name}} has entered maintenance mode", 73 }, 74 { 75 Key: "ExitMaintenanceModeEvent", 76 Description: "Exit maintenance mode", 77 Category: "info", 78 FullFormat: "Host {{.Host.Name}} in {{.Datacenter.Name}} has exited maintenance mode", 79 }, 80 { 81 Key: "HostRemovedEvent", 82 Description: "Host removed", 83 FullFormat: "Removed host {{.Host.Name}} in {{.Datacenter.Name}}", 84 Category: "info", 85 }, 86 { 87 Key: "VmSuspendedEvent", 88 Description: "VM suspended", 89 Category: "info", 90 FullFormat: "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is suspended", 91 }, 92 { 93 Key: "VmMigratedEvent", 94 Description: "VM migrated", 95 Category: "info", 96 FullFormat: "Migration of virtual machine {{.Vm.Name}} from {{.SourceHost.Name}}, {{.SourceDatastore.Name}} to {{.Host.Name}}, {{.Ds.Name}} completed", 97 }, 98 { 99 Key: "VmBeingMigratedEvent", 100 Description: "VM migrating", 101 Category: "info", 102 FullFormat: "Relocating {{.Vm.Name}} from {{.Host.Name}, {{.Ds.Name}} in {{.Datacenter.Name}} to {{.DestHost.Name}, {{.DestDatastore.Name}} in {{.DestDatacenter.Name}}", 103 }, 104 { 105 Key: "VmMacAssignedEvent", 106 Description: "VM MAC assigned", 107 Category: "info", 108 FullFormat: "New MAC address ({{.Mac}}) assigned to adapter {{.Adapter}} for {{.Vm.Name}}", 109 }, 110 { 111 Key: "VmRegisteredEvent", 112 Description: "VM registered", 113 Category: "info", 114 FullFormat: "Registered {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}", 115 }, 116 { 117 Key: "VmReconfiguredEvent", 118 Description: "VM reconfigured", 119 Category: "info", 120 FullFormat: "Reconfigured {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}", 121 }, 122 { 123 Key: "VmGuestRebootEvent", 124 Description: "Guest reboot", 125 Category: "info", 126 FullFormat: "Guest OS reboot for {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}", 127 }, 128 { 129 Key: "VmBeingClonedEvent", 130 Description: "VM being cloned", 131 Category: "info", 132 FullFormat: "Cloning {{.Vm.Name}} on host {{.Host.Name}} in {{.Datacenter.Name}} to {{.DestName}} on host {{.DestHost.Name}}", 133 }, 134 { 135 Key: "VmClonedEvent", 136 Description: "VM cloned", 137 Category: "info", 138 FullFormat: "Clone of {{.SourceVm.Name}} completed", 139 }, 140 { 141 Key: "VmBeingDeployedEvent", 142 Description: "Deploying VM", 143 Category: "info", 144 FullFormat: "Deploying {{.Vm.Name}} on host {{.Host.Name}} in {{.Datacenter.Name}} from template {{.SrcTemplate.Name}}", 145 }, 146 { 147 Key: "VmDeployedEvent", 148 Description: "VM deployed", 149 Category: "info", 150 FullFormat: "Template {{.SrcTemplate.Name}} deployed on host {{.Host.Name}}", 151 }, 152 { 153 Key: "VmInstanceUuidAssignedEvent", 154 Description: "Assign a new instance UUID", 155 Category: "info", 156 FullFormat: "Assign a new instance UUID ({{.InstanceUuid}}) to {{.Vm.Name}}", 157 }, 158 { 159 Key: "VmPoweredOnEvent", 160 Description: "VM powered on", 161 Category: "info", 162 FullFormat: "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is powered on", 163 }, 164 { 165 Key: "VmStartingEvent", 166 Description: "VM starting", 167 Category: "info", 168 FullFormat: "{{.Vm.Name}} on host {{.Host.Name}} in {{.Datacenter.Name}} is starting", 169 }, 170 { 171 Key: "VmStoppingEvent", 172 Description: "VM stopping", 173 Category: "info", 174 FullFormat: "{{.Vm.Name}} on host {{.Host.Name}} in {{.Datacenter.Name}} is stopping", 175 }, 176 { 177 Key: "VmSuspendingEvent", 178 Description: "VM being suspended", 179 Category: "info", 180 FullFormat: "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is being suspended", 181 }, 182 { 183 Key: "VmResumingEvent", 184 Description: "VM resuming", 185 Category: "info", 186 FullFormat: "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is resumed", 187 }, 188 { 189 Key: "VmBeingCreatedEvent", 190 Description: "Creating VM", 191 Category: "info", 192 FullFormat: "Creating {{.Vm.Name}} on host {{.Host.Name}} in {{.Datacenter.Name}}", 193 }, 194 { 195 Key: "VmCreatedEvent", 196 Description: "VM created", 197 Category: "info", 198 FullFormat: "Created virtual machine {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}", 199 }, 200 { 201 Key: "VmRemovedEvent", 202 Description: "VM removed", 203 Category: "info", 204 FullFormat: "Removed {{.Vm.Name}} on {{.Host.Name}} from {{.Datacenter.Name}}", 205 }, 206 { 207 Key: "VmResettingEvent", 208 Description: "VM resetting", 209 Category: "info", 210 FullFormat: "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is reset", 211 }, 212 { 213 Key: "VmGuestShutdownEvent", 214 Description: "Guest OS shut down", 215 Category: "info", 216 FullFormat: "Guest OS shut down for {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}", 217 }, 218 { 219 Key: "VmUuidAssignedEvent", 220 Description: "VM UUID assigned", 221 Category: "info", 222 FullFormat: "Assigned new BIOS UUID ({{.Uuid}}) to {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}", 223 }, 224 { 225 Key: "VmPoweredOffEvent", 226 Description: "VM powered off", 227 Category: "info", 228 FullFormat: "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is powered off", 229 }, 230 { 231 Key: "VmRelocatedEvent", 232 Description: "VM relocated", 233 Category: "info", 234 FullFormat: "Completed the relocation of the virtual machine", 235 }, 236 { 237 Key: "CustomizationFailed", 238 Description: "An error occurred during customization", 239 Category: "info", 240 FullFormat: "An error occurred during customization on VM {{.Vm.Name}}", 241 }, 242 { 243 Key: "CustomizationStartedEvent", 244 Description: "Started customization", 245 Category: "info", 246 FullFormat: "Started customization of VM {{.Vm.Name}}", 247 }, 248 { 249 Key: "CustomizationSucceeded", 250 Description: "Customization succeeded", 251 Category: "info", 252 FullFormat: "Customization of VM {{.Vm.Name}} succeeded", 253 }, 254 { 255 Key: "DrsVmMigratedEvent", 256 Description: "DRS VM migrated", 257 Category: "info", 258 FullFormat: "DRS migrated {{.Vm.Name}} from {{.SourceHost.Name}} to {{.Host.Name}} in cluster {{.ComputeResource.Name}} in {{.Datacenter.Name}}", 259 }, 260 { 261 Key: "DrsVmPoweredOnEvent", 262 Description: "DRS VM powered on", 263 Category: "info", 264 FullFormat: "DRS powered On {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}", 265 }, 266 { 267 Key: "DvsCreatedEvent", 268 Description: "vSphere Distributed Switch created", 269 Category: "info", 270 FullFormat: "A vSphere Distributed Switch {{.Dvs.Name}} was created in {{.Datacenter.Name}}.", 271 }, 272 { 273 Key: "DvsDestroyedEvent", 274 Description: "vSphere Distributed Switch deleted", 275 Category: "info", 276 FullFormat: "vSphere Distributed Switch {{.Dvs.Name}} in {{.Datacenter.Name}} was deleted.", 277 }, 278 { 279 Key: "DvsReconfiguredEvent", 280 Description: "vSphere Distributed Switch reconfigured", 281 Category: "info", 282 FullFormat: "The vSphere Distributed Switch {{.Dvs.Name}} in {{.Datacenter.Name}} was reconfigured.", 283 }, 284 { 285 Key: "DvsHostJoinedEvent", 286 Description: "Host joined the vSphere Distributed Switch", 287 Category: "info", 288 FullFormat: "The host {{.HostJoined.Name}} joined the vSphere Distributed Switch {{.Dvs.Name}} in {{.Datacenter.Name}}.", 289 }, 290 { 291 Key: "DvsHostLeftEvent", 292 Description: "Host left vSphere Distributed Switch", 293 Category: "info", 294 FullFormat: "The host {{.HostLeft.Name}} left the vSphere Distributed Switch {{.Dvs.Name}} in {{.Datacenter.Name}}.", 295 }, 296 { 297 Key: "DVPortgroupCreatedEvent", 298 Description: "dvPort group created", 299 Category: "info", 300 FullFormat: "dvPort group {{.Net.Name}} in {{.Datacenter.Name}} was added to switch {{.Dvs.Name}}.", 301 }, 302 { 303 Key: "DVPortgroupDestroyedEvent", 304 Description: "dvPort group deleted", 305 Category: "info", 306 FullFormat: "dvPort group {{.Net.Name}} in {{.Datacenter.Name}} was deleted.", 307 }, 308 }