Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vcsim custom 'state' definition #1185

Closed
jakerobinson opened this issue Jul 20, 2018 · 4 comments
Closed

vcsim custom 'state' definition #1185

jakerobinson opened this issue Jul 20, 2018 · 4 comments

Comments

@jakerobinson
Copy link

@jakerobinson jakerobinson commented Jul 20, 2018

I'd like to define a custom state of a simulator instance (e.g. datacenters, networks, VMs, hosts) so that I don't have to remove the defaults and add my own at runtime. This would allow me to mimic what I have in my physical lab or even in production, and test different scenarios very quickly.

@dougm
Copy link
Member

@dougm dougm commented Jul 20, 2018

vcsim -dc 0 and your inventory is empty

Or vcsim -vm 0 if you want everything except VMs. Similar for the other types.
The flags are hooked up to the Model fields, we could have an option to specify in a file instead of the switches:

// Datacenter specifies the number of Datacenter entities to create
Datacenter int
// Portgroup specifies the number of DistributedVirtualPortgroup entities to create per Datacenter
Portgroup int
// Host specifies the number of standalone HostSystems entities to create per Datacenter
Host int `json:",omitempty"`
// Cluster specifies the number of ClusterComputeResource entities to create per Datacenter
Cluster int
// ClusterHost specifies the number of HostSystems entities to create within a Cluster
ClusterHost int `json:",omitempty"`
// Pool specifies the number of ResourcePool entities to create per Cluster
Pool int
// Datastore specifies the number of Datastore entities to create
// Each Datastore will have temporary local file storage and will be mounted
// on every HostSystem created by the ModelConfig
Datastore int
// Machine specifies the number of VirtualMachine entities to create per ResourcePool
Machine int
// Folder specifies the number of Datacenter to place within a Folder.
// This includes a folder for the Datacenter itself and its host, vm, network and datastore folders.
// All resources for the Datacenter are placed within these folders, rather than the top-level folders.
Folder int
// App specifies the number of VirtualApp to create per Cluster
App int
// Pod specifies the number of StoragePod to create per Cluster
Pod int

@dougm
Copy link
Member

@dougm dougm commented Jul 20, 2018

The related flags:

% vcsim -h
Usage of vcsim:
  -app int
        Number of virtual apps per compute resource
  -cluster int
        Number of clusters (default 1)
  -dc int
        Number of datacenters (default 1)
  -ds int
        Number of local datastores (default 1)
  -folder int
        Number of folders
  -host int
        Number of hosts per cluster (default 3)
  -pg int
        Number of port groups (default 1)
  -pod int
        Number of storage pods per datacenter
  -pool int
        Number of resource pools per compute resource
  -standalone-host int
        Number of standalone hosts (default 1)
  -vm int
        Number of virtual machines per resource pool (default 2)

@dougm
Copy link
Member

@dougm dougm commented Oct 18, 2018

@jakerobinson do the flags above provide what you need?

@github-actions
Copy link

@github-actions github-actions bot commented May 26, 2021

This issue is stale because it has been open for 90 days with no
activity. It will automatically close after 30 more days of
inactivity. Mark as fresh by adding the comment /remove-lifecycle stale.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants