The nova.db.sqlalchemy.models Module

SQLAlchemy models for nova data.

class AgentBuild(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents an agent build.

architecture
created_at
deleted
deleted_at
hypervisor
id
md5hash
os
updated_at
url
version
class Aggregate(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a cluster of hosts that exists in this zone.

availability_zone
created_at
deleted
deleted_at
hosts
id
metadetails
name
updated_at
class AggregateHost(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a host that is member of an aggregate.

aggregate_id
created_at
deleted
deleted_at
host
id
updated_at
class AggregateMetadata(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a metadata key/value pair for an aggregate.

aggregate_id
created_at
deleted
deleted_at
id
key
updated_at
value
class BandwidthUsage(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Cache for instance bandwidth usage data pulled from the hypervisor.

bw_in
bw_out
created_at
deleted
deleted_at
id
last_ctr_in
last_ctr_out
last_refreshed
mac
start_period
updated_at
uuid
class BlockDeviceMapping(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents block device mapping that is defined by EC2.

connection_info
created_at
delete_on_termination
deleted
deleted_at
device_name
id
instance
instance_uuid
no_device
snapshot_id
updated_at
virtual_name
volume_id
volume_size
class Cell(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents parent and child cells of this cell. Cells can have multiple parents and children, so there could be any number of entries with is_parent=True or False

api_url
created_at
deleted
deleted_at
id
is_parent
name
password
rpc_host
rpc_port
rpc_virtual_host
updated_at
username
weight_offset
weight_scale
class Certificate(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a x509 certificate.

created_at
deleted
deleted_at
file_name
id
project_id
updated_at
user_id
class ComputeNode(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a running compute service on a host.

cpu_info
created_at
current_workload
deleted
deleted_at
disk_available_least
free_disk_gb
free_ram_mb
hypervisor_hostname
hypervisor_type
hypervisor_version
id
local_gb
local_gb_used
memory_mb
memory_mb_used
running_vms
service
service_id
updated_at
vcpus
vcpus_used
class ComputeNodeStat(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Stats related to the current workload of a compute host that are intended to aid in making scheduler decisions.

compute_node_id
created_at
deleted
deleted_at
id
key
primary_join = 'and_(ComputeNodeStat.compute_node_id == ComputeNode.id, ComputeNodeStat.deleted == 0)'
stats
updated_at
value
class Console(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a console session for an instance.

created_at
deleted
deleted_at
id
instance_name
instance_uuid
password
pool
pool_id
port
updated_at
class ConsolePool(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents pool of consoles on the same physical node.

address
compute_host
console_type
created_at
deleted
deleted_at
host
id
password
public_hostname
updated_at
username
class DNSDomain(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a DNS domain with availability zone or project info.

availability_zone
created_at
deleted
deleted_at
domain
project_id
scope
updated_at
class FixedIp(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a fixed ip for an instance.

address
allocated
created_at
deleted
deleted_at
host
id
instance
instance_uuid
leased
network
network_id
reserved
updated_at
virtual_interface_id
class FloatingIp(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a floating ip that dynamically forwards to a fixed ip.

address
auto_assigned
created_at
deleted
deleted_at
fixed_ip
fixed_ip_id
host
id
interface
pool
project_id
updated_at
class Instance(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a guest VM.

access_ip_v4
access_ip_v6
architecture
auto_disk_config
availability_zone
cell_name
config_drive
created_at
default_ephemeral_device
default_swap_device
deleted
deleted_at
disable_terminate
display_description
display_name
ephemeral_gb
host
hostname
id
image_ref
injected_files = []
instance_type_id
kernel_id
key_data
key_name
launch_index
launched_at
launched_on
locked
memory_mb
name
node
os_type
power_state
progress
project_id
ramdisk_id
reservation_id
root_device_name
root_gb
scheduled_at
shutdown_terminate
task_state
terminated_at
updated_at
user_data
user_id
uuid
vcpus
vm_mode
vm_state
class InstanceAction(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Track client actions on an instance.

The intention is that there will only be one of these per user request. A lookup by (instance_uuid, request_id) should always return a single result.

action
created_at
deleted
deleted_at
finish_time
id
instance_uuid
message
project_id
request_id
start_time
updated_at
user_id
class InstanceActionEvent(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Track events that occur during an InstanceAction.

action_id
created_at
deleted
deleted_at
event
finish_time
id
result
start_time
traceback
updated_at
class InstanceFault(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

code
created_at
deleted
deleted_at
details
host
id
instance_uuid
message
updated_at
class InstanceIdMapping(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Compatibility layer for the EC2 instance service.

created_at
deleted
deleted_at
id
updated_at
uuid
class InstanceInfoCache(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a cache of information about an instance

created_at
deleted
deleted_at
id
instance
instance_uuid
network_info
updated_at
class InstanceMetadata(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a user-provided metadata key/value pair for an instance.

created_at
deleted
deleted_at
id
instance
instance_uuid
key
updated_at
value
class InstanceSystemMetadata(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a system-owned metadata key/value pair for an instance.

created_at
deleted
deleted_at
id
instance
instance_uuid
key
primary_join = 'and_(InstanceSystemMetadata.instance_uuid == Instance.uuid, InstanceSystemMetadata.deleted == 0)'
updated_at
value
class InstanceTypeExtraSpecs(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents additional specs as key/value pairs for an instance_type.

created_at
deleted
deleted_at
id
instance_type
instance_type_id
key
updated_at
value
class InstanceTypeProjects(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represent projects associated instance_types.

created_at
deleted
deleted_at
id
instance_type
instance_type_id
project_id
updated_at
class InstanceTypes(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represent possible instance_types or flavor of VM offered.

created_at
deleted
deleted_at
disabled
ephemeral_gb
flavorid
id
is_public
memory_mb
name
root_gb
rxtx_factor
swap
updated_at
vcpu_weight
vcpus
class IscsiTarget(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents an iscsi target for a given host.

created_at
deleted
deleted_at
host
id
target_num
updated_at
volume
volume_id
class KeyPair(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a public key pair for ssh.

created_at
deleted
deleted_at
fingerprint
id
name
public_key
updated_at
user_id
class Migration(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a running host-to-host migration.

created_at
deleted
deleted_at
dest_compute
dest_host
dest_node
id
instance
instance_uuid
new_instance_type_id
old_instance_type_id
source_compute
source_node
status
updated_at
class Network(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a network.

bridge
bridge_interface
broadcast
cidr
cidr_v6
created_at
deleted
deleted_at
dhcp_start
dns1
dns2
gateway
gateway_v6
host
id
injected
label
multi_host
netmask
netmask_v6
priority
project_id
rxtx_base
updated_at
uuid
vlan
vpn_private_address
vpn_public_address
vpn_public_port
class NovaBase

Bases: nova.openstack.common.db.sqlalchemy.models.SoftDeleteMixin, nova.openstack.common.db.sqlalchemy.models.ModelBase

class ProviderFirewallRule(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a rule in a security group.

cidr
created_at
deleted
deleted_at
from_port
id
protocol
to_port
updated_at
class Quota(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a single quota override for a project.

If there is no row for a given project id and resource, then the default for the quota class is used. If there is no row for a given quota class and resource, then the default for the deployment is used. If the row is present but the hard limit is Null, then the resource is unlimited.

created_at
deleted
deleted_at
hard_limit
id
project_id
resource
updated_at
class QuotaClass(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a single quota override for a quota class.

If there is no row for a given quota class and resource, then the default for the deployment is used. If the row is present but the hard limit is Null, then the resource is unlimited.

class_name
created_at
deleted
deleted_at
hard_limit
id
resource
updated_at
class QuotaUsage(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents the current usage for a given resource.

created_at
deleted
deleted_at
id
in_use
project_id
reserved
resource
total
until_refresh
updated_at
class Reservation(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a resource reservation for quotas.

created_at
deleted
deleted_at
delta
expire
id
project_id
resource
updated_at
usage
usage_id
uuid
class S3Image(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Compatibility layer for the S3 image service talking to Glance.

created_at
deleted
deleted_at
id
updated_at
uuid
class SecurityGroup(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a security group.

created_at
deleted
deleted_at
description
id
instances
name
project_id
updated_at
user_id
class SecurityGroupIngressDefaultRule(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

cidr
created_at
deleted
deleted_at
from_port
id
protocol
to_port
updated_at
class SecurityGroupIngressRule(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a rule in a security group.

cidr
created_at
deleted
deleted_at
from_port
grantee_group
group_id
id
parent_group
parent_group_id
protocol
to_port
updated_at
class SecurityGroupInstanceAssociation(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

created_at
deleted
deleted_at
id
instance_uuid
security_group_id
updated_at
class Service(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a running service on a host.

binary
created_at
deleted
deleted_at
disabled
host
id
report_count
topic
updated_at
class Snapshot(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a block storage device that can be attached to a VM.

created_at
deleted
deleted_at
display_description
display_name
id
name
progress
project_id
status
updated_at
user_id
volume_id
volume_name
volume_size
class SnapshotIdMapping(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Compatibility layer for the EC2 snapshot service.

created_at
deleted
deleted_at
id
updated_at
uuid
class TaskLog(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Audit log for background periodic tasks.

created_at
deleted
deleted_at
errors
host
id
message
period_beginning
period_ending
state
task_items
task_name
updated_at
class VirtualInterface(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a virtual interface on an instance.

address
created_at
deleted
deleted_at
id
instance_uuid
network_id
updated_at
uuid
class Volume(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Represents a block storage device that can be attached to a VM.

attach_status
attach_time
availability_zone
created_at
deleted
deleted_at
display_description
display_name
ec2_id
host
id
instance_uuid
launched_at
mountpoint
name
project_id
provider_auth
provider_location
scheduled_at
size
snapshot_id
status
terminated_at
updated_at
user_id
volume_type_id
class VolumeIdMapping(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Compatibility layer for the EC2 volume service.

created_at
deleted
deleted_at
id
updated_at
uuid
class VolumeUsage(**kwargs)

Bases: sqlalchemy.ext.declarative.Base, nova.db.sqlalchemy.models.NovaBase

Cache for volume usage data pulled from the hypervisor.

created_at
curr_last_refreshed
curr_read_bytes
curr_reads
curr_write_bytes
curr_writes
deleted
deleted_at
id
instance_id
tot_last_refreshed
tot_read_bytes
tot_reads
tot_write_bytes
tot_writes
updated_at
volume_id

Previous topic

The nova.db.sqlalchemy.migration Module

Next topic

The nova.db.sqlalchemy.types Module

This Page