@@ -216,7 +216,7 @@ CREATE TABLE `cloud`.`nics` (
216216 ` id` bigint unsigned NOT NULL UNIQUE AUTO_INCREMENT COMMENT ' id' ,
217217 ` instance_id` bigint unsigned COMMENT ' vm instance id' ,
218218 ` mac_address` varchar (17 ) COMMENT ' mac address' ,
219- ` ip4_address` varchar ( 15 ) COMMENT ' ip4 address' ,
219+ ` ip4_address` char ( 40 ) COMMENT ' ip4 address' ,
220220 ` netmask` varchar (15 ) COMMENT ' netmask for ip4 address' ,
221221 ` gateway` varchar (15 ) COMMENT ' gateway' ,
222222 ` ip_type` varchar (32 ) COMMENT ' type of ip' ,
@@ -300,7 +300,7 @@ CREATE TABLE `cloud`.`op_host_upgrade` (
300300CREATE TABLE `cloud `.` op_lock` (
301301 ` key` varchar (128 ) NOT NULL UNIQUE COMMENT ' primary key of the table' ,
302302 ` mac` varchar (17 ) NOT NULL COMMENT ' mac address of who acquired this lock' ,
303- ` ip` varchar ( 15 ) NOT NULL COMMENT ' ip address of who acquired this lock' ,
303+ ` ip` char ( 40 ) NOT NULL COMMENT ' ip address of who acquired this lock' ,
304304 ` thread` varchar (255 ) NOT NULL COMMENT ' Thread that acquired this lock' ,
305305 ` acquired_on` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT ' Time acquired' ,
306306 ` waiters` int NOT NULL DEFAULT 0 COMMENT ' How many have waited for this' ,
@@ -371,7 +371,7 @@ CREATE TABLE `cloud`.`volumes` (
371371 ` pod_id` bigint unsigned COMMENT ' pod this volume belongs to' ,
372372 ` data_center_id` bigint unsigned NOT NULL COMMENT ' data center this volume belongs to' ,
373373 ` iscsi_name` varchar (255 ) COMMENT ' iscsi target name' ,
374- ` host_ip` varchar ( 15 ) COMMENT ' host ip address for convenience' ,
374+ ` host_ip` char ( 40 ) COMMENT ' host ip address for convenience' ,
375375 ` volume_type` varchar (64 ) NOT NULL COMMENT ' root, swap or data' ,
376376 ` resource_type` varchar (64 ) COMMENT ' pool-based or host-based' ,
377377 ` pool_type` varchar (64 ) COMMENT ' type of the pool' ,
@@ -490,7 +490,7 @@ CREATE TABLE `cloud`.`data_center` (
490490
491491CREATE TABLE `cloud `.` op_dc_ip_address_alloc` (
492492 ` id` bigint unsigned NOT NULL AUTO_INCREMENT COMMENT ' primary key' ,
493- ` ip_address` varchar ( 15 ) NOT NULL COMMENT ' ip address' ,
493+ ` ip_address` char ( 40 ) NOT NULL COMMENT ' ip address' ,
494494 ` data_center_id` bigint unsigned NOT NULL COMMENT ' data center it belongs to' ,
495495 ` pod_id` bigint unsigned NOT NULL COMMENT ' pod it belongs to' ,
496496 ` instance_id` bigint unsigned NULL COMMENT ' instance id' ,
@@ -507,7 +507,7 @@ CREATE TABLE `cloud`.`op_dc_ip_address_alloc` (
507507
508508CREATE TABLE `cloud `.` op_dc_link_local_ip_address_alloc` (
509509 ` id` bigint unsigned NOT NULL AUTO_INCREMENT COMMENT ' primary key' ,
510- ` ip_address` varchar ( 15 ) NOT NULL COMMENT ' ip address' ,
510+ ` ip_address` char ( 40 ) NOT NULL COMMENT ' ip address' ,
511511 ` data_center_id` bigint unsigned NOT NULL COMMENT ' data center it belongs to' ,
512512 ` pod_id` bigint unsigned NOT NULL COMMENT ' pod it belongs to' ,
513513 ` instance_id` bigint unsigned NULL COMMENT ' instance id' ,
@@ -600,17 +600,17 @@ CREATE TABLE `cloud`.`host` (
600600 ` name` varchar (255 ) NOT NULL ,
601601 ` status` varchar (32 ) NOT NULL ,
602602 ` type` varchar (32 ) NOT NULL ,
603- ` private_ip_address` varchar ( 15 ) NOT NULL ,
603+ ` private_ip_address` char ( 40 ) NOT NULL ,
604604 ` private_netmask` varchar (15 ),
605605 ` private_mac_address` varchar (17 ),
606- ` storage_ip_address` varchar ( 15 ) NOT NULL ,
606+ ` storage_ip_address` char ( 40 ) NOT NULL ,
607607 ` storage_netmask` varchar (15 ),
608608 ` storage_mac_address` varchar (17 ),
609- ` storage_ip_address_2` varchar ( 15 ),
609+ ` storage_ip_address_2` char ( 40 ),
610610 ` storage_mac_address_2` varchar (17 ),
611611 ` storage_netmask_2` varchar (15 ),
612612 ` cluster_id` bigint unsigned COMMENT ' foreign key to cluster' ,
613- ` public_ip_address` varchar ( 15 ),
613+ ` public_ip_address` char ( 40 ),
614614 ` public_netmask` varchar (15 ),
615615 ` public_mac_address` varchar (17 ),
616616 ` proxy_port` int (10 ) unsigned,
@@ -667,7 +667,7 @@ CREATE TABLE `cloud`.`mshost` (
667667 ` msid` bigint unsigned NOT NULL UNIQUE COMMENT ' management server id derived from MAC address' ,
668668 ` name` varchar (255 ),
669669 ` version` varchar (255 ),
670- ` service_ip` varchar ( 15 ) NOT NULL ,
670+ ` service_ip` char ( 40 ) NOT NULL ,
671671 ` service_port` integer NOT NULL ,
672672 ` last_update` DATETIME NULL COMMENT ' Last record update time' ,
673673 ` removed` datetime COMMENT ' date removed if not null' ,
@@ -746,7 +746,7 @@ CREATE TABLE `cloud`.`user_statistics` (
746746 ` id` bigint unsigned UNIQUE NOT NULL AUTO_INCREMENT,
747747 ` data_center_id` bigint unsigned NOT NULL ,
748748 ` account_id` bigint unsigned NOT NULL ,
749- ` public_ip_address` varchar ( 15 ),
749+ ` public_ip_address` char ( 40 ),
750750 ` device_id` bigint unsigned NOT NULL ,
751751 ` device_type` varchar (32 ) NOT NULL ,
752752 ` network_id` bigint unsigned,
@@ -792,7 +792,7 @@ CREATE TABLE `cloud`.`vm_instance` (
792792 ` vm_template_id` bigint unsigned,
793793 ` guest_os_id` bigint unsigned NOT NULL ,
794794 ` private_mac_address` varchar (17 ),
795- ` private_ip_address` varchar ( 15 ),
795+ ` private_ip_address` char ( 40 ),
796796 ` private_netmask` varchar (15 ),
797797 ` pod_id` bigint unsigned,
798798 ` data_center_id` bigint unsigned NOT NULL COMMENT ' Data Center the instance belongs to' ,
@@ -834,7 +834,7 @@ CREATE TABLE `cloud`.`user_vm` (
834834 ` id` bigint unsigned UNIQUE NOT NULL ,
835835 ` iso_id` bigint unsigned,
836836 ` display_name` varchar (255 ),
837- ` guest_ip_address` varchar ( 15 ) COMMENT ' ip address within the guest network' ,
837+ ` guest_ip_address` char ( 40 ) COMMENT ' ip address within the guest network' ,
838838 ` guest_mac_address` varchar (17 ) COMMENT ' mac address within the guest network' ,
839839 ` guest_netmask` varchar (15 ) COMMENT ' netmask within the guest network' ,
840840 ` user_data` varchar (2048 ),
@@ -855,10 +855,10 @@ CREATE TABLE `cloud`.`user_vm_details` (
855855CREATE TABLE `cloud `.` domain_router` (
856856 ` id` bigint unsigned UNIQUE NOT NULL COMMENT ' Primary Key' ,
857857 ` public_mac_address` varchar (17 ) COMMENT ' mac address of the public facing network card' ,
858- ` public_ip_address` varchar ( 15 ) COMMENT ' public ip address used for source net' ,
858+ ` public_ip_address` char ( 40 ) COMMENT ' public ip address used for source net' ,
859859 ` public_netmask` varchar (15 ) COMMENT ' netmask used for the domR' ,
860860 ` guest_netmask` varchar (15 ) COMMENT ' netmask used for the guest network' ,
861- ` guest_ip_address` varchar ( 15 ) COMMENT ' ip address in the guest network' ,
861+ ` guest_ip_address` char ( 40 ) COMMENT ' ip address in the guest network' ,
862862 ` network_id` bigint unsigned NOT NULL DEFAULT 0 COMMENT ' network configuration that this domain router belongs to' ,
863863 ` role` varchar (64 ) NOT NULL COMMENT ' type of role played by this router' ,
864864 PRIMARY KEY (` id` ),
@@ -924,7 +924,7 @@ CREATE TABLE `cloud`.`template_zone_ref` (
924924CREATE TABLE `cloud `.` console_proxy` (
925925 ` id` bigint unsigned NOT NULL auto_increment,
926926 ` public_mac_address` varchar (17 ) unique COMMENT ' mac address of the public facing network card' ,
927- ` public_ip_address` varchar ( 15 ) UNIQUE COMMENT ' public ip address for the console proxy' ,
927+ ` public_ip_address` char ( 40 ) UNIQUE COMMENT ' public ip address for the console proxy' ,
928928 ` public_netmask` varchar (15 ) COMMENT ' public netmask used for the console proxy' ,
929929 ` active_session` int (10 ) NOT NULL DEFAULT 0 COMMENT ' active session number' ,
930930 ` last_update` DATETIME NULL COMMENT ' Last session update time' ,
@@ -936,7 +936,7 @@ CREATE TABLE `cloud`.`console_proxy` (
936936CREATE TABLE `cloud `.` secondary_storage_vm` (
937937 ` id` bigint unsigned NOT NULL auto_increment,
938938 ` public_mac_address` varchar (17 ) unique COMMENT ' mac address of the public facing network card' ,
939- ` public_ip_address` varchar ( 15 ) UNIQUE COMMENT ' public ip address for the sec storage vm' ,
939+ ` public_ip_address` char ( 40 ) UNIQUE COMMENT ' public ip address for the sec storage vm' ,
940940 ` public_netmask` varchar (15 ) COMMENT ' public netmask used for the sec storage vm' ,
941941 ` guid` varchar (255 ) COMMENT ' copied from guid of secondary storage host' ,
942942 ` nfs_share` varchar (255 ) COMMENT ' server and path exported by the nfs server ' ,
@@ -1128,7 +1128,7 @@ CREATE TABLE `cloud`.`load_balancer` (
11281128 ` name` varchar (255 ) NOT NULL ,
11291129 ` description` varchar (4096 ) NULL ,
11301130 ` account_id` bigint unsigned NOT NULL ,
1131- ` ip_address` varchar ( 15 ) NOT NULL ,
1131+ ` ip_address` char ( 40 ) NOT NULL ,
11321132 ` public_port` varchar (10 ) NOT NULL ,
11331133 ` private_port` varchar (10 ) NOT NULL ,
11341134 ` algorithm` varchar (255 ) NOT NULL ,
@@ -1140,7 +1140,7 @@ CREATE TABLE `cloud`.`remote_access_vpn` (
11401140 ` account_id` bigint unsigned NOT NULL ,
11411141 ` network_id` bigint unsigned NOT NULL ,
11421142 ` domain_id` bigint unsigned NOT NULL ,
1143- ` local_ip` varchar ( 15 ) NOT NULL ,
1143+ ` local_ip` char ( 40 ) NOT NULL ,
11441144 ` ip_range` varchar (32 ) NOT NULL ,
11451145 ` ipsec_psk` varchar (256 ) NOT NULL ,
11461146 ` state` char (32 ) NOT NULL ,
@@ -1176,7 +1176,7 @@ CREATE TABLE `cloud`.`storage_pool` (
11761176 ` cluster_id` bigint unsigned COMMENT ' foreign key to cluster' ,
11771177 ` available_bytes` bigint unsigned,
11781178 ` capacity_bytes` bigint unsigned,
1179- ` host_address` varchar ( 255 ) NOT NULL COMMENT ' FQDN or IP of storage server' ,
1179+ ` host_address` char ( 40 ) NOT NULL COMMENT ' FQDN or IP of storage server' ,
11801180 ` path` varchar (255 ) NOT NULL COMMENT ' Filesystem path that is shared' ,
11811181 ` created` datetime COMMENT ' date the pool created' ,
11821182 ` removed` datetime COMMENT ' date removed if not null' ,
0 commit comments