diff --git a/.gitignore b/.gitignore index f41862895ec..016554a5f75 100644 --- a/.gitignore +++ b/.gitignore @@ -18,10 +18,7 @@ build/replace.properties build/build.number bin/ -cloudstack-proprietary/ -premium/ .lock-wscript -artifacts/ .waf-* waf-* target/ @@ -37,7 +34,7 @@ cloud-*.tar.bz2 *.egg-info/ *.prefs build.number -api.log.*.gz +*.log.*.gz cloud.log.*.* unittest deps/cloud.userlibraries @@ -59,6 +56,7 @@ tools/cli/build/ *.iso *.tar.gz *.tgz +.* target-eclipse awsapi/modules/* !.gitignore diff --git a/core/src/com/cloud/vm/VirtualDisk.java b/api/src/com/cloud/agent/api/storage/CreateVolumeOVAAnswer.java old mode 100644 new mode 100755 similarity index 73% rename from core/src/com/cloud/vm/VirtualDisk.java rename to api/src/com/cloud/agent/api/storage/CreateVolumeOVAAnswer.java index ad7bb43d40b..52a57dba7b2 --- a/core/src/com/cloud/vm/VirtualDisk.java +++ b/api/src/com/cloud/agent/api/storage/CreateVolumeOVAAnswer.java @@ -1,31 +1,26 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.vm; - -import com.cloud.storage.Storage; - -/** - * VirtualDisk describes the disks that are plugged into - * the virtual machine. - * - */ -public class VirtualDisk { - public Storage.ImageFormat format; - public String url; - public boolean bootable; - public long size; -} +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.agent.api.storage; + +import com.cloud.agent.api.Answer; + +public class CreateVolumeOVAAnswer extends Answer { + public CreateVolumeOVAAnswer(CreateVolumeOVACommand cmd, boolean result, String details) { + super(cmd, result, details); + } + +} diff --git a/api/src/com/cloud/agent/api/storage/CreateVolumeOVACommand.java b/api/src/com/cloud/agent/api/storage/CreateVolumeOVACommand.java new file mode 100755 index 00000000000..224b7c80d43 --- /dev/null +++ b/api/src/com/cloud/agent/api/storage/CreateVolumeOVACommand.java @@ -0,0 +1,60 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.agent.api.storage; + +import com.cloud.agent.api.Command; +import com.cloud.agent.api.to.StorageFilerTO; +import com.cloud.storage.StoragePool; + +public class CreateVolumeOVACommand extends Command { + String secUrl; + String volPath; + String volName; + StorageFilerTO pool; + + public CreateVolumeOVACommand() { + } + + public CreateVolumeOVACommand(String secUrl, String volPath, String volName, StoragePool pool, int wait) { + this.secUrl = secUrl; + this.volPath = volPath; + this.volName = volName; + this.pool = new StorageFilerTO(pool); + setWait(wait); + } + + @Override + public boolean executeInSequence() { + return true; + } + + public String getVolPath() { + return this.volPath; + } + + public String getVolName() { + return this.volName; + } + public String getSecondaryStorageUrl() { + return this.secUrl; + } + public StorageFilerTO getPool() { + return pool; + } +} + + diff --git a/server/src/com/cloud/maint/UpgradeManagerMBean.java b/api/src/com/cloud/agent/api/storage/PrepareOVAPackingAnswer.java old mode 100644 new mode 100755 similarity index 73% rename from server/src/com/cloud/maint/UpgradeManagerMBean.java rename to api/src/com/cloud/agent/api/storage/PrepareOVAPackingAnswer.java index 1c7cb310b18..923d952a137 --- a/server/src/com/cloud/maint/UpgradeManagerMBean.java +++ b/api/src/com/cloud/agent/api/storage/PrepareOVAPackingAnswer.java @@ -1,23 +1,26 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.maint; - -import com.cloud.utils.mgmt.ManagementBean; - -public interface UpgradeManagerMBean extends ManagementBean { - public String deployNewAgent(String location); -} +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.agent.api.storage; + +import com.cloud.agent.api.Answer; + +public class PrepareOVAPackingAnswer extends Answer { + public PrepareOVAPackingAnswer(PrepareOVAPackingCommand cmd, boolean result, String details) { + super(cmd, result, details); + } + +} diff --git a/core/src/com/cloud/storage/snapshot/SnapshotSchedule.java b/api/src/com/cloud/agent/api/storage/PrepareOVAPackingCommand.java old mode 100644 new mode 100755 similarity index 51% rename from core/src/com/cloud/storage/snapshot/SnapshotSchedule.java rename to api/src/com/cloud/agent/api/storage/PrepareOVAPackingCommand.java index 6f3d2ce5468..29fa26d0bd0 --- a/core/src/com/cloud/storage/snapshot/SnapshotSchedule.java +++ b/api/src/com/cloud/agent/api/storage/PrepareOVAPackingCommand.java @@ -1,46 +1,48 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.storage.snapshot; - -import org.apache.cloudstack.api.Identity; -import org.apache.cloudstack.api.InternalIdentity; - -import java.util.Date; - -public interface SnapshotSchedule extends InternalIdentity, Identity { - - Long getVolumeId(); - - Long getPolicyId(); - - void setPolicyId(long policyId); - - /** - * @return the scheduledTimestamp - */ - Date getScheduledTimestamp(); - - void setScheduledTimestamp(Date scheduledTimestamp); - - Long getAsyncJobId(); - - void setAsyncJobId(Long asyncJobId); - - Long getSnapshotId(); - - void setSnapshotId(Long snapshotId); -} +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.agent.api.storage; + +import com.cloud.agent.api.Command; + +public class PrepareOVAPackingCommand extends Command { + private String templatePath; + private String secUrl; + + public PrepareOVAPackingCommand() { + } + + public PrepareOVAPackingCommand(String secUrl, String templatePath) { + this.secUrl = secUrl; + this.templatePath = templatePath; + } + + @Override + public boolean executeInSequence() { + return true; + } + + public String getTemplatePath() { + return this.templatePath; + } + + public String getSecondaryStorageUrl() { + return this.secUrl; + } + +} + + \ No newline at end of file diff --git a/core/src/com/cloud/alert/AlertAdapter.java b/api/src/com/cloud/alert/AlertAdapter.java similarity index 100% rename from core/src/com/cloud/alert/AlertAdapter.java rename to api/src/com/cloud/alert/AlertAdapter.java diff --git a/api/src/com/cloud/async/AsyncJob.java b/api/src/com/cloud/async/AsyncJob.java index 830e901a283..47f9b574e23 100644 --- a/api/src/com/cloud/async/AsyncJob.java +++ b/api/src/com/cloud/async/AsyncJob.java @@ -51,7 +51,10 @@ public interface AsyncJob extends Identity, InternalIdentity { AutoScaleVmProfile, AutoScaleVmGroup, GlobalLoadBalancerRule, - AffinityGroup + LoadBalancerRule, + AffinityGroup, + InternalLbVm, + DedicatedGuestVlanRange } long getUserId(); diff --git a/api/src/com/cloud/configuration/ConfigurationService.java b/api/src/com/cloud/configuration/ConfigurationService.java index 19b0a42d97f..381fcad95cc 100644 --- a/api/src/com/cloud/configuration/ConfigurationService.java +++ b/api/src/com/cloud/configuration/ConfigurationService.java @@ -20,6 +20,11 @@ import java.util.List; import javax.naming.NamingException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.exception.ResourceAllocationException; import org.apache.cloudstack.api.command.admin.config.UpdateCfgCmd; import org.apache.cloudstack.api.command.admin.ldap.LDAPConfigCmd; import org.apache.cloudstack.api.command.admin.ldap.LDAPRemoveCmd; @@ -49,10 +54,6 @@ import org.apache.cloudstack.api.command.user.network.ListNetworkOfferingsCmd; import com.cloud.dc.DataCenter; import com.cloud.dc.Pod; import com.cloud.dc.Vlan; -import com.cloud.exception.ConcurrentOperationException; -import com.cloud.exception.InsufficientCapacityException; -import com.cloud.exception.ResourceAllocationException; -import com.cloud.exception.ResourceUnavailableException; import com.cloud.network.Networks.TrafficType; import com.cloud.offering.DiskOffering; import com.cloud.offering.NetworkOffering; @@ -70,7 +71,7 @@ public interface ConfigurationService { * - the command wrapping name and value parameters * @return updated configuration object if successful */ - Configuration updateConfiguration(UpdateCfgCmd cmd); + Configuration updateConfiguration(UpdateCfgCmd cmd) throws InvalidParameterValueException; /** * Create a service offering through the API @@ -255,7 +256,7 @@ public interface ConfigurationService { NetworkOffering getNetworkOffering(long id); - Integer getNetworkOfferingNetworkRate(long networkOfferingId); + Integer getNetworkOfferingNetworkRate(long networkOfferingId, Long dataCenterId); Account getVlanAccount(long vlanId); @@ -267,7 +268,7 @@ public interface ConfigurationService { Long getDefaultPageSize(); - Integer getServiceOfferingNetworkRate(long serviceOfferingId); + Integer getServiceOfferingNetworkRate(long serviceOfferingId, Long dataCenterId); DiskOffering getDiskOffering(long diskOfferingId); diff --git a/api/src/com/cloud/event/EventTypes.java b/api/src/com/cloud/event/EventTypes.java index e2886a3ea6c..903454153f3 100755 --- a/api/src/com/cloud/event/EventTypes.java +++ b/api/src/com/cloud/event/EventTypes.java @@ -16,6 +16,9 @@ // under the License. package com.cloud.event; +import java.util.HashMap; +import java.util.Map; + import com.cloud.configuration.Configuration; import com.cloud.dc.DataCenter; import com.cloud.dc.Pod; @@ -23,8 +26,18 @@ import com.cloud.dc.StorageNetworkIpRange; import com.cloud.dc.Vlan; import com.cloud.domain.Domain; import com.cloud.host.Host; -import com.cloud.network.*; -import com.cloud.network.as.*; +import com.cloud.network.GuestVlan; +import com.cloud.network.Network; +import com.cloud.network.PhysicalNetwork; +import com.cloud.network.PhysicalNetworkServiceProvider; +import com.cloud.network.PhysicalNetworkTrafficType; +import com.cloud.network.PublicIpAddress; +import com.cloud.network.RemoteAccessVpn; +import com.cloud.network.as.AutoScaleCounter; +import com.cloud.network.as.AutoScalePolicy; +import com.cloud.network.as.AutoScaleVmGroup; +import com.cloud.network.as.AutoScaleVmProfile; +import com.cloud.network.as.Condition; import com.cloud.network.router.VirtualRouter; import com.cloud.network.rules.LoadBalancer; import com.cloud.network.rules.StaticNat; @@ -43,9 +56,6 @@ import com.cloud.user.Account; import com.cloud.user.User; import com.cloud.vm.VirtualMachine; -import java.util.HashMap; -import java.util.Map; - public class EventTypes { //map of Event and corresponding entity for which Event is applicable @@ -391,6 +401,14 @@ public class EventTypes { public static final String EVENT_AFFINITY_GROUP_ASSIGN = "AG.ASSIGN"; public static final String EVENT_AFFINITY_GROUP_REMOVE = "AG.REMOVE"; public static final String EVENT_VM_AFFINITY_GROUP_UPDATE = "VM.AG.UPDATE"; + + public static final String EVENT_INTERNAL_LB_VM_START = "INTERNALLBVM.START"; + public static final String EVENT_INTERNAL_LB_VM_STOP = "INTERNALLBVM.STOP"; + + // Dedicated guest vlan range + public static final String EVENT_GUEST_VLAN_RANGE_DEDICATE = "GUESTVLANRANGE.DEDICATE"; + public static final String EVENT_DEDICATED_GUEST_VLAN_RANGE_RELEASE = "GUESTVLANRANGE.RELEASE"; + public static final String EVENT_PORTABLE_IP_RANGE_CREATE = "PORTABLE.IP.RANGE.CREATE"; public static final String EVENT_PORTABLE_IP_RANGE_DELETE = "PORTABLE.IP.RANGE.DELETE"; @@ -695,6 +713,9 @@ public class EventTypes { entityEventDetails.put(EVENT_AUTOSCALEVMGROUP_UPDATE, AutoScaleVmGroup.class.getName()); entityEventDetails.put(EVENT_AUTOSCALEVMGROUP_ENABLE, AutoScaleVmGroup.class.getName()); entityEventDetails.put(EVENT_AUTOSCALEVMGROUP_DISABLE, AutoScaleVmGroup.class.getName()); + + entityEventDetails.put(EVENT_GUEST_VLAN_RANGE_DEDICATE, GuestVlan.class.getName()); + entityEventDetails.put(EVENT_DEDICATED_GUEST_VLAN_RANGE_RELEASE, GuestVlan.class.getName()); } public static String getEntityForEvent (String eventName) { diff --git a/core/src/com/cloud/event/UsageEvent.java b/api/src/com/cloud/event/UsageEvent.java similarity index 100% rename from core/src/com/cloud/event/UsageEvent.java rename to api/src/com/cloud/event/UsageEvent.java diff --git a/core/src/com/cloud/exception/AgentControlChannelException.java b/api/src/com/cloud/exception/AgentControlChannelException.java similarity index 100% rename from core/src/com/cloud/exception/AgentControlChannelException.java rename to api/src/com/cloud/exception/AgentControlChannelException.java diff --git a/core/src/com/cloud/info/ConsoleProxyLoadInfo.java b/api/src/com/cloud/info/ConsoleProxyLoadInfo.java similarity index 100% rename from core/src/com/cloud/info/ConsoleProxyLoadInfo.java rename to api/src/com/cloud/info/ConsoleProxyLoadInfo.java diff --git a/core/src/com/cloud/info/RunningHostCountInfo.java b/api/src/com/cloud/info/RunningHostCountInfo.java similarity index 100% rename from core/src/com/cloud/info/RunningHostCountInfo.java rename to api/src/com/cloud/info/RunningHostCountInfo.java diff --git a/api/src/com/cloud/network/GuestVlan.java b/api/src/com/cloud/network/GuestVlan.java new file mode 100644 index 00000000000..a5173d87830 --- /dev/null +++ b/api/src/com/cloud/network/GuestVlan.java @@ -0,0 +1,31 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.network; + +import org.apache.cloudstack.api.Identity; +import org.apache.cloudstack.api.InternalIdentity; + +public interface GuestVlan extends InternalIdentity, Identity { + + public long getId(); + + public long getAccountId(); + + public String getGuestVlanRange(); + + public long getPhysicalNetworkId(); +} diff --git a/api/src/com/cloud/network/IpAddress.java b/api/src/com/cloud/network/IpAddress.java index 835fa548236..de11a6de79b 100644 --- a/api/src/com/cloud/network/IpAddress.java +++ b/api/src/com/cloud/network/IpAddress.java @@ -83,4 +83,7 @@ public interface IpAddress extends ControlledEntity, Identity, InternalIdentity String getVmIp(); boolean isPortable(); + + Long getNetworkId(); + } diff --git a/api/src/com/cloud/network/Network.java b/api/src/com/cloud/network/Network.java index 4472dbacc53..fa062c6a694 100644 --- a/api/src/com/cloud/network/Network.java +++ b/api/src/com/cloud/network/Network.java @@ -16,18 +16,19 @@ // under the License. package com.cloud.network; +import java.net.URI; +import java.util.ArrayList; +import java.util.List; + +import org.apache.cloudstack.acl.ControlledEntity; +import org.apache.cloudstack.api.Identity; +import org.apache.cloudstack.api.InternalIdentity; + import com.cloud.network.Networks.BroadcastDomainType; import com.cloud.network.Networks.Mode; import com.cloud.network.Networks.TrafficType; import com.cloud.utils.fsm.StateMachine2; import com.cloud.utils.fsm.StateObject; -import org.apache.cloudstack.acl.ControlledEntity; -import org.apache.cloudstack.api.Identity; -import org.apache.cloudstack.api.InternalIdentity; - -import java.net.URI; -import java.util.ArrayList; -import java.util.List; /** * owned by an account. @@ -50,7 +51,7 @@ public interface Network extends ControlledEntity, StateObject, I Capability.MultipleIps, Capability.TrafficStatistics, Capability.SupportedTrafficDirection, Capability.SupportedEgressProtocols); public static final Service Lb = new Service("Lb", Capability.SupportedLBAlgorithms, Capability.SupportedLBIsolation, Capability.SupportedProtocols, Capability.TrafficStatistics, Capability.LoadBalancingSupportedIps, - Capability.SupportedStickinessMethods, Capability.ElasticLb); + Capability.SupportedStickinessMethods, Capability.ElasticLb, Capability.LbSchemes); public static final Service UserData = new Service("UserData"); public static final Service SourceNat = new Service("SourceNat", Capability.SupportedSourceNatTypes, Capability.RedundantRouter); public static final Service StaticNat = new Service("StaticNat", Capability.ElasticIp); @@ -124,6 +125,7 @@ public interface Network extends ControlledEntity, StateObject, I public static final Provider None = new Provider("None", false); // NiciraNvp is not an "External" provider, otherwise we get in trouble with NetworkServiceImpl.providersConfiguredForExternalNetworking public static final Provider NiciraNvp = new Provider("NiciraNvp", false); + public static final Provider InternalLbVm = new Provider("InternalLbVm", false); public static final Provider CiscoVnmc = new Provider("CiscoVnmc", true); private String name; @@ -177,6 +179,7 @@ public interface Network extends ControlledEntity, StateObject, I public static final Capability SupportedTrafficDirection = new Capability("SupportedTrafficDirection"); public static final Capability SupportedEgressProtocols = new Capability("SupportedEgressProtocols"); public static final Capability HealthCheckPolicy = new Capability("HealthCheckPolicy"); + public static final Capability LbSchemes = new Capability("LbSchemes"); private String name; diff --git a/api/src/com/cloud/network/NetworkModel.java b/api/src/com/cloud/network/NetworkModel.java index 4d7d714a7ae..f84a8b0c76a 100644 --- a/api/src/com/cloud/network/NetworkModel.java +++ b/api/src/com/cloud/network/NetworkModel.java @@ -33,6 +33,7 @@ import com.cloud.network.Networks.TrafficType; import com.cloud.network.element.NetworkElement; import com.cloud.network.element.UserDataServiceProvider; import com.cloud.offering.NetworkOffering; +import com.cloud.offering.NetworkOffering.Detail; import com.cloud.user.Account; import com.cloud.vm.Nic; import com.cloud.vm.NicProfile; @@ -181,7 +182,7 @@ public interface NetworkModel { /** * @return */ - String getDefaultNetworkDomain(); + String getDefaultNetworkDomain(long zoneId); /** * @param ntwkOffId @@ -263,4 +264,12 @@ public interface NetworkModel { boolean isProviderEnabledInZone(long zoneId, String provider); Nic getPlaceholderNicForRouter(Network network, Long podId); + + IpAddress getPublicIpAddress(String ipAddress, long zoneId); + + List getUsedIpsInNetwork(Network network); + + Map getNtwkOffDetails(long offId); + + Networks.IsolationType[] listNetworkIsolationMethods(); } \ No newline at end of file diff --git a/api/src/com/cloud/network/NetworkService.java b/api/src/com/cloud/network/NetworkService.java index 0e9a5a76485..4785b9c6feb 100755 --- a/api/src/com/cloud/network/NetworkService.java +++ b/api/src/com/cloud/network/NetworkService.java @@ -18,6 +18,8 @@ package com.cloud.network; import java.util.List; +import org.apache.cloudstack.api.command.admin.network.DedicateGuestVlanRangeCmd; +import org.apache.cloudstack.api.command.admin.network.ListDedicatedGuestVlanRangesCmd; import org.apache.cloudstack.api.command.admin.usage.ListTrafficTypeImplementorsCmd; import org.apache.cloudstack.api.command.user.network.RestartNetworkCmd; import org.apache.cloudstack.api.command.user.network.CreateNetworkCmd; @@ -29,6 +31,7 @@ import com.cloud.exception.InsufficientAddressCapacityException; import com.cloud.exception.InsufficientCapacityException; import com.cloud.exception.ResourceAllocationException; import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.GuestVlan; import com.cloud.network.Network.Service; import com.cloud.network.Networks.TrafficType; import com.cloud.user.Account; @@ -117,6 +120,12 @@ public interface NetworkService { boolean deletePhysicalNetworkTrafficType(Long id); + GuestVlan dedicateGuestVlanRange(DedicateGuestVlanRangeCmd cmd); + + Pair, Integer> listDedicatedGuestVlanRanges(ListDedicatedGuestVlanRangesCmd cmd); + + boolean releaseDedicatedGuestVlanRange(Long dedicatedGuestVlanRangeId); + Pair, Integer> listTrafficTypes(Long physicalNetworkId); @@ -141,6 +150,7 @@ public interface NetworkService { ResourceAllocationException, ResourceUnavailableException, ConcurrentOperationException; /** + * * @param networkName * @param displayText * @param physicalNetworkId @@ -151,13 +161,14 @@ public interface NetworkService { * @param netmask * @param networkOwnerId * @param vpcId TODO + * @param sourceNat * @return * @throws InsufficientCapacityException * @throws ConcurrentOperationException * @throws ResourceAllocationException */ Network createPrivateNetwork(String networkName, String displayText, long physicalNetworkId, String vlan, - String startIp, String endIP, String gateway, String netmask, long networkOwnerId, Long vpcId) + String startIp, String endIP, String gateway, String netmask, long networkOwnerId, Long vpcId, Boolean sourceNat) throws ResourceAllocationException, ConcurrentOperationException, InsufficientCapacityException; /* Requests an IP address for the guest nic */ diff --git a/server/src/com/cloud/network/UserIpv6Address.java b/api/src/com/cloud/network/UserIpv6Address.java similarity index 100% rename from server/src/com/cloud/network/UserIpv6Address.java rename to api/src/com/cloud/network/UserIpv6Address.java diff --git a/api/src/com/cloud/network/VirtualNetworkApplianceService.java b/api/src/com/cloud/network/VirtualNetworkApplianceService.java index 250ecb24e91..58eead2af07 100644 --- a/api/src/com/cloud/network/VirtualNetworkApplianceService.java +++ b/api/src/com/cloud/network/VirtualNetworkApplianceService.java @@ -63,5 +63,7 @@ public interface VirtualNetworkApplianceService { VirtualRouter startRouter(long id) throws ResourceUnavailableException, InsufficientCapacityException, ConcurrentOperationException; VirtualRouter destroyRouter(long routerId, Account caller, Long callerUserId) throws ResourceUnavailableException, ConcurrentOperationException; + + VirtualRouter findRouter(long routerId); } diff --git a/api/src/com/cloud/network/VirtualRouterProvider.java b/api/src/com/cloud/network/VirtualRouterProvider.java index ed6a2741ba0..f67686e6b08 100644 --- a/api/src/com/cloud/network/VirtualRouterProvider.java +++ b/api/src/com/cloud/network/VirtualRouterProvider.java @@ -23,7 +23,8 @@ public interface VirtualRouterProvider extends InternalIdentity, Identity { public enum VirtualRouterProviderType { VirtualRouter, ElasticLoadBalancerVm, - VPCVirtualRouter + VPCVirtualRouter, + InternalLbVm } public VirtualRouterProviderType getType(); diff --git a/api/src/com/cloud/network/lb/LoadBalancingRule.java b/api/src/com/cloud/network/lb/LoadBalancingRule.java index 3e11e8c7c2c..4b37782a8c7 100644 --- a/api/src/com/cloud/network/lb/LoadBalancingRule.java +++ b/api/src/com/cloud/network/lb/LoadBalancingRule.java @@ -25,111 +25,83 @@ import com.cloud.network.as.Condition; import com.cloud.network.as.Counter; import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.LoadBalancer; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.utils.Pair; +import com.cloud.utils.net.Ip; -public class LoadBalancingRule implements FirewallRule, LoadBalancer { +public class LoadBalancingRule { private LoadBalancer lb; + private Ip sourceIp; private List destinations; private List stickinessPolicies; private LbAutoScaleVmGroup autoScaleVmGroup; private List healthCheckPolicies; public LoadBalancingRule(LoadBalancer lb, List destinations, - List stickinessPolicies, List healthCheckPolicies) { + List stickinessPolicies, List healthCheckPolicies, Ip sourceIp) { this.lb = lb; this.destinations = destinations; this.stickinessPolicies = stickinessPolicies; this.healthCheckPolicies = healthCheckPolicies; + this.sourceIp = sourceIp; } - @Override public long getId() { return lb.getId(); } - @Override - public long getAccountId() { - return lb.getAccountId(); - } - - @Override - public long getDomainId() { - return lb.getDomainId(); - } - - @Override public String getName() { return lb.getName(); } - @Override public String getDescription() { return lb.getDescription(); } - @Override public int getDefaultPortStart() { return lb.getDefaultPortStart(); } - @Override public int getDefaultPortEnd() { return lb.getDefaultPortEnd(); } - @Override public String getAlgorithm() { return lb.getAlgorithm(); } - @Override public String getUuid() { return lb.getUuid(); } - @Override public String getXid() { return lb.getXid(); } - @Override - public Long getSourceIpAddressId() { - return lb.getSourceIpAddressId(); - } - - @Override public Integer getSourcePortStart() { return lb.getSourcePortStart(); } - @Override public Integer getSourcePortEnd() { return lb.getSourcePortEnd(); } - @Override public String getProtocol() { return lb.getProtocol(); } - @Override - public Purpose getPurpose() { - return Purpose.LoadBalancing; + public FirewallRule.Purpose getPurpose() { + return FirewallRule.Purpose.LoadBalancing; } - @Override - public State getState() { + public FirewallRule.State getState() { return lb.getState(); } - @Override public long getNetworkId() { return lb.getNetworkId(); } - public LoadBalancer getLb() { - return lb; - } public void setDestinations(List destinations) { this.destinations = destinations; @@ -287,36 +259,6 @@ public class LoadBalancingRule implements FirewallRule, LoadBalancer { } } - @Override - public Integer getIcmpCode() { - return null; - } - - @Override - public Integer getIcmpType() { - return null; - } - - @Override - public List getSourceCidrList() { - return null; - } - - @Override - public Long getRelated() { - return null; - } - - @Override - public TrafficType getTrafficType() { - return null; - } - - @Override - public FirewallRuleType getType() { - return FirewallRuleType.User; - } - public LbAutoScaleVmGroup getAutoScaleVmGroup() { return autoScaleVmGroup; } @@ -473,4 +415,11 @@ public class LoadBalancingRule implements FirewallRule, LoadBalancer { } } + public Ip getSourceIp() { + return sourceIp; + } + + public Scheme getScheme() { + return lb.getScheme(); + } } diff --git a/api/src/com/cloud/network/lb/LoadBalancingRulesService.java b/api/src/com/cloud/network/lb/LoadBalancingRulesService.java index ed39bedaa6f..5fc41e34c34 100644 --- a/api/src/com/cloud/network/lb/LoadBalancingRulesService.java +++ b/api/src/com/cloud/network/lb/LoadBalancingRulesService.java @@ -17,10 +17,10 @@ package com.cloud.network.lb; import java.util.List; +import java.util.Map; import org.apache.cloudstack.api.command.user.loadbalancer.CreateLBHealthCheckPolicyCmd; import org.apache.cloudstack.api.command.user.loadbalancer.CreateLBStickinessPolicyCmd; -import org.apache.cloudstack.api.command.user.loadbalancer.CreateLoadBalancerRuleCmd; import org.apache.cloudstack.api.command.user.loadbalancer.ListLBHealthCheckPoliciesCmd; import org.apache.cloudstack.api.command.user.loadbalancer.ListLBStickinessPoliciesCmd; import org.apache.cloudstack.api.command.user.loadbalancer.ListLoadBalancerRuleInstancesCmd; @@ -30,12 +30,13 @@ import org.apache.cloudstack.api.command.user.loadbalancer.UpdateLoadBalancerRul import com.cloud.exception.InsufficientAddressCapacityException; import com.cloud.exception.NetworkRuleConflictException; import com.cloud.exception.ResourceUnavailableException; -import com.cloud.network.lb.LoadBalancingRule.LbStickinessPolicy; import com.cloud.network.rules.HealthCheckPolicy; import com.cloud.network.rules.LoadBalancer; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.network.rules.StickinessPolicy; import com.cloud.uservm.UserVm; import com.cloud.utils.Pair; +import com.cloud.utils.net.Ip; public interface LoadBalancingRulesService { @@ -49,7 +50,9 @@ public interface LoadBalancingRulesService { * @return the newly created LoadBalancerVO if successful, null otherwise * @throws InsufficientAddressCapacityException */ - LoadBalancer createLoadBalancerRule(CreateLoadBalancerRuleCmd lb, boolean openFirewall) throws NetworkRuleConflictException, InsufficientAddressCapacityException; + LoadBalancer createPublicLoadBalancerRule(String xId, String name, String description, + int srcPortStart, int srcPortEnd, int defPortStart, int defPortEnd, Long ipAddrId, String protocol, String algorithm, + long networkId, long lbOwnerId, boolean openFirewall) throws NetworkRuleConflictException, InsufficientAddressCapacityException; LoadBalancer updateLoadBalancerRule(UpdateLoadBalancerRuleCmd cmd); @@ -134,8 +137,9 @@ public interface LoadBalancingRulesService { List searchForLBHealthCheckPolicies(ListLBHealthCheckPoliciesCmd cmd); - List listByNetworkId(long networkId); - LoadBalancer findById(long LoadBalancer); - public void updateLBHealthChecks() throws ResourceUnavailableException; + + public void updateLBHealthChecks(Scheme scheme) throws ResourceUnavailableException; + + Map getLbInstances(long lbId); } diff --git a/api/src/com/cloud/network/router/VirtualRouter.java b/api/src/com/cloud/network/router/VirtualRouter.java index d7239dd3452..2311f489918 100755 --- a/api/src/com/cloud/network/router/VirtualRouter.java +++ b/api/src/com/cloud/network/router/VirtualRouter.java @@ -23,7 +23,7 @@ import com.cloud.vm.VirtualMachine; */ public interface VirtualRouter extends VirtualMachine { public enum Role { - VIRTUAL_ROUTER, LB + VIRTUAL_ROUTER, LB, INTERNAL_LB_VM } Role getRole(); boolean getIsRedundantRouter(); diff --git a/api/src/com/cloud/network/rules/LoadBalancer.java b/api/src/com/cloud/network/rules/LoadBalancer.java index ab6085aceb7..e6dadcaee97 100644 --- a/api/src/com/cloud/network/rules/LoadBalancer.java +++ b/api/src/com/cloud/network/rules/LoadBalancer.java @@ -19,16 +19,10 @@ package com.cloud.network.rules; /** * Definition for a LoadBalancer */ -public interface LoadBalancer extends FirewallRule { - - String getName(); - - String getDescription(); - +public interface LoadBalancer extends FirewallRule, LoadBalancerContainer { + int getDefaultPortStart(); int getDefaultPortEnd(); - String getAlgorithm(); - } diff --git a/core/src/com/cloud/storage/SecondaryStorage.java b/api/src/com/cloud/network/rules/LoadBalancerContainer.java similarity index 77% rename from core/src/com/cloud/storage/SecondaryStorage.java rename to api/src/com/cloud/network/rules/LoadBalancerContainer.java index dc01642767f..9d5ea595c9d 100644 --- a/core/src/com/cloud/storage/SecondaryStorage.java +++ b/api/src/com/cloud/network/rules/LoadBalancerContainer.java @@ -14,17 +14,20 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -package com.cloud.storage; +package com.cloud.network.rules; -public interface SecondaryStorage { +public interface LoadBalancerContainer { - String getBackupPath(); - - String getTemplatePath(); - - String getIsoPath(); + public enum Scheme { + Public, Internal; + } - void createTemplate(); + String getName(); + + String getDescription(); - void destroyTemplate(); + String getAlgorithm(); + + Scheme getScheme(); + } diff --git a/api/src/com/cloud/network/rules/RulesService.java b/api/src/com/cloud/network/rules/RulesService.java index d47b38f9d43..45abd84a9ec 100644 --- a/api/src/com/cloud/network/rules/RulesService.java +++ b/api/src/com/cloud/network/rules/RulesService.java @@ -67,7 +67,7 @@ public interface RulesService { boolean applyPortForwardingRules(long ipAdddressId, Account caller) throws ResourceUnavailableException; - boolean enableStaticNat(long ipAddressId, long vmId, long networkId, boolean isSystemVm, String vmGuestIp) throws NetworkRuleConflictException, ResourceUnavailableException; + boolean enableStaticNat(long ipAddressId, long vmId, long networkId, String vmGuestIp) throws NetworkRuleConflictException, ResourceUnavailableException; PortForwardingRule getPortForwardigRule(long ruleId); diff --git a/api/src/com/cloud/network/security/SecurityGroupRules.java b/api/src/com/cloud/network/security/SecurityGroupRules.java index d255e46fde5..4dbafd62e98 100644 --- a/api/src/com/cloud/network/security/SecurityGroupRules.java +++ b/api/src/com/cloud/network/security/SecurityGroupRules.java @@ -31,6 +31,8 @@ public interface SecurityGroupRules extends InternalIdentity { Long getRuleId(); + String getRuleUuid(); + int getStartPort(); int getEndPort(); diff --git a/api/src/com/cloud/network/vpc/PrivateIp.java b/api/src/com/cloud/network/vpc/PrivateIp.java index 857fc226f30..eb6843339c5 100644 --- a/api/src/com/cloud/network/vpc/PrivateIp.java +++ b/api/src/com/cloud/network/vpc/PrivateIp.java @@ -44,5 +44,6 @@ public interface PrivateIp { String getMacAddress(); long getNetworkId(); + boolean getSourceNat(); } diff --git a/api/src/com/cloud/network/vpc/VpcGateway.java b/api/src/com/cloud/network/vpc/VpcGateway.java index 17566160ec3..e3530d08561 100644 --- a/api/src/com/cloud/network/vpc/VpcGateway.java +++ b/api/src/com/cloud/network/vpc/VpcGateway.java @@ -77,4 +77,8 @@ public interface VpcGateway extends Identity, ControlledEntity, InternalIdentity * @return */ State getState(); + /** + * @return + */ + boolean getSourceNat(); } diff --git a/api/src/com/cloud/network/vpc/VpcOffering.java b/api/src/com/cloud/network/vpc/VpcOffering.java index 3961d0aaba7..3ec81e693af 100644 --- a/api/src/com/cloud/network/vpc/VpcOffering.java +++ b/api/src/com/cloud/network/vpc/VpcOffering.java @@ -26,6 +26,7 @@ public interface VpcOffering extends InternalIdentity, Identity { } public static final String defaultVPCOfferingName = "Default VPC offering"; + public static final String defaultVPCNSOfferingName = "Default VPC offering with Netscaler"; /** * diff --git a/api/src/com/cloud/network/vpc/VpcService.java b/api/src/com/cloud/network/vpc/VpcService.java index 07ce89b0a3f..23e276489c2 100644 --- a/api/src/com/cloud/network/vpc/VpcService.java +++ b/api/src/com/cloud/network/vpc/VpcService.java @@ -163,6 +163,7 @@ public interface VpcService { /** * Persists VPC private gateway in the Database. * + * * @param vpcId TODO * @param physicalNetworkId * @param vlan @@ -170,13 +171,14 @@ public interface VpcService { * @param gateway * @param netmask * @param gatewayOwnerId + * @param isSourceNat * @return * @throws InsufficientCapacityException * @throws ConcurrentOperationException * @throws ResourceAllocationException */ public PrivateGateway createVpcPrivateGateway(long vpcId, Long physicalNetworkId, String vlan, String ipAddress, - String gateway, String netmask, long gatewayOwnerId) throws ResourceAllocationException, + String gateway, String netmask, long gatewayOwnerId, Boolean isSourceNat) throws ResourceAllocationException, ConcurrentOperationException, InsufficientCapacityException; /** diff --git a/api/src/com/cloud/offering/NetworkOffering.java b/api/src/com/cloud/offering/NetworkOffering.java index 6f0b9937854..72e2a2bbbab 100644 --- a/api/src/com/cloud/offering/NetworkOffering.java +++ b/api/src/com/cloud/offering/NetworkOffering.java @@ -16,6 +16,8 @@ // under the License. package com.cloud.offering; +import java.util.Map; + import org.apache.cloudstack.acl.InfrastructureEntity; import org.apache.cloudstack.api.Identity; import org.apache.cloudstack.api.InternalIdentity; @@ -38,6 +40,11 @@ public interface NetworkOffering extends InfrastructureEntity, InternalIdentity, Disabled, Enabled } + + public enum Detail { + InternalLbProvider, + PublicLbProvider + } public final static String SystemPublicNetwork = "System-Public-Network"; public final static String SystemControlNetwork = "System-Control-Network"; @@ -116,5 +123,9 @@ public interface NetworkOffering extends InfrastructureEntity, InternalIdentity, boolean isInline(); boolean getIsPersistent(); + + boolean getInternalLb(); + + boolean getPublicLb(); } diff --git a/api/src/com/cloud/offering/ServiceOffering.java b/api/src/com/cloud/offering/ServiceOffering.java index d6c215f42f0..165369c5e9b 100755 --- a/api/src/com/cloud/offering/ServiceOffering.java +++ b/api/src/com/cloud/offering/ServiceOffering.java @@ -30,6 +30,7 @@ public interface ServiceOffering extends InfrastructureEntity, InternalIdentity, public static final String ssvmDefaultOffUniqueName = "Cloud.com-SecondaryStorage"; public static final String routerDefaultOffUniqueName = "Cloud.Com-SoftwareRouter"; public static final String elbVmDefaultOffUniqueName = "Cloud.Com-ElasticLBVm"; + public static final String internalLbVmDefaultOffUniqueName = "Cloud.Com-InternalLBVm"; public enum StorageType { local, diff --git a/core/src/com/cloud/resource/UnableDeleteHostException.java b/api/src/com/cloud/resource/UnableDeleteHostException.java similarity index 100% rename from core/src/com/cloud/resource/UnableDeleteHostException.java rename to api/src/com/cloud/resource/UnableDeleteHostException.java diff --git a/core/src/com/cloud/storage/StoragePoolDiscoverer.java b/api/src/com/cloud/storage/StoragePoolDiscoverer.java similarity index 73% rename from core/src/com/cloud/storage/StoragePoolDiscoverer.java rename to api/src/com/cloud/storage/StoragePoolDiscoverer.java index c7dd362a5c3..40a925dc73e 100644 --- a/core/src/com/cloud/storage/StoragePoolDiscoverer.java +++ b/api/src/com/cloud/storage/StoragePoolDiscoverer.java @@ -19,8 +19,6 @@ package com.cloud.storage; import java.net.URI; import java.util.Map; -import org.apache.cloudstack.storage.datastore.db.StoragePoolVO; - import com.cloud.exception.DiscoveryException; import com.cloud.utils.component.Adapter; @@ -29,7 +27,7 @@ import com.cloud.utils.component.Adapter; */ public interface StoragePoolDiscoverer extends Adapter { - Map> find(long dcId, Long podId, URI uri, Map details) throws DiscoveryException; - - Map> find(long dcId, Long podId, URI uri, Map details, String username, String password) throws DiscoveryException; + Map> find(long dcId, Long podId, URI uri, Map details) throws DiscoveryException; + + Map> find(long dcId, Long podId, URI uri, Map details, String username, String password) throws DiscoveryException; } diff --git a/api/src/com/cloud/storage/snapshot/SnapshotSchedule.java b/api/src/com/cloud/storage/snapshot/SnapshotSchedule.java index 12c1445f0ad..6f3d2ce5468 100644 --- a/api/src/com/cloud/storage/snapshot/SnapshotSchedule.java +++ b/api/src/com/cloud/storage/snapshot/SnapshotSchedule.java @@ -16,12 +16,12 @@ // under the License. package com.cloud.storage.snapshot; +import org.apache.cloudstack.api.Identity; +import org.apache.cloudstack.api.InternalIdentity; + import java.util.Date; -public interface SnapshotSchedule { - long getId(); - - String getUuid(); +public interface SnapshotSchedule extends InternalIdentity, Identity { Long getVolumeId(); @@ -38,10 +38,9 @@ public interface SnapshotSchedule { Long getAsyncJobId(); - void setAsyncJobId(long asyncJobId); + void setAsyncJobId(Long asyncJobId); Long getSnapshotId(); void setSnapshotId(Long snapshotId); - } diff --git a/core/src/com/cloud/vm/ConsoleProxy.java b/api/src/com/cloud/vm/ConsoleProxy.java similarity index 100% rename from core/src/com/cloud/vm/ConsoleProxy.java rename to api/src/com/cloud/vm/ConsoleProxy.java diff --git a/core/src/com/cloud/vm/SecondaryStorageVm.java b/api/src/com/cloud/vm/SecondaryStorageVm.java similarity index 100% rename from core/src/com/cloud/vm/SecondaryStorageVm.java rename to api/src/com/cloud/vm/SecondaryStorageVm.java diff --git a/core/src/com/cloud/vm/SystemVm.java b/api/src/com/cloud/vm/SystemVm.java similarity index 100% rename from core/src/com/cloud/vm/SystemVm.java rename to api/src/com/cloud/vm/SystemVm.java diff --git a/api/src/com/cloud/vm/UserVmService.java b/api/src/com/cloud/vm/UserVmService.java index 7e89cd3e618..fa89521af0a 100755 --- a/api/src/com/cloud/vm/UserVmService.java +++ b/api/src/com/cloud/vm/UserVmService.java @@ -449,8 +449,8 @@ public interface UserVmService { VirtualMachine vmStorageMigration(Long vmId, StoragePool destPool); - UserVm restoreVM(RestoreVMCmd cmd); + UserVm restoreVM(RestoreVMCmd cmd) throws InsufficientCapacityException, ResourceUnavailableException; - UserVm upgradeVirtualMachine(ScaleVMCmd scaleVMCmd) throws ResourceUnavailableException, ConcurrentOperationException, ManagementServerException, VirtualMachineMigrationException; + boolean upgradeVirtualMachine(ScaleVMCmd scaleVMCmd) throws ResourceUnavailableException, ConcurrentOperationException, ManagementServerException, VirtualMachineMigrationException; } diff --git a/api/src/com/cloud/vm/VirtualMachine.java b/api/src/com/cloud/vm/VirtualMachine.java index 8f807d450c7..ce9add62469 100755 --- a/api/src/com/cloud/vm/VirtualMachine.java +++ b/api/src/com/cloud/vm/VirtualMachine.java @@ -186,6 +186,7 @@ public interface VirtualMachine extends RunningOn, ControlledEntity, Identity, I SecondaryStorageVm, ElasticIpVm, ElasticLoadBalancerVm, + InternalLoadBalancerVm, /* * UserBareMetal is only used for selecting VirtualMachineGuru, there is no @@ -196,7 +197,7 @@ public interface VirtualMachine extends RunningOn, ControlledEntity, Identity, I public static boolean isSystemVM(VirtualMachine.Type vmtype) { if (DomainRouter.equals(vmtype) || ConsoleProxy.equals(vmtype) - || SecondaryStorageVm.equals(vmtype)) { + || SecondaryStorageVm.equals(vmtype) || InternalLoadBalancerVm.equals(vmtype)) { return true; } return false; diff --git a/core/src/com/cloud/vm/VirtualMachineName.java b/api/src/com/cloud/vm/VirtualMachineName.java similarity index 100% rename from core/src/com/cloud/vm/VirtualMachineName.java rename to api/src/com/cloud/vm/VirtualMachineName.java diff --git a/core/src/com/cloud/vm/VmDetailConstants.java b/api/src/com/cloud/vm/VmDetailConstants.java similarity index 100% rename from core/src/com/cloud/vm/VmDetailConstants.java rename to api/src/com/cloud/vm/VmDetailConstants.java diff --git a/api/src/org/apache/cloudstack/api/ApiConstants.java b/api/src/org/apache/cloudstack/api/ApiConstants.java index 7e040ca9d91..23e57e65f70 100755 --- a/api/src/org/apache/cloudstack/api/ApiConstants.java +++ b/api/src/org/apache/cloudstack/api/ApiConstants.java @@ -85,6 +85,7 @@ public class ApiConstants { public static final String GSLB_SERVICE_TYPE = "gslbservicetype"; public static final String GSLB_STICKY_SESSION_METHOD = "gslbstickysessionmethodname"; public static final String GUEST_CIDR_ADDRESS = "guestcidraddress"; + public static final String GUEST_VLAN_RANGE = "guestvlanrange"; public static final String HA_ENABLE = "haenable"; public static final String HOST_ID = "hostid"; public static final String HOST_NAME = "hostname"; @@ -223,6 +224,7 @@ public class ApiConstants { public static final String VIRTUAL_MACHINE_ID = "virtualmachineid"; public static final String VIRTUAL_MACHINE_IDS = "virtualmachineids"; public static final String VLAN = "vlan"; + public static final String VLAN_RANGE = "vlanrange"; public static final String REMOVE_VLAN="removevlan"; public static final String VLAN_ID = "vlanid"; public static final String VM_AVAILABLE = "vmavailable"; @@ -480,6 +482,12 @@ public class ApiConstants { public static final String HEALTHCHECK_HEALTHY_THRESHOLD = "healthythreshold"; public static final String HEALTHCHECK_UNHEALTHY_THRESHOLD = "unhealthythreshold"; public static final String HEALTHCHECK_PINGPATH = "pingpath"; + public static final String SOURCE_PORT = "sourceport"; + public static final String INSTANCE_PORT = "instanceport"; + public static final String SOURCE_IP = "sourceipaddress"; + public static final String SOURCE_IP_NETWORK_ID = "sourceipaddressnetworkid"; + public static final String SCHEME = "scheme"; + public static final String PROVIDER_TYPE = "providertype"; public static final String AFFINITY_GROUP_IDS = "affinitygroupids"; public static final String AFFINITY_GROUP_NAMES = "affinitygroupnames"; public static final String ASA_INSIDE_PORT_PROFILE = "insideportprofile"; diff --git a/api/src/org/apache/cloudstack/api/BaseCmd.java b/api/src/org/apache/cloudstack/api/BaseCmd.java index 200675ddaca..8d66a8327f0 100644 --- a/api/src/org/apache/cloudstack/api/BaseCmd.java +++ b/api/src/org/apache/cloudstack/api/BaseCmd.java @@ -28,6 +28,9 @@ import java.util.regex.Pattern; import javax.inject.Inject; import org.apache.cloudstack.affinity.AffinityGroupService; +import org.apache.cloudstack.network.element.InternalLoadBalancerElementService; +import org.apache.cloudstack.network.lb.ApplicationLoadBalancerService; +import org.apache.cloudstack.network.lb.InternalLoadBalancerVMService; import org.apache.cloudstack.query.QueryService; import org.apache.cloudstack.usage.UsageService; import org.apache.log4j.Logger; @@ -42,6 +45,7 @@ import com.cloud.exception.NetworkRuleConflictException; import com.cloud.exception.PermissionDeniedException; import com.cloud.exception.ResourceAllocationException; import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.NetworkModel; import com.cloud.network.NetworkService; import com.cloud.network.NetworkUsageService; import com.cloud.network.StorageNetworkService; @@ -138,7 +142,12 @@ public abstract class BaseCmd { @Inject public VMSnapshotService _vmSnapshotService; @Inject public DataStoreProviderApiService dataStoreProviderApiService; @Inject public VpcProvisioningService _vpcProvSvc; + @Inject public ApplicationLoadBalancerService _newLbSvc; + @Inject public ApplicationLoadBalancerService _appLbService; @Inject public AffinityGroupService _affinityGroupService; + @Inject public InternalLoadBalancerElementService _internalLbElementSvc; + @Inject public InternalLoadBalancerVMService _internalLbSvc; + @Inject public NetworkModel _ntwkModel; public abstract void execute() throws ResourceUnavailableException, InsufficientCapacityException, ServerApiException, ConcurrentOperationException, ResourceAllocationException, NetworkRuleConflictException; diff --git a/api/src/org/apache/cloudstack/api/ResponseGenerator.java b/api/src/org/apache/cloudstack/api/ResponseGenerator.java index 003daaee53c..d0ab1f4aa98 100644 --- a/api/src/org/apache/cloudstack/api/ResponseGenerator.java +++ b/api/src/org/apache/cloudstack/api/ResponseGenerator.java @@ -19,91 +19,17 @@ package org.apache.cloudstack.api; import java.text.DecimalFormat; import java.util.EnumSet; import java.util.List; +import java.util.Map; -import com.cloud.vm.NicSecondaryIp; import org.apache.cloudstack.affinity.AffinityGroup; import org.apache.cloudstack.affinity.AffinityGroupResponse; import org.apache.cloudstack.api.ApiConstants.HostDetails; import org.apache.cloudstack.api.ApiConstants.VMDetails; import org.apache.cloudstack.api.command.user.job.QueryAsyncJobResultCmd; -import org.apache.cloudstack.api.response.AccountResponse; -import org.apache.cloudstack.api.response.AsyncJobResponse; -import org.apache.cloudstack.api.response.AutoScalePolicyResponse; -import org.apache.cloudstack.api.response.AutoScaleVmGroupResponse; -import org.apache.cloudstack.api.response.AutoScaleVmProfileResponse; -import org.apache.cloudstack.api.response.CapacityResponse; -import org.apache.cloudstack.api.response.ClusterResponse; -import org.apache.cloudstack.api.response.ConditionResponse; -import org.apache.cloudstack.api.response.ConfigurationResponse; -import org.apache.cloudstack.api.response.CounterResponse; -import org.apache.cloudstack.api.response.CreateCmdResponse; -import org.apache.cloudstack.api.response.DiskOfferingResponse; -import org.apache.cloudstack.api.response.DomainResponse; -import org.apache.cloudstack.api.response.DomainRouterResponse; -import org.apache.cloudstack.api.response.EventResponse; -import org.apache.cloudstack.api.response.ExtractResponse; -import org.apache.cloudstack.api.response.FirewallResponse; -import org.apache.cloudstack.api.response.FirewallRuleResponse; -import org.apache.cloudstack.api.response.GuestOSResponse; -import org.apache.cloudstack.api.response.HostResponse; -import org.apache.cloudstack.api.response.HypervisorCapabilitiesResponse; -import org.apache.cloudstack.api.response.IPAddressResponse; -import org.apache.cloudstack.api.response.InstanceGroupResponse; -import org.apache.cloudstack.api.response.IpForwardingRuleResponse; -import org.apache.cloudstack.api.response.LBHealthCheckResponse; -import org.apache.cloudstack.api.response.LBStickinessResponse; -import org.apache.cloudstack.api.response.LDAPConfigResponse; -import org.apache.cloudstack.api.response.LoadBalancerResponse; -import org.apache.cloudstack.api.response.NetworkACLResponse; -import org.apache.cloudstack.api.response.NetworkOfferingResponse; -import org.apache.cloudstack.api.response.NetworkResponse; -import org.apache.cloudstack.api.response.NicResponse; -import org.apache.cloudstack.api.response.NicSecondaryIpResponse; -import org.apache.cloudstack.api.response.PhysicalNetworkResponse; -import org.apache.cloudstack.api.response.PodResponse; -import org.apache.cloudstack.api.response.PrivateGatewayResponse; -import org.apache.cloudstack.api.response.ProjectAccountResponse; -import org.apache.cloudstack.api.response.ProjectInvitationResponse; -import org.apache.cloudstack.api.response.ProjectResponse; -import org.apache.cloudstack.api.response.ProviderResponse; -import org.apache.cloudstack.api.response.RegionResponse; -import org.apache.cloudstack.api.response.RemoteAccessVpnResponse; -import org.apache.cloudstack.api.response.ResourceCountResponse; -import org.apache.cloudstack.api.response.ResourceLimitResponse; -import org.apache.cloudstack.api.response.ResourceTagResponse; -import org.apache.cloudstack.api.response.S3Response; -import org.apache.cloudstack.api.response.SecurityGroupResponse; -import org.apache.cloudstack.api.response.ServiceOfferingResponse; -import org.apache.cloudstack.api.response.ServiceResponse; -import org.apache.cloudstack.api.response.Site2SiteCustomerGatewayResponse; -import org.apache.cloudstack.api.response.Site2SiteVpnConnectionResponse; -import org.apache.cloudstack.api.response.Site2SiteVpnGatewayResponse; -import org.apache.cloudstack.api.response.SnapshotPolicyResponse; -import org.apache.cloudstack.api.response.SnapshotResponse; -import org.apache.cloudstack.api.response.SnapshotScheduleResponse; -import org.apache.cloudstack.api.response.StaticRouteResponse; -import org.apache.cloudstack.api.response.StorageNetworkIpRangeResponse; -import org.apache.cloudstack.api.response.StoragePoolResponse; -import org.apache.cloudstack.api.response.SwiftResponse; -import org.apache.cloudstack.api.response.SystemVmInstanceResponse; -import org.apache.cloudstack.api.response.SystemVmResponse; -import org.apache.cloudstack.api.response.TemplatePermissionsResponse; -import org.apache.cloudstack.api.response.TemplateResponse; -import org.apache.cloudstack.api.response.TrafficMonitorResponse; -import org.apache.cloudstack.api.response.TrafficTypeResponse; -import org.apache.cloudstack.api.response.UsageRecordResponse; -import org.apache.cloudstack.api.response.UserResponse; -import org.apache.cloudstack.api.response.UserVmResponse; -import org.apache.cloudstack.api.response.VMSnapshotResponse; -import org.apache.cloudstack.api.response.VirtualRouterProviderResponse; -import org.apache.cloudstack.api.response.VlanIpRangeResponse; -import org.apache.cloudstack.api.response.VolumeResponse; -import org.apache.cloudstack.api.response.VpcOfferingResponse; -import org.apache.cloudstack.api.response.VpcResponse; -import org.apache.cloudstack.api.response.VpnUsersResponse; -import org.apache.cloudstack.api.response.ZoneResponse; +import org.apache.cloudstack.api.response.*; import org.apache.cloudstack.region.PortableIp; import org.apache.cloudstack.region.PortableIpRange; +import org.apache.cloudstack.network.lb.ApplicationLoadBalancerRule; import org.apache.cloudstack.region.Region; import org.apache.cloudstack.usage.Usage; @@ -120,9 +46,25 @@ import com.cloud.domain.Domain; import com.cloud.event.Event; import com.cloud.host.Host; import com.cloud.hypervisor.HypervisorCapabilities; -import com.cloud.network.*; +import com.cloud.network.GuestVlan; +import com.cloud.network.IpAddress; +import com.cloud.network.Network; import com.cloud.network.Network.Service; -import com.cloud.network.as.*; +import com.cloud.network.Networks.IsolationType; +import com.cloud.network.PhysicalNetwork; +import com.cloud.network.PhysicalNetworkServiceProvider; +import com.cloud.network.PhysicalNetworkTrafficType; +import com.cloud.network.RemoteAccessVpn; +import com.cloud.network.Site2SiteCustomerGateway; +import com.cloud.network.Site2SiteVpnConnection; +import com.cloud.network.Site2SiteVpnGateway; +import com.cloud.network.VirtualRouterProvider; +import com.cloud.network.VpnUser; +import com.cloud.network.as.AutoScalePolicy; +import com.cloud.network.as.AutoScaleVmGroup; +import com.cloud.network.as.AutoScaleVmProfile; +import com.cloud.network.as.Condition; +import com.cloud.network.as.Counter; import com.cloud.network.router.VirtualRouter; import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.HealthCheckPolicy; @@ -145,7 +87,12 @@ import com.cloud.projects.ProjectAccount; import com.cloud.projects.ProjectInvitation; import com.cloud.region.ha.GlobalLoadBalancerRule; import com.cloud.server.ResourceTag; -import com.cloud.storage.*; +import com.cloud.storage.GuestOS; +import com.cloud.storage.S3; +import com.cloud.storage.Snapshot; +import com.cloud.storage.StoragePool; +import com.cloud.storage.Swift; +import com.cloud.storage.Volume; import com.cloud.storage.snapshot.SnapshotPolicy; import com.cloud.storage.snapshot.SnapshotSchedule; import com.cloud.template.VirtualMachineTemplate; @@ -153,11 +100,12 @@ import com.cloud.user.Account; import com.cloud.user.User; import com.cloud.user.UserAccount; import com.cloud.uservm.UserVm; +import com.cloud.utils.net.Ip; import com.cloud.vm.InstanceGroup; import com.cloud.vm.Nic; -import com.cloud.vm.snapshot.VMSnapshot; +import com.cloud.vm.NicSecondaryIp; import com.cloud.vm.VirtualMachine; -import org.apache.cloudstack.api.response.*; +import com.cloud.vm.snapshot.VMSnapshot; public interface ResponseGenerator { UserResponse createUserResponse(UserAccount user); @@ -200,6 +148,8 @@ public interface ResponseGenerator { IPAddressResponse createIPAddressResponse(IpAddress ipAddress); + GuestVlanRangeResponse createDedicatedGuestVlanRangeResponse(GuestVlan result); + GlobalLoadBalancerResponse createGlobalLoadBalancerResponse(GlobalLoadBalancerRule globalLoadBalancerRule); LoadBalancerResponse createLoadBalancerResponse(LoadBalancer loadBalancer); @@ -395,6 +345,8 @@ public interface ResponseGenerator { NicSecondaryIpResponse createSecondaryIPToNicResponse(NicSecondaryIp result); public NicResponse createNicResponse(Nic result); + ApplicationLoadBalancerResponse createLoadBalancerContainerReponse(ApplicationLoadBalancerRule lb, Map lbInstances); + AffinityGroupResponse createAffinityGroupResponse(AffinityGroup group); Long getAffinityGroupId(String name, long entityOwnerId); @@ -402,4 +354,9 @@ public interface ResponseGenerator { PortableIpRangeResponse createPortableIPRangeResponse(PortableIpRange range); PortableIpResponse createPortableIPResponse(PortableIp portableIp); + + InternalLoadBalancerElementResponse createInternalLbElementResponse(VirtualRouterProvider result); + + IsolationMethodResponse createIsolationMethodResponse(IsolationType method); + } diff --git a/api/src/org/apache/cloudstack/api/command/admin/cluster/ListClustersCmd.java b/api/src/org/apache/cloudstack/api/command/admin/cluster/ListClustersCmd.java index 0417b187e38..f2dd3499b84 100644 --- a/api/src/org/apache/cloudstack/api/command/admin/cluster/ListClustersCmd.java +++ b/api/src/org/apache/cloudstack/api/command/admin/cluster/ListClustersCmd.java @@ -70,6 +70,9 @@ public class ListClustersCmd extends BaseListCmd { @Parameter(name=ApiConstants.MANAGED_STATE, type=CommandType.STRING, description="whether this cluster is managed by cloudstack") private String managedState; + @Parameter(name=ApiConstants.ZONE_TYPE, type=CommandType.STRING, description="the network type of the zone that the virtual machine belongs to") + private String zoneType; + @Parameter(name=ApiConstants.SHOW_CAPACITIES, type=CommandType.BOOLEAN, description="flag to display the capacity of the clusters") private Boolean showCapacities; @@ -114,7 +117,10 @@ public class ListClustersCmd extends BaseListCmd { this.managedState = managedstate; } - + public String getZoneType() { + return zoneType; + } + public Boolean getShowCapacities() { return showCapacities; } diff --git a/api/src/org/apache/cloudstack/api/command/admin/config/ListCfgsByCmd.java b/api/src/org/apache/cloudstack/api/command/admin/config/ListCfgsByCmd.java index 9f34405ffbd..a11904e90ce 100644 --- a/api/src/org/apache/cloudstack/api/command/admin/config/ListCfgsByCmd.java +++ b/api/src/org/apache/cloudstack/api/command/admin/config/ListCfgsByCmd.java @@ -45,11 +45,17 @@ public class ListCfgsByCmd extends BaseListCmd { @Parameter(name = ApiConstants.NAME, type = CommandType.STRING, description = "lists configuration by name") private String configName; - @Parameter(name=ApiConstants.SCOPE, type = CommandType.STRING, description = "scope(zone/cluster/pool/account) of the parameter that needs to be updated") - private String scope; + @Parameter(name=ApiConstants.ZONE_ID, type=CommandType.UUID, entityType=ZoneResponse.class, description="the ID of the Zone to update the parameter value for corresponding zone") + private Long zone_id; - @Parameter(name=ApiConstants.ID, type = CommandType.UUID, entityType = {ZoneResponse.class, ClusterResponse.class, StoragePoolResponse.class, AccountResponse.class}, description = "corresponding ID of the scope") - private Long id; + @Parameter(name=ApiConstants.CLUSTER_ID, type=CommandType.UUID, entityType=ClusterResponse.class, description="the ID of the Cluster to update the parameter value for corresponding cluster") + private Long cluster_id; + + @Parameter(name=ApiConstants.STORAGE_ID, type=CommandType.UUID, entityType=StoragePoolResponse.class, description="the ID of the Storage pool to update the parameter value for corresponding storage pool") + private Long storagepool_id; + + @Parameter(name=ApiConstants.ACCOUNT_ID, type=CommandType.UUID, entityType=AccountResponse.class, description="the ID of the Account to update the parameter value for corresponding account") + private Long account_id; // /////////////////////////////////////////////////// @@ -64,14 +70,21 @@ public class ListCfgsByCmd extends BaseListCmd { return configName; } - public String getScope() { - return scope; + public Long getZoneId() { + return zone_id; } - public Long getId() { - return id; + public Long getClusterId() { + return cluster_id; } + public Long getStoragepoolId() { + return storagepool_id; + } + + public Long getAccountId() { + return account_id; + } @Override public Long getPageSizeVal() { @@ -100,10 +113,17 @@ public class ListCfgsByCmd extends BaseListCmd { for (Configuration cfg : result.first()) { ConfigurationResponse cfgResponse = _responseGenerator.createConfigurationResponse(cfg); cfgResponse.setObjectName("configuration"); - if (scope != null) { - cfgResponse.setScope(scope); - } else { - cfgResponse.setScope("global"); + if(getZoneId() != null) { + cfgResponse.setScope("zone"); + } + if(getClusterId() != null) { + cfgResponse.setScope("cluster"); + } + if(getStoragepoolId() != null) { + cfgResponse.setScope("storagepool"); + } + if(getAccountId() != null) { + cfgResponse.setScope("account"); } configResponses.add(cfgResponse); } diff --git a/api/src/org/apache/cloudstack/api/command/admin/config/UpdateCfgCmd.java b/api/src/org/apache/cloudstack/api/command/admin/config/UpdateCfgCmd.java index 074c5a3b028..deb61d3741d 100644 --- a/api/src/org/apache/cloudstack/api/command/admin/config/UpdateCfgCmd.java +++ b/api/src/org/apache/cloudstack/api/command/admin/config/UpdateCfgCmd.java @@ -43,11 +43,17 @@ public class UpdateCfgCmd extends BaseCmd { @Parameter(name=ApiConstants.VALUE, type=CommandType.STRING, description="the value of the configuration", length=4095) private String value; - @Parameter(name=ApiConstants.SCOPE, type = CommandType.STRING, description = "scope(zone/cluster/pool/account) of the parameter that needs to be updated") - private String scope; + @Parameter(name=ApiConstants.ZONE_ID, type=CommandType.UUID, entityType=ZoneResponse.class, description="the ID of the Zone to update the parameter value for corresponding zone") + private Long zone_id; - @Parameter(name=ApiConstants.ID, type = CommandType.UUID, entityType = {ZoneResponse.class, ClusterResponse.class, StoragePoolResponse.class, AccountResponse.class}, description = "corresponding ID of the scope") - private Long id; + @Parameter(name=ApiConstants.CLUSTER_ID, type=CommandType.UUID, entityType=ClusterResponse.class, description="the ID of the Cluster to update the parameter value for corresponding cluster") + private Long cluster_id; + + @Parameter(name=ApiConstants.STORAGE_ID, type=CommandType.UUID, entityType=StoragePoolResponse.class, description="the ID of the Storage pool to update the parameter value for corresponding storage pool") + private Long storagepool_id; + + @Parameter(name=ApiConstants.ACCOUNT_ID, type=CommandType.UUID, entityType=AccountResponse.class, description="the ID of the Account to update the parameter value for corresponding account") + private Long account_id; ///////////////////////////////////////////////////// /////////////////// Accessors /////////////////////// @@ -61,12 +67,20 @@ public class UpdateCfgCmd extends BaseCmd { return value; } - public String getScope() { - return scope; + public Long getZoneId() { + return zone_id; } - public Long getId() { - return id; + public Long getClusterId() { + return cluster_id; + } + + public Long getStoragepoolId() { + return storagepool_id; + } + + public Long getAccountId() { + return account_id; } ///////////////////////////////////////////////////// @@ -89,12 +103,19 @@ public class UpdateCfgCmd extends BaseCmd { if (cfg != null) { ConfigurationResponse response = _responseGenerator.createConfigurationResponse(cfg); response.setResponseName(getCommandName()); - if (scope != null) { - response.setScope(scope); - response.setValue(value); - } else { - response.setScope("global"); + if(getZoneId() != null) { + response.setScope("zone"); } + if(getClusterId() != null) { + response.setScope("cluster"); + } + if(getStoragepoolId() != null) { + response.setScope("storagepool"); + } + if(getAccountId() != null) { + response.setScope("account"); + } + response.setValue(value); this.setResponseObject(response); } else { throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to update config"); diff --git a/api/src/org/apache/cloudstack/api/command/admin/internallb/ConfigureInternalLoadBalancerElementCmd.java b/api/src/org/apache/cloudstack/api/command/admin/internallb/ConfigureInternalLoadBalancerElementCmd.java new file mode 100644 index 00000000000..7c3d1e95e57 --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/admin/internallb/ConfigureInternalLoadBalancerElementCmd.java @@ -0,0 +1,114 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.cloudstack.api.command.admin.internallb; + +import java.util.List; + +import javax.inject.Inject; + +import org.apache.cloudstack.api.APICommand; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.ApiErrorCode; +import org.apache.cloudstack.api.BaseAsyncCmd; +import org.apache.cloudstack.api.Parameter; +import org.apache.cloudstack.api.ServerApiException; +import org.apache.cloudstack.api.response.InternalLoadBalancerElementResponse; +import org.apache.cloudstack.network.element.InternalLoadBalancerElementService; +import org.apache.log4j.Logger; + +import com.cloud.event.EventTypes; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.VirtualRouterProvider; +import com.cloud.user.Account; +import com.cloud.user.UserContext; + +@APICommand(name = "configureInternalLoadBalancerElement", responseObject=InternalLoadBalancerElementResponse.class, + description="Configures an Internal Load Balancer element.", since="4.2.0") +public class ConfigureInternalLoadBalancerElementCmd extends BaseAsyncCmd { + public static final Logger s_logger = Logger.getLogger(ConfigureInternalLoadBalancerElementCmd.class.getName()); + private static final String s_name = "configureinternalloadbalancerelementresponse"; + + @Inject + private List _service; + + ///////////////////////////////////////////////////// + //////////////// API parameters ///////////////////// + ///////////////////////////////////////////////////// + + @Parameter(name=ApiConstants.ID, type=CommandType.UUID, entityType = InternalLoadBalancerElementResponse.class, + required=true, description="the ID of the internal lb provider") + private Long id; + + @Parameter(name=ApiConstants.ENABLED, type=CommandType.BOOLEAN, required=true, description="Enables/Disables the Internal Load Balancer element") + private Boolean enabled; + + ///////////////////////////////////////////////////// + /////////////////// Accessors /////////////////////// + ///////////////////////////////////////////////////// + + + public Long getId() { + return id; + } + + public Boolean getEnabled() { + return enabled; + } + + ///////////////////////////////////////////////////// + /////////////// API Implementation/////////////////// + ///////////////////////////////////////////////////// + + @Override + public String getCommandName() { + return s_name; + } + + @Override + public long getEntityOwnerId() { + return Account.ACCOUNT_ID_SYSTEM; + } + + @Override + public String getEventType() { + return EventTypes.EVENT_NETWORK_ELEMENT_CONFIGURE; + } + + @Override + public String getEventDescription() { + return "configuring internal load balancer element: " + id; + } + + @Override + public void execute() throws ConcurrentOperationException, ResourceUnavailableException, InsufficientCapacityException{ + s_logger.debug("hello alena"); + UserContext.current().setEventDetails("Internal load balancer element: " + id); + s_logger.debug("hello alena"); + VirtualRouterProvider result = _service.get(0).configureInternalLoadBalancerElement(getId(), getEnabled()); + s_logger.debug("hello alena"); + if (result != null){ + InternalLoadBalancerElementResponse routerResponse = _responseGenerator.createInternalLbElementResponse(result); + routerResponse.setResponseName(getCommandName()); + this.setResponseObject(routerResponse); + } else { + throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to configure the internal load balancer element"); + } + } +} diff --git a/api/src/org/apache/cloudstack/api/command/admin/internallb/CreateInternalLoadBalancerElementCmd.java b/api/src/org/apache/cloudstack/api/command/admin/internallb/CreateInternalLoadBalancerElementCmd.java new file mode 100644 index 00000000000..2902f7ae18a --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/admin/internallb/CreateInternalLoadBalancerElementCmd.java @@ -0,0 +1,116 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.command.admin.internallb; + +import java.util.List; + +import javax.inject.Inject; + +import org.apache.cloudstack.api.APICommand; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.ApiErrorCode; +import org.apache.cloudstack.api.BaseAsyncCreateCmd; +import org.apache.cloudstack.api.Parameter; +import org.apache.cloudstack.api.ServerApiException; +import org.apache.cloudstack.api.response.InternalLoadBalancerElementResponse; +import org.apache.cloudstack.api.response.ProviderResponse; +import org.apache.cloudstack.network.element.InternalLoadBalancerElementService; +import org.apache.log4j.Logger; + +import com.cloud.event.EventTypes; +import com.cloud.exception.ResourceAllocationException; +import com.cloud.network.VirtualRouterProvider; +import com.cloud.user.Account; +import com.cloud.user.UserContext; + +@APICommand(name = "createInternalLoadBalancerElement", responseObject=InternalLoadBalancerElementResponse.class, description="Create an Internal Load Balancer element.",since="4.2.0") +public class CreateInternalLoadBalancerElementCmd extends BaseAsyncCreateCmd { + public static final Logger s_logger = Logger.getLogger(CreateInternalLoadBalancerElementCmd.class.getName()); + private static final String s_name = "createinternalloadbalancerelementresponse"; + + @Inject + private List _service; + + ///////////////////////////////////////////////////// + //////////////// API parameters ///////////////////// + ///////////////////////////////////////////////////// + + @Parameter(name=ApiConstants.NETWORK_SERVICE_PROVIDER_ID, type=CommandType.UUID, entityType = ProviderResponse.class, required=true, description="the network service provider ID of the internal load balancer element") + private Long nspId; + + ///////////////////////////////////////////////////// + /////////////////// Accessors /////////////////////// + ///////////////////////////////////////////////////// + + public void setNspId(Long nspId) { + this.nspId = nspId; + } + + public Long getNspId() { + return nspId; + } + + ///////////////////////////////////////////////////// + /////////////// API Implementation/////////////////// + ///////////////////////////////////////////////////// + + + + @Override + public String getCommandName() { + return s_name; + } + + @Override + public long getEntityOwnerId() { + return Account.ACCOUNT_ID_SYSTEM; + } + + @Override + public void execute(){ + UserContext.current().setEventDetails("Virtual router element Id: "+getEntityId()); + VirtualRouterProvider result = _service.get(0).getInternalLoadBalancerElement(getEntityId()); + if (result != null) { + InternalLoadBalancerElementResponse response = _responseGenerator.createInternalLbElementResponse(result); + response.setResponseName(getCommandName()); + this.setResponseObject(response); + }else { + throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to add Virtual Router entity to physical network"); + } + } + + @Override + public void create() throws ResourceAllocationException { + VirtualRouterProvider result = _service.get(0).addInternalLoadBalancerElement(getNspId()); + if (result != null) { + setEntityId(result.getId()); + setEntityUuid(result.getUuid()); + } else { + throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to add Internal Load Balancer entity to physical network"); + } + } + + @Override + public String getEventType() { + return EventTypes.EVENT_SERVICE_PROVIDER_CREATE; + } + + @Override + public String getEventDescription() { + return "Adding physical network element Internal Load Balancer: " + getEntityId(); + } +} diff --git a/api/src/org/apache/cloudstack/api/command/admin/internallb/ListInternalLBVMsCmd.java b/api/src/org/apache/cloudstack/api/command/admin/internallb/ListInternalLBVMsCmd.java new file mode 100644 index 00000000000..e314b3245c7 --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/admin/internallb/ListInternalLBVMsCmd.java @@ -0,0 +1,151 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.command.admin.internallb; + +import org.apache.cloudstack.api.APICommand; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.BaseListProjectAndAccountResourcesCmd; +import org.apache.cloudstack.api.Parameter; +import org.apache.cloudstack.api.response.DomainRouterResponse; +import org.apache.cloudstack.api.response.HostResponse; +import org.apache.cloudstack.api.response.ListResponse; +import org.apache.cloudstack.api.response.NetworkResponse; +import org.apache.cloudstack.api.response.PodResponse; +import org.apache.cloudstack.api.response.UserVmResponse; +import org.apache.cloudstack.api.response.VpcResponse; +import org.apache.cloudstack.api.response.ZoneResponse; +import org.apache.log4j.Logger; + +import com.cloud.async.AsyncJob; +import com.cloud.network.router.VirtualRouter.Role; + +@APICommand(name = "listInternalLoadBalancerVMs", description="List internal LB VMs.", responseObject=DomainRouterResponse.class) +public class ListInternalLBVMsCmd extends BaseListProjectAndAccountResourcesCmd { + public static final Logger s_logger = Logger.getLogger(ListInternalLBVMsCmd.class.getName()); + + private static final String s_name = "listinternallbvmssresponse"; + + ///////////////////////////////////////////////////// + //////////////// API parameters ///////////////////// + ///////////////////////////////////////////////////// + + @Parameter(name=ApiConstants.HOST_ID, type=CommandType.UUID, entityType=HostResponse.class, + description="the host ID of the Internal LB VM") + private Long hostId; + + @Parameter(name=ApiConstants.ID, type=CommandType.UUID, entityType=UserVmResponse.class, + description="the ID of the Internal LB VM") + private Long id; + + @Parameter(name=ApiConstants.NAME, type=CommandType.STRING, description="the name of the Internal LB VM") + private String routerName; + + @Parameter(name=ApiConstants.POD_ID, type=CommandType.UUID, entityType=PodResponse.class, + description="the Pod ID of the Internal LB VM") + private Long podId; + + @Parameter(name=ApiConstants.STATE, type=CommandType.STRING, description="the state of the Internal LB VM") + private String state; + + @Parameter(name=ApiConstants.ZONE_ID, type=CommandType.UUID, entityType=ZoneResponse.class, + description="the Zone ID of the Internal LB VM") + private Long zoneId; + + @Parameter(name=ApiConstants.NETWORK_ID, type=CommandType.UUID, entityType=NetworkResponse.class, + description="list by network id") + private Long networkId; + + @Parameter(name=ApiConstants.VPC_ID, type=CommandType.UUID, entityType=VpcResponse.class, + description="List Internal LB VMs by VPC") + private Long vpcId; + + @Parameter(name=ApiConstants.FOR_VPC, type=CommandType.BOOLEAN, description="if true is passed for this parameter, list only VPC Internal LB VMs") + private Boolean forVpc; + + @Parameter(name=ApiConstants.ZONE_TYPE, type=CommandType.STRING, description="the network type of the zone that the virtual machine belongs to") + private String zoneType; + + + ///////////////////////////////////////////////////// + /////////////////// Accessors /////////////////////// + ///////////////////////////////////////////////////// + + public Long getHostId() { + return hostId; + } + + public Long getId() { + return id; + } + + public String getRouterName() { + return routerName; + } + + public Long getPodId() { + return podId; + } + + public String getState() { + return state; + } + + public Long getZoneId() { + return zoneId; + } + + public Long getNetworkId() { + return networkId; + } + + public Long getVpcId() { + return vpcId; + } + + public Boolean getForVpc() { + return forVpc; + } + + public String getRole() { + return Role.INTERNAL_LB_VM.toString(); + } + + public String getZoneType() { + return zoneType; + } + + ///////////////////////////////////////////////////// + /////////////// API Implementation/////////////////// + ///////////////////////////////////////////////////// + + @Override + public String getCommandName() { + return s_name; + } + + @Override + public AsyncJob.Type getInstanceType() { + return AsyncJob.Type.DomainRouter; + } + + @Override + public void execute(){ + ListResponse response = _queryService.searchForInternalLbVms(this); + response.setResponseName(getCommandName()); + this.setResponseObject(response); + } +} diff --git a/api/src/org/apache/cloudstack/api/command/admin/internallb/ListInternalLoadBalancerElementsCmd.java b/api/src/org/apache/cloudstack/api/command/admin/internallb/ListInternalLoadBalancerElementsCmd.java new file mode 100644 index 00000000000..18536191995 --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/admin/internallb/ListInternalLoadBalancerElementsCmd.java @@ -0,0 +1,99 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.command.admin.internallb; + +import java.util.ArrayList; +import java.util.List; + +import javax.inject.Inject; + +import org.apache.cloudstack.api.APICommand; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.BaseListCmd; +import org.apache.cloudstack.api.Parameter; +import org.apache.cloudstack.api.ServerApiException; +import org.apache.cloudstack.api.response.InternalLoadBalancerElementResponse; +import org.apache.cloudstack.api.response.ListResponse; +import org.apache.cloudstack.api.response.ProviderResponse; +import org.apache.cloudstack.network.element.InternalLoadBalancerElementService; +import org.apache.log4j.Logger; + +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.ResourceAllocationException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.VirtualRouterProvider; + +@APICommand(name = "listInternalLoadBalancerElements", description="Lists all available Internal Load Balancer elements.", + responseObject=InternalLoadBalancerElementResponse.class, since="4.2.0") +public class ListInternalLoadBalancerElementsCmd extends BaseListCmd { + public static final Logger s_logger = Logger.getLogger(ListInternalLoadBalancerElementsCmd.class.getName()); + private static final String _name = "listinternalloadbalancerelementsresponse"; + + @Inject + private InternalLoadBalancerElementService _service; + + ///////////////////////////////////////////////////// + //////////////// API parameters ///////////////////// + ///////////////////////////////////////////////////// + @Parameter(name=ApiConstants.ID, type=CommandType.UUID, entityType = InternalLoadBalancerElementResponse.class, + description="list internal load balancer elements by id") + private Long id; + + @Parameter(name=ApiConstants.NSP_ID, type=CommandType.UUID, entityType = ProviderResponse.class, + description="list internal load balancer elements by network service provider id") + private Long nspId; + + @Parameter(name=ApiConstants.ENABLED, type=CommandType.BOOLEAN, description="list internal load balancer elements by enabled state") + private Boolean enabled; + + ///////////////////////////////////////////////////// + /////////////////// Accessors /////////////////////// + ///////////////////////////////////////////////////// + + public Long getId() { + return id; + } + + public Long getNspId() { + return nspId; + } + + public Boolean getEnabled() { + return enabled; + } + + @Override + public String getCommandName() { + return _name; + } + + @Override + public void execute() throws ResourceUnavailableException, InsufficientCapacityException, ServerApiException, ConcurrentOperationException, ResourceAllocationException { + List providers = _service.searchForInternalLoadBalancerElements(getId(), getNspId(), getEnabled()); + ListResponse response = new ListResponse(); + List providerResponses = new ArrayList(); + for (VirtualRouterProvider provider : providers) { + InternalLoadBalancerElementResponse providerResponse = _responseGenerator.createInternalLbElementResponse(provider); + providerResponses.add(providerResponse); + } + response.setResponses(providerResponses); + response.setResponseName(getCommandName()); + this.setResponseObject(response); + + } +} diff --git a/api/src/org/apache/cloudstack/api/command/admin/internallb/StartInternalLBVMCmd.java b/api/src/org/apache/cloudstack/api/command/admin/internallb/StartInternalLBVMCmd.java new file mode 100644 index 00000000000..31d132b5c9c --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/admin/internallb/StartInternalLBVMCmd.java @@ -0,0 +1,120 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.command.admin.internallb; + +import org.apache.cloudstack.api.APICommand; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.ApiErrorCode; +import org.apache.cloudstack.api.BaseAsyncCmd; +import org.apache.cloudstack.api.Parameter; +import org.apache.cloudstack.api.ServerApiException; +import org.apache.cloudstack.api.response.DomainRouterResponse; +import org.apache.log4j.Logger; + +import com.cloud.async.AsyncJob; +import com.cloud.event.EventTypes; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.router.VirtualRouter; +import com.cloud.network.router.VirtualRouter.Role; +import com.cloud.user.UserContext; + +@APICommand(name = "startInternalLoadBalancerVM", responseObject=DomainRouterResponse.class, description="Starts an existing internal lb vm.") +public class StartInternalLBVMCmd extends BaseAsyncCmd { + public static final Logger s_logger = Logger.getLogger(StartInternalLBVMCmd.class.getName()); + private static final String s_name = "startinternallbvmresponse"; + + + ///////////////////////////////////////////////////// + //////////////// API parameters ///////////////////// + ///////////////////////////////////////////////////// + + @Parameter(name=ApiConstants.ID, type=CommandType.UUID, entityType=DomainRouterResponse.class, + required=true, description="the ID of the internal lb vm") + private Long id; + + ///////////////////////////////////////////////////// + /////////////////// Accessors /////////////////////// + ///////////////////////////////////////////////////// + + public Long getId() { + return id; + } + + ///////////////////////////////////////////////////// + /////////////// API Implementation/////////////////// + ///////////////////////////////////////////////////// + + @Override + public String getCommandName() { + return s_name; + } + + public static String getResultObjectName() { + return "router"; + } + + @Override + public long getEntityOwnerId() { + VirtualRouter router = _entityMgr.findById(VirtualRouter.class, getId()); + if (router != null && router.getRole() == Role.INTERNAL_LB_VM) { + return router.getAccountId(); + } else { + throw new InvalidParameterValueException("Unable to find internal lb vm by id"); + } + } + + @Override + public String getEventType() { + return EventTypes.EVENT_INTERNAL_LB_VM_START; + } + + @Override + public String getEventDescription() { + return "starting internal lb vm: " + getId(); + } + + public AsyncJob.Type getInstanceType() { + return AsyncJob.Type.InternalLbVm; + } + + public Long getInstanceId() { + return getId(); + } + + @Override + public void execute() throws ConcurrentOperationException, ResourceUnavailableException, InsufficientCapacityException{ + UserContext.current().setEventDetails("Internal Lb Vm Id: "+getId()); + VirtualRouter result = null; + VirtualRouter router = _routerService.findRouter(getId()); + if (router == null || router.getRole() != Role.INTERNAL_LB_VM) { + throw new InvalidParameterValueException("Can't find internal lb vm by id"); + } else { + result = _internalLbSvc.startInternalLbVm(getId(), UserContext.current().getCaller(), UserContext.current().getCallerUserId()); + } + + if (result != null){ + DomainRouterResponse routerResponse = _responseGenerator.createDomainRouterResponse(result); + routerResponse.setResponseName(getCommandName()); + this.setResponseObject(routerResponse); + } else { + throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to start internal lb vm"); + } + } +} diff --git a/api/src/org/apache/cloudstack/api/command/admin/internallb/StopInternalLBVMCmd.java b/api/src/org/apache/cloudstack/api/command/admin/internallb/StopInternalLBVMCmd.java new file mode 100644 index 00000000000..f40db49b417 --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/admin/internallb/StopInternalLBVMCmd.java @@ -0,0 +1,123 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.command.admin.internallb; + +import org.apache.cloudstack.api.APICommand; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.ApiErrorCode; +import org.apache.cloudstack.api.BaseAsyncCmd; +import org.apache.cloudstack.api.Parameter; +import org.apache.cloudstack.api.ServerApiException; +import org.apache.cloudstack.api.response.DomainRouterResponse; +import org.apache.log4j.Logger; + +import com.cloud.async.AsyncJob; +import com.cloud.event.EventTypes; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.router.VirtualRouter; +import com.cloud.network.router.VirtualRouter.Role; +import com.cloud.user.UserContext; + +@APICommand(name = "stopInternalLoadBalancerVM", description = "Stops an Internal LB vm.", responseObject = DomainRouterResponse.class) +public class StopInternalLBVMCmd extends BaseAsyncCmd { + public static final Logger s_logger = Logger.getLogger(StopInternalLBVMCmd.class.getName()); + private static final String s_name = "stopinternallbvmresponse"; + + // /////////////////////////////////////////////////// + // ////////////// API parameters ///////////////////// + // /////////////////////////////////////////////////// + + @Parameter(name = ApiConstants.ID, type = CommandType.UUID, entityType = DomainRouterResponse.class, + required = true, description = "the ID of the internal lb vm") + private Long id; + + @Parameter(name = ApiConstants.FORCED, type = CommandType.BOOLEAN, required = false, description = "Force stop the VM. The caller knows the VM is stopped.") + private Boolean forced; + + // /////////////////////////////////////////////////// + // ///////////////// Accessors /////////////////////// + // /////////////////////////////////////////////////// + + public Long getId() { + return id; + } + + // /////////////////////////////////////////////////// + // ///////////// API Implementation/////////////////// + // /////////////////////////////////////////////////// + + @Override + public String getCommandName() { + return s_name; + } + + @Override + public long getEntityOwnerId() { + VirtualRouter vm = _entityMgr.findById(VirtualRouter.class, getId()); + if (vm != null && vm.getRole() == Role.INTERNAL_LB_VM) { + return vm.getAccountId(); + } else { + throw new InvalidParameterValueException("Unable to find internal lb vm by id"); + } + } + + @Override + public String getEventType() { + return EventTypes.EVENT_INTERNAL_LB_VM_STOP; + } + + @Override + public String getEventDescription() { + return "stopping internal lb vm: " + getId(); + } + + @Override + public AsyncJob.Type getInstanceType() { + return AsyncJob.Type.InternalLbVm; + } + + @Override + public Long getInstanceId() { + return getId(); + } + + public boolean isForced() { + return (forced != null) ? forced : false; + } + + @Override + public void execute() throws ConcurrentOperationException, ResourceUnavailableException { + UserContext.current().setEventDetails("Internal lb vm Id: "+getId()); + VirtualRouter result = null; + VirtualRouter vm = _routerService.findRouter(getId()); + if (vm == null || vm.getRole() != Role.INTERNAL_LB_VM) { + throw new InvalidParameterValueException("Can't find internal lb vm by id"); + } else { + result = _internalLbSvc.stopInternalLbVm(getId(), isForced(), UserContext.current().getCaller(), UserContext.current().getCallerUserId()); + } + + if (result != null) { + DomainRouterResponse response = _responseGenerator.createDomainRouterResponse(result); + response.setResponseName(getCommandName()); + this.setResponseObject(response); + } else { + throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to stop internal lb vm"); + } + } +} diff --git a/api/src/org/apache/cloudstack/api/command/admin/network/CreateNetworkOfferingCmd.java b/api/src/org/apache/cloudstack/api/command/admin/network/CreateNetworkOfferingCmd.java index b48bf9e763e..6410715727c 100644 --- a/api/src/org/apache/cloudstack/api/command/admin/network/CreateNetworkOfferingCmd.java +++ b/api/src/org/apache/cloudstack/api/command/admin/network/CreateNetworkOfferingCmd.java @@ -31,7 +31,6 @@ import org.apache.cloudstack.api.Parameter; import org.apache.cloudstack.api.ServerApiException; import org.apache.cloudstack.api.response.NetworkOfferingResponse; import org.apache.cloudstack.api.response.ServiceOfferingResponse; - import org.apache.log4j.Logger; import com.cloud.exception.InvalidParameterValueException; @@ -95,6 +94,10 @@ public class CreateNetworkOfferingCmd extends BaseCmd { @Parameter(name=ApiConstants.IS_PERSISTENT, type=CommandType.BOOLEAN, description="true if network offering supports persistent networks; defaulted to false if not specified") private Boolean isPersistent; + + @Parameter(name=ApiConstants.DETAILS, type=CommandType.MAP, since="4.2.0", description="Template details in key/value pairs." + + " Supported keys are internallbprovider/publiclbprovider with service provider as a value") + protected Map details; ///////////////////////////////////////////////////// /////////////////// Accessors /////////////////////// @@ -215,6 +218,16 @@ public class CreateNetworkOfferingCmd extends BaseCmd { return capabilityMap; } + + public Map getDetails() { + if (details == null || details.isEmpty()) { + return null; + } + + Collection paramsCollection = details.values(); + Map params = (Map) (paramsCollection.toArray())[0]; + return params; + } ///////////////////////////////////////////////////// /////////////// API Implementation/////////////////// diff --git a/api/src/org/apache/cloudstack/api/command/admin/network/DedicateGuestVlanRangeCmd.java b/api/src/org/apache/cloudstack/api/command/admin/network/DedicateGuestVlanRangeCmd.java new file mode 100644 index 00000000000..ec1436065ba --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/admin/network/DedicateGuestVlanRangeCmd.java @@ -0,0 +1,118 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package org.apache.cloudstack.api.command.admin.network; + +import com.cloud.exception.ResourceAllocationException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.GuestVlan; +import com.cloud.user.Account; +import org.apache.cloudstack.api.APICommand; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.ApiErrorCode; +import org.apache.cloudstack.api.BaseCmd; +import org.apache.cloudstack.api.Parameter; +import org.apache.cloudstack.api.ServerApiException; +import org.apache.cloudstack.api.response.DomainResponse; +import org.apache.cloudstack.api.response.GuestVlanRangeResponse; +import org.apache.cloudstack.api.response.PhysicalNetworkResponse; +import org.apache.cloudstack.api.response.ProjectResponse; +import org.apache.log4j.Logger; + +@APICommand(name = "dedicateGuestVlanRange", description="Dedicates a guest vlan range to an account", responseObject=GuestVlanRangeResponse.class) +public class DedicateGuestVlanRangeCmd extends BaseCmd { + public static final Logger s_logger = Logger.getLogger(DedicateGuestVlanRangeCmd.class.getName()); + + private static final String s_name = "dedicateguestvlanrangeresponse"; + + ///////////////////////////////////////////////////// + //////////////// API parameters ///////////////////// + ///////////////////////////////////////////////////// + + @Parameter(name=ApiConstants.VLAN_RANGE, type=CommandType.STRING, required=true, + description="guest vlan range to be dedicated") + private String vlan; + + @Parameter(name=ApiConstants.ACCOUNT, type=CommandType.STRING, required=true, + description="account who will own the VLAN") + private String accountName; + + @Parameter(name=ApiConstants.PROJECT_ID, type=CommandType.UUID, entityType = ProjectResponse.class, + description="project who will own the VLAN") + private Long projectId; + + @Parameter(name=ApiConstants.DOMAIN_ID, type=CommandType.UUID, entityType = DomainResponse.class, + required=true, description="domain ID of the account owning a VLAN") + private Long domainId; + + @Parameter(name=ApiConstants.PHYSICAL_NETWORK_ID, type=CommandType.UUID, entityType = PhysicalNetworkResponse.class, + required=true, description="physical network ID of the vlan") + private Long physicalNetworkId; + + ///////////////////////////////////////////////////// + /////////////////// Accessors /////////////////////// + ///////////////////////////////////////////////////// + + public String getVlan() { + return vlan; + } + + public String getAccountName() { + return accountName; + } + + public Long getDomainId() { + return domainId; + } + + public Long getPhysicalNetworkId() { + return physicalNetworkId; + } + + public Long getProjectId() { + return projectId; + } + + ///////////////////////////////////////////////////// + /////////////// API Implementation/////////////////// + ///////////////////////////////////////////////////// + + @Override + public String getCommandName() { + return s_name; + } + + @Override + public long getEntityOwnerId() { + return Account.ACCOUNT_ID_SYSTEM; + } + + @Override + public void execute() throws ResourceUnavailableException, ResourceAllocationException { + GuestVlan result = _networkService.dedicateGuestVlanRange(this); + if (result != null) { + GuestVlanRangeResponse response = _responseGenerator.createDedicatedGuestVlanRangeResponse(result); + response.setResponseName(getCommandName()); + response.setObjectName("dedicatedguestvlanrange"); + this.setResponseObject(response); + } else { + throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to dedicate guest vlan range"); + } + } + +} diff --git a/api/src/org/apache/cloudstack/api/command/admin/network/ListDedicatedGuestVlanRangesCmd.java b/api/src/org/apache/cloudstack/api/command/admin/network/ListDedicatedGuestVlanRangesCmd.java new file mode 100644 index 00000000000..7f93efc780f --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/admin/network/ListDedicatedGuestVlanRangesCmd.java @@ -0,0 +1,129 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.command.admin.network; + +import com.cloud.network.GuestVlan; +import com.cloud.user.Account; +import com.cloud.utils.Pair; +import org.apache.cloudstack.api.*; +import org.apache.cloudstack.api.response.*; +import org.apache.log4j.Logger; + +import java.util.ArrayList; +import java.util.List; + + +@APICommand(name = "listDedicatedGuestVlanRanges", description="Lists dedicated guest vlan ranges", responseObject=GuestVlanRangeResponse.class) +public class ListDedicatedGuestVlanRangesCmd extends BaseListCmd { + public static final Logger s_logger = Logger.getLogger(ListDedicatedGuestVlanRangesCmd.class.getName()); + + private static final String s_name = "listdedicatedguestvlanrangesresponse"; + + ///////////////////////////////////////////////////// + //////////////// API parameters ///////////////////// + ///////////////////////////////////////////////////// + + @Parameter(name=ApiConstants.ID, type=CommandType.UUID, entityType=GuestVlanRangeResponse.class, + description="list dedicated guest vlan ranges by id") + private Long id; + + @Parameter(name=ApiConstants.ACCOUNT, type=CommandType.STRING, description="the account with which the guest VLAN range is associated. Must be used with the domainId parameter.") + private String accountName; + + @Parameter(name=ApiConstants.PROJECT_ID, type=CommandType.UUID, entityType = ProjectResponse.class, + description="project who will own the guest VLAN range") + private Long projectId; + + @Parameter(name=ApiConstants.DOMAIN_ID, type=CommandType.UUID, entityType = DomainResponse.class, + description="the domain ID with which the guest VLAN range is associated. If used with the account parameter, returns all guest VLAN ranges for that account in the specified domain.") + private Long domainId; + + @Parameter(name=ApiConstants.GUEST_VLAN_RANGE, type=CommandType.STRING, description="the dedicated guest vlan range") + private String guestVlanRange; + + @Parameter(name=ApiConstants.PHYSICAL_NETWORK_ID, type=CommandType.UUID, entityType = PhysicalNetworkResponse.class, + description="physical network id of the guest VLAN range") + private Long physicalNetworkId; + + @Parameter(name=ApiConstants.ZONE_ID, type=CommandType.UUID, entityType = ZoneResponse.class, + description="zone of the guest VLAN range") + private Long zoneId; + + ///////////////////////////////////////////////////// + /////////////////// Accessors /////////////////////// + ///////////////////////////////////////////////////// + + public Long getId() { + return id; + } + + public String getAccountName() { + return accountName; + } + + public Long getDomainId() { + return domainId; + } + + public Long getProjectId() { + return projectId; + } + + public String getGuestVlanRange() { + return guestVlanRange; + } + + public Long getPhysicalNetworkId() { + return physicalNetworkId; + } + + public Long getZoneId() { + return zoneId; + } + + + ///////////////////////////////////////////////////// + /////////////// API Implementation/////////////////// + ///////////////////////////////////////////////////// + + @Override + public String getCommandName() { + return s_name; + } + + @Override + public long getEntityOwnerId() { + return Account.ACCOUNT_ID_SYSTEM; + } + + @Override + public void execute(){ + Pair, Integer> vlans = _networkService.listDedicatedGuestVlanRanges(this); + ListResponse response = new ListResponse(); + List guestVlanResponses = new ArrayList(); + for (GuestVlan vlan : vlans.first()) { + GuestVlanRangeResponse guestVlanResponse = _responseGenerator.createDedicatedGuestVlanRangeResponse(vlan); + guestVlanResponse.setObjectName("dedicatedguestvlanrange"); + guestVlanResponses.add(guestVlanResponse); + } + + response.setResponses(guestVlanResponses, vlans.second()); + response.setResponseName(getCommandName()); + this.setResponseObject(response); + } + +} diff --git a/api/src/org/apache/cloudstack/api/command/admin/network/ListNetworkIsolationMethodsCmd.java b/api/src/org/apache/cloudstack/api/command/admin/network/ListNetworkIsolationMethodsCmd.java new file mode 100644 index 00000000000..7eef22a78b4 --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/admin/network/ListNetworkIsolationMethodsCmd.java @@ -0,0 +1,58 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.command.admin.network; + +import java.util.ArrayList; +import java.util.List; + +import org.apache.cloudstack.api.APICommand; +import org.apache.cloudstack.api.BaseListCmd; +import org.apache.cloudstack.api.response.IsolationMethodResponse; +import org.apache.cloudstack.api.response.ListResponse; + +import com.cloud.network.Networks; + +@APICommand(name = "listNetworkIsolationMethods", description="Lists supported methods of network isolation", +responseObject=IsolationMethodResponse.class, since="4.2.0") +public class ListNetworkIsolationMethodsCmd extends BaseListCmd{ + + private static final String s_name = "listnetworkisolationmethodsresponse"; + + @Override + public void execute() { + Networks.IsolationType[] methods = _ntwkModel.listNetworkIsolationMethods(); + + ListResponse response = new ListResponse(); + List isolationResponses = new ArrayList(); + if (methods != null) { + for (Networks.IsolationType method : methods) { + IsolationMethodResponse isolationMethod = _responseGenerator.createIsolationMethodResponse(method); + isolationResponses.add(isolationMethod); + } + } + response.setResponses(isolationResponses, methods.length); + response.setResponseName(getCommandName()); + this.setResponseObject(response); + + } + + @Override + public String getCommandName() { + return s_name; + } + +} diff --git a/api/src/org/apache/cloudstack/api/command/admin/network/ReleaseDedicatedGuestVlanRangeCmd.java b/api/src/org/apache/cloudstack/api/command/admin/network/ReleaseDedicatedGuestVlanRangeCmd.java new file mode 100644 index 00000000000..76cb42dab19 --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/admin/network/ReleaseDedicatedGuestVlanRangeCmd.java @@ -0,0 +1,94 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.cloudstack.api.command.admin.network; + +import com.cloud.async.AsyncJob; +import com.cloud.event.EventTypes; +import com.cloud.exception.ResourceInUseException; +import com.cloud.user.Account; +import com.cloud.user.UserContext; +import org.apache.cloudstack.api.*; +import org.apache.cloudstack.api.response.CounterResponse; +import org.apache.cloudstack.api.response.GuestVlanRangeResponse; +import org.apache.cloudstack.api.response.SuccessResponse; +import org.apache.log4j.Logger; + +@APICommand(name = "releaseDedicatedGuestVlanRange", description = "Releases a dedicated guest vlan range to the system", responseObject = SuccessResponse.class) +public class ReleaseDedicatedGuestVlanRangeCmd extends BaseAsyncCmd { + public static final Logger s_logger = Logger.getLogger(ReleaseDedicatedGuestVlanRangeCmd.class.getName()); + private static final String s_name = "releasededicatedguestvlanrangeresponse"; + + // /////////////////////////////////////////////////// + // ////////////// API parameters ///////////////////// + // /////////////////////////////////////////////////// + + @Parameter(name=ApiConstants.ID, type=CommandType.UUID, entityType=GuestVlanRangeResponse.class, + required=true, description="the ID of the dedicated guest vlan range") + private Long id; + + // /////////////////////////////////////////////////// + // ///////////////// Accessors /////////////////////// + // /////////////////////////////////////////////////// + + @Override + public String getCommandName() { + return s_name; + } + + public Long getId() { + return id; + } + + @Override + public AsyncJob.Type getInstanceType() { + return AsyncJob.Type.DedicatedGuestVlanRange; + } + + @Override + public long getEntityOwnerId() { + return Account.ACCOUNT_ID_SYSTEM; + } + + @Override + public String getEventType() { + return EventTypes.EVENT_DEDICATED_GUEST_VLAN_RANGE_RELEASE; + } + + @Override + public String getEventDescription() { + return "Releasing a dedicated guest vlan range."; + } + + // /////////////////////////////////////////////////// + // ///////////// API Implementation/////////////////// + // /////////////////////////////////////////////////// + + + @Override + public void execute(){ + UserContext.current().setEventDetails("Dedicated guest vlan range Id: " + id); + boolean result = _networkService.releaseDedicatedGuestVlanRange(getId()); + if (result) { + SuccessResponse response = new SuccessResponse(getCommandName()); + this.setResponseObject(response); + } else { + throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to release dedicated guest vlan range"); + } + } + +} diff --git a/api/src/org/apache/cloudstack/api/command/admin/router/CreateVirtualRouterElementCmd.java b/api/src/org/apache/cloudstack/api/command/admin/router/CreateVirtualRouterElementCmd.java index 39fac136233..b3fca5addf1 100644 --- a/api/src/org/apache/cloudstack/api/command/admin/router/CreateVirtualRouterElementCmd.java +++ b/api/src/org/apache/cloudstack/api/command/admin/router/CreateVirtualRouterElementCmd.java @@ -31,6 +31,7 @@ import org.apache.cloudstack.api.response.VirtualRouterProviderResponse; import org.apache.log4j.Logger; import com.cloud.event.EventTypes; +import com.cloud.exception.InvalidParameterValueException; import com.cloud.exception.ResourceAllocationException; import com.cloud.network.VirtualRouterProvider; import com.cloud.network.VirtualRouterProvider.VirtualRouterProviderType; @@ -52,6 +53,9 @@ public class CreateVirtualRouterElementCmd extends BaseAsyncCreateCmd { @Parameter(name=ApiConstants.NETWORK_SERVICE_PROVIDER_ID, type=CommandType.UUID, entityType = ProviderResponse.class, required=true, description="the network service provider ID of the virtual router element") private Long nspId; + + @Parameter(name=ApiConstants.PROVIDER_TYPE, type=CommandType.UUID, entityType = ProviderResponse.class, description="The provider type. Supported types are VirtualRouter (default) and VPCVirtualRouter") + private String providerType; ///////////////////////////////////////////////////// /////////////////// Accessors /////////////////////// @@ -61,16 +65,27 @@ public class CreateVirtualRouterElementCmd extends BaseAsyncCreateCmd { this.nspId = nspId; } - - public Long getNspId() { return nspId; } + + public VirtualRouterProviderType getProviderType() { + if (providerType != null) { + if (providerType.equalsIgnoreCase(VirtualRouterProviderType.VirtualRouter.toString())) { + return VirtualRouterProviderType.VirtualRouter; + } else if (providerType.equalsIgnoreCase(VirtualRouterProviderType.VPCVirtualRouter.toString())) { + return VirtualRouterProviderType.VPCVirtualRouter; + } else throw new InvalidParameterValueException("Invalid providerType specified"); + } + return VirtualRouterProviderType.VirtualRouter; + } ///////////////////////////////////////////////////// /////////////// API Implementation/////////////////// ///////////////////////////////////////////////////// + + @Override public String getCommandName() { return s_name; @@ -96,7 +111,7 @@ public class CreateVirtualRouterElementCmd extends BaseAsyncCreateCmd { @Override public void create() throws ResourceAllocationException { - VirtualRouterProvider result = _service.get(0).addElement(getNspId(), VirtualRouterProviderType.VirtualRouter); + VirtualRouterProvider result = _service.get(0).addElement(getNspId(), getProviderType()); if (result != null) { setEntityId(result.getId()); setEntityUuid(result.getUuid()); diff --git a/api/src/org/apache/cloudstack/api/command/admin/router/ListRoutersCmd.java b/api/src/org/apache/cloudstack/api/command/admin/router/ListRoutersCmd.java index 9fbc9401532..78c3554ae73 100644 --- a/api/src/org/apache/cloudstack/api/command/admin/router/ListRoutersCmd.java +++ b/api/src/org/apache/cloudstack/api/command/admin/router/ListRoutersCmd.java @@ -31,6 +31,7 @@ import org.apache.cloudstack.api.response.ZoneResponse; import org.apache.log4j.Logger; import com.cloud.async.AsyncJob; +import com.cloud.network.router.VirtualRouter.Role; @APICommand(name = "listRouters", description="List routers.", responseObject=DomainRouterResponse.class) public class ListRoutersCmd extends BaseListProjectAndAccountResourcesCmd { @@ -77,7 +78,7 @@ public class ListRoutersCmd extends BaseListProjectAndAccountResourcesCmd { @Parameter(name=ApiConstants.FOR_VPC, type=CommandType.BOOLEAN, description="if true is passed for this parameter, list only VPC routers") private Boolean forVpc; - + ///////////////////////////////////////////////////// /////////////////// Accessors /////////////////////// ///////////////////////////////////////////////////// @@ -121,6 +122,10 @@ public class ListRoutersCmd extends BaseListProjectAndAccountResourcesCmd { public Boolean getForVpc() { return forVpc; } + + public String getRole() { + return Role.VIRTUAL_ROUTER.toString(); + } ///////////////////////////////////////////////////// /////////////// API Implementation/////////////////// diff --git a/api/src/org/apache/cloudstack/api/command/admin/router/StartRouterCmd.java b/api/src/org/apache/cloudstack/api/command/admin/router/StartRouterCmd.java index 1d3930b6b63..ad0461e0eb7 100644 --- a/api/src/org/apache/cloudstack/api/command/admin/router/StartRouterCmd.java +++ b/api/src/org/apache/cloudstack/api/command/admin/router/StartRouterCmd.java @@ -29,8 +29,10 @@ import com.cloud.async.AsyncJob; import com.cloud.event.EventTypes; import com.cloud.exception.ConcurrentOperationException; import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.InvalidParameterValueException; import com.cloud.exception.ResourceUnavailableException; import com.cloud.network.router.VirtualRouter; +import com.cloud.network.router.VirtualRouter.Role; import com.cloud.user.Account; import com.cloud.user.UserContext; @@ -100,7 +102,13 @@ public class StartRouterCmd extends BaseAsyncCmd { @Override public void execute() throws ConcurrentOperationException, ResourceUnavailableException, InsufficientCapacityException{ UserContext.current().setEventDetails("Router Id: "+getId()); - VirtualRouter result = _routerService.startRouter(id); + VirtualRouter result = null; + VirtualRouter router = _routerService.findRouter(getId()); + if (router == null || router.getRole() != Role.VIRTUAL_ROUTER) { + throw new InvalidParameterValueException("Can't find router by id"); + } else { + result = _routerService.startRouter(getId()); + } if (result != null){ DomainRouterResponse routerResponse = _responseGenerator.createDomainRouterResponse(result); routerResponse.setResponseName(getCommandName()); diff --git a/api/src/org/apache/cloudstack/api/command/admin/router/StopRouterCmd.java b/api/src/org/apache/cloudstack/api/command/admin/router/StopRouterCmd.java index 60dd9386c75..94473cf9ffc 100644 --- a/api/src/org/apache/cloudstack/api/command/admin/router/StopRouterCmd.java +++ b/api/src/org/apache/cloudstack/api/command/admin/router/StopRouterCmd.java @@ -28,8 +28,10 @@ import org.apache.log4j.Logger; import com.cloud.async.AsyncJob; import com.cloud.event.EventTypes; import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InvalidParameterValueException; import com.cloud.exception.ResourceUnavailableException; import com.cloud.network.router.VirtualRouter; +import com.cloud.network.router.VirtualRouter.Role; import com.cloud.user.Account; import com.cloud.user.UserContext; @@ -103,7 +105,14 @@ public class StopRouterCmd extends BaseAsyncCmd { @Override public void execute() throws ConcurrentOperationException, ResourceUnavailableException { UserContext.current().setEventDetails("Router Id: "+getId()); - VirtualRouter result = _routerService.stopRouter(getId(), isForced()); + VirtualRouter result = null; + VirtualRouter router = _routerService.findRouter(getId()); + if (router == null || router.getRole() != Role.VIRTUAL_ROUTER) { + throw new InvalidParameterValueException("Can't find router by id"); + } else { + result = _routerService.stopRouter(getId(), isForced()); + } + if (result != null) { DomainRouterResponse response = _responseGenerator.createDomainRouterResponse(result); response.setResponseName(getCommandName()); diff --git a/api/src/org/apache/cloudstack/api/command/admin/vpc/CreatePrivateGatewayCmd.java b/api/src/org/apache/cloudstack/api/command/admin/vpc/CreatePrivateGatewayCmd.java index 9fd736f8543..20556957ff2 100644 --- a/api/src/org/apache/cloudstack/api/command/admin/vpc/CreatePrivateGatewayCmd.java +++ b/api/src/org/apache/cloudstack/api/command/admin/vpc/CreatePrivateGatewayCmd.java @@ -69,6 +69,11 @@ public class CreatePrivateGatewayCmd extends BaseAsyncCreateCmd { required=true, description="the VPC network belongs to") private Long vpcId; + @Parameter(name=ApiConstants.SOURCE_NAT_SUPPORTED, type=CommandType.BOOLEAN, required=false, + description="source NAT supported value. Default value false. If 'true' source NAT is enabled on the private gateway" + + " 'false': sourcenat is not supported") + private Boolean isSourceNat; + ///////////////////////////////////////////////////// /////////////////// Accessors /////////////////////// ///////////////////////////////////////////////////// @@ -97,6 +102,13 @@ public class CreatePrivateGatewayCmd extends BaseAsyncCreateCmd { return vpcId; } + public Boolean getIsSourceNat () { + if (isSourceNat == null) { + return false; + } + return true; + } + ///////////////////////////////////////////////////// /////////////// API Implementation/////////////////// ///////////////////////////////////////////////////// @@ -111,7 +123,7 @@ public class CreatePrivateGatewayCmd extends BaseAsyncCreateCmd { PrivateGateway result = null; try { result = _vpcService.createVpcPrivateGateway(getVpcId(), getPhysicalNetworkId(), - getVlan(), getStartIp(), getGateway(), getNetmask(), getEntityOwnerId()); + getVlan(), getStartIp(), getGateway(), getNetmask(), getEntityOwnerId(), getIsSourceNat()); } catch (InsufficientCapacityException ex){ s_logger.info(ex); s_logger.trace(ex); diff --git a/api/src/org/apache/cloudstack/api/command/user/loadbalancer/CreateApplicationLoadBalancerCmd.java b/api/src/org/apache/cloudstack/api/command/user/loadbalancer/CreateApplicationLoadBalancerCmd.java new file mode 100644 index 00000000000..17ae959aa6e --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/user/loadbalancer/CreateApplicationLoadBalancerCmd.java @@ -0,0 +1,218 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.command.user.loadbalancer; + +import org.apache.cloudstack.api.APICommand; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.ApiErrorCode; +import org.apache.cloudstack.api.BaseAsyncCreateCmd; +import org.apache.cloudstack.api.Parameter; +import org.apache.cloudstack.api.ServerApiException; +import org.apache.cloudstack.api.response.ApplicationLoadBalancerResponse; +import org.apache.cloudstack.api.response.NetworkResponse; +import org.apache.cloudstack.network.lb.ApplicationLoadBalancerRule; +import org.apache.log4j.Logger; + +import com.cloud.async.AsyncJob; +import com.cloud.event.EventTypes; +import com.cloud.exception.InsufficientAddressCapacityException; +import com.cloud.exception.InsufficientVirtualNetworkCapcityException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.NetworkRuleConflictException; +import com.cloud.exception.ResourceAllocationException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.Network; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.user.UserContext; +import com.cloud.utils.net.NetUtils; + +@APICommand(name = "createLoadBalancer", description="Creates a Load Balancer", responseObject=ApplicationLoadBalancerResponse.class, since="4.2.0") +public class CreateApplicationLoadBalancerCmd extends BaseAsyncCreateCmd { + public static final Logger s_logger = Logger.getLogger(CreateApplicationLoadBalancerCmd.class.getName()); + + private static final String s_name = "createloadbalancerresponse"; + + ///////////////////////////////////////////////////// + //////////////// API parameters ///////////////////// + ///////////////////////////////////////////////////// + @Parameter(name=ApiConstants.NAME, type=CommandType.STRING, required=true, description="name of the Load Balancer") + private String loadBalancerName; + + @Parameter(name=ApiConstants.DESCRIPTION, type=CommandType.STRING, description="the description of the Load Balancer", length=4096) + private String description; + + @Parameter(name=ApiConstants.NETWORK_ID, type=CommandType.UUID, required=true, entityType = NetworkResponse.class, + description="The guest network the Load Balancer will be created for") + private Long networkId; + + @Parameter(name=ApiConstants.SOURCE_PORT, type=CommandType.INTEGER, required=true, description="the source port the network traffic will be load balanced from") + private Integer sourcePort; + + @Parameter(name=ApiConstants.ALGORITHM, type=CommandType.STRING, required=true, description="load balancer algorithm (source, roundrobin, leastconn)") + private String algorithm; + + @Parameter(name=ApiConstants.INSTANCE_PORT, type=CommandType.INTEGER, required=true, description="the TCP port of the virtual machine where the network traffic will be load balanced to") + private Integer instancePort; + + @Parameter(name=ApiConstants.SOURCE_IP, type=CommandType.STRING, description="the source ip address the network traffic will be load balanced from") + private String sourceIp; + + @Parameter(name=ApiConstants.SOURCE_IP_NETWORK_ID, type=CommandType.UUID, entityType = NetworkResponse.class, required=true, + description="the network id of the source ip address") + private Long sourceIpNetworkId; + + @Parameter(name=ApiConstants.SCHEME, type=CommandType.STRING, required=true, description="the load balancer scheme. Supported value in this release is Internal") + private String scheme; + + + + ///////////////////////////////////////////////////// + /////////////////// Accessors /////////////////////// + ///////////////////////////////////////////////////// + + public String getAlgorithm() { + return algorithm; + } + + public String getDescription() { + return description; + } + + public String getLoadBalancerName() { + return loadBalancerName; + } + + public Integer getPrivatePort() { + return instancePort; + } + + public long getNetworkId() { + return networkId; + } + + public String getName() { + return loadBalancerName; + } + + public Integer getSourcePort() { + return sourcePort.intValue(); + } + + public String getProtocol() { + return NetUtils.TCP_PROTO; + } + + public long getAccountId() { + //get account info from the network object + Network ntwk = _networkService.getNetwork(networkId); + if (ntwk == null) { + throw new InvalidParameterValueException("Invalid network id specified"); + } + + return ntwk.getAccountId(); + + } + + public int getInstancePort() { + return instancePort.intValue(); + } + + @Override + public String getEventType() { + return EventTypes.EVENT_LOAD_BALANCER_CREATE; + } + + @Override + public String getEventDescription() { + return "creating load balancer: " + getName() + " account: " + getAccountId(); + + } + + @Override + public AsyncJob.Type getInstanceType() { + return AsyncJob.Type.LoadBalancerRule; + } + + public String getSourceIp() { + return sourceIp; + } + + public long getSourceIpNetworkId() { + return sourceIpNetworkId; + } + + public Scheme getScheme() { + if (scheme.equalsIgnoreCase(Scheme.Internal.toString())) { + return Scheme.Internal; + } else { + throw new InvalidParameterValueException("Invalid value for scheme. Supported value is Internal"); + } + } + + @Override + public long getEntityOwnerId() { + return getAccountId(); + } + + ///////////////////////////////////////////////////// + /////////////// API Implementation/////////////////// + ///////////////////////////////////////////////////// + @Override + public String getCommandName() { + return s_name; + } + + @Override + public void execute() throws ResourceAllocationException, ResourceUnavailableException { + ApplicationLoadBalancerRule rule = null; + try { + UserContext.current().setEventDetails("Load Balancer Id: " + getEntityId()); + // State might be different after the rule is applied, so get new object here + rule = _entityMgr.findById(ApplicationLoadBalancerRule.class, getEntityId()); + ApplicationLoadBalancerResponse lbResponse = _responseGenerator.createLoadBalancerContainerReponse(rule, _lbService.getLbInstances(getEntityId())); + setResponseObject(lbResponse); + lbResponse.setResponseName(getCommandName()); + } catch (Exception ex) { + s_logger.warn("Failed to create Load Balancer due to exception ", ex); + } finally { + if (rule == null) { + throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to create Load Balancer"); + } + } + } + + @Override + public void create() { + try { + + ApplicationLoadBalancerRule result = _appLbService.createApplicationLoadBalancer(getName(), getDescription(), getScheme(), + getSourceIpNetworkId(), getSourceIp(), getSourcePort(), getInstancePort(), getAlgorithm(), getNetworkId(), getEntityOwnerId()); + this.setEntityId(result.getId()); + this.setEntityUuid(result.getUuid()); + }catch (NetworkRuleConflictException e) { + s_logger.warn("Exception: ", e); + throw new ServerApiException(ApiErrorCode.NETWORK_RULE_CONFLICT_ERROR, e.getMessage()); + } catch (InsufficientAddressCapacityException e) { + s_logger.warn("Exception: ", e); + throw new ServerApiException(ApiErrorCode.INSUFFICIENT_CAPACITY_ERROR, e.getMessage()); + } catch (InsufficientVirtualNetworkCapcityException e) { + s_logger.warn("Exception: ", e); + throw new ServerApiException(ApiErrorCode.INSUFFICIENT_CAPACITY_ERROR, e.getMessage()); + } + } +} + diff --git a/api/src/org/apache/cloudstack/api/command/user/loadbalancer/CreateLoadBalancerRuleCmd.java b/api/src/org/apache/cloudstack/api/command/user/loadbalancer/CreateLoadBalancerRuleCmd.java index 5f1d97b2803..f6cc1f130bd 100644 --- a/api/src/org/apache/cloudstack/api/command/user/loadbalancer/CreateLoadBalancerRuleCmd.java +++ b/api/src/org/apache/cloudstack/api/command/user/loadbalancer/CreateLoadBalancerRuleCmd.java @@ -148,7 +148,7 @@ public class CreateLoadBalancerRuleCmd extends BaseAsyncCreateCmd /*implements } - public Long getNetworkId() { + public long getNetworkId() { if (networkId != null) { return networkId; } @@ -278,7 +278,9 @@ public class CreateLoadBalancerRuleCmd extends BaseAsyncCreateCmd /*implements throw new InvalidParameterValueException("Parameter cidrList is deprecated; if you need to open firewall rule for the specific cidr, please refer to createFirewallRule command"); } try { - LoadBalancer result = _lbService.createLoadBalancerRule(this, getOpenFirewall()); + LoadBalancer result = _lbService.createPublicLoadBalancerRule(getXid(), getName(), getDescription(), + getSourcePortStart(), getSourcePortEnd(), getDefaultPortStart(), getDefaultPortEnd(), getSourceIpAddressId(), getProtocol(), getAlgorithm(), + getNetworkId(), getEntityOwnerId(), getOpenFirewall()); this.setEntityId(result.getId()); this.setEntityUuid(result.getUuid()); } catch (NetworkRuleConflictException e) { diff --git a/api/src/org/apache/cloudstack/api/command/user/loadbalancer/DeleteApplicationLoadBalancerCmd.java b/api/src/org/apache/cloudstack/api/command/user/loadbalancer/DeleteApplicationLoadBalancerCmd.java new file mode 100644 index 00000000000..bc6cd09526c --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/user/loadbalancer/DeleteApplicationLoadBalancerCmd.java @@ -0,0 +1,116 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.command.user.loadbalancer; + +import org.apache.cloudstack.api.APICommand; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.ApiErrorCode; +import org.apache.cloudstack.api.BaseAsyncCmd; +import org.apache.cloudstack.api.Parameter; +import org.apache.cloudstack.api.ServerApiException; +import org.apache.cloudstack.api.response.FirewallRuleResponse; +import org.apache.cloudstack.api.response.SuccessResponse; +import org.apache.cloudstack.network.lb.ApplicationLoadBalancerRule; +import org.apache.log4j.Logger; + +import com.cloud.async.AsyncJob; +import com.cloud.event.EventTypes; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.user.UserContext; + +@APICommand(name = "deleteLoadBalancer", description="Deletes a load balancer", responseObject=SuccessResponse.class, since="4.2.0") +public class DeleteApplicationLoadBalancerCmd extends BaseAsyncCmd { + public static final Logger s_logger = Logger.getLogger(DeleteApplicationLoadBalancerCmd.class.getName()); + private static final String s_name = "deleteloadbalancerresponse"; + ///////////////////////////////////////////////////// + //////////////// API parameters ///////////////////// + ///////////////////////////////////////////////////// + + @Parameter(name=ApiConstants.ID, type=CommandType.UUID, entityType = FirewallRuleResponse.class, + required=true, description="the ID of the Load Balancer") + private Long id; + + + ///////////////////////////////////////////////////// + /////////////////// Accessors /////////////////////// + ///////////////////////////////////////////////////// + + public Long getId() { + return id; + } + + ///////////////////////////////////////////////////// + /////////////// API Implementation/////////////////// + ///////////////////////////////////////////////////// + + @Override + public String getCommandName() { + return s_name; + } + + @Override + public long getEntityOwnerId() { + ApplicationLoadBalancerRule lb = _entityMgr.findById(ApplicationLoadBalancerRule.class, getId()); + if (lb != null) { + return lb.getAccountId(); + } else { + throw new InvalidParameterValueException("Can't find load balancer by id specified"); + } + } + + @Override + public String getEventType() { + return EventTypes.EVENT_LOAD_BALANCER_DELETE; + } + + @Override + public String getEventDescription() { + return "deleting load balancer: " + getId(); + } + + @Override + public void execute(){ + UserContext.current().setEventDetails("Load balancer Id: " + getId()); + boolean result = _appLbService.deleteApplicationLoadBalancer(getId()); + + if (result) { + SuccessResponse response = new SuccessResponse(getCommandName()); + this.setResponseObject(response); + } else { + throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to delete load balancer"); + } + } + + @Override + public String getSyncObjType() { + return BaseAsyncCmd.networkSyncObject; + } + + @Override + public Long getSyncObjId() { + ApplicationLoadBalancerRule lb = _appLbService.getApplicationLoadBalancer(id); + if(lb == null){ + throw new InvalidParameterValueException("Unable to find load balancer by id "); + } + return lb.getNetworkId(); + } + + @Override + public AsyncJob.Type getInstanceType() { + return AsyncJob.Type.FirewallRule; + } +} diff --git a/api/src/org/apache/cloudstack/api/command/user/loadbalancer/ListApplicationLoadBalancersCmd.java b/api/src/org/apache/cloudstack/api/command/user/loadbalancer/ListApplicationLoadBalancersCmd.java new file mode 100644 index 00000000000..8e5df31ed29 --- /dev/null +++ b/api/src/org/apache/cloudstack/api/command/user/loadbalancer/ListApplicationLoadBalancersCmd.java @@ -0,0 +1,131 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.command.user.loadbalancer; + +import java.util.ArrayList; +import java.util.List; + +import org.apache.cloudstack.api.APICommand; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.BaseListTaggedResourcesCmd; +import org.apache.cloudstack.api.Parameter; +import org.apache.cloudstack.api.response.ApplicationLoadBalancerResponse; +import org.apache.cloudstack.api.response.FirewallRuleResponse; +import org.apache.cloudstack.api.response.ListResponse; +import org.apache.cloudstack.api.response.NetworkResponse; +import org.apache.cloudstack.network.lb.ApplicationLoadBalancerRule; +import org.apache.log4j.Logger; + +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.utils.Pair; + +@APICommand(name = "listLoadBalancers", description = "Lists Load Balancers", responseObject = ApplicationLoadBalancerResponse.class, since="4.2.0") +public class ListApplicationLoadBalancersCmd extends BaseListTaggedResourcesCmd { + public static final Logger s_logger = Logger.getLogger(ListApplicationLoadBalancersCmd.class.getName()); + + private static final String s_name = "listloadbalancerssresponse"; + + // /////////////////////////////////////////////////// + // ////////////// API parameters ///////////////////// + // /////////////////////////////////////////////////// + + @Parameter(name = ApiConstants.ID, type = CommandType.UUID, entityType = FirewallRuleResponse.class, + description = "the ID of the Load Balancer") + private Long id; + + @Parameter(name = ApiConstants.NAME, type = CommandType.STRING, description = "the name of the Load Balancer") + private String loadBalancerName; + + @Parameter(name = ApiConstants.SOURCE_IP, type = CommandType.STRING, description = "the source ip address of the Load Balancer") + private String sourceIp; + + @Parameter(name=ApiConstants.SOURCE_IP_NETWORK_ID, type=CommandType.UUID, entityType = NetworkResponse.class, + description="the network id of the source ip address") + private Long sourceIpNetworkId; + + @Parameter(name = ApiConstants.SCHEME, type = CommandType.STRING, description = "the scheme of the Load Balancer. Supported value is Internal in the current release") + private String scheme; + + @Parameter(name=ApiConstants.NETWORK_ID, type=CommandType.UUID, entityType = NetworkResponse.class, + description="the network id of the Load Balancer") + private Long networkId; + + + // /////////////////////////////////////////////////// + // ///////////////// Accessors /////////////////////// + // /////////////////////////////////////////////////// + + public Long getId() { + return id; + } + + public String getLoadBalancerRuleName() { + return loadBalancerName; + } + + public String getLoadBalancerName() { + return loadBalancerName; + } + + public String getSourceIp() { + return sourceIp; + } + + public Long getSourceIpNetworkId() { + return sourceIpNetworkId; + } + + @Override + public String getCommandName() { + return s_name; + } + + public Scheme getScheme() { + if (scheme != null) { + if (scheme.equalsIgnoreCase(Scheme.Internal.toString())) { + return Scheme.Internal; + } else { + throw new InvalidParameterValueException("Invalid value for scheme. Supported value is Internal"); + } + } + return null; + } + + public Long getNetworkId() { + return networkId; + } + // /////////////////////////////////////////////////// + // ///////////// API Implementation/////////////////// + // /////////////////////////////////////////////////// + + @Override + public void execute() { + Pair, Integer> loadBalancers = _appLbService.listApplicationLoadBalancers(this); + ListResponse response = new ListResponse(); + List lbResponses = new ArrayList(); + for (ApplicationLoadBalancerRule loadBalancer : loadBalancers.first()) { + ApplicationLoadBalancerResponse lbResponse = _responseGenerator.createLoadBalancerContainerReponse(loadBalancer, _lbService.getLbInstances(loadBalancer.getId())); + lbResponse.setObjectName("loadbalancer"); + lbResponses.add(lbResponse); + } + response.setResponses(lbResponses, loadBalancers.second()); + response.setResponseName(getCommandName()); + this.setResponseObject(response); + } + +} diff --git a/api/src/org/apache/cloudstack/api/command/user/nat/EnableStaticNatCmd.java b/api/src/org/apache/cloudstack/api/command/user/nat/EnableStaticNatCmd.java index a0ec68ef5dd..902dbae00aa 100644 --- a/api/src/org/apache/cloudstack/api/command/user/nat/EnableStaticNatCmd.java +++ b/api/src/org/apache/cloudstack/api/command/user/nat/EnableStaticNatCmd.java @@ -120,7 +120,7 @@ public class EnableStaticNatCmd extends BaseCmd{ @Override public void execute() throws ResourceUnavailableException{ try { - boolean result = _rulesService.enableStaticNat(ipAddressId, virtualMachineId, getNetworkId(), false, getVmSecondaryIp()); + boolean result = _rulesService.enableStaticNat(ipAddressId, virtualMachineId, getNetworkId(), getVmSecondaryIp()); if (result) { SuccessResponse response = new SuccessResponse(getCommandName()); this.setResponseObject(response); diff --git a/api/src/org/apache/cloudstack/api/command/user/snapshot/CreateSnapshotCmd.java b/api/src/org/apache/cloudstack/api/command/user/snapshot/CreateSnapshotCmd.java index 95d76599f70..0b33f568d8a 100644 --- a/api/src/org/apache/cloudstack/api/command/user/snapshot/CreateSnapshotCmd.java +++ b/api/src/org/apache/cloudstack/api/command/user/snapshot/CreateSnapshotCmd.java @@ -163,6 +163,7 @@ public class CreateSnapshotCmd extends BaseAsyncCreateCmd { @Override public void execute() { + s_logger.info("VOLSS: createSnapshotCmd starts:" + System.currentTimeMillis()); UserContext.current().setEventDetails("Volume Id: "+getVolumeId()); Snapshot snapshot = _snapshotService.createSnapshot(getVolumeId(), getPolicyId(), getEntityId(), _accountService.getAccount(getEntityOwnerId())); if (snapshot != null) { @@ -172,6 +173,7 @@ public class CreateSnapshotCmd extends BaseAsyncCreateCmd { } else { throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to create snapshot due to an internal error creating snapshot for volume " + volumeId); } + s_logger.info("VOLSS: backupSnapshotCmd finishes:" + System.currentTimeMillis()); } diff --git a/api/src/org/apache/cloudstack/api/command/user/vm/ScaleVMCmd.java b/api/src/org/apache/cloudstack/api/command/user/vm/ScaleVMCmd.java index 4fc65c37e58..4f2ac750ce5 100644 --- a/api/src/org/apache/cloudstack/api/command/user/vm/ScaleVMCmd.java +++ b/api/src/org/apache/cloudstack/api/command/user/vm/ScaleVMCmd.java @@ -22,11 +22,12 @@ import com.cloud.user.UserContext; import com.cloud.uservm.UserVm; import org.apache.cloudstack.api.*; import org.apache.cloudstack.api.response.ServiceOfferingResponse; +import org.apache.cloudstack.api.response.SuccessResponse; import org.apache.cloudstack.api.response.UserVmResponse; import org.apache.log4j.Logger; -@APICommand(name = "scaleVirtualMachine", description="Scales the virtual machine to a new service offering.", responseObject=UserVmResponse.class) +@APICommand(name = "scaleVirtualMachine", description="Scales the virtual machine to a new service offering.", responseObject=SuccessResponse.class) public class ScaleVMCmd extends BaseCmd { public static final Logger s_logger = Logger.getLogger(ScaleVMCmd.class.getName()); private static final String s_name = "scalevirtualmachineresponse"; @@ -83,7 +84,7 @@ public class ScaleVMCmd extends BaseCmd { @Override public void execute(){ //UserContext.current().setEventDetails("Vm Id: "+getId()); - UserVm result = null; + boolean result; try { result = _userVmService.upgradeVirtualMachine(this); } catch (ResourceUnavailableException ex) { @@ -99,9 +100,8 @@ public class ScaleVMCmd extends BaseCmd { s_logger.warn("Exception: ", ex); throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, ex.getMessage()); } - if (result != null){ - UserVmResponse response = _responseGenerator.createUserVmResponse("virtualmachine", result).get(0); - response.setResponseName(getCommandName()); + if (result){ + SuccessResponse response = new SuccessResponse(getCommandName()); this.setResponseObject(response); } else { throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to scale vm"); diff --git a/api/src/org/apache/cloudstack/api/command/user/vmsnapshot/RevertToSnapshotCmd.java b/api/src/org/apache/cloudstack/api/command/user/vmsnapshot/RevertToVMSnapshotCmd.java similarity index 91% rename from api/src/org/apache/cloudstack/api/command/user/vmsnapshot/RevertToSnapshotCmd.java rename to api/src/org/apache/cloudstack/api/command/user/vmsnapshot/RevertToVMSnapshotCmd.java index ea7bf60d6a3..f6d8b2c4a35 100644 --- a/api/src/org/apache/cloudstack/api/command/user/vmsnapshot/RevertToSnapshotCmd.java +++ b/api/src/org/apache/cloudstack/api/command/user/vmsnapshot/RevertToVMSnapshotCmd.java @@ -37,11 +37,11 @@ import com.cloud.user.UserContext; import com.cloud.uservm.UserVm; import com.cloud.vm.snapshot.VMSnapshot; -@APICommand(name = "revertToSnapshot",description = "Revert VM from a vmsnapshot.", responseObject = UserVmResponse.class, since="4.2.0") -public class RevertToSnapshotCmd extends BaseAsyncCmd { +@APICommand(name = "revertToVMSnapshot",description = "Revert VM from a vmsnapshot.", responseObject = UserVmResponse.class, since="4.2.0") +public class RevertToVMSnapshotCmd extends BaseAsyncCmd { public static final Logger s_logger = Logger - .getLogger(RevertToSnapshotCmd.class.getName()); - private static final String s_name = "reverttosnapshotresponse"; + .getLogger(RevertToVMSnapshotCmd.class.getName()); + private static final String s_name = "reverttovmsnapshotresponse"; @Parameter(name = ApiConstants.VM_SNAPSHOT_ID, type = CommandType.UUID, required = true,entityType=VMSnapshotResponse.class,description = "The ID of the vm snapshot") private Long vmSnapShotId; diff --git a/api/src/org/apache/cloudstack/api/response/ApplicationLoadBalancerInstanceResponse.java b/api/src/org/apache/cloudstack/api/response/ApplicationLoadBalancerInstanceResponse.java new file mode 100644 index 00000000000..2d6614d217b --- /dev/null +++ b/api/src/org/apache/cloudstack/api/response/ApplicationLoadBalancerInstanceResponse.java @@ -0,0 +1,63 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.response; + +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.BaseResponse; + +import com.cloud.serializer.Param; +import com.google.gson.annotations.SerializedName; + +/** + * + * Load Balancer instance is the User Vm instance participating in the Load Balancer + * + */ + +@SuppressWarnings("unused") +public class ApplicationLoadBalancerInstanceResponse extends BaseResponse{ + + @SerializedName(ApiConstants.ID) @Param(description = "the instance ID") + private String id; + + @SerializedName(ApiConstants.NAME) @Param(description = "the name of the instance") + private String name; + + @SerializedName(ApiConstants.STATE) @Param(description="the state of the instance") + private String state; + + @SerializedName(ApiConstants.IP_ADDRESS) + @Param(description="the ip address of the instance") + private String ipAddress; + + + public void setId(String id) { + this.id = id; + } + + public void setName(String name) { + this.name = name; + } + + public void setState(String state) { + this.state = state; + } + + public void setIpAddress(String ipAddress) { + this.ipAddress = ipAddress; + } +} diff --git a/api/src/org/apache/cloudstack/api/response/ApplicationLoadBalancerResponse.java b/api/src/org/apache/cloudstack/api/response/ApplicationLoadBalancerResponse.java new file mode 100644 index 00000000000..de9bce6c658 --- /dev/null +++ b/api/src/org/apache/cloudstack/api/response/ApplicationLoadBalancerResponse.java @@ -0,0 +1,142 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.cloudstack.api.response; + +import java.util.LinkedHashSet; +import java.util.List; +import java.util.Set; + +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.BaseResponse; + +import com.cloud.serializer.Param; +import com.google.gson.annotations.SerializedName; + +@SuppressWarnings("unused") +public class ApplicationLoadBalancerResponse extends BaseResponse implements ControlledEntityResponse{ + @SerializedName(ApiConstants.ID) @Param(description = "the Load Balancer ID") + private String id; + + @SerializedName(ApiConstants.NAME) @Param(description = "the name of the Load Balancer") + private String name; + + @SerializedName(ApiConstants.DESCRIPTION) @Param(description = "the description of the Load Balancer") + private String description; + + @SerializedName(ApiConstants.ALGORITHM) @Param(description = "the load balancer algorithm (source, roundrobin, leastconn)") + private String algorithm; + + @SerializedName(ApiConstants.NETWORK_ID) @Param(description="Load Balancer network id") + private String networkId; + + @SerializedName(ApiConstants.SOURCE_IP) @Param(description="Load Balancer source ip") + private String sourceIp; + + @SerializedName(ApiConstants.SOURCE_IP_NETWORK_ID) @Param(description="Load Balancer source ip network id") + private String sourceIpNetworkId; + + @SerializedName(ApiConstants.ACCOUNT) + @Param(description = "the account of the Load Balancer") + private String accountName; + + @SerializedName(ApiConstants.PROJECT_ID) @Param(description="the project id of the Load Balancer") + private String projectId; + + @SerializedName(ApiConstants.PROJECT) @Param(description="the project name of the Load Balancer") + private String projectName; + + @SerializedName(ApiConstants.DOMAIN_ID) + @Param(description = "the domain ID of the Load Balancer") + private String domainId; + + @SerializedName(ApiConstants.DOMAIN) + @Param(description = "the domain of the Load Balancer") + private String domainName; + + @SerializedName("loadbalancerrule") @Param(description="the list of rules associated with the Load Balancer", responseObject = ApplicationLoadBalancerRuleResponse.class) + private List lbRules; + + @SerializedName("loadbalancerinstance") @Param(description="the list of instances associated with the Load Balancer", responseObject = ApplicationLoadBalancerInstanceResponse.class) + private List lbInstances; + + @SerializedName(ApiConstants.TAGS) @Param(description="the list of resource tags associated with the Load Balancer", responseObject = ResourceTagResponse.class) + private List tags; + + public void setAccountName(String accountName) { + this.accountName = accountName; + } + + @Override + public void setDomainId(String domainId) { + this.domainId = domainId; + } + + public void setDomainName(String domainName) { + this.domainName = domainName; + } + + @Override + public void setProjectId(String projectId) { + this.projectId = projectId; + } + + @Override + public void setProjectName(String projectName) { + this.projectName = projectName; + } + + public void setTags(List tags) { + this.tags = tags; + } + + public void setId(String id) { + this.id = id; + } + + public void setName(String name) { + this.name = name; + } + + public void setDescription(String description) { + this.description = description; + } + + public void setAlgorithm(String algorithm) { + this.algorithm = algorithm; + } + + public void setNetworkId(String networkId) { + this.networkId = networkId; + } + + public void setSourceIp(String sourceIp) { + this.sourceIp = sourceIp; + } + + public void setSourceIpNetworkId(String sourceIpNetworkId) { + this.sourceIpNetworkId = sourceIpNetworkId; + } + + public void setLbRules(List lbRules) { + this.lbRules = lbRules; + } + + public void setLbInstances(List lbInstances) { + this.lbInstances = lbInstances; + } +} diff --git a/api/src/org/apache/cloudstack/api/response/ApplicationLoadBalancerRuleResponse.java b/api/src/org/apache/cloudstack/api/response/ApplicationLoadBalancerRuleResponse.java new file mode 100644 index 00000000000..ffc64d5ca46 --- /dev/null +++ b/api/src/org/apache/cloudstack/api/response/ApplicationLoadBalancerRuleResponse.java @@ -0,0 +1,51 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.cloudstack.api.response; + +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.BaseResponse; + +import com.cloud.serializer.Param; +import com.google.gson.annotations.SerializedName; + +/** + * Subobject of the load balancer container response + */ +@SuppressWarnings("unused") +public class ApplicationLoadBalancerRuleResponse extends BaseResponse{ + @SerializedName(ApiConstants.SOURCE_PORT) @Param(description = "source port of the load balancer rule") + private Integer sourcePort; + + @SerializedName(ApiConstants.INSTANCE_PORT) @Param(description = "instance port of the load balancer rule") + private Integer instancePort; + + @SerializedName(ApiConstants.STATE) @Param(description = "the state of the load balancer rule") + private String state; + + public void setSourcePort(Integer sourcePort) { + this.sourcePort = sourcePort; + } + + public void setInstancePort(Integer instancePort) { + this.instancePort = instancePort; + } + + public void setState(String state) { + this.state = state; + } +} diff --git a/api/src/org/apache/cloudstack/api/response/ConfigurationResponse.java b/api/src/org/apache/cloudstack/api/response/ConfigurationResponse.java index 176c47aff8b..fa0d4b45475 100644 --- a/api/src/org/apache/cloudstack/api/response/ConfigurationResponse.java +++ b/api/src/org/apache/cloudstack/api/response/ConfigurationResponse.java @@ -35,6 +35,9 @@ public class ConfigurationResponse extends BaseResponse { @SerializedName(ApiConstants.SCOPE) @Param(description="scope(zone/cluster/pool/account) of the parameter that needs to be updated") private String scope; + @SerializedName(ApiConstants.ID) @Param(description="the value of the configuration") + private Long id; + @SerializedName(ApiConstants.DESCRIPTION) @Param(description="the description of the configuration") private String description; diff --git a/api/src/org/apache/cloudstack/api/response/DomainRouterResponse.java b/api/src/org/apache/cloudstack/api/response/DomainRouterResponse.java index 79c8596a8d1..852d98815a3 100644 --- a/api/src/org/apache/cloudstack/api/response/DomainRouterResponse.java +++ b/api/src/org/apache/cloudstack/api/response/DomainRouterResponse.java @@ -153,8 +153,11 @@ public class DomainRouterResponse extends BaseResponse implements ControlledView @SerializedName("scriptsversion") @Param(description="the version of scripts") private String scriptsVersion; - @SerializedName(ApiConstants.VPC_ID) @Param(description="VPC the network belongs to") + @SerializedName(ApiConstants.VPC_ID) @Param(description="VPC the router belongs to") private String vpcId; + + @SerializedName(ApiConstants.ROLE) @Param(description="role of the domain router") + private String role; @SerializedName("nic") @Param(description="the list of nics associated with the router", responseObject = NicResponse.class, since="4.0") @@ -164,15 +167,11 @@ public class DomainRouterResponse extends BaseResponse implements ControlledView nics = new LinkedHashSet(); } - - @Override public String getObjectId() { return this.getId(); } - - public String getId() { return id; } @@ -372,4 +371,8 @@ public class DomainRouterResponse extends BaseResponse implements ControlledView public void setIp6Dns2(String ip6Dns2) { this.ip6Dns2 = ip6Dns2; } + + public void setRole(String role) { + this.role = role; + } } diff --git a/api/src/org/apache/cloudstack/api/response/GuestVlanRangeResponse.java b/api/src/org/apache/cloudstack/api/response/GuestVlanRangeResponse.java new file mode 100644 index 00000000000..bf19688c13f --- /dev/null +++ b/api/src/org/apache/cloudstack/api/response/GuestVlanRangeResponse.java @@ -0,0 +1,94 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.response; + +import com.cloud.serializer.Param; +import com.google.gson.annotations.SerializedName; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.BaseResponse; +import org.apache.cloudstack.api.EntityReference; + +import com.cloud.network.GuestVlan; + +@EntityReference(value=GuestVlan.class) +@SuppressWarnings("unused") +public class GuestVlanRangeResponse extends BaseResponse implements ControlledEntityResponse { + @SerializedName(ApiConstants.ID) @Param(description="the ID of the guest VLAN range") + private String id; + + @SerializedName(ApiConstants.ACCOUNT) @Param(description="the account of the guest VLAN range") + private String accountName; + + @SerializedName(ApiConstants.DOMAIN_ID) @Param(description="the domain ID of the guest VLAN range") + private String domainId; + + @SerializedName(ApiConstants.DOMAIN) @Param(description="the domain name of the guest VLAN range") + private String domainName; + + @SerializedName(ApiConstants.GUEST_VLAN_RANGE) @Param(description="the guest VLAN range") + private String guestVlanRange; + + @SerializedName(ApiConstants.PROJECT_ID) @Param(description="the project id of the guest vlan range") + private String projectId; + + @SerializedName(ApiConstants.PROJECT) @Param(description="the project name of the guest vlan range") + private String projectName; + + @SerializedName(ApiConstants.PHYSICAL_NETWORK_ID) @Param(description="the physical network of the guest vlan range") + private Long physicalNetworkId; + + @SerializedName(ApiConstants.ZONE_ID) @Param(description="the zone of the guest vlan range") + private Long zoneId; + + + public void setId(String id) { + this.id = id; + } + + public void setAccountName(String accountName) { + this.accountName = accountName; + } + + public void setDomainId(String domainId) { + this.domainId = domainId; + } + + public void setDomainName(String domainName) { + this.domainName = domainName; + } + + public void setGuestVlanRange(String guestVlanRange) { + this.guestVlanRange = guestVlanRange; + } + + public void setProjectId(String projectId) { + this.projectId = projectId; + } + + public void setProjectName(String projectName) { + this.projectName = projectName; + } + + public void setPhysicalNetworkId(Long physicalNetworkId) { + this.physicalNetworkId = physicalNetworkId; + } + + public void setZoneId(Long zoneId) { + this.zoneId = zoneId; + } + +} diff --git a/api/src/org/apache/cloudstack/api/response/InternalLoadBalancerElementResponse.java b/api/src/org/apache/cloudstack/api/response/InternalLoadBalancerElementResponse.java new file mode 100644 index 00000000000..b7e8634ee8f --- /dev/null +++ b/api/src/org/apache/cloudstack/api/response/InternalLoadBalancerElementResponse.java @@ -0,0 +1,51 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.api.response; + +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.BaseResponse; +import org.apache.cloudstack.api.EntityReference; + +import com.cloud.network.VirtualRouterProvider; +import com.cloud.serializer.Param; +import com.google.gson.annotations.SerializedName; + +@EntityReference(value=VirtualRouterProvider.class) +@SuppressWarnings("unused") +public class InternalLoadBalancerElementResponse extends BaseResponse { + @SerializedName(ApiConstants.ID) @Param(description="the id of the internal load balancer element") + private String id; + + @SerializedName(ApiConstants.NSP_ID) @Param(description="the physical network service provider id of the element") + private String nspId; + + @SerializedName(ApiConstants.ENABLED) @Param(description="Enabled/Disabled the element") + private Boolean enabled; + + + public void setId(String id) { + this.id = id; + } + + public void setNspId(String nspId) { + this.nspId = nspId; + } + + public void setEnabled(Boolean enabled) { + this.enabled = enabled; + } +} diff --git a/core/src/com/cloud/agent/RecoveryHandler.java b/api/src/org/apache/cloudstack/api/response/IsolationMethodResponse.java similarity index 59% rename from core/src/com/cloud/agent/RecoveryHandler.java rename to api/src/org/apache/cloudstack/api/response/IsolationMethodResponse.java index 418c7b1034f..3aaa7a4a1ab 100644 --- a/core/src/com/cloud/agent/RecoveryHandler.java +++ b/api/src/org/apache/cloudstack/api/response/IsolationMethodResponse.java @@ -14,18 +14,20 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -package com.cloud.agent; +package org.apache.cloudstack.api.response; -import com.cloud.agent.api.Command; +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.BaseResponse; -public interface RecoveryHandler { - /** - * Perform the necessary recovery because the success of this command - * is not known. - * - * @param agentId agent the commands were sent to. - * @param seq sequence number. - * @param cmds commands that failed. - */ - public void handle(long agentId, long seq, Command[] cmds); +import com.cloud.serializer.Param; +import com.google.gson.annotations.SerializedName; + +@SuppressWarnings("unused") +public class IsolationMethodResponse extends BaseResponse{ + @SerializedName(ApiConstants.NAME) @Param(description="Network isolation method name") + private String name; + + public void setIsolationMethodName(String isolationMethodName) { + this.name = isolationMethodName; + } } diff --git a/api/src/org/apache/cloudstack/api/response/NetworkOfferingResponse.java b/api/src/org/apache/cloudstack/api/response/NetworkOfferingResponse.java index b1dcd423117..7a7e371e180 100644 --- a/api/src/org/apache/cloudstack/api/response/NetworkOfferingResponse.java +++ b/api/src/org/apache/cloudstack/api/response/NetworkOfferingResponse.java @@ -18,6 +18,7 @@ package org.apache.cloudstack.api.response; import java.util.Date; import java.util.List; +import java.util.Map; import org.apache.cloudstack.api.ApiConstants; import org.apache.cloudstack.api.BaseResponse; @@ -83,6 +84,10 @@ public class NetworkOfferingResponse extends BaseResponse { @SerializedName(ApiConstants.IS_PERSISTENT) @Param(description="true if network offering supports persistent networks, false otherwise") private Boolean isPersistent; + + @SerializedName(ApiConstants.DETAILS) @Param(description="additional key/value details tied with network offering", since="4.2.0") + private Map details; + public void setId(String id) { this.id = id; @@ -156,5 +161,9 @@ public class NetworkOfferingResponse extends BaseResponse { public void setIsPersistent(Boolean isPersistent) { this.isPersistent = isPersistent; } + + public void setDetails(Map details) { + this.details = details; + } } diff --git a/api/src/org/apache/cloudstack/api/response/PrivateGatewayResponse.java b/api/src/org/apache/cloudstack/api/response/PrivateGatewayResponse.java index 4123477dbfe..ca760626324 100644 --- a/api/src/org/apache/cloudstack/api/response/PrivateGatewayResponse.java +++ b/api/src/org/apache/cloudstack/api/response/PrivateGatewayResponse.java @@ -76,6 +76,10 @@ public class PrivateGatewayResponse extends BaseResponse implements ControlledEn private String state; + @SerializedName(ApiConstants.SOURCE_NAT_SUPPORTED) @Param(description = "Souce Nat enable status") + private Boolean sourceNat; + + @Override public String getObjectId() { return this.id; @@ -145,5 +149,11 @@ public class PrivateGatewayResponse extends BaseResponse implements ControlledEn public void setState(String state) { this.state = state; } + + public void setSourceNat(Boolean sourceNat) { + this.sourceNat = sourceNat; + } + + } diff --git a/api/src/org/apache/cloudstack/api/response/VirtualRouterProviderResponse.java b/api/src/org/apache/cloudstack/api/response/VirtualRouterProviderResponse.java index 92d9a1d0cc1..de355bd0c25 100644 --- a/api/src/org/apache/cloudstack/api/response/VirtualRouterProviderResponse.java +++ b/api/src/org/apache/cloudstack/api/response/VirtualRouterProviderResponse.java @@ -25,6 +25,7 @@ import com.cloud.serializer.Param; import com.google.gson.annotations.SerializedName; @EntityReference(value=VirtualRouterProvider.class) +@SuppressWarnings("unused") public class VirtualRouterProviderResponse extends BaseResponse implements ControlledEntityResponse { @SerializedName(ApiConstants.ID) @Param(description="the id of the router") private String id; diff --git a/api/src/org/apache/cloudstack/network/element/InternalLoadBalancerElementService.java b/api/src/org/apache/cloudstack/network/element/InternalLoadBalancerElementService.java new file mode 100644 index 00000000000..33a0c64058e --- /dev/null +++ b/api/src/org/apache/cloudstack/network/element/InternalLoadBalancerElementService.java @@ -0,0 +1,56 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.network.element; + +import java.util.List; + + +import com.cloud.network.VirtualRouterProvider; +import com.cloud.utils.component.PluggableService; + +public interface InternalLoadBalancerElementService extends PluggableService{ + /** + * Configures existing Internal Load Balancer Element (enables or disables it) + * @param id + * @param enable + * @return + */ + VirtualRouterProvider configureInternalLoadBalancerElement(long id, boolean enable); + + /** + * Adds Internal Load Balancer element to the Network Service Provider + * @param ntwkSvcProviderId + * @return + */ + VirtualRouterProvider addInternalLoadBalancerElement(long ntwkSvcProviderId); + + /** + * Retrieves existing Internal Load Balancer element + * @param id + * @return + */ + VirtualRouterProvider getInternalLoadBalancerElement(long id); + + /** + * Searches for existing Internal Load Balancer elements based on parameters passed to the call + * @param id + * @param ntwkSvsProviderId + * @param enabled + * @return + */ + List searchForInternalLoadBalancerElements(Long id, Long ntwkSvsProviderId, Boolean enabled); +} diff --git a/server/src/com/cloud/maint/UpgradeMonitor.java b/api/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerContainer.java similarity index 74% rename from server/src/com/cloud/maint/UpgradeMonitor.java rename to api/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerContainer.java index ca78fe22ece..df94d3d4338 100644 --- a/server/src/com/cloud/maint/UpgradeMonitor.java +++ b/api/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerContainer.java @@ -14,21 +14,15 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -package com.cloud.maint; +package org.apache.cloudstack.network.lb; -/** - * has been released. - * - */ -public class UpgradeMonitor implements Runnable { - private String _url; - private long _period; +import com.cloud.network.rules.LoadBalancerContainer; +import com.cloud.utils.net.Ip; + +public interface ApplicationLoadBalancerContainer extends LoadBalancerContainer{ - public UpgradeMonitor(String url, long period) { - _url = url; - } + public Long getSourceIpNetworkId(); - public void run() { - - } + public Ip getSourceIp(); + } diff --git a/server/src/com/cloud/maint/dao/AgentUpgradeDao.java b/api/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerRule.java similarity index 78% rename from server/src/com/cloud/maint/dao/AgentUpgradeDao.java rename to api/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerRule.java index e9763db5804..f4acb734c8b 100644 --- a/server/src/com/cloud/maint/dao/AgentUpgradeDao.java +++ b/api/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerRule.java @@ -14,10 +14,11 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -package com.cloud.maint.dao; -import com.cloud.maint.AgentUpgradeVO; -import com.cloud.utils.db.GenericDao; +package org.apache.cloudstack.network.lb; -public interface AgentUpgradeDao extends GenericDao { +import com.cloud.network.rules.LoadBalancer; + +public interface ApplicationLoadBalancerRule extends ApplicationLoadBalancerContainer, LoadBalancer{ + int getInstancePort(); } diff --git a/api/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerService.java b/api/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerService.java new file mode 100644 index 00000000000..b2ac358555b --- /dev/null +++ b/api/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerService.java @@ -0,0 +1,42 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.cloudstack.network.lb; + +import java.util.List; + +import org.apache.cloudstack.api.command.user.loadbalancer.ListApplicationLoadBalancersCmd; + +import com.cloud.exception.InsufficientAddressCapacityException; +import com.cloud.exception.InsufficientVirtualNetworkCapcityException; +import com.cloud.exception.NetworkRuleConflictException; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.utils.Pair; + +public interface ApplicationLoadBalancerService { + + ApplicationLoadBalancerRule createApplicationLoadBalancer(String name, String description, Scheme scheme, long sourceIpNetworkId, String sourceIp, + int sourcePort, int instancePort, String algorithm, long networkId, long lbOwnerId) throws InsufficientAddressCapacityException, + NetworkRuleConflictException, InsufficientVirtualNetworkCapcityException; + + boolean deleteApplicationLoadBalancer(long id); + + Pair, Integer> listApplicationLoadBalancers(ListApplicationLoadBalancersCmd cmd); + + ApplicationLoadBalancerRule getApplicationLoadBalancer(long ruleId); + +} diff --git a/api/src/org/apache/cloudstack/network/lb/InternalLoadBalancerVMService.java b/api/src/org/apache/cloudstack/network/lb/InternalLoadBalancerVMService.java new file mode 100644 index 00000000000..91cd88d91c1 --- /dev/null +++ b/api/src/org/apache/cloudstack/network/lb/InternalLoadBalancerVMService.java @@ -0,0 +1,34 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.network.lb; + +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.exception.StorageUnavailableException; +import com.cloud.network.router.VirtualRouter; +import com.cloud.user.Account; + +public interface InternalLoadBalancerVMService { + + VirtualRouter startInternalLbVm(long internalLbVmId, Account caller, long callerUserId) + throws StorageUnavailableException, InsufficientCapacityException, ConcurrentOperationException, ResourceUnavailableException; + + VirtualRouter stopInternalLbVm(long vmId, boolean forced, Account caller, long callerUserId) + throws ConcurrentOperationException, ResourceUnavailableException; + +} diff --git a/api/src/org/apache/cloudstack/query/QueryService.java b/api/src/org/apache/cloudstack/query/QueryService.java index 443c5df65b5..2f50d63828c 100644 --- a/api/src/org/apache/cloudstack/query/QueryService.java +++ b/api/src/org/apache/cloudstack/query/QueryService.java @@ -18,6 +18,7 @@ package org.apache.cloudstack.query; import org.apache.cloudstack.affinity.AffinityGroupResponse; import org.apache.cloudstack.api.command.admin.host.ListHostsCmd; +import org.apache.cloudstack.api.command.admin.internallb.ListInternalLBVMsCmd; import org.apache.cloudstack.api.command.admin.router.ListRoutersCmd; import org.apache.cloudstack.api.command.admin.storage.ListStoragePoolsCmd; import org.apache.cloudstack.api.command.admin.user.ListUsersCmd; @@ -101,4 +102,6 @@ public interface QueryService { public ListResponse listAffinityGroups(Long affinityGroupId, String affinityGroupName, String affinityGroupType, Long vmId, Long startIndex, Long pageSize); + + ListResponse searchForInternalLbVms(ListInternalLBVMsCmd cmd); } diff --git a/api/test/org/apache/cloudstack/api/command/test/ScaleVMCmdTest.java b/api/test/org/apache/cloudstack/api/command/test/ScaleVMCmdTest.java index 301fa02ca29..8a28290e04b 100644 --- a/api/test/org/apache/cloudstack/api/command/test/ScaleVMCmdTest.java +++ b/api/test/org/apache/cloudstack/api/command/test/ScaleVMCmdTest.java @@ -16,31 +16,20 @@ // under the License. package org.apache.cloudstack.api.command.test; -import com.cloud.user.Account; -import com.cloud.user.UserContext; import com.cloud.uservm.UserVm; import com.cloud.vm.UserVmService; import junit.framework.Assert; import junit.framework.TestCase; import org.apache.cloudstack.api.ResponseGenerator; import org.apache.cloudstack.api.ServerApiException; -import org.apache.cloudstack.api.command.admin.region.AddRegionCmd; import org.apache.cloudstack.api.command.user.vm.ScaleVMCmd; -import org.apache.cloudstack.api.response.RegionResponse; -import org.apache.cloudstack.api.response.UserVmResponse; -import org.apache.cloudstack.region.Region; -import org.apache.cloudstack.region.RegionService; + import org.junit.Before; import org.junit.Rule; import org.junit.Test; import org.junit.rules.ExpectedException; import org.mockito.Mockito; -import java.util.ArrayList; -import java.util.List; -import java.util.UUID; - - public class ScaleVMCmdTest extends TestCase{ private ScaleVMCmd scaleVMCmd; @@ -57,12 +46,11 @@ public class ScaleVMCmdTest extends TestCase{ public Long getId() { return 2L; } + @Override + public String getCommandName() { + return "scalevirtualmachineresponse"; + } }; - - //Account account = new AccountVO("testaccount", 1L, "networkdomain", (short) 0, "uuid"); - //UserContext.registerContext(1, account, null, true); - - } @@ -71,11 +59,10 @@ public class ScaleVMCmdTest extends TestCase{ UserVmService userVmService = Mockito.mock(UserVmService.class); - UserVm uservm = Mockito.mock(UserVm.class); try { Mockito.when( userVmService.upgradeVirtualMachine(scaleVMCmd)) - .thenReturn(uservm); + .thenReturn(true); }catch (Exception e){ Assert.fail("Received exception when success expected " +e.getMessage()); } @@ -83,13 +70,6 @@ public class ScaleVMCmdTest extends TestCase{ scaleVMCmd._userVmService = userVmService; responseGenerator = Mockito.mock(ResponseGenerator.class); - UserVmResponse userVmResponse = Mockito.mock(UserVmResponse.class); - List responseList = new ArrayList(); - responseList.add(userVmResponse); - - Mockito.when(responseGenerator.createUserVmResponse("virtualmachine",uservm)) - .thenReturn(responseList); - scaleVMCmd._responseGenerator = responseGenerator; scaleVMCmd.execute(); @@ -101,10 +81,9 @@ public class ScaleVMCmdTest extends TestCase{ UserVmService userVmService = Mockito.mock(UserVmService.class); try { - UserVm uservm = Mockito.mock(UserVm.class); Mockito.when( userVmService.upgradeVirtualMachine(scaleVMCmd)) - .thenReturn(null); + .thenReturn(false); }catch (Exception e){ Assert.fail("Received exception when success expected " +e.getMessage()); } diff --git a/awsapi/pom.xml b/awsapi/pom.xml index f19a71381d3..d4573491723 100644 --- a/awsapi/pom.xml +++ b/awsapi/pom.xml @@ -286,12 +286,6 @@ - install - src - src @@ -307,6 +301,17 @@ + + org.apache.maven.plugins + maven-surefire-plugin + + + com/cloud/gate/util/UtilTestCase.java + com/cloud/gate/service/ServiceTestCase.java + com/cloud/gate/util/CloudStackClientTestCase.java + + + org.apache.maven.plugins maven-war-plugin @@ -364,22 +369,6 @@ - diff --git a/awsapi/test/com/cloud/gate/model/ModelTestCase.java b/awsapi/test/com/cloud/gate/model/ModelTestCase.java deleted file mode 100644 index 91aeaa75215..00000000000 --- a/awsapi/test/com/cloud/gate/model/ModelTestCase.java +++ /dev/null @@ -1,368 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.gate.model; - -import java.util.Date; -import java.util.Iterator; -import java.util.List; - -import org.apache.log4j.Logger; -import org.hibernate.Query; -import org.hibernate.Session; -import org.hibernate.Transaction; -import org.junit.Assert; - -import com.cloud.bridge.model.MHost; -import com.cloud.bridge.model.MHostMount; -import com.cloud.bridge.model.SBucket; -import com.cloud.bridge.model.SHost; -import com.cloud.bridge.model.SMeta; -import com.cloud.bridge.model.SObject; -import com.cloud.bridge.util.CloudSessionFactory; -import com.cloud.bridge.util.QueryHelper; -import com.cloud.gate.testcase.BaseTestCase; - -public class ModelTestCase extends BaseTestCase { - protected final static Logger logger = Logger.getLogger(ModelTestCase.class); - - public void testSHost() { - SHost host; - - // create the record - Session session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - host = new SHost(); - host.setHost("localhost"); - host.setExportRoot("/"); - host.setUserOnHost("root"); - host.setUserPassword("password"); - session.saveOrUpdate(host); - txn.commit(); - } finally { - session.close(); - } - Assert.assertTrue(host.getId() != 0); - - // retrive the record - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - host = (SHost)session.get(SHost.class, (long)host.getId()); - txn.commit(); - - Assert.assertTrue(host.getHost().equals("localhost")); - Assert.assertTrue(host.getUserOnHost().equals("root")); - Assert.assertTrue(host.getUserPassword().equals("password")); - - logger.info("Retrived record, host:" + host.getHost() - + ", user: " + host.getUserOnHost() - + ", password: " + host.getUserPassword()); - - } finally { - session.close(); - } - - // delete the record - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - host = (SHost)session.get(SHost.class, (long)host.getId()); - session.delete(host); - txn.commit(); - } finally { - session.close(); - } - - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - host = (SHost)session.get(SHost.class, (long)host.getId()); - txn.commit(); - - Assert.assertTrue(host == null); - } finally { - session.close(); - } - } - - public void testSBucket() { - SHost host; - SBucket bucket; - Session session; - - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - host = new SHost(); - host.setHost("localhost"); - host.setUserOnHost("root"); - host.setUserPassword("password"); - host.setExportRoot("/"); - - bucket = new SBucket(); - bucket.setName("Bucket"); - bucket.setOwnerCanonicalId("OwnerId-dummy"); - bucket.setCreateTime(new Date()); - - host.getBuckets().add(bucket); - bucket.setShost(host); - - session.save(host); - session.save(bucket); - txn.commit(); - } finally { - session.close(); - } - - long bucketId = bucket.getId(); - - // load bucket - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - bucket = (SBucket)session.get(SBucket.class, bucketId); - txn.commit(); - - Assert.assertTrue(bucket.getShost().getHost().equals("localhost")); - Assert.assertTrue(bucket.getName().equals("Bucket")); - Assert.assertTrue(bucket.getOwnerCanonicalId().equals("OwnerId-dummy")); - } finally { - session.close(); - } - - // delete the bucket - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - bucket = (SBucket)session.get(SBucket.class, bucketId); - session.delete(bucket); - - host = (SHost)session.get(SHost.class, host.getId()); - session.delete(host); - txn.commit(); - } finally { - session.close(); - } - - // verify the deletion - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - bucket = (SBucket)session.get(SBucket.class, bucketId); - txn.commit(); - - Assert.assertTrue(bucket == null); - } finally { - session.close(); - } - } - - public void testSObject() { - SHost host; - SBucket bucket; - Session session; - SObject sobject; - - // setup - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - host = new SHost(); - host.setHost("localhost"); - host.setUserOnHost("root"); - host.setUserPassword("password"); - host.setExportRoot("/"); - - bucket = new SBucket(); - bucket.setName("Bucket"); - bucket.setOwnerCanonicalId("OwnerId-dummy"); - bucket.setCreateTime(new Date()); - bucket.setShost(host); - host.getBuckets().add(bucket); - - sobject = new SObject(); - sobject.setNameKey("ObjectNameKey"); - sobject.setOwnerCanonicalId("OwnerId-dummy"); - sobject.setCreateTime(new Date()); - sobject.setBucket(bucket); - bucket.getObjectsInBucket().add(sobject); - - session.save(host); - session.save(bucket); - session.save(sobject); - txn.commit(); - - } finally { - session.close(); - } - - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - sobject = (SObject)session.get(SObject.class, sobject.getId()); - txn.commit(); - Assert.assertTrue(sobject.getBucket().getName().equals("Bucket")); - Assert.assertTrue(sobject.getNameKey().equals("ObjectNameKey")); - Assert.assertTrue(sobject.getOwnerCanonicalId().equals("OwnerId-dummy")); - } finally { - session.close(); - } - - // test delete cascade - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - bucket = (SBucket)session.get(SBucket.class, bucket.getId()); - session.delete(bucket); - - host = (SHost)session.get(SHost.class, host.getId()); - session.delete(host); - txn.commit(); - } finally { - session.close(); - } - } - - public void testMeta() { - Session session; - - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - SMeta meta = new SMeta(); - meta.setTarget("SObject"); - meta.setTargetId(1); - meta.setName("param1"); - meta.setValue("value1"); - session.save(meta); - - logger.info("Meta 1: " + meta.getId()); - - meta = new SMeta(); - meta.setTarget("SObject"); - meta.setTargetId(1); - meta.setName("param2"); - meta.setValue("value2"); - session.save(meta); - - logger.info("Meta 2: " + meta.getId()); - - txn.commit(); - } finally { - session.close(); - } - - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - Query query = session.createQuery("from SMeta where target=? and targetId=?"); - QueryHelper.bindParameters(query, new Object[] { - "SObject", new Long(1) - }); - List l = QueryHelper.executeQuery(query); - txn.commit(); - - for(SMeta meta: l) { - logger.info("" + meta.getName() + "=" + meta.getValue()); - } - } finally { - session.close(); - } - - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - Query query = session.createQuery("delete from SMeta where target=?"); - QueryHelper.bindParameters(query, new Object[] {"SObject"}); - query.executeUpdate(); - txn.commit(); - } finally { - session.close(); - } - } - - public void testHosts() { - Session session; - SHost shost; - MHost mhost; - MHostMount hostMount; - - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - shost = new SHost(); - shost.setHost("Storage host1"); - shost.setUserOnHost("root"); - shost.setUserPassword("password"); - shost.setExportRoot("/"); - session.save(shost); - - mhost = new MHost(); - mhost.setHostKey("1"); - mhost.setHost("management host1"); - mhost.setVersion("v1"); - session.save(mhost); - - hostMount = new MHostMount(); - hostMount.setMhost(mhost); - hostMount.setShost(shost); - hostMount.setMountPath("/mnt"); - session.save(hostMount); - txn.commit(); - } finally { - session.close(); - } - - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - mhost = (MHost)session.createQuery("from MHost where hostKey=?"). - setLong(0, new Long(1)).uniqueResult(); - - if(mhost != null) { - Iterator it = mhost.getMounts().iterator(); - while(it.hasNext()) { - MHostMount mount = (MHostMount)it.next(); - Assert.assertTrue(mount.getMountPath().equals("/mnt")); - - logger.info(mount.getMountPath()); - } - } - txn.commit(); - } finally { - session.close(); - } - - session = CloudSessionFactory.getInstance().openSession(); - try { - Transaction txn = session.beginTransaction(); - mhost = (MHost)session.createQuery("from MHost where hostKey=?"). - setLong(0, new Long(1)).uniqueResult(); - if(mhost != null) - session.delete(mhost); - - shost = (SHost)session.createQuery("from SHost where host=?"). - setString(0, "Storage host1").uniqueResult(); - if(shost != null) - session.delete(shost); - txn.commit(); - } finally { - session.close(); - } - } -} diff --git a/awsapi/test/com/cloud/gate/persist/PersitTestCase.java b/awsapi/test/com/cloud/gate/persist/PersitTestCase.java deleted file mode 100644 index 4961d932682..00000000000 --- a/awsapi/test/com/cloud/gate/persist/PersitTestCase.java +++ /dev/null @@ -1,73 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.gate.persist; - -import org.apache.log4j.Logger; - -import com.cloud.bridge.persist.PersistContext; -import com.cloud.gate.testcase.BaseTestCase; - -public class PersitTestCase extends BaseTestCase { - protected final static Logger logger = Logger.getLogger(PersitTestCase.class); - - public void testNamedLock() { - Thread t1 = new Thread(new Runnable() { - public void run() { - for(int i = 0; i < 10; i++) { - if(PersistContext.acquireNamedLock("TestLock", 3)) { - logger.info("Thread 1 acquired lock"); - try { - Thread.currentThread().sleep(BaseTestCase.getRandomMilliseconds(5000, 10000)); - } catch (InterruptedException e) { - } - logger.info("Thread 1 to release lock"); - PersistContext.releaseNamedLock("TestLock"); - } else { - logger.info("Thread 1 is unable to acquire lock"); - } - } - } - }); - - Thread t2 = new Thread(new Runnable() { - public void run() { - for(int i = 0; i < 10; i++) { - if(PersistContext.acquireNamedLock("TestLock", 3)) { - logger.info("Thread 2 acquired lock"); - try { - Thread.currentThread().sleep(BaseTestCase.getRandomMilliseconds(1000, 5000)); - } catch (InterruptedException e) { - } - logger.info("Thread 2 to release lock"); - PersistContext.releaseNamedLock("TestLock"); - } else { - logger.info("Thread 2 is unable to acquire lock"); - } - } - } - }); - - t1.start(); - t2.start(); - - try { - t1.join(); - t2.join(); - } catch(InterruptedException e) { - } - } -} diff --git a/client/WEB-INF/classes/resources/messages.properties b/client/WEB-INF/classes/resources/messages.properties index ad8f42b0e78..1638be19e49 100644 --- a/client/WEB-INF/classes/resources/messages.properties +++ b/client/WEB-INF/classes/resources/messages.properties @@ -14,16 +14,10 @@ # KIND, either express or implied. See the License for the # specific language governing permissions and limitations # under the License. -label.add.affinity.group=Add new affinity group -message.delete.affinity.group=Please confirm that you would like to remove this affinity group. -label.delete.affinity.group=Delete Affinity Group -label.edit.affinity.group=Edit Affinity Group -label.affinity=Affinity -label.anti.affinity=Anti-affinity -label.affinity.groups=Affinity Groups -label.anti.affinity.groups=Anti-affinity Groups -label.affinity.group=Affinity Group -label.anti.affinity.group=Anti-affinity Group +message.select.affinity.groups=Please select any affinity groups you want this VM to belong to: +message.no.affinity.groups=You do not have any affinity groups. Please continue to the next step. +label.action.delete.nic=Remove NIC +message.action.delete.nic=Please confirm that want to remove this NIC, which will also remove the associated network from the VM. changed.item.properties=Changed item properties confirm.enable.s3=Please fill in the following information to enable support for S3-backed Secondary Storage confirm.enable.swift=Please fill in the following information to enable support for Swift @@ -31,7 +25,7 @@ error.could.not.enable.zone=Could not enable zone error.installWizard.message=Something went wrong; you may go back and correct any errors error.invalid.username.password=Invalid username or password error.login=Your username/password does not match our records. -error.menu.select=Unable to perform action due to no items being selected. +error.menu.select=Unable to perform action due to no items being selected. error.mgmt.server.inaccessible=The Management Server is unaccessible. Please try again later. error.password.not.match=The password fields do not match error.please.specify.physical.network.tags=Network offerings is not available until you specify tags for this physical network. @@ -40,115 +34,115 @@ error.something.went.wrong.please.correct.the.following=Something went wrong; pl error.unable.to.reach.management.server=Unable to reach Management Server error.unresolved.internet.name=Your internet name cannot be resolved. extractable=Extractable -force.delete.domain.warning=Warning: Choosing this option will cause the deletion of all child domains and all associated accounts and their resources. +force.delete.domain.warning=Warning\: Choosing this option will cause the deletion of all child domains and all associated accounts and their resources. force.delete=Force Delete +force.remove.host.warning=Warning\: Choosing this option will cause CloudStack to forcefully stop all running virtual machines before removing this host from the cluster. force.remove=Force Remove -force.remove.host.warning=Warning: Choosing this option will cause CloudStack to forcefully stop all running virtual machines before removing this host from the cluster. +force.stop.instance.warning=Warning\: Forcing a stop on this instance should be your last option. It can lead to data loss as well as inconsistent behavior of the virtual machine state. force.stop=Force Stop -force.stop.instance.warning=Warning: Forcing a stop on this instance should be your last option. It can lead to data loss as well as inconsistent behavior of the virtual machine state. ICMP.code=ICMP Code ICMP.type=ICMP Type image.directory=Image Directory inline=Inline instances.actions.reboot.label=Reboot instance label.accept.project.invitation=Accept project invitation -label.account=Account label.account.and.security.group=Account, Security group label.account.id=Account ID label.account.name=Account Name -label.accounts=Accounts label.account.specific=Account-Specific +label.account=Account +label.accounts=Accounts label.acquire.new.ip=Acquire New IP -label.action.attach.disk=Attach Disk label.action.attach.disk.processing=Attaching Disk.... -label.action.attach.iso=Attach ISO +label.action.attach.disk=Attach Disk label.action.attach.iso.processing=Attaching ISO.... -label.action.cancel.maintenance.mode=Cancel Maintenance Mode +label.action.attach.iso=Attach ISO label.action.cancel.maintenance.mode.processing=Cancelling Maintenance Mode.... +label.action.cancel.maintenance.mode=Cancel Maintenance Mode label.action.change.password=Change Password -label.action.change.service=Change Service label.action.change.service.processing=Changing Service.... -label.action.copy.ISO=Copy ISO +label.action.change.service=Change Service label.action.copy.ISO.processing=Coping ISO.... -label.action.copy.template=Copy Template +label.action.copy.ISO=Copy ISO label.action.copy.template.processing=Coping Template.... -label.action.create.template=Create Template +label.action.copy.template=Copy Template label.action.create.template.from.vm=Create Template from VM label.action.create.template.from.volume=Create Template from Volume label.action.create.template.processing=Creating Template.... -label.action.create.vm=Create VM +label.action.create.template=Create Template label.action.create.vm.processing=Creating VM.... -label.action.create.volume=Create Volume +label.action.create.vm=Create VM label.action.create.volume.processing=Creating Volume.... -label.action.delete.account=Delete account +label.action.create.volume=Create Volume label.action.delete.account.processing=Deleting account.... -label.action.delete.cluster=Delete Cluster +label.action.delete.account=Delete account label.action.delete.cluster.processing=Deleting Cluster.... -label.action.delete.disk.offering=Delete Disk Offering +label.action.delete.cluster=Delete Cluster label.action.delete.disk.offering.processing=Deleting Disk Offering.... -label.action.delete.domain=Delete Domain +label.action.delete.disk.offering=Delete Disk Offering label.action.delete.domain.processing=Deleting Domain.... -label.action.delete.firewall=Delete firewall rule +label.action.delete.domain=Delete Domain label.action.delete.firewall.processing=Deleting Firewall.... -label.action.delete.ingress.rule=Delete Ingress Rule +label.action.delete.firewall=Delete firewall rule label.action.delete.ingress.rule.processing=Deleting Ingress Rule.... -label.action.delete.IP.range=Delete IP Range +label.action.delete.ingress.rule=Delete Ingress Rule label.action.delete.IP.range.processing=Deleting IP Range.... -label.action.delete.ISO=Delete ISO +label.action.delete.IP.range=Delete IP Range label.action.delete.ISO.processing=Deleting ISO.... -label.action.delete.load.balancer=Delete load balancer rule +label.action.delete.ISO=Delete ISO label.action.delete.load.balancer.processing=Deleting Load Balancer.... -label.action.delete.network=Delete Network +label.action.delete.load.balancer=Delete load balancer rule label.action.delete.network.processing=Deleting Network.... +label.action.delete.network=Delete Network label.action.delete.nexusVswitch=Delete Nexus 1000v label.action.delete.physical.network=Delete physical network -label.action.delete.pod=Delete Pod label.action.delete.pod.processing=Deleting Pod.... -label.action.delete.primary.storage=Delete Primary Storage +label.action.delete.pod=Delete Pod label.action.delete.primary.storage.processing=Deleting Primary Storage.... -label.action.delete.secondary.storage=Delete Secondary Storage +label.action.delete.primary.storage=Delete Primary Storage label.action.delete.secondary.storage.processing=Deleting Secondary Storage.... -label.action.delete.security.group=Delete Security Group +label.action.delete.secondary.storage=Delete Secondary Storage label.action.delete.security.group.processing=Deleting Security Group.... -label.action.delete.service.offering=Delete Service Offering +label.action.delete.security.group=Delete Security Group label.action.delete.service.offering.processing=Deleting Service Offering.... -label.action.delete.snapshot=Delete Snapshot +label.action.delete.service.offering=Delete Service Offering label.action.delete.snapshot.processing=Deleting Snapshot.... +label.action.delete.snapshot=Delete Snapshot label.action.delete.system.service.offering=Delete System Service Offering -label.action.delete.template=Delete Template label.action.delete.template.processing=Deleting Template.... -label.action.delete.user=Delete User +label.action.delete.template=Delete Template label.action.delete.user.processing=Deleting User.... -label.action.delete.volume=Delete Volume +label.action.delete.user=Delete User label.action.delete.volume.processing=Deleting Volume.... -label.action.delete.zone=Delete Zone +label.action.delete.volume=Delete Volume label.action.delete.zone.processing=Deleting Zone.... -label.action.destroy.instance=Destroy Instance +label.action.delete.zone=Delete Zone label.action.destroy.instance.processing=Destroying Instance.... -label.action.destroy.systemvm=Destroy System VM +label.action.destroy.instance=Destroy Instance label.action.destroy.systemvm.processing=Destroying System VM.... -label.action.detach.disk=Detach Disk +label.action.destroy.systemvm=Destroy System VM label.action.detach.disk.processing=Detaching Disk.... -label.action.detach.iso=Detach ISO +label.action.detach.disk=Detach Disk label.action.detach.iso.processing=Detaching ISO.... -label.action.disable.account=Disable account +label.action.detach.iso=Detach ISO label.action.disable.account.processing=Disabling account.... -label.action.disable.cluster=Disable Cluster +label.action.disable.account=Disable account label.action.disable.cluster.processing=Disabling Cluster.... +label.action.disable.cluster=Disable Cluster label.action.disable.nexusVswitch=Disable Nexus 1000v label.action.disable.physical.network=Disable physical network -label.action.disable.pod=Disable Pod label.action.disable.pod.processing=Disabling Pod.... -label.action.disable.static.NAT=Disable Static NAT +label.action.disable.pod=Disable Pod label.action.disable.static.NAT.processing=Disabling Static NAT.... -label.action.disable.user=Disable User +label.action.disable.static.NAT=Disable Static NAT label.action.disable.user.processing=Disabling User.... -label.action.disable.zone=Disable Zone +label.action.disable.user=Disable User label.action.disable.zone.processing=Disabling Zone.... +label.action.disable.zone=Disable Zone label.action.download.ISO=Download ISO label.action.download.template=Download Template -label.action.download.volume=Download Volume label.action.download.volume.processing=Downloading Volume.... +label.action.download.volume=Download Volume label.action.edit.account=Edit account label.action.edit.disk.offering=Edit Disk Offering label.action.edit.domain=Edit Domain @@ -156,9 +150,9 @@ label.action.edit.global.setting=Edit Global Setting label.action.edit.host=Edit Host label.action.edit.instance=Edit Instance label.action.edit.ISO=Edit ISO -label.action.edit.network=Edit Network label.action.edit.network.offering=Edit Network Offering label.action.edit.network.processing=Editing Network.... +label.action.edit.network=Edit Network label.action.edit.pod=Edit Pod label.action.edit.primary.storage=Edit Primary Storage label.action.edit.resource.limits=Edit Resource Limits @@ -166,37 +160,37 @@ label.action.edit.service.offering=Edit Service Offering label.action.edit.template=Edit Template label.action.edit.user=Edit User label.action.edit.zone=Edit Zone -label.action.enable.account=Enable account label.action.enable.account.processing=Enabling account.... -label.action.enable.cluster=Enable Cluster +label.action.enable.account=Enable account label.action.enable.cluster.processing=Enabling Cluster.... -label.action.enable.maintenance.mode=Enable Maintenance Mode +label.action.enable.cluster=Enable Cluster label.action.enable.maintenance.mode.processing=Enabling Maintenance Mode.... +label.action.enable.maintenance.mode=Enable Maintenance Mode label.action.enable.nexusVswitch=Enable Nexus 1000v label.action.enable.physical.network=Enable physical network -label.action.enable.pod=Enable Pod label.action.enable.pod.processing=Enabling Pod.... -label.action.enable.static.NAT=Enable Static NAT +label.action.enable.pod=Enable Pod label.action.enable.static.NAT.processing=Enabling Static NAT.... -label.action.enable.user=Enable User +label.action.enable.static.NAT=Enable Static NAT label.action.enable.user.processing=Enabling User.... -label.action.enable.zone=Enable Zone +label.action.enable.user=Enable User label.action.enable.zone.processing=Enabling Zone.... -label.action.force.reconnect=Force Reconnect +label.action.enable.zone=Enable Zone label.action.force.reconnect.processing=Reconnecting.... -label.action.generate.keys=Generate Keys +label.action.force.reconnect=Force Reconnect label.action.generate.keys.processing=Generate Keys.... +label.action.generate.keys=Generate Keys label.action.list.nexusVswitch=List Nexus 1000v -label.action.lock.account=Lock account label.action.lock.account.processing=Locking account.... -label.action.manage.cluster=Manage Cluster +label.action.lock.account=Lock account label.action.manage.cluster.processing=Managing Cluster.... -label.action.migrate.instance=Migrate Instance +label.action.manage.cluster=Manage Cluster label.action.migrate.instance.processing=Migrating Instance.... -label.action.migrate.router=Migrate Router +label.action.migrate.instance=Migrate Instance label.action.migrate.router.processing=Migrating Router.... -label.action.migrate.systemvm=Migrate System VM +label.action.migrate.router=Migrate Router label.action.migrate.systemvm.processing=Migrating System VM.... +label.action.migrate.systemvm=Migrate System VM label.action.reboot.instance.processing=Rebooting Instance.... label.action.reboot.instance=Reboot Instance label.action.reboot.router.processing=Rebooting Router.... @@ -217,7 +211,6 @@ label.action.resize.volume=Resize Volume label.action.resource.limits=Resource limits label.action.restore.instance.processing=Restoring Instance.... label.action.restore.instance=Restore Instance -label.actions=Actions label.action.start.instance.processing=Starting Instance.... label.action.start.instance=Start Instance label.action.start.router.processing=Starting Router.... @@ -241,18 +234,19 @@ label.action.update.resource.count=Update Resource Count label.action.vmsnapshot.create=Take VM Snapshot label.action.vmsnapshot.delete=Delete VM snapshot label.action.vmsnapshot.revert=Revert to VM snapshot +label.actions=Actions label.activate.project=Activate Project label.active.sessions=Active Sessions -label.add.account=Add Account -label.add.accounts=Add accounts -label.add.accounts.to=Add accounts to label.add.account.to.project=Add account to project +label.add.account=Add Account +label.add.accounts.to=Add accounts to +label.add.accounts=Add accounts label.add.ACL=Add ACL -label.add=Add +label.add.affinity.group=Add new affinity group label.add.BigSwitchVns.device=Add BigSwitch Vns Controller -label.add.by=Add by label.add.by.cidr=Add By CIDR label.add.by.group=Add By Group +label.add.by=Add by label.add.cluster=Add Cluster label.add.compute.offering=Add compute offering label.add.direct.iprange=Add Direct Ip Range @@ -263,24 +257,15 @@ label.add.F5.device=Add F5 device label.add.firewall=Add firewall rule label.add.guest.network=Add guest network label.add.host=Add Host -label.adding=Adding -label.adding.cluster=Adding Cluster -label.adding.failed=Adding Failed -label.adding.pod=Adding Pod -label.adding.processing=Adding.... label.add.ingress.rule=Add Ingress Rule -label.adding.succeeded=Adding Succeeded -label.adding.user=Adding User -label.adding.zone=Adding Zone label.add.ip.range=Add IP Range -label.additional.networks=Additional Networks label.add.load.balancer=Add Load Balancer label.add.more=Add More label.add.netScaler.device=Add Netscaler device label.add.network.ACL=Add network ACL -label.add.network=Add Network label.add.network.device=Add Network Device label.add.network.offering=Add network offering +label.add.network=Add Network label.add.new.F5=Add new F5 label.add.new.gateway=Add new gateway label.add.new.NetScaler=Add new NetScaler @@ -306,21 +291,34 @@ label.add.template=Add Template label.add.to.group=Add to group label.add.user=Add User label.add.vlan=Add VLAN -label.add.vm=Add VM -label.add.vms=Add VMs -label.add.vms.to.lb=Add VM(s) to load balancer rule label.add.VM.to.tier=Add VM to tier +label.add.vm=Add VM +label.add.vms.to.lb=Add VM(s) to load balancer rule +label.add.vms=Add VMs label.add.volume=Add Volume label.add.vpc=Add VPC label.add.vpn.customer.gateway=Add VPN Customer Gateway label.add.VPN.gateway=Add VPN Gateway label.add.vpn.user=Add VPN user label.add.zone=Add Zone +label.add=Add +label.adding.cluster=Adding Cluster +label.adding.failed=Adding Failed +label.adding.pod=Adding Pod +label.adding.processing=Adding.... +label.adding.succeeded=Adding Succeeded +label.adding.user=Adding User +label.adding.zone=Adding Zone +label.adding=Adding +label.additional.networks=Additional Networks label.admin.accounts=Admin Accounts label.admin=Admin -label.advanced=Advanced label.advanced.mode=Advanced Mode label.advanced.search=Advance Search +label.advanced=Advanced +label.affinity.group=Affinity Group +label.affinity.groups=Affinity Groups +label.affinity=Affinity label.agent.password=Agent Password label.agent.username=Agent Username label.agree=Agree @@ -328,23 +326,26 @@ label.alert=Alert label.algorithm=Algorithm label.allocated=Allocated label.allocation.state=Allocation State +label.anti.affinity.group=Anti-affinity Group +label.anti.affinity.groups=Anti-affinity Groups +label.anti.affinity=Anti-affinity label.api.key=API Key label.apply=Apply -label.assign=Assign label.assign.to.load.balancer=Assigning instance to load balancer -label.associated.network=Associated Network +label.assign=Assign label.associated.network.id=Associated Network ID +label.associated.network=Associated Network label.attached.iso=Attached ISO label.author.email=Author e-mail label.author.name=Author name -label.availability=Availability label.availability.zone=Availability Zone -label.available=Available +label.availability=Availability label.available.public.ips=Available Public IP Addresses +label.available=Available label.back=Back label.bandwidth=Bandwidth -label.basic=Basic label.basic.mode=Basic Mode +label.basic=Basic label.bigswitch.controller.address=BigSwitch Vns Controller Address label.bootable=Bootable label.broadcast.domain.range=Broadcast domain range @@ -359,12 +360,12 @@ label.by.pod=By Pod label.by.role=By Role label.by.start.date=By Start Date label.by.state=By State +label.by.traffic.type=By Traffic Type +label.by.type.id=By Type ID +label.by.type=By Type +label.by.zone=By Zone label.bytes.received=Bytes Received label.bytes.sent=Bytes Sent -label.by.traffic.type=By Traffic Type -label.by.type=By Type -label.by.type.id=By Type ID -label.by.zone=By Zone label.cancel=Cancel label.capacity=Capacity label.certificate=Certificate @@ -373,50 +374,50 @@ label.change.value=Change value label.character=Character label.checksum=MD5 checksum label.cidr.account=CIDR or Account/Security Group -label.cidr=CIDR label.CIDR.list=CIDR list label.cidr.list=Source CIDR label.CIDR.of.destination.network=CIDR of destination network +label.cidr=CIDR label.clean.up=Clean up label.clear.list=Clear list label.close=Close label.cloud.console=Cloud Management Console label.cloud.managed=Cloud.com Managed -label.cluster=Cluster label.cluster.name=Cluster Name -label.clusters=Clusters label.cluster.type=Cluster Type +label.cluster=Cluster +label.clusters=Clusters label.clvm=CLVM label.code=Code label.community=Community label.compute.and.storage=Compute and Storage -label.compute=Compute label.compute.offering=Compute offering label.compute.offerings=Compute offerings +label.compute=Compute label.configuration=Configuration -label.configure=Configure label.configure.network.ACLs=Configure Network ACLs label.configure.vpc=Configure VPC -label.confirmation=Confirmation +label.configure=Configure label.confirm.password=Confirm password -label.congratulations=Congratulations! +label.confirmation=Confirmation +label.congratulations=Congratulations\! label.conserve.mode=Conserve mode label.console.proxy=Console proxy label.continue.basic.install=Continue with basic installation label.continue=Continue label.corrections.saved=Corrections saved -label.cpu.allocated=CPU Allocated label.cpu.allocated.for.VMs=CPU Allocated for VMs +label.cpu.allocated=CPU Allocated label.CPU.cap=CPU Cap -label.cpu=CPU label.cpu.limits=CPU limits label.cpu.mhz=CPU (in MHz) label.cpu.utilized=CPU Utilized -label.created.by.system=Created by system -label.created=Created +label.cpu=CPU label.create.project=Create project label.create.template=Create template label.create.VPN.connection=Create VPN Connection +label.created.by.system=Created by system +label.created=Created label.cross.zones=Cross Zones label.custom.disk.size=Custom Disk Size label.daily=Daily @@ -427,11 +428,11 @@ label.day.of.week=Day of Week label.dead.peer.detection=Dead Peer Detection label.decline.invitation=Decline invitation label.dedicated=Dedicated -label.default=Default label.default.use=Default Use label.default.view=Default View +label.default=Default +label.delete.affinity.group=Delete Affinity Group label.delete.BigSwitchVns=Remove BigSwitch Vns Controller -label.delete=Delete label.delete.F5=Delete F5 label.delete.gateway=delete gateway label.delete.NetScaler=Delete NetScaler @@ -442,58 +443,60 @@ label.delete.VPN.connection=delete VPN connection label.delete.VPN.customer.gateway=delete VPN Customer Gateway label.delete.VPN.gateway=delete VPN Gateway label.delete.vpn.user=Delete VPN user +label.delete=Delete label.deleting.failed=Deleting Failed label.deleting.processing=Deleting.... label.description=Description label.destination.physical.network.id=Destination physical network ID label.destination.zone=Destination Zone -label.destroy=Destroy label.destroy.router=Destroy router +label.destroy=Destroy label.detaching.disk=Detaching Disk label.details=Details label.device.id=Device ID label.devices=Devices -label.dhcp=DHCP label.DHCP.server.type=DHCP Server Type +label.dhcp=DHCP label.direct.ips=Shared Network IPs -label.disabled=Disabled label.disable.provider=Disable provider label.disable.vpn=Disable VPN +label.disabled=Disabled label.disabling.vpn.access=Disabling VPN Access label.disk.allocated=Disk Allocated label.disk.offering=Disk Offering -label.disk.size=Disk Size label.disk.size.gb=Disk Size (in GB) +label.disk.size=Disk Size label.disk.total=Disk Total label.disk.volume=Disk Volume label.display.name=Display name label.display.text=Display Text label.dns.1=DNS 1 label.dns.2=DNS 2 -label.dns=DNS label.DNS.domain.for.guest.networks=DNS domain for Guest Networks +label.dns=DNS label.domain.admin=Domain Admin -label.domain=Domain label.domain.id=Domain ID label.domain.name=Domain Name label.domain.router=Domain router label.domain.suffix=DNS Domain Suffix (i.e., xyz.com) +label.domain=Domain label.done=Done label.double.quotes.are.not.allowed=Double quotes are not allowed label.download.progress=Download Progress label.drag.new.position=Drag to new position -label.edit=Edit +label.edit.affinity.group=Edit Affinity Group label.edit.lb.rule=Edit LB rule label.edit.network.details=Edit network details label.edit.project.details=Edit project details label.edit.tags=Edit tags label.edit.traffic.type=Edit traffic type label.edit.vpc=Edit VPC +label.edit=Edit label.egress.rule=Egress rule label.egress.rules=Egress rules -label.elastic=Elastic label.elastic.IP=Elastic IP label.elastic.LB=Elastic LB +label.elastic=Elastic label.email=Email label.enable.provider=Enable provider label.enable.s3=Enable S3-backed Secondary Storage @@ -502,18 +505,17 @@ label.enable.vpn=Enable VPN label.enabling.vpn.access=Enabling VPN Access label.enabling.vpn=Enabling VPN label.end.IP=End IP -label.endpoint=Endpoint -label.endpoint.or.operation=Endpoint or Operation label.end.port=End Port label.end.reserved.system.IP=End Reserved system IP label.end.vlan=End Vlan +label.endpoint.or.operation=Endpoint or Operation +label.endpoint=Endpoint label.enter.token=Enter token label.error.code=Error Code label.error=Error label.ESP.encryption=ESP Encryption label.ESP.hash=ESP Hash label.ESP.lifetime=ESP Lifetime (second) -label.ESP.lifetime=ESP Lifetime(second) label.ESP.policy=ESP policy label.esx.host=ESX/ESXi Host label.example=Example @@ -527,8 +529,8 @@ label.firewall=Firewall label.first.name=First Name label.format=Format label.friday=Friday -label.full=Full label.full.path=Full path +label.full=Full label.gateway=Gateway label.general.alerts=General Alerts label.generating.url=Generating URL @@ -536,40 +538,39 @@ label.go.step.2=Go to Step 2 label.go.step.3=Go to Step 3 label.go.step.4=Go to Step 4 label.go.step.5=Go to Step 5 -label.group=Group label.group.optional=Group (Optional) +label.group=Group label.guest.cidr=Guest CIDR label.guest.end.ip=Guest end IP label.guest.gateway=Guest Gateway -label.guest=Guest -label.guest.ip=Guest IP Address label.guest.ip.range=Guest IP Range +label.guest.ip=Guest IP Address label.guest.netmask=Guest Netmask label.guest.networks=Guest networks label.guest.start.ip=Guest start IP label.guest.traffic=Guest Traffic label.guest.type=Guest Type +label.guest=Guest label.ha.enabled=HA Enabled label.help=Help label.hide.ingress.rule=Hide Ingress Rule label.hints=Hints label.host.alerts=Host Alerts -label.host=Host label.host.MAC=Host MAC label.host.name=Host Name +label.host.tags=Host Tags +label.host=Host label.hosts=Hosts -label.host.tags=Host Tags label.hourly=Hourly label.hypervisor.capabilities=Hypervisor capabilities -label.hypervisor=Hypervisor label.hypervisor.type=Hypervisor Type label.hypervisor.version=Hypervisor version +label.hypervisor=Hypervisor label.id=ID label.IKE.DH=IKE DH label.IKE.encryption=IKE Encryption label.IKE.hash=IKE Hash label.IKE.lifetime=IKE lifetime (second) -label.IKE.lifetime=IKE Lifetime (second) label.IKE.policy=IKE policy label.info=Info label.ingress.rule=Ingress Rule @@ -584,54 +585,55 @@ label.installWizard.addPrimaryStorageIntro.subtitle=What is primary storage? label.installWizard.addPrimaryStorageIntro.title=Let’s add primary storage label.installWizard.addSecondaryStorageIntro.subtitle=What is secondary storage? label.installWizard.addSecondaryStorageIntro.title=Let’s add secondary storage +label.installWizard.addZone.title=Add zone label.installWizard.addZoneIntro.subtitle=What is a zone? label.installWizard.addZoneIntro.title=Let’s add a zone -label.installWizard.addZone.title=Add zone label.installWizard.click.launch=Click the launch button. -label.installWizard.subtitle=This tour will aid you in setting up your CloudStack™ installation -label.installWizard.title=Hello and Welcome to CloudStack™ -label.instance=Instance +label.installWizard.subtitle=This tour will aid you in setting up your CloudStack&\#8482 installation +label.installWizard.title=Hello and Welcome to CloudStack&\#8482 label.instance.limits=Instance Limits label.instance.name=Instance Name +label.instance=Instance label.instances=Instances label.internal.dns.1=Internal DNS 1 label.internal.dns.2=Internal DNS 2 label.internal.name=Internal name label.interval.type=Interval Type -label.introduction.to.cloudstack=Introduction to CloudStack™ +label.introduction.to.cloudstack=Introduction to CloudStack&\#8482 label.invalid.integer=Invalid Integer label.invalid.number=Invalid Number label.invitations=Invitations -label.invited.accounts=Invited accounts -label.invite=Invite label.invite.to=Invite to +label.invite=Invite +label.invited.accounts=Invited accounts label.ip.address=IP Address -label.ipaddress=IP Address label.ip.allocations=IP Allocations -label.ip=IP label.ip.limits=Public IP Limits label.ip.or.fqdn=IP or FQDN label.ip.range=IP Range label.ip.ranges=IP Ranges -label.IPsec.preshared.key=IPsec Preshared-Key +label.ip=IP +label.ipaddress=IP Address label.ips=IPs -label.iscsi=iSCSI +label.IPsec.preshared.key=IPsec Preshared-Key label.is.default=Is Default +label.is.redundant.router=Redundant +label.is.shared=Is Shared +label.is.system=Is System +label.iscsi=iSCSI label.iso.boot=ISO Boot label.iso=ISO label.isolated.networks=Isolated networks label.isolation.method=Isolation method label.isolation.mode=Isolation Mode label.isolation.uri=Isolation URI -label.is.redundant.router=Redundant -label.is.shared=Is Shared -label.is.system=Is System label.item.listing=Item listing label.keep=Keep -label.keyboard.type=Keyboard type label.key=Key +label.keyboard.type=Keyboard type label.kvm.traffic.label=KVM traffic label label.label=Label +label.lang.arabic=Arabic label.lang.brportugese=Brazilian Portugese label.lang.catalan=Catalan label.lang.chinese=Chinese (Simplified) @@ -647,33 +649,31 @@ label.lang.spanish=Spanish label.last.disconnected=Last Disconnected label.last.name=Last Name label.latest.events=Latest events -label.launch=Launch label.launch.vm=Launch VM -label.launch.zone=Launch zone +label.launch.zone=Launch zone +label.launch=Launch label.LB.isolation=LB isolation label.least.connections=Least connections label.level=Level label.linklocal.ip=Link Local IP Adddress label.load.balancer=Load Balancer -label.load.balancing=Load Balancing label.load.balancing.policies=Load balancing policies +label.load.balancing=Load Balancing label.loading=Loading -label.local=Local label.local.storage.enabled=Local storage enabled -label.local.storage.enabled=Local Storage Enabled label.local.storage=Local Storage +label.local=Local label.login=Login label.logout=Logout +label.LUN.number=LUN \# label.lun=LUN -label.LUN.number=LUN # label.make.project.owner=Make account project owner +label.manage.resources=Manage Resources label.manage=Manage label.management.ips=Management IP Addresses label.management=Management -label.manage.resources=Manage Resources label.max.cpus=Max. CPU cores label.max.guest.limit=Max guest limit -label.maximum=Maximum label.max.memory=Max. memory (MiB) label.max.networks=Max. networks label.max.primary.storage=Max. primary (GiB) @@ -684,13 +684,14 @@ label.max.templates=Max. templates label.max.vms=Max. user VMs label.max.volumes=Max. volumes label.max.vpcs=Max. VPCs +label.maximum=Maximum label.may.continue=You may now continue. label.memory.allocated=Memory Allocated label.memory.limits=Memory limits (MiB) label.memory.mb=Memory (in MB) -label.memory=Memory label.memory.total=Memory Total label.memory.used=Memory Used +label.memory=Memory label.menu.accounts=Accounts label.menu.alerts=Alerts label.menu.all.accounts=All Accounts @@ -714,8 +715,8 @@ label.menu.my.accounts=My Accounts label.menu.my.instances=My Instances label.menu.my.isos=My ISOs label.menu.my.templates=My Templates -label.menu.network=Network label.menu.network.offerings=Network Offerings +label.menu.network=Network label.menu.physical.resources=Physical Resources label.menu.regions=Regions label.menu.running.instances=Running Instances @@ -725,15 +726,15 @@ label.menu.snapshots=Snapshots label.menu.stopped.instances=Stopped Instances label.menu.storage=Storage label.menu.system.service.offerings=System Offerings -label.menu.system=System label.menu.system.vms=System VMs +label.menu.system=System label.menu.templates=Templates label.menu.virtual.appliances=Virtual Appliances label.menu.virtual.resources=Virtual Resources label.menu.volumes=Volumes label.migrate.instance.to.host=Migrate instance to another host -label.migrate.instance.to=Migrate instance to label.migrate.instance.to.ps=Migrate instance to another primary storage +label.migrate.instance.to=Migrate instance to label.migrate.router.to=Migrate Router to label.migrate.systemvm.to=Migrate System VM to label.migrate.to.host=Migrate to host @@ -751,24 +752,22 @@ label.move.up.row=Move up one row label.my.account=My Account label.my.network=My network label.my.templates=My templates -label.name=Name label.name.optional=Name (Optional) +label.name=Name label.nat.port.range=NAT Port Range label.netmask=Netmask label.netScaler=NetScaler +label.network.ACL.total=Network ACL Total label.network.ACL=Network ACL label.network.ACLs=Network ACLs -label.network.ACL.total=Network ACL Total label.network.desc=Network Desc -label.network.device=Network Device label.network.device.type=Network Device Type -label.network.domain=Network Domain +label.network.device=Network Device label.network.domain.text=Network domain +label.network.domain=Network Domain label.network.id=Network ID -label.networking.and.security=Networking and security label.network.label.display.for.blank.value=Use default gateway label.network.name=Network Name -label.network=Network label.network.offering.display.text=Network Offering Display Text label.network.offering.id=Network Offering ID label.network.offering.name=Network Offering Name @@ -777,18 +776,20 @@ label.network.rate.megabytes=Network Rate (Mb/s) label.network.rate=Network Rate label.network.read=Network Read label.network.service.providers=Network Service Providers -label.networks=Networks label.network.type=Network Type label.network.write=Network Write -label.new=New +label.network=Network +label.networking.and.security=Networking and security +label.networks=Networks label.new.password=New Password label.new.project=New Project label.new.vm=New VM +label.new=New label.next=Next label.nexusVswitch=Nexus 1000v -label.nfs=NFS label.nfs.server=NFS Server label.nfs.storage=NFS Storage +label.nfs=NFS label.nic.adapter.type=NIC adapter type label.nicira.controller.address=Controller Address label.nicira.l3gatewayserviceuuid=L3 Gateway Service Uuid @@ -800,20 +801,19 @@ label.no.data=No data to show label.no.errors=No Recent Errors label.no.isos=No available ISOs label.no.items=No Available Items -label.none=None -label.no=No label.no.security.groups=No Available Security Groups -label.not.found=Not Found label.no.thanks=No thanks -label.no.thanks=No Thanks +label.no=No +label.none=None +label.not.found=Not Found label.notifications=Notifications +label.num.cpu.cores=\# of CPU Cores label.number.of.clusters=Number of Clusters label.number.of.hosts=Number of Hosts label.number.of.pods=Number of Pods label.number.of.system.vms=Number of System VMs label.number.of.virtual.routers=Number of Virtual Routers label.number.of.zones=Number of Zones -label.num.cpu.cores=# of CPU Cores label.numretries=Number of Retries label.ocfs2=OCFS2 label.offer.ha=Offer HA @@ -824,14 +824,14 @@ label.os.preference=OS Preference label.os.type=OS Type label.owned.public.ips=Owned Public IP Addresses label.owner.account=Owner Account -label.owner.domain=Owner Domain +label.owner.domain=Owner Domain label.parent.domain=Parent Domain label.password.enabled=Password Enabled label.password=Password label.path=Path label.perfect.forward.secrecy=Perfect Forward Secrecy label.physical.network.ID=Physical network ID -label.physical.network=Physical Network +label.physical.network=Physical Network label.PING.CIFS.password=PING CIFS password label.PING.CIFS.username=PING CIFS username label.PING.dir=PING Directory @@ -847,8 +847,8 @@ label.port.forwarding.policies=Port forwarding policies label.port.forwarding=Port Forwarding label.port.range=Port Range label.PreSetup=PreSetup -label.previous=Previous label.prev=Prev +label.previous=Previous label.primary.allocated=Primary Storage Allocated label.primary.network=Primary Network label.primary.storage.count=Primary Storage Pools @@ -857,20 +857,20 @@ label.primary.storage=Primary Storage label.primary.used=Primary Storage Used label.private.Gateway=Private Gateway label.private.interface=Private Interface -label.private.ip=Private IP Address label.private.ip.range=Private IP Range +label.private.ip=Private IP Address label.private.ips=Private IP Addresses -label.privatekey=PKCS#8 Private Key label.private.network=Private network label.private.port=Private Port label.private.zone=Private Zone +label.privatekey=PKCS\#8 Private Key label.project.dashboard=Project dashboard label.project.id=Project ID label.project.invite=Invite to project label.project.name=Project name +label.project.view=Project View label.project=Project label.projects=Projects -label.project.view=Project View label.protocol=Protocol label.providers=Providers label.public.interface=Public Interface @@ -878,9 +878,9 @@ label.public.ip=Public IP Address label.public.ips=Public IP Addresses label.public.network=Public network label.public.port=Public Port -label.public=Public -label.public.traffic=Public traffic +label.public.traffic=Public traffic label.public.zone=Public Zone +label.public=Public label.purpose=Purpose label.Pxe.server.type=Pxe Server Type label.quickview=Quickview @@ -900,7 +900,6 @@ label.remove.ingress.rule=Remove ingress rule label.remove.ip.range=Remove IP range label.remove.pf=Remove port forwarding rule label.remove.project.account=Remove account from project -label.remove.project.account=Remove project account label.remove.region=Remove Region label.remove.rule=Remove rule label.remove.static.nat.rule=Remove static NAT rule @@ -908,8 +907,8 @@ label.remove.static.route=Remove static route label.remove.tier=Remove tier label.remove.vm.from.lb=Remove VM from load balancer rule label.remove.vpc=remove VPC -label.removing=Removing label.removing.user=Removing User +label.removing=Removing label.required=Required label.reserved.system.gateway=Reserved system gateway label.reserved.system.ip=Reserved System IP @@ -919,9 +918,9 @@ label.resize.new.offering.id=New Offering label.resize.new.size=New Size(GB) label.resize.shrink.ok=Shrink OK label.resource.limits=Resource Limits +label.resource.state=Resource state label.resource=Resource label.resources=Resources -label.resource.state=Resource state label.restart.network=Restart network label.restart.required=Restart required label.restart.vpc=restart VPC @@ -950,36 +949,36 @@ label.scope=Scope label.search=Search label.secondary.storage.count=Secondary Storage Pools label.secondary.storage.limits=Secondary Storage limits (GiB) -label.secondary.storage=Secondary Storage label.secondary.storage.vm=Secondary storage VM +label.secondary.storage=Secondary Storage label.secondary.used=Secondary Storage Used label.secret.key=Secret Key label.security.group.name=Security Group Name label.security.group=Security Group label.security.groups.enabled=Security Groups Enabled label.security.groups=Security Groups +label.select-view=Select view label.select.a.template=Select a template label.select.a.zone=Select a zone -label.select.instance=Select instance label.select.instance.to.attach.volume.to=Select instance to attach volume to +label.select.instance=Select instance label.select.iso.or.template=Select ISO or template label.select.offering=Select offering label.select.project=Select Project -label.select=Select label.select.tier=Select Tier -label.select-view=Select view label.select.vm.for.static.nat=Select VM for static NAT +label.select=Select label.sent=Sent label.server=Server label.service.capabilities=Service Capabilities label.service.offering=Service Offering label.session.expired=Session Expired -label.setup.network=Setup Network -label.setup=Setup -label.setup.zone=Setup Zone label.set.up.zone.type=Set up zone type -label.SharedMountPoint=SharedMountPoint +label.setup.network=Setup Network +label.setup.zone=Setup Zone +label.setup=Setup label.shared=Shared +label.SharedMountPoint=SharedMountPoint label.show.ingress.rule=Show Ingress Rule label.shutdown.provider=Shutdown provider label.site.to.site.VPN=Site-to-site VPN @@ -987,9 +986,9 @@ label.size=Size label.skip.guide=I have used CloudStack before, skip this guide label.snapshot.limits=Snapshot Limits label.snapshot.name=Snapshot Name +label.snapshot.s=Snapshot (s) label.snapshot.schedule=Setup Recurring Snapshot label.snapshot=Snapshot -label.snapshot.s=Snapshot (s) label.snapshots=Snapshots label.source.nat=Source NAT label.source=Source @@ -1003,21 +1002,21 @@ label.start.reserved.system.IP=Start Reserved system IP label.start.vlan=Start Vlan label.state=State label.static.nat.enabled=Static NAT Enabled -label.static.nat=Static NAT label.static.nat.to=Static NAT to label.static.nat.vm.details=Static NAT VM Details +label.static.nat=Static NAT label.statistics=Statistics label.status=Status +label.step.1.title=Step 1\: Select a Template label.step.1=Step 1 -label.step.1.title=Step 1: Select a Template +label.step.2.title=Step 2\: Service Offering label.step.2=Step 2 -label.step.2.title=Step 2: Service Offering +label.step.3.title=Step 3\: Select a Disk Offering label.step.3=Step 3 -label.step.3.title=Step 3: Select a Disk Offering +label.step.4.title=Step 4\: Network label.step.4=Step 4 -label.step.4.title=Step 4: Network +label.step.5.title=Step 5\: Review label.step.5=Step 5 -label.step.5.title=Step 5: Review label.stickiness=Stickiness label.sticky.cookie-name=Cookie name label.sticky.domain=Domain @@ -1031,15 +1030,15 @@ label.sticky.postonly=Post only label.sticky.prefix=Prefix label.sticky.request-learn=Request learn label.sticky.tablesize=Table size -label.stopped.vms=Stopped VMs label.stop=Stop -label.storage=Storage +label.stopped.vms=Stopped VMs label.storage.tags=Storage Tags label.storage.traffic=Storage Traffic label.storage.type=Storage Type +label.storage=Storage label.subdomain.access=Subdomain Access label.submit=Submit -label.submitted.by=[Submitted by: ] +label.submitted.by=[Submitted by\: ] label.succeeded=Succeeded label.sunday=Sunday label.super.cidr.for.guest.networks=Super CIDR for Guest Networks @@ -1049,9 +1048,9 @@ label.suspend.project=Suspend Project label.system.capacity=System Capacity label.system.offering=System Offering label.system.service.offering=System Service Offering -label.system.vms=System VMs -label.system.vm=System VM label.system.vm.type=System VM Type +label.system.vm=System VM +label.system.vms=System VMs label.system.wide.capacity=System-wide capacity label.tagged=Tagged label.tags=Tags @@ -1066,14 +1065,14 @@ label.theme.lightblue=Custom - Light Blue label.thursday=Thursday label.tier.details=Tier details label.tier=Tier +label.time.zone=Timezone +label.time=Time label.timeout.in.second = Timeout(seconds) label.timeout=Timeout -label.time=Time -label.time.zone=Timezone label.timezone=Timezone label.token=Token -label.total.cpu=Total CPU label.total.CPU=Total CPU +label.total.cpu=Total CPU label.total.hosts=Total Hosts label.total.memory=Total Memory label.total.of.ip=Total of IP Address @@ -1081,8 +1080,8 @@ label.total.of.vm=Total of VM label.total.storage=Total Storage label.total.vms=Total VMs label.traffic.label=Traffic label -label.traffic.types=Traffic Types label.traffic.type=Traffic Type +label.traffic.types=Traffic Types label.tuesday=Tuesday label.type.id=Type ID label.type=Type @@ -1093,15 +1092,15 @@ label.update.project.resources=Update project resources label.update.ssl.cert= SSL Certificate label.update.ssl= SSL Certificate label.updating=Updating -label.upload=Upload label.upload.volume=Upload volume +label.upload=Upload label.url=URL label.usage.interface=Usage Interface +label.use.vm.ip=Use VM IP\: label.used=Used +label.user=User label.username=Username label.users=Users -label.user=User -label.use.vm.ip=Use VM IP: label.value=Value label.vcdcname=vCenter DC name label.vcenter.cluster=vCenter Cluster @@ -1114,47 +1113,47 @@ label.vcipaddress=vCenter IP Address label.version=Version label.view.all=View all label.view.console=View console -label.viewing=Viewing label.view.more=View more label.view=View -label.virtual.appliances=Virtual Appliances +label.viewing=Viewing label.virtual.appliance=Virtual Appliance +label.virtual.appliances=Virtual Appliances label.virtual.machines=Virtual machines label.virtual.network=Virtual Network -label.virtual.routers=Virtual Routers label.virtual.router=Virtual Router +label.virtual.routers=Virtual Routers label.vlan.id=VLAN ID label.vlan.range=VLAN Range label.vlan=VLAN label.vm.add=Add Instance label.vm.destroy=Destroy label.vm.display.name=VM display name -label.VMFS.datastore=VMFS datastore -label.vmfs=VMFS label.vm.name=VM name label.vm.reboot=Reboot +label.vm.start=Start +label.vm.state=VM state +label.vm.stop=Stop +label.VMFS.datastore=VMFS datastore +label.vmfs=VMFS label.VMs.in.tier=VMs in tier +label.vms=VMs label.vmsnapshot.current=isCurrent label.vmsnapshot.memory=Snapshot memory label.vmsnapshot.parentname=Parent label.vmsnapshot.type=Type label.vmsnapshot=VM Snapshots -label.vm.start=Start -label.vm.state=VM state -label.vm.stop=Stop -label.vms=VMs label.vmware.traffic.label=VMware traffic label label.volgroup=Volume Group label.volume.limits=Volume Limits label.volume.name=Volume Name -label.volumes=Volumes label.volume=Volume +label.volumes=Volumes label.vpc.id=VPC ID label.VPC.router.details=VPC router details label.vpc=VPC label.VPN.connection=VPN Connection -label.vpn.customer.gateway=VPN Customer Gateway label.VPN.customer.gateway=VPN Customer Gateway +label.vpn.customer.gateway=VPN Customer Gateway label.VPN.gateway=VPN Gateway label.vpn=VPN label.vsmctrlvlanid=Control VLAN ID @@ -1167,27 +1166,27 @@ label.wednesday=Wednesday label.weekly=Weekly label.welcome.cloud.console=Welcome to Management Console label.welcome=Welcome -label.what.is.cloudstack=What is CloudStack™? +label.what.is.cloudstack=What is CloudStack&\#8482? label.xen.traffic.label=XenServer traffic label label.yes=Yes label.zone.details=Zone details label.zone.id=Zone ID label.zone.name=Zone name -label.zone.step.1.title=Step 1: Select a Network -label.zone.step.2.title=Step 2: Add a Zone -label.zone.step.3.title=Step 3: Add a Pod -label.zone.step.4.title=Step 4: Add an IP range -label.zones=Zones +label.zone.step.1.title=Step 1\: Select a Network +label.zone.step.2.title=Step 2\: Add a Zone +label.zone.step.3.title=Step 3\: Add a Pod +label.zone.step.4.title=Step 4\: Add an IP range label.zone.type=Zone Type label.zone.wide=Zone-Wide -label.zoneWizard.trafficType.guest=Guest: Traffic between end-user virtual machines -label.zoneWizard.trafficType.management=Management: Traffic between CloudStack\'s internal resources, including any components that communicate with the Management Server, such as hosts and CloudStack system VMs -label.zoneWizard.trafficType.public=Public: Traffic between the internet and virtual machines in the cloud. -label.zoneWizard.trafficType.storage=Storage: Traffic between primary and secondary storage servers, such as VM templates and snapshots label.zone=Zone +label.zones=Zones +label.zoneWizard.trafficType.guest=Guest\: Traffic between end-user virtual machines +label.zoneWizard.trafficType.management=Management\: Traffic between CloudStack\\\\'s internal resources, including any components that communicate with the Management Server, such as hosts and CloudStack system VMs +label.zoneWizard.trafficType.public=Public\: Traffic between the internet and virtual machines in the cloud. +label.zoneWizard.trafficType.storage=Storage\: Traffic between primary and secondary storage servers, such as VM templates and snapshots managed.state=Managed State -message.acquire.new.ip=Please confirm that you would like to acquire a new IP for this network. message.acquire.new.ip.vpc=Please confirm that you would like to acquire a new IP for this VPC. +message.acquire.new.ip=Please confirm that you would like to acquire a new IP for this network. message.acquire.public.ip=Please select a zone from which you want to acquire your new IP from. message.action.cancel.maintenance.mode=Please confirm that you want to cancel this maintenance. message.action.cancel.maintenance=Your host has been successfully canceled for maintenance. This process can take up to several minutes. @@ -1196,8 +1195,8 @@ message.action.change.service.warning.for.router=Your router must be stopped bef message.action.delete.cluster=Please confirm that you want to delete this cluster. message.action.delete.disk.offering=Please confirm that you want to delete this disk offering. message.action.delete.domain=Please confirm that you want to delete this domain. -message.action.delete.external.firewall=Please confirm that you would like to remove this external firewall. Warning: If you are planning to add back the same external firewall, you must reset usage data on the device. -message.action.delete.external.load.balancer=Please confirm that you would like to remove this external load balancer. Warning: If you are planning to add back the same external load balancer, you must reset usage data on the device. +message.action.delete.external.firewall=Please confirm that you would like to remove this external firewall. Warning\: If you are planning to add back the same external firewall, you must reset usage data on the device. +message.action.delete.external.load.balancer=Please confirm that you would like to remove this external load balancer. Warning\: If you are planning to add back the same external load balancer, you must reset usage data on the device. message.action.delete.ingress.rule=Please confirm that you want to delete this ingress rule. message.action.delete.ISO.for.all.zones=The ISO is used by all zones. Please confirm that you want to delete it from all zones. message.action.delete.ISO=Please confirm that you want to delete this ISO. @@ -1233,15 +1232,14 @@ message.action.enable.pod=Please confirm that you want to enable this pod. message.action.enable.zone=Please confirm that you want to enable this zone. message.action.force.reconnect=Your host has been successfully forced to reconnect. This process can take up to several minutes. message.action.host.enable.maintenance.mode=Enabling maintenance mode will cause a live migration of all running instances on this host to any available host. -message.action.instance.reset.password=Please confirm that you want to change the ROOT password for this virtual machine. +message.action.instance.reset.password=Please confirm that you want to change the ROOT password for this virtual machine. message.action.manage.cluster=Please confirm that you want to manage the cluster. -message.action.primarystorage.enable.maintenance.mode=Warning: placing the primary storage into maintenance mode will cause all VMs using volumes from it to be stopped. Do you want to continue? +message.action.primarystorage.enable.maintenance.mode=Warning\: placing the primary storage into maintenance mode will cause all VMs using volumes from it to be stopped. Do you want to continue? message.action.reboot.instance=Please confirm that you want to reboot this instance. message.action.reboot.router=All services provided by this virtual router will be interrupted. Please confirm that you want to reboot this router. message.action.reboot.systemvm=Please confirm that you want to reboot this system VM. message.action.release.ip=Please confirm that you want to release this IP. message.action.remove.host=Please confirm that you want to remove this host. -message.action.remove.host=Removing last/only host in cluster and reinstalling the host will destroy working environment/database on the host and render the VM Guests unuseable. message.action.reset.password.off=Your instance currently does not support this feature. message.action.reset.password.warning=Your instance must be stopped before attempting to change its current password. message.action.restore.instance=Please confirm that you want to restore this instance. @@ -1256,40 +1254,40 @@ message.action.unmanage.cluster=Please confirm that you want to unmanage the clu message.action.vmsnapshot.delete=Please confirm that you want to delete this VM snapshot. message.action.vmsnapshot.revert=Revert VM snapshot message.activate.project=Are you sure you want to activate this project? -message.add.cluster=Add a hypervisor managed cluster for zone , pod -message.add.cluster.zone=Add a hypervisor managed cluster for zone +message.add.cluster.zone=Add a hypervisor managed cluster for zone +message.add.cluster=Add a hypervisor managed cluster for zone , pod message.add.disk.offering=Please specify the following parameters to add a new disk offering message.add.domain=Please specify the subdomain you want to create under this domain message.add.firewall=Add a firewall to zone message.add.guest.network=Please confirm that you would like to add a guest network message.add.host=Please specify the following parameters to add a new host -message.adding.host=Adding host -message.adding.Netscaler.device=Adding Netscaler device -message.adding.Netscaler.provider=Adding Netscaler provider +message.add.ip.range.direct.network=Add an IP range to direct network in zone +message.add.ip.range.to.pod=

Add an IP range to pod\:

message.add.ip.range=Add an IP range to public network in zone -message.add.ip.range.direct.network=Add an IP range to direct network in zone -message.add.ip.range.to.pod=

Add an IP range to pod:

-message.additional.networks.desc=Please select additional network(s) that your virtual instance will be connected to. +message.add.load.balancer.under.ip=The load balancer rule has been added under IP\: message.add.load.balancer=Add a load balancer to zone -message.add.load.balancer.under.ip=The load balancer rule has been added under IP: -message.add.network=Add a new network for zone: +message.add.network=Add a new network for zone\: message.add.new.gateway.to.vpc=Please specify the information to add a new gateway to this VPC. -message.add.pod=Add a new pod for zone -message.add.pod.during.zone.creation=Each zone must contain in one or more pods, and we will add the first pod now. A pod contains hosts and primary storage servers, which you will add in a later step. First, configure a range of reserved IP addresses for CloudStack's internal management traffic. The reserved IP range must be unique for each zone in the cloud. +message.add.pod.during.zone.creation=Each zone must contain in one or more pods, and we will add the first pod now. A pod contains hosts and primary storage servers, which you will add in a later step. First, configure a range of reserved IP addresses for CloudStack\\'s internal management traffic. The reserved IP range must be unique for each zone in the cloud. +message.add.pod=Add a new pod for zone +message.add.primary.storage=Add a new Primary Storage for zone , pod message.add.primary=Please specify the following parameters to add a new primary storage -message.add.primary.storage=Add a new Primary Storage for zone , pod message.add.region=Please specify the required information to add a new region. -message.add.secondary.storage=Add a new storage for zone +message.add.secondary.storage=Add a new storage for zone message.add.service.offering=Please fill in the following data to add a new compute offering. message.add.system.service.offering=Please fill in the following data to add a new system service offering. message.add.template=Please enter the following data to create your new template message.add.volume=Please fill in the following data to add a new volume. message.add.VPN.gateway=Please confirm that you want to add a VPN Gateway +message.adding.host=Adding host +message.adding.Netscaler.device=Adding Netscaler device +message.adding.Netscaler.provider=Adding Netscaler provider +message.additional.networks.desc=Please select additional network(s) that your virtual instance will be connected to. message.advanced.mode.desc=Choose this network model if you wish to enable VLAN support. This network model provides the most flexibility in allowing administrators to provide custom network offerings such as providing firewall, vpn, or load balancer support as well as enabling direct vs virtual networking. message.advanced.security.group=Choose this if you wish to use security groups to provide guest VM isolation. message.advanced.virtual=Choose this if you wish to use zone-wide VLANs to provide guest VM isolation. -message.after.enable.s3=S3-backed Secondary Storage configured. Note: When you leave this page, you will not be able to re-configure S3 again. -message.after.enable.swift=Swift configured. Note: When you leave this page, you will not be able to re-configure Swift again. +message.after.enable.s3=S3-backed Secondary Storage configured. Note\: When you leave this page, you will not be able to re-configure S3 again. +message.after.enable.swift=Swift configured. Note\: When you leave this page, you will not be able to re-configure Swift again. message.alert.state.detected=Alert state detected message.allow.vpn.access=Please enter a username and password of the user that you want to allow VPN access. message.apply.snapshot.policy=You have successfully updated your current snapshot policy. @@ -1314,10 +1312,10 @@ message.confirm.join.project=Please confirm you wish to join this project. message.confirm.remove.IP.range=Please confirm that you would like to remove this IP range. message.confirm.shutdown.provider=Please confirm that you would like to shutdown this provider message.copy.iso.confirm=Please confirm that you wish to copy your ISO to -message.copy.template=Copy template XXX from zone to +message.copy.template=Copy template XXX from zone to +message.create.template.vm=Create VM from template +message.create.template.volume=Please specify the following information before creating a template of your disk volume\: . Creation of the template can range from several minutes to longer depending on the size of the volume. message.create.template=Are you sure you want to create template? -message.create.template.vm=Create VM from template -message.create.template.volume=Please specify the following information before creating a template of your disk volume: . Creation of the template can range from several minutes to longer depending on the size of the volume. message.creating.cluster=Creating cluster message.creating.guest.network=Creating guest network message.creating.physical.networks=Creating physical networks @@ -1327,6 +1325,7 @@ message.creating.secondary.storage=Creating secondary storage message.creating.zone=Creating zone message.decline.invitation=Are you sure you want to decline this project invitation? message.delete.account=Please confirm that you want to delete this account. +message.delete.affinity.group=Please confirm that you would like to remove this affinity group. message.delete.gateway=Please confirm you want to delete the gateway message.delete.project=Are you sure you want to delete this project? message.delete.user=Please confirm that you would like to delete this user. @@ -1336,31 +1335,31 @@ message.delete.VPN.gateway=Please confirm that you want to delete this VPN Gatew message.desc.advanced.zone=For more sophisticated network topologies. This network model provides the most flexibility in defining guest networks and providing custom network offerings such as firewall, VPN, or load balancer support. message.desc.basic.zone=Provide a single network where each VM instance is assigned an IP directly from the network. Guest isolation can be provided through layer-3 means such as security groups (IP address source filtering). message.desc.cluster=Each pod must contain one or more clusters, and we will add the first cluster now. A cluster provides a way to group hosts. The hosts in a cluster all have identical hardware, run the same hypervisor, are on the same subnet, and access the same shared storage. Each cluster consists of one or more hosts and one or more primary storage servers. -message.desc.host=Each cluster must contain at least one host (computer) for guest VMs to run on, and we will add the first host now. For a host to function in CloudStack, you must install hypervisor software on the host, assign an IP address to the host, and ensure the host is connected to the CloudStack management server.

Give the host's DNS or IP address, the user name (usually root) and password, and any labels you use to categorize hosts. +message.desc.host=Each cluster must contain at least one host (computer) for guest VMs to run on, and we will add the first host now. For a host to function in CloudStack, you must install hypervisor software on the host, assign an IP address to the host, and ensure the host is connected to the CloudStack management server.

Give the host\\'s DNS or IP address, the user name (usually root) and password, and any labels you use to categorize hosts. message.desc.primary.storage=Each cluster must contain one or more primary storage servers, and we will add the first one now. Primary storage contains the disk volumes for all the VMs running on hosts in the cluster. Use any standards-compliant protocol that is supported by the underlying hypervisor. message.desc.secondary.storage=Each zone must have at least one NFS or secondary storage server, and we will add the first one now. Secondary storage stores VM templates, ISO images, and VM disk volume snapshots. This server must be available to all hosts in the zone.

Provide the IP address and exported path. message.desc.zone=A zone is the largest organizational unit in CloudStack, and it typically corresponds to a single datacenter. Zones provide physical isolation and redundancy. A zone consists of one or more pods (each of which contains hosts and primary storage servers) and a secondary storage server which is shared by all pods in the zone. message.detach.disk=Are you sure you want to detach this disk? message.detach.iso.confirm=Please confirm that you want to detach the ISO from this virtual instance. -message.disable.account=Please confirm that you want to disable this account. By disabling the account, all users for this account will no longer have access to their cloud resources. All running virtual machines will be immediately shut down. +message.disable.account=Please confirm that you want to disable this account. By disabling the account, all users for this account will no longer have access to their cloud resources. All running virtual machines will be immediately shut down. message.disable.snapshot.policy=You have successfully disabled your current snapshot policy. message.disable.user=Please confirm that you would like to disable this user. message.disable.vpn.access=Please confirm that you want to disable VPN Access. message.disable.vpn=Are you sure you want to disable VPN? -message.download.ISO=Please click 00000 to download ISO -message.download.template=Please click 00000 to download template +message.download.ISO=Please click 00000 to download ISO +message.download.template=Please click 00000 to download template message.download.volume.confirm=Please confirm that you want to download this volume -message.download.volume=Please click 00000 to download volume +message.download.volume=Please click 00000 to download volume message.edit.account=Edit ("-1" indicates no limit to the amount of resources create) message.edit.confirm=Please confirm that your changes before clicking "Save". message.edit.limits=Please specify limits to the following resources. A "-1" indicates no limit to the amount of resources create. message.edit.traffic.type=Please specify the traffic label you want associated with this traffic type. message.enable.account=Please confirm that you want to enable this account. -message.enabled.vpn.ip.sec=Your IPSec pre-shared key is -message.enabled.vpn=Your VPN access is currently enabled and can be accessed via the IP message.enable.user=Please confirm that you would like to enable this user. message.enable.vpn.access=VPN is currently disabled for this IP Address. Would you like to enable VPN access? message.enable.vpn=Please confirm that you want VPN access enabled for this IP address. +message.enabled.vpn.ip.sec=Your IPSec pre-shared key is +message.enabled.vpn=Your VPN access is currently enabled and can be accessed via the IP message.enabling.security.group.provider=Enabling Security Group provider message.enabling.zone=Enabling zone message.enter.token=Please enter the token that you were given in your invite e-mail. @@ -1368,14 +1367,14 @@ message.generate.keys=Please confirm that you would like to generate new keys fo message.guest.traffic.in.advanced.zone=Guest network traffic is communication between end-user virtual machines. Specify a range of VLAN IDs to carry guest traffic for each physical network. message.guest.traffic.in.basic.zone=Guest network traffic is communication between end-user virtual machines. Specify a range of IP addresses that CloudStack can assign to guest VMs. Make sure this range does not overlap the reserved system IP range. message.installWizard.click.retry=Click the button to retry launch. -message.installWizard.copy.whatIsACluster=A cluster provides a way to group hosts. The hosts in a cluster all have identical hardware, run the same hypervisor, are on the same subnet, and access the same shared storage. Virtual machine instances (VMs) can be live-migrated from one host to another within the same cluster, without interrupting service to the user. A cluster is the third-largest organizational unit within a CloudStack™ deployment. Clusters are contained within pods, and pods are contained within zones.

CloudStack™ allows multiple clusters in a cloud deployment, but for a Basic Installation, we only need one cluster. -message.installWizard.copy.whatIsAHost=A host is a single computer. Hosts provide the computing resources that run the guest virtual machines. Each host has hypervisor software installed on it to manage the guest VMs (except for bare metal hosts, which are a special case discussed in the Advanced Installation Guide). For example, a Linux KVM-enabled server, a Citrix XenServer server, and an ESXi server are hosts. In a Basic Installation, we use a single host running XenServer or KVM.

The host is the smallest organizational unit within a CloudStack™ deployment. Hosts are contained within clusters, clusters are contained within pods, and pods are contained within zones. -message.installWizard.copy.whatIsAPod=A pod often represents a single rack. Hosts in the same pod are in the same subnet.

A pod is the second-largest organizational unit within a CloudStack™ deployment. Pods are contained within zones. Each zone can contain one or more pods; in the Basic Installation, you will have just one pod in your zone. -message.installWizard.copy.whatIsAZone=A zone is the largest organizational unit within a CloudStack™ deployment. A zone typically corresponds to a single datacenter, although it is permissible to have multiple zones in a datacenter. The benefit of organizing infrastructure into zones is to provide physical isolation and redundancy. For example, each zone can have its own power supply and network uplink, and the zones can be widely separated geographically (though this is not required). -message.installWizard.copy.whatIsCloudStack=CloudStack™ is a software platform that pools computing resources to build public, private, and hybrid Infrastructure as a Service (IaaS) clouds. CloudStack™ manages the network, storage, and compute nodes that make up a cloud infrastructure. Use CloudStack™ to deploy, manage, and configure cloud computing environments.

Extending beyond individual virtual machine images running on commodity hardware, CloudStack™ provides a turnkey cloud infrastructure software stack for delivering virtual datacenters as a service - delivering all of the essential components to build, deploy, and manage multi-tier and multi-tenant cloud applications. Both open-source and Premium versions are available, with the open-source version offering nearly identical features. -message.installWizard.copy.whatIsPrimaryStorage=A CloudStack™ cloud infrastructure makes use of two types of storage: primary storage and secondary storage. Both of these can be iSCSI or NFS servers, or localdisk.

Primary storage is associated with a cluster, and it stores the disk volumes of each guest VM for all the VMs running on hosts in that cluster. The primary storage server is typically located close to the hosts. -message.installWizard.copy.whatIsSecondaryStorage=Secondary storage is associated with a zone, and it stores the following:
  • Templates - OS images that can be used to boot VMs and can include additional configuration information, such as installed applications
  • ISO images - OS images that can be bootable or non-bootable
  • Disk volume snapshots - saved copies of VM data which can be used for data recovery or to create new templates
-message.installWizard.now.building=Now building your cloud... +message.installWizard.copy.whatIsACluster=A cluster provides a way to group hosts. The hosts in a cluster all have identical hardware, run the same hypervisor, are on the same subnet, and access the same shared storage. Virtual machine instances (VMs) can be live-migrated from one host to another within the same cluster, without interrupting service to the user. A cluster is the third-largest organizational unit within a CloudStack&\#8482; deployment. Clusters are contained within pods, and pods are contained within zones.

CloudStack&\#8482; allows multiple clusters in a cloud deployment, but for a Basic Installation, we only need one cluster. +message.installWizard.copy.whatIsAHost=A host is a single computer. Hosts provide the computing resources that run the guest virtual machines. Each host has hypervisor software installed on it to manage the guest VMs (except for bare metal hosts, which are a special case discussed in the Advanced Installation Guide). For example, a Linux KVM-enabled server, a Citrix XenServer server, and an ESXi server are hosts. In a Basic Installation, we use a single host running XenServer or KVM.

The host is the smallest organizational unit within a CloudStack&\#8482; deployment. Hosts are contained within clusters, clusters are contained within pods, and pods are contained within zones. +message.installWizard.copy.whatIsAPod=A pod often represents a single rack. Hosts in the same pod are in the same subnet.

A pod is the second-largest organizational unit within a CloudStack&\#8482; deployment. Pods are contained within zones. Each zone can contain one or more pods; in the Basic Installation, you will have just one pod in your zone. +message.installWizard.copy.whatIsAZone=A zone is the largest organizational unit within a CloudStack&\#8482; deployment. A zone typically corresponds to a single datacenter, although it is permissible to have multiple zones in a datacenter. The benefit of organizing infrastructure into zones is to provide physical isolation and redundancy. For example, each zone can have its own power supply and network uplink, and the zones can be widely separated geographically (though this is not required). +message.installWizard.copy.whatIsCloudStack=CloudStack&\#8482 is a software platform that pools computing resources to build public, private, and hybrid Infrastructure as a Service (IaaS) clouds. CloudStack&\#8482 manages the network, storage, and compute nodes that make up a cloud infrastructure. Use CloudStack&\#8482 to deploy, manage, and configure cloud computing environments.

Extending beyond individual virtual machine images running on commodity hardware, CloudStack&\#8482 provides a turnkey cloud infrastructure software stack for delivering virtual datacenters as a service - delivering all of the essential components to build, deploy, and manage multi-tier and multi-tenant cloud applications. Both open-source and Premium versions are available, with the open-source version offering nearly identical features. +message.installWizard.copy.whatIsPrimaryStorage=A CloudStack&\#8482; cloud infrastructure makes use of two types of storage\: primary storage and secondary storage. Both of these can be iSCSI or NFS servers, or localdisk.

Primary storage is associated with a cluster, and it stores the disk volumes of each guest VM for all the VMs running on hosts in that cluster. The primary storage server is typically located close to the hosts. +message.installWizard.copy.whatIsSecondaryStorage=Secondary storage is associated with a zone, and it stores the following\:
  • Templates - OS images that can be used to boot VMs and can include additional configuration information, such as installed applications
  • ISO images - OS images that can be bootable or non-bootable
  • Disk volume snapshots - saved copies of VM data which can be used for data recovery or to create new templates
+message.installWizard.now.building=Now building your cloud... message.installWizard.tooltip.addCluster.name=A name for the cluster. This can be text of your choosing and is not used by CloudStack. message.installWizard.tooltip.addHost.hostname=The DNS name or IP address of the host. message.installWizard.tooltip.addHost.password=This is the password for the user named above (from your XenServer install). @@ -1405,26 +1404,26 @@ message.instanceWizard.noTemplates=You do not have any templates available; plea message.ip.address.changed=Your IP addresses may have changed; would you like to refresh the listing? Note that in this case the details pane will close. message.iso.desc=Disc image containing data or bootable media for OS message.join.project=You have now joined a project. Please switch to Project view to see the project. -message.launch.vm.on.private.network=Do you wish to launch your instance on your own private dedicated network? +message.launch.vm.on.private.network=Do you wish to launch your instance on your own private dedicated network? message.launch.zone=Zone is ready to launch; please proceed to the next step. message.lock.account=Please confirm that you want to lock this account. By locking the account, all users for this account will no longer be able to manage their cloud resources. Existing resources can still be accessed. message.migrate.instance.confirm=Please confirm the host you wish to migrate the virtual instance to. message.migrate.instance.to.host=Please confirm that you want to migrate instance to another host. message.migrate.instance.to.ps=Please confirm that you want to migrate instance to another primary storage. -message.migrate.router.confirm=Please confirm the host you wish to migrate the router to: -message.migrate.systemvm.confirm=Please confirm the host you wish to migrate the system VM to: +message.migrate.router.confirm=Please confirm the host you wish to migrate the router to\: +message.migrate.systemvm.confirm=Please confirm the host you wish to migrate the system VM to\: message.migrate.volume=Please confirm that you want to migrate volume to another primary storage. -message.new.user=Specify the following to add a new user to the account +message.new.user=Specify the following to add a new user to the account message.no.network.support.configuration.not.true=You do not have any zone that has security group enabled. Thus, no additional network features. Please continue to step 5. message.no.network.support=Your selected hypervisor, vSphere, does not have any additional network features. Please continue to step 5. message.no.projects.adminOnly=You do not have any projects.
Please ask your administrator to create a new project. message.no.projects=You do not have any projects.
Please create a new one from the projects section. -message.number.clusters=

# of Clusters

-message.number.hosts=

# of Hosts

-message.number.pods=

# of Pods

-message.number.storage=

# of Primary Storage Volumes

-message.number.zones=

# of Zones

-message.pending.projects.1=You have pending project invitations: +message.number.clusters=

\# of Clusters

+message.number.hosts=

\# of Hosts

+message.number.pods=

\# of Pods

+message.number.storage=

\# of Primary Storage Volumes

+message.number.zones=

\# of Zones

+message.pending.projects.1=You have pending project invitations\: message.pending.projects.2=To view, please go to the projects section, then select invitations from the drop-down. message.please.add.at.lease.one.traffic.range=Please add at least one traffic range. message.please.proceed=Please proceed to the next step. @@ -1455,7 +1454,7 @@ message.select.security.groups=Please select security group(s) for your new VM message.select.template=Please select a template for your new virtual instance. message.setup.physical.network.during.zone.creation.basic=When adding a basic zone, you can set up one physical network, which corresponds to a NIC on the hypervisor. The network carries several types of traffic.

You may also drag and drop other traffic types onto the physical network. message.setup.physical.network.during.zone.creation=When adding an advanced zone, you need to set up one or more physical networks. Each network corresponds to a NIC on the hypervisor. Each physical network can carry one or more types of traffic, with certain restrictions on how they may be combined.

Drag and drop one or more traffic types onto each physical network. -message.setup.successful=Cloud setup successful! +message.setup.successful=Cloud setup successful\! message.snapshot.schedule=You can setup recurring snapshot schedules by selecting from the available options below and applying your policy preference message.specify.url=Please specify URL message.step.1.continue=Please select a template or ISO to continue @@ -1466,7 +1465,7 @@ message.step.3.continue=Please select a disk offering to continue message.step.3.desc= message.step.4.continue=Please select at least one network to continue message.step.4.desc=Please select the primary network that your virtual instance will be connected to. -message.storage.traffic=Traffic between CloudStack's internal resources, including any components that communicate with the Management Server, such as hosts and CloudStack system VMs. Please configure storage traffic here. +message.storage.traffic=Traffic between CloudStack\\'s internal resources, including any components that communicate with the Management Server, such as hosts and CloudStack system VMs. Please configure storage traffic here. message.suspend.project=Are you sure you want to suspend this project? message.template.desc=OS image that can be used to boot VMs message.tooltip.dns.1=Name of a DNS server for use by VMs in the zone. The public IP addresses for the zone must have a route to this server. @@ -1480,7 +1479,7 @@ message.tooltip.reserved.system.netmask=The network prefix that defines the pod message.tooltip.zone.name=A name for the zone. message.update.os.preference=Please choose a OS preference for this host. All virtual instances with similar preferences will be first allocated to this host before choosing another. message.update.resource.count=Please confirm that you want to update resource counts for this account. -message.update.ssl=Please submit a new X.509 compliant SSL certificate to be updated to each console proxy virtual instance: +message.update.ssl=Please submit a new X.509 compliant SSL certificate to be updated to each console proxy virtual instance\: message.validate.instance.name=Instance name can not be longer than 63 characters. Only ASCII letters a~z, A~Z, digits 0~9, hyphen are allowed. Must start with a letter and end with a letter or a digit. message.virtual.network.desc=A dedicated virtualized network for your account. The broadcast domain is contained within a VLAN and all public network access is routed out by a virtual router. message.vm.create.template.confirm=Create Template will reboot the VM automatically. @@ -1491,9 +1490,9 @@ message.zone.creation.complete.would.you.like.to.enable.this.zone=Zone creation message.Zone.creation.complete=Zone creation complete message.zone.no.network.selection=The zone you selected does not have any choices for network selection. message.zone.step.1.desc=Please select a network model for your zone. -message.zone.step.2.desc=Please enter the following info to add a new zone -message.zone.step.3.desc=Please enter the following info to add a new pod -message.zoneWizard.enable.local.storage=WARNING: If you enable local storage for this zone, you must do the following, depending on where you would like your system VMs to launch:

1. If system VMs need to be launched in primary storage, primary storage needs to be added to the zone after creation. You must also start the zone in a disabled state.

2. If system VMs need to be launched in local storage, system.vm.use.local.storage needs to be set to true before you enable the zone.


Would you like to continue? +message.zone.step.2.desc=Please enter the following info to add a new zone +message.zone.step.3.desc=Please enter the following info to add a new pod +message.zoneWizard.enable.local.storage=WARNING\: If you enable local storage for this zone, you must do the following, depending on where you would like your system VMs to launch\:

1. If system VMs need to be launched in primary storage, primary storage needs to be added to the zone after creation. You must also start the zone in a disabled state.

2. If system VMs need to be launched in local storage, system.vm.use.local.storage needs to be set to true before you enable the zone.


Would you like to continue? mode=Mode network.rate=Network Rate notification.reboot.instance=Reboot instance @@ -1511,14 +1510,14 @@ state.Creating=Creating state.Declined=Declined state.Destroyed=Destroyed state.Disabled=Disabled -state.enabled=Enabled state.Enabled=Enabled +state.enabled=Enabled state.Error=Error state.Expunging=Expunging state.Migrating=Migrating state.Pending=Pending -state.ready=Ready state.Ready=Ready +state.ready=Ready state.Running=Running state.Starting=Starting state.Stopped=Stopped diff --git a/client/WEB-INF/classes/resources/messages_ar.properties b/client/WEB-INF/classes/resources/messages_ar.properties new file mode 100644 index 00000000000..4d3011b5a6c --- /dev/null +++ b/client/WEB-INF/classes/resources/messages_ar.properties @@ -0,0 +1,285 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + + +changed.item.properties=\u062a\u063a\u064a\u0631 \u062e\u0635\u0627\u0626\u0635 \u0627\u0644\u0639\u0646\u0635\u0631 +confirm.enable.s3=\u0641\u0636\u0644\u0627 \u0642\u0645 \u0628\u062a\u0639\u0628\u0626\u0629 \u0627\u0644\u0628\u064a\u0627\u0646\u0627\u062a \u0627\u0644\u0642\u0627\u062f\u0645\u0629 \u0644\u062a\u0645\u0643\u064a\u0646 \u0627\u0644\u062a\u062e\u0632\u064a\u0646 S3 \u0644\u0644\u0630\u0627\u0643\u0631\u0629 \u0627\u0644\u062b\u0627\u0646\u0648\u064a\u0629. +instances.actions.reboot.label=\u0625\u0639\u0627\u062f\u0629 \u062a\u0634\u063a\u064a\u0644 \u0627\u0644\u0646\u0645\u0648\u0630\u062c +label.accept.project.invitation=\u0642\u0628\u0648\u0644 \u062f\u0639\u0648\u0629 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 +label.action.delete.system.service.offering=\u062d\u0630\u0641 \u0646\u0638\u0627\u0645 \u062a\u0642\u062f\u064a\u0645 \u0627\u0644\u062e\u062f\u0645\u0629 +label.action.disable.physical.network=\u062a\u0639\u0637\u064a\u0644 \u0634\u0628\u0643\u0629 \u0641\u064a\u0632\u064a\u0627\u0626\u064a\u0629 +label.action.enable.physical.network=\u062a\u0645\u0643\u064a\u0646 \u0634\u0628\u0643\u0629 \u0641\u064a\u0632\u064a\u0627\u0626\u064a\u0629 +label.activate.project=\u062a\u0641\u0639\u064a\u0644 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 +label.add.accounts.to=\u0625\u0636\u0627\u0641\u0629 \u062d\u0633\u0627\u0628\u0627\u062a \u0625\u0644\u0649 +label.add.accounts=\u0625\u0636\u0627\u0641\u0629 \u062d\u0633\u0627\u0628\u0627\u062a +label.add.account.to.project=\u0625\u0636\u0627\u0641\u0629 \u062d\u0633\u0627\u0628 \u0644\u0644\u0645\u0634\u0631\u0648\u0639 +label.add.ACL=\u0625\u0636\u0627\u0641\u0629 ACL +label.add.network.ACL=\u0625\u0636\u0627\u0641\u0629 \u0634\u0628\u0643\u0629 ACL +label.add.new.gateway=\u0623\u0636\u0641 \u0628\u0648\u0627\u0628\u0629 \u062c\u062f\u064a\u062f\u0629 +label.add.new.tier=\u0625\u0636\u0627\u0641\u0629 \u0637\u0628\u0642\u0629 \u062c\u062f\u064a\u062f\u0629 +label.add.port.forwarding.rule=\u0625\u0636\u0627\u0641\u0629 \u0642\u0627\u0639\u062f\u0629 \u0645\u0646\u0641\u0630 \u0625\u0639\u0627\u062f\u0629 \u0627\u0644\u062a\u0648\u062c\u064a\u0647 +label.add.route=\u0625\u0636\u0627\u0641\u0629 \u0645\u0633\u0627\u0631 +label.add.rule=\u0625\u0636\u0627\u0641\u0629 \u0642\u0627\u0639\u062f\u0629 +label.add.static.route=\u0625\u0636\u0627\u0641\u0629 \u062a\u0648\u062c\u064a\u0647 \u062b\u0627\u0628\u062a +label.add.to.group=\u0625\u0636\u0627\u0641\u0629 \u0625\u0644\u0649 \u0627\u0644\u0645\u062c\u0645\u0648\u0639\u0629 +label.add.VM.to.tier=\u0625\u0636\u0627\u0641\u0629 \u062c\u0647\u0627\u0632 \u0625\u0641\u062a\u0631\u0627\u0636\u064a \u0641\u064a \u0637\u0628\u0642\u0629 +label.add.vpc=\u0625\u0636\u0627\u0641\u0629 \u0633\u062d\u0627\u0628\u0629 \u0625\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u062e\u0627\u0635\u0629 +label.add.VPN.gateway=\u0623\u0636\u0641 \u0628\u0648\u0627\u0628\u0629 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 +label.allocated=\u062a\u062e\u0635\u064a\u0635 +label.apply=\u062a\u0637\u0628\u064a\u0642 +label.associated.network=\u0634\u0628\u0643\u0629 \u0645\u0631\u062a\u0628\u0637\u0629 +label.broadcast.uri=\u0628\u062b \u0627\u0644\u0631\u0627\u0628\u0637 +label.change.value=\u062a\u063a\u064a\u0631 \u0627\u0644\u0642\u064a\u0645\u0629 +label.CIDR.list=\u0642\u0627\u0626\u0645\u0629 CIDR +label.CIDR.of.destination.network=CIDR \u0627\u0644\u062e\u0627\u0635 \u0628\u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0645\u0648\u062c\u0647\u0629. +label.clean.up=\u062a\u0646\u0638\u064a\u0641 +label.clear.list=\u0645\u0633\u062d \u0627\u0644\u0642\u0627\u0626\u0645\u0629 +label.configuration=\u0627\u0644\u062a\u0643\u0648\u064a\u0646 +label.configure.network.ACLs=\u0636\u0628\u0637 \u0634\u0628\u0643\u0629 ACLs +label.configure=\u0642\u0645 \u0628\u062a\u0643\u0648\u064a\u0646 +label.configure.vpc=\u062a\u0643\u0648\u064a\u0646 VPC +label.corrections.saved=\u062a\u0645 \u062d\u0641\u0638 \u0627\u0644\u062a\u0635\u062d\u064a\u062d\u0627\u062a +label.cpu.mhz=\u0648\u062d\u062f\u0629 \u0627\u0644\u0645\u0639\u0627\u0644\u062c\u0629 \u0627\u0644\u0645\u0631\u0643\u0632\u064a\u0629 (\u0628\u0627\u0644\u0645\u064a\u063a\u0627\u0647\u064a\u0631\u062a\u0632) +label.cpu=\u00d9\u0088\u00d8\u00ad\u00d8\u00af\u00d8\u00a9 \u00d8\u00a7\u00d9\u0084\u00d9 +label.create.project=\u0623\u0646\u0634\u0626 \u0645\u0634\u0631\u0648\u0639 +label.create.VPN.connection=\u0625\u0646\u0634\u0627\u0621 \u0627\u062a\u0635\u0627\u0644 \u0628\u0648\u0627\u0628\u0629 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 +label.dead.peer.detection=\u0643\u0634\u0641 \u0627\u0644\u0642\u0631\u064a\u0646 \u0627\u0644\u0645\u0641\u0642\u0648\u062f +label.decline.invitation=\u0631\u0641\u0636 \u0627\u0644\u062f\u0639\u0648\u0629 +label.default=\u0627\u0644\u0625\u0641\u062a\u0631\u0627\u0636\u064a +label.default.view=\u0637\u0631\u064a\u0642\u0629 \u0627\u0644\u0639\u0631\u0636 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 +label.delete.gateway=\u0627\u062d\u0630\u0641 \u0627\u0644\u0628\u0648\u0627\u0628\u0629 +label.delete.project=\u062d\u0630\u0641 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 +label.delete.VPN.connection=\u0627\u062d\u0630\u0641 \u0628\u0648\u0627\u0628\u0629 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 +label.delete.VPN.customer.gateway=\u062d\u0630\u0641 \u0628\u0648\u0627\u0628\u0629 VPN \u0627\u0644\u0645\u062e\u0635\u0635\u0629 +label.delete.VPN.gateway=\u0627\u062d\u0630\u0641 \u0628\u0648\u0627\u0628\u0629 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 +label.destroy=\u0647\u062f\u0645 +label.devices=\u0627\u0644\u0623\u062c\u0647\u0632\u0629 +label.direct.ips=\u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0645\u0634\u062a\u0631\u0643\u0629 IPs +label.display.name=\u0639\u0631\u0636 \u0627\u0644\u0627\u0633\u0645 +label.DNS.domain.for.guest.networks=\u0645\u062c\u0627\u0644 DNS \u0644\u0634\u0628\u0643\u0627\u062a \u0627\u0644\u0632\u0627\u0626\u0631 +label.dns=\u0646\u0638\u0627\u0645 \u062a\u0633\u0645\u064a\u0629 \u0627\u0644\u0645\u062c\u0627\u0644 DNS +label.drag.new.position=\u0627\u0633\u062d\u0628 \u0644\u0645\u0648\u0642\u0641 \u062c\u062f\u064a\u062f +label.edit.network.details=\u062a\u062d\u0631\u064a\u0631 \u062a\u0641\u0627\u0635\u064a\u0644 \u0627\u0644\u0634\u0628\u0643\u0629 +label.edit.project.details=\u0627\u0636\u0627\u0641\u0629 \u062a\u0641\u0627\u0635\u064a\u0644 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 +label.edit.tags=\u062a\u0639\u062f\u064a\u0644 \u0627\u0644\u0639\u0644\u0627\u0645\u0627\u062a +label.edit.vpc=\u062a\u0639\u062f\u064a\u0644 VPC +label.egress.rules=\u0642\u0648\u0627\u0639\u062f \u0627\u0644\u062e\u0631\u0648\u062c +label.elastic=\u0645\u0631\u0646 +label.enable.s3=\u062a\u0645\u0643\u064a\u0646 \u0627\u0644\u062a\u062e\u0632\u064a\u0646 \u0627\u0644\u062b\u0627\u0646\u0648\u064a S3 +label.endpoint=\u0646\u0642\u0637\u0629 \u0627\u0644\u0646\u0647\u0627\u064a\u0629 +label.error=\u062e\u0637\u0623 +label.ESP.lifetime=\u0639\u0645\u0631 ESP (\u062b\u0627\u0646\u064a\u0629) +label.ESP.policy=\u0633\u064a\u0627\u0633\u0629 ESP +label.filterBy=\u062a\u0635\u0641\u064a\u0629 \u062d\u0633\u0628 +label.full.path=\u0645\u0633\u0627\u0631 \u0643\u0627\u0645\u0644 +label.guest.type=\u0646\u0648\u0639 \u0627\u0644\u0636\u064a\u0641 +label.IKE.lifetime=\u0639\u0645\u0631 IKE (\u062b\u0627\u0646\u064a\u0629) +label.IKE.policy=\u0633\u064a\u0627\u0633\u0629 IKE +label.instances=\u0627\u0644\u062d\u0627\u0644\u0627\u062a +label.invitations=\u062f\u0639\u0648\u0627\u062a +label.invited.accounts=\u062f\u0639\u0648\u0629 \u062d\u0633\u0627\u0628\u0627\u062a +label.invite.to=\u062f\u0639\u0648\u0629 \u0644\u0640 +label.IPsec.preshared.key=\u0645\u0641\u062a\u0627\u062d \u0623\u0645\u0646 \u0628\u0631\u0648\u062a\u0648\u0643\u0648\u0644 \u0627\u0644\u0625\u0646\u062a\u0631\u0646\u062a \u062a\u0645\u062a \u0645\u0634\u0627\u0631\u0643\u062a\u0647 \u0645\u0633\u0628\u0642\u0627 +label.isolation.uri=\u0639\u0632\u0644 \u0627\u0644\u0631\u0627\u0628\u0637 +label.keyboard.type=\u0646\u0648\u0639 \u0644\u0648\u062d\u0629 \u0627\u0644\u0645\u0641\u0627\u062a\u064a\u062d +label.least.connections=\u0623\u0642\u0644 \u0627\u0644\u0625\u062a\u0635\u0627\u0644\u0627\u062a +label.local.storage.enabled=\u062a\u0645\u0643\u064a\u0646 \u0627\u0644\u062a\u062e\u0632\u064a\u0646 \u0627\u0644\u0645\u062d\u0644\u064a +label.make.project.owner=\u062c\u0639\u0644 \u0627\u0644\u062d\u0633\u0627\u0628 \u0645\u0627\u0644\u0643 \u0644\u0644\u0645\u0634\u0631\u0648\u0639 +label.max.guest.limit=\u0627\u0644\u062d\u062f \u0627\u0644\u0623\u0642\u0635\u0627\u0621 \u0644\u0636\u064a\u0641 +label.memory.mb=\u0627\u0644\u0630\u0627\u0643\u0631\u0629 ( \u0628\u0627\u0644\u0645\u064a\u062c\u0627\u0628\u0627\u064a\u0628\u062a) +label.memory=\u0627\u0644\u0630\u0627\u0643\u0631\u0629 +label.menu.alerts=\u0627\u0644\u062a\u0646\u0628\u064a\u0647\u0627\u062a +label.menu.all.accounts=\u062c\u0645\u064a\u0639 \u0627\u0644\u062d\u0633\u0627\u0628\u0627\u062a +label.menu.all.instances=\u062c\u0645\u064a\u0639 \u0627\u0644\u062d\u0627\u0644\u0627\u062a +label.menu.community.isos=\u0627\u0644\u062a\u0636\u0627\u0645\u0646 \u0627\u0644\u062f\u0648\u0644\u064a \u0627\u0644\u0645\u062c\u062a\u0645\u0639\u064a +label.menu.community.templates=\u0642\u0648\u0627\u0644\u0628 \u0627\u0644\u0645\u062c\u062a\u0645\u0639 +label.menu.configuration=\u062a\u0631\u062a\u064a\u0628 +label.menu.dashboard=\u0644\u0648\u062d\u0629 \u0627\u0644\u0642\u064a\u0627\u062f\u0629 +label.menu.destroyed.instances=\u062d\u0627\u0644\u0627\u062a \u0627\u0644\u062a\u062f\u0645\u064a\u0631 +label.menu.disk.offerings=\u0639\u0631\u0648\u0636 \u0627\u0644\u0642\u0631\u0635 +label.menu.domains=\u0627\u0644\u0645\u062c\u0627\u0644\u0627\u062a +label.menu.events=\u0623\u062d\u062f\u0627\u062b +label.menu.featured.isos=\u0645\u0645\u064a\u0632\u0627\u062a \u0627\u0644\u062a\u0636\u0627\u0645\u0646 \u0627\u0644\u062f\u0648\u0644\u064a +label.menu.featured.templates=\u0642\u0648\u0627\u0644\u0628 \u0645\u0645\u064a\u0632\u0629 +label.menu.global.settings=\u0627\u0644\u0625\u0639\u062f\u0627\u062f\u0627\u062a \u0627\u0644\u0639\u0645\u0648\u0645\u064a\u0629 +label.menu.instances=\u0627\u0644\u062d\u0627\u0644\u0627\u062a +label.migrate.instance.to.host=\u0646\u0642\u0644 \u0627\u0644\u0642\u0627\u0644\u0628 \u0625\u0644\u0649 \u0645\u0636\u064a\u0641 \u0622\u062e\u0631 +label.migrate.instance.to.ps=\u0646\u0642\u0644 \u0627\u0644\u0642\u0627\u0644\u0628 \u0625\u0644\u0649 \u0627\u0644\u0630\u0627\u0643\u0631\u0629 \u0627\u0644\u0623\u0633\u0627\u0633\u064a\u0629 +label.migrate.to.host=\u0627\u0644\u062a\u062d\u0648\u0644 \u0625\u0644\u0649 \u0627\u0644\u0645\u0636\u064a\u0641 +label.migrate.to.storage=\u0627\u0644\u062a\u062d\u0648\u0644 \u0625\u0644\u0649 \u0627\u0644\u062a\u062e\u0632\u064a\u0646 +label.move.down.row=\u0627\u0644\u0627\u0646\u062a\u0642\u0627\u0644 \u0625\u0644\u0649 \u0627\u0644\u0623\u0633\u0641\u0644 \u0628\u0635\u0641 \u0648\u0627\u062d\u062f +label.move.to.bottom=\u0627\u0644\u0627\u0646\u062a\u0642\u0627\u0644 \u0625\u0644\u0649 \u0627\u0644\u0623\u0633\u0641\u0644 +label.move.to.top=\u0627\u0646\u062a\u0642\u0627\u0644 \u0625\u0644\u0649 \u0623\u0639\u0644\u0649 +label.move.up.row=\u0627\u0644\u0627\u0646\u062a\u0642\u0627\u0644 \u0625\u0644\u0649 \u0627\u0644\u0623\u0639\u0644\u0649 \u0628\u0635\u0641 \u0648\u0627\u062d\u062f +label.my.network=\u0634\u0628\u0643\u062a\u064a +label.my.templates=\u0642\u0648\u0627\u0644\u0628\u064a +label.network.ACLs=\u0634\u0628\u0643\u0629 ACLs +label.network.ACL.total=\u0625\u062c\u0645\u0627\u0644 \u0634\u0628\u0643\u0629 ACL +label.network.ACL=\u0634\u0628\u0643\u0629 ACL +label.networks=\u0627\u0644\u0634\u0628\u0643\u0627\u062a +label.new.project=\u0645\u0634\u0631\u0648\u0639 \u062c\u062f\u064a\u062f +label.new=\u062c\u062f\u064a\u062f +label.no.data=\u0644\u0627 \u064a\u0648\u062c\u062f \u0628\u064a\u0627\u0646\u0627\u062a \u0644\u0644\u0639\u0631\u0636 +label.no.thanks=\u0644\u0627\u061b \u0634\u0643\u0631\u0627\u064b +label.notifications=\u0627\u0644\u062a\u0646\u0628\u064a\u0647\u0627\u062a +label.ok=\u0645\u0648\u0627\u0641\u0642 +label.order=\u062a\u0631\u062a\u064a\u0628 +label.previous=\u0627\u0644\u0633\u0627\u0628\u0642 +label.private.Gateway=\u0645\u0646\u0641\u0630\\Gateway \u062e\u0627\u0635 +label.project.invite=\u062f\u0639\u0648\u0629 \u0625\u0644\u0649 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 +label.project.name=\u0627\u0633\u0645 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 +label.projects=\u0627\u0644\u0645\u0634\u0627\u0631\u064a\u0639 +label.project=\u0645\u0634\u0631\u0648\u0639 +label.project.view=\u0639\u0631\u0636 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 +label.quickview=\u0646\u0638\u0631\u0629 \u0633\u0631\u064a\u0639\u0629 +label.reboot=\u0625\u0639\u0627\u062f\u0629 \u062a\u0634\u063a\u064a\u0644 +label.remind.later=\u0630\u0643\u0631\u0646\u064a \u0644\u0627\u062d\u0642\u0627\u064b +label.remove.ACL=\u0625\u0632\u0627\u0644\u0629 ACL +label.remove.static.route=\u0625\u0632\u0627\u0644\u0629 \u0627\u0644\u062a\u0648\u062c\u064a\u0647 \u062b\u0627\u0628\u062a +label.remove.tier=\u0625\u0636\u0627\u0641\u0629 \u0637\u0628\u0642\u0629 +label.remove.vpc=\u0625\u0632\u0627\u0644\u0629 VPC +label.reset.VPN.connection=\u0625\u0639\u0627\u062f\u0629 \u062a\u0639\u064a\u064a\u0646 \u0627\u062a\u0635\u0627\u0644 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 +label.restart.network=\u0625\u0639\u0627\u062f\u0629 \u062a\u0634\u063a\u064a\u0644 \u0627\u0644\u0634\u0628\u0643\u0629 +label.restart.required=\u0645\u0637\u0644\u0648\u0628 \u0625\u0639\u0627\u062f\u0629 \u0627\u0644\u062a\u0634\u063a\u064a\u0644 +label.restart.vpc=\u0625\u0639\u062f\u0627\u0629 \u062a\u0634\u063a\u064a\u0644 VPC +label.restore=\u0625\u0633\u062a\u0639\u0627\u062f\u0629 +label.review=\u0645\u0631\u0627\u062c\u0639\u0629 +label.revoke.project.invite=\u0625\u0644\u063a\u0627\u0621 \u0627\u0644\u062f\u0639\u0648\u0629 +label.s3.access_key=\u0645\u0641\u062a\u0627\u062d \u0627\u0644\u0648\u0635\u0648\u0644 +label.s3.bucket=\u062f\u0644\u0648 +label.s3.connection_timeout=\u0645\u0647\u0644\u0629 \u0627\u0644\u0627\u062a\u0635\u0627\u0644 +label.s3.endpoint=\u0646\u0642\u0637\u0629 \u0627\u0644\u0646\u0647\u0627\u064a\u0629 +label.s3.max_error_retry=\u0623\u0642\u0635\u0649 \u062e\u0637\u0623 \u0641\u064a \u0625\u0639\u0627\u062f\u0629 \u0627\u0644\u0645\u062d\u0627\u0648\u0644\u0629 +label.s3.secret_key=\u0627\u0644\u0645\u0641\u062a\u0627\u062d \u0627\u0644\u0633\u0631\u064a +label.s3.socket_timeout=\u0645\u0647\u0644\u0629 \u0627\u0644\u0645\u0642\u0628\u0633 +label.s3.use_https=\u0627\u0633\u062a\u062e\u062f\u0645 HTTPS +label.scope=\u0627\u0644\u0645\u062c\u0627\u0644 +label.search=\u0628\u062d\u062b +label.secret.key=\u0627\u0644\u0645\u0641\u062a\u0627\u062d \u0627\u0644\u0633\u0631\u064a +label.select.a.template=\u0627\u062e\u062a\u0631 \u0642\u0627\u0644\u0628 +label.select.project=\u062d\u062f\u062f \u0627\u0644\u0645\u0634\u0631\u0648\u0639 +label.select.tier=\u062d\u062f\u062f \u0637\u0628\u0642\u0629 +label.select-view=\u062d\u062f\u062f \u0637\u0631\u064a\u0642\u0629 \u0627\u0644\u0639\u0631\u0636 +label.service.capabilities=\u0642\u062f\u0631\u0627\u062a \u0627\u0644\u062e\u062f\u0645\u0629 +label.setup=\u0627\u0644\u062a\u062b\u0628\u064a\u062a +label.site.to.site.VPN=\u0645\u0648\u0642\u0639 \u0625\u0644\u0649 \u0645\u0648\u0642\u0639-\u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 \u0627\u0644\u0638\u0627\u0647\u0631\u064a\u0629 VPN +label.source=\u0645\u0635\u062f\u0631 +label.specify.IP.ranges=\u062a\u062d\u062f\u064a\u062f \u0646\u0637\u0627\u0642\u0627\u062a IP +label.sticky.tablesize=\u062d\u062c\u0645 \u0627\u0644\u062c\u062f\u0648\u0644 +label.stop=\u062a\u0648\u0642\u0641 +label.super.cidr.for.guest.networks=CIDR \u0645\u0645\u062a\u0627\u0632 \u0644\u0634\u0628\u0643\u0627\u062a \u0627\u0644\u0636\u064a\u0641. +label.supported.services=\t\u0627\u0644\u062e\u062f\u0645\u0627\u062a \u0627\u0644\u0645\u062f\u0639\u0648\u0645\u0629 +label.suspend.project=\u0625\u064a\u0642\u0627\u0641 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 +label.tier.details=\u062a\u0641\u0627\u0635\u064a\u0644 \u0627\u0644\u0637\u0628\u0642\u0629 +label.tier=\u0637\u0628\u0642\u0629 +label.upload=\u0631\u0641\u0639 +label.view.all=\u0639\u0631\u0636 \u0627\u0644\u0643\u0644 +label.viewing=\u0639\u0631\u0636 +label.view=\u0639\u0631\u0636 +label.vm.destroy=\u0647\u062f\u0645 +label.vm.reboot=\u0625\u0639\u0627\u062f\u0629 \u062a\u0634\u063a\u064a\u0644 +label.VMs.in.tier=\u0627\u0644\u0623\u062c\u0647\u0632\u0629 \u0627\u0644\u0625\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0641\u064a \u0637\u0628\u0642\u0629 +label.vm.stop=\u062a\u0648\u0642\u0641 +label.volume.limits=\u062d\u062f\u0648\u062f \u0627\u0644\u0645\u0646\u0637\u0642\u0629 +label.vpc.id=\u0647\u0648\u064a\u0629 \u062e\u0627\u0635\u0629 \u0628\u0633\u062d\u0627\u0628\u0629 \u0625\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u062e\u0627\u0635\u0629 +label.VPC.router.details=\u062a\u0641\u0627\u0635\u064a\u0644 \u062c\u0647\u0627\u0632 \u0627\u0644\u062a\u0648\u062c\u064a\u0647 VPC +label.vpc=\u0633\u062d\u0627\u0628\u0629 \u0625\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u062e\u0627\u0635\u0629 VPC +label.VPN.connection=\u0625\u062a\u0635\u0627\u0644 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 +label.vpn.customer.gateway=\u0628\u0648\u0627\u0628\u0629 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 \u0644\u0644\u0639\u0645\u064a\u0644 +label.VPN.customer.gateway=\u0628\u0648\u0627\u0628\u0629 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 \u0644\u0644\u0639\u0645\u064a\u0644 +label.VPN.gateway=\u0628\u0648\u0627\u0628\u0629 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 +label.waiting=\u0642\u064a\u062f \u0627\u0644\u0625\u0646\u062a\u0638\u0627\u0631 +label.warn=\u062a\u062d\u0630\u064a\u0631 +label.wednesday=\u0627\u0644\u0623\u0631\u0628\u0639\u0627\u0621 +label.weekly=\u0625\u0633\u0628\u0648\u0639\u064a +label.welcome.cloud.console=\u0645\u0631\u062d\u0628\u0627 \u0628\u0643\u0645 \u0641\u064a \u0648\u062d\u062f\u0629 \u0627\u0644\u062a\u062d\u0643\u0645 \u0627\u0644\u0625\u0631\u0627\u062f\u064a\u0629 +label.welcome=\u0645\u0631\u062d\u0628\u0627 +label.yes=\u0646\u0639\u0645 +label.zone.details=\u062a\u0641\u0627\u0635\u064a\u0644 \u0627\u0644\u0645\u0646\u0637\u0642\u0629 +label.zone.name=\u0627\u0633\u0645 \u0627\u0644\u0645\u0646\u0637\u0642\u0629 +label.zone.step.1.title=\u0627\u0644\u062e\u0637\u0648\u0629 1 \\\: \u0639\u0644\u0649 .<\u0642\u0648\u064a> \u0627\u062e\u062a\u0631 \u0634\u0628\u0643\u0629 +label.zone.step.2.title=\u0627\u0644\u062e\u0637\u0648\u0629 2 \\\: <\u0642\u0648\u064a> \u0625\u0636\u0627\u0641\u0629 \u0645\u0646\u0637\u0642\u0629 +label.zone.step.3.title=\u0627\u0644\u062e\u0637\u0648\u0629 3 \\\: \u0639\u0644\u0649 <\u0642\u0648\u064a> \u0625\u0636\u0627\u0641\u0629 \u0628\u0648\u062f +label.zone.step.4.title=\u0627\u0644\u062e\u0637\u0648\u0629 4 \\\: <\u0642\u0648\u064a> \u0625\u0636\u0627\u0641\u0629 \u0645\u062c\u0645\u0648\u0639\u0629 IP <\\\u0642\u0648\u064a> +label.zone.wide=\u0645\u0646\u0637\u0642\u0629 \u0648\u0627\u0633\u0639\u0629 +label.zoneWizard.trafficType.guest=\u0627\u0644\u0636\u064a\u0641 \\\: \u0627\u0644\u062d\u0631\u0643\u0629 \u0628\u064a\u0646 \u0627\u0644\u0623\u062c\u0647\u0632\u0629 \u0627\u0644\u0625\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0644\u0644\u0645\u0633\u062a\u062e\u062f\u0645 \u0627\u0644\u0646\u0647\u0627\u0626\u064a. +label.zoneWizard.trafficType.public=\u0627\u0644\u0639\u0627\u0645\u0629 \\\: \u0627\u0644\u0645\u0631\u0648\u0631 \u0628\u064a\u0646 \u0627\u0644\u0625\u0646\u062a\u0631\u0646\u062a \u0648\u0627\u0644\u0623\u062c\u0647\u0632\u0629 \u0627\u0644\u0638\u0627\u0647\u0631\u064a\u0629 \u0641\u064a \u0627\u0644\u0633\u062d\u0627\u0628\u0629. +label.zoneWizard.trafficType.storage=\u0627\u0644\u062a\u062e\u0632\u064a\u0646 \\\: \u0627\u0644\u0645\u0631\u0648\u0631 \u0628\u064a\u0646 \u0645\u0644\u0642\u0645\u0627\u062a \u0627\u0644\u062a\u062e\u0632\u064a\u0646 \u0627\u0644\u0627\u0628\u062a\u062f\u0627\u0626\u064a\u0629 \u0648\u0627\u0644\u062b\u0627\u0646\u0648\u064a\u0629\u060c \u0645\u062b\u0644 \u0642\u0648\u0627\u0644\u0628 VM \u0648\u0627\u0644\u0644\u0642\u0637\u0627\u062a +message.acquire.new.ip.vpc=\u064a\u0631\u062c\u0649 \u0627\u0644\u062a\u0623\u0643\u064a\u062f \u0628\u0623\u0646\u0643 \u062a\u0631\u063a\u0628 \u0641\u064a \u0627\u0644\u062d\u0635\u0648\u0644 \u0639\u0644\u0649 \u0628\u0648\u0631\u062a\u0648\u0643\u0648\u0644 \u0625\u0646\u062a\u0631\u0646\u062a \u062c\u062f\u064a\u062f \u0644\u0647\u0630\u0627 \u0627\u0644\u062d\u0627\u0633\u0648\u0628 \u0627\u0644\u0625\u0641\u062a\u0631\u0627\u0636\u064a. +message.action.delete.system.service.offering=\u0627\u0644\u0631\u062c\u0627\u0621 \u062a\u0623\u0643\u064a\u062f \u0631\u063a\u0628\u062a\u0643 \u0641\u064a \u062d\u0630\u0641 \u062e\u062f\u0645\u0629 \u0627\u0644\u0646\u0638\u0627\u0645 \u0627\u0644\u0645\u0642\u062f\u0645\u0629. +message.action.disable.physical.network=\u0641\u0636\u0644\u0627 \u060c \u0623\u0643\u0651\u062f \u0623\u0646\u0643 \u062a\u0631\u064a\u062f \u062a\u0639\u0637\u064a\u0644 \u0647\u0630\u0647 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0641\u064a\u0632\u064a\u0627\u0626\u064a\u0629 +message.action.enable.physical.network=\u0641\u0636\u0644\u0627 \u060c \u0623\u0643\u0651\u062f \u0623\u0646\u0643 \u062a\u0631\u064a\u062f \u062a\u0645\u0643\u064a\u0646 \u0647\u0630\u0647 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0641\u064a\u0632\u064a\u0627\u0626\u064a\u0629 +message.activate.project=\u0647\u0644 \u0623\u0646\u062a \u0645\u062a\u0623\u0643\u062f \u0645\u0646 \u0623\u0646\u0643 \u062a\u0631\u064a\u062f \u062a\u0641\u0639\u064a\u0644 \u0647\u0630\u0627 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 \u061f +message.add.domain=\u064a\u0631\u062c\u0649 \u062a\u062d\u062f\u064a\u062f \u0627\u0644\u0645\u062c\u0627\u0644 \u0627\u0644\u0641\u0631\u0639\u064a \u0627\u0644\u0630\u064a \u062a\u0631\u064a\u062f \u0625\u0646\u0634\u0627\u0621 \u062a\u062d\u062a \u0647\u0630\u0627 \u0627\u0644\u0646\u0637\u0627\u0642 +message.add.new.gateway.to.vpc=\u0641\u0636\u0644\u0627 \u062d\u062f\u062f \u0627\u0644\u0645\u0639\u0644\u0648\u0645\u0627\u062a \u0644\u0625\u0636\u0627\u0641\u0629 \u0628\u0648\u0627\u0628\u0629 gateway \u0644\u0647\u0630\u0647 \u0627\u0644\u0633\u062d\u0627\u0628\u0629 \u0627\u0644\u0625\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u062e\u0627\u0635\u0629 VPC +message.add.system.service.offering=\u0627\u0644\u0631\u062c\u0627\u0621 \u062a\u0639\u0628\u0626\u0629 \u0627\u0644\u0628\u064a\u0627\u0646\u0627\u062a \u0627\u0644\u062a\u0627\u0644\u064a\u0629 \u0644\u0625\u0636\u0627\u0641\u0629 \u0646\u0638\u0627\u0645 \u062c\u062f\u064a\u062f \u0644\u0637\u0631\u062d +message.add.VPN.gateway=\u064a\u0631\u062c\u0649 \u062a\u0623\u0643\u064a\u062f \u0631\u063a\u0628\u062a\u0643 \u0641\u064a \u0625\u0636\u0627\u0641\u0629 \u0628\u0648\u0627\u0628\u0629 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 VPN +message.after.enable.s3=\u062a\u0645 \u0625\u0639\u062f\u0627\u062f \u0627\u0644\u062a\u062e\u0632\u064a\u0646 S3 \u0644\u0644\u0630\u0627\u0643\u0631\u0629 \u0627\u0644\u062b\u0627\u0646\u0648\u064a\u0629. \u062a\u0646\u0648\u064a\u0647 \: \u0639\u0646\u062f \u0645\u063a\u0627\u062f\u0631\u062a\u0643 \u0644\u0647\u0630\u0647 \u0627\u0644\u0635\u0641\u062d\u0629 \u0644\u0646 \u064a\u0643\u0648\u0646 \u0628\u0625\u0645\u0643\u0627\u0646\u0643 \u0625\u0639\u0627\u062f\u0629 \u0636\u0628\u0637 S3 \u0645\u0631\u0629 \u0623\u062e\u0631\u0649. +message.confirm.join.project=\u0646\u0631\u062c\u0648 \u062a\u0623\u0643\u064a\u062f \u0631\u063a\u0628\u062a\u0643 \u0641\u064a \u0627\u0644\u0645\u0634\u0627\u0631\u0643\u0629 \u0641\u064a \u0627\u0644\u0645\u0634\u0631\u0648\u0639 +message.decline.invitation=\u0647\u0644 \u0623\u0646\u062a \u0645\u062a\u0623\u0643\u062f \u0645\u0646 \u0623\u0646\u0643 \u062a\u0631\u064a\u062f \u0631\u0641\u0636 \u0647\u0630\u0647 \u0627\u0644\u062f\u0639\u0648\u0629 \u0627\u0644\u0645\u0634\u0631\u0648\u0639\u061f +message.delete.gateway=\u064a\u0631\u062c\u0649 \u062a\u0623\u0643\u064a\u062f \u0631\u063a\u0628\u062a\u0643 \u0641\u064a \u062d\u0630\u0641 \u0627\u0644\u0628\u0648\u0627\u0628\u0629 +message.delete.project=\u0647\u0644 \u0623\u0646\u062a \u0645\u062a\u0623\u0643\u062f \u0645\u0646 \u0623\u0646\u0643 \u062a\u0631\u064a\u062f \u062d\u0630\u0641 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 \u061f +message.delete.user=\u0627\u0644\u0631\u062c\u0627\u0621 \u0627\u0644\u062a\u0623\u0643\u064a\u062f \u0628\u0623\u0646\u0643 \u062a\u0631\u063a\u0628 \u0628\u062d\u0630\u0641 \u0647\u0630\u0627 \u0627\u0644\u0645\u0633\u062a\u062e\u062f\u0645 +message.delete.VPN.connection=\u064a\u0631\u062c\u0649 \u062a\u0623\u0643\u064a\u062f \u0631\u063a\u0628\u062a\u0643 \u0641\u064a \u062d\u0630\u0641 \u0628\u0648\u0627\u0628\u0629 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 VPN +message.delete.VPN.gateway=\u064a\u0631\u062c\u0649 \u062a\u0623\u0643\u064a\u062f \u0631\u063a\u0628\u062a\u0643 \u0641\u064a \u062d\u0630\u0641 \u0628\u0648\u0627\u0628\u0629 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 +message.detach.disk=\u0647\u0644 \u0623\u0646\u062a \u0645\u062a\u0623\u0643\u062f \u0645\u0646 \u0623\u0646\u0643 \u062a\u0631\u064a\u062f \u0641\u0635\u0644 \u0647\u0630\u0627 \u0627\u0644\u0642\u0631\u0635\u061f +message.disable.user=\u0627\u0644\u0631\u062c\u0627\u0621 \u0627\u0644\u062a\u0623\u0643\u064a\u062f \u0628\u0623\u0646\u0643 \u062a\u0631\u063a\u0628 \u0628\u062a\u0639\u0637\u064a\u0644 \u0647\u0630\u0627 \u0627\u0644\u0645\u0633\u062a\u062e\u062f\u0645 +message.enable.account=\u0627\u0644\u0631\u062c\u0627\u0621 \u062a\u0623\u0643\u064a\u062f \u0623\u0646\u0643 \u062a\u0631\u064a\u062f \u062a\u0645\u0643\u064a\u0646 \u0647\u0630\u0627 \u0627\u0644\u062d\u0633\u0627\u0628. +message.enable.user=\u0627\u0644\u0631\u062c\u0627\u0621 \u0627\u0644\u062a\u0623\u0643\u064a\u062f \u0628\u0623\u0646\u0643 \u062a\u0631\u063a\u0628 \u0628\u062a\u0641\u0639\u064a\u0644 \u0647\u0630\u0627 \u0627\u0644\u0645\u0633\u062a\u062e\u062f\u0645 +message.generate.keys=\u0627\u0644\u0631\u062c\u0627\u0621 \u0627\u0644\u062a\u0623\u0643\u064a\u062f \u0628\u0623\u0646\u0643 \u062a\u0631\u063a\u0628 \u0628\u0625\u0646\u0634\u0627\u0621 \u0645\u0641\u0627\u062a\u064a\u062d \u062c\u062f\u064a\u062f\u0629 \u0644\u0647\u0630\u0627 \u0627\u0644\u0645\u0633\u062a\u062e\u062f\u0645 +message.instanceWizard.noTemplates=\u0644\u064a\u0633 \u0644\u062f\u064a\u0643 \u0623\u064a \u0642\u0648\u0627\u0644\u0628 \u0645\u062a\u0627\u062d\u0629\u061b \u064a\u0631\u062c\u0649 \u0625\u0636\u0627\u0641\u0629 \u0642\u0627\u0644\u0628 \u0645\u062a\u0648\u0627\u0641\u0642\u060c \u0648\u0625\u0639\u0627\u062f\u0629 \u0625\u0637\u0644\u0627\u0642 \u0627\u0644\u0645\u0639\u0627\u0644\u062c . +message.join.project=\u0644\u0642\u062f \u0627\u0646\u0636\u0645\u0645\u062a \u0625\u0644\u0649 \u0627\u0644\u0645\u0634\u0631\u0648\u0639. \u064a\u0631\u062c\u0649 \u0627\u0644\u062a\u0628\u062f\u064a\u0644 \u0625\u0644\u0649 \u0637\u0631\u064a\u0642\u0629 \u0639\u0631\u0636 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 \u0644\u0631\u0624\u064a\u0629 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 +message.migrate.instance.to.host=\u064a\u0631\u062c\u0649 \u062a\u0623\u0643\u064a\u062f \u0623\u0646\u0643 \u062a\u0631\u064a\u062f \u0646\u0642\u0644 \u0627\u0644\u0642\u0627\u0644\u0628 \u0625\u0644\u0649 \u0645\u0636\u064a\u0641 \u0622\u062e\u0631. +message.migrate.instance.to.ps=\u064a\u0631\u062c\u0649 \u062a\u0623\u0643\u064a\u062f \u0623\u0646\u0643 \u062a\u0631\u064a\u062f \u0646\u0642\u0644 \u0627\u0644\u0642\u0627\u0644\u0628 \u0625\u0644\u0649 \u0627\u0644\u0630\u0627\u0643\u0631\u0629 \u0627\u0644\u0623\u0633\u0627\u0633\u064a\u0629. +message.no.projects.adminOnly=\u0644\u064a\u0633 \u0644\u062f\u064a\u0643 \u0623\u064a \u0645\u0634\u0627\u0631\u064a\u0639.
\u0627\u0644\u0631\u062c\u0627\u0621 \u0637\u0644\u0628 \u0645\u0646 \u0627\u0644\u0645\u0633\u0624\u0648\u0644 \u0625\u0646\u0634\u0627\u0621 \u0645\u0634\u0631\u0648\u0639 \u062c\u062f\u064a\u062f. +message.no.projects=\u0644\u064a\u0633 \u0644\u062f\u064a\u0643 \u0623\u064a \u0645\u0634\u0627\u0631\u064a\u0639.
\u064a\u0631\u062c\u0649 \u0625\u0646\u0634\u0627\u0621 \u0645\u0634\u0631\u0648\u0639 \u062c\u062f\u064a\u062f \u0645\u0646 \u0642\u0633\u0645 \u0627\u0644\u0645\u0634\u0627\u0631\u064a\u0639. +message.pending.projects.1=\u0644\u062f\u064a\u0643 \u062f\u0639\u0648\u0627\u062a \u0645\u0634\u0631\u0648\u0639 \u0645\u0639\u0644\u0642\u0629/\: +message.pending.projects.2=\u0644\u0639\u0631\u0636\u060c \u0627\u0644\u0631\u062c\u0627\u0621 \u0627\u0644\u0630\u0647\u0627\u0628 \u0625\u0644\u0649 \u0642\u0633\u0645 \u0627\u0644\u0645\u0634\u0627\u0631\u064a\u0639\u060c \u062b\u0645 \u062d\u062f\u062f \u062f\u0639\u0648\u0627\u062a \u0645\u0646 \u0627\u0644\u0642\u0627\u0626\u0645\u0629 \u0627\u0644\u0645\u0646\u0633\u062f\u0644\u0629. +message.please.select.networks=\u0627\u0644\u0631\u062c\u0627\u0621 \u0627\u062e\u062a\u064a\u0627\u0631 \u0627\u0644\u0634\u0628\u0643\u0627\u062a \u0644\u062c\u0647\u0627\u0632\u0643 \u0627\u0644\u0625\u0641\u062a\u0631\u0627\u0636\u064a +message.project.invite.sent=\u062a\u0645 \u0625\u0631\u0633\u0627\u0644 \u0627\u0644\u062f\u0639\u0648\u0629 ; \u0633\u064a\u062a\u0645 \u0625\u0636\u0627\u0641\u062a\u0647\u0645 \u0625\u0644\u0649 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 \u0628\u0645\u062c\u0631\u062f \u0642\u0628\u0648\u0644 \u0627\u0644\u062f\u0639\u0648\u0629 +message.remove.vpc=\u064a\u0631\u062c\u0649 \u062a\u0623\u0643\u064a\u062f \u0631\u063a\u0628\u062a\u0643 \u0641\u064a \u062d\u0630\u0641 \u0627\u0644\u0640VPC +message.reset.password.warning.notPasswordEnabled=\u0627\u0644\u0642\u0627\u0644\u0628 \u0644\u0647\u0630\u0627 \u0627\u0644\u0646\u0645\u0648\u0630\u062c \u062a\u0645 \u0627\u0646\u0634\u0627\u0626\u0647 \u0645\u0646 \u062f\u0648\u0646 \u0643\u0644\u0645\u0629 \u0645\u0631\u0648\u0631 \u0645\u0645\u0643\u0646\u0629 +message.reset.password.warning.notStopped=\u064a\u062c\u0628 \u0625\u064a\u0642\u0627\u0641 \u0627\u0644\u0646\u0645\u0648\u0630\u062c \u0627\u0644\u062e\u0627\u0635 \u0628\u0643 \u0642\u0628\u0644 \u0645\u062d\u0627\u0648\u0644\u0629 \u062a\u063a\u064a\u064a\u0631 \u0643\u0644\u0645\u0629 \u0627\u0644\u0645\u0631\u0648\u0631 \u0627\u0644\u062d\u0627\u0644\u064a\u0629 +message.reset.VPN.connection=\u064a\u0631\u062c\u0649 \u062a\u0623\u0643\u064a\u062f \u0623\u0646\u0643 \u062a\u0631\u064a\u062f \u0625\u0639\u0627\u062f\u0629-\u0636\u0628\u0637 \u0625\u062a\u0635\u0627\u0644 \u0627\u0644\u0634\u0628\u0643\u0629 \u0627\u0644\u0627\u0641\u062a\u0631\u0627\u0636\u064a\u0629 \u0627\u0644\u0634\u062e\u0635\u064a\u0629 VPN +message.restart.vpc=\u064a\u0631\u062c\u0649 \u062a\u0623\u0643\u064a\u062f \u0631\u063a\u0628\u062a\u0643 \u0641\u064a \u0625\u0639\u0627\u062f\u0629 \u062a\u0634\u063a\u064a\u0644 \u0627\u0644\u0640VPN +message.select.template=\u0627\u0644\u0631\u062c\u0627\u0621 \u0627\u062e\u062a\u064a\u0627\u0631 \u0642\u0627\u0644\u0628 \u0644\u0645\u062b\u0627\u0644\u0643 \u0627\u0644\u0625\u0641\u062a\u0631\u0627\u0636\u064a \u0627\u0644\u062c\u062f\u064a\u062f +message.step.2.desc= +message.step.3.desc= +message.suspend.project=\u0647\u0644 \u0623\u0646\u062a \u0645\u062a\u0623\u0643\u062f \u0645\u0646 \u0623\u0646\u0643 \u062a\u0631\u064a\u062f \u0625\u064a\u0642\u0627\u0641 \u0647\u0630\u0627 \u0627\u0644\u0645\u0634\u0631\u0648\u0639 \u061f +message.update.resource.count=\u0627\u0644\u0631\u062c\u0627\u0621 \u0627\u0644\u062a\u0623\u0643\u064a\u062f \u0628\u0623\u0646\u0643 \u062a\u0631\u063a\u0628 \u0628\u062a\u062d\u062f\u064a\u062b \u0645\u0635\u0627\u062f\u0631 \u0627\u0644\u062d\u0633\u0627\u0628\u0627\u062a \u0644\u0647\u0630\u0627 \u0627\u0644\u062d\u0633\u0627\u0628 +message.vm.review.launch=\u064a\u0631\u062c\u0649 \u0645\u0631\u0627\u062c\u0639\u0629 \u0627\u0644\u0645\u0639\u0644\u0648\u0645\u0627\u062a \u0627\u0644\u062a\u0627\u0644\u064a\u0629 \u0648\u062a\u0623\u0643\u062f \u0623\u0646 \u0645\u062b\u0627\u0644\u0643 \u0627\u0644\u0625\u0641\u062a\u0631\u0627\u0636\u064a \u0635\u062d\u064a\u062d \u0642\u0628\u0644 \u0627\u0644\u0625\u0646\u0637\u0644\u0627\u0642 +message.zoneWizard.enable.local.storage=\u062a\u062d\u0630\u064a\u0631\\\: \u0625\u0630\u0627 \u0642\u0645\u062a \u0628\u062a\u0645\u0643\u064a\u0646 \u0627\u0644\u0630\u0627\u0643\u0631\u0629 \u0627\u0644\u0645\u062d\u0644\u064a\u0629 \u0644\u0647\u0630\u0627 \u0627\u0644\u0646\u0637\u0627\u0642 \u064a\u062c\u0628 \u0639\u0644\u064a\u0643 \u0639\u0645\u0644 \u0627\u0644\u0622\u062a\u064a \u060c \u0625\u0639\u062a\u0645\u0627\u062f\u0627 \u0639\u0644\u0649 \u0627\u0644\u0645\u0643\u0627\u0646 \u0627\u0644\u0630\u064a \u062a\u0631\u063a\u0628 \u0623\u0646 \u064a\u0646\u0637\u0644\u0642 \u0645\u0646\u0647 \u0646\u0638\u0627\u0645\u0643 \u0627\u0644\u0625\u0641\u062a\u0631\u0627\u0636\u064a \\\:

1.\u0625\u0630\u0627 \u0643\u0627\u0646 \u0646\u0638\u0627\u0645\u0643 \u0627\u0644\u0625\u0641\u062a\u0631\u0627\u0636\u064a \u064a\u062d\u062a\u0627\u062c \u0625\u0644\u0649 \u062a\u0634\u063a\u064a\u0644 \u0627\u0644\u0630\u0627\u0643\u0631\u0629 \u0627\u0644\u0625\u0628\u062a\u062f\u0627\u0626\u064a\u0629 +notification.reboot.instance=\u0625\u0639\u0627\u062f\u0629 \u062a\u0634\u063a\u064a\u0644 \u0627\u0644\u0646\u0645\u0648\u0630\u062c +notification.start.instance=\u0628\u062f\u0621 \u0627\u0644\u0646\u0645\u0648\u0630\u062c +notification.stop.instance=\u0625\u064a\u0642\u0627\u0641 \u0627\u0644\u0646\u0645\u0648\u0630\u062c +state.Accepted=\u062a\u0645 \u0627\u0644\u0642\u0628\u0648\u0644 +state.Active=\u0646\u0634\u0637 +state.Allocated=\u062a\u062e\u0635\u064a\u0635 +state.Completed=\u062a\u0645 \u0627\u0644\u0627\u0643\u0645\u0627\u0644 +state.Creating=\u0625\u0646\u0634\u0627\u0621 +state.Declined=\u062a\u0645 \u0627\u0644\u0631\u0641\u0636 +state.Destroyed=\u062f\u0645\u0631 +state.enabled=\u062a\u0645\u0643\u064a\u0646 +state.Enabled=\u062a\u0645\u0643\u064a\u0646 +state.Error=\u062e\u0637\u0623 +state.Expunging=\u0645\u062d\u0648 +state.Pending=\u0641\u064a \u0627\u0644\u0627\u0646\u062a\u0638\u0627\u0631 +state.ready=\u062c\u0627\u0647\u0632 +state.Ready=\u062c\u0627\u0647\u0632 +state.Stopped=\u062a\u0648\u0642\u0641 +state.Suspended=\u062a\u0645 \u0627\u0644\u0625\u064a\u0642\u0627\u0641 +ui.listView.filters.all=\u0627\u0644\u0643\u0644 diff --git a/client/WEB-INF/classes/resources/messages_ca.properties b/client/WEB-INF/classes/resources/messages_ca.properties index 2d8e953419f..4e66083dbd5 100644 --- a/client/WEB-INF/classes/resources/messages_ca.properties +++ b/client/WEB-INF/classes/resources/messages_ca.properties @@ -15,6 +15,7 @@ # specific language governing permissions and limitations # under the License. + confirm.enable.swift=Si us plau ompliu la seg\u00fcent informaci\u00f3 per habilitar el suport per a Swift error.installWizard.message=Quelcom ha fallat, vost\u00e8 pot tornar enrere i corregir els errors detalls suggerime error.password.not.match=Els camps de contrasenya no coincideixen diff --git a/client/WEB-INF/classes/resources/messages_de_DE.properties b/client/WEB-INF/classes/resources/messages_de_DE.properties index 45812687d2f..ca87323cc77 100644 --- a/client/WEB-INF/classes/resources/messages_de_DE.properties +++ b/client/WEB-INF/classes/resources/messages_de_DE.properties @@ -15,13 +15,14 @@ # specific language governing permissions and limitations # under the License. + error.installWizard.message=Ein Fehler ist aufgetreten; Sie k\u00f6nnen zur\u00fcckgehen und den Fehler korregieren error.login=Ihr Benutzername / Passwort stimmt nicht mit uneren unseren Aufzeichnungen \u00fcberein. error.session.expired=Ihre Sitzung ist abgelaufen. force.delete.domain.warning=Achtung\: Diese Auswahl f\u00fchrt zu einer L\u00f6schung aller untergeordneten Domains und aller angeschlossenen Konten sowie ihrer Quellen. force.delete=Erzwinge L\u00f6schung force.remove=Erzwinge Entfernung -force.remove.host.warning=Achtung\: Diese Auswahl wird CloudStack zum sofortigen Anhalten der virtuellen Maschine f\u00fchren, bevor der Host vom Cluster entfernt wurde. +force.remove.host.warning=Achtung\: Diese Auswahl wird CloudStack zum sofortigen Anhalten der virtuellen Maschine f\u00fchren, bevor der Host vom Cluster entfernt wurde. force.stop=Erzwinge Abbruch ICMP.code=ICMP Code ICMP.type=ICMP-Typ @@ -159,7 +160,7 @@ label.action.migrate.instance.processing=Umziehen einer Instanz label.action.reboot.instance=Instanz neustarten label.action.reboot.instance.processing=Neustarten der Instanz... label.action.reboot.router.processing=Neustart vom Router .... -label.action.reboot.router=Router neu starten +label.action.reboot.router=Router neu starten label.action.reboot.systemvm.processing=Neustart-System VM .... label.action.reboot.systemvm=System VM neu starten label.action.release.ip=IP ver\u00f6ffentlichen @@ -271,7 +272,7 @@ label.cidr=CIDR label.cidr.list=Quelle CIDR label.close=Schliessen label.cloud.console=Cloud Management Konsole -label.cloud.managed=Geleitet von cloud.com +label.cloud.managed=Geleitet von cloud.com label.cluster=Cluster label.cluster.type=Cluster-Typ label.code=Code @@ -279,7 +280,7 @@ label.configuration=Konfiguration label.confirmation=Best\u00e4tigung label.congratulations=Herzlichen Gl\u00fcckwunsch label.corrections.saved=Korrekturen gespeichert -label.cpu.allocated=Zugeteilte CPU +label.cpu.allocated=Zugeteilte CPU label.CPU.cap=CPU Obergrenze label.cpu=CPU label.cpu.mhz=CPU (in MHz) @@ -708,7 +709,7 @@ message.enable.account=Bitte best\u00e4tigen Sie, dass Sie dieses Konto aktivier message.enabled.vpn=Ihr VPN Zugriff ist zurzeit aktiv und via IP k\u00f6nnen Sie darauf zugreifen message.enable.vpn.access=VPN ist zurzeit nicht f\u00fcr diese IP Addresse aktiviert. M\u00f6chten Sie den VPN Zugriff aktivieren? message.installWizard.click.retry=Bitte den Start Button f\u00fcr einen neuen Versuch dr\u00fccken -message.installWizard.tooltip.addCluster.name=Der Name des Clusters. Der Name kann frei gew\u00e4hlt werden und wird von Cloudstack nicht genutzt. +message.installWizard.tooltip.addCluster.name=Der Name des Clusters. Der Name kann frei gew\u00e4hlt werden und wird von Cloudstack nicht genutzt. message.installWizard.tooltip.addHost.hostname=Der DNS-Name oder die IP-Adresse des hosts message.installWizard.tooltip.addHost.password=Dies ist das Passwort des o.a. Users (von der XenServer Installation) message.installWizard.tooltip.addHost.username=\u00fcberlicherweise root @@ -717,16 +718,16 @@ message.installWizard.tooltip.addPod.reservedSystemGateway=Das Gateways f\u00fcr message.installWizard.tooltip.addPod.reservedSystemNetmask=Die Subnetzmaske des Gast-Netzwerks message.installWizard.tooltip.addPrimaryStorage.name=Der Name der Storage Devices message.installWizard.tooltip.addPrimaryStorage.path=(f\u00fcr NFS) Bei NFS wird hier der exportierte Pfad (Shared Mount Point) angegeben. F\u00fcr KVM wird hier der Pfad angegeben, wo auf jedem Host das primary storage gemountet wurde. Z.B. "/mnt/primary" -message.installWizard.tooltip.addPrimaryStorage.server=(f\u00fcr NFS, iSCSI oder PreSetup) Die IP-Adresse oder der DNS-Name des storage devices. -message.installWizard.tooltip.addSecondaryStorage.nfsServer=Die IP-Adresse des NFS-Servers, der den Secondary Storage bereitstellt. -message.installWizard.tooltip.addSecondaryStorage.path=Der exportierte Pfad, der auf dem o.a. Server liegt. +message.installWizard.tooltip.addPrimaryStorage.server=(f\u00fcr NFS, iSCSI oder PreSetup) Die IP-Adresse oder der DNS-Name des storage devices. +message.installWizard.tooltip.addSecondaryStorage.nfsServer=Die IP-Adresse des NFS-Servers, der den Secondary Storage bereitstellt. +message.installWizard.tooltip.addSecondaryStorage.path=Der exportierte Pfad, der auf dem o.a. Server liegt. message.installWizard.tooltip.addZone.name=Der Name f\u00fcr die zone -message.installWizard.tooltip.configureGuestTraffic.description=Eine Beschreibung des Netzwerkes. -message.installWizard.tooltip.configureGuestTraffic.guestGateway=Das gateway, welches der Gast benutzen soll. +message.installWizard.tooltip.configureGuestTraffic.description=Eine Beschreibung des Netzwerkes. +message.installWizard.tooltip.configureGuestTraffic.guestGateway=Das gateway, welches der Gast benutzen soll. message.installWizard.tooltip.configureGuestTraffic.guestNetmask=Die Subnetzmaske des Gast-Netzwerks message.installWizard.tooltip.configureGuestTraffic.name=Der Name f\u00fcr das Netzwerk message.migrate.instance.to.host=Bitte best\u00e4tigen sie, dass die Instanz auf einen anderen Host migriert werden soll -message.migrate.instance.to.ps=Bitte best\u00e4tigen sie, dass sie die Instanz auf einen anderen prim\u00e4ren Speicher migrieren wollen. +message.migrate.instance.to.ps=Bitte best\u00e4tigen sie, dass sie die Instanz auf einen anderen prim\u00e4ren Speicher migrieren wollen. message.new.user=Spezifieren Sie das folgende um einen neuen Nutzer dem Benutzerkonto hinzuzuf\u00fcgen message.remove.vpn.access=Bitte best\u00e4tigen Sie, dass Sie den VPN-Zugriff vom folgenden Benutzer entfernen m\u00f6chten. message.setup.successful=Cloud setup erfolgreich diff --git a/client/WEB-INF/classes/resources/messages_es.properties b/client/WEB-INF/classes/resources/messages_es.properties index 28f9363724a..16cfc1cda49 100644 --- a/client/WEB-INF/classes/resources/messages_es.properties +++ b/client/WEB-INF/classes/resources/messages_es.properties @@ -15,7 +15,8 @@ # specific language governing permissions and limitations # under the License. -error.installWizard.message=Algo salio mal, debes ir para atr\u00e1s y corregir los error. + +error.installWizard.message=Algo salio mal, debes ir para atr\u00e1s y corregir los error. error.login=Su nombre de usuario / contrase\u00c3\u00b1a no coincide con nuestros registros. error.mgmt.server.inaccessible=El Servidor de Gesti\u00c3\u00b3n es inaccesible. Por favor, int\u00c3\u00a9ntelo de nuevo m\u00c3\u00a1s tarde. error.session.expired=Su sesi\u00c3\u00b3n ha caducado. @@ -31,133 +32,133 @@ ICMP.code=ICMP C\u00c3\u00b3digo ICMP.type=Tipo ICMP image.directory=Directorio de la imagen inline=en l\u00c3\u00adnea -label.account=Cuenta -label.account.id=ID de la cuenta -label.account.name=Nombre de la cuenta +label.account=Cuenta +label.account.id=ID de la cuenta +label.account.name=Nombre de la cuenta label.accounts=Cuentas -label.account.specific=espec\u00c3\u00adficas de la cuenta +label.account.specific=espec\u00c3\u00adficas de la cuenta label.acquire.new.ip=adquirir nuevas IP -label.action.attach.disk=Conecte el disco -label.action.attach.disk.processing=disco Fijaci\u00c3\u00b3n .... -label.action.attach.iso=Adjuntar ISO -label.action.attach.iso.processing=Colocaci\u00c3\u00b3n de la norma ISO .... -label.action.cancel.maintenance.mode=Cancelar modo de mantenimiento -label.action.cancel.maintenance.mode.processing=Cancelaci\u00c3\u00b3n del modo de mantenimiento .... -label.action.change.password=Cambiar contrase\u00c3\u00b1a -label.action.change.service=Cambio de Servicio -label.action.change.service.processing=Cambio de servicio .... -label.action.copy.ISO=Copia de la ISO -label.action.copy.ISO.processing=hacer frente ISO .... -label.action.copy.template=Copia de plantilla -label.action.copy.template.processing=hacer frente plantilla .... -label.action.create.template=Crear plantilla +label.action.attach.disk=Conecte el disco +label.action.attach.disk.processing=disco Fijaci\u00c3\u00b3n .... +label.action.attach.iso=Adjuntar ISO +label.action.attach.iso.processing=Colocaci\u00c3\u00b3n de la norma ISO .... +label.action.cancel.maintenance.mode=Cancelar modo de mantenimiento +label.action.cancel.maintenance.mode.processing=Cancelaci\u00c3\u00b3n del modo de mantenimiento .... +label.action.change.password=Cambiar contrase\u00c3\u00b1a +label.action.change.service=Cambio de Servicio +label.action.change.service.processing=Cambio de servicio .... +label.action.copy.ISO=Copia de la ISO +label.action.copy.ISO.processing=hacer frente ISO .... +label.action.copy.template=Copia de plantilla +label.action.copy.template.processing=hacer frente plantilla .... +label.action.create.template=Crear plantilla label.action.create.template.from.vm=Crear plantilla de VM label.action.create.template.from.volume=Crear plantilla de volumen -label.action.create.template.processing=Creaci\u00c3\u00b3n de plantillas .... -label.action.create.vm=Crear VM -label.action.create.vm.processing=Creaci\u00c3\u00b3n de m\u00c3\u00a1quina virtual .... -label.action.create.volume=Crear volumen -label.action.create.volume.processing=Crear volumen .... -label.action.delete.account=Eliminar cuenta -label.action.delete.account.processing=Eliminar cuentas .... -label.action.delete.cluster=Borrar Grupo -label.action.delete.cluster.processing=Borrar Grupo .... -label.action.delete.disk.offering=Borrar disco Ofrenda -label.action.delete.disk.offering.processing=Borrar disco ofrece .... -label.action.delete.domain=Eliminar de dominio -label.action.delete.domain.processing=Eliminaci\u00c3\u00b3n de dominio .... -label.action.delete.firewall=Eliminar servidor de seguridad -label.action.delete.firewall.processing=Eliminaci\u00c3\u00b3n de firewall .... -label.action.delete.ingress.rule=Borrar ingreso Regla -label.action.delete.ingress.rule.processing=Eliminaci\u00c3\u00b3n de ingreso regla .... -label.action.delete.IP.range=Eliminar Rango de IP -label.action.delete.IP.range.processing=Eliminar Rango de IP .... -label.action.delete.ISO=Eliminar ISO -label.action.delete.ISO.processing=Eliminaci\u00c3\u00b3n de la norma ISO .... -label.action.delete.load.balancer=Eliminar equilibrador de carga +label.action.create.template.processing=Creaci\u00c3\u00b3n de plantillas .... +label.action.create.vm=Crear VM +label.action.create.vm.processing=Creaci\u00c3\u00b3n de m\u00c3\u00a1quina virtual .... +label.action.create.volume=Crear volumen +label.action.create.volume.processing=Crear volumen .... +label.action.delete.account=Eliminar cuenta +label.action.delete.account.processing=Eliminar cuentas .... +label.action.delete.cluster=Borrar Grupo +label.action.delete.cluster.processing=Borrar Grupo .... +label.action.delete.disk.offering=Borrar disco Ofrenda +label.action.delete.disk.offering.processing=Borrar disco ofrece .... +label.action.delete.domain=Eliminar de dominio +label.action.delete.domain.processing=Eliminaci\u00c3\u00b3n de dominio .... +label.action.delete.firewall=Eliminar servidor de seguridad +label.action.delete.firewall.processing=Eliminaci\u00c3\u00b3n de firewall .... +label.action.delete.ingress.rule=Borrar ingreso Regla +label.action.delete.ingress.rule.processing=Eliminaci\u00c3\u00b3n de ingreso regla .... +label.action.delete.IP.range=Eliminar Rango de IP +label.action.delete.IP.range.processing=Eliminar Rango de IP .... +label.action.delete.ISO=Eliminar ISO +label.action.delete.ISO.processing=Eliminaci\u00c3\u00b3n de la norma ISO .... +label.action.delete.load.balancer=Eliminar equilibrador de carga label.action.delete.load.balancer.processing=Eliminaci\u00c3\u00b3n del equilibrador de carga .... -label.action.delete.network=Eliminar Red -label.action.delete.network.processing=Eliminaci\u00c3\u00b3n de red .... -label.action.delete.pod=Eliminar Pod -label.action.delete.pod.processing=Eliminar Pod .... -label.action.delete.primary.storage=Almacenamiento primario Eliminar -label.action.delete.primary.storage.processing=Eliminaci\u00c3\u00b3n de almacenamiento primaria .... -label.action.delete.secondary.storage.processing=Eliminaci\u00c3\u00b3n de almacenamiento secundario .... -label.action.delete.secondary.storage=secundaria almacenamiento Eliminar -label.action.delete.security.group=Borrar Grupo de Seguridad -label.action.delete.security.group.processing=Eliminar grupo de seguridad .... -label.action.delete.service.offering=Eliminar Oferta de Servicio -label.action.delete.service.offering.processing=Eliminaci\u00c3\u00b3n de Oferta de Servicio .... -label.action.delete.snapshot=Eliminar instant\u00c3\u00a1nea -label.action.delete.snapshot.processing=Eliminar instant\u00c3\u00a1nea .... -label.action.delete.template=Eliminar plantilla -label.action.delete.template.processing=Eliminar plantilla .... -label.action.delete.user=Eliminar usuario -label.action.delete.user.processing=Eliminar usuario .... -label.action.delete.volume=Eliminar volumen -label.action.delete.volume.processing=Eliminar volumen .... -label.action.delete.zone=Eliminar Zona -label.action.delete.zone.processing=Eliminaci\u00c3\u00b3n de la Zona .... -label.action.destroy.instance=Destruye Instancia -label.action.destroy.instance.processing=Destrucci\u00c3\u00b3n Instancia .... +label.action.delete.network=Eliminar Red +label.action.delete.network.processing=Eliminaci\u00c3\u00b3n de red .... +label.action.delete.pod=Eliminar Pod +label.action.delete.pod.processing=Eliminar Pod .... +label.action.delete.primary.storage=Almacenamiento primario Eliminar +label.action.delete.primary.storage.processing=Eliminaci\u00c3\u00b3n de almacenamiento primaria .... +label.action.delete.secondary.storage.processing=Eliminaci\u00c3\u00b3n de almacenamiento secundario .... +label.action.delete.secondary.storage=secundaria almacenamiento Eliminar +label.action.delete.security.group=Borrar Grupo de Seguridad +label.action.delete.security.group.processing=Eliminar grupo de seguridad .... +label.action.delete.service.offering=Eliminar Oferta de Servicio +label.action.delete.service.offering.processing=Eliminaci\u00c3\u00b3n de Oferta de Servicio .... +label.action.delete.snapshot=Eliminar instant\u00c3\u00a1nea +label.action.delete.snapshot.processing=Eliminar instant\u00c3\u00a1nea .... +label.action.delete.template=Eliminar plantilla +label.action.delete.template.processing=Eliminar plantilla .... +label.action.delete.user=Eliminar usuario +label.action.delete.user.processing=Eliminar usuario .... +label.action.delete.volume=Eliminar volumen +label.action.delete.volume.processing=Eliminar volumen .... +label.action.delete.zone=Eliminar Zona +label.action.delete.zone.processing=Eliminaci\u00c3\u00b3n de la Zona .... +label.action.destroy.instance=Destruye Instancia +label.action.destroy.instance.processing=Destrucci\u00c3\u00b3n Instancia .... label.action.destroy.systemvm=destruir el sistema VM label.action.destroy.systemvm.processing=Destrucci\u00c3\u00b3n del sistema VM .... -label.action.detach.disk.processing=Extracci\u00c3\u00b3n disco .... -label.action.detach.disk=Separar disco -label.action.detach.iso.processing=Extracci\u00c3\u00b3n ISO .... -label.action.detach.iso=Separar ISO -label.action.disable.account=Desactivar cuenta -label.action.disable.account.processing=Deshabilitar cuenta .... -label.action.disable.cluster=Deshabilitar cl\u00c3\u00baster -label.action.disable.cluster.processing=Desactivaci\u00c3\u00b3n de Cluster Server .... -label.action.disable.pod=Deshabilitar Pod -label.action.disable.pod.processing=Deshabilitar Pod .... -label.action.disable.static.NAT=Deshabilitar NAT est\u00c3\u00a1tica -label.action.disable.static.NAT.processing=Deshabilitar NAT est\u00c3\u00a1tica .... -label.action.disable.user=Deshabilitar usuario -label.action.disable.user.processing=Desactivaci\u00c3\u00b3n de usuario .... -label.action.disable.zone=Deshabilitar la zona -label.action.disable.zone.processing=Desactivaci\u00c3\u00b3n de la zona .... -label.action.download.ISO=ISO Descargar -label.action.download.template=Descargar plantilla -label.action.download.volume=Descargar Volumen -label.action.download.volume.processing=Volumen Descargar .... -label.action.edit.account=Editar cuenta -label.action.edit.disk.offering=Editar disco Ofrenda -label.action.edit.domain=Editar Dominio -label.action.edit.global.setting=Editar Mundial Marco +label.action.detach.disk.processing=Extracci\u00c3\u00b3n disco .... +label.action.detach.disk=Separar disco +label.action.detach.iso.processing=Extracci\u00c3\u00b3n ISO .... +label.action.detach.iso=Separar ISO +label.action.disable.account=Desactivar cuenta +label.action.disable.account.processing=Deshabilitar cuenta .... +label.action.disable.cluster=Deshabilitar cl\u00c3\u00baster +label.action.disable.cluster.processing=Desactivaci\u00c3\u00b3n de Cluster Server .... +label.action.disable.pod=Deshabilitar Pod +label.action.disable.pod.processing=Deshabilitar Pod .... +label.action.disable.static.NAT=Deshabilitar NAT est\u00c3\u00a1tica +label.action.disable.static.NAT.processing=Deshabilitar NAT est\u00c3\u00a1tica .... +label.action.disable.user=Deshabilitar usuario +label.action.disable.user.processing=Desactivaci\u00c3\u00b3n de usuario .... +label.action.disable.zone=Deshabilitar la zona +label.action.disable.zone.processing=Desactivaci\u00c3\u00b3n de la zona .... +label.action.download.ISO=ISO Descargar +label.action.download.template=Descargar plantilla +label.action.download.volume=Descargar Volumen +label.action.download.volume.processing=Volumen Descargar .... +label.action.edit.account=Editar cuenta +label.action.edit.disk.offering=Editar disco Ofrenda +label.action.edit.domain=Editar Dominio +label.action.edit.global.setting=Editar Mundial Marco label.action.edit.host=edici\u00c3\u00b3n Anfitri\u00c3\u00b3n -label.action.edit.instance=Editar Instancia -label.action.edit.ISO=Editar ISO +label.action.edit.instance=Editar Instancia +label.action.edit.ISO=Editar ISO label.action.edit.network=Edici\u00c3\u00b3n de redes -label.action.edit.network.offering=Editar Red ofrece -label.action.edit.pod=Editar Pod -label.action.edit.primary.storage=Editar Almacenamiento primario -label.action.edit.resource.limits=Editar l\u00c3\u00admites de recursos -label.action.edit.service.offering=Editar Oferta de Servicio -label.action.edit.template=Editar plantilla -label.action.edit.user=Editar usuario -label.action.edit.zone=Edici\u00c3\u00b3n Zona -label.action.enable.account=Habilitar cuenta -label.action.enable.account.processing=cuenta de Habilitaci\u00c3\u00b3n .... -label.action.enable.cluster=Habilitar cl\u00c3\u00baster -label.action.enable.cluster.processing=Habilitar cl\u00c3\u00baster .... -label.action.enable.maintenance.mode=Activar el modo de mantenimiento -label.action.enable.maintenance.mode.processing=Habilitaci\u00c3\u00b3n del modo de mantenimiento .... -label.action.enable.pod=Habilitar Pod -label.action.enable.pod.processing=Habilitaci\u00c3\u00b3n Pod .... -label.action.enable.static.NAT=Habilitar NAT est\u00c3\u00a1tica -label.action.enable.static.NAT.processing=Habilitar NAT est\u00c3\u00a1tica .... -label.action.enable.user.processing=Habilitaci\u00c3\u00b3n del usuario .... -label.action.enable.user=usuario Activar +label.action.edit.network.offering=Editar Red ofrece +label.action.edit.pod=Editar Pod +label.action.edit.primary.storage=Editar Almacenamiento primario +label.action.edit.resource.limits=Editar l\u00c3\u00admites de recursos +label.action.edit.service.offering=Editar Oferta de Servicio +label.action.edit.template=Editar plantilla +label.action.edit.user=Editar usuario +label.action.edit.zone=Edici\u00c3\u00b3n Zona +label.action.enable.account=Habilitar cuenta +label.action.enable.account.processing=cuenta de Habilitaci\u00c3\u00b3n .... +label.action.enable.cluster=Habilitar cl\u00c3\u00baster +label.action.enable.cluster.processing=Habilitar cl\u00c3\u00baster .... +label.action.enable.maintenance.mode=Activar el modo de mantenimiento +label.action.enable.maintenance.mode.processing=Habilitaci\u00c3\u00b3n del modo de mantenimiento .... +label.action.enable.pod=Habilitar Pod +label.action.enable.pod.processing=Habilitaci\u00c3\u00b3n Pod .... +label.action.enable.static.NAT=Habilitar NAT est\u00c3\u00a1tica +label.action.enable.static.NAT.processing=Habilitar NAT est\u00c3\u00a1tica .... +label.action.enable.user.processing=Habilitaci\u00c3\u00b3n del usuario .... +label.action.enable.user=usuario Activar label.action.enable.zone=Habilitar la zona -label.action.enable.zone.processing=Habilitaci\u00c3\u00b3n de zona .... -label.action.force.reconnect=Fuerza Vuelva a conectar -label.action.force.reconnect.processing=Reconectando .... -label.action.generate.keys=Generar Claves -label.action.generate.keys.processing=Generar claves .... -label.action.lock.account=Bloqueo de cuenta -label.action.lock.account.processing=Bloqueo de cuenta .... +label.action.enable.zone.processing=Habilitaci\u00c3\u00b3n de zona .... +label.action.force.reconnect=Fuerza Vuelva a conectar +label.action.force.reconnect.processing=Reconectando .... +label.action.generate.keys=Generar Claves +label.action.generate.keys.processing=Generar claves .... +label.action.lock.account=Bloqueo de cuenta +label.action.lock.account.processing=Bloqueo de cuenta .... label.action.manage.cluster=gestionar racimo label.action.manage.cluster.processing=La gesti\u00c3\u00b3n de cl\u00c3\u00basteres .... label.action.migrate.instance=Migrar Instancia @@ -166,650 +167,650 @@ label.action.migrate.router=migrar Router label.action.migrate.router.processing=Migraci\u00c3\u00b3n router .... label.action.migrate.systemvm=Migrar del sistema VM label.action.migrate.systemvm.processing=La migraci\u00c3\u00b3n de VM del sistema .... -label.action.reboot.instance.processing=Reiniciar Instancia .... -label.action.reboot.instance=Reiniciar Instancia -label.action.reboot.router.processing=Reiniciar router .... -label.action.reboot.router=Reiniciar router -label.action.reboot.systemvm.processing=reinicio del sistema VM .... -label.action.reboot.systemvm=Reiniciar sistema VM -label.action.recurring.snapshot=recurrente instant\u00c3\u00a1neas -label.action.release.ip=estreno IP -label.action.release.ip.processing=Liberar IP .... -label.action.remove.host.processing=Extracci\u00c3\u00b3n de host .... -label.action.remove.host=Quitar host -label.action.reset.password.processing=Restablecimiento de la contrase\u00c3\u00b1a .... -label.action.reset.password=Restablecer contrase\u00c3\u00b1a -label.action.resource.limits=Recursos l\u00c3\u00admites -label.action.restore.instance.processing=Restaurar Instancia .... -label.action.restore.instance=Restaurar Instancia -label.actions=Acciones -label.action.start.instance=Iniciar Instancia -label.action.start.instance.processing=A partir Instancia .... -label.action.start.router=inicio del router -label.action.start.router.processing=A partir del router .... -label.action.start.systemvm=Inicio del sistema VM -label.action.start.systemvm.processing=A partir del sistema VM .... -label.action.stop.instance=Detener Instancia -label.action.stop.instance.processing=Detener Instancia .... -label.action.stop.router=Detener router -label.action.stop.router.processing=Detener router .... -label.action.stop.systemvm=parada del sistema VM -label.action.stop.systemvm.processing=Detener sistema VM .... -label.action.take.snapshot.processing=Tomar instant\u00c3\u00a1neas .... -label.action.take.snapshot=Tomar instant\u00c3\u00a1nea +label.action.reboot.instance.processing=Reiniciar Instancia .... +label.action.reboot.instance=Reiniciar Instancia +label.action.reboot.router.processing=Reiniciar router .... +label.action.reboot.router=Reiniciar router +label.action.reboot.systemvm.processing=reinicio del sistema VM .... +label.action.reboot.systemvm=Reiniciar sistema VM +label.action.recurring.snapshot=recurrente instant\u00c3\u00a1neas +label.action.release.ip=estreno IP +label.action.release.ip.processing=Liberar IP .... +label.action.remove.host.processing=Extracci\u00c3\u00b3n de host .... +label.action.remove.host=Quitar host +label.action.reset.password.processing=Restablecimiento de la contrase\u00c3\u00b1a .... +label.action.reset.password=Restablecer contrase\u00c3\u00b1a +label.action.resource.limits=Recursos l\u00c3\u00admites +label.action.restore.instance.processing=Restaurar Instancia .... +label.action.restore.instance=Restaurar Instancia +label.actions=Acciones +label.action.start.instance=Iniciar Instancia +label.action.start.instance.processing=A partir Instancia .... +label.action.start.router=inicio del router +label.action.start.router.processing=A partir del router .... +label.action.start.systemvm=Inicio del sistema VM +label.action.start.systemvm.processing=A partir del sistema VM .... +label.action.stop.instance=Detener Instancia +label.action.stop.instance.processing=Detener Instancia .... +label.action.stop.router=Detener router +label.action.stop.router.processing=Detener router .... +label.action.stop.systemvm=parada del sistema VM +label.action.stop.systemvm.processing=Detener sistema VM .... +label.action.take.snapshot.processing=Tomar instant\u00c3\u00a1neas .... +label.action.take.snapshot=Tomar instant\u00c3\u00a1nea label.action.unmanage.cluster.processing=Unmanaging Grupo .... label.action.unmanage.cluster=Unmanage racimo -label.action.update.OS.preference=Actualizar OS Preferencia -label.action.update.OS.preference.processing=Actualizaci\u00c3\u00b3n de sistema operativo preferencia .... +label.action.update.OS.preference=Actualizar OS Preferencia +label.action.update.OS.preference.processing=Actualizaci\u00c3\u00b3n de sistema operativo preferencia .... label.action.update.resource.count=Actualizaci\u00c3\u00b3n de recursos Conde label.action.update.resource.count.processing=Actualizaci\u00c3\u00b3n de Conde de recursos .... -label.active.sessions=Sesiones activas -label.add.account=A\u00c3\u00b1adir cuenta -label.add=Agregar -label.add.by.cidr=A\u00c3\u00b1adir Por CIDR -label.add.by.group=A\u00c3\u00b1adir Por el Grupo de -label.add.cluster=A\u00c3\u00b1adir Grupo -label.add.direct.iprange=A\u00c3\u00b1adir Direct IP Gama -label.add.disk.offering=A\u00c3\u00b1adir disco Ofrenda -label.add.domain=Agregar dominio -label.add.firewall=Agregar Servidor de seguridad -label.add.host=Agregar host -label.adding=Agregar -label.adding.cluster=Adici\u00c3\u00b3n de cl\u00c3\u00baster -label.adding.failed=No se pudo agregar -label.adding.pod=Agregar Pod -label.adding.processing=A\u00c3\u00b1adir .... -label.add.ingress.rule=A\u00c3\u00b1adir regla del ingreso -label.adding.succeeded=Agregar Sucesor -label.adding.user=Agregar usuario -label.adding.zone=Agregar la zona -label.add.ip.range=A\u00c3\u00b1adir Rango de IP -label.additional.networks=Redes adicional -label.add.load.balancer=A\u00c3\u00b1adir equilibrador de carga -label.add.more=A\u00c3\u00b1adir m\u00c3\u00a1s -label.add.network=Agregar sitios de red +label.active.sessions=Sesiones activas +label.add.account=A\u00c3\u00b1adir cuenta +label.add=Agregar +label.add.by.cidr=A\u00c3\u00b1adir Por CIDR +label.add.by.group=A\u00c3\u00b1adir Por el Grupo de +label.add.cluster=A\u00c3\u00b1adir Grupo +label.add.direct.iprange=A\u00c3\u00b1adir Direct IP Gama +label.add.disk.offering=A\u00c3\u00b1adir disco Ofrenda +label.add.domain=Agregar dominio +label.add.firewall=Agregar Servidor de seguridad +label.add.host=Agregar host +label.adding=Agregar +label.adding.cluster=Adici\u00c3\u00b3n de cl\u00c3\u00baster +label.adding.failed=No se pudo agregar +label.adding.pod=Agregar Pod +label.adding.processing=A\u00c3\u00b1adir .... +label.add.ingress.rule=A\u00c3\u00b1adir regla del ingreso +label.adding.succeeded=Agregar Sucesor +label.adding.user=Agregar usuario +label.adding.zone=Agregar la zona +label.add.ip.range=A\u00c3\u00b1adir Rango de IP +label.additional.networks=Redes adicional +label.add.load.balancer=A\u00c3\u00b1adir equilibrador de carga +label.add.more=A\u00c3\u00b1adir m\u00c3\u00a1s +label.add.network=Agregar sitios de red label.add.network.device=A\u00c3\u00b1adir dispositivo de red -label.add.pod=A\u00c3\u00b1adir Pod -label.add.primary.storage=A\u00c3\u00b1adir Almacenamiento primario -label.add.secondary.storage=A\u00c3\u00b1adir secundaria almacenamiento -label.add.security.group=Agregar grupo de seguridad -label.add.service.offering=A\u00c3\u00b1adir Servicio de Oferta -label.add.template=A\u00c3\u00b1adir plantilla +label.add.pod=A\u00c3\u00b1adir Pod +label.add.primary.storage=A\u00c3\u00b1adir Almacenamiento primario +label.add.secondary.storage=A\u00c3\u00b1adir secundaria almacenamiento +label.add.security.group=Agregar grupo de seguridad +label.add.service.offering=A\u00c3\u00b1adir Servicio de Oferta +label.add.template=A\u00c3\u00b1adir plantilla label.add.to.group=Agregar al grupo -label.add.user=Agregar usuario -label.add.vlan=A\u00c3\u00b1adir VLAN -label.add.volume=A\u00c3\u00b1adir volumen -label.add.zone=A\u00c3\u00b1adir Zona -label.admin.accounts=Administrador de Cuentas -label.admin=Admin -label.advanced=Avanzado -label.advanced.mode=Modo avanzado -label.advanced.search=B\u00c3\u00basqueda Avanzada +label.add.user=Agregar usuario +label.add.vlan=A\u00c3\u00b1adir VLAN +label.add.volume=A\u00c3\u00b1adir volumen +label.add.zone=A\u00c3\u00b1adir Zona +label.admin.accounts=Administrador de Cuentas +label.admin=Admin +label.advanced=Avanzado +label.advanced.mode=Modo avanzado +label.advanced.search=B\u00c3\u00basqueda Avanzada label.alert=Alerta -label.algorithm=Algoritmo -label.allocated=Asignados -label.api.key=clave de API -label.assign=Asignar -label.assign.to.load.balancer=instancia de Asignaci\u00c3\u00b3n de equilibrador de carga -label.associated.network.id=ID de red asociados -label.attached.iso=adjunta ISO -label.availability=Disponibilidad -label.availability.zone=Disponibilidad de la zona +label.algorithm=Algoritmo +label.allocated=Asignados +label.api.key=clave de API +label.assign=Asignar +label.assign.to.load.balancer=instancia de Asignaci\u00c3\u00b3n de equilibrador de carga +label.associated.network.id=ID de red asociados +label.attached.iso=adjunta ISO +label.availability=Disponibilidad +label.availability.zone=Disponibilidad de la zona label.available=Disponible -label.available.public.ips=Disponible direcciones IP p\u00c3\u00bablicas -label.back=Volver -label.basic.mode=Modo b\u00c3\u00a1sico -label.bootable=arranque -label.broadcast.domain.type=Tipo de dominio de difusi\u00c3\u00b3n +label.available.public.ips=Disponible direcciones IP p\u00c3\u00bablicas +label.back=Volver +label.basic.mode=Modo b\u00c3\u00a1sico +label.bootable=arranque +label.broadcast.domain.type=Tipo de dominio de difusi\u00c3\u00b3n label.by.account=Por Cuenta -label.by.availability=Por Disponibilidad +label.by.availability=Por Disponibilidad label.by.domain=Por dominio label.by.end.date=Por Fecha de finalizaci\u00c3\u00b3n -label.by.level=por Nivel +label.by.level=por Nivel label.by.pod=Por Pod -label.by.role=por funci\u00c3\u00b3n +label.by.role=por funci\u00c3\u00b3n label.by.start.date=Por Fecha de inicio -label.by.state=Por Estado -label.bytes.received=Bytes recibidos -label.bytes.sent=Bytes enviados -label.by.traffic.type=Por tipo de tr\u00c3\u00a1fico +label.by.state=Por Estado +label.bytes.received=Bytes recibidos +label.bytes.sent=Bytes enviados +label.by.traffic.type=Por tipo de tr\u00c3\u00a1fico label.by.type.id=Por tipo de identificaci\u00c3\u00b3n -label.by.type=Por tipo +label.by.type=Por tipo label.by.zone=Por Zona -label.cancel=Cancelar -label.certificate=Certificado -label.character=Personaje -label.cidr.account=CIDR o de cuenta / Grupo de Seguridad +label.cancel=Cancelar +label.certificate=Certificado +label.character=Personaje +label.cidr.account=CIDR o de cuenta / Grupo de Seguridad label.cidr=CIDR label.cidr.list=fuente CIDR -label.close=Cerrar -label.cloud.console=Cloud Management Console -label.cloud.managed=Cloud.com Gestionado -label.cluster=Grupo -label.cluster.type=Tipo de Cluster Server +label.close=Cerrar +label.cloud.console=Cloud Management Console +label.cloud.managed=Cloud.com Gestionado +label.cluster=Grupo +label.cluster.type=Tipo de Cluster Server label.clvm=CLVM -label.code=C\u00c3\u00b3digo -label.configuration=Configuraci\u00c3\u00b3n +label.code=C\u00c3\u00b3digo +label.configuration=Configuraci\u00c3\u00b3n label.confirmation=Confirmation -label.congratulations=Felicitaciones \! +label.congratulations=Felicitaciones \! label.cpu.allocated=CPU asignado label.cpu.allocated.for.VMs=CPU asignado para m\u00c3\u00a1quinas virtuales label.CPU.cap=CPU Cap -label.cpu=CPU +label.cpu=CPU label.cpu.utilized=CPU Utilizado -label.created=creaci\u00c3\u00b3n -label.cross.zones=Cruz Zonas -label.custom.disk.size=Personal Disk Size -label.daily=diario +label.created=creaci\u00c3\u00b3n +label.cross.zones=Cruz Zonas +label.custom.disk.size=Personal Disk Size +label.daily=diario label.data.disk.offering=Datos Disco Offering -label.date=Fecha -label.day.of.month=D\u00c3\u00ada del mes -label.day.of.week=d\u00c3\u00ada de la semana +label.date=Fecha +label.day.of.month=D\u00c3\u00ada del mes +label.day.of.week=d\u00c3\u00ada de la semana label.default.use=Usar por defecto -label.delete=Eliminar -label.deleting.failed=No se pudo eliminar -label.deleting.processing=Eliminar .... -label.description=Descripci\u00c3\u00b3n -label.destroy=Destroy -label.detaching.disk=Extracci\u00c3\u00b3n del disco -label.details=Detalles -label.device.id=ID de dispositivo +label.delete=Eliminar +label.deleting.failed=No se pudo eliminar +label.deleting.processing=Eliminar .... +label.description=Descripci\u00c3\u00b3n +label.destroy=Destroy +label.detaching.disk=Extracci\u00c3\u00b3n del disco +label.details=Detalles +label.device.id=ID de dispositivo label.DHCP.server.type=Tipo de servidor DHCP -label.disabled=personas de movilidad reducida -label.disabling.vpn.access=Desactivaci\u00c3\u00b3n de VPN de acceso -label.disk.allocated=disco asignado -label.disk.offering=disco Ofrenda -label.disk.size.gb=tama\u00c3\u00b1o de disco (en GB) -label.disk.size=tama\u00c3\u00b1o de disco -label.disk.total=disco Total -label.disk.volume=volumen de disco -label.display.text=visualizaci\u00c3\u00b3n de texto -label.dns.1=DNS 1 -label.dns.2=DNS 2 -label.domain.admin=Administrador de dominio -label.domain=dominio -label.domain.id=ID de dominio -label.domain.name=Nombre de dominio +label.disabled=personas de movilidad reducida +label.disabling.vpn.access=Desactivaci\u00c3\u00b3n de VPN de acceso +label.disk.allocated=disco asignado +label.disk.offering=disco Ofrenda +label.disk.size.gb=tama\u00c3\u00b1o de disco (en GB) +label.disk.size=tama\u00c3\u00b1o de disco +label.disk.total=disco Total +label.disk.volume=volumen de disco +label.display.text=visualizaci\u00c3\u00b3n de texto +label.dns.1=DNS 1 +label.dns.2=DNS 2 +label.domain.admin=Administrador de dominio +label.domain=dominio +label.domain.id=ID de dominio +label.domain.name=Nombre de dominio label.domain.suffix=DNS sufijo de dominio (es decir, xyz.com) -label.double.quotes.are.not.allowed=comillas dobles no se permite +label.double.quotes.are.not.allowed=comillas dobles no se permite label.download.progress=Progreso de la descarga -label.edit=Editar -label.email=correo electr\u00c3\u00b3nico -label.enabling.vpn.access=Habilitaci\u00c3\u00b3n de Acceso VPN -label.enabling.vpn=Habilitaci\u00c3\u00b3n VPN -label.endpoint.or.operation=punto final o de Operaci\u00c3\u00b3n -label.end.port=Puerto final -label.error.code=C\u00c3\u00b3digo de error -label.error=Error -label.esx.host=ESX / ESXi anfitri\u00c3\u00b3n -label.example=Ejemplo -label.failed=Error -label.featured=destacados -label.firewall=Servidor de seguridad -label.first.name=Nombre -label.format=Formato -label.friday=Viernes +label.edit=Editar +label.email=correo electr\u00c3\u00b3nico +label.enabling.vpn.access=Habilitaci\u00c3\u00b3n de Acceso VPN +label.enabling.vpn=Habilitaci\u00c3\u00b3n VPN +label.endpoint.or.operation=punto final o de Operaci\u00c3\u00b3n +label.end.port=Puerto final +label.error.code=C\u00c3\u00b3digo de error +label.error=Error +label.esx.host=ESX / ESXi anfitri\u00c3\u00b3n +label.example=Ejemplo +label.failed=Error +label.featured=destacados +label.firewall=Servidor de seguridad +label.first.name=Nombre +label.format=Formato +label.friday=Viernes label.full=completo -label.gateway=puerta de enlace -label.general.alerts=General de Alertas -label.generating.url=Generar URL -label.go.step.2=Ir al paso 2 -label.go.step.3=Ir al paso 3 -label.go.step.4=Ir al paso 4 -label.go.step.5=Ir al paso 5 -label.group=Grupo -label.group.optional=Grupo (Opcional) -label.guest.cidr=Habitaci\u00c3\u00b3n CIDR -label.guest.gateway=Habitaci\u00c3\u00b3n Gateway -label.guest.ip=Habitaci\u00c3\u00b3n direcci\u00c3\u00b3n IP -label.guest.ip.range=Habitaci\u00c3\u00b3n Rango de IP -label.guest.netmask=Habitaci\u00c3\u00b3n m\u00c3\u00a1scara de red -label.ha.enabled=HA Activado -label.help=Ayuda +label.gateway=puerta de enlace +label.general.alerts=General de Alertas +label.generating.url=Generar URL +label.go.step.2=Ir al paso 2 +label.go.step.3=Ir al paso 3 +label.go.step.4=Ir al paso 4 +label.go.step.5=Ir al paso 5 +label.group=Grupo +label.group.optional=Grupo (Opcional) +label.guest.cidr=Habitaci\u00c3\u00b3n CIDR +label.guest.gateway=Habitaci\u00c3\u00b3n Gateway +label.guest.ip=Habitaci\u00c3\u00b3n direcci\u00c3\u00b3n IP +label.guest.ip.range=Habitaci\u00c3\u00b3n Rango de IP +label.guest.netmask=Habitaci\u00c3\u00b3n m\u00c3\u00a1scara de red +label.ha.enabled=HA Activado +label.help=Ayuda label.hide.ingress.rule=Ocultar el art\u00c3\u00adculo ingreso -label.host.alerts=Host Alertas -label.host=Ej\u00c3\u00a9rcitos -label.host.name=nombre de host -label.hosts=Ej\u00c3\u00a9rcitos -label.hourly=por hora -label.hypervisor=Hypervisor -label.hypervisor.type=Tipo Hypervisor -label.id=ID -label.info=Informaci\u00c3\u00b3n -label.ingress.rule=ingreso Regla -label.initiated.by=Iniciado por -label.installWizard.click.launch=Click en el bot\u00f3n de lanzar. -label.instance=Instancia -label.instance.limits=Instancia L\u00c3\u00admites -label.instance.name=Nombre de instancia -label.instances=Instancias -label.internal.dns.1=DNS interno una -label.internal.dns.2=DNS interno 2 -label.interval.type=Tipo de intervalo -label.invalid.integer=entero no v\u00c3\u00a1lido -label.invalid.number=N\u00c3\u00bamero no v\u00c3\u00a1lido +label.host.alerts=Host Alertas +label.host=Ej\u00c3\u00a9rcitos +label.host.name=nombre de host +label.hosts=Ej\u00c3\u00a9rcitos +label.hourly=por hora +label.hypervisor=Hypervisor +label.hypervisor.type=Tipo Hypervisor +label.id=ID +label.info=Informaci\u00c3\u00b3n +label.ingress.rule=ingreso Regla +label.initiated.by=Iniciado por +label.installWizard.click.launch=Click en el bot\u00f3n de lanzar. +label.instance=Instancia +label.instance.limits=Instancia L\u00c3\u00admites +label.instance.name=Nombre de instancia +label.instances=Instancias +label.internal.dns.1=DNS interno una +label.internal.dns.2=DNS interno 2 +label.interval.type=Tipo de intervalo +label.invalid.integer=entero no v\u00c3\u00a1lido +label.invalid.number=N\u00c3\u00bamero no v\u00c3\u00a1lido label.invite=Invitar label.invite.to=Invitar a . -label.ip.address=Direcci\u00c3\u00b3n IP -label.ipaddress=Direcci\u00c3\u00b3n IP -label.ip.allocations=IP asignaciones -label.ip=IP -label.ip.limits=IP p\u00c3\u00bablica L\u00c3\u00admites -label.ip.or.fqdn=IP o FQDN -label.ip.range=Rango de IP -label.ips=IP -label.iscsi=iSCSI -label.is.default=Es por defecto -label.iso.boot=ISO de arranque -label.iso=ISO +label.ip.address=Direcci\u00c3\u00b3n IP +label.ipaddress=Direcci\u00c3\u00b3n IP +label.ip.allocations=IP asignaciones +label.ip=IP +label.ip.limits=IP p\u00c3\u00bablica L\u00c3\u00admites +label.ip.or.fqdn=IP o FQDN +label.ip.range=Rango de IP +label.ips=IP +label.iscsi=iSCSI +label.is.default=Es por defecto +label.iso.boot=ISO de arranque +label.iso=ISO label.isolation.mode=modo de aislamiento label.is.redundant.router=redundante -label.is.shared=es compartido -label.is.system=es el Sistema -label.keep=Mantener -label.lang.chinese=Chino (simplificado) -label.lang.english=Ingl\u00c3\u00a9s -label.lang.japanese=japon\u00c3\u00a9s -label.lang.spanish=Espa\u00c3\u00b1ol -label.last.disconnected=\u00c3\u009altima Desconectado -label.last.name=Apellido +label.is.shared=es compartido +label.is.system=es el Sistema +label.keep=Mantener +label.lang.chinese=Chino (simplificado) +label.lang.english=Ingl\u00c3\u00a9s +label.lang.japanese=japon\u00c3\u00a9s +label.lang.spanish=Espa\u00c3\u00b1ol +label.last.disconnected=\u00c3\u009altima Desconectado +label.last.name=Apellido label.launch=Lanzar label.launch.vm=Lanzar maquina virtual -label.level=Nivel -label.load.balancer=equilibrador de carga -label.loading=Carga -label.local=local -label.login=Login -label.logout=Cerrar sesi\u00c3\u00b3n -label.lun=LUN -label.manage=Administrar -label.maximum=m\u00c3\u00a1ximo +label.level=Nivel +label.load.balancer=equilibrador de carga +label.loading=Carga +label.local=local +label.login=Login +label.logout=Cerrar sesi\u00c3\u00b3n +label.lun=LUN +label.manage=Administrar +label.maximum=m\u00c3\u00a1ximo label.max.volumes=Maxima cantidad de Volumes -label.memory.allocated=memoria asignada -label.memory=memoria (en MB) -label.memory.total=Total de memoria -label.memory.used=memoria usada +label.memory.allocated=memoria asignada +label.memory=memoria (en MB) +label.memory.total=Total de memoria +label.memory.used=memoria usada label.menu.accounts=Cuentas -label.menu.alerts=Alertas -label.menu.all.accounts=Todas las cuentas -label.menu.all.instances=todas las instancias -label.menu.community.isos=Comunidad ISOs -label.menu.community.templates=plantillas de la comunidad -label.menu.configuration=Configuraci\u00c3\u00b3n -label.menu.dashboard=Interfaz -label.menu.destroyed.instances=Destruir instancias -label.menu.disk.offerings=disco ofertas -label.menu.domains=dominio -label.menu.events=Eventos -label.menu.featured.isos=destacados ISO -label.menu.featured.templates=destacados plantillas -label.menu.global.settings=Configuraci\u00c3\u00b3n global -label.menu.instances=Instancias -label.menu.ipaddresses=Direcciones IP -label.menu.isos=ISO -label.menu.my.accounts=Mis cuentas -label.menu.my.instances=Mi instancias -label.menu.my.isos=Mi ISOs -label.menu.my.templates=Mis plantillas -label.menu.network.offerings=Red de ofertas -label.menu.network=Red -label.menu.physical.resources=Recursos F\u00c3\u00adsicos -label.menu.running.instances=Ejecuci\u00c3\u00b3n de instancias -label.menu.security.groups=Grupos de seguridad -label.menu.service.offerings=Ofertas de Servicios -label.menu.snapshots=instant\u00c3\u00a1neas -label.menu.stopped.instances=Detenido instancias -label.menu.storage=Almacenamiento -label.menu.system=Sistema -label.menu.system.vms=Sistema de m\u00c3\u00a1quinas virtuales -label.menu.templates=plantillas -label.menu.virtual.appliances=Virtual Appliances -label.menu.virtual.resources=Virtual de Recursos -label.menu.volumes=Vol\u00c3\u00bamenes +label.menu.alerts=Alertas +label.menu.all.accounts=Todas las cuentas +label.menu.all.instances=todas las instancias +label.menu.community.isos=Comunidad ISOs +label.menu.community.templates=plantillas de la comunidad +label.menu.configuration=Configuraci\u00c3\u00b3n +label.menu.dashboard=Interfaz +label.menu.destroyed.instances=Destruir instancias +label.menu.disk.offerings=disco ofertas +label.menu.domains=dominio +label.menu.events=Eventos +label.menu.featured.isos=destacados ISO +label.menu.featured.templates=destacados plantillas +label.menu.global.settings=Configuraci\u00c3\u00b3n global +label.menu.instances=Instancias +label.menu.ipaddresses=Direcciones IP +label.menu.isos=ISO +label.menu.my.accounts=Mis cuentas +label.menu.my.instances=Mi instancias +label.menu.my.isos=Mi ISOs +label.menu.my.templates=Mis plantillas +label.menu.network.offerings=Red de ofertas +label.menu.network=Red +label.menu.physical.resources=Recursos F\u00c3\u00adsicos +label.menu.running.instances=Ejecuci\u00c3\u00b3n de instancias +label.menu.security.groups=Grupos de seguridad +label.menu.service.offerings=Ofertas de Servicios +label.menu.snapshots=instant\u00c3\u00a1neas +label.menu.stopped.instances=Detenido instancias +label.menu.storage=Almacenamiento +label.menu.system=Sistema +label.menu.system.vms=Sistema de m\u00c3\u00a1quinas virtuales +label.menu.templates=plantillas +label.menu.virtual.appliances=Virtual Appliances +label.menu.virtual.resources=Virtual de Recursos +label.menu.volumes=Vol\u00c3\u00bamenes label.migrate.instance.to.host=Migrar instancia a otro host. label.migrate.instance.to=Migraci\u00c3\u00b3n de ejemplo para label.migrate.instance.to.ps=Migrar instancia a otro primary storage. label.migrate.router.to=Router para migrar label.migrate.systemvm.to=Migrar m\u00c3\u00a1quina virtual del sistema para -label.minimum=M\u00c3\u00adnimo -label.minute.past.hour=Minuto (s) despu\u00c3\u00a9s de la hora -label.monday=lunes -label.monthly=mensual -label.more.templates=plantillas \= M\u00c3\u00a1s -label.my.account=Mi Cuenta +label.minimum=M\u00c3\u00adnimo +label.minute.past.hour=Minuto (s) despu\u00c3\u00a9s de la hora +label.monday=lunes +label.monthly=mensual +label.more.templates=plantillas \= M\u00c3\u00a1s +label.my.account=Mi Cuenta label.my.templates=Mis plantillas -label.name=Nombre -label.name.optional=Nombre (Opcional) -label.netmask=m\u00c3\u00a1scara de red -label.network.desc=Red de Desc +label.name=Nombre +label.name.optional=Nombre (Opcional) +label.netmask=m\u00c3\u00a1scara de red +label.network.desc=Red de Desc label.network.device=De dispositivos de red label.network.device.type=Tipo de red de dispositivos label.network.domain=red de dominio -label.network.id=ID de red -label.network.name=Nombre de red -label.network.offering.display.text=Red ofrece visualizaci\u00c3\u00b3n de texto -label.network.offering.id=Red ofrece ID -label.network.offering.name=Red ofrece Nombre -label.network.offering=Red ofrece -label.network.rate=Tasa de Red -label.network.read=Leer de la red -label.network=Red +label.network.id=ID de red +label.network.name=Nombre de red +label.network.offering.display.text=Red ofrece visualizaci\u00c3\u00b3n de texto +label.network.offering.id=Red ofrece ID +label.network.offering.name=Red ofrece Nombre +label.network.offering=Red ofrece +label.network.rate=Tasa de Red +label.network.read=Leer de la red +label.network=Red label.networks=Redes -label.network.type=Tipo de red -label.network.write=Escribir en la red +label.network.type=Tipo de red +label.network.write=Escribir en la red label.new=Nuevo -label.new.password=Nueva contrase\u00c3\u00b1a +label.new.password=Nueva contrase\u00c3\u00b1a label.new.vm=Nueva maquina virtual -label.next=Siguiente -label.nfs=NFS -label.nfs.server=servidor NFS -label.nfs.storage=NFS Almacenamiento -label.nics=NIC -label.no.actions=No Acciones disponibles -label.no.alerts=No alertas recientes -label.no.errors=No recientes errores -label.no.isos=No ISOs disponibles -label.no.items=No art\u00c3\u00adculos disponibles +label.next=Siguiente +label.nfs=NFS +label.nfs.server=servidor NFS +label.nfs.storage=NFS Almacenamiento +label.nics=NIC +label.no.actions=No Acciones disponibles +label.no.alerts=No alertas recientes +label.no.errors=No recientes errores +label.no.isos=No ISOs disponibles +label.no.items=No art\u00c3\u00adculos disponibles label.none=Ninguno -label.no=No -label.no.security.groups=No hay grupos disponibles de Seguridad +label.no=No +label.no.security.groups=No hay grupos disponibles de Seguridad label.not.found=No se ha encontrado -label.no.thanks=No, gracias -label.num.cpu.cores=n\u00c3\u00bamero de n\u00c3\u00bacleos de CPU +label.no.thanks=No, gracias +label.num.cpu.cores=n\u00c3\u00bamero de n\u00c3\u00bacleos de CPU label.numretries=N\u00c3\u00bamero de reintentos label.ocfs2=OCFS2 -label.offer.ha=Oferta HA -label.optional=Opcional -label.os.preference=OS Preferencia -label.os.type=tipo de Sistema Operativo -label.owned.public.ips=propiedad p\u00c3\u00bablica Direcciones IP -label.owner.account=titular de la cuenta -label.parent.domain=Padres de dominio -label.password=Contrase\u00c3\u00b1a -label.password.enabled=Contrase\u00c3\u00b1a Activado -label.path=Ruta +label.offer.ha=Oferta HA +label.optional=Opcional +label.os.preference=OS Preferencia +label.os.type=tipo de Sistema Operativo +label.owned.public.ips=propiedad p\u00c3\u00bablica Direcciones IP +label.owner.account=titular de la cuenta +label.parent.domain=Padres de dominio +label.password=Contrase\u00c3\u00b1a +label.password.enabled=Contrase\u00c3\u00b1a Activado +label.path=Ruta label.PING.CIFS.password=PING CIFS contrase\u00c3\u00b1a label.PING.CIFS.username=PING CIFS nombre de usuario label.PING.dir=PING Directorio label.PING.storage.IP=PING almacenamiento IP -label.please.wait=Por favor espere -label.pod=Pod -label.port.forwarding=Port Forwarding -label.port.range=rango de puertos +label.please.wait=Por favor espere +label.pod=Pod +label.port.forwarding=Port Forwarding +label.port.range=rango de puertos label.PreSetup=PreSetup -label.prev=Anterior +label.prev=Anterior label.previous=Previo -label.primary.allocated=primaria asignado de almacenamiento -label.primary.network=Red Primaria -label.primary.storage=Almacenamiento Primario -label.primary.used=Primaria Almacenado -label.private.interface=Interfaz privada -label.private.ip=direcci\u00c3\u00b3n IP privada -label.private.ip.range=IP privada Gama -label.private.ips=direcciones IP privadas +label.primary.allocated=primaria asignado de almacenamiento +label.primary.network=Red Primaria +label.primary.storage=Almacenamiento Primario +label.primary.used=Primaria Almacenado +label.private.interface=Interfaz privada +label.private.ip=direcci\u00c3\u00b3n IP privada +label.private.ip.range=IP privada Gama +label.private.ips=direcciones IP privadas label.privatekey=PKCS\#8 la clave privada -label.private.port=Puerto privado -label.private.zone=Zona Privada +label.private.port=Puerto privado +label.private.zone=Zona Privada label.project.name=Nombre del Proyecto -label.protocol=Protocolo -label.public.interface=interfaz p\u00c3\u00bablica -label.public.ip=direcci\u00c3\u00b3n IP p\u00c3\u00bablica -label.public.ips=direcciones IP p\u00c3\u00bablicas -label.public.port=Puerto P\u00c3\u00bablico -label.public=P\u00c3\u00bablica -label.public.zone=Zona P\u00c3\u00bablica +label.protocol=Protocolo +label.public.interface=interfaz p\u00c3\u00bablica +label.public.ip=direcci\u00c3\u00b3n IP p\u00c3\u00bablica +label.public.ips=direcciones IP p\u00c3\u00bablicas +label.public.port=Puerto P\u00c3\u00bablico +label.public=P\u00c3\u00bablica +label.public.zone=Zona P\u00c3\u00bablica label.Pxe.server.type=Tipo de servidor Pxe -label.reboot=Reiniciar -label.recent.errors=recientes errores +label.reboot=Reiniciar +label.recent.errors=recientes errores label.redundant.router=enrutador redundante -label.refresh=Actualizar -label.related=relacionados -label.remind.later=Recordar mas tarde -label.remove.from.load.balancer=ejemplo Eliminaci\u00c3\u00b3n de equilibrador de carga +label.refresh=Actualizar +label.related=relacionados +label.remind.later=Recordar mas tarde +label.remove.from.load.balancer=ejemplo Eliminaci\u00c3\u00b3n de equilibrador de carga label.removing=Borrando. -label.removing.user=Eliminar usuario -label.required=Requerido -label.reserved.system.ip=Reservados sistema de PI -label.resource.limits=L\u00c3\u00admites de Recursos -label.resource=Recursos -label.resources=Recursos -label.role=Papel +label.removing.user=Eliminar usuario +label.required=Requerido +label.reserved.system.ip=Reservados sistema de PI +label.resource.limits=L\u00c3\u00admites de Recursos +label.resource=Recursos +label.resources=Recursos +label.role=Papel label.root.disk.offering=Root Disco Offering -label.running.vms=Ejecuci\u00c3\u00b3n de m\u00c3\u00a1quinas virtuales -label.s3.secret_key=clave secreta -label.saturday=s\u00c3\u00a1bado -label.save=Guardar -label.saving.processing=ahorro .... -label.scope=Alcance -label.search=Buscar -label.secondary.storage=Almacenamiento secundario -label.secondary.used=Secundaria Almacenado -label.secret.key=clave secreta -label.security.group=Grupo de Seguridad -label.security.group.name=Nombre de grupo de seguridad +label.running.vms=Ejecuci\u00c3\u00b3n de m\u00c3\u00a1quinas virtuales +label.s3.secret_key=clave secreta +label.saturday=s\u00c3\u00a1bado +label.save=Guardar +label.saving.processing=ahorro .... +label.scope=Alcance +label.search=Buscar +label.secondary.storage=Almacenamiento secundario +label.secondary.used=Secundaria Almacenado +label.secret.key=clave secreta +label.security.group=Grupo de Seguridad +label.security.group.name=Nombre de grupo de seguridad label.security.groups.enabled=Los grupos de seguridad habilitado -label.security.groups=Grupos de seguridad +label.security.groups=Grupos de seguridad label.select.a.zone=Seleccione una zona. -label.sent=Enviados -label.server=Servidor -label.service.offering=Oferta de Servicio +label.sent=Enviados +label.server=Servidor +label.service.offering=Oferta de Servicio label.session.expired=Session Caducado -label.shared=compartidas -label.SharedMountPoint=SharedMountPoint +label.shared=compartidas +label.SharedMountPoint=SharedMountPoint label.show.ingress.rule=Mostrar la regla del ingreso -label.size=Tama\u00c3\u00b1o -label.snapshot=Instant\u00c3\u00a1nea -label.snapshot.limits=instant\u00c3\u00a1neas L\u00c3\u00admites -label.snapshot.name=Nombre de instant\u00c3\u00a1neas -label.snapshot.schedule=Lista de instant\u00c3\u00a1neas -label.snapshot.s=Instant\u00c3\u00a1nea (s) -label.snapshots=instant\u00c3\u00a1neas -label.source.nat=NAT Fuente -label.specify.vlan=Especifique VLAN +label.size=Tama\u00c3\u00b1o +label.snapshot=Instant\u00c3\u00a1nea +label.snapshot.limits=instant\u00c3\u00a1neas L\u00c3\u00admites +label.snapshot.name=Nombre de instant\u00c3\u00a1neas +label.snapshot.schedule=Lista de instant\u00c3\u00a1neas +label.snapshot.s=Instant\u00c3\u00a1nea (s) +label.snapshots=instant\u00c3\u00a1neas +label.source.nat=NAT Fuente +label.specify.vlan=Especifique VLAN label.SR.name = SR Nombre de etiqueta -label.start.port=Iniciar Puerto -label.state=Estado -label.static.nat=NAT est\u00c3\u00a1tica -label.static.nat.to=est\u00c3\u00a1tico NAT para -label.statistics=Estad\u00c3\u00adsticas -label.status=Estado -label.step.1=Paso 1 -label.step.1.title=Paso 1\: Seleccione una plantilla -label.step.2=Paso 2 -label.step.2.title=Paso 2\: Oferta de Servicio -label.step.3=Paso 3 -label.step.3.title=Paso 3\: Seleccione un disco Ofrenda -label.step.4=Paso 4 -label.step.4.title=Paso 4\: Red -label.step.5=Paso 5 -label.step.5.title=Paso 5\: Revisi\u00c3\u00b3n -label.sticky.domain=dominio +label.start.port=Iniciar Puerto +label.state=Estado +label.static.nat=NAT est\u00c3\u00a1tica +label.static.nat.to=est\u00c3\u00a1tico NAT para +label.statistics=Estad\u00c3\u00adsticas +label.status=Estado +label.step.1=Paso 1 +label.step.1.title=Paso 1\: Seleccione una plantilla +label.step.2=Paso 2 +label.step.2.title=Paso 2\: Oferta de Servicio +label.step.3=Paso 3 +label.step.3.title=Paso 3\: Seleccione un disco Ofrenda +label.step.4=Paso 4 +label.step.4.title=Paso 4\: Red +label.step.5=Paso 5 +label.step.5.title=Paso 5\: Revisi\u00c3\u00b3n +label.sticky.domain=dominio label.sticky.mode=modo -label.stop=Detener -label.stopped.vms=Detenido m\u00c3\u00a1quinas virtuales -label.storage=Almacenamiento +label.stop=Detener +label.stopped.vms=Detenido m\u00c3\u00a1quinas virtuales +label.storage=Almacenamiento label.storage.tags=Etiquetas de almacenamiento -label.storage.type=Tipo de almacenamiento -label.submit=Enviar -label.submitted.by=[Enviado por\: ] -label.succeeded=Sucesor -label.sunday=domingo -label.system.capacity=Capacidad de todo el sistema -label.system.vm=Sistema de VM -label.system.vms=Sistema de m\u00c3\u00a1quinas virtuales -label.system.vm.type=Tipo de sistema VM -label.tagged=etiqueta -label.tags=Etiquetas -label.target.iqn=Objetivo IQN -label.task.completed=Tarea finalizada. -label.template.limits=Plantilla L\u00c3\u00admites -label.template=plantilla +label.storage.type=Tipo de almacenamiento +label.submit=Enviar +label.submitted.by=[Enviado por\: ] +label.succeeded=Sucesor +label.sunday=domingo +label.system.capacity=Capacidad de todo el sistema +label.system.vm=Sistema de VM +label.system.vms=Sistema de m\u00c3\u00a1quinas virtuales +label.system.vm.type=Tipo de sistema VM +label.tagged=etiqueta +label.tags=Etiquetas +label.target.iqn=Objetivo IQN +label.task.completed=Tarea finalizada. +label.template.limits=Plantilla L\u00c3\u00admites +label.template=plantilla label.TFTP.dir=Directorio de TFTP -label.theme.default=Tema Por Defecto +label.theme.default=Tema Por Defecto label.theme.grey=Personal - Gris label.theme.lightblue=Personal - Azul -label.thursday=Jueves +label.thursday=Jueves label.timeout.in.second = Tiempo de espera (segundos) -label.time=Tiempo -label.time.zone=Zona horaria -label.timezone=Zona horaria +label.time=Tiempo +label.time.zone=Zona horaria +label.timezone=Zona horaria label.total.cpu=Total CPU label.total.CPU=Total CPU -label.total.vms=Total de m\u00c3\u00a1quinas virtuales -label.traffic.type=Tipo de Tr\u00c3\u00a1fico -label.tuesday=martes -label.type.id=Tipo de identificaci\u00c3\u00b3n -label.type=Tipo -label.unavailable=no disponible +label.total.vms=Total de m\u00c3\u00a1quinas virtuales +label.traffic.type=Tipo de Tr\u00c3\u00a1fico +label.tuesday=martes +label.type.id=Tipo de identificaci\u00c3\u00b3n +label.type=Tipo +label.unavailable=no disponible label.unlimited=Unlimited -label.untagged=sin etiquetar -label.updating=Actualizar +label.untagged=sin etiquetar +label.updating=Actualizar label.url=URL -label.usage.interface=Interfaz de uso -label.used=Usado -label.username=Nombre de usuario -label.users=usuario -label.user=Usuario -label.value=Valor -label.vcenter.cluster=vCenter cl\u00c3\u00baster -label.vcenter.datacenter=vCenter de centros de datos -label.vcenter.datastore=vCenter almac\u00c3\u00a9n de datos -label.vcenter.host=vCenter anfitri\u00c3\u00b3n -label.vcenter.password=vCenter Contrase\u00c3\u00b1a -label.vcenter.username=vCenter Nombre de usuario -label.version=Versi\u00c3\u00b3n -label.virtual.appliances=Virtual Appliances -label.virtual.appliance=Virtual Appliance +label.usage.interface=Interfaz de uso +label.used=Usado +label.username=Nombre de usuario +label.users=usuario +label.user=Usuario +label.value=Valor +label.vcenter.cluster=vCenter cl\u00c3\u00baster +label.vcenter.datacenter=vCenter de centros de datos +label.vcenter.datastore=vCenter almac\u00c3\u00a9n de datos +label.vcenter.host=vCenter anfitri\u00c3\u00b3n +label.vcenter.password=vCenter Contrase\u00c3\u00b1a +label.vcenter.username=vCenter Nombre de usuario +label.version=Versi\u00c3\u00b3n +label.virtual.appliances=Virtual Appliances +label.virtual.appliance=Virtual Appliance label.virtual.machines=Maquinas virtuales -label.virtual.network=Red Virtual -label.vlan.id=ID de VLAN -label.vlan.range=VLAN Gama -label.vlan=VLAN -label.vm.add=A\u00c3\u00b1adir Instancia -label.vm.destroy=Destroy +label.virtual.network=Red Virtual +label.vlan.id=ID de VLAN +label.vlan.range=VLAN Gama +label.vlan=VLAN +label.vm.add=A\u00c3\u00b1adir Instancia +label.vm.destroy=Destroy label.VMFS.datastore=VMFS de datos tienda -label.vmfs=VMFS -label.vm.reboot=Reiniciar -label.vmsnapshot.type=Tipo -label.vm.start=Inicio -label.vm.stop=Detener -label.vms=VM +label.vmfs=VMFS +label.vm.reboot=Reiniciar +label.vmsnapshot.type=Tipo +label.vm.start=Inicio +label.vm.stop=Detener +label.vms=VM label.volgroup=Volume Group -label.volume.limits=l\u00c3\u00admites de volumen -label.volume.name=Nombre de Volumen -label.volumes=Vol\u00c3\u00bamenes -label.volume=Volumen -label.vpn=VPN -label.vsphere.managed=Gestionado \= vSphere -label.waiting=Esperando -label.warn=Advertir -label.wednesday=mi\u00c3\u00a9rcoles -label.weekly=Semanal -label.welcome=Bienvenido -label.welcome.cloud.console=Bienvenido a la consola de administraci\u00c3\u00b3n -label.yes=S\u00c3\u00ad -label.zone.id=Zona de identificaci\u00c3\u00b3n -label.zone.step.1.title=Paso 1\: Seleccione una red -label.zone.step.2.title=Paso 2\: A\u00c3\u00b1adir una zona -label.zone.step.3.title=Paso 3\: A\u00c3\u00b1adir una vaina -label.zone.step.4.title=Paso 4\: A\u00c3\u00b1adir un rango de IP -label.zone.wide=Zona para todo el +label.volume.limits=l\u00c3\u00admites de volumen +label.volume.name=Nombre de Volumen +label.volumes=Vol\u00c3\u00bamenes +label.volume=Volumen +label.vpn=VPN +label.vsphere.managed=Gestionado \= vSphere +label.waiting=Esperando +label.warn=Advertir +label.wednesday=mi\u00c3\u00a9rcoles +label.weekly=Semanal +label.welcome=Bienvenido +label.welcome.cloud.console=Bienvenido a la consola de administraci\u00c3\u00b3n +label.yes=S\u00c3\u00ad +label.zone.id=Zona de identificaci\u00c3\u00b3n +label.zone.step.1.title=Paso 1\: Seleccione una red +label.zone.step.2.title=Paso 2\: A\u00c3\u00b1adir una zona +label.zone.step.3.title=Paso 3\: A\u00c3\u00b1adir una vaina +label.zone.step.4.title=Paso 4\: A\u00c3\u00b1adir un rango de IP +label.zone.wide=Zona para todo el label.zone=Zona managed.state=Estado logr\u00c3\u00b3 -message.acquire.public.ip=Por favor seleccione una zona de la que desea adquirir su nueva IP. -message.action.cancel.maintenance.mode=Por favor, confirme que desea cancelar el mantenimiento +message.acquire.public.ip=Por favor seleccione una zona de la que desea adquirir su nueva IP. +message.action.cancel.maintenance.mode=Por favor, confirme que desea cancelar el mantenimiento message.action.cancel.maintenance=Su acogida ha sido cancelado con \u00c3\u00a9xito para el mantenimiento. Este proceso puede tardar hasta varios minutos. -message.action.delete.cluster=Por favor, confirme que desea eliminar del cl\u00c3\u00baster -message.action.delete.disk.offering=Por favor, confirme que desea eliminar ofreciendo disco -message.action.delete.domain=Por favor, confirme que desea eliminar de dominio +message.action.delete.cluster=Por favor, confirme que desea eliminar del cl\u00c3\u00baster +message.action.delete.disk.offering=Por favor, confirme que desea eliminar ofreciendo disco +message.action.delete.domain=Por favor, confirme que desea eliminar de dominio message.action.delete.external.firewall=Por favor, confirme que desea quitar este servidor de seguridad externo. Advertencia\: Si usted est\u00c3\u00a1 planeando volver a agregar el servidor de seguridad externo mismo, debe restablecer los datos de uso en el dispositivo. message.action.delete.external.load.balancer=Por favor, confirme que desea eliminar este equilibrador de carga externa. Advertencia\: Si usted est\u00c3\u00a1 planeando volver a agregar la misma equilibrador de carga externo, debe restablecer los datos de uso en el dispositivo. -message.action.delete.ingress.rule=Por favor, confirme que desea eliminar la regla de ingreso -message.action.delete.ISO.for.all.zones=La ISO es utilizado por todas las zonas. Por favor, confirme que desea eliminar de todas las zonas. -message.action.delete.ISO=Por favor, confirme que desea eliminar la norma ISO -message.action.delete.network=Por favor, confirme que desea eliminar de la red -message.action.delete.pod=Por favor, confirme que desea eliminar de la vaina -message.action.delete.primary.storage=Por favor, confirme que desea eliminar el almacenamiento primario -message.action.delete.secondary.storage=Por favor, confirme que desea eliminar de almacenamiento secundario -message.action.delete.security.group=Por favor, confirme que desea eliminar el grupo de seguridad -message.action.delete.service.offering=Por favor, confirme que desea eliminar oferta de servicios +message.action.delete.ingress.rule=Por favor, confirme que desea eliminar la regla de ingreso +message.action.delete.ISO.for.all.zones=La ISO es utilizado por todas las zonas. Por favor, confirme que desea eliminar de todas las zonas. +message.action.delete.ISO=Por favor, confirme que desea eliminar la norma ISO +message.action.delete.network=Por favor, confirme que desea eliminar de la red +message.action.delete.pod=Por favor, confirme que desea eliminar de la vaina +message.action.delete.primary.storage=Por favor, confirme que desea eliminar el almacenamiento primario +message.action.delete.secondary.storage=Por favor, confirme que desea eliminar de almacenamiento secundario +message.action.delete.security.group=Por favor, confirme que desea eliminar el grupo de seguridad +message.action.delete.service.offering=Por favor, confirme que desea eliminar oferta de servicios message.action.delete.snapshot=Por favor, confirme que desea eliminar instant\u00c3\u00a1neas -message.action.delete.template.for.all.zones=La plantilla es utilizada por todas las zonas. Por favor, confirme que desea eliminar de todas las zonas. -message.action.delete.template=Por favor, confirme que desea eliminar la plantilla -message.action.delete.volume=Por favor, confirme que desea eliminar el volumen -message.action.delete.zone=Por favor, confirme que desea eliminar la zona -message.action.destroy.instance=Por favor, confirme que desea destruir ejemplo +message.action.delete.template.for.all.zones=La plantilla es utilizada por todas las zonas. Por favor, confirme que desea eliminar de todas las zonas. +message.action.delete.template=Por favor, confirme que desea eliminar la plantilla +message.action.delete.volume=Por favor, confirme que desea eliminar el volumen +message.action.delete.zone=Por favor, confirme que desea eliminar la zona +message.action.destroy.instance=Por favor, confirme que desea destruir ejemplo message.action.destroy.systemvm=Por favor, confirme que desea destruir la m\u00c3\u00a1quina virtual del sistema. message.action.disable.cluster=Por favor, confirme que desea desactivar este grupo. message.action.disable.pod=Por favor, confirme que desea desactivar esta vaina. -message.action.disable.static.NAT=Por favor, confirme que desea desactivar NAT est\u00c3\u00a1tica +message.action.disable.static.NAT=Por favor, confirme que desea desactivar NAT est\u00c3\u00a1tica message.action.disable.zone=Por favor, confirme que desea desactivar esta zona. message.action.enable.cluster=Por favor, confirme que desea habilitar este grupo. message.action.enable.maintenance=Su acogida ha sido preparado con \u00c3\u00a9xito para el mantenimiento. Este proceso puede tardar hasta varios minutos o m\u00c3\u00a1s dependiendo de c\u00c3\u00b3mo las m\u00c3\u00a1quinas virtuales se encuentran actualmente en este servidor. -message.action.enable.pod=Por favor, confirme que desea habilitar esta vaina. -message.action.enable.zone=Por favor, confirme que desea habilitar esta zona. -message.action.force.reconnect=Por favor, confirme que desea forzar una reconexi\u00c3\u00b3n para el anfitri\u00c3\u00b3n -message.action.host.enable.maintenance.mode=mode \= mantenimiento de Habilitaci\u00c3\u00b3n provocar\u00c3\u00a1 una migraci\u00c3\u00b3n en vivo de todas las instancias que se ejecutan en el sistema para cualquier m\u00c3\u00a1quina disponible. +message.action.enable.pod=Por favor, confirme que desea habilitar esta vaina. +message.action.enable.zone=Por favor, confirme que desea habilitar esta zona. +message.action.force.reconnect=Por favor, confirme que desea forzar una reconexi\u00c3\u00b3n para el anfitri\u00c3\u00b3n +message.action.host.enable.maintenance.mode=mode \= mantenimiento de Habilitaci\u00c3\u00b3n provocar\u00c3\u00a1 una migraci\u00c3\u00b3n en vivo de todas las instancias que se ejecutan en el sistema para cualquier m\u00c3\u00a1quina disponible. message.action.manage.cluster=Por favor, confirme que desea para administrar el cl\u00c3\u00baster. -message.action.primarystorage.enable.maintenance.mode=Advertencia\: colocar el almacenamiento principal en modo de mantenimiento har\u00c3\u00a1 que todas las m\u00c3\u00a1quinas virtuales utilizando vol\u00c3\u00bamenes de que sea detenido. \u00c2\u00bfDesea continuar? -message.action.reboot.instance=Por favor, confirme que desea reiniciar el ejemplo -message.action.reboot.systemvm=Por favor, confirme que desea reiniciar el sistema VM -message.action.release.ip=Por favor, confirme que desea liberar IP +message.action.primarystorage.enable.maintenance.mode=Advertencia\: colocar el almacenamiento principal en modo de mantenimiento har\u00c3\u00a1 que todas las m\u00c3\u00a1quinas virtuales utilizando vol\u00c3\u00bamenes de que sea detenido. \u00c2\u00bfDesea continuar? +message.action.reboot.instance=Por favor, confirme que desea reiniciar el ejemplo +message.action.reboot.systemvm=Por favor, confirme que desea reiniciar el sistema VM +message.action.release.ip=Por favor, confirme que desea liberar IP message.action.reset.password.off=Su ejemplo en la actualidad no es compatible con esta funci\u00c3\u00b3n. message.action.reset.password.warning=Su ejemplo debe ser detenido antes de intentar cambiar su contrase\u00c3\u00b1a actual. -message.action.restore.instance=Por favor, confirme que desea restaurar ejemplo -message.action.start.instance=Por favor, confirme que desea iniciar la instancia -message.action.start.router=Por favor, confirme que desea iniciar router -message.action.start.systemvm=Por favor, confirme que desea iniciar el sistema VM -message.action.stop.instance=Por favor, confirme que desea detener la instancia -message.action.stop.systemvm=Por favor, confirme que desea detener sistema VM -message.action.take.snapshot=Por favor, confirme que desea tomar instant\u00c3\u00a1neas +message.action.restore.instance=Por favor, confirme que desea restaurar ejemplo +message.action.start.instance=Por favor, confirme que desea iniciar la instancia +message.action.start.router=Por favor, confirme que desea iniciar router +message.action.start.systemvm=Por favor, confirme que desea iniciar el sistema VM +message.action.stop.instance=Por favor, confirme que desea detener la instancia +message.action.stop.systemvm=Por favor, confirme que desea detener sistema VM +message.action.take.snapshot=Por favor, confirme que desea tomar instant\u00c3\u00a1neas message.action.unmanage.cluster=Por favor, confirme que desea unmanage del cl\u00c3\u00baster. -message.add.cluster=A\u00c3\u00b1adir un hipervisor administradas por cl\u00c3\u00baster de zona , la consola de -message.add.cluster.zone=A\u00c3\u00b1adir un hipervisor administradas por cl\u00c3\u00baster de zona -message.add.disk.offering=Por favor, especifique los par\u00c3\u00a1metros siguientes para agregar un nuevo disco que ofrece -message.add.firewall=A\u00c3\u00b1adir un servidor de seguridad a la zona -message.add.host=Por favor, especifique los par\u00c3\u00a1metros siguientes para agregar un nuevo host -message.add.ip.range=A\u00c3\u00b1adir un rango de IP a la red p\u00c3\u00bablica en la zona -message.add.ip.range.direct.network=A\u00c3\u00b1adir un rango de IP para dirigir red en la zona -message.add.ip.range.to.pod=

A\u00c3\u00b1adir un rango de IP de la vaina\:

-message.additional.networks.desc=Por favor seleccione de red adicionales (s) que la instancia virtual estar\u00c3\u00a1 conectado. -message.add.load.balancer=A\u00c3\u00b1adir un equilibrador de carga a la zona -message.add.network=Agregar una nueva red para la zona\: -message.add.pod=Agregar una vaina nueva zona -message.add.primary=Por favor, especifique los par\u00c3\u00a1metros siguientes para agregar un nuevo almacenamiento primario -message.add.primary.storage=Agregar una nueva almacenamiento primario para zona , la consola de -message.add.secondary.storage=A\u00c3\u00b1adir un nuevo almacenamiento de zona -message.add.service.offering=Por favor, rellene los siguientes datos para agregar una nueva oferta de servicio. -message.add.template=Por favor ingrese los siguientes datos para crear la nueva plantilla -message.add.volume=Por favor, rellene los siguientes datos para agregar un nuevo volumen. -message.advanced.mode.desc=Seleccione este modelo de red si desea habilitar soporte VLAN. Este modelo de red proporciona la m\u00c3\u00a1xima flexibilidad al permitir a los administradores proporcionar ofertas personalizadas de la red como el suministro de firewall, VPN, o el apoyo equilibrador de carga, as\u00c3\u00ad como permitir vs directa de redes virtuales. +message.add.cluster=A\u00c3\u00b1adir un hipervisor administradas por cl\u00c3\u00baster de zona , la consola de +message.add.cluster.zone=A\u00c3\u00b1adir un hipervisor administradas por cl\u00c3\u00baster de zona +message.add.disk.offering=Por favor, especifique los par\u00c3\u00a1metros siguientes para agregar un nuevo disco que ofrece +message.add.firewall=A\u00c3\u00b1adir un servidor de seguridad a la zona +message.add.host=Por favor, especifique los par\u00c3\u00a1metros siguientes para agregar un nuevo host +message.add.ip.range=A\u00c3\u00b1adir un rango de IP a la red p\u00c3\u00bablica en la zona +message.add.ip.range.direct.network=A\u00c3\u00b1adir un rango de IP para dirigir red en la zona +message.add.ip.range.to.pod=

A\u00c3\u00b1adir un rango de IP de la vaina\:

+message.additional.networks.desc=Por favor seleccione de red adicionales (s) que la instancia virtual estar\u00c3\u00a1 conectado. +message.add.load.balancer=A\u00c3\u00b1adir un equilibrador de carga a la zona +message.add.network=Agregar una nueva red para la zona\: +message.add.pod=Agregar una vaina nueva zona +message.add.primary=Por favor, especifique los par\u00c3\u00a1metros siguientes para agregar un nuevo almacenamiento primario +message.add.primary.storage=Agregar una nueva almacenamiento primario para zona , la consola de +message.add.secondary.storage=A\u00c3\u00b1adir un nuevo almacenamiento de zona +message.add.service.offering=Por favor, rellene los siguientes datos para agregar una nueva oferta de servicio. +message.add.template=Por favor ingrese los siguientes datos para crear la nueva plantilla +message.add.volume=Por favor, rellene los siguientes datos para agregar un nuevo volumen. +message.advanced.mode.desc=Seleccione este modelo de red si desea habilitar soporte VLAN. Este modelo de red proporciona la m\u00c3\u00a1xima flexibilidad al permitir a los administradores proporcionar ofertas personalizadas de la red como el suministro de firewall, VPN, o el apoyo equilibrador de carga, as\u00c3\u00ad como permitir vs directa de redes virtuales. message.advanced.security.group=Elija esta opci\u00c3\u00b3n si desea utilizar grupos de seguridad para proporcionar resultados de aislamiento VM. message.advanced.virtual=Elija esta opci\u00c3\u00b3n si desea utilizar VLAN toda la zona para proporcionar el aislamiento VM invitado. -message.allow.vpn.access=Por favor, introduzca un nombre de usuario y la contrase\u00c3\u00b1a del usuario que desea permitir el acceso de VPN. +message.allow.vpn.access=Por favor, introduzca un nombre de usuario y la contrase\u00c3\u00b1a del usuario que desea permitir el acceso de VPN. message.apply.snapshot.policy=Ha actualizado su pol\u00c3\u00adtica instant\u00c3\u00a1nea actual. -message.attach.iso.confirm=Por favor, confirme que desea conectar el ISO a la instancia virtual -message.attach.volume=Por favor, rellene los siguientes datos para fijar un nuevo volumen. Si est\u00c3\u00a1 colocando un volumen de disco a una m\u00c3\u00a1quina virtual de Windows basado, usted tendr\u00c3\u00a1 que reiniciar la instancia para ver el disco adjunto. -message.basic.mode.desc=Seleccione este modelo de red si lo haces * no * desea habilitar cualquier soporte VLAN. Todas las instancias virtuales creados en virtud de este modelo de red se le asignar\u00c3\u00a1 una direcci\u00c3\u00b3n IP directamente desde la red y grupos de seguridad se utilizan para proporcionar la seguridad y la segregaci\u00c3\u00b3n. -message.change.offering.confirm=Por favor, confirme que desea cambiar la oferta de servicio de la instancia virtual. -message.copy.iso.confirm=Por favor, confirme que desea copiar el ISO a -message.copy.template=Copia plantilla XXX de la zona -message.create.template.vm=Crear VM de la plantilla -message.create.template.volume=Por favor, especifique la siguiente informaci\u00c3\u00b3n antes de crear una plantilla de su volumen de disco\: . Creaci\u00c3\u00b3n de la plantilla puede oscilar entre varios minutos m\u00c3\u00a1s, dependiendo del tama\u00c3\u00b1o del volumen. -message.delete.account=Por favor, confirme que desea eliminar esta cuenta. -message.detach.iso.confirm=Por favor, confirme que desea quitar el ISO de la instancia virtual +message.attach.iso.confirm=Por favor, confirme que desea conectar el ISO a la instancia virtual +message.attach.volume=Por favor, rellene los siguientes datos para fijar un nuevo volumen. Si est\u00c3\u00a1 colocando un volumen de disco a una m\u00c3\u00a1quina virtual de Windows basado, usted tendr\u00c3\u00a1 que reiniciar la instancia para ver el disco adjunto. +message.basic.mode.desc=Seleccione este modelo de red si lo haces * no * desea habilitar cualquier soporte VLAN. Todas las instancias virtuales creados en virtud de este modelo de red se le asignar\u00c3\u00a1 una direcci\u00c3\u00b3n IP directamente desde la red y grupos de seguridad se utilizan para proporcionar la seguridad y la segregaci\u00c3\u00b3n. +message.change.offering.confirm=Por favor, confirme que desea cambiar la oferta de servicio de la instancia virtual. +message.copy.iso.confirm=Por favor, confirme que desea copiar el ISO a +message.copy.template=Copia plantilla XXX de la zona +message.create.template.vm=Crear VM de la plantilla +message.create.template.volume=Por favor, especifique la siguiente informaci\u00c3\u00b3n antes de crear una plantilla de su volumen de disco\: . Creaci\u00c3\u00b3n de la plantilla puede oscilar entre varios minutos m\u00c3\u00a1s, dependiendo del tama\u00c3\u00b1o del volumen. +message.delete.account=Por favor, confirme que desea eliminar esta cuenta. +message.detach.iso.confirm=Por favor, confirme que desea quitar el ISO de la instancia virtual message.disable.snapshot.policy=Ha desactivado su pol\u00c3\u00adtica instant\u00c3\u00a1nea actual. message.disable.vpn.access=Por favor, confirme que desea desactivar VPN de acceso. message.download.volume=Por favor, haga clic 00000 para bajar el volumen -message.edit.confirm=Por favor confirmar los cambios antes de hacer clic en "Guardar" -message.edit.limits=Por favor, especifique los l\u00c3\u00admites de los recursos siguientes. A "-1" indica que no hay l\u00c3\u00admite a la cantidad de los recursos de crear. -message.enable.account=Por favor, confirme que desea habilitar esta cuenta. -message.enabled.vpn.ip.sec=La clave pre-compartida IPSec es -message.enabled.vpn=Su acceso a la VPN est\u00c3\u00a1 habilitado y se puede acceder a trav\u00c3\u00a9s de la IP -message.enable.vpn.access=VPN \= est\u00c3\u00a1 desactivado para esta direcci\u00c3\u00b3n IP. \u00c2\u00bfTe gustar\u00c3\u00ada que permitan el acceso VPN? -message.enable.vpn=VPN de acceso actualmente no est\u00c3\u00a1 habilitado. Por favor, haga clic aqu\u00c3\u00ad para habilitar VPN. +message.edit.confirm=Por favor confirmar los cambios antes de hacer clic en "Guardar" +message.edit.limits=Por favor, especifique los l\u00c3\u00admites de los recursos siguientes. A "-1" indica que no hay l\u00c3\u00admite a la cantidad de los recursos de crear. +message.enable.account=Por favor, confirme que desea habilitar esta cuenta. +message.enabled.vpn.ip.sec=La clave pre-compartida IPSec es +message.enabled.vpn=Su acceso a la VPN est\u00c3\u00a1 habilitado y se puede acceder a trav\u00c3\u00a9s de la IP +message.enable.vpn.access=VPN \= est\u00c3\u00a1 desactivado para esta direcci\u00c3\u00b3n IP. \u00c2\u00bfTe gustar\u00c3\u00ada que permitan el acceso VPN? +message.enable.vpn=VPN de acceso actualmente no est\u00c3\u00a1 habilitado. Por favor, haga clic aqu\u00c3\u00ad para habilitar VPN. message.installWizard.click.retry=Haz click en el bot\u00f3n para re-intentar el lanzamiento de la instancia. -message.installWizard.tooltip.addCluster.name=Nombre del Cluster. Puede ser alfanum\u00e9rico .Este no es usado por CloudStack +message.installWizard.tooltip.addCluster.name=Nombre del Cluster. Puede ser alfanum\u00e9rico .Este no es usado por CloudStack message.installWizard.tooltip.addHost.hostname=El nombre DNS o direcci\u00f3n IP del host message.installWizard.tooltip.addHost.username=Generalmente root message.installWizard.tooltip.addPod.name=Nombre del POD @@ -818,44 +819,44 @@ message.installWizard.tooltip.addPrimaryStorage.name=\ Nombre para el storage message.installWizard.tooltip.addSecondaryStorage.nfsServer=Direcci\u00f3n IP del servidor NFS que contiene el secondary storage message.installWizard.tooltip.addZone.name=Nombre de la zona. message.installWizard.tooltip.configureGuestTraffic.description=Una breve descripci\u00f3n para su red. -message.installWizard.tooltip.configureGuestTraffic.guestGateway=El gatway, puerta de enlace, que las maquinas guest deben usar. -message.installWizard.tooltip.configureGuestTraffic.name=Nombre de su RED -message.lock.account=Por favor, confirme que desea bloquear esta cuenta. Al bloquear la cuenta, todos los usuarios de esta cuenta ya no ser\u00c3\u00a1 capaz de gestionar sus recursos de la nube. Los recursos existentes todav\u00c3\u00ada se puede acceder. +message.installWizard.tooltip.configureGuestTraffic.guestGateway=El gatway, puerta de enlace, que las maquinas guest deben usar. +message.installWizard.tooltip.configureGuestTraffic.name=Nombre de su RED +message.lock.account=Por favor, confirme que desea bloquear esta cuenta. Al bloquear la cuenta, todos los usuarios de esta cuenta ya no ser\u00c3\u00a1 capaz de gestionar sus recursos de la nube. Los recursos existentes todav\u00c3\u00ada se puede acceder. message.migrate.instance.confirm=Por favor, confirme el anfitri\u00c3\u00b3n desea migrar la instancia virtual. message.migrate.instance.to.host=Por favor, confirmar que desea mover la instancia a otro host. message.migrate.instance.to.ps=Por favor, confirmar que desea mover la instancia a otro primary storage. message.migrate.router.confirm=Por favor, confirme el hu\u00c3\u00a9sped que desea migrar el router\: message.migrate.systemvm.confirm=Por favor, confirme el hu\u00c3\u00a9sped que desea migrar la m\u00c3\u00a1quina virtual de sistema\: message.no.network.support.configuration.not.true=Usted no tiene ninguna zona que ha permitido a grupo de seguridad. Por lo tanto, no hay funciones de red adicionales. Por favor, contin\u00c3\u00bae con el paso 5. -message.no.network.support=El hipervisor seleccionado, vSphere, no tiene funciones de red adicionales. Por favor, contin\u00c3\u00bae con el paso 5. -message.number.clusters=

\# de Grupos

-message.number.hosts=

\# de Anfitri\u00c3\u00b3n

-message.number.pods=

\# de Las vainas

-message.number.storage=

\# de Almacenamiento primario

-message.number.zones=

\# de Zonas

-message.remove.vpn.access=Por favor, confirme que desea eliminar el acceso VPN desde el siguiente usuario -message.restart.mgmt.server=Por favor, reinicie el servidor de administraci\u00c3\u00b3n (s) para la nueva configuraci\u00c3\u00b3n surta efecto. -message.security.group.usage=(Uso pulse Ctrl para seleccionar todos los grupos de seguridad se aplica) -message.select.item=Por favor, seleccionar un item . +message.no.network.support=El hipervisor seleccionado, vSphere, no tiene funciones de red adicionales. Por favor, contin\u00c3\u00bae con el paso 5. +message.number.clusters=

\# de Grupos

+message.number.hosts=

\# de Anfitri\u00c3\u00b3n

+message.number.pods=

\# de Las vainas

+message.number.storage=

\# de Almacenamiento primario

+message.number.zones=

\# de Zonas

+message.remove.vpn.access=Por favor, confirme que desea eliminar el acceso VPN desde el siguiente usuario +message.restart.mgmt.server=Por favor, reinicie el servidor de administraci\u00c3\u00b3n (s) para la nueva configuraci\u00c3\u00b3n surta efecto. +message.security.group.usage=(Uso pulse Ctrl para seleccionar todos los grupos de seguridad se aplica) +message.select.item=Por favor, seleccionar un item . message.setup.successful=La configuraci\u00f3n de la cloud finalizo satisfactoriamente. -message.snapshot.schedule=Puede horarios de configuraci\u00c3\u00b3n recurrente instant\u00c3\u00a1neas mediante la selecci\u00c3\u00b3n de las opciones disponibles a continuaci\u00c3\u00b3n y la aplicaci\u00c3\u00b3n de su preferencia pol\u00c3\u00adtica -message.step.1.continue=Por favor seleccione una plantilla o ISO para continuar -message.step.1.desc=Por favor seleccione una plantilla para la instancia virtual. Tambi\u00c3\u00a9n puede optar por seleccionar una plantilla en blanco desde el que puede ser una imagen ISO instalado en. -message.step.2.continue=Por favor seleccione una oferta de servicio para continuar +message.snapshot.schedule=Puede horarios de configuraci\u00c3\u00b3n recurrente instant\u00c3\u00a1neas mediante la selecci\u00c3\u00b3n de las opciones disponibles a continuaci\u00c3\u00b3n y la aplicaci\u00c3\u00b3n de su preferencia pol\u00c3\u00adtica +message.step.1.continue=Por favor seleccione una plantilla o ISO para continuar +message.step.1.desc=Por favor seleccione una plantilla para la instancia virtual. Tambi\u00c3\u00a9n puede optar por seleccionar una plantilla en blanco desde el que puede ser una imagen ISO instalado en. +message.step.2.continue=Por favor seleccione una oferta de servicio para continuar message.step.2.desc= -message.step.3.continue=Por favor seleccione una oferta en disco para continuar +message.step.3.continue=Por favor seleccione una oferta en disco para continuar message.step.3.desc= message.step.4.continue=Por favor seleccione al menos una red social para continuar -message.step.4.desc=Por favor, seleccione la red primaria que la instancia virtual estar\u00c3\u00a1 conectado. -message.update.os.preference=Por favor seleccione un sistema operativo de preferencia para este equipo. Todas las instancias virtuales con preferencias similares ser\u00c3\u00a1n los primeros asignados a este equipo antes de elegir otro. -message.update.ssl=Por favor, env\u00c3\u00ade una nueva X.509 compatible con certificado SSL que se actualizar\u00c3\u00a1 a cada instancia virtual de la consola del servidor proxy\: -message.virtual.network.desc=Una red dedicada virtualizados para su cuenta. El dominio de difusi\u00c3\u00b3n est\u00c3\u00a1 contenida dentro de una VLAN y todos los acceso a la red p\u00c3\u00bablica se encamina a cabo por un router virtual. +message.step.4.desc=Por favor, seleccione la red primaria que la instancia virtual estar\u00c3\u00a1 conectado. +message.update.os.preference=Por favor seleccione un sistema operativo de preferencia para este equipo. Todas las instancias virtuales con preferencias similares ser\u00c3\u00a1n los primeros asignados a este equipo antes de elegir otro. +message.update.ssl=Por favor, env\u00c3\u00ade una nueva X.509 compatible con certificado SSL que se actualizar\u00c3\u00a1 a cada instancia virtual de la consola del servidor proxy\: +message.virtual.network.desc=Una red dedicada virtualizados para su cuenta. El dominio de difusi\u00c3\u00b3n est\u00c3\u00a1 contenida dentro de una VLAN y todos los acceso a la red p\u00c3\u00bablica se encamina a cabo por un router virtual. message.vm.create.template.confirm=Crear plantilla de la m\u00c3\u00a1quina virtual se reiniciar\u00c3\u00a1 autom\u00c3\u00a1ticamente. -message.volume.create.template.confirm=Por favor, confirme que desea crear una plantilla para este volumen de disco. Creaci\u00c3\u00b3n de la plantilla puede oscilar entre varios minutos m\u00c3\u00a1s, dependiendo del tama\u00c3\u00b1o del volumen. -message.zone.step.1.desc=Por favor seleccione un modelo de red para su zona. +message.volume.create.template.confirm=Por favor, confirme que desea crear una plantilla para este volumen de disco. Creaci\u00c3\u00b3n de la plantilla puede oscilar entre varios minutos m\u00c3\u00a1s, dependiendo del tama\u00c3\u00b1o del volumen. +message.zone.step.1.desc=Por favor seleccione un modelo de red para su zona. mode=modo -network.rate=Tasa de Red +network.rate=Tasa de Red side.by.side=Juntos -state.Allocated=Asignados -state.Disabled=personas de movilidad reducida -state.Error=Error +state.Allocated=Asignados +state.Disabled=personas de movilidad reducida +state.Error=Error diff --git a/client/WEB-INF/classes/resources/messages_fr_FR.properties b/client/WEB-INF/classes/resources/messages_fr_FR.properties index 6a7cc9a9d55..8be438a11c1 100644 --- a/client/WEB-INF/classes/resources/messages_fr_FR.properties +++ b/client/WEB-INF/classes/resources/messages_fr_FR.properties @@ -15,78 +15,46 @@ # specific language governing permissions and limitations # under the License. -#Stored by I18NEdit, may be edited! -ICMP.code=Code ICMP -ICMP.type=Type ICMP -changed.item.properties=Propri\u00E9t\u00E9s de l\\'\u00E9l\u00E9ment modifi\u00E9es + +changed.item.properties=Propri\u00e9t\u00e9s de l\\'\u00e9l\u00e9ment modifi\u00e9es confirm.enable.s3=Remplir les informations suivantes pour activer le support de stockage secondaire S3 confirm.enable.swift=Remplir les informations suivantes pour activer Swift error.could.not.enable.zone=Impossible d\\'activer la zone -error.installWizard.message=Une erreur s\\'est produite ; vous pouvez retourner en arri\u00E8re et corriger les erreurs +error.installWizard.message=Une erreur s\\'est produite ; vous pouvez retourner en arri\u00e8re et corriger les erreurs error.invalid.username.password=Utilisateur ou mot de passe invalide -error.login=Votre nom d\\'utilisateur / mot de passe ne correspond pas \u00E0 nos donn\u00E9es. -error.menu.select=\u00C9chec de l\\'action car il n\\'y a aucun \u00E9l\u00E9ment s\u00E9lectionn\u00E9. +error.login=Votre nom d\\'utilisateur / mot de passe ne correspond pas \u00e0 nos donn\u00e9es. +error.menu.select=\u00c9chec de l\\'action car il n\\'y a aucun \u00e9l\u00e9ment s\u00e9lectionn\u00e9. error.mgmt.server.inaccessible=Le serveur de gestion est indisponible. Essayez plus tard. error.password.not.match=Les mots de passe ne correspondent pas -error.please.specify.physical.network.tags=L\\'offre r\u00E9seau ne sera pas disponible tant que des libell\u00E9s n\\'auront pas \u00E9t\u00E9 renseign\u00E9s pour ce r\u00E9seau physique. -error.session.expired=Votre session a expir\u00E9e. +error.please.specify.physical.network.tags=L\\'offre r\u00e9seau ne sera pas disponible tant que des libell\u00e9s n\\'auront pas \u00e9t\u00e9 renseign\u00e9s pour ce r\u00e9seau physique. +error.session.expired=Votre session a expir\u00e9e. error.something.went.wrong.please.correct.the.following=Erreur; corriger le point suivant error.unable.to.reach.management.server=Impossible de joindre le serveur d\\'administration -error.unresolved.internet.name=Votre nom Internet ne peut pas \u00EAtre r\u00E9solu. -extractable=D\u00E9compressable +error.unresolved.internet.name=Votre nom Internet ne peut pas \u00eatre r\u00e9solu. +extractable=D\u00e9compressable +force.delete.domain.warning=Attention \: Choisir cette option entra\u00eenera la suppression de tous les domaines issus et l\\'ensemble des comptes associ\u00e9s, ainsi que de leur ressources force.delete=Forcer la suppression -force.delete.domain.warning=Attention \: Choisir cette option entra\u00EEnera la suppression de tous les domaines issus et l\\'ensemble des comptes associ\u00E9s, ainsi que de leur ressources force.remove=Forcer la suppression -force.remove.host.warning=Attention \: Choisir cette option entra\u00EEnera CloudStack \u00E0\u00A0arr\u00EAter l\\'ensemble des machines virtuelles avant d\\'enlever l\\'h\u00F4te du cluster -force.stop=Forcer l\\'arr\u00EAt -force.stop.instance.warning=Attention \: un arr\u00EAt forc\u00E9 sur cette instance est la dernier option. Cela peut engendrer des pertes de donn\u00E9es et/ou un comportement inconsistant de votre instance. -image.directory=R\u00E9pertoire d\\'images -inline=Align\u00E9 -instances.actions.reboot.label=Red\u00E9marrer l\\'instance -label.CIDR.list=Liste CIDR -label.CIDR.of.destination.network=CIDR du r\u00E9seau de destination -label.CPU.cap=Limitation CPU -label.DHCP.server.type=Serveur DHCP -label.DNS.domain.for.guest.networks=Domaine DNS pour les r\u00E9seaux invit\u00E9s -label.ESP.encryption=Chiffrement ESP -label.ESP.hash=Empreinte ESP -label.ESP.lifetime=Dur\u00E9e de vie ESP (secondes) -label.ESP.policy=Mode ESP -label.IKE.DH=DH IKE -label.IKE.encryption=Chiffrement IKE -label.IKE.hash=Empreinte IKE -label.IKE.lifetime=Dur\u00E9e de vie IKE (secondes) -label.IKE.policy=Mode IKE -label.IPsec.preshared.key=Cl\u00E9 partag\u00E9e IPsec -label.LB.isolation=R\u00E9partition de charge isol\u00E9e -label.LUN.number=N\u00B0 LUN -label.PING.CIFS.password=Mot de passe CIFS PING -label.PING.CIFS.username=Identifiant CIFS PING -label.PING.dir=R\u00E9pertoire PING -label.PING.storage.IP=IP stockage PING -label.PreSetup=PreSetup -label.Pxe.server.type=Serveur PXE -label.SR.name=Nom du point de montage -label.SharedMountPoint=Point de montage partag\u00E9 -label.TFTP.dir=R\u00E9pertoire TFTP -label.VMFS.datastore=Magasin de donn\u00E9es VMFS -label.VMs.in.tier=Machines virtuelles dans le tiers -label.VPC.router.details=D\u00E9tails routeur VPC -label.VPN.connection=Connexion VPN -label.VPN.customer.gateway=Passerelle VPN client -label.VPN.gateway=Passerelle VPN +force.remove.host.warning=Attention \: Choisir cette option entra\u00eenera CloudStack \u00e0\u00a0arr\u00eater l\\'ensemble des machines virtuelles avant d\\'enlever l\\'h\u00f4te du cluster +force.stop=Forcer l\\'arr\u00eat +force.stop.instance.warning=Attention \: un arr\u00eat forc\u00e9 sur cette instance est la dernier option. Cela peut engendrer des pertes de donn\u00e9es et/ou un comportement inconsistant de votre instance. +ICMP.code=Code ICMP +ICMP.type=Type ICMP +image.directory=R\u00e9pertoire d\\'images +inline=Align\u00e9 +instances.actions.reboot.label=Red\u00e9marrer l\\'instance label.accept.project.invitation=Accepter l\\'invitation au projet +label.account.and.security.group=Compte, groupe de s\u00e9curit\u00e9 label.account=Compte -label.account.and.security.group=Compte, groupe de s\u00E9curit\u00E9 label.account.id=ID du Compte label.account.name=Nom du compte -label.account.specific=Sp\u00E9cifique au compte label.accounts=Comptes -label.acquire.new.ip=Acqu\u00E9rir une nouvelle adresse IP -label.action.attach.disk=Rattacher un disque +label.account.specific=Sp\u00e9cifique au compte +label.acquire.new.ip=Acqu\u00e9rir une nouvelle adresse IP label.action.attach.disk.processing=Rattachement du Disque... -label.action.attach.iso=Rattacher une image ISO +label.action.attach.disk=Rattacher un disque label.action.attach.iso.processing=Rattachement de l\\'image ISO +label.action.attach.iso=Rattacher une image ISO label.action.cancel.maintenance.mode=Annuler le mode maintenance label.action.cancel.maintenance.mode.processing=Annulation du mode maintenance... label.action.change.password=Changer le mot de passe @@ -94,100 +62,100 @@ label.action.change.service=Changer d\\'offre de service label.action.change.service.processing=Changement de d\\'offre de service... label.action.copy.ISO=Copier une image ISO label.action.copy.ISO.processing=Copie de l\\'image ISO... -label.action.copy.template=Copier un mod\u00E8le -label.action.copy.template.processing=Copie du Mod\u00E8le... -label.action.create.template=Cr\u00E9er un mod\u00E8le -label.action.create.template.from.vm=Cr\u00E9er un mod\u00E8le depuis la VM -label.action.create.template.from.volume=Cr\u00E9er un mod\u00E8le depuis le volume -label.action.create.template.processing=Cr\u00E9ation du Mod\u00E8le... -label.action.create.vm=Cr\u00E9er une VM -label.action.create.vm.processing=Cr\u00E9ation de la VM... -label.action.create.volume=Cr\u00E9er un Volume -label.action.create.volume.processing=Cr\u00E9ation du Volume... -label.action.delete.IP.range=Supprimer la plage IP -label.action.delete.IP.range.processing=Suppression de la plage IP... -label.action.delete.ISO=Supprimer l\\'image ISO -label.action.delete.ISO.processing=Suppression de l\\'image ISO... -label.action.delete.account=Supprimer un compte +label.action.copy.template=Copier un mod\u00e8le +label.action.copy.template.processing=Copie du Mod\u00e8le... +label.action.create.template=Cr\u00e9er un mod\u00e8le +label.action.create.template.from.vm=Cr\u00e9er un mod\u00e8le depuis la VM +label.action.create.template.from.volume=Cr\u00e9er un mod\u00e8le depuis le volume +label.action.create.template.processing=Cr\u00e9ation du Mod\u00e8le... +label.action.create.vm=Cr\u00e9er une VM +label.action.create.vm.processing=Cr\u00e9ation de la VM... +label.action.create.volume=Cr\u00e9er un Volume +label.action.create.volume.processing=Cr\u00e9ation du Volume... label.action.delete.account.processing=Suppression du compte... -label.action.delete.cluster=Supprimer le Cluster +label.action.delete.account=Supprimer un compte label.action.delete.cluster.processing=Suppression du Cluster... -label.action.delete.disk.offering=Supprimer l\\'offre Disque +label.action.delete.cluster=Supprimer le Cluster label.action.delete.disk.offering.processing=Suppression de l\\'offre Disque... -label.action.delete.domain=Supprimer le domaine +label.action.delete.disk.offering=Supprimer l\\'offre Disque label.action.delete.domain.processing=Suppression du domaine... -label.action.delete.firewall=Supprimer la r\u00E8gle de pare-feu +label.action.delete.domain=Supprimer le domaine label.action.delete.firewall.processing=Suppression du Pare-feu... -label.action.delete.ingress.rule=Supprimer la r\u00E8gle d\\'entr\u00E9e -label.action.delete.ingress.rule.processing=Suppression de la r\u00E8gle d\\'entr\u00E9e.. -label.action.delete.load.balancer=Supprimer la r\u00E8gle de r\u00E9partition de charge -label.action.delete.load.balancer.processing=Suppression du r\u00E9partiteur de charge... -label.action.delete.network=Supprimer le r\u00E9seau -label.action.delete.network.processing=Suppression du r\u00E9seau... +label.action.delete.firewall=Supprimer la r\u00e8gle de pare-feu +label.action.delete.ingress.rule.processing=Suppression de la r\u00e8gle d\\'entr\u00e9e.. +label.action.delete.ingress.rule=Supprimer la r\u00e8gle d\\'entr\u00e9e +label.action.delete.IP.range.processing=Suppression de la plage IP... +label.action.delete.IP.range=Supprimer la plage IP +label.action.delete.ISO.processing=Suppression de l\\'image ISO... +label.action.delete.ISO=Supprimer l\\'image ISO +label.action.delete.load.balancer.processing=Suppression du r\u00e9partiteur de charge... +label.action.delete.load.balancer=Supprimer la r\u00e8gle de r\u00e9partition de charge +label.action.delete.network.processing=Suppression du r\u00e9seau... +label.action.delete.network=Supprimer le r\u00e9seau label.action.delete.nexusVswitch=Supprimer le Nexus 1000v -label.action.delete.physical.network=Supprimer le r\u00E9seau physique -label.action.delete.pod=Supprimer le Pod +label.action.delete.physical.network=Supprimer le r\u00e9seau physique label.action.delete.pod.processing=Suppression du pod... -label.action.delete.primary.storage=Supprimer le stockage principal +label.action.delete.pod=Supprimer le Pod label.action.delete.primary.storage.processing=Suppression du stockage principal... -label.action.delete.secondary.storage=Supprimer le stockage secondaire +label.action.delete.primary.storage=Supprimer le stockage principal label.action.delete.secondary.storage.processing=Suppression du stockage secondaire... -label.action.delete.security.group=Supprimer le groupe de s\u00E9curit\u00E9 -label.action.delete.security.group.processing=Suppression du groupe de s\u00E9curit\u00E9 -label.action.delete.service.offering=Supprimer l\\'offre de service +label.action.delete.secondary.storage=Supprimer le stockage secondaire +label.action.delete.security.group.processing=Suppression du groupe de s\u00e9curit\u00e9 +label.action.delete.security.group=Supprimer le groupe de s\u00e9curit\u00e9 label.action.delete.service.offering.processing=Suppression de l\\'offre de service... -label.action.delete.snapshot=Supprimer l\\'instantan\u00E9 -label.action.delete.snapshot.processing=Suppression de l\\'instantan\u00E9... -label.action.delete.system.service.offering=Supprimer l\\'offre syst\u00E8me -label.action.delete.template=Supprimer le mod\u00E8le -label.action.delete.template.processing=Suppression du mod\u00E8le... -label.action.delete.user=Supprimer l\\'utilisateur +label.action.delete.service.offering=Supprimer l\\'offre de service +label.action.delete.snapshot.processing=Suppression de l\\'instantan\u00e9... +label.action.delete.snapshot=Supprimer l\\'instantan\u00e9 +label.action.delete.system.service.offering=Supprimer l\\'offre syst\u00e8me +label.action.delete.template.processing=Suppression du mod\u00e8le... +label.action.delete.template=Supprimer le mod\u00e8le label.action.delete.user.processing=Suppression de l\\'utilisateur... -label.action.delete.volume=Supprimer le volume +label.action.delete.user=Supprimer l\\'utilisateur label.action.delete.volume.processing=Suppression du volume... -label.action.delete.zone=Supprimer la zone +label.action.delete.volume=Supprimer le volume label.action.delete.zone.processing=Suppression de la zone... -label.action.destroy.instance=Supprimer l\\'instance +label.action.delete.zone=Supprimer la zone label.action.destroy.instance.processing=Suppression de l\\'instance... -label.action.destroy.systemvm=Supprimer la VM Syst\u00E8me -label.action.destroy.systemvm.processing=Suppression de la VM Syst\u00E8me... -label.action.detach.disk=D\u00E9tacher le disque -label.action.detach.disk.processing=D\u00E9tachement du disque... -label.action.detach.iso=D\u00E9tacher l\\'image ISO -label.action.detach.iso.processing=D\u00E9tachement de l\\'image ISO... -label.action.disable.account=D\u00E9sactiver le compte -label.action.disable.account.processing=D\u00E9sactivation du compte... -label.action.disable.cluster=D\u00E9sactiver le cluster -label.action.disable.cluster.processing=D\u00E9sactivation du cluster... -label.action.disable.nexusVswitch=D\u00E9sactiver le Nexus 1000v -label.action.disable.physical.network=D\u00E9sactiver le r\u00E9seau physique -label.action.disable.pod=D\u00E9sactiver le Pod -label.action.disable.pod.processing=D\u00E9sactivation du Pod... -label.action.disable.static.NAT=D\u00E9sactiver le NAT Statique -label.action.disable.static.NAT.processing=D\u00E9sactivation du NAT Statique... -label.action.disable.user=D\u00E9sactiver l\\'utilisateur -label.action.disable.user.processing=D\u00E9sactivation de l\\'utilisateur... -label.action.disable.zone=D\u00E9sactivation de la zone -label.action.disable.zone.processing=D\u00E9sactivation de la zone... -label.action.download.ISO=T\u00E9l\u00E9charger une image ISO -label.action.download.template=T\u00E9l\u00E9charger un mod\u00E8le -label.action.download.volume=T\u00E9l\u00E9charger un volume -label.action.download.volume.processing=T\u00E9l\u00E9chargement du volume... -label.action.edit.ISO=Modifier l\\'image ISO +label.action.destroy.instance=Supprimer l\\'instance +label.action.destroy.systemvm.processing=Suppression de la VM Syst\u00e8me... +label.action.destroy.systemvm=Supprimer la VM Syst\u00e8me +label.action.detach.disk=D\u00e9tacher le disque +label.action.detach.disk.processing=D\u00e9tachement du disque... +label.action.detach.iso=D\u00e9tacher l\\'image ISO +label.action.detach.iso.processing=D\u00e9tachement de l\\'image ISO... +label.action.disable.account=D\u00e9sactiver le compte +label.action.disable.account.processing=D\u00e9sactivation du compte... +label.action.disable.cluster=D\u00e9sactiver le cluster +label.action.disable.cluster.processing=D\u00e9sactivation du cluster... +label.action.disable.nexusVswitch=D\u00e9sactiver le Nexus 1000v +label.action.disable.physical.network=D\u00e9sactiver le r\u00e9seau physique +label.action.disable.pod=D\u00e9sactiver le Pod +label.action.disable.pod.processing=D\u00e9sactivation du Pod... +label.action.disable.static.NAT=D\u00e9sactiver le NAT Statique +label.action.disable.static.NAT.processing=D\u00e9sactivation du NAT Statique... +label.action.disable.user=D\u00e9sactiver l\\'utilisateur +label.action.disable.user.processing=D\u00e9sactivation de l\\'utilisateur... +label.action.disable.zone=D\u00e9sactivation de la zone +label.action.disable.zone.processing=D\u00e9sactivation de la zone... +label.action.download.ISO=T\u00e9l\u00e9charger une image ISO +label.action.download.template=T\u00e9l\u00e9charger un mod\u00e8le +label.action.download.volume.processing=T\u00e9l\u00e9chargement du volume... +label.action.download.volume=T\u00e9l\u00e9charger un volume label.action.edit.account=Modifier le Compte label.action.edit.disk.offering=Modifier l\\'offre de disque label.action.edit.domain=Modifier le domaine label.action.edit.global.setting=Modifier la configuration globale -label.action.edit.host=Modifier l\\'h\u00F4te +label.action.edit.host=Modifier l\\'h\u00f4te label.action.edit.instance=Modifier l\\'instance -label.action.edit.network=Modifier le r\u00E9seau -label.action.edit.network.offering=Modifier l\\'offre de service r\u00E9seau -label.action.edit.network.processing=Modification du R\u00E9seau... +label.action.edit.ISO=Modifier l\\'image ISO +label.action.edit.network=Modifier le r\u00e9seau +label.action.edit.network.offering=Modifier l\\'offre de service r\u00e9seau +label.action.edit.network.processing=Modification du R\u00e9seau... label.action.edit.pod=Modifier le pod label.action.edit.primary.storage=Modifier le stockage principal label.action.edit.resource.limits=Modifier les limites de ressources label.action.edit.service.offering=Modifier l\\'offre de service -label.action.edit.template=Modifier le mod\u00E8le +label.action.edit.template=Modifier le mod\u00e8le label.action.edit.user=Modifier l\\'utilisateur label.action.edit.zone=Modifier la zone label.action.enable.account=Activer le compte @@ -197,7 +165,7 @@ label.action.enable.cluster.processing=Activation du cluster... label.action.enable.maintenance.mode=Activer le mode maintenance label.action.enable.maintenance.mode.processing=Activation du mode maintenance... label.action.enable.nexusVswitch=Activer le Nexus 1000v -label.action.enable.physical.network=Activer le r\u00E9seau physique +label.action.enable.physical.network=Activer le r\u00e9seau physique label.action.enable.pod=Activer le Pod label.action.enable.pod.processing=Activation du Pod... label.action.enable.static.NAT=Activer le NAT Statique @@ -208,74 +176,74 @@ label.action.enable.zone=Activer la zone label.action.enable.zone.processing=Activation de la zone... label.action.force.reconnect=Forcer la reconnexion label.action.force.reconnect.processing=Reconnexion en cours... -label.action.generate.keys=G\u00E9n\u00E9rer les cl\u00E9s -label.action.generate.keys.processing=G\u00E9n\u00E9ration des cl\u00E9s... +label.action.generate.keys=G\u00e9n\u00e9rer les cl\u00e9s +label.action.generate.keys.processing=G\u00e9n\u00e9ration des cl\u00e9s... label.action.list.nexusVswitch=Liste des Nexus 1000v -label.action.lock.account=Verrouiller le compte label.action.lock.account.processing=Verrouillage du compte... -label.action.manage.cluster=G\u00E9rer le Cluster +label.action.lock.account=Verrouiller le compte +label.action.manage.cluster=G\u00e9rer le Cluster label.action.manage.cluster.processing=Gestion du cluster... label.action.migrate.instance=Migrer l\\'instance label.action.migrate.instance.processing=Migration de l\\'instance... label.action.migrate.router=Migration routeur label.action.migrate.router.processing=Migration routeur en cours... -label.action.migrate.systemvm=Migration VM syst\u00E8me -label.action.migrate.systemvm.processing=Migration VM syst\u00E8me en cours ... -label.action.reboot.instance=Red\u00E9marrer l\\'instance -label.action.reboot.instance.processing=Red\u00E9marrage de l\\'instance... -label.action.reboot.router=Red\u00E9marrer le routeur -label.action.reboot.router.processing=Red\u00E9marrage du routeur... -label.action.reboot.systemvm=Red\u00E9marrer la VM Syst\u00E8me -label.action.reboot.systemvm.processing=Red\u00E9marrage de la VM Syst\u00E8me... -label.action.recurring.snapshot=Instantan\u00E9s r\u00E9currents +label.action.migrate.systemvm=Migration VM syst\u00e8me +label.action.migrate.systemvm.processing=Migration VM syst\u00e8me en cours ... +label.action.reboot.instance.processing=Red\u00e9marrage de l\\'instance... +label.action.reboot.instance=Red\u00e9marrer l\\'instance +label.action.reboot.router.processing=Red\u00e9marrage du routeur... +label.action.reboot.router=Red\u00e9marrer le routeur +label.action.reboot.systemvm.processing=Red\u00e9marrage de la VM Syst\u00e8me... +label.action.reboot.systemvm=Red\u00e9marrer la VM Syst\u00e8me +label.action.recurring.snapshot=Instantan\u00e9s r\u00e9currents label.action.register.iso=Enregistrer ISO -label.action.register.template=Enregistrer mod\u00E8le -label.action.release.ip=Lib\u00E9rer l\\'adresse IP -label.action.release.ip.processing=Lib\u00E9ration de l\\'adresse IP... -label.action.remove.host=Supprimer l\\'h\u00F4te -label.action.remove.host.processing=Suppression de l\\'h\u00F4te... -label.action.reset.password=R\u00E9-initialiser le mot de passe -label.action.reset.password.processing=R\u00E9-initialisation du mot de passe... -label.action.resize.volume=Redimensionner Volume +label.action.register.template=Enregistrer mod\u00e8le +label.action.release.ip=Lib\u00e9rer l\\'adresse IP +label.action.release.ip.processing=Lib\u00e9ration de l\\'adresse IP... +label.action.remove.host.processing=Suppression de l\\'h\u00f4te... +label.action.remove.host=Supprimer l\\'h\u00f4te +label.action.reset.password.processing=R\u00e9-initialisation du mot de passe... +label.action.reset.password=R\u00e9-initialiser le mot de passe label.action.resize.volume.processing=Redimensionnement en cours... +label.action.resize.volume=Redimensionner Volume label.action.resource.limits=Limites de ressources -label.action.restore.instance=Restaurer l\\'instance label.action.restore.instance.processing=Restauration de l\\'instance... -label.action.start.instance=D\u00E9marrer l\\'instance -label.action.start.instance.processing=D\u00E9marrage de l\\'instance... -label.action.start.router=D\u00E9marrer le routeur -label.action.start.router.processing=D\u00E9marrage du routeur... -label.action.start.systemvm=D\u00E9marrer la VM syst\u00E8me -label.action.start.systemvm.processing=D\u00E9marrage de la VM syst\u00E8me... -label.action.stop.instance=Arr\u00EAter l\\'Instance -label.action.stop.instance.processing=Arr\u00EAt de l\\'Instance... -label.action.stop.router=Arr\u00EAter le routeur -label.action.stop.router.processing=Arr\u00EAt du routeur... -label.action.stop.systemvm=Arr\u00EAter la VM syst\u00E8me -label.action.stop.systemvm.processing=Arr\u00EAt de la VM syst\u00E8me... -label.action.take.snapshot=Prendre un instantan\u00E9 -label.action.take.snapshot.processing=Prise de l\\'instantan\u00E9... -label.action.unmanage.cluster=Ne plus g\u00E9rer le Cluster -label.action.unmanage.cluster.processing=Arr\u00EAt de la gestion du Cluster -label.action.update.OS.preference=Mettre \u00E0 jour les pr\u00E9f\u00E9rences d\\'OS -label.action.update.OS.preference.processing=Mise \u00E0 jour des pr\u00E9f\u00E9rences d\\'OS... -label.action.update.resource.count=Mettre \u00E0 jour le compteur des ressources -label.action.update.resource.count.processing=Mise \u00E0 jour du compteur... +label.action.restore.instance=Restaurer l\\'instance label.actions=Actions +label.action.start.instance=D\u00e9marrer l\\'instance +label.action.start.instance.processing=D\u00e9marrage de l\\'instance... +label.action.start.router=D\u00e9marrer le routeur +label.action.start.router.processing=D\u00e9marrage du routeur... +label.action.start.systemvm=D\u00e9marrer la VM syst\u00e8me +label.action.start.systemvm.processing=D\u00e9marrage de la VM syst\u00e8me... +label.action.stop.instance=Arr\u00eater l\\'Instance +label.action.stop.instance.processing=Arr\u00eat de l\\'Instance... +label.action.stop.router=Arr\u00eater le routeur +label.action.stop.router.processing=Arr\u00eat du routeur... +label.action.stop.systemvm=Arr\u00eater la VM syst\u00e8me +label.action.stop.systemvm.processing=Arr\u00eat de la VM syst\u00e8me... +label.action.take.snapshot=Prendre un instantan\u00e9 +label.action.take.snapshot.processing=Prise de l\\'instantan\u00e9... +label.action.unmanage.cluster=Ne plus g\u00e9rer le Cluster +label.action.unmanage.cluster.processing=Arr\u00eat de la gestion du Cluster +label.action.update.OS.preference=Mettre \u00e0 jour les pr\u00e9f\u00e9rences d\\'OS +label.action.update.OS.preference.processing=Mise \u00e0 jour des pr\u00e9f\u00e9rences d\\'OS... +label.action.update.resource.count=Mettre \u00e0 jour le compteur des ressources +label.action.update.resource.count.processing=Mise \u00e0 jour du compteur... +label.action.vmsnapshot.create=Prendre un instantan\u00e9 VM +label.action.vmsnapshot.delete=Supprimer l\\'instantan\u00e9 VM +label.action.vmsnapshot.revert=Revenir \u00e0 un instantan\u00e9 VM label.activate.project=Activer projet label.active.sessions=Sessions actives -label.add=Ajouter -label.add.ACL=Ajouter r\u00E8gle ACL -label.add.F5.device=Ajouter un F5 -label.add.NiciraNvp.device=Ajouter un contr\u00F4leur Nvp -label.add.SRX.device=Ajouter un SRX -label.add.VM.to.tier=Ajouter une machine virtuelle au tiers -label.add.VPN.gateway=Ajouter une passerelle VPN label.add.account=Ajouter un compte -label.add.account.to.project=Ajouter un compte au projet label.add.accounts=Ajouter des comptes label.add.accounts.to=Ajouter des comptes sur -label.add.by=Ajout\u00E9 par +label.add.account.to.project=Ajouter un compte au projet +label.add.ACL=Ajouter r\u00e8gle ACL +label.add.affinity.group=Ajouter nouvea groupe d\\'affinit\u00e9 +label.add=Ajouter +label.add.BigSwitchVns.device=Ajouter contr\u00f4leur BigSwitch Vns +label.add.by=Ajout\u00e9 par label.add.by.cidr=Ajouter par CIDR label.add.by.group=Ajouter par groupe label.add.cluster=Ajouter un cluster @@ -283,308 +251,343 @@ label.add.compute.offering=Ajouter une offre de calcul label.add.direct.iprange=Ajouter une plage d\\'adresse IP directe label.add.disk.offering=Ajouter une offre disque label.add.domain=Ajouter un domaine -label.add.egress.rule=Ajouter la r\u00E8gle sortante -label.add.firewall=Ajouter une r\u00E8gle de pare-feu -label.add.guest.network=Ajouter un r\u00E9seau d\\'invit\u00E9 -label.add.host=Ajouter un h\u00F4te -label.add.ingress.rule=Ajouter une r\u00E8gle d\\'entr\u00E9e +label.add.egress.rule=Ajouter la r\u00e8gle sortante +label.add.F5.device=Ajouter un F5 +label.add.firewall=Ajouter une r\u00e8gle de pare-feu +label.add.guest.network=Ajouter un r\u00e9seau d\\'invit\u00e9 +label.add.host=Ajouter un h\u00f4te +label.adding=Ajout +label.adding.cluster=Ajout du Cluster +label.adding.failed=\u00c9chec de l\\'ajout +label.adding.pod=Ajout du Pod +label.adding.processing=Ajout... +label.add.ingress.rule=Ajouter une r\u00e8gle d\\'entr\u00e9e +label.adding.succeeded=Ajout r\u00e9ussi +label.adding.user=Ajout de l\\'utilisateur +label.adding.zone=Ajout de la zone label.add.ip.range=Ajouter une plage IP -label.add.load.balancer=Ajouter un r\u00E9partiteur de charge +label.additional.networks=R\u00e9seaux additionnels +label.add.load.balancer=Ajouter un r\u00e9partiteur de charge label.add.more=Ajouter plus label.add.netScaler.device=Ajouter un Netscaler -label.add.network=Ajouter un r\u00E9seau -label.add.network.ACL=Ajouter une r\u00E8gle d\\'acc\u00E8s r\u00E9seau ACL -label.add.network.device=Ajouter un \u00E9quipement r\u00E9seau -label.add.network.offering=Ajouter une offre r\u00E9seau +label.add.network.ACL=Ajouter une r\u00e8gle d\\'acc\u00e8s r\u00e9seau ACL +label.add.network=Ajouter un r\u00e9seau +label.add.network.device=Ajouter un \u00e9quipement r\u00e9seau +label.add.network.offering=Ajouter une offre r\u00e9seau label.add.new.F5=Ajouter un F5 +label.add.new.gateway=Ajouter une nouvelle passerelle label.add.new.NetScaler=Ajouter un Netscaler label.add.new.SRX=Ajouter un SRX -label.add.new.gateway=Ajouter une nouvelle passerelle label.add.new.tier=Ajouter un nouveau tiers -label.add.physical.network=Ajouter un r\u00E9seau physique +label.add.NiciraNvp.device=Ajouter un contr\u00f4leur Nvp +label.add.physical.network=Ajouter un r\u00e9seau physique label.add.pod=Ajouter un pod -label.add.port.forwarding.rule=Ajouter une r\u00E8gle de transfert de port +label.add.port.forwarding.rule=Ajouter une r\u00e8gle de transfert de port label.add.primary.storage=Ajouter un stockage principal +label.add.region=Ajouter R\u00e9gion label.add.resources=Ajouter ressources label.add.route=Ajouter route -label.add.rule=Ajouter r\u00E8gle +label.add.rule=Ajouter r\u00e8gle label.add.secondary.storage=Ajouter un stockage secondaire -label.add.security.group=Ajouter un groupe de s\u00E9curit\u00E9 +label.add.security.group=Ajouter un groupe de s\u00e9curit\u00e9 label.add.service.offering=Ajouter une offre de service -label.add.static.nat.rule=Ajouter une r\u00E8gle de NAT statique +label.add.SRX.device=Ajouter un SRX +label.add.static.nat.rule=Ajouter une r\u00e8gle de NAT statique label.add.static.route=Ajouter une route statique -label.add.system.service.offering=Ajouter une offre de service syst\u00E8me -label.add.template=Ajouter un mod\u00E8le +label.add.system.service.offering=Ajouter une offre de service syst\u00e8me +label.add.template=Ajouter un mod\u00e8le label.add.to.group=Ajouter au groupe label.add.user=Ajouter un utilisateur label.add.vlan=Ajouter un VLAN label.add.vm=Ajouter VM label.add.vms=Ajouter VMs -label.add.vms.to.lb=Ajouter une/des VM(s) \u00E0 la r\u00E8gle de r\u00E9partition de charge +label.add.vms.to.lb=Ajouter une/des VM(s) \u00e0 la r\u00e8gle de r\u00e9partition de charge +label.add.VM.to.tier=Ajouter une machine virtuelle au tiers label.add.volume=Ajouter un volume label.add.vpc=Ajouter un VPC label.add.vpn.customer.gateway=Ajouter une passerelle VPN cliente +label.add.VPN.gateway=Ajouter une passerelle VPN label.add.vpn.user=Ajouter un utilisateur VPN label.add.zone=Ajouter une zone -label.adding=Ajout -label.adding.cluster=Ajout du Cluster -label.adding.failed=\u00C9chec de l\\'ajout -label.adding.pod=Ajout du Pod -label.adding.processing=Ajout... -label.adding.succeeded=Ajout r\u00E9ussi -label.adding.user=Ajout de l\\'utilisateur -label.adding.zone=Ajout de la zone -label.additional.networks=R\u00E9seaux additionnels -label.admin=Administrateur label.admin.accounts=Comptes Administrateur -label.advanced=Avanc\u00E9 -label.advanced.mode=Mode avanc\u00E9 -label.advanced.search=Recherche avanc\u00E9e +label.admin=Administrateur +label.advanced=Avanc\u00e9 +label.advanced.mode=Mode avanc\u00e9 +label.advanced.search=Recherche avanc\u00e9e +label.affinity=Affinit\u00e9 +label.affinity.group=Groupe d\\'Affinit\u00e9 +label.affinity.groups=Groups d\\'Affinit\u00e9 label.agent.password=Mot de passe Agent label.agent.username=Identifiant Agent label.agree=Accepter label.alert=Alerte label.algorithm=Algorithme -label.allocated=Allou\u00E9 -label.allocation.state=\u00C9tat -label.api.key=Cl\u00E9 d\\'API +label.allocated=Allou\u00e9 +label.allocation.state=\u00c9tat +label.anti.affinity=Anti-affinit\u00e9 +label.anti.affinity.group=Groupe d\\'Anti-affinit\u00e9 +label.anti.affinity.groups=Groupes d\\'Anti-affinit\u00e9 +label.api.key=Cl\u00e9 d\\'API label.apply=Appliquer label.assign=Assigner -label.assign.to.load.balancer=Assigner l\\'instance au r\u00E9partiteur de charge -label.associated.network=R\u00E9seau associ\u00E9 -label.associated.network.id=ID du r\u00E9seau associ\u00E9 -label.attached.iso=Image ISO attach\u00E9e -label.availability=Disponibilit\u00E9 -label.availability.zone=Zone de disponibilit\u00E9 +label.assign.to.load.balancer=Assigner l\\'instance au r\u00e9partiteur de charge +label.associated.network.id=ID du r\u00e9seau associ\u00e9 +label.associated.network=R\u00e9seau associ\u00e9 +label.attached.iso=Image ISO attach\u00e9e +label.author.email=Email auteur +label.author.name=Nom auteur +label.availability=Disponibilit\u00e9 +label.availability.zone=Zone de disponibilit\u00e9 label.available=Disponible label.available.public.ips=Adresses IP publiques disponibles label.back=Retour label.bandwidth=Bande passante label.basic=Basique label.basic.mode=Mode basique -label.bootable=Amor\u00E7able +label.bigswitch.controller.address=Adresse du contr\u00f4leur BigSwitch Vns +label.bootable=Amor\u00e7able label.broadcast.domain.range=Plage du domaine multi-diffusion label.broadcast.domain.type=Type de domaine de multi-diffusion label.broadcast.uri=URI multi-diffusion label.by.account=Par compte -label.by.availability=Par disponibilit\u00E9 +label.by.availability=Par disponibilit\u00e9 label.by.domain=Par domaine label.by.end.date=Par date de fin label.by.level=Par niveau label.by.pod=Par Pod -label.by.role=Par r\u00F4le -label.by.start.date=Par date de d\u00E9but -label.by.state=Par \u00E9tat +label.by.role=Par r\u00f4le +label.by.start.date=Par date de d\u00e9but +label.by.state=Par \u00e9tat +label.bytes.received=Octets re\u00e7us +label.bytes.sent=Octets envoy\u00e9s label.by.traffic.type=Par type de trafic -label.by.type=Par type label.by.type.id=Par type d\\'ID +label.by.type=Par type label.by.zone=Par zone -label.bytes.received=Octets re\u00E7us -label.bytes.sent=Octets envoy\u00E9s label.cancel=Annuler -label.capacity=Capacit\u00E9 +label.capacity=Capacit\u00e9 label.certificate=Certificat label.change.service.offering=Modifier l\\'offre de service label.change.value=Modifier la valeur -label.character=Caract\u00E8re -label.checksum=Somme de contr\u00F4le MD5 +label.character=Caract\u00e8re +label.checksum=Somme de contr\u00f4le MD5 +label.cidr.account=CIDR ou Compte/Groupe de s\u00e9curit\u00e9 label.cidr=CIDR -label.cidr.account=CIDR ou Compte/Groupe de s\u00E9curit\u00E9 label.cidr.list=CIDR Source +label.CIDR.list=Liste CIDR +label.CIDR.of.destination.network=CIDR du r\u00e9seau de destination label.clean.up=Nettoyage label.clear.list=Purger la liste label.close=Fermer label.cloud.console=Console d\\'Administration du Cloud -label.cloud.managed=G\u00E9r\u00E9 par Cloud.com +label.cloud.managed=G\u00e9r\u00e9 par Cloud.com label.cluster=Cluster label.cluster.name=Nom du cluster -label.cluster.type=Type de Cluster label.clusters=Clusters +label.cluster.type=Type de Cluster label.clvm=CLVM label.code=Code -label.community=Communaut\u00E9 -label.compute=Processeur +label.community=Communaut\u00e9 label.compute.and.storage=Calcul et Stockage label.compute.offering=Offre de calcul label.compute.offerings=Offres de calcul +label.compute=Processeur label.configuration=Configuration label.configure=Configurer -label.configure.network.ACLs=Configurer les r\u00E8gles d\\'acc\u00E8s r\u00E9seau ACL +label.configure.network.ACLs=Configurer les r\u00e8gles d\\'acc\u00e8s r\u00e9seau ACL label.configure.vpc=Configurer le VPC -label.confirm.password=Confirmer le mot de passe label.confirmation=Confirmation -label.congratulations=F\u00E9licitations \! +label.confirm.password=Confirmer le mot de passe +label.congratulations=F\u00e9licitations \! label.conserve.mode=Conserver le mode label.console.proxy=Console proxy -label.continue=Continuer label.continue.basic.install=Continuer avec l\\'installation basique -label.corrections.saved=Modifications enregistr\u00E9es +label.continue=Continuer +label.corrections.saved=Modifications enregistr\u00e9es +label.cpu.allocated=CPU allou\u00e9e +label.cpu.allocated.for.VMs=CPU allou\u00e9e aux VMs +label.CPU.cap=Limitation CPU label.cpu=CPU -label.cpu.allocated=CPU allou\u00E9e -label.cpu.allocated.for.VMs=CPU allou\u00E9e aux VMs +label.cpu.limits=Limites CPU label.cpu.mhz=CPU (en MHz) -label.cpu.utilized=CPU utilis\u00E9e -label.create.VPN.connection=Cr\u00E9er une connexion VPN -label.create.project=Cr\u00E9er un projet -label.create.template=Cr\u00E9er un mod\u00E8le -label.created=Cr\u00E9\u00E9 -label.created.by.system=Cr\u00E9\u00E9 par le syst\u00E8me +label.cpu.utilized=CPU utilis\u00e9e +label.created.by.system=Cr\u00e9\u00e9 par le syst\u00e8me +label.created=Cr\u00e9\u00e9 +label.create.project=Cr\u00e9er un projet +label.create.template=Cr\u00e9er un mod\u00e8le +label.create.VPN.connection=Cr\u00e9er une connexion VPN label.cross.zones=Multi Zones -label.custom.disk.size=Taille de disque personnalis\u00E9e +label.custom.disk.size=Taille de disque personnalis\u00e9e label.daily=Quotidien -label.data.disk.offering=Offre de disque de donn\u00E9es +label.data.disk.offering=Offre de disque de donn\u00e9es label.date=Date label.day.of.month=Jour du mois label.day.of.week=Jour de la semaine -label.dead.peer.detection=D\u00E9tection de pair mort +label.dead.peer.detection=D\u00e9tection de pair mort label.decline.invitation=Refuser l\\'invitation -label.dedicated=D\u00E9di\u00E9 -label.default=Par d\u00E9faut -label.default.use=Utilisation par d\u00E9faut -label.default.view=Vue par d\u00E9faut -label.delete=Supprimer +label.dedicated=D\u00e9di\u00e9 +label.default=Par d\u00e9faut +label.default.use=Utilisation par d\u00e9faut +label.default.view=Vue par d\u00e9faut +label.delete.affinity.group=Supprimer le groupe d\\'affinit\u00e9 +label.delete.BigSwitchVns=Supprimer contr\u00f4leur BigSwitch Vns label.delete.F5=Supprimer F5 +label.delete.gateway=Supprimer la passerelle label.delete.NetScaler=Supprimer Netscaler -label.delete.NiciraNvp=Supprimer un contr\u00F4leur Nvp +label.delete.NiciraNvp=Supprimer un contr\u00f4leur Nvp +label.delete.project=Supprimer projet label.delete.SRX=Supprimer SRX +label.delete=Supprimer label.delete.VPN.connection=Supprimer la connexion VPN label.delete.VPN.customer.gateway=Supprimer la passerelle VPN client label.delete.VPN.gateway=Supprimer la passerelle VPN -label.delete.gateway=Supprimer la passerelle -label.delete.project=Supprimer projet label.delete.vpn.user=Supprimer l\\'utilisateur VPN -label.deleting.failed=Suppression \u00E9chou\u00E9e +label.deleting.failed=Suppression \u00e9chou\u00e9e label.deleting.processing=Suppression... label.description=Description -label.destination.physical.network.id=Identifiant du r\u00E9seau physique de destination +label.destination.physical.network.id=Identifiant du r\u00e9seau physique de destination label.destination.zone=Zone de destination -label.destroy=D\u00E9truire +label.destroy=D\u00e9truire label.destroy.router=Supprimer le routeur -label.detaching.disk=D\u00E9tacher le disque -label.details=D\u00E9tails -label.device.id=ID du p\u00E9riph\u00E9rique +label.detaching.disk=D\u00e9tacher le disque +label.details=D\u00e9tails +label.device.id=ID du p\u00e9riph\u00e9rique label.devices=Machines label.dhcp=DHCP -label.direct.ips=Adresses IP du r\u00E9seau partag\u00E9 -label.disable.provider=D\u00E9sactiver ce fournisseur -label.disable.vpn=D\u00E9sactiver le VPN -label.disabled=D\u00E9sactiv\u00E9 -label.disabling.vpn.access=D\u00E9sactiver l\\'acc\u00E8s VPN -label.disk.allocated=Disque Allou\u00E9 +label.DHCP.server.type=Serveur DHCP +label.direct.ips=Adresses IP du r\u00e9seau partag\u00e9 +label.disabled=D\u00e9sactiv\u00e9 +label.disable.provider=D\u00e9sactiver ce fournisseur +label.disable.vpn=D\u00e9sactiver le VPN +label.disabling.vpn.access=D\u00e9sactiver l\\'acc\u00e8s VPN +label.disk.allocated=Disque Allou\u00e9 label.disk.offering=Offre de Disque -label.disk.size=Taille du disque label.disk.size.gb=Taille du disque (en Go) +label.disk.size=Taille du disque label.disk.total=Espace disque total label.disk.volume=Volume disque label.display.name=Nom commun -label.display.text=Texte affich\u00E9 -label.dns=DNS +label.display.text=Texte affich\u00e9 label.dns.1=DNS 1 label.dns.2=DNS 2 -label.domain=Domaine +label.dns=DNS +label.DNS.domain.for.guest.networks=Domaine DNS pour les r\u00e9seaux invit\u00e9s label.domain.admin=Administrateur du domaine +label.domain=Domaine label.domain.id=ID du domaine label.domain.name=Nom de domaine label.domain.router=Routeur du domaine label.domain.suffix=Suffixe de domaine DNS (i.e., xyz.com) -label.done=Termin\u00E9 -label.double.quotes.are.not.allowed=Les guillemets ne sont pas autoris\u00E9es -label.download.progress=Progression du t\u00E9l\u00E9chargement -label.drag.new.position=D\u00E9placer sur une autre position +label.done=Termin\u00e9 +label.double.quotes.are.not.allowed=Les guillemets ne sont pas autoris\u00e9es +label.download.progress=Progression du t\u00e9l\u00e9chargement +label.drag.new.position=D\u00e9placer sur une autre position +label.edit.affinity.group=Modifier le groupe d\\'affinit\u00e9 +label.edit.lb.rule=Modifier la r\u00e8gle LB label.edit=Modifier -label.edit.lb.rule=Modifier la r\u00E8gle LB -label.edit.network.details=Modifier les param\u00E8tres r\u00E9seau -label.edit.project.details=Modifier les d\u00E9tails du projet +label.edit.network.details=Modifier les param\u00e8tres r\u00e9seau +label.edit.project.details=Modifier les d\u00e9tails du projet label.edit.tags=Modifier les balises label.edit.traffic.type=Modifier le type de trafic label.edit.vpc=Modifier le VPC -label.egress.rule=R\u00E8gle sortante -label.egress.rules=R\u00E8gles de sortie -label.elastic=\u00C9lastique +label.egress.rule=R\u00e8gle sortante +label.egress.rules=R\u00e8gles de sortie label.elastic.IP=IP extensible -label.elastic.LB=R\u00E9partition de charge extensible +label.elastic.LB=R\u00e9partition de charge extensible +label.elastic=\u00c9lastique label.email=Email label.enable.provider=Activer le fournisseur label.enable.s3=Activer le stockage secondaire de type S3 label.enable.swift=Activer Swift label.enable.vpn=Activer VPN +label.enabling.vpn.access=Activation de l\\'acc\u00e8s VPN label.enabling.vpn=Activation du VPN -label.enabling.vpn.access=Activation de l\\'acc\u00E8s VPN label.end.IP=Fin de plage IP +label.endpoint.or.operation=Terminaison ou Op\u00e9ration +label.endpoint=Terminaison label.end.port=Port de fin -label.end.reserved.system.IP=Adresse IP de fin r\u00E9serv\u00E9e Syst\u00E8me +label.end.reserved.system.IP=Adresse IP de fin r\u00e9serv\u00e9e Syst\u00e8me label.end.vlan=VLAN de fin -label.endpoint.or.operation=Terminaison ou Op\u00E9ration label.enter.token=Entrez le jeton unique -label.error=Erreur label.error.code=Code d\\'erreur -label.esx.host=H\u00F4te ESX/ESXi +label.error=Erreur +label.ESP.encryption=Chiffrement ESP +label.ESP.hash=Empreinte ESP +label.ESP.lifetime=Dur\u00e9e de vie ESP (secondes) +label.ESP.policy=Mode ESP +label.esx.host=H\u00f4te ESX/ESXi label.example=Exemple +label.external.link=Lien externe label.f5=F5 -label.failed=\u00C9chou\u00E9 -label.featured=Sponsoris\u00E9 -label.fetch.latest=Rafra\u00EEchir +label.failed=\u00c9chou\u00e9 +label.featured=Sponsoris\u00e9 +label.fetch.latest=Rafra\u00eechir label.filterBy=Filtre label.firewall=Pare-feu -label.first.name=Pr\u00E9nom +label.first.name=Pr\u00e9nom label.format=Format label.friday=Vendredi label.full=Complet label.full.path=Chemin complet label.gateway=Passerelle -label.general.alerts=Alertes g\u00E9n\u00E9rales -label.generating.url=G\u00E9n\u00E9ration de l\\'URL -label.go.step.2=Aller \u00E0 l\\'\u00E9tape 2 -label.go.step.3=Aller \u00E0 l\\'\u00E9tape 3 -label.go.step.4=Aller \u00E0 l\\'\u00E9tape 4 -label.go.step.5=Aller \u00E0 l\\'\u00E9tape 5 +label.general.alerts=Alertes g\u00e9n\u00e9rales +label.generating.url=G\u00e9n\u00e9ration de l\\'URL +label.go.step.2=Aller \u00e0 l\\'\u00e9tape 2 +label.go.step.3=Aller \u00e0 l\\'\u00e9tape 3 +label.go.step.4=Aller \u00e0 l\\'\u00e9tape 4 +label.go.step.5=Aller \u00e0 l\\'\u00e9tape 5 label.group=Groupe label.group.optional=Groupe (optionnel) -label.guest=Invit\u00E9 -label.guest.cidr=CIDR invit\u00E9 -label.guest.end.ip=Adresse IP de fin pour les invit\u00E9s -label.guest.gateway=Passerelle pour les invit\u00E9s -label.guest.ip=Adresse IP des invit\u00E9s -label.guest.ip.range=Plage d\\'adresses IP des invit\u00E9s -label.guest.netmask=Masque de r\u00E9seau des invit\u00E9s -label.guest.networks=R\u00E9seaux d\\'invit\u00E9 -label.guest.start.ip=Adresse IP de d\u00E9but pour les invit\u00E9s -label.guest.traffic=Trafic invit\u00E9 -label.guest.type=Type d\\'invit\u00E9 -label.ha.enabled=Haute disponibilit\u00E9 activ\u00E9e +label.guest.cidr=CIDR invit\u00e9 +label.guest.end.ip=Adresse IP de fin pour les invit\u00e9s +label.guest.gateway=Passerelle pour les invit\u00e9s +label.guest=Invit\u00e9 +label.guest.ip=Adresse IP des invit\u00e9s +label.guest.ip.range=Plage d\\'adresses IP des invit\u00e9s +label.guest.netmask=Masque de r\u00e9seau des invit\u00e9s +label.guest.networks=R\u00e9seaux d\\'invit\u00e9 +label.guest.start.ip=Adresse IP de d\u00e9but pour les invit\u00e9s +label.guest.traffic=Trafic invit\u00e9 +label.guest.type=Type d\\'invit\u00e9 +label.ha.enabled=Haute disponibilit\u00e9 activ\u00e9e label.help=Aide -label.hide.ingress.rule=Cacher la r\u00E8gle d\\'entr\u00E9e +label.hide.ingress.rule=Cacher la r\u00e8gle d\\'entr\u00e9e label.hints=Astuces -label.host=H\u00F4te -label.host.MAC=Adresse MAC h\u00F4te -label.host.alerts=Alertes des h\u00F4tes -label.host.name=Nom d\\'h\u00F4te -label.host.tags=\u00C9tiquettes d\\'h\u00F4te -label.hosts=H\u00F4tes +label.host.alerts=Alertes des h\u00f4tes +label.host=H\u00f4te +label.host.MAC=Adresse MAC h\u00f4te +label.host.name=Nom d\\'h\u00f4te +label.hosts=H\u00f4tes +label.host.tags=\u00c9tiquettes d\\'h\u00f4te label.hourly=Chaque heure -label.hypervisor=Hyperviseur label.hypervisor.capabilities=Fonctions hyperviseur +label.hypervisor=Hyperviseur label.hypervisor.type=Type d\\'hyperviseur label.hypervisor.version=Version hyperviseur label.id=ID +label.IKE.DH=DH IKE +label.IKE.encryption=Chiffrement IKE +label.IKE.hash=Empreinte IKE +label.IKE.lifetime=Dur\u00e9e de vie IKE (secondes) +label.IKE.policy=Mode IKE label.info=Information -label.ingress.rule=R\u00E8gle d\\'entr\u00E9e -label.initiated.by=Initi\u00E9 par +label.ingress.rule=R\u00e8gle d\\'entr\u00e9e +label.initiated.by=Initi\u00e9 par label.installWizard.addClusterIntro.subtitle=Qu\\'est ce qu\\'un cluster ? label.installWizard.addClusterIntro.title=Ajoutons un cluster -label.installWizard.addHostIntro.subtitle=Qu\\'est ce qu\\'un h\u00F4te ? -label.installWizard.addHostIntro.title=Ajoutons un h\u00F4te +label.installWizard.addHostIntro.subtitle=Qu\\'est ce qu\\'un h\u00f4te ? +label.installWizard.addHostIntro.title=Ajoutons un h\u00f4te label.installWizard.addPodIntro.subtitle=Qu\\'est ce qu\\'un pod ? label.installWizard.addPodIntro.title=Ajoutons un pod label.installWizard.addPrimaryStorageIntro.subtitle=Qu\\'est ce que le stockage principal ? label.installWizard.addPrimaryStorageIntro.title=Ajoutons du stockage principal label.installWizard.addSecondaryStorageIntro.subtitle=Qu\\'est ce que le stockage secondaire ? label.installWizard.addSecondaryStorageIntro.title=Ajoutons du stockage secondaire -label.installWizard.addZone.title=Ajouter une zone label.installWizard.addZoneIntro.subtitle=Qu\\'est ce qu\\'une zone ? label.installWizard.addZoneIntro.title=Ajoutons une zone -label.installWizard.click.launch=Appuyer sur le bouton d\u00E9marrer. -label.installWizard.subtitle=Ce tutoriel vous aidera \u00E0 configurer votre installation CloudStack&\#8482; +label.installWizard.addZone.title=Ajouter une zone +label.installWizard.click.launch=Appuyer sur le bouton d\u00e9marrer. +label.installWizard.subtitle=Ce tutoriel vous aidera \u00e0 configurer votre installation CloudStack&\#8482; label.installWizard.title=Bonjour et bienvenue dans CloudStack&\#8482; label.instance=Instance label.instance.limits=Limites des instances @@ -594,105 +597,114 @@ label.internal.dns.1=DNS interne 1 label.internal.dns.2=DNS interne 2 label.internal.name=Nom interne label.interval.type=Type d\\'intervalle -label.introduction.to.cloudstack=Introduction \u00E0 CloudStack&\#8482; +label.introduction.to.cloudstack=Introduction \u00e0 CloudStack&\#8482; label.invalid.integer=Nombre entier invalide label.invalid.number=Nombre invalide label.invitations=Invitations +label.invited.accounts=Comptes invit\u00e9s label.invite=Inviter label.invite.to=Inviter sur -label.invited.accounts=Comptes invit\u00E9s -label.ip=IP label.ip.address=Adresse IP +label.ipaddress=Adresse IP label.ip.allocations=Allocations de IPs +label.ip=IP label.ip.limits=Limite de IPs publiques label.ip.or.fqdn=IP ou FQDN label.ip.range=Plage IP label.ip.ranges=Plages IP -label.ipaddress=Adresse IP +label.IPsec.preshared.key=Cl\u00e9 partag\u00e9e IPsec label.ips=IPs -label.is.default=Est par d\u00E9faut -label.is.redundant.router=Redondant -label.is.shared=Est partag\u00E9 -label.is.system=Est Syst\u00E8me label.iscsi=iSCSI +label.is.default=Est par d\u00e9faut +label.iso.boot=D\u00e9marrage par ISO label.iso=ISO -label.iso.boot=D\u00E9marrage par ISO -label.isolated.networks=R\u00E9seaux isol\u00E9s -label.isolation.method=M\u00E9thode de s\u00E9paration +label.isolated.networks=R\u00e9seaux isol\u00e9s +label.isolation.method=M\u00e9thode de s\u00e9paration label.isolation.mode=Mode d\\'isolation label.isolation.uri=URI d\\'isolation -label.item.listing=Liste des \u00E9l\u00E9ments +label.is.redundant.router=Redondant +label.is.shared=Est partag\u00e9 +label.is.system=Est Syst\u00e8me +label.item.listing=Liste des \u00e9l\u00e9ments label.keep=Conserver -label.key=Clef label.keyboard.type=Type de clavier -label.kvm.traffic.label=Libell\u00E9 pour le trafic KVM -label.label=Libell\u00E9 -label.lang.brportugese=Portuguais Br\u00E9sil +label.key=Clef +label.kvm.traffic.label=Libell\u00e9 pour le trafic KVM +label.label=Libell\u00e9 +label.lang.arabic=Arabe +label.lang.brportugese=Portuguais Br\u00e9sil label.lang.catalan=Catalan -label.lang.chinese=Chinois (simplifi\u00E9) +label.lang.chinese=Chinois (simplifi\u00e9) label.lang.english=Anglais -label.lang.french=Fran\u00E7ais +label.lang.french=Fran\u00e7ais label.lang.german=Allemand label.lang.italian=Italien label.lang.japanese=Japonais -label.lang.korean=Cor\u00E9en -label.lang.norwegian=Norv\u00E9gien +label.lang.korean=Cor\u00e9en +label.lang.norwegian=Norv\u00e9gien label.lang.russian=Russe label.lang.spanish=Espagnol -label.last.disconnected=Derni\u00E8re D\u00E9connexion +label.last.disconnected=Derni\u00e8re D\u00e9connexion label.last.name=Nom -label.latest.events=Derniers \u00E9v\u00E9nements -label.launch=D\u00E9marrer -label.launch.vm=D\u00E9marrer VM -label.launch.zone=D\u00E9marrer la zone +label.latest.events=Derniers \u00e9v\u00e9nements +label.launch=D\u00e9marrer +label.launch.vm=D\u00e9marrer VM +label.launch.zone=D\u00e9marrer la zone +label.LB.isolation=R\u00e9partition de charge isol\u00e9e label.least.connections=Le moins de connexions label.level=Niveau label.linklocal.ip=Adresse IP de lien local -label.load.balancer=R\u00E9partiteur de charge -label.load.balancing=R\u00E9partition de charge -label.load.balancing.policies=R\u00E8gles de r\u00E9partition de charge +label.load.balancer=R\u00e9partiteur de charge +label.load.balancing.policies=R\u00e8gles de r\u00e9partition de charge +label.load.balancing=R\u00e9partition de charge label.loading=Chargement en cours label.local=Local +label.local.storage.enabled=Stockage local activ\u00e9 label.local.storage=Stockage local -label.local.storage.enabled=Stockage local activ\u00E9 label.login=Connexion -label.logout=D\u00E9connexion +label.logout=D\u00e9connexion label.lun=LUN -label.make.project.owner=Devenir propri\u00E9taire du projet -label.manage=G\u00E9r\u00E9 -label.manage.resources=G\u00E9rer les ressources +label.LUN.number=N\u00b0 LUN +label.make.project.owner=Devenir propri\u00e9taire du projet +label.manage=G\u00e9r\u00e9 label.management=Administration label.management.ips=Adresses IP de gestion -label.max.guest.limit=Nombre maximum d\\'invit\u00E9s -label.max.networks=R\u00E9seaux Max. +label.manage.resources=G\u00e9rer les ressources +label.max.cpus=Nombre coeurs CPU max. +label.max.guest.limit=Nombre maximum d\\'invit\u00e9s +label.maximum=Maximum +label.max.memory=M\u00e9moire max. (Mo) +label.max.networks=R\u00e9seaux Max. +label.max.primary.storage=Principal max. (Go) label.max.public.ips=Max. IP publiques -label.max.snapshots=Max instantan\u00E9es -label.max.templates=Max. mod\u00E8les +label.max.secondary.storage=Secondaire max. (Go) +label.max.snapshots=Max instantan\u00e9es +label.max.templates=Max. mod\u00e8les label.max.vms=Max. VMs utilisateur label.max.volumes=Max. volumes label.max.vpcs=Max. VPCs -label.maximum=Maximum label.may.continue=Vous pouvez continuer. -label.memory=M\u00E9moire (en Mo) -label.memory.allocated=M\u00E9moire allou\u00E9e -label.memory.mb=M\u00E9moire (en MB) -label.memory.total=M\u00E9moire totale -label.memory.used=M\u00E9moire utilis\u00E9e +label.memory.allocated=M\u00e9moire allou\u00e9e +label.memory.limits=Limites m\u00e9moire (Mo) +label.memory.mb=M\u00e9moire (en MB) +label.memory=M\u00e9moire (en Mo) +label.memory.total=M\u00e9moire totale +label.memory.used=M\u00e9moire utilis\u00e9e label.menu.accounts=Comptes label.menu.alerts=Alertes label.menu.all.accounts=Tous les comptes label.menu.all.instances=Toutes les instances -label.menu.community.isos=ISO de la communaut\u00E9 -label.menu.community.templates=Mod\u00E8les de la communaut\u00E9 +label.menu.community.isos=ISO de la communaut\u00e9 +label.menu.community.templates=Mod\u00e8les de la communaut\u00e9 label.menu.configuration=Configuration label.menu.dashboard=Tableau de bord -label.menu.destroyed.instances=Instances d\u00E9truites +label.menu.destroyed.instances=Instances d\u00e9truites label.menu.disk.offerings=Offres de disque label.menu.domains=Domaines -label.menu.events=\u00C9v\u00E9nements -label.menu.featured.isos=ISOs Sponsoris\u00E9es -label.menu.featured.templates=Mod\u00E8les sponsoris\u00E9s -label.menu.global.settings=Param\u00E8tres globaux +label.menu.events=\u00c9v\u00e9nements +label.menu.featured.isos=ISOs Sponsoris\u00e9es +label.menu.featured.templates=Mod\u00e8les sponsoris\u00e9s +label.menu.global.settings=Param\u00e8tres globaux label.menu.infrastructure=Infrastructure label.menu.instances=Instances label.menu.ipaddresses=Adresses IP @@ -700,72 +712,73 @@ label.menu.isos=ISOs label.menu.my.accounts=Mes comptes label.menu.my.instances=Mes instances label.menu.my.isos=Mes ISOs -label.menu.my.templates=Mes mod\u00E8les -label.menu.network=R\u00E9seau -label.menu.network.offerings=Offres de Service R\u00E9seau +label.menu.my.templates=Mes mod\u00e8les +label.menu.network.offerings=Offres de Service R\u00e9seau +label.menu.network=R\u00e9seau label.menu.physical.resources=Ressources physiques +label.menu.regions=R\u00e9gions label.menu.running.instances=Instances actives -label.menu.security.groups=Groupes de s\u00E9curit\u00E9 +label.menu.security.groups=Groupes de s\u00e9curit\u00e9 label.menu.service.offerings=Offres de Service -label.menu.snapshots=Instantan\u00E9s -label.menu.stopped.instances=Instances Arr\u00EAt\u00E9es +label.menu.snapshots=Instantan\u00e9s +label.menu.stopped.instances=Instances Arr\u00eat\u00e9es label.menu.storage=Stockage -label.menu.system=Syst\u00E8me -label.menu.system.service.offerings=Offres syst\u00E8me -label.menu.system.vms=\ VMs Syst\u00E8mes -label.menu.templates=Mod\u00E8les +label.menu.system.service.offerings=Offres syst\u00e8me +label.menu.system=Syst\u00e8me +label.menu.system.vms=\ VMs Syst\u00e8mes +label.menu.templates=Mod\u00e8les label.menu.virtual.appliances=Appliances Virtuelles label.menu.virtual.resources=Ressources Virtuelles label.menu.volumes=Volumes +label.migrate.instance.to.host=Migration de l\\'instance sur un autre h\u00f4te label.migrate.instance.to=Migrer l\\'instance vers -label.migrate.instance.to.host=Migration de l\\'instance sur un autre h\u00F4te label.migrate.instance.to.ps=Migration de l\\'instance sur un autre stockage principal -label.migrate.router.to=Migrer le routeur vers -label.migrate.systemvm.to=Migrer la VM syst\u00E8me vers -label.migrate.to.host=Migrer vers un h\u00F4te +label.migrate.router.to=Migrer le routeur vers +label.migrate.systemvm.to=Migrer la VM syst\u00e8me vers +label.migrate.to.host=Migrer vers un h\u00f4te label.migrate.to.storage=Migrer vers un stockage label.migrate.volume=Migration du volume vers un autre stockage principal label.minimum=Minimum label.minute.past.hour=minute(s) label.monday=Lundi label.monthly=Mensuel -label.more.templates=Plus de mod\u00E8les +label.more.templates=Plus de mod\u00e8les label.move.down.row=Descendre d\\'un cran -label.move.to.bottom=D\u00E9placer en bas +label.move.to.bottom=D\u00e9placer en bas label.move.to.top=Placer au dessus label.move.up.row=Monter d\\'un cran label.my.account=Mon compte -label.my.network=Mon r\u00E9seau -label.my.templates=Mes mod\u00E8les +label.my.network=Mon r\u00e9seau +label.my.templates=Mes mod\u00e8les label.name=Nom label.name.optional=Nom (optionnel) label.nat.port.range=Plage de port NAT +label.netmask=Masque de r\u00e9seau label.netScaler=NetScaler -label.netmask=Masque de r\u00E9seau -label.network=R\u00E9seau -label.network.ACL=R\u00E8gles d\\'acc\u00E8s r\u00E9seau ACL -label.network.ACL.total=Total R\u00E8gles d\\'acc\u00E8s r\u00E9seau -label.network.ACLs=R\u00E8gles d\\'acc\u00E8s r\u00E9seau -label.network.desc=Description r\u00E9seau -label.network.device=\u00C9quipement R\u00E9seau -label.network.device.type=Type d\\'\u00E9quipement r\u00E9seau +label.network.ACL=R\u00e8gles d\\'acc\u00e8s r\u00e9seau ACL +label.network.ACLs=R\u00e8gles d\\'acc\u00e8s r\u00e9seau +label.network.ACL.total=Total R\u00e8gles d\\'acc\u00e8s r\u00e9seau +label.network.desc=Description r\u00e9seau +label.network.device.type=Type d\\'\u00e9quipement r\u00e9seau +label.network.device=\u00c9quipement R\u00e9seau label.network.domain=Nom de domaine -label.network.domain.text=Domaine r\u00E9seau -label.network.id=ID r\u00E9seau -label.network.label.display.for.blank.value=Utiliser la passerelle par d\u00E9faut -label.network.name=Nom du r\u00E9seau -label.network.offering=Offre de Service R\u00E9seau -label.network.offering.display.text=Texte affich\u00E9 d\\'Offre de R\u00E9seau -label.network.offering.id=ID de l\\'Offre de Service R\u00E9seau -label.network.offering.name=Nom de l\\'Offre de Service R\u00E9seau -label.network.rate=D\u00E9bit R\u00E9seau -label.network.rate.megabytes=D\u00E9bit r\u00E9seau (Mo/s) -label.network.read=Lecture r\u00E9seau -label.network.service.providers=Fournisseurs de service r\u00E9seau -label.network.type=Type de r\u00E9seau -label.network.write=\u00C9criture r\u00E9seau -label.networking.and.security=R\u00E9seau et s\u00E9curit\u00E9 -label.networks=R\u00E9seaux +label.network.domain.text=Domaine r\u00e9seau +label.network.id=ID r\u00e9seau +label.networking.and.security=R\u00e9seau et s\u00e9curit\u00e9 +label.network.label.display.for.blank.value=Utiliser la passerelle par d\u00e9faut +label.network.name=Nom du r\u00e9seau +label.network.offering.display.text=Texte affich\u00e9 d\\'Offre de R\u00e9seau +label.network.offering.id=ID de l\\'Offre de Service R\u00e9seau +label.network.offering.name=Nom de l\\'Offre de Service R\u00e9seau +label.network.offering=Offre de Service R\u00e9seau +label.network.rate=D\u00e9bit R\u00e9seau +label.network.rate.megabytes=D\u00e9bit r\u00e9seau (Mo/s) +label.network.read=Lecture r\u00e9seau +label.network=R\u00e9seau +label.network.service.providers=Fournisseurs de service r\u00e9seau +label.networks=R\u00e9seaux +label.network.type=Type de r\u00e9seau +label.network.write=\u00c9criture r\u00e9seau label.new=Nouveau label.new.password=Nouveau mot de passe label.new.project=Nouveau projet @@ -775,220 +788,234 @@ label.nexusVswitch=Nexus 1000v label.nfs=NFS label.nfs.server=Serveur NFS label.nfs.storage=Stockage NFS -label.nic.adapter.type=Type de carte r\u00E9seau -label.nicira.controller.address=Adresse du contr\u00F4leur +label.nic.adapter.type=Type de carte r\u00e9seau +label.nicira.controller.address=Adresse du contr\u00f4leur label.nicira.l3gatewayserviceuuid=Uuid du service passerelle L3 label.nicira.transportzoneuuid=Uuid de la Zone Transport label.nics=Cartes NIC -label.no=Non label.no.actions=Aucune action disponible -label.no.alerts=Aucune alerte r\u00E9cente -label.no.data=Aucune donn\u00E9e -label.no.errors=Aucune erreur r\u00E9cente +label.no.alerts=Aucune alerte r\u00e9cente +label.no.data=Aucune donn\u00e9e +label.no.errors=Aucune erreur r\u00e9cente label.no.isos=Aucun ISOs disponible -label.no.items=Aucun \u00E9l\u00E9ment disponible -label.no.security.groups=Aucun groupe de s\u00E9curit\u00E9 disponible -label.no.thanks=Non merci +label.no.items=Aucun \u00e9l\u00e9ment disponible label.none=Aucun +label.no=Non +label.no.security.groups=Aucun groupe de s\u00e9curit\u00e9 disponible label.not.found=Introuvable +label.no.thanks=Non merci label.notifications=Messages -label.num.cpu.cores=Nombre de c\u0153urs label.number.of.clusters=Nombre de clusters -label.number.of.hosts=Nombre d\\'H\u00F4tes +label.number.of.hosts=Nombre d\\'H\u00f4tes label.number.of.pods=Nombre de Pods -label.number.of.system.vms=Nombre de VM Syst\u00E8me +label.number.of.system.vms=Nombre de VM Syst\u00e8me label.number.of.virtual.routers=Nombre de routeurs virtuels label.number.of.zones=Nombre de zones +label.num.cpu.cores=Nombre de c\u0153urs label.numretries=Nombre de tentatives label.ocfs2=OCFS2 -label.offer.ha=Offrir la haute disponibilit\u00E9 +label.offer.ha=Offrir la haute disponibilit\u00e9 label.ok=OK label.optional=Facultatif label.order=Ordre -label.os.preference=Pr\u00E9f\u00E9rence OS +label.os.preference=Pr\u00e9f\u00e9rence OS label.os.type=Type du OS -label.owned.public.ips=Adresses IP Publiques d\u00E9tenues -label.owner.account=Propri\u00E9taire -label.owner.domain=Propri\u00E9taire +label.owned.public.ips=Adresses IP Publiques d\u00e9tenues +label.owner.account=Propri\u00e9taire +label.owner.domain=Propri\u00e9taire label.parent.domain=Parent du Domaine +label.password.enabled=Mot de passe activ\u00e9 label.password=Mot de passe -label.password.enabled=Mot de passe activ\u00E9 label.path=Chemin -label.perfect.forward.secrecy=Confidentialit\u00E9 persistante -label.physical.network=R\u00E9seau physique -label.physical.network.ID=Identifiant du r\u00E9seau physique +label.perfect.forward.secrecy=Confidentialit\u00e9 persistante +label.physical.network.ID=Identifiant du r\u00e9seau physique +label.physical.network=R\u00e9seau physique +label.PING.CIFS.password=Mot de passe CIFS PING +label.PING.CIFS.username=Identifiant CIFS PING +label.PING.dir=R\u00e9pertoire PING +label.PING.storage.IP=IP stockage PING label.please.specify.netscaler.info=Renseigner les informations sur le Netscaler label.please.wait=Patientez s\\'il vous plait -label.pod=Pod +label.plugin.details=D\u00e9tails extension +label.plugins=Extensions label.pod.name=Nom du pod +label.pod=Pod label.pods=Pods +label.port.forwarding.policies=R\u00e8gles de transfert de port label.port.forwarding=Redirection de port -label.port.forwarding.policies=R\u00E8gles de transfert de port label.port.range=Plage de ports -label.prev=Pr\u00E9c\u00E9dent +label.PreSetup=PreSetup label.previous=Retour -label.primary.allocated=Stockage principal allou\u00E9 -label.primary.network=R\u00E9seau principal -label.primary.storage=Premier stockage +label.prev=Pr\u00e9c\u00e9dent +label.primary.allocated=Stockage principal allou\u00e9 +label.primary.network=R\u00e9seau principal label.primary.storage.count=Groupes de stockage principal -label.primary.used=Stockage principal utilis\u00E9 -label.private.Gateway=Passerelle priv\u00E9e -label.private.interface=Interface priv\u00E9e -label.private.ip=Adresse IP Priv\u00E9e -label.private.ip.range=Plage d\\'adresses IP Priv\u00E9es -label.private.ips=Adresses IP Priv\u00E9es -label.private.network=R\u00E9seau priv\u00E9 -label.private.port=Port priv\u00E9 -label.private.zone=Zone Priv\u00E9e -label.privatekey=Cl\u00E9 priv\u00E9e PKCS\#8 -label.project=Projet +label.primary.storage.limits=Limites stockage principal (Go) +label.primary.storage=Premier stockage +label.primary.used=Stockage principal utilis\u00e9 +label.private.Gateway=Passerelle priv\u00e9e +label.private.interface=Interface priv\u00e9e +label.private.ip=Adresse IP Priv\u00e9e +label.private.ip.range=Plage d\\'adresses IP Priv\u00e9es +label.private.ips=Adresses IP Priv\u00e9es +label.privatekey=Cl\u00e9 priv\u00e9e PKCS\#8 +label.private.network=R\u00e9seau priv\u00e9 +label.private.port=Port priv\u00e9 +label.private.zone=Zone Priv\u00e9e label.project.dashboard=Tableau de bord projet label.project.id=ID projet label.project.invite=Inviter sur le projet label.project.name=Nom du projet -label.project.view=Vue projet +label.project=Projet label.projects=Projets +label.project.view=Vue projet label.protocol=Protocole label.providers=Fournisseurs -label.public=Publique label.public.interface=Interface publique label.public.ip=Adresse IP publique label.public.ips=Adresses IP publiques -label.public.network=R\u00E9seau public +label.public.network=R\u00e9seau public label.public.port=Port public +label.public=Publique label.public.traffic=Trafic public label.public.zone=Zone publique -label.purpose=R\u00F4le -label.quickview=Aper\u00E7u -label.reboot=Red\u00E9marrer -label.recent.errors=Erreurs r\u00E9centes -label.redundant.router=Routeur redondant +label.purpose=R\u00f4le +label.Pxe.server.type=Serveur PXE +label.quickview=Aper\u00e7u +label.reboot=Red\u00e9marrer +label.recent.errors=Erreurs r\u00e9centes label.redundant.router.capability=Router redondant -label.redundant.state=\u00C9tat de la redondance +label.redundant.router=Routeur redondant +label.redundant.state=\u00c9tat de la redondance label.refresh=Actualiser +label.region=R\u00e9gion label.related=Connexes label.remind.later=Rappeler moi plus tard -label.remove.ACL=Supprimer une r\u00E8gle ACL -label.remove.egress.rule=Supprimer la r\u00E8gle sortante -label.remove.from.load.balancer=Supprimer l\\'instance du r\u00E9partiteur de charge -label.remove.ingress.rule=Supprimer la r\u00E8gle entrante +label.remove.ACL=Supprimer une r\u00e8gle ACL +label.remove.egress.rule=Supprimer la r\u00e8gle sortante +label.remove.from.load.balancer=Supprimer l\\'instance du r\u00e9partiteur de charge +label.remove.ingress.rule=Supprimer la r\u00e8gle entrante label.remove.ip.range=Supprimer la plage IP -label.remove.pf=Supprimer la r\u00E8gle de transfert de port +label.remove.pf=Supprimer la r\u00e8gle de transfert de port label.remove.project.account=Supprimer le compte projet -label.remove.rule=Supprimer la r\u00E8gle +label.remove.region=Supprimer r\u00e9gion +label.remove.rule=Supprimer la r\u00e8gle label.remove.static.nat.rule=Supprimer le NAT statique label.remove.static.route=Supprimer une route statique label.remove.tier=Supprimer le tiers -label.remove.vm.from.lb=Supprimer la VM de la r\u00E8gle de r\u00E9partition de charge +label.remove.vm.from.lb=Supprimer la VM de la r\u00e8gle de r\u00e9partition de charge label.remove.vpc=Supprimer le VPC label.removing=Suppression label.removing.user=Retrait de l\\'utilisateur label.required=Requis -label.reserved.system.gateway=Passerelle r\u00E9serv\u00E9e Syst\u00E8me -label.reserved.system.ip=Adresse IP Syst\u00E8me r\u00E9serv\u00E9e -label.reserved.system.netmask=Masque de sous-r\u00E9seau r\u00E9serv\u00E9 Syst\u00E8me -label.reset.VPN.connection=R\u00E9-initialiser la connexion VPN +label.reserved.system.gateway=Passerelle r\u00e9serv\u00e9e Syst\u00e8me +label.reserved.system.ip=Adresse IP Syst\u00e8me r\u00e9serv\u00e9e +label.reserved.system.netmask=Masque de sous-r\u00e9seau r\u00e9serv\u00e9 Syst\u00e8me +label.reset.VPN.connection=R\u00e9-initialiser la connexion VPN label.resize.new.offering.id=Nouvelle Offre label.resize.new.size=Nouvelle Taille (Go) -label.resize.shrink.ok=R\u00E9duction OK -label.resource=Ressource +label.resize.shrink.ok=R\u00e9duction OK label.resource.limits=Limite des ressources -label.resource.state=\u00C9tat des ressources +label.resource=Ressource label.resources=Ressources -label.restart.network=Red\u00E9marrage du r\u00E9seau -label.restart.required=Red\u00E9marrage n\u00E9cessaire -label.restart.vpc=Red\u00E9marrer le VPC +label.resource.state=\u00c9tat des ressources +label.restart.network=Red\u00e9marrage du r\u00e9seau +label.restart.required=Red\u00e9marrage n\u00e9cessaire +label.restart.vpc=Red\u00e9marrer le VPC label.restore=Restaurer label.review=Revoir -label.revoke.project.invite=R\u00E9voquer l\\'invitation -label.role=R\u00F4le -label.root.disk.controller=Contr\u00F4leur de disque principal +label.revoke.project.invite=R\u00e9voquer l\\'invitation +label.role=R\u00f4le +label.root.disk.controller=Contr\u00f4leur de disque principal label.root.disk.offering=Offre de disque racine -label.round.robin=Al\u00E9atoire -label.rules=R\u00E8gles +label.round.robin=Al\u00e9atoire +label.rules=R\u00e8gles label.running.vms=VMs actives -label.s3.access_key=Cl\u00E9 d\\'Acc\u00E8s +label.s3.access_key=Cl\u00e9 d\\'Acc\u00e8s label.s3.bucket=Seau -label.s3.connection_timeout=D\u00E9lai d\\'expiration de connexion +label.s3.connection_timeout=D\u00e9lai d\\'expiration de connexion label.s3.endpoint=Terminaison -label.s3.max_error_retry=Nombre d\\'essai en erreur max. -label.s3.secret_key=Cl\u00E9 Priv\u00E9e -label.s3.socket_timeout=D\u00E9lai d\\'expiration de la socket +label.s3.max_error_retry=Nombre d\\'essai en erreur max. +label.s3.secret_key=Cl\u00e9 Priv\u00e9e +label.s3.socket_timeout=D\u00e9lai d\\'expiration de la socket label.s3.use_https=Utiliser HTTPS label.saturday=Samedi -label.save=Sauvegarder label.save.and.continue=Enregistrer et continuer +label.save=Sauvegarder label.saving.processing=Sauvegarde en cours... -label.scope=Port\u00E9e +label.scope=Port\u00e9e label.search=Rechercher -label.secondary.storage=Stockage secondaire label.secondary.storage.count=Groupes de stockage secondaire +label.secondary.storage.limits=Limites stockage secondaire (Go) +label.secondary.storage=Stockage secondaire label.secondary.storage.vm=VM stockage secondaire -label.secondary.used=Stockage secondaire utilis\u00E9 -label.secret.key=Cl\u00E9 priv\u00E9e -label.security.group=Groupe de s\u00E9curit\u00E9 -label.security.group.name=Nom du groupe de s\u00E9curit\u00E9 -label.security.groups=Groupes de s\u00E9curit\u00E9 -label.security.groups.enabled=Groupes de s\u00E9curit\u00E9 Activ\u00E9s -label.select=S\u00E9lectionner -label.select-view=S\u00E9lectionner la vue -label.select.a.template=S\u00E9lectionner un mod\u00E8le -label.select.a.zone=S\u00E9lectionner une zone -label.select.instance=S\u00E9lectionner une instance -label.select.instance.to.attach.volume.to=S\u00E9lectionner l\\'instance \u00E0 laquelle rattacher ce volume -label.select.iso.or.template=S\u00E9lectionner un ISO ou un mod\u00E8le -label.select.offering=S\u00E9lectionner une offre -label.select.project=S\u00E9lectionner un projet -label.select.tier=S\u00E9lectionner le tiers -label.select.vm.for.static.nat=S\u00E9lectionner une VM pour le NAT statique -label.sent=Envoy\u00E9 +label.secondary.used=Stockage secondaire utilis\u00e9 +label.secret.key=Cl\u00e9 priv\u00e9e +label.security.group=Groupe de s\u00e9curit\u00e9 +label.security.group.name=Nom du groupe de s\u00e9curit\u00e9 +label.security.groups.enabled=Groupes de s\u00e9curit\u00e9 Activ\u00e9s +label.security.groups=Groupes de s\u00e9curit\u00e9 +label.select.a.template=S\u00e9lectionner un mod\u00e8le +label.select.a.zone=S\u00e9lectionner une zone +label.select.instance=S\u00e9lectionner une instance +label.select.instance.to.attach.volume.to=S\u00e9lectionner l\\'instance \u00e0 laquelle rattacher ce volume +label.select.iso.or.template=S\u00e9lectionner un ISO ou un mod\u00e8le +label.select.offering=S\u00e9lectionner une offre +label.select.project=S\u00e9lectionner un projet +label.select=S\u00e9lectionner +label.select.tier=S\u00e9lectionner le tiers +label.select-view=S\u00e9lectionner la vue +label.select.vm.for.static.nat=S\u00e9lectionner une VM pour le NAT statique +label.sent=Envoy\u00e9 label.server=Serveur label.service.capabilities=Fonctions disponibles label.service.offering=Offre de Service -label.session.expired=Session expir\u00E9e -label.set.up.zone.type=Configurer le type de zone +label.session.expired=Session expir\u00e9e label.setup=Configuration -label.setup.network=Configurer le r\u00E9seau +label.setup.network=Configurer le r\u00e9seau label.setup.zone=Configurer la zone +label.set.up.zone.type=Configurer le type de zone label.shared=En partage -label.show.ingress.rule=Montrer la r\u00E8gle d\\'entr\u00E9e -label.shutdown.provider=\u00C9teindre ce fournisseur -label.site.to.site.VPN=VPN Site-\u00E0-Site +label.SharedMountPoint=Point de montage partag\u00e9 +label.show.ingress.rule=Montrer la r\u00e8gle d\\'entr\u00e9e +label.shutdown.provider=\u00c9teindre ce fournisseur +label.site.to.site.VPN=VPN Site-\u00e0-Site label.size=Taille -label.skip.guide=J\\'ai d\u00E9j\u00E0 utilis\u00E9 CloudStack avant, passer ce tutoriel -label.snapshot=Instantan\u00E9 -label.snapshot.limits=Limites d\\'instantan\u00E9s -label.snapshot.name=Nom Instantan\u00E9 -label.snapshot.s=Instantan\u00E9(s) -label.snapshot.schedule=Configurer un instantan\u00E9 r\u00E9current -label.snapshots=Instantan\u00E9s -label.source=Origine +label.skip.guide=J\\'ai d\u00e9j\u00e0 utilis\u00e9 CloudStack avant, passer ce tutoriel +label.snapshot=Instantan\u00e9 +label.snapshot.limits=Limites d\\'instantan\u00e9s +label.snapshot.name=Nom Instantan\u00e9 +label.snapshot.schedule=Configurer un instantan\u00e9 r\u00e9current +label.snapshot.s=Instantan\u00e9(s) +label.snapshots=Instantan\u00e9s label.source.nat=NAT Source -label.specify.IP.ranges=Sp\u00E9cifier des plages IP -label.specify.vlan=Pr\u00E9ciser le VLAN +label.source=Origine +label.specify.IP.ranges=Sp\u00e9cifier des plages IP +label.specify.vlan=Pr\u00e9ciser le VLAN +label.SR.name = Nom du point de montage label.srx=SRX -label.start.IP=Plage de d\u00E9but IP -label.start.port=Port de d\u00E9but -label.start.reserved.system.IP=Adresse IP de d\u00E9but r\u00E9serv\u00E9e Syst\u00E8me -label.start.vlan=VLAN de d\u00E9part -label.state=\u00C9tat +label.start.IP=Plage de d\u00e9but IP +label.start.port=Port de d\u00e9but +label.start.reserved.system.IP=Adresse IP de d\u00e9but r\u00e9serv\u00e9e Syst\u00e8me +label.start.vlan=VLAN de d\u00e9part +label.state=\u00c9tat +label.static.nat.enabled=NAT statique activ\u00e9 label.static.nat=NAT Statique -label.static.nat.enabled=NAT statique activ\u00E9 label.static.nat.to=NAT Statique vers -label.static.nat.vm.details=D\u00E9tails des NAT statique VM +label.static.nat.vm.details=D\u00e9tails des NAT statique VM label.statistics=Statistiques label.status=Statut -label.step.1=\u00C9tape 1 -label.step.1.title=\u00C9tape 1 \: S\u00E9lectionnez un mod\u00E8le -label.step.2=\u00C9tape 2 -label.step.2.title=\u00C9tape 2 \: Offre de Service -label.step.3=\u00C9tape 3 -label.step.3.title=\u00C9tape 3 \: S\u00E9lectionnez une offre de service -label.step.4=\u00C9tape 4 -label.step.4.title=\u00C9tape 4 \: R\u00E9seau -label.step.5=\u00C9tape 5 -label.step.5.title=\u00C9tape 5 \: V\u00E9rification -label.stickiness=Fid\u00E9lit\u00E9 +label.step.1.title=\u00c9tape 1 \: S\u00e9lectionnez un mod\u00e8le +label.step.1=\u00c9tape 1 +label.step.2.title=\u00c9tape 2 \: Offre de Service +label.step.2=\u00c9tape 2 +label.step.3.title=\u00c9tape 3 \: S\u00e9lectionnez une offre de service +label.step.3=\u00c9tape 3 +label.step.4.title=\u00c9tape 4 \: R\u00e9seau +label.step.4=\u00c9tape 4 +label.step.5.title=\u00c9tape 5 \: V\u00e9rification +label.step.5=\u00c9tape 5 +label.stickiness=Fid\u00e9lit\u00e9 label.sticky.cookie-name=Nom du cookie label.sticky.domain=Domaine label.sticky.expire=Expiration @@ -997,127 +1024,140 @@ label.sticky.indirect=Indirect label.sticky.length=Longueur label.sticky.mode=Mode label.sticky.nocache=Pas de cache -label.sticky.postonly=Apr\u00E8s seulement -label.sticky.prefix=Pr\u00E9fixe -label.sticky.request-learn=Apprendre la requ\u00EAte +label.sticky.postonly=Apr\u00e8s seulement +label.sticky.prefix=Pr\u00e9fixe +label.sticky.request-learn=Apprendre la requ\u00eate label.sticky.tablesize=Taille du tableau -label.stop=Arr\u00EAter -label.stopped.vms=VMs arr\u00EAt\u00E9es +label.stop=Arr\u00eater +label.stopped.vms=VMs arr\u00eat\u00e9es label.storage=Stockage -label.storage.tags=\u00C9tiquettes de stockage +label.storage.tags=\u00c9tiquettes de stockage label.storage.traffic=Trafic stockage label.storage.type=Type de stockage -label.subdomain.access=Acc\u00E8s sous-domaine +label.subdomain.access=Acc\u00e8s sous-domaine label.submit=Envoyer label.submitted.by=[Soumis par \: ] -label.succeeded=R\u00E9ussi +label.succeeded=R\u00e9ussi label.sunday=Dimanche -label.super.cidr.for.guest.networks=Super CIDR pour les r\u00E9seaux invit\u00E9s -label.supported.services=Services support\u00E9s -label.supported.source.NAT.type=Type de NAT support\u00E9 +label.super.cidr.for.guest.networks=Super CIDR pour les r\u00e9seaux invit\u00e9s +label.supported.services=Services support\u00e9s +label.supported.source.NAT.type=Type de NAT support\u00e9 label.suspend.project=Suspendre projet -label.system.capacity=Capacit\u00E9 syst\u00E8me -label.system.offering=Offre de syst\u00E8me -label.system.service.offering=Offre de Service Syst\u00E8me -label.system.vm=VM Syst\u00E8me -label.system.vm.type=Type de VM syst\u00E8me -label.system.vms=\ VMs Syst\u00E8mes -label.system.wide.capacity=Capacit\u00E9 globale -label.tagged=\u00C9tiquet\u00E9 -label.tags=\u00C9tiquette +label.system.capacity=Capacit\u00e9 syst\u00e8me +label.system.offering=Offre de syst\u00e8me +label.system.service.offering=Offre de Service Syst\u00e8me +label.system.vms=\ VMs Syst\u00e8mes +label.system.vm.type=Type de VM syst\u00e8me +label.system.vm=VM Syst\u00e8me +label.system.wide.capacity=Capacit\u00e9 globale +label.tagged=\u00c9tiquet\u00e9 +label.tags=\u00c9tiquette label.target.iqn=Cible IQN -label.task.completed=T\u00E2che termin\u00E9e -label.template=Mod\u00E8le -label.template.limits=Limites de mod\u00E8le -label.theme.default=Th\u00E8me par d\u00E9faut -label.theme.grey=Personnalis\u00E9 - Gris -label.theme.lightblue=Personnalis\u00E9 - Bleu clair +label.task.completed=T\u00e2che termin\u00e9e +label.template.limits=Limites de mod\u00e8le +label.template=Mod\u00e8le +label.TFTP.dir=R\u00e9pertoire TFTP +label.theme.default=Th\u00e8me par d\u00e9faut +label.theme.grey=Personnalis\u00e9 - Gris +label.theme.lightblue=Personnalis\u00e9 - Bleu clair label.thursday=Jeudi +label.tier.details=D\u00e9tails du tiers label.tier=Tiers -label.tier.details=D\u00E9tails du tiers +label.timeout=D\u00e9lai d\\'expiration +label.timeout.in.second = D\u00e9lai d\\'expiration (secondes) label.time=Temps label.time.zone=Fuseau horaire -label.timeout=D\u00E9lai d\\'expiration -label.timeout.in.second=D\u00E9lai d\\'expiration (secondes) label.timezone=Fuseau horaire label.token=Jeton unique -label.total.CPU=Capacit\u00E9 totale en CPU -label.total.cpu=Capacit\u00E9 Totale en CPU -label.total.hosts=Total H\u00F4tes -label.total.memory=Total m\u00E9moire +label.total.cpu=Capacit\u00e9 Totale en CPU +label.total.CPU=Capacit\u00e9 totale en CPU +label.total.hosts=Total H\u00f4tes +label.total.memory=Total m\u00e9moire label.total.of.ip=Total adresses IP label.total.of.vm=Total VM label.total.storage=Total stockage label.total.vms=Nombre total de VMs -label.traffic.label=Libell\u00E9 de trafic -label.traffic.type=Type de Trafic +label.traffic.label=Libell\u00e9 de trafic label.traffic.types=Types de trafic +label.traffic.type=Type de Trafic label.tuesday=Mardi -label.type=Type label.type.id=ID du Type +label.type=Type label.unavailable=Indisponible -label.unlimited=Illimit\u00E9 -label.untagged=Non Tagg\u00E9 -label.update.project.resources=Mettre \u00E0 jour les ressources du projet -label.update.ssl=Certificat SSL -label.update.ssl.cert=Certificat SSL -label.updating=Mise \u00E0 jour +label.unlimited=Illimit\u00e9 +label.untagged=Non Tagg\u00e9 +label.update.project.resources=Mettre \u00e0 jour les ressources du projet +label.update.ssl.cert= Certificat SSL +label.update.ssl= Certificat SSL +label.updating=Mise \u00e0 jour label.upload=Charger label.upload.volume=Charger un volume label.url=URL label.usage.interface=Interface Utilisation -label.used=Utilis\u00E9 -label.user=Utilisateur +label.used=Utilis\u00e9 label.username=Nom d\\'Utilisateur label.users=Utilisateurs +label.user=Utilisateur +label.use.vm.ip=Utiliser IP VM \: label.value=Valeur label.vcdcname=Nom du DC vCenter label.vcenter.cluster=Cluster vCenter label.vcenter.datacenter=Datacenter vCenter label.vcenter.datastore=Datastore vCenter -label.vcenter.host=H\u00F4te vCenter +label.vcenter.host=H\u00f4te vCenter label.vcenter.password=Mot de passe vCenter label.vcenter.username=Nom d\\'utilisateur vCenter label.vcipaddress=Adresse IP vCenter label.version=Version -label.view=Voir label.view.all=Voir tout label.view.console=Voir la console -label.view.more=Voir plus label.viewing=Consultation en cours +label.view.more=Voir plus +label.view=Voir label.virtual.appliance=Appliance Virtuelle label.virtual.appliances=Appliances Virtuelles label.virtual.machines=Machines virtuelles -label.virtual.network=R\u00E9seau virtuel +label.virtual.network=R\u00e9seau virtuel label.virtual.router=Routeur Virtuel label.virtual.routers=Routeurs virtuels -label.vlan=VLAN label.vlan.id=ID du VLAN label.vlan.range=Plage du VLAN +label.vlan=VLAN label.vm.add=Ajouter une instance -label.vm.destroy=D\u00E9truire +label.vm.destroy=D\u00e9truire label.vm.display.name=Nom commun VM -label.vm.name=Nom de la VM -label.vm.reboot=Red\u00E9marrer -label.vm.start=D\u00E9marrer -label.vm.state=\u00C9tat VM -label.vm.stop=Arr\u00EAter +label.VMFS.datastore=Magasin de donn\u00e9es VMFS label.vmfs=VMFS +label.vm.name=Nom de la VM +label.vm.reboot=Red\u00e9marrer +label.VMs.in.tier=Machines virtuelles dans le tiers +label.vmsnapshot.current=estCourant +label.vmsnapshot=Instantan\u00e9s VM +label.vmsnapshot.memory=M\u00e9more instantan\u00e9 +label.vmsnapshot.parentname=Parent +label.vmsnapshot.type=Type +label.vm.start=D\u00e9marrer +label.vm.state=\u00c9tat VM +label.vm.stop=Arr\u00eater label.vms=VMs -label.vmware.traffic.label=Libell\u00E9 pour le trafic VMware +label.vmware.traffic.label=Libell\u00e9 pour le trafic VMware label.volgroup=Groupe de Volume -label.volume=Volume label.volume.limits=Limites des volumes label.volume.name=Nom du volume label.volumes=Volumes -label.vpc=VPC +label.volume=Volume label.vpc.id=ID VPC -label.vpn=VPN +label.VPC.router.details=D\u00e9tails routeur VPC +label.vpc=VPC +label.VPN.connection=Connexion VPN label.vpn.customer.gateway=Passerelle VPN client -label.vsmctrlvlanid=\ ID VLAN Contr\u00F4le +label.VPN.customer.gateway=Passerelle VPN client +label.VPN.gateway=Passerelle VPN +label.vpn=VPN +label.vsmctrlvlanid=\ ID VLAN Contr\u00f4le label.vsmpktvlanid=ID VLAN Paquet label.vsmstoragevlanid=VLAN ID Stockage -label.vsphere.managed=G\u00E9r\u00E9e par vSphere +label.vsphere.managed=G\u00e9r\u00e9e par vSphere label.waiting=En attente label.warn=Avertissement label.wednesday=Mercredi @@ -1125,353 +1165,361 @@ label.weekly=Hebdomadaire label.welcome=Bienvenue label.welcome.cloud.console=Bienvenue dans la Console d\\'Administration label.what.is.cloudstack=Qu\\'est-ce-que CloudStack&\#8482; ? -label.xen.traffic.label=Libell\u00E9 pour le trafic XenServer +label.xen.traffic.label=Libell\u00e9 pour le trafic XenServer label.yes=Oui -label.zone=Zone -label.zone.details=D\u00E9tails de la zone +label.zone.details=D\u00e9tails de la zone label.zone.id=ID de la zone label.zone.name=Nom de zone -label.zone.step.1.title=\u00C9tape 1 \: S\u00E9lectionnez un r\u00E9seau -label.zone.step.2.title=\u00C9tape 2 \: Ajoutez une zone -label.zone.step.3.title=\u00C9tape 3 \: Ajoutez un Pod -label.zone.step.4.title=\u00C9tape 4 \: Ajoutez une plage d\\'adresses IP -label.zone.type=Type de zone -label.zone.wide=Transverse \u00E0 la zone -label.zoneWizard.trafficType.guest=Invit\u00E9 \: Trafic entre les machines virtuelles utilisateurs -label.zoneWizard.trafficType.management=Administration \: Trafic entre les ressources internes de CloudStack, incluant tous les composants qui communiquent avec le serveur d\\'administration, tels que les h\u00F4tes and les machines virtuelles Syst\u00E8mes CloudStack -label.zoneWizard.trafficType.public=Public \: Trafic entre Internet et les machines virtuelles dans le nuage -label.zoneWizard.trafficType.storage=Stockage \: Trafic entre les serveurs de stockages principaux et secondaires, tel que le transfert de machines virtuelles mod\u00E8les et des instantan\u00E9s de disques +label.zone.step.1.title=\u00c9tape 1 \: S\u00e9lectionnez un r\u00e9seau +label.zone.step.2.title=\u00c9tape 2 \: Ajoutez une zone +label.zone.step.3.title=\u00c9tape 3 \: Ajoutez un Pod +label.zone.step.4.title=\u00c9tape 4 \: Ajoutez une plage d\\'adresses IP label.zones=Zones -managed.state=\u00C9tat de la gestion -message.Zone.creation.complete=Cr\u00E9ation de la zone termin\u00E9e -message.acquire.new.ip=Confirmer l\\'acquisition d\\'une nouvelle adresse IP pour ce r\u00E9seau. +label.zone.type=Type de zone +label.zone.wide=Transverse \u00e0 la zone +label.zoneWizard.trafficType.guest=Invit\u00e9 \: Trafic entre les machines virtuelles utilisateurs +label.zoneWizard.trafficType.management=Administration \: Trafic entre les ressources internes de CloudStack, incluant tous les composants qui communiquent avec le serveur d\\'administration, tels que les h\u00f4tes and les machines virtuelles Syst\u00e8mes CloudStack +label.zoneWizard.trafficType.public=Public \: Trafic entre Internet et les machines virtuelles dans le nuage +label.zoneWizard.trafficType.storage=Stockage \: Trafic entre les serveurs de stockages principaux et secondaires, tel que le transfert de machines virtuelles mod\u00e8les et des instantan\u00e9s de disques +label.zone=Zone +managed.state=\u00c9tat de la gestion +message.acquire.new.ip=Confirmer l\\'acquisition d\\'une nouvelle adresse IP pour ce r\u00e9seau. message.acquire.new.ip.vpc=Veuillez confirmer que vous voulez une nouvelle adresse IP pour ce VPC -message.acquire.public.ip=S\u00E9lectionnez la zone dans laquelle vous voulez acqu\u00E9rir votre nouvelle adresse IP. -message.action.cancel.maintenance=Votre h\u00F4te a quitt\u00E9 la maintenance. Ce processus peut prendre jusqu\\'\u00E0 plusieurs minutes. +message.acquire.public.ip=S\u00e9lectionnez la zone dans laquelle vous voulez acqu\u00e9rir votre nouvelle adresse IP. message.action.cancel.maintenance.mode=Confirmer l\\'annulation de cette maintenance. -message.action.change.service.warning.for.instance=Votre instance doit \u00EAtre arr\u00EAt\u00E9e avant d\\'essayer de changer son offre de service. -message.action.change.service.warning.for.router=Votre routeur doit \u00EAtre arr\u00EAt\u00E9 avant d\\'essayer de changer son offre de service. -message.action.delete.ISO=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer cette ISO. -message.action.delete.ISO.for.all.zones=L\\'ISO est utilis\u00E9 par toutes les zones. S\\'il vous pla\u00EEt confirmer que vous voulez le supprimer de toutes les zones. -message.action.delete.cluster=\u00CAtes-vous s\u00FBr que vous voulez supprimer ce cluster. -message.action.delete.disk.offering=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer cette offre de disque. -message.action.delete.domain=\u00CAtes-vous s\u00FBr que vous voulez supprimer ce domaine. -message.action.delete.external.firewall=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer ce pare-feu externe. Attention \: Si vous pr\u00E9voyez de rajouter le m\u00EAme pare-feu externe de nouveau, vous devez r\u00E9-initialiser les donn\u00E9es d\\'utilisation sur l\\'appareil. -message.action.delete.external.load.balancer=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer ce r\u00E9partiteur de charge externe. Attention \: Si vous pensez ajouter le m\u00EAme r\u00E9partiteur de charge plus tard, vous devez remettre \u00E0 z\u00E9ro les statistiques d\\'utilisation de cet \u00E9quipement. -message.action.delete.ingress.rule=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer cette r\u00E8gle d\\'entr\u00E9e. -message.action.delete.network=\u00CAtes-vous s\u00FBr que vous voulez supprimer ce r\u00E9seau. +message.action.cancel.maintenance=Votre h\u00f4te a quitt\u00e9 la maintenance. Ce processus peut prendre jusqu\\'\u00e0 plusieurs minutes. +message.action.change.service.warning.for.instance=Votre instance doit \u00eatre arr\u00eat\u00e9e avant d\\'essayer de changer son offre de service. +message.action.change.service.warning.for.router=Votre routeur doit \u00eatre arr\u00eat\u00e9 avant d\\'essayer de changer son offre de service. +message.action.delete.cluster=\u00cates-vous s\u00fbr que vous voulez supprimer ce cluster. +message.action.delete.disk.offering=\u00cates-vous s\u00fbr que vous souhaitez supprimer cette offre de disque. +message.action.delete.domain=\u00cates-vous s\u00fbr que vous voulez supprimer ce domaine. +message.action.delete.external.firewall=\u00cates-vous s\u00fbr que vous souhaitez supprimer ce pare-feu externe. Attention \: Si vous pr\u00e9voyez de rajouter le m\u00eame pare-feu externe de nouveau, vous devez r\u00e9-initialiser les donn\u00e9es d\\'utilisation sur l\\'appareil. +message.action.delete.external.load.balancer=\u00cates-vous s\u00fbr que vous souhaitez supprimer ce r\u00e9partiteur de charge externe. Attention \: Si vous pensez ajouter le m\u00eame r\u00e9partiteur de charge plus tard, vous devez remettre \u00e0 z\u00e9ro les statistiques d\\'utilisation de cet \u00e9quipement. +message.action.delete.ingress.rule=\u00cates-vous s\u00fbr que vous souhaitez supprimer cette r\u00e8gle d\\'entr\u00e9e. +message.action.delete.ISO.for.all.zones=L\\'ISO est utilis\u00e9 par toutes les zones. S\\'il vous pla\u00eet confirmer que vous voulez le supprimer de toutes les zones. +message.action.delete.ISO=\u00cates-vous s\u00fbr que vous souhaitez supprimer cette ISO. +message.action.delete.network=\u00cates-vous s\u00fbr que vous voulez supprimer ce r\u00e9seau. message.action.delete.nexusVswitch=Confirmer la suppession de ce Nexus 1000v -message.action.delete.physical.network=Confirmer la suppression du r\u00E9seau physique -message.action.delete.pod=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer ce pod. -message.action.delete.primary.storage=\u00CAtes-vous s\u00FBr que vous voulez supprimer ce stockage principal. -message.action.delete.secondary.storage=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer ce stockage secondaire. -message.action.delete.security.group=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer ce groupe de s\u00E9curit\u00E9. -message.action.delete.service.offering=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer cette offre de service. -message.action.delete.snapshot=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer cet instantan\u00E9 -message.action.delete.system.service.offering=\u00CAtes-vous s\u00FBr que vous voulez supprimer l\\'offre syst\u00E8me. -message.action.delete.template=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer ce mod\u00E8le. -message.action.delete.template.for.all.zones=Ce mod\u00E8le est utilis\u00E9 par toutes les zones. \u00CAtes-vous s\u00FBr que vous souhaitez le supprimer de toutes les zones. -message.action.delete.volume=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer ce volume. -message.action.delete.zone=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer cette zone. -message.action.destroy.instance=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer cette instance. -message.action.destroy.systemvm=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer cette VM Syst\u00E8me. -message.action.disable.cluster=\u00CAtes-vous s\u00FBr que vous souhaitez d\u00E9sactiver ce cluster -message.action.disable.nexusVswitch=Confirmer la d\u00E9sactivation de ce Nexus 1000v -message.action.disable.physical.network=Confirmer l\\'activation de ce r\u00E9seau physique. -message.action.disable.pod=\u00CAtes-vous s\u00FBr que vous souhaitez d\u00E9sactiver ce Pod -message.action.disable.static.NAT=\u00CAtes-vous s\u00FBr que vous souhaitez d\u00E9sactiver le NAT statique. -message.action.disable.zone=\u00CAtes-vous s\u00FBr que vous souhaitez d\u00E9sactiver cette zone -message.action.download.iso=Confirmer le t\u00E9l\u00E9chargement de cet ISO -message.action.download.template=Confirmer le t\u00E9l\u00E9chargement de ce mod\u00E8le -message.action.enable.cluster=\u00CAtes-vous s\u00FBr que vous souhaitez activer ce cluster -message.action.enable.maintenance=Votre h\u00F4te a \u00E9t\u00E9 mis en mode maintenance avec succ\u00E8s. Ce processus peut durer plusieurs minutes ou plus, suivant le nombre de VMs actives sur cet h\u00F4te. +message.action.delete.physical.network=Confirmer la suppression du r\u00e9seau physique +message.action.delete.pod=\u00cates-vous s\u00fbr que vous souhaitez supprimer ce pod. +message.action.delete.primary.storage=\u00cates-vous s\u00fbr que vous voulez supprimer ce stockage principal. +message.action.delete.secondary.storage=\u00cates-vous s\u00fbr que vous souhaitez supprimer ce stockage secondaire. +message.action.delete.security.group=\u00cates-vous s\u00fbr que vous souhaitez supprimer ce groupe de s\u00e9curit\u00e9. +message.action.delete.service.offering=\u00cates-vous s\u00fbr que vous souhaitez supprimer cette offre de service. +message.action.delete.snapshot=\u00cates-vous s\u00fbr que vous souhaitez supprimer cet instantan\u00e9 +message.action.delete.system.service.offering=\u00cates-vous s\u00fbr que vous voulez supprimer l\\'offre syst\u00e8me. +message.action.delete.template.for.all.zones=Ce mod\u00e8le est utilis\u00e9 par toutes les zones. \u00cates-vous s\u00fbr que vous souhaitez le supprimer de toutes les zones. +message.action.delete.template=\u00cates-vous s\u00fbr que vous souhaitez supprimer ce mod\u00e8le. +message.action.delete.volume=\u00cates-vous s\u00fbr que vous souhaitez supprimer ce volume. +message.action.delete.zone=\u00cates-vous s\u00fbr que vous souhaitez supprimer cette zone. +message.action.destroy.instance=\u00cates-vous s\u00fbr que vous souhaitez supprimer cette instance. +message.action.destroy.systemvm=\u00cates-vous s\u00fbr que vous souhaitez supprimer cette VM Syst\u00e8me. +message.action.disable.cluster=\u00cates-vous s\u00fbr que vous souhaitez d\u00e9sactiver ce cluster +message.action.disable.nexusVswitch=Confirmer la d\u00e9sactivation de ce Nexus 1000v +message.action.disable.physical.network=Confirmer l\\'activation de ce r\u00e9seau physique. +message.action.disable.pod=\u00cates-vous s\u00fbr que vous souhaitez d\u00e9sactiver ce Pod +message.action.disable.static.NAT=\u00cates-vous s\u00fbr que vous souhaitez d\u00e9sactiver le NAT statique. +message.action.disable.zone=\u00cates-vous s\u00fbr que vous souhaitez d\u00e9sactiver cette zone +message.action.download.iso=Confirmer le t\u00e9l\u00e9chargement de cet ISO +message.action.download.template=Confirmer le t\u00e9l\u00e9chargement de ce mod\u00e8le +message.action.enable.cluster=\u00cates-vous s\u00fbr que vous souhaitez activer ce cluster +message.action.enable.maintenance=Votre h\u00f4te a \u00e9t\u00e9 mis en mode maintenance avec succ\u00e8s. Ce processus peut durer plusieurs minutes ou plus, suivant le nombre de VMs actives sur cet h\u00f4te. message.action.enable.nexusVswitch=Confirmer l\\'activation de ce Nexus 1000v -message.action.enable.physical.network=Confirmer l\\'activation de ce r\u00E9seau physique. -message.action.enable.pod=\u00CAtes-vous s\u00FBr que vous souhaitez activer ce Pod -message.action.enable.zone=\u00CAtes-vous s\u00FBr que vous souhaitez activer cette zone -message.action.force.reconnect=Votre h\u00F4te a \u00E9t\u00E9 forc\u00E9e \u00E0 se reconnecter avec succ\u00E8s. Ce processus peut prendre jusqu\\'\u00E0 plusieurs minutes. -message.action.host.enable.maintenance.mode=Activer le mode maintenance va causer la migration \u00E0 chaud de l\\'ensemble des instances de cet h\u00F4te sur les autres h\u00F4tes disponibles. +message.action.enable.physical.network=Confirmer l\\'activation de ce r\u00e9seau physique. +message.action.enable.pod=\u00cates-vous s\u00fbr que vous souhaitez activer ce Pod +message.action.enable.zone=\u00cates-vous s\u00fbr que vous souhaitez activer cette zone +message.action.force.reconnect=Votre h\u00f4te a \u00e9t\u00e9 forc\u00e9e \u00e0 se reconnecter avec succ\u00e8s. Ce processus peut prendre jusqu\\'\u00e0 plusieurs minutes. +message.action.host.enable.maintenance.mode=Activer le mode maintenance va causer la migration \u00e0 chaud de l\\'ensemble des instances de cet h\u00f4te sur les autres h\u00f4tes disponibles. message.action.instance.reset.password=Confirmer le changement du mot de passe ROOT pour cette machine virtuelle. -message.action.manage.cluster=\u00CAtes-vous s\u00FBr que vous souhaitez g\u00E9rer le cluster -message.action.primarystorage.enable.maintenance.mode=Attention \: placer ce stockage principal en mode maintenance va provoquer l\\'arr\u00EAt de l\\'ensemble des VMs utilisant des volumes sur ce stockage. Souhaitez-vous continuer ? -message.action.reboot.instance=\u00CAtes-vous s\u00FBr que vous souhaitez red\u00E9marrer cette instance. -message.action.reboot.router=Tous les services fournit par ce routeur virtuel vont \u00EAtre interrompus. Confirmer le r\u00E9-amor\u00E7age de ce routeur. -message.action.reboot.systemvm=\u00CAtes-vous s\u00FBr que vous souhaitez red\u00E9marrer cette VM Syst\u00E8me -message.action.release.ip=\u00CAtes-vous s\u00FBr que vous souhaitez lib\u00E9rer cette IP. -message.action.remove.host=\u00CAtes-vous s\u00FBr que vous voulez supprimer cet h\u00F4te. -message.action.reset.password.off=Votre instance ne supporte pas pour le moment cette fonctionnalit\u00E9. -message.action.reset.password.warning=Votre instance doit \u00EAtre arr\u00EAt\u00E9e avant d\\'essayer de changer son mot de passe. -message.action.restore.instance=\u00CAtes-vous s\u00FBr que vous souhaitez restaurer cette instance. -message.action.start.instance=\u00CAtes-vous s\u00FBr que vous souhaitez d\u00E9marrer cette instance. -message.action.start.router=\u00CAtes-vous s\u00FBr que vous souhaitez d\u00E9marrer ce routeur. -message.action.start.systemvm=\u00CAtes-vous s\u00FBr que vous souhaitez red\u00E9marrer cette VM syst\u00E8me. -message.action.stop.instance=\u00CAtes-vous s\u00FBr que vous souhaitez arr\u00EAter cette instance. -message.action.stop.router=Tous les services fournit par ce routeur virtuel vont \u00EAtre interrompus. Confirmer l\\'arr\u00EAt de ce routeur. -message.action.stop.systemvm=\u00CAtes-vous s\u00FBr que vous souhaitez arr\u00EAter cette VM. -message.action.take.snapshot=Confirmer la prise d\\'un instantan\u00E9 pour ce volume. -message.action.unmanage.cluster=Confirmez que vous ne voulez plus g\u00E9rer le cluster -message.activate.project=\u00CAtes-vous s\u00FBr de vouloir activer ce projet ? -message.add.VPN.gateway=Confirmer l\\'ajout d\\'une passerelle VPN -message.add.cluster=Ajouter un cluster d\\'hyperviseurs g\u00E9r\u00E9 pour cette zone , pod -message.add.cluster.zone=Ajouter un cluster d\\'hyperviseurs g\u00E9r\u00E9 pour cette zone -message.add.disk.offering=Renseignez les param\u00E8tres suivants pour ajouter un offre de service de disques -message.add.domain=Sp\u00E9cifier le sous domaine que vous souhaitez cr\u00E9er sous ce domaine -message.add.firewall=Ajouter un pare-feu \u00E0 cette zone -message.add.guest.network=Confirmer l\\'ajout du r\u00E9seau invit\u00E9 -message.add.host=Renseignez les param\u00E8tres suivants pour ajouter une h\u00F4te -message.add.ip.range=Ajouter une plage IP pour le r\u00E9seau publique dans la zone -message.add.ip.range.direct.network=Ajouter une plage IP au r\u00E9seau direct dans la zone -message.add.ip.range.to.pod=

Ajouter une plage IP pour le pod\:

-message.add.load.balancer=Ajouter un r\u00E9partiteur de charge \u00E0 la zone -message.add.load.balancer.under.ip=La r\u00E8gle de r\u00E9partition de charge \u00E9t\u00E9 ajout\u00E9e sous l\\'adresse IP \: -message.add.network=Ajouter un nouveau r\u00E9seau \u00E0 la zone\: -message.add.new.gateway.to.vpc=Renseigner les informations suivantes pour ajouter une nouvelle passerelle pour ce VPC -message.add.pod=Ajouter un nouveau pod \u00E0 la zone -message.add.pod.during.zone.creation=Chaque zone doit contenir un ou plusieurs pods, et le premier pod sera ajout\u00E9 maintenant. Une pod contient les h\u00F4tes et les serveurs de stockage principal, qui seront ajout\u00E9s dans une \u00E9tape ult\u00E9rieure. Configurer une plage d\\'adresses IP r\u00E9serv\u00E9es pour le trafic de gestion interne de CloudStack. La plage d\\'IP r\u00E9serv\u00E9e doit \u00EAtre unique pour chaque zone dans le nuage. -message.add.primary=Renseignez les param\u00E8tres suivants pour ajouter un stockage principal -message.add.primary.storage=Ajouter un nouveau stockage principal \u00E0 la zone , pod -message.add.secondary.storage=Ajouter un nouveau stockage pour la zone -message.add.service.offering=Renseigner les informations suivantes pour ajouter une nouvelle offre de service de calcul. -message.add.system.service.offering=Ajouter les informations suivantes pour cr\u00E9er une nouvelle offre syst\u00E8me. -message.add.template=Renseignez les informations suivantes pour cr\u00E9er votre nouveau mod\u00E8le -message.add.volume=Renseignez les informations suivantes pour ajouter un nouveau volume +message.action.manage.cluster=\u00cates-vous s\u00fbr que vous souhaitez g\u00e9rer le cluster +message.action.primarystorage.enable.maintenance.mode=Attention \: placer ce stockage principal en mode maintenance va provoquer l\\'arr\u00eat de l\\'ensemble des VMs utilisant des volumes sur ce stockage. Souhaitez-vous continuer ? +message.action.reboot.instance=\u00cates-vous s\u00fbr que vous souhaitez red\u00e9marrer cette instance. +message.action.reboot.router=Tous les services fournit par ce routeur virtuel vont \u00eatre interrompus. Confirmer le r\u00e9-amor\u00e7age de ce routeur. +message.action.reboot.systemvm=\u00cates-vous s\u00fbr que vous souhaitez red\u00e9marrer cette VM Syst\u00e8me +message.action.release.ip=\u00cates-vous s\u00fbr que vous souhaitez lib\u00e9rer cette IP. +message.action.remove.host=\u00cates-vous s\u00fbr que vous voulez supprimer cet h\u00f4te. +message.action.reset.password.off=Votre instance ne supporte pas pour le moment cette fonctionnalit\u00e9. +message.action.reset.password.warning=Votre instance doit \u00eatre arr\u00eat\u00e9e avant d\\'essayer de changer son mot de passe. +message.action.restore.instance=\u00cates-vous s\u00fbr que vous souhaitez restaurer cette instance. +message.action.start.instance=\u00cates-vous s\u00fbr que vous souhaitez d\u00e9marrer cette instance. +message.action.start.router=\u00cates-vous s\u00fbr que vous souhaitez d\u00e9marrer ce routeur. +message.action.start.systemvm=\u00cates-vous s\u00fbr que vous souhaitez red\u00e9marrer cette VM syst\u00e8me. +message.action.stop.instance=\u00cates-vous s\u00fbr que vous souhaitez arr\u00eater cette instance. +message.action.stop.router=Tous les services fournit par ce routeur virtuel vont \u00eatre interrompus. Confirmer l\\'arr\u00eat de ce routeur. +message.action.stop.systemvm=\u00cates-vous s\u00fbr que vous souhaitez arr\u00eater cette VM. +message.action.take.snapshot=Confirmer la prise d\\'un instantan\u00e9 pour ce volume. +message.action.unmanage.cluster=Confirmez que vous ne voulez plus g\u00e9rer le cluster +message.action.vmsnapshot.delete=Confirmez que vous souhaitez supprimer cet instantan\u00e9 VM. +message.action.vmsnapshot.revert=Revenir \u00e0 un instantan\u00e9 VM +message.activate.project=\u00cates-vous s\u00fbr de vouloir activer ce projet ? +message.add.cluster=Ajouter un cluster d\\'hyperviseurs g\u00e9r\u00e9 pour cette zone , pod +message.add.cluster.zone=Ajouter un cluster d\\'hyperviseurs g\u00e9r\u00e9 pour cette zone +message.add.disk.offering=Renseignez les param\u00e8tres suivants pour ajouter un offre de service de disques +message.add.domain=Sp\u00e9cifier le sous domaine que vous souhaitez cr\u00e9er sous ce domaine +message.add.firewall=Ajouter un pare-feu \u00e0 cette zone +message.add.guest.network=Confirmer l\\'ajout du r\u00e9seau invit\u00e9 +message.add.host=Renseignez les param\u00e8tres suivants pour ajouter une h\u00f4te +message.adding.host=Ajout un h\u00f4te message.adding.Netscaler.device=Ajouter un Netscaler message.adding.Netscaler.provider=Ajouter un fournisseur Netscaler -message.adding.host=Ajout un h\u00F4te -message.additional.networks.desc=S\u00E9lectionnez le(s) r\u00E9seau(x) additionnel(s) au(x)quel(s) sera connect\u00E9e votre instance. -message.advanced.mode.desc=Choisissez ce mod\u00E8le de r\u00E9seau si vous souhaitez b\u00E9n\u00E9ficier du support des VLANs. Ce mode de r\u00E9seau donne le plus de flexibilit\u00E9 aux administrateurs pour fournir des offres de service r\u00E9seau personnalis\u00E9es comme fournir des pare-feux, VPN, r\u00E9partiteurs de charge ou \u00E9galement activer des r\u00E9seaux virtuels ou directs. -message.advanced.security.group=Choisissez ceci si vous souhaitez utiliser les groupes de s\u00E9curit\u00E9 pour fournir l\\'isolation des VMs invit\u00E9es. -message.advanced.virtual=Choisissez ceci si vous souhaitez utiliser des VLANs pour fournir l\\'isolation des VMs invit\u00E9es. -message.after.enable.s3=Le stockage secondaire S3 est configur\u00E9. Note \: Quand vous quitterez cette page, vous ne pourrez plus re-configurer le support S3. -message.after.enable.swift=Swift configur\u00E9. Remarque \: une fois que vous quitterez cette page, il ne sera plus possible de re-configurer Swift \u00E0 nouveau. -message.alert.state.detected=\u00C9tat d\\'alerte d\u00E9tect\u00E9 -message.allow.vpn.access=Entrez un nom d\\'utilisateur et un mot de passe pour l\\'utilisateur que vous souhaitez autoriser \u00E0 utiliser l\\'acc\u00E8s VPN. -message.apply.snapshot.policy=Vous avez mis \u00E0 jour votre politique d\\'instantan\u00E9s avec succ\u00E8s. -message.attach.iso.confirm=\u00CAtes-vous s\u00FBr que vous souhaitez attacher l\\'image ISO \u00E0 cette instance. -message.attach.volume=Renseignez les donn\u00E9es suivantes pour attacher un nouveau volume. Si vous attachez un volume disque \u00E0 une machine virtuelle sous Windows, vous aurez besoin de red\u00E9marrer l\\'instance pour voir le nouveau disque. -message.basic.mode.desc=Choisissez ce mod\u00E8le de r\u00E9seau si vous *ne voulez pas* activer le support des VLANs. Toutes les instances cr\u00E9\u00E9es avec ce mod\u00E8le de r\u00E9seau se verront assigner une adresse IP et les groupes de s\u00E9curit\u00E9 seront utilis\u00E9s pour fournir l\\'isolation entre les VMs. -message.change.offering.confirm=\u00CAtes-vous s\u00FBr que vous souhaitez changer l\\'offre de service de cette instance. +message.add.ip.range=Ajouter une plage IP pour le r\u00e9seau publique dans la zone +message.add.ip.range.direct.network=Ajouter une plage IP au r\u00e9seau direct dans la zone +message.add.ip.range.to.pod=

Ajouter une plage IP pour le pod\:

+message.additional.networks.desc=S\u00e9lectionnez le(s) r\u00e9seau(x) additionnel(s) au(x)quel(s) sera connect\u00e9e votre instance. +message.add.load.balancer=Ajouter un r\u00e9partiteur de charge \u00e0 la zone +message.add.load.balancer.under.ip=La r\u00e8gle de r\u00e9partition de charge \u00e9t\u00e9 ajout\u00e9e sous l\\'adresse IP \: +message.add.network=Ajouter un nouveau r\u00e9seau \u00e0 la zone\: +message.add.new.gateway.to.vpc=Renseigner les informations suivantes pour ajouter une nouvelle passerelle pour ce VPC +message.add.pod=Ajouter un nouveau pod \u00e0 la zone +message.add.pod.during.zone.creation=Chaque zone doit contenir un ou plusieurs pods, et le premier pod sera ajout\u00e9 maintenant. Une pod contient les h\u00f4tes et les serveurs de stockage primaire, qui seront ajout\u00e9s dans une \u00e9tape ult\u00e9rieure. Configurer une plage d\\'adresses IP r\u00e9serv\u00e9es pour le trafic de gestion interne de CloudStack. La plage d\\'IP r\u00e9serv\u00e9e doit \u00eatre unique pour chaque zone dans le nuage. +message.add.primary=Renseignez les param\u00e8tres suivants pour ajouter un stockage principal +message.add.primary.storage=Ajouter un nouveau stockage principal \u00e0 la zone , pod +message.add.region=Renseigner les informations suivantes pour ajouter une nouvelle r\u00e9gion. +message.add.secondary.storage=Ajouter un nouveau stockage pour la zone +message.add.service.offering=Renseigner les informations suivantes pour ajouter une nouvelle offre de service de calcul. +message.add.system.service.offering=Ajouter les informations suivantes pour cr\u00e9er une nouvelle offre syst\u00e8me. +message.add.template=Renseignez les informations suivantes pour cr\u00e9er votre nouveau mod\u00e8le +message.add.volume=Renseignez les informations suivantes pour ajouter un nouveau volume +message.add.VPN.gateway=Confirmer l\\'ajout d\\'une passerelle VPN +message.advanced.mode.desc=Choisissez ce mod\u00e8le de r\u00e9seau si vous souhaitez b\u00e9n\u00e9ficier du support des VLANs. Ce mode de r\u00e9seau donne le plus de flexibilit\u00e9 aux administrateurs pour fournir des offres de service r\u00e9seau personnalis\u00e9es comme fournir des pare-feux, VPN, r\u00e9partiteurs de charge ou \u00e9galement activer des r\u00e9seaux virtuels ou directs. +message.advanced.security.group=Choisissez ceci si vous souhaitez utiliser les groupes de s\u00e9curit\u00e9 pour fournir l\\'isolation des VMs invit\u00e9es. +message.advanced.virtual=Choisissez ceci si vous souhaitez utiliser des VLANs pour fournir l\\'isolation des VMs invit\u00e9es. +message.after.enable.s3=Le stockage secondaire S3 est configur\u00e9. Note \: Quand vous quitterez cette page, vous ne pourrez plus re-configurer le support S3. +message.after.enable.swift=Swift configur\u00e9. Remarque \: une fois que vous quitterez cette page, il ne sera plus possible de re-configurer Swift \u00e0 nouveau. +message.alert.state.detected=\u00c9tat d\\'alerte d\u00e9tect\u00e9 +message.allow.vpn.access=Entrez un nom d\\'utilisateur et un mot de passe pour l\\'utilisateur que vous souhaitez autoriser \u00e0 utiliser l\\'acc\u00e8s VPN. +message.apply.snapshot.policy=Vous avez mis \u00e0 jour votre politique d\\'instantan\u00e9s avec succ\u00e8s. +message.attach.iso.confirm=\u00cates-vous s\u00fbr que vous souhaitez attacher l\\'image ISO \u00e0 cette instance. +message.attach.volume=Renseignez les donn\u00e9es suivantes pour attacher un nouveau volume. Si vous attachez un volume disque \u00e0 une machine virtuelle sous Windows, vous aurez besoin de red\u00e9marrer l\\'instance pour voir le nouveau disque. +message.basic.mode.desc=Choisissez ce mod\u00e8le de r\u00e9seau si vous *ne voulez pas* activer le support des VLANs. Toutes les instances cr\u00e9\u00e9es avec ce mod\u00e8le de r\u00e9seau se verront assigner une adresse IP et les groupes de s\u00e9curit\u00e9 seront utilis\u00e9s pour fournir l\\'isolation entre les VMs. +message.change.offering.confirm=\u00cates-vous s\u00fbr que vous souhaitez changer l\\'offre de service de cette instance. message.change.password=Merci de modifier votre mot de passe. -message.configure.all.traffic.types=Vous avez de multiples r\u00E9seaux physiques ; veuillez configurer les libell\u00E9s pour chaque type de trafic en cliquant sur le bouton Modifier. -message.configuring.guest.traffic=Configuration du r\u00E9seau VM -message.configuring.physical.networks=Configuration des r\u00E9seaux physiques -message.configuring.public.traffic=Configuration du r\u00E9seau public -message.configuring.storage.traffic=Configuration du r\u00E9seau de stockage -message.confirm.action.force.reconnect=Confirmer la re-connexion forc\u00E9e de cet h\u00F4te. +message.configure.all.traffic.types=Vous avez de multiples r\u00e9seaux physiques ; veuillez configurer les libell\u00e9s pour chaque type de trafic en cliquant sur le bouton Modifier. +message.configuring.guest.traffic=Configuration du r\u00e9seau VM +message.configuring.physical.networks=Configuration des r\u00e9seaux physiques +message.configuring.public.traffic=Configuration du r\u00e9seau public +message.configuring.storage.traffic=Configuration du r\u00e9seau de stockage +message.confirm.action.force.reconnect=Confirmer la re-connexion forc\u00e9e de cet h\u00f4te. message.confirm.delete.F5=Confirmer la suppression du F5 message.confirm.delete.NetScaler=Confirmer la suppression du Netscaler message.confirm.delete.SRX=Confirmer la suppression du SRX -message.confirm.destroy.router=\u00CAtes-vous s\u00FBr que vous voulez supprimer ce routeur -message.confirm.disable.provider=Confirmer la d\u00E9sactivation de ce fournisseur +message.confirm.destroy.router=\u00cates-vous s\u00fbr que vous voulez supprimer ce routeur +message.confirm.disable.provider=Confirmer la d\u00e9sactivation de ce fournisseur message.confirm.enable.provider=Confirmer l\\'activation de ce fournisseur -message.confirm.join.project=\u00CAtes-vous s\u00FBr que vous souhaitez rejoindre ce projet. -message.confirm.remove.IP.range=\u00CAtes-vous s\u00FBr que vous voulez supprimer cette plage d\\'adresses IP -message.confirm.shutdown.provider=Confirmer l\\'arr\u00EAt de ce fournisseur -message.copy.iso.confirm=\u00CAtes-vous s\u00FBr que vous souhaitez copier votre image ISO vers -message.copy.template=Copier le mod\u00E8le XXX de la zone vers -message.create.template=Voulez vous cr\u00E9er un mod\u00E8le ? -message.create.template.vm=Cr\u00E9er la VM depuis le mod\u00E8le -message.create.template.volume=Renseignez les informations suivantes avec de cr\u00E9er un mod\u00E8le \u00E0 partir de votre volume de disque\:. La cr\u00E9ation du mod\u00E8le peut prendre plusieurs minutes suivant la taille du volume. -message.creating.cluster=Cr\u00E9ation du cluster -message.creating.guest.network=Cr\u00E9ation du r\u00E9seau pour les invit\u00E9s -message.creating.physical.networks=Cr\u00E9ation des r\u00E9seaux physiques -message.creating.pod=Cr\u00E9ation d\\'un pod -message.creating.primary.storage=Cr\u00E9ation du stockage principal -message.creating.secondary.storage=Cr\u00E9ation du stockage secondaire -message.creating.zone=Cr\u00E9ation de la zone +message.confirm.join.project=\u00cates-vous s\u00fbr que vous souhaitez rejoindre ce projet. +message.confirm.remove.IP.range=\u00cates-vous s\u00fbr que vous voulez supprimer cette plage d\\'adresses IP +message.confirm.shutdown.provider=Confirmer l\\'arr\u00eat de ce fournisseur +message.copy.iso.confirm=\u00cates-vous s\u00fbr que vous souhaitez copier votre image ISO vers +message.copy.template=Copier le mod\u00e8le XXX de la zone vers +message.create.template.vm=Cr\u00e9er la VM depuis le mod\u00e8le +message.create.template.volume=Renseignez les informations suivantes avec de cr\u00e9er un mod\u00e8le \u00e0 partir de votre volume de disque\:. La cr\u00e9ation du mod\u00e8le peut prendre plusieurs minutes suivant la taille du volume. +message.create.template=Voulez vous cr\u00e9er un mod\u00e8le ? +message.creating.cluster=Cr\u00e9ation du cluster +message.creating.guest.network=Cr\u00e9ation du r\u00e9seau pour les invit\u00e9s +message.creating.physical.networks=Cr\u00e9ation des r\u00e9seaux physiques +message.creating.pod=Cr\u00e9ation d\\'un pod +message.creating.primary.storage=Cr\u00e9ation du stockage principal +message.creating.secondary.storage=Cr\u00e9ation du stockage secondaire +message.creating.zone=Cr\u00e9ation de la zone message.decline.invitation=Voulez-vous refuser cette invitation au projet ? -message.delete.VPN.connection=\u00CAtes-vous s\u00FBr que vous voulez supprimer la connexion VPN -message.delete.VPN.customer.gateway=\u00CAtes-vous s\u00FBr que vous voulez supprimer cette passerelle VPN client -message.delete.VPN.gateway=\u00CAtes-vous s\u00FBr que vous voulez supprimer cette passerelle VPN -message.delete.account=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer ce compte. -message.delete.gateway=\u00CAtes-vous s\u00FBr que vous voulez supprimer cette passerelle -message.delete.project=\u00CAtes-vous s\u00FBr de vouloir supprimer ce projet ? -message.delete.user=\u00CAtes-vous s\u00FBr que vous voulez supprimer cet utilisateur. -message.desc.advanced.zone=Pour des topologies de r\u00E9seau plus sophistiqu\u00E9es. Ce mod\u00E8le de r\u00E9seau permet plus de flexibilit\u00E9 dans la d\u00E9finition des r\u00E9seaux d\\'invit\u00E9s et propose des offres personnalis\u00E9es telles que le support de pare-feu, VPN ou d\\'\u00E9quilibrage de charge. -message.desc.basic.zone=Fournit un r\u00E9seau unique o\u00F9 chaque instance de machine virtuelle se voit attribuer une adresse IP directement depuis le r\u00E9seau. L\\'isolation des invit\u00E9s peut \u00EAtre assur\u00E9 au niveau de la couche r\u00E9seau-3 tels que les groupes de s\u00E9curit\u00E9 (filtrage d\\'adresse IP source). -message.desc.cluster=Chaque pod doit contenir un ou plusieurs clusters, et le premier cluster sera ajout\u00E9 tout de suite. Un cluster est un regroupement pour h\u00F4tes. Les h\u00F4tes d\\'un cluster ont tous un mat\u00E9riel identique, ex\u00E9cutent le m\u00EAme hyperviseur, sont dans le m\u00EAme sous-r\u00E9seau, et acc\u00E8dent au m\u00EAme stockage partag\u00E9. Chaque cluster comprend une ou plusieurs h\u00F4tes et un ou plusieurs serveurs de stockage principal. -message.desc.host=Chaque cluster doit contenir au moins un h\u00F4te (machine) pour ex\u00E9cuter des machines virtuelles invit\u00E9es, et le premier h\u00F4te sera ajout\u00E9 tout de suite. Pour un h\u00F4te fonctionnant dans CloudStack, vous devez installer un logiciel hyperviseur sur l\\'h\u00F4te, attribuer une adresse IP \u00E0 l\\'h\u00F4te, et s\\'assurer que l\\'h\u00F4te est connect\u00E9 au serveur d\\'administration CloudStack.

Indiquer le nom de l\\'h\u00F4te ou son adresse IP, l\\'identifiant de connexion (g\u00E9n\u00E9ralement root) et le mot de passe ainsi que toutes les \u00E9tiquettes permettant de classer les h\u00F4tes. -message.desc.primary.storage=Chaque cluster doit contenir un ou plusieurs serveurs de stockage principal, et le premier sera ajout\u00E9 tout de suite. Le stockage principal contient les volumes de disque pour les machines virtuelles s\\'ex\u00E9cutant sur les h\u00F4tes dans le cluster. Utiliser les protocoles standards pris en charge par l\\'hyperviseur sous-jacent. -message.desc.secondary.storage=Chaque zone doit avoir au moins un serveur NFS ou un serveur de stockage secondaire, et sera ajout\u00E9 en premier tout de suite. Le stockage secondaire entrepose les mod\u00E8les de machines virtuelles, les images ISO et les images disques des volumes des machines virtuelles. Ce serveur doit \u00EAtre accessible pour toutes les machines h\u00F4tes dans la zone.

Saisir l\\'adresse IP et le chemin d\\'export. -message.desc.zone=Une zone est la plus grande unit\u00E9 organisationnelle dans CloudStack, et correspond typiquement \u00E0 un centre de donn\u00E9es. Les zones fournissent un isolement physique et de la redondance. Une zone est constitu\u00E9e d\\'un ou plusieurs pods (dont chacun contient les h\u00F4tes et les serveurs de stockage principal) et un serveur de stockage secondaire qui est partag\u00E9e par tous les pods dans la zone. -message.detach.disk=Voulez-vous d\u00E9tacher ce disque ? -message.detach.iso.confirm=\u00CAtes-vous s\u00FBr que vous souhaitez d\u00E9tacher l\\'image ISO de cette instance. -message.disable.account=Veuillez confirmer que vous voulez d\u00E9sactiver ce compte. En d\u00E9sactivant le compte, tous les utilisateurs pour ce compte n\\'auront plus acc\u00E8s \u00E0 leurs ressources sur le cloud. Toutes les machines virtuelles vont \u00EAtre arr\u00EAt\u00E9es imm\u00E9diatement. -message.disable.snapshot.policy=Vous avez d\u00E9sactiv\u00E9 votre politique d\\'instantan\u00E9 avec succ\u00E8s. -message.disable.user=Confirmer la d\u00E9sactivation de cet utilisateur. -message.disable.vpn=\u00CAtes-vous s\u00FBr de vouloir d\u00E9sactiver le VPN ? -message.disable.vpn.access=\u00CAtes-vous s\u00FBr que vous souhaitez d\u00E9sactiver l\\'acc\u00E8s VPN. -message.download.ISO=Cliquer 00000 pour t\u00E9l\u00E9charger une image ISO -message.download.template=Cliquer sur 00000 pour t\u00E9l\u00E9charger le mod\u00E8le -message.download.volume=Cliquer sur 00000 pour t\u00E9l\u00E9charger le volume -message.download.volume.confirm=Confirmer le t\u00E9l\u00E9chargement du volume +message.delete.account=\u00cates-vous s\u00fbr que vous souhaitez supprimer ce compte. +message.delete.affinity.group=Confirmer la supression de ce groupe d\\'affinit\u00e9. +message.delete.gateway=\u00cates-vous s\u00fbr que vous voulez supprimer cette passerelle +message.delete.project=\u00cates-vous s\u00fbr de vouloir supprimer ce projet ? +message.delete.user=\u00cates-vous s\u00fbr que vous voulez supprimer cet utilisateur. +message.delete.VPN.connection=\u00cates-vous s\u00fbr que vous voulez supprimer la connexion VPN +message.delete.VPN.customer.gateway=\u00cates-vous s\u00fbr que vous voulez supprimer cette passerelle VPN client +message.delete.VPN.gateway=\u00cates-vous s\u00fbr que vous voulez supprimer cette passerelle VPN +message.desc.advanced.zone=Pour des topologies de r\u00e9seau plus sophistiqu\u00e9es. Ce mod\u00e8le de r\u00e9seau permet plus de flexibilit\u00e9 dans la d\u00e9finition des r\u00e9seaux d\\'invit\u00e9s et propose des offres personnalis\u00e9es telles que le support de pare-feu, VPN ou d\\'\u00e9quilibrage de charge. +message.desc.basic.zone=Fournit un r\u00e9seau unique o\u00f9 chaque instance de machine virtuelle se voit attribuer une adresse IP directement depuis le r\u00e9seau. L\\'isolation des invit\u00e9s peut \u00eatre assur\u00e9 au niveau de la couche r\u00e9seau-3 tels que les groupes de s\u00e9curit\u00e9 (filtrage d\\'adresse IP source). +message.desc.cluster=Chaque pod doit contenir un ou plusieurs clusters, et le premier cluster sera ajout\u00e9 tout de suite. Un cluster est un regroupement pour h\u00f4tes. Les h\u00f4tes d\\'un cluster ont tous un mat\u00e9riel identique, ex\u00e9cutent le m\u00eame hyperviseur, sont dans le m\u00eame sous-r\u00e9seau, et acc\u00e8dent au m\u00eame stockage partag\u00e9. Chaque cluster comprend une ou plusieurs h\u00f4tes et un ou plusieurs serveurs de stockage principal. +message.desc.host=Chaque cluster doit contenir au moins un h\u00f4te (machine) pour ex\u00e9ctuer des machines virtuelles invit\u00e9es, et le premier h\u00f4te sera ajout\u00e9e maintenant. Pour un h\u00f4te fonctionnant dans CloudStack, vous devez installer un logiciel hyperviseur sur l\\'h\u00f4te, attribuer une adresse IP \u00e0 l\\'h\u00f4te, et s\\'assurer que l\\'h\u00f4te est connect\u00e9 au serveur d\\'administration CloudStack.

Indiquer le nom de l\\'h\u00f4te ou son adresse IP, l\\'identifiant de connexion (g\u00e9n\u00e9ralement root) et le mot de passe ainsi que toutes les \u00e9tiquettes permettant de classer les h\u00f4tes. +message.desc.primary.storage=Chaque cluster doit contenir un ou plusieurs serveurs de stockage principal, et le premier sera ajout\u00e9 tout de suite. Le stockage principal contient les volumes de disque pour les machines virtuelles s\\'ex\u00e9cutant sur les h\u00f4tes dans le cluster. Utiliser les protocoles standards pris en charge par l\\'hyperviseur sous-jacent. +message.desc.secondary.storage=Chaque zone doit avoir au moins un serveur NFS ou un serveur de stockage secondaire, et sera ajout\u00e9 en premier tout de suite. Le stockage secondaire entrepose les mod\u00e8les de machines virtuelles, les images ISO et les images disques des volumes des machines virtuelles. Ce serveur doit \u00eatre accessible pour toutes les machines h\u00f4tes dans la zone.

Saisir l\\'adresse IP et le chemin d\\'export. +message.desc.zone=Une zone est la plus grande unit\u00e9 organisationnelle dans CloudStack, et correspond typiquement \u00e0 un centre de donn\u00e9es. Les zones fournissent un isolement physique et de la redondance. Une zone est constitu\u00e9e d\\'un ou plusieurs pods (dont chacun contient les h\u00f4tes et les serveurs de stockage principal) et un serveur de stockage secondaire qui est partag\u00e9e par tous les pods dans la zone. +message.detach.disk=Voulez-vous d\u00e9tacher ce disque ? +message.detach.iso.confirm=\u00cates-vous s\u00fbr que vous souhaitez d\u00e9tacher l\\'image ISO de cette instance. +message.disable.account=Veuillez confirmer que vous voulez d\u00e9sactiver ce compte. En d\u00e9sactivant le compte, tous les utilisateurs pour ce compte n\\'auront plus acc\u00e8s \u00e0 leurs ressources sur le cloud. Toutes les machines virtuelles vont \u00eatre arr\u00eat\u00e9es imm\u00e9diatement. +message.disable.snapshot.policy=Vous avez d\u00e9sactiv\u00e9 votre politique d\\'instantan\u00e9 avec succ\u00e8s. +message.disable.user=Confirmer la d\u00e9sactivation de cet utilisateur. +message.disable.vpn.access=\u00cates-vous s\u00fbr que vous souhaitez d\u00e9sactiver l\\'acc\u00e8s VPN. +message.disable.vpn=\u00cates-vous s\u00fbr de vouloir d\u00e9sactiver le VPN ? +message.download.ISO=Cliquer 00000 pour t\u00e9l\u00e9charger une image ISO +message.download.template=Cliquer sur 00000 pour t\u00e9l\u00e9charger le mod\u00e8le +message.download.volume=Cliquer sur 00000 pour t\u00e9l\u00e9charger le volume +message.download.volume.confirm=Confirmer le t\u00e9l\u00e9chargement du volume message.edit.account=Modifier ("-1" signifie pas de limite de ressources) message.edit.confirm=Confirmer les changements avant de cliquer sur "Enregistrer". -message.edit.limits=Renseignez les limites pour les ressources suivantes. "-1" indique qu\\'il n\\'y a pas de limites pour la cr\u00E9ation de ressources. -message.edit.traffic.type=Sp\u00E9cifier le libell\u00E9 de trafic associ\u00E9 avec ce type de trafic. -message.enable.account=\u00CAtes-vous s\u00FBr que vous souhaitez activer ce compte. +message.edit.limits=Renseignez les limites pour les ressources suivantes. "-1" indique qu\\'il n\\'y a pas de limites pour la cr\u00e9ation de ressources. +message.edit.traffic.type=Sp\u00e9cifier le libell\u00e9 de trafic associ\u00e9 avec ce type de trafic. +message.enable.account=\u00cates-vous s\u00fbr que vous souhaitez activer ce compte. +message.enabled.vpn.ip.sec=Votre cl\u00e9 partag\u00e9e IPSec est +message.enabled.vpn=Votre acc\u00e8s VPN est activ\u00e9 et peut \u00eatre acc\u00e9d\u00e9 par l\\'IP message.enable.user=Confirmer l\\'activation de cet utilisateur. -message.enable.vpn=Confirmer l\\'activation de l\\'acc\u00E8s VPN pour cette adresse IP. -message.enable.vpn.access=Le VPN est d\u00E9sactiv\u00E9 pour cette adresse IP. Voulez vous activer l\\'acc\u00E8s VPN ? -message.enabled.vpn=Votre acc\u00E8s VPN est activ\u00E9 et peut \u00EAtre acc\u00E9d\u00E9 par l\\'IP -message.enabled.vpn.ip.sec=Votre cl\u00E9 partag\u00E9e IPSec est -message.enabling.security.group.provider=Activation du fournisseur de groupe de s\u00E9curit\u00E9 +message.enable.vpn.access=Le VPN est d\u00e9sactiv\u00e9 pour cette adresse IP. Voulez vous activer l\\'acc\u00e8s VPN ? +message.enable.vpn=Confirmer l\\'activation de l\\'acc\u00e8s VPN pour cette adresse IP. +message.enabling.security.group.provider=Activation du fournisseur de groupe de s\u00e9curit\u00e9 message.enabling.zone=Activation de la zone -message.enter.token=Entrer le jeton unique re\u00E7u dans le message d\\'invitation. -message.generate.keys=Confirmer la g\u00E9n\u00E9ration de nouvelles clefs pour cet utilisateur. -message.guest.traffic.in.advanced.zone=Le trafic r\u00E9seau d\\'invit\u00E9 est la communication entre les machines virtuelles utilisateur. Sp\u00E9cifier une plage d\\'identifiant VLAN pour le trafic des invit\u00E9s pour chaque r\u00E9seau physique. -message.guest.traffic.in.basic.zone=Le trafic r\u00E9seau d\\'invit\u00E9 est la communication entre les machines virtuelles utilisateur. Sp\u00E9cifier une plage d\\'adresses IP que CloudStack peut assigner aux machines virtuelles Invit\u00E9. S\\'assurer que cette plage n\\'empi\u00E8te pas sur la plage r\u00E9serv\u00E9e aux adresses IP Syst\u00E8me. -message.installWizard.click.retry=Appuyer sur le bouton pour essayer \u00E0 nouveau le d\u00E9marrage. -message.installWizard.copy.whatIsACluster=Un cluster permet de grouper les h\u00F4tes. Les h\u00F4tes d\\'un cluster ont un mat\u00E9riel identique, ex\u00E9cutent le m\u00EAme hyperviseur, sont sur le m\u00EAme sous-r\u00E9seau, et acc\u00E8dent au m\u00EAme stockage partag\u00E9. Les instances de machines virtuelles (VM) peuvent \u00EAtre migr\u00E9es \u00E0 chaud d\\'un h\u00F4te \u00E0 un autre au sein du m\u00EAme groupe, sans interrompre les services utilisateur. Un cluster est la trois \u00E8me plus large unit\u00E9 organisationnelle dans un d\u00E9ploiement CloudStack&\#8482;. Les clusters sont contenus dans les pods et les pods sont contenus dans les zones.

CloudStack&\#8482; permet d\\'avoir plusieurs clusters dans un d\u00E9ploiement en nuage, mais pour une installation basique, il n\\'y a qu\\'un seul cluster. -message.installWizard.copy.whatIsAHost=Un h\u00F4te est une machine. Les h\u00F4tes fournissent les ressources informatiques qui ex\u00E9cutent les machines virtuelles invit\u00E9es. Chaque h\u00F4te a un logiciel hyperviseur install\u00E9 pour g\u00E9rer les machines virtuelles invit\u00E9es (sauf pour les h\u00F4tes de type \\'bare-metal\\', qui sont un cas particulier d\u00E9taill\u00E9 dans le Guide d\\'installation avanc\u00E9e). Par exemple, un serveur Linux avec KVM, un serveur Citrix XenServer, et un serveur ESXi sont des h\u00F4tes. Dans une installation basique, un seul h\u00F4te ex\u00E9cutant XenServer ou KVM est utilis\u00E9.

L\\'h\u00F4te est la plus petite unit\u00E9 organisation au sein d\\'un d\u00E9ploiement CloudStack&\#8482;. Les h\u00F4tes sont contenus dans les clusters, les clusters sont contenus dans les pods et les pods sont contenus dans les zones. -message.installWizard.copy.whatIsAPod=Un pod repr\u00E9sente souvent un seul rack. Les h\u00F4tes dans le m\u00EAme pod sont dans le m\u00EAme sous-r\u00E9seau.
Un pod est la deuxi\u00E8me plus grande unit\u00E9 organisationnelle au sein d\\'un d\u00E9ploiement CloudStack&\#8482;. Les pods sont contenus dans les zones. Chaque zone peut contenir un ou plusieurs pods ; dans l\\'Installation Basique, vous aurez juste un pod dans votre zone. -message.installWizard.copy.whatIsAZone=Une zone est la plus grande unit\u00E9 organisationnelle au sein d\\'un d\u00E9ploiement CloudStack&\#8482;. Une zone correspond typiquement \u00E0 un centre de donn\u00E9es, mais il est permis d\\'avoir plusieurs zones dans un centre de donn\u00E9es. L\\'avantage d\\'organiser une infrastructure en zones est de fournir une isolation physique et de la redondance. Par exemple, chaque zone peut avoir sa propre alimentation et de liaison avec le r\u00E9seau, et les zones peuvent \u00EAtre tr\u00E8s \u00E9loign\u00E9es g\u00E9ographiquement (m\u00EAme si ce n\\'est pas une obligation). -message.installWizard.copy.whatIsCloudStack=CloudStack&\#8482; est une plate-forme logicielle de pools de ressources informatiques pour construire des infrastructures publiques, priv\u00E9es et hybrides en tant que services (IaaS) dans les nuages. CloudStack&\#8482; g\u00E8re le r\u00E9seau, le stockage et les noeuds de calcul qui composent une infrastructure dans les nuages. Utilisez CloudStack&\#8482; pour d\u00E9ployer, g\u00E9rer et configurer les environnements d\\'informatiques dans les nuages.

S\\'\u00E9tendant au-del\u00E0 des machines virtuelles individuelles fonctionnant sur du mat\u00E9riel standard, CloudStack&\#8482; offre une solution d\\'informatique en nuage cl\u00E9 en main pour fournir des centres de donn\u00E9es virtuels comme service - fournissant tous les composants essentiels pour construire, d\u00E9ployer et g\u00E9rer des applications \\'cloud\\' multi-niveaux et multi-locataire. Les versions libre et Premium sont disponibles, la version Libre offrant des caract\u00E9ristiques presque identiques. -message.installWizard.copy.whatIsPrimaryStorage=Une infrastructure CloudStack&\#8482; utilise deux types de stockage \: stockage principal et stockage secondaire. Les deux peuvent \u00EAtre des serveurs iSCSI ou NFS, ou sur disque local.

Le stockage principal est associ\u00E9 \u00E0 un cluster, et stocke les volumes disques de chaque machine virtuelle pour toutes les VMs s\\'ex\u00E9cutant sur les h\u00F4tes dans le cluster. Le serveur de stockage principal est typiquement proche des h\u00F4tes. -message.installWizard.copy.whatIsSecondaryStorage=Le stockage secondaire est associ\u00E9 \u00E0 une zone, et il stocke les \u00E9l\u00E9ments suivants\:
  • Mod\u00E8les - images de syst\u00E8mes d\\'exploitation qui peuvent \u00EAtre utilis\u00E9es pour d\u00E9marrer les machines virtuelles et peuvent inclure des informations de configuration suppl\u00E9mentaires, telles que les applications pr\u00E9-install\u00E9es
  • Images ISO - images de syst\u00E8me d\\'exploitation ou d\\'installation d\\'OS qui peuvent \u00EAtre amor\u00E7able ou non-amor\u00E7able
  • Images de volume disque - capture des donn\u00E9es de machines virtuelles qui peuvent \u00EAtre utilis\u00E9es pour la r\u00E9cup\u00E9ration des donn\u00E9es ou cr\u00E9er des mod\u00E8les
+message.enter.token=Entrer le jeton unique re\u00e7u dans le message d\\'invitation. +message.generate.keys=Confirmer la g\u00e9n\u00e9ration de nouvelles clefs pour cet utilisateur. +message.guest.traffic.in.advanced.zone=Le trafic r\u00e9seau d\\'invit\u00e9 est la communication entre les machines virtuelles utilisateur. Sp\u00e9cifier une plage d\\'identifiant VLAN pour le trafic des invit\u00e9s pour chaque r\u00e9seau physique. +message.guest.traffic.in.basic.zone=Le trafic r\u00e9seau d\\'invit\u00e9 est la communication entre les machines virtuelles utilisateur. Sp\u00e9cifier une plage d\\'adresses IP que CloudStack peut assigner aux machines virtuelles Invit\u00e9. S\\'assurer que cette plage n\\'empi\u00e8te pas sur la plage r\u00e9serv\u00e9e aux adresses IP Syst\u00e8me. +message.installWizard.click.retry=Appuyer sur le bouton pour essayer \u00e0 nouveau le d\u00e9marrage. +message.installWizard.copy.whatIsACluster=Un cluster permet de grouper les h\u00f4tes. Les h\u00f4tes d\\'un cluster ont un mat\u00e9riel identique, ex\u00e9cutent le m\u00eame hyperviseur, sont sur le m\u00eame sous-r\u00e9seau, et acc\u00e8dent au m\u00eame stockage partag\u00e9. Les instances de machines virtuelles (VM) peuvent \u00eatre migr\u00e9es \u00e0 chaud d\\'un h\u00f4te \u00e0 un autre au sein du m\u00eame groupe, sans interrompre les services utilisateur. Un cluster est la trois \u00e8me plus large unit\u00e9 organisationnelle dans un d\u00e9ploiement CloudStack&\#8482;. Les clusters sont contenus dans les pods et les pods sont contenus dans les zones.

CloudStack&\#8482; permet d\\'avoir plusieurs clusters dans un d\u00e9ploiement en nuage, mais pour une installation basique, il n\\'y a qu\\'un seul cluster. +message.installWizard.copy.whatIsAHost=Un h\u00f4te est une machine. Les h\u00f4tes fournissent les ressources informatiques qui ex\u00e9cutent les machines virtuelles invit\u00e9es. Chaque h\u00f4te a un logiciel hyperviseur install\u00e9 pour g\u00e9rer les machines virtuelles invit\u00e9es (sauf pour les h\u00f4tes de type \\'bare-metal\\', qui sont un cas particulier d\u00e9taill\u00e9 dans le Guide d\\'installation avanc\u00e9e). Par exemple, un serveur Linux avec KVM, un serveur Citrix XenServer, et un serveur ESXi sont des h\u00f4tes. Dans une installation basique, un seul h\u00f4te ex\u00e9cutant XenServer ou KVM est utilis\u00e9.

L\\'h\u00f4te est la plus petite unit\u00e9 organisation au sein d\\'un d\u00e9ploiement CloudStack&\#8482;. Les h\u00f4tes sont contenus dans les clusters, les clusters sont contenus dans les pods et les pods sont contenus dans les zones. +message.installWizard.copy.whatIsAPod=Un pod repr\u00e9sente souvent un seul rack. Les h\u00f4tes dans le m\u00eame pod sont dans le m\u00eame sous-r\u00e9seau.
Un pod est la deuxi\u00e8me plus grande unit\u00e9 organisationnelle au sein d\\'un d\u00e9ploiement CloudStack&\#8482;. Les pods sont contenus dans les zones. Chaque zone peut contenir un ou plusieurs pods ; dans l\\'Installation Basique, vous aurez juste un pod dans votre zone. +message.installWizard.copy.whatIsAZone=Une zone est la plus grande unit\u00e9 organisationnelle au sein d\\'un d\u00e9ploiement CloudStack&\#8482;. Une zone correspond typiquement \u00e0 un centre de donn\u00e9es, mais il est permis d\\'avoir plusieurs zones dans un centre de donn\u00e9es. L\\'avantage d\\'organiser une infrastructure en zones est de fournir une isolation physique et de la redondance. Par exemple, chaque zone peut avoir sa propre alimentation et de liaison avec le r\u00e9seau, et les zones peuvent \u00eatre tr\u00e8s \u00e9loign\u00e9es g\u00e9ographiquement (m\u00eame si ce n\\'est pas une obligation). +message.installWizard.copy.whatIsCloudStack=CloudStack&\#8482; est une plate-forme logicielle de pools de ressources informatiques pour construire des infrastructures publiques, priv\u00e9es et hybrides en tant que services (IaaS) dans les nuages. CloudStack&\#8482; g\u00e8re le r\u00e9seau, le stockage et les noeuds de calcul qui composent une infrastructure dans les nuages. Utilisez CloudStack&\#8482; pour d\u00e9ployer, g\u00e9rer et configurer les environnements d\\'informatiques dans les nuages.

S\\'\u00e9tendant au-del\u00e0 des machines virtuelles individuelles fonctionnant sur du mat\u00e9riel standard, CloudStack&\#8482; offre une solution d\\'informatique en nuage cl\u00e9 en main pour fournir des centres de donn\u00e9es virtuels comme service - fournissant tous les composants essentiels pour construire, d\u00e9ployer et g\u00e9rer des applications \\'cloud\\' multi-niveaux et multi-locataire. Les versions libre et Premium sont disponibles, la version Libre offrant des caract\u00e9ristiques presque identiques. +message.installWizard.copy.whatIsPrimaryStorage=Une infrastructure CloudStack&\#8482; utilise deux types de stockage \: stockage principal et stockage secondaire. Les deux peuvent \u00eatre des serveurs iSCSI ou NFS, ou sur disque local.

Le stockage principal est associ\u00e9 \u00e0 un cluster, et stocke les volumes disques de chaque machine virtuelle pour toutes les VMs s\\'ex\u00e9cutant sur les h\u00f4tes dans le cluster. Le serveur de stockage principal est typiquement proche des h\u00f4tes. +message.installWizard.copy.whatIsSecondaryStorage=Le stockage secondaire est associ\u00e9 \u00e0 une zone, et il stocke les \u00e9l\u00e9ments suivants\:
  • Mod\u00e8les - images de syst\u00e8mes d\\'exploitation qui peuvent \u00eatre utilis\u00e9es pour d\u00e9marrer les machines virtuelles et peuvent inclure des informations de configuration suppl\u00e9mentaires, telles que les applications pr\u00e9-install\u00e9es
  • Images ISO - images de syst\u00e8me d\\'exploitation ou d\\'installation d\\'OS qui peuvent \u00eatre amor\u00e7able ou non-amor\u00e7able
  • Images de volume disque - capture des donn\u00e9es de machines virtuelles qui peuvent \u00eatre utilis\u00e9es pour la r\u00e9cup\u00e9ration des donn\u00e9es ou cr\u00e9er des mod\u00e8les
message.installWizard.now.building=Construction de votre Cloud en cours -message.installWizard.tooltip.addCluster.name=Un nom pour le cluster. Ce choix est libre et n\\'est pas utilis\u00E9 par CloudStack. +message.installWizard.tooltip.addCluster.name=Un nom pour le cluster. Ce choix est libre et n\\'est pas utilis\u00e9 par CloudStack. message.installWizard.tooltip.addHost.hostname=Le nom DNS ou adresse IP du serveur. -message.installWizard.tooltip.addHost.password=Le mot de passe pour l\\'utilisateur indiqu\u00E9 pr\u00E9c\u00E9demment (issu de l\\'installation XenServer). +message.installWizard.tooltip.addHost.password=Le mot de passe pour l\\'utilisateur indiqu\u00e9 pr\u00e9c\u00e9demment (issu de l\\'installation XenServer). message.installWizard.tooltip.addHost.username=Habituellement root. message.installWizard.tooltip.addPod.name=Nom pour le pod -message.installWizard.tooltip.addPod.reservedSystemEndIp=Ceci est la plage d\\'adresses IP dans le r\u00E9seau priv\u00E9 que CloudStack utilise la gestion des VMs du stockage secondaire et les VMs Console Proxy. Ces adresses IP sont prises dans le m\u00EAme sous-r\u00E9seau que les serveurs h\u00F4tes. +message.installWizard.tooltip.addPod.reservedSystemEndIp=Ceci est la plage d\\'adresses IP dans le r\u00e9seau priv\u00e9 que CloudStack utilise la gestion des VMs du stockage secondaire et les VMs Console Proxy. Ces adresses IP sont prises dans le m\u00eame sous-r\u00e9seau que les serveurs h\u00f4tes. message.installWizard.tooltip.addPod.reservedSystemGateway=Passerelle pour les serveurs dans ce pod -message.installWizard.tooltip.addPod.reservedSystemNetmask=Le masque r\u00E9seau que les instances utiliseront sur le r\u00E9seau -message.installWizard.tooltip.addPod.reservedSystemStartIp=Ceci est la plage d\\'adresses IP dans le r\u00E9seau priv\u00E9 que CloudStack utilise la gestion des VMs du stockage secondaire et les VMs Console Proxy. Ces adresses IP sont prises dans le m\u00EAme sous-r\u00E9seau que les serveurs h\u00F4tes. +message.installWizard.tooltip.addPod.reservedSystemNetmask=Le masque r\u00e9seau que les instances utiliseront sur le r\u00e9seau +message.installWizard.tooltip.addPod.reservedSystemStartIp=Ceci est la plage d\\'adresses IP dans le r\u00e9seau priv\u00e9 que CloudStack utilise la gestion des VMs du stockage secondaire et les VMs Console Proxy. Ces adresses IP sont prises dans le m\u00eame sous-r\u00e9seau que les serveurs h\u00f4tes. message.installWizard.tooltip.addPrimaryStorage.name=Nom pour ce stockage -message.installWizard.tooltip.addPrimaryStorage.path=(pour NFS) Dans NFS, ceci est le chemin d\\'export depuis le serveur. (pour SharedMountPoint) Le chemin. Avec KVM, c\\'est le chemin sur chaque h\u00F4te o\u00F9 ce stockage principal est mont\u00E9. Par exemple, "/mnt/primary". +message.installWizard.tooltip.addPrimaryStorage.path=(pour NFS) Dans NFS, ceci est le chemin d\\'export depuis le serveur. (pour SharedMountPoint) Le chemin. Avec KVM, c\\'est le chemin sur chaque h\u00f4te o\u00f9 ce stockage principal est mont\u00e9. Par exemple, "/mnt/primary". message.installWizard.tooltip.addPrimaryStorage.server=(pour NFS, iSCSI ou PreSetup) Adresse IP ou nom DNS du stockage message.installWizard.tooltip.addSecondaryStorage.nfsServer=Adresse IP du serveur NFS supportant le stockage secondaire -message.installWizard.tooltip.addSecondaryStorage.path=Le chemin export\u00E9, situ\u00E9 sur le serveur sp\u00E9cifi\u00E9 pr\u00E9c\u00E9demment -message.installWizard.tooltip.addZone.dns1=Ces serveurs DNS sont utilis\u00E9s par les machines virtuelles Invit\u00E9es dans la zone. Ces serveurs DNS seront accessibles par le r\u00E9seau public, ce dernier sera ajout\u00E9 plus tard. Les adresses IP publiques pour la zone doivent avoir une route vers les serveurs DNS indiqu\u00E9s ici. -message.installWizard.tooltip.addZone.dns2=Ces serveurs DNS sont utilis\u00E9s par les machines virtuelles Invit\u00E9es dans la zone. Ces serveurs DNS seront accessibles par le r\u00E9seau public, ce dernier sera ajout\u00E9 plus tard. Les adresses IP publiques pour la zone doivent avoir une route vers les serveurs DNS indiqu\u00E9s ici. -message.installWizard.tooltip.addZone.internaldns1=Ces serveurs DNS sont utilis\u00E9s par les machines virtuelles Invit\u00E9es dans la zone. Ces serveurs DNS seront accessibles par le r\u00E9seau public, ce dernier sera ajout\u00E9 plus tard. Les adresses IP publiques pour la zone doivent avoir une route vers les serveurs DNS indiqu\u00E9s ici. -message.installWizard.tooltip.addZone.internaldns2=Ces serveurs DNS sont utilis\u00E9s par les machines virtuelles Invit\u00E9es dans la zone. Ces serveurs DNS seront accessibles par le r\u00E9seau public, ce dernier sera ajout\u00E9 plus tard. Les adresses IP publiques pour la zone doivent avoir une route vers les serveurs DNS indiqu\u00E9s ici. +message.installWizard.tooltip.addSecondaryStorage.path=Le chemin export\u00e9, situ\u00e9 sur le serveur sp\u00e9cifi\u00e9 pr\u00e9c\u00e9demment +message.installWizard.tooltip.addZone.dns1=Ces serveurs DNS sont utilis\u00e9s par les machines virtuelles Invit\u00e9es dans la zone. Ces serveurs DNS seront accessibles par le r\u00e9seau public, ce dernier sera ajout\u00e9 plus tard. Les adresses IP publiques pour la zone doivent avoir une route vers les serveurs DNS indiqu\u00e9s ici. +message.installWizard.tooltip.addZone.dns2=Ces serveurs DNS sont utilis\u00e9s par les machines virtuelles Invit\u00e9es dans la zone. Ces serveurs DNS seront accessibles par le r\u00e9seau public, ce dernier sera ajout\u00e9 plus tard. Les adresses IP publiques pour la zone doivent avoir une route vers les serveurs DNS indiqu\u00e9s ici. +message.installWizard.tooltip.addZone.internaldns1=Ces serveurs DNS sont utilis\u00e9s par les machines virtuelles Invit\u00e9es dans la zone. Ces serveurs DNS seront accessibles par le r\u00e9seau public, ce dernier sera ajout\u00e9 plus tard. Les adresses IP publiques pour la zone doivent avoir une route vers les serveurs DNS indiqu\u00e9s ici. +message.installWizard.tooltip.addZone.internaldns2=Ces serveurs DNS sont utilis\u00e9s par les machines virtuelles Invit\u00e9es dans la zone. Ces serveurs DNS seront accessibles par le r\u00e9seau public, ce dernier sera ajout\u00e9 plus tard. Les adresses IP publiques pour la zone doivent avoir une route vers les serveurs DNS indiqu\u00e9s ici. message.installWizard.tooltip.addZone.name=Nom pour la zone -message.installWizard.tooltip.configureGuestTraffic.description=Description pour ce r\u00E9seau -message.installWizard.tooltip.configureGuestTraffic.guestEndIp=La plage d\\'adresses IP qui sera disponible en allocation pour les machines invit\u00E9es dans cette zone. Si une carte r\u00E9seau est utilis\u00E9e, ces adresses IP peuvent \u00EAtre dans le m\u00EAme CIDR que le CIDR du pod. -message.installWizard.tooltip.configureGuestTraffic.guestGateway=La passerelle que les instances invit\u00E9es doivent utiliser -message.installWizard.tooltip.configureGuestTraffic.guestNetmask=Le masque r\u00E9seau que les instances devrait utiliser sur le r\u00E9seau -message.installWizard.tooltip.configureGuestTraffic.guestStartIp=La plage d\\'adresses IP qui sera disponible en allocation pour les machines invit\u00E9es dans cette zone. Si une carte r\u00E9seau est utilis\u00E9e, ces adresses IP peuvent \u00EAtre dans le m\u00EAme CIDR que le CIDR du pod. -message.installWizard.tooltip.configureGuestTraffic.name=Nom pour ce r\u00E9seau -message.instanceWizard.noTemplates=Vous n\\'avez pas de image disponible ; Ajouter un mod\u00E8le compatible puis relancer l\\'assistant de cr\u00E9ation d\\'instance. -message.ip.address.changed=Vos adresses IP ont peut \u00EAtre chang\u00E9es ; Voulez vous rafra\u00EEchir la liste ? Dans ce cas, le panneau de d\u00E9tail se fermera. -message.iso.desc=Image disque contenant des donn\u00E9es ou un support amor\u00E7able pour OS -message.join.project=Vous avez rejoint un projet. S\u00E9lectionnez la vue Projet pour le voir. -message.launch.vm.on.private.network=Souhaitez vous d\u00E9marrer cette instance sur votre propre r\u00E9seau priv\u00E9 ? -message.launch.zone=La zone est pr\u00EAte \u00E0 d\u00E9marrer ; passer \u00E0 l\\'\u00E9tape suivante. -message.lock.account=\u00CAtes-vous s\u00FBr que vous souhaitez verrouiller ce compte. En le verrouillant, les utilisateurs de ce compte ne seront plus capables de g\u00E9rer leurs ressources. Les ressources existantes resteront toutefois accessibles. -message.migrate.instance.confirm=Confirmez l\\'h\u00F4te vers lequel vous souhaitez migrer cette instance -message.migrate.instance.to.host=Confirmer la migration de l\\'instance vers un autre h\u00F4te +message.installWizard.tooltip.configureGuestTraffic.description=Description pour ce r\u00e9seau +message.installWizard.tooltip.configureGuestTraffic.guestEndIp=La plage d\\'adresses IP qui sera disponible en allocation pour les machines invit\u00e9es dans cette zone. Si une carte r\u00e9seau est utilis\u00e9e, ces adresses IP peuvent \u00eatre dans le m\u00eame CIDR que le CIDR du pod. +message.installWizard.tooltip.configureGuestTraffic.guestGateway=La passerelle que les instances invit\u00e9es doivent utiliser +message.installWizard.tooltip.configureGuestTraffic.guestNetmask=Le masque r\u00e9seau que les instances devrait utiliser sur le r\u00e9seau +message.installWizard.tooltip.configureGuestTraffic.guestStartIp=La plage d\\'adresses IP qui sera disponible en allocation pour les machines invit\u00e9es dans cette zone. Si une carte r\u00e9seau est utilis\u00e9e, ces adresses IP peuvent \u00eatre dans le m\u00eame CIDR que le CIDR du pod. +message.installWizard.tooltip.configureGuestTraffic.name=Nom pour ce r\u00e9seau +message.instanceWizard.noTemplates=Vous n\\'avez pas de image disponible ; Ajouter un mod\u00e8le compatible puis relancer l\\'assistant de cr\u00e9ation d\\'instance. +message.ip.address.changed=Vos adresses IP ont peut \u00eatre chang\u00e9es ; Voulez vous rafra\u00eechir la liste ? Dans ce cas, le panneau de d\u00e9tail se fermera. +message.iso.desc=Image disque contenant des donn\u00e9es ou un support amor\u00e7able pour OS +message.join.project=Vous avez rejoint un projet. S\u00e9lectionnez la vue Projet pour le voir. +message.launch.vm.on.private.network=Souhaitez vous d\u00e9marrer cette instance sur votre propre r\u00e9seau priv\u00e9 ? +message.launch.zone=La zone est pr\u00eate \u00e0 d\u00e9marrer ; passer \u00e0 l\\'\u00e9tape suivante. +message.lock.account=\u00cates-vous s\u00fbr que vous souhaitez verrouiller ce compte. En le verrouillant, les utilisateurs de ce compte ne seront plus capables de g\u00e9rer leurs ressources. Les ressources existantes resteront toutefois accessibles. +message.migrate.instance.confirm=Confirmez l\\'h\u00f4te vers lequel vous souhaitez migrer cette instance +message.migrate.instance.to.host=Confirmer la migration de l\\'instance vers un autre h\u00f4te message.migrate.instance.to.ps=Confirmer la migration de l\\'instance vers un autre stockage principal message.migrate.router.confirm=Confirmer la migration du routeur vers \: -message.migrate.systemvm.confirm=Confirmer la migration de la VM syst\u00E8me vers \: +message.migrate.systemvm.confirm=Confirmer la migration de la VM syst\u00e8me vers \: message.migrate.volume=Confirmer la migration du volume vers un autre stockage principal. message.new.user=Renseigner les informations suivantes pour ajouter un nouveau compte utilisateur -message.no.network.support=S\u00E9lectionnez l\\'hyperviseur. vSphere, n\\'a pas de fonctionnalit\u00E9s suppl\u00E9mentaires pour le r\u00E9seau. Continuez \u00E0 l\\'\u00E9tape 5. -message.no.network.support.configuration.not.true=Il n\\'y a pas de zone avec la fonction groupe de s\u00E9curit\u00E9 active. D\u00E8s lors, pas de fonction r\u00E9seau suppl\u00E9mentaires disponibles. Continuer \u00E0 l\\'\u00E9tape 5. -message.no.projects=Vous n\\'avez pas de projet.
Vous pouvez en cr\u00E9er un depuis la section projets. +message.no.network.support.configuration.not.true=Il n\\'y a pas de zone avec la fonction groupe de s\u00e9curit\u00e9 active. D\u00e8s lors, pas de fonction r\u00e9seau suppl\u00e9mentaires disponibles. Continuer \u00e0 l\\'\u00e9tape 5. +message.no.network.support=S\u00e9lectionnez l\\'hyperviseur. vSphere, n\\'a pas de fonctionnalit\u00e9s suppl\u00e9mentaires pour le r\u00e9seau. Continuez \u00e0 l\\'\u00e9tape 5. message.no.projects.adminOnly=Vous n\\'avez pas de projet.
Contacter votre administrateur pour ajouter un projet. +message.no.projects=Vous n\\'avez pas de projet.
Vous pouvez en cr\u00e9er un depuis la section projets. message.number.clusters=

\# de Clusters

-message.number.hosts=

\# d\\' H\u00F4tes

+message.number.hosts=

\# d\\' H\u00f4tes

message.number.pods=

\# de Pods

message.number.storage=

\# de Volumes de Stockage Principal

message.number.zones=

\# de Zones

message.pending.projects.1=Vous avez des invitations projet en attente \: -message.pending.projects.2=Pour les visualiser, aller dans la section projets, puis s\u00E9lectionner invitation dans la liste d\u00E9roulante. -message.please.add.at.lease.one.traffic.range=Ajouter au moins une plage r\u00E9seau -message.please.proceed=Continuer vers la prochaine \u00E9tape. -message.please.select.a.configuration.for.your.zone=S\u00E9lectionner une configuration pour la zone. -message.please.select.a.different.public.and.management.network.before.removing=S\u00E9lectionner un r\u00E9seau public et d\\'administration diff\u00E9rent avant de supprimer -message.please.select.networks=S\u00E9lectionner les r\u00E9seaux pour votre machine virtuelle. -message.please.wait.while.zone.is.being.created=Patienter pendant la cr\u00E9ation de la zone, cela peut prendre du temps... -message.project.invite.sent=Invitation envoy\u00E9e ; les utilisateurs seront ajout\u00E9s apr\u00E8s acceptation de l\\'invitation -message.public.traffic.in.advanced.zone=Le trafic public est g\u00E9n\u00E9r\u00E9 lorsque les machines virtuelles dans le nuage acc\u00E8dent \u00E0 Internet. Des adresses IP publiquement accessibles doivent \u00EAtre pr\u00E9vues \u00E0 cet effet. Les utilisateurs peuvent utiliser l\\'interface d\\'administration de CloudStack pour acqu\u00E9rir ces adresses IP qui impl\u00E9menteront une translation d\\'adresse NAT entre le r\u00E9seau d\\'invit\u00E9 et le r\u00E9seau public.

Fournir au moins une plage d\\'adresses IP pour le trafic Internet. -message.public.traffic.in.basic.zone=Le trafic public est g\u00E9n\u00E9r\u00E9 lorsque les machines virtuelles dans le nuage acc\u00E8dent \u00E0 Internet ou fournissent des services \u00E0 des utilisateurs sur Internet. Des adresses IP publiquement accessibles doivent \u00EAtre pr\u00E9vus \u00E0 cet effet. Quand une instance est cr\u00E9\u00E9e, une adresse IP publique depuis un ensemble d\\'adresses IP publiques sera allou\u00E9e \u00E0 l\\'instance, en plus de l\\'adresse IP de l\\'invit\u00E9. La translation d\\'adresses statique NAT 1-1 sera mises en place automatiquement entre l\\'adresse IP publique et l\\'adresse IP de l\\'invit\u00E9. Les utilisateurs peuvent \u00E9galement utiliser l\\'interface d\\'administration CloudStack pour acqu\u00E9rir des adresses IP suppl\u00E9mentaires pour ajouter une translation d\\'adresse statique NAT entre leurs instances et le r\u00E9seau d\\'adresses IP publiques. +message.pending.projects.2=Pour les visualiser, aller dans la section projets, puis s\u00e9lectionner invitation dans la liste d\u00e9roulante. +message.please.add.at.lease.one.traffic.range=Ajouter au moins une plage r\u00e9seau +message.please.proceed=Continuer vers la prochaine \u00e9tape. +message.please.select.a.configuration.for.your.zone=S\u00e9lectionner une configuration pour la zone. +message.please.select.a.different.public.and.management.network.before.removing=S\u00e9lectionner un r\u00e9seau public et d\\'administration diff\u00e9rent avant de supprimer +message.please.select.networks=S\u00e9lectionner les r\u00e9seaux pour votre machine virtuelle. +message.please.wait.while.zone.is.being.created=Patienter pendant la cr\u00e9ation de la zone, cela peut prendre du temps... +message.project.invite.sent=Invitation envoy\u00e9e ; les utilisateurs seront ajout\u00e9s apr\u00e8s acceptation de l\\'invitation +message.public.traffic.in.advanced.zone=Le trafic public est g\u00e9n\u00e9r\u00e9 lorsque les machines virtuelles dans le nuage acc\u00e8dent \u00e0 Internet. Des adresses IP publiquement accessibles doivent \u00eatre pr\u00e9vues \u00e0 cet effet. Les utilisateurs peuvent utiliser l\\'interface d\\'administration de CloudStack pour acqu\u00e9rir ces adresses IP qui impl\u00e9menteront une translation d\\'adresse NAT entre le r\u00e9seau d\\'invit\u00e9 et le r\u00e9seau public.

Fournir au moins une plage d\\'adresses IP pour le trafic Internet. +message.public.traffic.in.basic.zone=Le trafic public est g\u00e9n\u00e9r\u00e9 lorsque les machines virtuelles dans le nuage acc\u00e8dent \u00e0 Internet ou fournissent des services \u00e0 des utilisateurs sur Internet. Des adresses IP publiquement accessibles doivent \u00eatre pr\u00e9vus \u00e0 cet effet. Quand une instance est cr\u00e9\u00e9e, une adresse IP publique depuis un ensemble d\\'adresses IP publiques sera allou\u00e9e \u00e0 l\\'instance, en plus de l\\'adresse IP de l\\'invit\u00e9. La translation d\\'adresses statique NAT 1-1 sera mises en place automatiquement entre l\\'adresse IP publique et l\\'adresse IP de l\\'invit\u00e9. Les utilisateurs peuvent \u00e9galement utiliser l\\'interface d\\'administration CloudStack pour acqu\u00e9rir des adresses IP suppl\u00e9mentaires pour ajouter une translation d\\'adresse statique NAT entre leurs instances et le r\u00e9seau d\\'adresses IP publiques. +message.redirecting.region=Redirection vers r\u00e9gion... +message.remove.region=Confirmer que vous souhaitez supprimer cette r\u00e9gion depuis ce serveur d\\'administration ? message.remove.vpc=Confirmer la suppression du VPC -message.remove.vpn.access=\u00CAtes-vous s\u00FBr que vous souhaitez supprimer l\\'acc\u00E8s VPN \u00E0 l\\'utilisateur suivant. -message.reset.VPN.connection=Confirmer le r\u00E9-initialisation de la connexion VPN -message.reset.password.warning.notPasswordEnabled=Le mod\u00E8le de cette instance a \u00E9t\u00E9 cr\u00E9\u00E9 sans la gestion de mot de passe -message.reset.password.warning.notStopped=Votre instance doit \u00EAtre arr\u00EAt\u00E9e avant de changer son mot de passe -message.restart.mgmt.server=Red\u00E9marrez votre(vos) serveur(s) de management pour appliquer les nouveaux param\u00E8tres. -message.restart.mgmt.usage.server=Red\u00E9marrer le ou les serveur(s) de gestion et le ou les serveur(s) de consommation pour que les nouveaux param\u00E8tres soient pris en compte. -message.restart.network=Tous les services fournit par ce routeur virtuel vont \u00EAtre interrompus. Confirmer le red\u00E9marrage de ce routeur. -message.restart.vpc=Confirmer le red\u00E9marrage du VPC -message.security.group.usage=(Utilisez Ctrl-clic pour s\u00E9lectionner les groupes de s\u00E9curit\u00E9 vis\u00E9s) -message.select.a.zone=Une zone correspond typiquement \u00E0 un seul centre de donn\u00E9es. Des zones multiples peuvent permettre de rendre votre cloud plus fiable en apportant une isolation physique et de la redondance. -message.select.instance=S\u00E9lectionner une instance. -message.select.iso=S\u00E9lectionner un ISO pour votre nouvelle instance virtuelle. -message.select.item=Merci de s\u00E9lectionner un \u00E9l\u00E9ment. -message.select.security.groups=Merci de s\u00E9lectionner un(des) groupe(s) de s\u00E9curit\u00E9 pour la nouvelle VM -message.select.template=S\u00E9lectionner un mod\u00E8le pour votre nouvelle instance virtuelle. -message.setup.physical.network.during.zone.creation=Lorsque vous ajoutez une zone avanc\u00E9e, vous avez besoin de d\u00E9finir un ou plusieurs r\u00E9seaux physiques. Chaque r\u00E9seau correspond \u00E0 une carte r\u00E9seau sur l\\'hyperviseur. Chaque r\u00E9seau physique peut supporter un ou plusieurs types de trafic, avec certaines restrictions sur la fa\u00E7on dont ils peuvent \u00EAtre combin\u00E9s.

Glisser et d\u00E9poser un ou plusieurs types de trafic sur chaque r\u00E9seau physique. -message.setup.physical.network.during.zone.creation.basic=Quand vous ajoutez une zone basique, vous pouvez param\u00E9trer un seul r\u00E9seau physique, correspondant \u00E0 une carte r\u00E9seau sur l\\'hyperviseur. Ce r\u00E9seau comportera plusieurs types de trafic.

Vous pouvez \u00E9galement glisser et d\u00E9poser d\\'autres types de trafic sur le r\u00E9seau physique. -message.setup.successful=Installation du Cloud r\u00E9ussie \! -message.snapshot.schedule=Vous pouvez mettre en place les politiques de g\u00E9n\u00E9ration d\\'instantan\u00E9s en s\u00E9lectionnant les options disponibles ci-dessous et en appliquant votre politique. +message.remove.vpn.access=\u00cates-vous s\u00fbr que vous souhaitez supprimer l\\'acc\u00e8s VPN \u00e0 l\\'utilisateur suivant. +message.reset.password.warning.notPasswordEnabled=Le mod\u00e8le de cette instance a \u00e9t\u00e9 cr\u00e9\u00e9 sans la gestion de mot de passe +message.reset.password.warning.notStopped=Votre instance doit \u00eatre arr\u00eat\u00e9e avant de changer son mot de passe +message.reset.VPN.connection=Confirmer le r\u00e9-initialisation de la connexion VPN +message.restart.mgmt.server=Red\u00e9marrez votre(vos) serveur(s) de management pour appliquer les nouveaux param\u00e8tres. +message.restart.mgmt.usage.server=Red\u00e9marrer le ou les serveur(s) de gestion et le ou les serveur(s) de consommation pour que les nouveaux param\u00e8tres soient pris en compte. +message.restart.network=Tous les services fournit par ce routeur virtuel vont \u00eatre interrompus. Confirmer le red\u00e9marrage de ce routeur. +message.restart.vpc=Confirmer le red\u00e9marrage du VPC +message.security.group.usage=(Utilisez Ctrl-clic pour s\u00e9lectionner les groupes de s\u00e9curit\u00e9 vis\u00e9s) +message.select.a.zone=Une zone correspond typiquement \u00e0 un seul centre de donn\u00e9es. Des zones multiples peuvent permettre de rendre votre cloud plus fiable en apportant une isolation physique et de la redondance. +message.select.instance=S\u00e9lectionner une instance. +message.select.iso=S\u00e9lectionner un ISO pour votre nouvelle instance virtuelle. +message.select.item=Merci de s\u00e9lectionner un \u00e9l\u00e9ment. +message.select.security.groups=Merci de s\u00e9lectionner un(des) groupe(s) de s\u00e9curit\u00e9 pour la nouvelle VM +message.select.template=S\u00e9lectionner un mod\u00e8le pour votre nouvelle instance virtuelle. +message.setup.physical.network.during.zone.creation.basic=Quand vous ajoutez une zone basique, vous pouvez param\u00e9trer un seul r\u00e9seau physique, correspondant \u00e0 une carte r\u00e9seau sur l\\'hyperviseur. Ce r\u00e9seau comportera plusieurs types de trafic.

Vous pouvez \u00e9galement glisser et d\u00e9poser d\\'autres types de trafic sur le r\u00e9seau physique. +message.setup.physical.network.during.zone.creation=Lorsque vous ajoutez une zone avanc\u00e9e, vous avez besoin de d\u00e9finir un ou plusieurs r\u00e9seaux physiques. Chaque r\u00e9seau correspond \u00e0 une carte r\u00e9seau sur l\\'hyperviseur. Chaque r\u00e9seau physique peut supporter un ou plusieurs types de trafic, avec certaines restrictions sur la fa\u00e7on dont ils peuvent \u00eatre combin\u00e9s.

Glisser et d\u00e9poser un ou plusieurs types de trafic sur chaque r\u00e9seau physique. +message.setup.successful=Installation du Cloud r\u00e9ussie \! +message.snapshot.schedule=Vous pouvez mettre en place les politiques de g\u00e9n\u00e9ration d\\'instantan\u00e9s en s\u00e9lectionnant les options disponibles ci-dessous et en appliquant votre politique. message.specify.url=Renseigner l\\'URL -message.step.1.continue=S\u00E9lectionnez un mod\u00E8le ou une image ISO pour continuer -message.step.1.desc=S\u00E9lectionnez un mod\u00E8le pour votre nouvelle instance virtuelle. Vous pouvez \u00E9galement choisir un mod\u00E8le vierge sur lequel une image ISO pourra \u00EAtre install\u00E9e. -message.step.2.continue=S\u00E9lectionnez une offre de service pour continuer -message.step.3.continue=S\u00E9lectionnez un offre de service de disque pour continuer -message.step.4.continue=S\u00E9lectionnez au moins un r\u00E9seau pour continuer -message.step.4.desc=S\u00E9lectionnez le r\u00E9seau principal auquel votre instance va \u00EAtre connect\u00E9. -message.storage.traffic=Trafic entre les ressources internes de CloudStack, incluant tous les composants qui communiquent avec le serveur d\\'administration, tels que les h\u00F4tes et les machines virtuelles Syst\u00E8mes CloudStack. Veuillez configurer le trafic de stockage ici. -message.suspend.project=\u00CAtes-vous s\u00FBr de vouloir suspendre ce projet ? -message.template.desc=Image OS pouvant \u00EAtre utilis\u00E9e pour d\u00E9marrer une VM -message.tooltip.dns.1=Nom d\\'un serveur DNS utilis\u00E9 par les VM de la zone. Les adresses IP publiques de cette zone doivent avoir une route vers ce serveur. -message.tooltip.dns.2=Nom d\\'un serveur DNS secondaire utilis\u00E9 par les VM de la zone. Les adresses IP publiques de cette zone doivent avoir une route vers ce serveur. -message.tooltip.internal.dns.1=Nom d\\'un serveur DNS que CloudStack peut utiliser pour les VM syst\u00E8me dans cette zone. Les adresses IP priv\u00E9es des pods doivent avoir une route vers ce serveur. -message.tooltip.internal.dns.2=Nom d\\'un serveur DNS que CloudStack peut utiliser pour les VM syst\u00E8me dans cette zone. Les adresses IP priv\u00E9es des pods doivent avoir une route vers ce serveur. -message.tooltip.network.domain=Suffixe DNS qui cr\u00E9era un nom de domaine personnalis\u00E9 pour les r\u00E9seau accessible par les VM invit\u00E9es. +message.step.1.continue=S\u00e9lectionnez un mod\u00e8le ou une image ISO pour continuer +message.step.1.desc=S\u00e9lectionnez un mod\u00e8le pour votre nouvelle instance virtuelle. Vous pouvez \u00e9galement choisir un mod\u00e8le vierge sur lequel une image ISO pourra \u00eatre install\u00e9e. +message.step.2.continue=S\u00e9lectionnez une offre de service pour continuer +message.step.2.desc= +message.step.3.continue=S\u00e9lectionnez un offre de service de disque pour continuer +message.step.3.desc= +message.step.4.continue=S\u00e9lectionnez au moins un r\u00e9seau pour continuer +message.step.4.desc=S\u00e9lectionnez le r\u00e9seau principal auquel votre instance va \u00eatre connect\u00e9. +message.storage.traffic=Trafic entre les ressources internes de CloudStack, incluant tous les composants qui communiquent avec le serveur d\\'administration, tels que les h\u00f4tes et les machines virtuelles Syst\u00e8mes CloudStack. Veuillez configurer le trafic de stockage ici. +message.suspend.project=\u00cates-vous s\u00fbr de vouloir suspendre ce projet ? +message.template.desc=Image OS pouvant \u00eatre utilis\u00e9e pour d\u00e9marrer une VM +message.tooltip.dns.1=Nom d\\'un serveur DNS utilis\u00e9 par les VM de la zone. Les adresses IP publiques de cette zone doivent avoir une route vers ce serveur. +message.tooltip.dns.2=Nom d\\'un serveur DNS secondaire utilis\u00e9 par les VM de la zone. Les adresses IP publiques de cette zone doivent avoir une route vers ce serveur. +message.tooltip.internal.dns.1=Nom d\\'un serveur DNS que CloudStack peut utiliser pour les VM syst\u00e8me dans cette zone. Les adresses IP priv\u00e9es des pods doivent avoir une route vers ce serveur. +message.tooltip.internal.dns.2=Nom d\\'un serveur DNS que CloudStack peut utiliser pour les VM syst\u00e8me dans cette zone. Les adresses IP priv\u00e9es des pods doivent avoir une route vers ce serveur. +message.tooltip.network.domain=Suffixe DNS qui cr\u00e9era un nom de domaine personnalis\u00e9 pour les r\u00e9seau accessible par les VM invit\u00e9es. message.tooltip.pod.name=Nom pour ce pod. -message.tooltip.reserved.system.gateway=La passerelle pour les h\u00F4tes du pod. -message.tooltip.reserved.system.netmask=Le pr\u00E9fixe r\u00E9seau utilis\u00E9 par le sous-r\u00E9seau du pod. Au format CIDR. +message.tooltip.reserved.system.gateway=La passerelle pour les h\u00f4tes du pod. +message.tooltip.reserved.system.netmask=Le pr\u00e9fixe r\u00e9seau utilis\u00e9 par le sous-r\u00e9seau du pod. Au format CIDR. message.tooltip.zone.name=Nom pour cette zone. -message.update.os.preference=Choisissez votre OS pr\u00E9f\u00E9r\u00E9 pour cet h\u00F4te. Toutes les instances avec des pr\u00E9f\u00E9rences similaires seront d\\'abord allou\u00E9es \u00E0 cet h\u00F4te avant d\\'en choisir un autre. -message.update.resource.count=Confirmer la mise \u00E0 jour des ressources pour ce compte. -message.update.ssl=Soumettez un nouveau certificat SSL compatible X.509 qui sera mis \u00E0 jour sur l\\'ensemble de instance de proxy console. -message.validate.instance.name=Le nom de l\\'instance ne peut d\u00E9passer 63 caract\u00E8res. Seuls les lettres de a \u00E0 z, les chiffres de 0 \u00E0 9 et les tirets sont accept\u00E9s. Le nom doit commencer par une lettre et se terminer par une lettre ou un chiffre. -message.virtual.network.desc=Un r\u00E9seau virtuel d\u00E9di\u00E9 pour votre compte. Ce domaine de multi-diffusion est contenu dans un VLAN et l\\'ensemble des r\u00E9seaux d\\'acc\u00E8s publique sont rout\u00E9s par un routeur virtuel. -message.vm.create.template.confirm=Cr\u00E9er un mod\u00E8le va red\u00E9marrer la VM automatiquement -message.vm.review.launch=Merci de v\u00E9rifier les informations suivantes et de confirmer que votre instance virtuelle est correcte avant de la d\u00E9marrer. -message.volume.create.template.confirm=\u00CAtes-vous s\u00FBr que vous souhaitez cr\u00E9er un mod\u00E8le pour ce disque. La cr\u00E9ation peut prendre plusieurs minutes, voire plus, selon la taille du volume. -message.you.must.have.at.least.one.physical.network=Vous devez avoir au moins un r\u00E9seau physique -message.zone.creation.complete.would.you.like.to.enable.this.zone=Cr\u00E9ation de la zone termin\u00E9e. Voulez-vous l\\'activer ? -message.zone.no.network.selection=La zone s\u00E9lectionn\u00E9e ne propose pas le r\u00E9seau choisi -message.zone.step.1.desc=S\u00E9lectionnez un mod\u00E8le de r\u00E9seau pour votre zone. +message.update.os.preference=Choisissez votre OS pr\u00e9f\u00e9r\u00e9 pour cet h\u00f4te. Toutes les instances avec des pr\u00e9f\u00e9rences similaires seront d\\'abord allou\u00e9es \u00e0 cet h\u00f4te avant d\\'en choisir un autre. +message.update.resource.count=Confirmer la mise \u00e0 jour des ressources pour ce compte. +message.update.ssl=Soumettez un nouveau certificat SSL compatible X.509 qui sera mis \u00e0 jour sur l\\'ensemble de instance de proxy console. +message.validate.instance.name=Le nom de l\\'instance ne peut d\u00e9passer 63 caract\u00e8res. Seuls les lettres de a \u00e0 z, les chiffres de 0 \u00e0 9 et les tirets sont accept\u00e9s. Le nom doit commencer par une lettre et se terminer par une lettre ou un chiffre. +message.virtual.network.desc=Un r\u00e9seau virtuel d\u00e9di\u00e9 pour votre compte. Ce domaine de multi-diffusion est contenu dans un VLAN et l\\'ensemble des r\u00e9seaux d\\'acc\u00e8s publique sont rout\u00e9s par un routeur virtuel. +message.vm.create.template.confirm=Cr\u00e9er un mod\u00e8le va red\u00e9marrer la VM automatiquement +message.vm.review.launch=Merci de v\u00e9rifier les informations suivantes et de confirmer que votre instance virtuelle est correcte avant de la d\u00e9marrer. +message.volume.create.template.confirm=\u00cates-vous s\u00fbr que vous souhaitez cr\u00e9er un mod\u00e8le pour ce disque. La cr\u00e9ation peut prendre plusieurs minutes, voire plus, selon la taille du volume. +message.you.must.have.at.least.one.physical.network=Vous devez avoir au moins un r\u00e9seau physique +message.Zone.creation.complete=Cr\u00e9ation de la zone termin\u00e9e +message.zone.creation.complete.would.you.like.to.enable.this.zone=Cr\u00e9ation de la zone termin\u00e9e. Voulez-vous l\\'activer ? +message.zone.no.network.selection=La zone s\u00e9lectionn\u00e9e ne propose pas le r\u00e9seau choisi +message.zone.step.1.desc=S\u00e9lectionnez un mod\u00e8le de r\u00e9seau pour votre zone. message.zone.step.2.desc=Renseigner les informations suivantes pour ajouter une nouvelle zone message.zone.step.3.desc=Renseigner les informations suivantes pour ajouter un nouveau pod -message.zoneWizard.enable.local.storage=ATTENTION \: si vous activez le stockage local pour cette zone, vous devez effectuer les op\u00E9rations suivantes, selon l\\'endroit o\u00F9 vous souhaitez lancer vos machines virtuelles Syst\u00E8mes \:

1. Si les machines virtuelles Syst\u00E8mes doivent \u00EAtre lanc\u00E9es depuis le stockage principal, ce dernier doit \u00EAtre ajout\u00E9 \u00E0 la zone apr\u00E8s la cr\u00E9ation. Vous devez \u00E9galement d\u00E9marrer la zone dans un \u00E9tat d\u00E9sactiv\u00E9.

2. Si les machines virtuelles Syst\u00E8mes doivent \u00EAtre lanc\u00E9es depuis le stockage local, le param\u00E8tre system.vm.use.local.storage doit \u00EAtre d\u00E9fini \u00E0 \\'true\\' avant d\\'activer la zone.


Voulez-vous continuer ? +message.zoneWizard.enable.local.storage=ATTENTION \: si vous activez le stockage local pour cette zone, vous devez effectuer les op\u00e9rations suivantes, selon l\\'endroit o\u00f9 vous souhaitez lancer vos machines virtuelles Syst\u00e8mes \:

1. Si les machines virtuelles Syst\u00e8mes doivent \u00eatre lanc\u00e9es depuis le stockage principal, ce dernier doit \u00eatre ajout\u00e9 \u00e0 la zone apr\u00e8s la cr\u00e9ation. Vous devez \u00e9galement d\u00e9marrer la zone dans un \u00e9tat d\u00e9sactiv\u00e9.

2. Si les machines virtuelles Syst\u00e8mes doivent \u00eatre lanc\u00e9es depuis le stockage local, le param\u00e8tre system.vm.use.local.storage doit \u00eatre d\u00e9fini \u00e0 \\'true\\' avant d\\'activer la zone.


Voulez-vous continuer ? mode=Mode -network.rate=D\u00E9bit R\u00E9seau -notification.reboot.instance=Red\u00E9marrer l\\'instance -notification.start.instance=D\u00E9marrer l\\'instance +network.rate=D\u00e9bit R\u00e9seau +notification.reboot.instance=Red\u00e9marrer l\\'instance +notification.start.instance=D\u00e9marrer l\\'instance notification.stop.instance=Stopper l\\'instance -side.by.side=C\u00F4te \u00E0 c\u00F4te -state.Accepted=Accept\u00E9 +side.by.side=C\u00f4te \u00e0 c\u00f4te +state.Accepted=Accept\u00e9 state.Active=Actif -state.Allocated=Allou\u00E9 +state.Allocated=Allou\u00e9 state.Allocating=Allocation en cours -state.BackedUp=Sauvegard\u00E9 +state.BackedUp=Sauvegard\u00e9 state.BackingUp=Sauvegarde en cours -state.Completed=Termin\u00E9 -state.Creating=Cr\u00E9ation en cours -state.Declined=Refus\u00E9 -state.Destroyed=Supprim\u00E9e -state.Disabled=D\u00E9sactiv\u00E9 +state.Completed=Termin\u00e9 +state.Creating=Cr\u00e9ation en cours +state.Declined=Refus\u00e9 +state.Destroyed=Supprim\u00e9e +state.Disabled=D\u00e9sactiv\u00e9 +state.enabled=Actifs state.Enabled=Actifs state.Error=Erreur state.Expunging=Purge en cours state.Migrating=Migration en cours state.Pending=En attente -state.Ready=Pr\u00EAt -state.Running=D\u00E9marr\u00E9e -state.Starting=D\u00E9marrage en cours -state.Stopped=Arr\u00EAt\u00E9e -state.Stopping=Arr\u00EAt en cours +state.ready=Pr\u00eat +state.Ready=Pr\u00eat +state.Running=D\u00e9marr\u00e9e +state.Starting=D\u00e9marrage en cours +state.Stopped=Arr\u00eat\u00e9e +state.Stopping=Arr\u00eat en cours state.Suspended=Suspendu -state.enabled=Actifs -state.ready=Pr\u00EAt ui.listView.filters.all=Tous ui.listView.filters.mine=Mon diff --git a/client/WEB-INF/classes/resources/messages_it_IT.properties b/client/WEB-INF/classes/resources/messages_it_IT.properties index c6bc2dba127..78323b02578 100644 --- a/client/WEB-INF/classes/resources/messages_it_IT.properties +++ b/client/WEB-INF/classes/resources/messages_it_IT.properties @@ -15,6 +15,7 @@ # specific language governing permissions and limitations # under the License. + changed.item.properties=Elementi delle propriet\u00e0 modificati confirm.enable.s3=Si prega di inserire i valori richiesti per abilitare il supporto per il Secondary Storage di tipo S3 confirm.enable.swift=Si prega di inserire i valori richiesti per abilitare il supporto per Swift @@ -432,7 +433,6 @@ label.zone.name=Nome Zona label.zones=Zone label.zone.type=Tipo di Zona label.zoneWizard.trafficType.guest=Guest\: Traffico di rete tra le virtual machine dell\\'utente finale -label.zoneWizard.trafficType.management=Management\: Traffico di rete tra le risorse interne di CloudStack, incluso qualsiasi componente che comunichi con il Management Server, come ad esempio gli host e le VM di Sistema di CloudStack label.zoneWizard.trafficType.public=Public\: Traffico di rete tra la rete internet e le virtual machine nell\\'infrastruttura cloud. label.zoneWizard.trafficType.storage=Storage\: Traffico di rete tra i server di primary e secondary storage, come ad esempio i template delle VM e le operazioni di snapshot message.acquire.new.ip=Si prega di confermare di voler acquisire un nuovo indirizzo IP per questa rete. diff --git a/client/WEB-INF/classes/resources/messages_ja.properties b/client/WEB-INF/classes/resources/messages_ja.properties index 2380e914a75..e483a97804b 100644 --- a/client/WEB-INF/classes/resources/messages_ja.properties +++ b/client/WEB-INF/classes/resources/messages_ja.properties @@ -15,873 +15,874 @@ # specific language governing permissions and limitations # under the License. -changed.item.properties=\u9805\u76EE\u306E\u30D7\u30ED\u30D1\u30C6\u30A3\u306E\u5909\u66F4 + +changed.item.properties=\u9805\u76ee\u306e\u30d7\u30ed\u30d1\u30c6\u30a3\u306e\u5909\u66f4 confirm.enable.s3=S3\u57fa\u76e4\u30bb\u30ab\u30f3\u30c0\u30ea\u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u6709\u52b9\u5316\u3059\u308b\u305f\u3081\u306b\u306f\u3001\u4ee5\u4e0b\u306e\u60c5\u5831\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044 -confirm.enable.swift=Swift1 \u306E\u30B5\u30DD\u30FC\u30C8\u3092\u6709\u52B9\u306B\u3059\u308B\u306B\u306F\u3001\u6B21\u306E\u60C5\u5831\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -error.could.not.enable.zone=\u30BE\u30FC\u30F3\u3092\u6709\u52B9\u306B\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F -error.installWizard.message=\u554F\u984C\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002\u623B\u3063\u3066\u30A8\u30E9\u30FC\u3092\u4FEE\u6B63\u3067\u304D\u307E\u3059\u3002 -error.invalid.username.password=\u7121\u52B9\u306A\u30E6\u30FC\u30B6\u30FC\u540D\u307E\u305F\u306F\u30D1\u30B9\u30EF\u30FC\u30C9 -error.login=\u30E6\u30FC\u30B6\u30FC\u540D/\u30D1\u30B9\u30EF\u30FC\u30C9\u304C\u8A18\u9332\u3068\u4E00\u81F4\u3057\u307E\u305B\u3093\u3002 +confirm.enable.swift=Swift1 \u306e\u30b5\u30dd\u30fc\u30c8\u3092\u6709\u52b9\u306b\u3059\u308b\u306b\u306f\u3001\u6b21\u306e\u60c5\u5831\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +error.could.not.enable.zone=\u30be\u30fc\u30f3\u3092\u6709\u52b9\u306b\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f +error.installWizard.message=\u554f\u984c\u304c\u767a\u751f\u3057\u307e\u3057\u305f\u3002\u623b\u3063\u3066\u30a8\u30e9\u30fc\u3092\u4fee\u6b63\u3067\u304d\u307e\u3059\u3002 +error.invalid.username.password=\u7121\u52b9\u306a\u30e6\u30fc\u30b6\u30fc\u540d\u307e\u305f\u306f\u30d1\u30b9\u30ef\u30fc\u30c9 +error.login=\u30e6\u30fc\u30b6\u30fc\u540d/\u30d1\u30b9\u30ef\u30fc\u30c9\u304c\u8a18\u9332\u3068\u4e00\u81f4\u3057\u307e\u305b\u3093\u3002 error.menu.select=\u00e3\u0082\u00a2\u00e3\u0082\u00a4\u00e3\u0083\u0086\u00e3\u0083\u00a0\u00e3\u0081\u008c\u00e9\u0081\u00b8\u00e6\u008a\u009e\u00e3\u0081\u0095\u00e3\u0082\u008c\u00e3\u0081\u00a6\u00e3\u0081\u0084\u00e3\u0081\u00aa\u00e3\u0081\u0084\u00e3\u0081\u009f\u00e3\u0082\u0081\u00e3\u0082\u00a2\u00e3\u0082\u00af\u00e3\u0082\u00b7\u00e3\u0083\u00a7\u00e3\u0083\u00b3\u00e3\u0082\u0092\u00e5\u00ae\u009f\u00e8\u00a1\u008c\u00e3\u0081\u0099\u00e3\u0082\u008b\u00e3\u0081\u0093\u00e3\u0081\u00a8\u00e3\u0081\u008c\u00e3\u0081\u00a7\u00e3\u0081\u008d\u00e3\u0081\u00be\u00e3\u0081\u009b\u00e3\u0082\u0093 -error.mgmt.server.inaccessible=\u7BA1\u7406\u30B5\u30FC\u30D0\u30FC\u306B\u30A2\u30AF\u30BB\u30B9\u3067\u304D\u307E\u305B\u3093\u3002\u5F8C\u3067\u518D\u5B9F\u884C\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -error.password.not.match=\u30D1\u30B9\u30EF\u30FC\u30C9\u304C\u4E00\u81F4\u3057\u307E\u305B\u3093 -error.please.specify.physical.network.tags=\u3053\u306E\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u30BF\u30B0\u3092\u6307\u5B9A\u3057\u306A\u3051\u308C\u3070\u3001\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306F\u4F7F\u7528\u3067\u304D\u307E\u305B\u3093\u3002 -error.session.expired=\u30BB\u30C3\u30B7\u30E7\u30F3\u306E\u6709\u52B9\u671F\u9650\u304C\u5207\u308C\u307E\u3057\u305F\u3002 -error.something.went.wrong.please.correct.the.following=\u554F\u984C\u304C\u767A\u751F\u3057\u307E\u3057\u305F\u3002\u6B21\u306E\u5185\u5BB9\u3092\u4FEE\u6B63\u3057\u3066\u304F\u3060\u3055\u3044 -error.unable.to.reach.management.server=\u7BA1\u7406\u30B5\u30FC\u30D0\u30FC\u3068\u901A\u4FE1\u3067\u304D\u307E\u305B\u3093 +error.mgmt.server.inaccessible=\u7ba1\u7406\u30b5\u30fc\u30d0\u30fc\u306b\u30a2\u30af\u30bb\u30b9\u3067\u304d\u307e\u305b\u3093\u3002\u5f8c\u3067\u518d\u5b9f\u884c\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +error.password.not.match=\u30d1\u30b9\u30ef\u30fc\u30c9\u304c\u4e00\u81f4\u3057\u307e\u305b\u3093 +error.please.specify.physical.network.tags=\u3053\u306e\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u30bf\u30b0\u3092\u6307\u5b9a\u3057\u306a\u3051\u308c\u3070\u3001\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306f\u4f7f\u7528\u3067\u304d\u307e\u305b\u3093\u3002 +error.session.expired=\u30bb\u30c3\u30b7\u30e7\u30f3\u306e\u6709\u52b9\u671f\u9650\u304c\u5207\u308c\u307e\u3057\u305f\u3002 +error.something.went.wrong.please.correct.the.following=\u554f\u984c\u304c\u767a\u751f\u3057\u307e\u3057\u305f\u3002\u6b21\u306e\u5185\u5bb9\u3092\u4fee\u6b63\u3057\u3066\u304f\u3060\u3055\u3044 +error.unable.to.reach.management.server=\u7ba1\u7406\u30b5\u30fc\u30d0\u30fc\u3068\u901a\u4fe1\u3067\u304d\u307e\u305b\u3093 error.unresolved.internet.name=\u3042\u306a\u305f\u306e\u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8\u540d\u306f\u89e3\u6c7a\u3055\u308c\u307e\u305b\u3093\u3067\u3057\u305f\u3002 -extractable=\u62BD\u51FA\u53EF\u80FD -force.delete.domain.warning=\u8B66\u544A\: \u3053\u306E\u30AA\u30D7\u30B7\u30E7\u30F3\u3092\u9078\u629E\u3059\u308B\u3068\u3001\u3059\u3079\u3066\u306E\u5B50\u30C9\u30E1\u30A4\u30F3\u304A\u3088\u3073\u95A2\u9023\u3059\u308B\u3059\u3079\u3066\u306E\u30A2\u30AB\u30A6\u30F3\u30C8\u3068\u305D\u306E\u30EA\u30BD\u30FC\u30B9\u304C\u524A\u9664\u3055\u308C\u307E\u3059\u3002 -force.delete=\u5F37\u5236\u524A\u9664 -force.remove.host.warning=\u8B66\u544A\: \u3053\u306E\u30AA\u30D7\u30B7\u30E7\u30F3\u3092\u9078\u629E\u3059\u308B\u3068\u3001\u5B9F\u884C\u4E2D\u306E\u3059\u3079\u3066\u306E\u4EEE\u60F3\u30DE\u30B7\u30F3\u304C\u5F37\u5236\u7684\u306B\u505C\u6B62\u3055\u308C\u3001\u30AF\u30E9\u30B9\u30BF\u30FC\u304B\u3089\u3053\u306E\u30DB\u30B9\u30C8\u304C\u5F37\u5236\u7684\u306B\u89E3\u9664\u3055\u308C\u307E\u3059\u3002 -force.remove=\u5F37\u5236\u89E3\u9664 -force.stop.instance.warning=\u8B66\u544A\: \u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u5F37\u5236\u505C\u6B62\u306F\u3001\u6700\u7D42\u624B\u6BB5\u306B\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u30C7\u30FC\u30BF\u3092\u640D\u5931\u3059\u308B\u3060\u3051\u3067\u306A\u304F\u3001\u4EEE\u60F3\u30DE\u30B7\u30F3\u306E\u52D5\u4F5C\u304C\u4E00\u8CAB\u3057\u306A\u304F\u306A\u308B\u53EF\u80FD\u6027\u304C\u3042\u308A\u307E\u3059\u3002 -force.stop=\u5F37\u5236\u505C\u6B62 -ICMP.code=ICMP \u30B3\u30FC\u30C9 -ICMP.type=ICMP \u306E\u7A2E\u985E -image.directory=\u753B\u50CF\u30C7\u30A3\u30EC\u30AF\u30C8\u30EA -inline=\u76F4\u5217 -instances.actions.reboot.label=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u518D\u8D77\u52D5 -label.accept.project.invitation=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u3078\u306E\u62DB\u5F85\u306E\u627F\u8AFE -label.account.and.security.group=\u30A2\u30AB\u30A6\u30F3\u30C8\u3001\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7 -label.account.id=\u30A2\u30AB\u30A6\u30F3\u30C8 ID -label.account.name=\u30A2\u30AB\u30A6\u30F3\u30C8\u540D -label.account.specific=\u30A2\u30AB\u30A6\u30F3\u30C8\u56FA\u6709 -label.accounts=\u30A2\u30AB\u30A6\u30F3\u30C8 -label.account=\u30A2\u30AB\u30A6\u30F3\u30C8 -label.acquire.new.ip=\u65B0\u3057\u3044 IP \u30A2\u30C9\u30EC\u30B9\u306E\u53D6\u5F97 -label.action.attach.disk.processing=\u30C7\u30A3\u30B9\u30AF\u3092\u30A2\u30BF\u30C3\u30C1\u3057\u3066\u3044\u307E\u3059... -label.action.attach.disk=\u30C7\u30A3\u30B9\u30AF\u306E\u30A2\u30BF\u30C3\u30C1 -label.action.attach.iso=ISO \u306E\u30A2\u30BF\u30C3\u30C1 -label.action.attach.iso.processing=ISO \u3092\u30A2\u30BF\u30C3\u30C1\u3057\u3066\u3044\u307E\u3059... -label.action.cancel.maintenance.mode.processing=\u4FDD\u5B88\u30E2\u30FC\u30C9\u3092\u30AD\u30E3\u30F3\u30BB\u30EB\u3057\u3066\u3044\u307E\u3059... -label.action.cancel.maintenance.mode=\u4FDD\u5B88\u30E2\u30FC\u30C9\u306E\u30AD\u30E3\u30F3\u30BB\u30EB -label.action.change.password=\u30D1\u30B9\u30EF\u30FC\u30C9\u306E\u5909\u66F4 -label.action.change.service.processing=\u30B5\u30FC\u30D3\u30B9\u3092\u5909\u66F4\u3057\u3066\u3044\u307E\u3059... -label.action.change.service=\u30B5\u30FC\u30D3\u30B9\u306E\u5909\u66F4 -label.action.copy.ISO=ISO \u306E\u30B3\u30D4\u30FC -label.action.copy.ISO.processing=ISO \u3092\u30B3\u30D4\u30FC\u3057\u3066\u3044\u307E\u3059... -label.action.copy.template.processing=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u30B3\u30D4\u30FC\u3057\u3066\u3044\u307E\u3059... -label.action.copy.template=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u30B3\u30D4\u30FC -label.action.create.template.from.vm=VM \u304B\u3089\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u4F5C\u6210 -label.action.create.template.from.volume=\u30DC\u30EA\u30E5\u30FC\u30E0\u304B\u3089\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u4F5C\u6210 -label.action.create.template.processing=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u4F5C\u6210\u3057\u3066\u3044\u307E\u3059... -label.action.create.template=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u4F5C\u6210 -label.action.create.vm.processing=VM \u3092\u4F5C\u6210\u3057\u3066\u3044\u307E\u3059... -label.action.create.vm=VM \u306E\u4F5C\u6210 -label.action.create.volume.processing=\u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u4F5C\u6210\u3057\u3066\u3044\u307E\u3059... -label.action.create.volume=\u30DC\u30EA\u30E5\u30FC\u30E0\u306E\u4F5C\u6210 -label.action.delete.account.processing=\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.account=\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u524A\u9664 -label.action.delete.cluster.processing=\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.cluster=\u30AF\u30E9\u30B9\u30BF\u30FC\u306E\u524A\u9664 -label.action.delete.disk.offering.processing=\u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.disk.offering=\u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u524A\u9664 -label.action.delete.domain.processing=\u30C9\u30E1\u30A4\u30F3\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.domain=\u30C9\u30E1\u30A4\u30F3\u306E\u524A\u9664 -label.action.delete.firewall.processing=\u30D5\u30A1\u30A4\u30A2\u30A6\u30A9\u30FC\u30EB\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.firewall=\u30D5\u30A1\u30A4\u30A2\u30A6\u30A9\u30FC\u30EB\u898F\u5247\u306E\u524A\u9664 -label.action.delete.ingress.rule.processing=\u53D7\u4FE1\u898F\u5247\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.ingress.rule=\u53D7\u4FE1\u898F\u5247\u306E\u524A\u9664 -label.action.delete.IP.range=IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u306E\u524A\u9664 -label.action.delete.IP.range.processing=IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.ISO=ISO \u306E\u524A\u9664 -label.action.delete.ISO.processing=ISO \u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.load.balancer.processing=\u8CA0\u8377\u5206\u6563\u88C5\u7F6E\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.load.balancer=\u8CA0\u8377\u5206\u6563\u898F\u5247\u306E\u524A\u9664 -label.action.delete.network.processing=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.network=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u524A\u9664 -label.action.delete.nexusVswitch=Nexus 1000V \u306E\u524A\u9664 -label.action.delete.physical.network=\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u524A\u9664 -label.action.delete.pod.processing=\u30DD\u30C3\u30C9\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.pod=\u30DD\u30C3\u30C9\u306E\u524A\u9664 -label.action.delete.primary.storage.processing=\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.primary.storage=\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u306E\u524A\u9664 -label.action.delete.secondary.storage.processing=\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.secondary.storage=\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u306E\u524A\u9664 -label.action.delete.security.group.processing=\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.security.group=\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u306E\u524A\u9664 -label.action.delete.service.offering.processing=\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.service.offering=\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u524A\u9664 -label.action.delete.snapshot.processing=\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.snapshot=\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u306E\u524A\u9664 -label.action.delete.system.service.offering=\u30B7\u30B9\u30C6\u30E0 \u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u524A\u9664 -label.action.delete.template.processing=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.template=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u524A\u9664 -label.action.delete.user.processing=\u30E6\u30FC\u30B6\u30FC\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.user=\u30E6\u30FC\u30B6\u30FC\u306E\u524A\u9664 -label.action.delete.volume.processing=\u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.volume=\u30DC\u30EA\u30E5\u30FC\u30E0\u306E\u524A\u9664 -label.action.delete.zone.processing=\u30BE\u30FC\u30F3\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.delete.zone=\u30BE\u30FC\u30F3\u306E\u524A\u9664 -label.action.destroy.instance.processing=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u7834\u68C4\u3057\u3066\u3044\u307E\u3059... -label.action.destroy.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u7834\u68C4 -label.action.destroy.systemvm.processing=\u30B7\u30B9\u30C6\u30E0 VM \u3092\u7834\u68C4\u3057\u3066\u3044\u307E\u3059... -label.action.destroy.systemvm=\u30B7\u30B9\u30C6\u30E0 VM \u306E\u7834\u68C4 -label.action.detach.disk.processing=\u30C7\u30A3\u30B9\u30AF\u3092\u30C7\u30BF\u30C3\u30C1\u3057\u3066\u3044\u307E\u3059... -label.action.detach.disk=\u30C7\u30A3\u30B9\u30AF\u306E\u30C7\u30BF\u30C3\u30C1 -label.action.detach.iso=ISO \u306E\u30C7\u30BF\u30C3\u30C1 -label.action.detach.iso.processing=ISO \u3092\u30C7\u30BF\u30C3\u30C1\u3057\u3066\u3044\u307E\u3059... -label.action.disable.account.processing=\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u7121\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.disable.account=\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u7121\u52B9\u5316 -label.action.disable.cluster.processing=\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u7121\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.disable.cluster=\u30AF\u30E9\u30B9\u30BF\u30FC\u306E\u7121\u52B9\u5316 -label.action.disable.nexusVswitch=Nexus 1000V \u306E\u7121\u52B9\u5316 -label.action.disable.physical.network=\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u7121\u52B9\u5316 -label.action.disable.pod.processing=\u30DD\u30C3\u30C9\u3092\u7121\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.disable.pod=\u30DD\u30C3\u30C9\u306E\u7121\u52B9\u5316 -label.action.disable.static.NAT.processing=\u9759\u7684 NAT \u3092\u7121\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.disable.static.NAT=\u9759\u7684 NAT \u306E\u7121\u52B9\u5316 -label.action.disable.user.processing=\u30E6\u30FC\u30B6\u30FC\u3092\u7121\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.disable.user=\u30E6\u30FC\u30B6\u30FC\u306E\u7121\u52B9\u5316 -label.action.disable.zone.processing=\u30BE\u30FC\u30F3\u3092\u7121\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.disable.zone=\u30BE\u30FC\u30F3\u306E\u7121\u52B9\u5316 -label.action.download.ISO=ISO \u306E\u30C0\u30A6\u30F3\u30ED\u30FC\u30C9 -label.action.download.template=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u30C0\u30A6\u30F3\u30ED\u30FC\u30C9 -label.action.download.volume.processing=\u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u30C0\u30A6\u30F3\u30ED\u30FC\u30C9\u3057\u3066\u3044\u307E\u3059... -label.action.download.volume=\u30DC\u30EA\u30E5\u30FC\u30E0\u306E\u30C0\u30A6\u30F3\u30ED\u30FC\u30C9 -label.action.edit.account=\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u7DE8\u96C6 -label.action.edit.disk.offering=\u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u7DE8\u96C6 -label.action.edit.domain=\u30C9\u30E1\u30A4\u30F3\u306E\u7DE8\u96C6 -label.action.edit.global.setting=\u30B0\u30ED\u30FC\u30D0\u30EB\u8A2D\u5B9A\u306E\u7DE8\u96C6 -label.action.edit.host=\u30DB\u30B9\u30C8\u306E\u7DE8\u96C6 -label.action.edit.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u7DE8\u96C6 -label.action.edit.ISO=ISO \u306E\u7DE8\u96C6 -label.action.edit.network.offering=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u7DE8\u96C6 -label.action.edit.network.processing=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u7DE8\u96C6\u3057\u3066\u3044\u307E\u3059... -label.action.edit.network=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u7DE8\u96C6 -label.action.edit.pod=\u30DD\u30C3\u30C9\u306E\u7DE8\u96C6 -label.action.edit.primary.storage=\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u306E\u7DE8\u96C6 -label.action.edit.resource.limits=\u30EA\u30BD\u30FC\u30B9\u5236\u9650\u306E\u7DE8\u96C6 -label.action.edit.service.offering=\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u7DE8\u96C6 -label.action.edit.template=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u7DE8\u96C6 -label.action.edit.user=\u30E6\u30FC\u30B6\u30FC\u306E\u7DE8\u96C6 -label.action.edit.zone=\u30BE\u30FC\u30F3\u306E\u7DE8\u96C6 -label.action.enable.account.processing=\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u6709\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.enable.account=\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u6709\u52B9\u5316 -label.action.enable.cluster.processing=\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u6709\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.enable.cluster=\u30AF\u30E9\u30B9\u30BF\u30FC\u306E\u6709\u52B9\u5316 -label.action.enable.maintenance.mode.processing=\u4FDD\u5B88\u30E2\u30FC\u30C9\u3092\u6709\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.enable.maintenance.mode=\u4FDD\u5B88\u30E2\u30FC\u30C9\u306E\u6709\u52B9\u5316 -label.action.enable.nexusVswitch=Nexus 1000V \u306E\u6709\u52B9\u5316 -label.action.enable.physical.network=\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u6709\u52B9\u5316 -label.action.enable.pod.processing=\u30DD\u30C3\u30C9\u3092\u6709\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.enable.pod=\u30DD\u30C3\u30C9\u306E\u6709\u52B9\u5316 -label.action.enable.static.NAT.processing=\u9759\u7684 NAT \u3092\u6709\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.enable.static.NAT=\u9759\u7684 NAT \u306E\u6709\u52B9\u5316 -label.action.enable.user.processing=\u30E6\u30FC\u30B6\u30FC\u3092\u6709\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.enable.user=\u30E6\u30FC\u30B6\u30FC\u306E\u6709\u52B9\u5316 -label.action.enable.zone.processing=\u30BE\u30FC\u30F3\u3092\u6709\u52B9\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.enable.zone=\u30BE\u30FC\u30F3\u306E\u6709\u52B9\u5316 -label.action.force.reconnect.processing=\u518D\u63A5\u7D9A\u3057\u3066\u3044\u307E\u3059... -label.action.force.reconnect=\u5F37\u5236\u518D\u63A5\u7D9A -label.action.generate.keys.processing=\u30AD\u30FC\u3092\u751F\u6210\u3057\u3066\u3044\u307E\u3059... -label.action.generate.keys=\u30AD\u30FC\u306E\u751F\u6210 -label.action.list.nexusVswitch=Nexus 1000V \u306E\u4E00\u89A7\u8868\u793A -label.action.lock.account.processing=\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u30ED\u30C3\u30AF\u3057\u3066\u3044\u307E\u3059... -label.action.lock.account=\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u30ED\u30C3\u30AF -label.action.manage.cluster.processing=\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u7BA1\u7406\u5BFE\u8C61\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.manage.cluster=\u30AF\u30E9\u30B9\u30BF\u30FC\u306E\u7BA1\u7406\u5BFE\u8C61\u5316 -label.action.migrate.instance.processing=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u79FB\u884C\u3057\u3066\u3044\u307E\u3059... -label.action.migrate.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u79FB\u884C -label.action.migrate.router.processing=\u30EB\u30FC\u30BF\u30FC\u3092\u79FB\u884C\u3057\u3066\u3044\u307E\u3059... -label.action.migrate.router=\u30EB\u30FC\u30BF\u30FC\u306E\u79FB\u884C -label.action.migrate.systemvm.processing=\u30B7\u30B9\u30C6\u30E0 VM \u3092\u79FB\u884C\u3057\u3066\u3044\u307E\u3059... -label.action.migrate.systemvm=\u30B7\u30B9\u30C6\u30E0 VM \u306E\u79FB\u884C -label.action.reboot.instance.processing=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u518D\u8D77\u52D5\u3057\u3066\u3044\u307E\u3059... -label.action.reboot.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u518D\u8D77\u52D5 -label.action.reboot.router.processing=\u30EB\u30FC\u30BF\u30FC\u3092\u518D\u8D77\u52D5\u3057\u3066\u3044\u307E\u3059... -label.action.reboot.router=\u30EB\u30FC\u30BF\u30FC\u306E\u518D\u8D77\u52D5 -label.action.reboot.systemvm.processing=\u30B7\u30B9\u30C6\u30E0 VM \u3092\u518D\u8D77\u52D5\u3057\u3066\u3044\u307E\u3059... -label.action.reboot.systemvm=\u30B7\u30B9\u30C6\u30E0 VM \u306E\u518D\u8D77\u52D5 -label.action.recurring.snapshot=\u5B9A\u671F\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8 -label.action.register.iso=ISO \u306E\u767B\u9332 -label.action.register.template=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u767B\u9332 -label.action.release.ip=IP \u30A2\u30C9\u30EC\u30B9\u306E\u89E3\u653E -label.action.release.ip.processing=IP \u30A2\u30C9\u30EC\u30B9\u3092\u89E3\u653E\u3057\u3066\u3044\u307E\u3059... -label.action.remove.host.processing=\u30DB\u30B9\u30C8\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.action.remove.host=\u30DB\u30B9\u30C8\u306E\u524A\u9664 -label.action.reset.password.processing=\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u30EA\u30BB\u30C3\u30C8\u3057\u3066\u3044\u307E\u3059... -label.action.reset.password=\u30D1\u30B9\u30EF\u30FC\u30C9\u306E\u30EA\u30BB\u30C3\u30C8 -label.action.resource.limits=\u30EA\u30BD\u30FC\u30B9\u5236\u9650 -label.action.restore.instance.processing=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u5FA9\u5143\u3057\u3066\u3044\u307E\u3059... -label.action.restore.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u5FA9\u5143 -label.action.start.instance.processing=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u8D77\u52D5\u3057\u3066\u3044\u307E\u3059... -label.action.start.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u8D77\u52D5 -label.action.start.router.processing=\u30EB\u30FC\u30BF\u30FC\u3092\u8D77\u52D5\u3057\u3066\u3044\u307E\u3059... -label.action.start.router=\u30EB\u30FC\u30BF\u30FC\u306E\u8D77\u52D5 -label.action.start.systemvm.processing=\u30B7\u30B9\u30C6\u30E0 VM \u3092\u8D77\u52D5\u3057\u3066\u3044\u307E\u3059... -label.action.start.systemvm=\u30B7\u30B9\u30C6\u30E0 VM \u306E\u8D77\u52D5 -label.action.stop.instance.processing=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u505C\u6B62\u3057\u3066\u3044\u307E\u3059... -label.action.stop.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u505C\u6B62 -label.action.stop.router.processing=\u30EB\u30FC\u30BF\u30FC\u3092\u505C\u6B62\u3057\u3066\u3044\u307E\u3059... -label.action.stop.router=\u30EB\u30FC\u30BF\u30FC\u306E\u505C\u6B62 -label.action.stop.systemvm.processing=\u30B7\u30B9\u30C6\u30E0 VM \u3092\u505C\u6B62\u3057\u3066\u3044\u307E\u3059... -label.action.stop.systemvm=\u30B7\u30B9\u30C6\u30E0 VM \u306E\u505C\u6B62 -label.actions=\u64CD\u4F5C -label.action.take.snapshot.processing=\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u3092\u4F5C\u6210\u3057\u3066\u3044\u307E\u3059.... -label.action.take.snapshot=\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u306E\u4F5C\u6210 -label.action.unmanage.cluster.processing=\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u975E\u7BA1\u7406\u5BFE\u8C61\u306B\u3057\u3066\u3044\u307E\u3059... -label.action.unmanage.cluster=\u30AF\u30E9\u30B9\u30BF\u30FC\u306E\u975E\u7BA1\u7406\u5BFE\u8C61\u5316 -label.action.update.OS.preference=OS \u57FA\u672C\u8A2D\u5B9A\u306E\u66F4\u65B0 -label.action.update.OS.preference.processing=OS \u57FA\u672C\u8A2D\u5B9A\u3092\u66F4\u65B0\u3057\u3066\u3044\u307E\u3059... -label.action.update.resource.count.processing=\u30EA\u30BD\u30FC\u30B9\u6570\u3092\u66F4\u65B0\u3057\u3066\u3044\u307E\u3059... -label.action.update.resource.count=\u30EA\u30BD\u30FC\u30B9\u6570\u306E\u66F4\u65B0 -label.activate.project=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u30A2\u30AF\u30C6\u30A3\u30D6\u5316 -label.active.sessions=\u30A2\u30AF\u30C6\u30A3\u30D6\u306A\u30BB\u30C3\u30B7\u30E7\u30F3 -label.add.accounts.to=\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u8FFD\u52A0\u5148\: -label.add.accounts=\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u8FFD\u52A0 -label.add.account.to.project=\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u3078\u306E\u8FFD\u52A0 -label.add.account=\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u8FFD\u52A0 -label.add.ACL=ACL \u306E\u8FFD\u52A0 -label.add.by.cidr=CIDR \u3067\u8FFD\u52A0 -label.add.by.group=\u30B0\u30EB\u30FC\u30D7\u3067\u8FFD\u52A0 -label.add.by=\u8FFD\u52A0\u5358\u4F4D -label.add.cluster=\u30AF\u30E9\u30B9\u30BF\u30FC\u306E\u8FFD\u52A0 -label.add.compute.offering=\u30B3\u30F3\u30D4\u30E5\u30FC\u30C6\u30A3\u30F3\u30B0 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u8FFD\u52A0 -label.add.direct.iprange=\u76F4\u63A5 IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u306E\u8FFD\u52A0 -label.add.disk.offering=\u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u8FFD\u52A0 -label.add.domain=\u30C9\u30E1\u30A4\u30F3\u306E\u8FFD\u52A0 -label.add.egress.rule=\u9001\u4FE1\u898F\u5247\u306E\u8FFD\u52A0 -label.add.F5.device=F5 \u30C7\u30D0\u30A4\u30B9\u306E\u8FFD\u52A0 -label.add.firewall=\u30D5\u30A1\u30A4\u30A2\u30A6\u30A9\u30FC\u30EB\u898F\u5247\u306E\u8FFD\u52A0 -label.add.guest.network=\u30B2\u30B9\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u8FFD\u52A0 -label.add.host=\u30DB\u30B9\u30C8\u306E\u8FFD\u52A0 -label.adding.cluster=\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u8FFD\u52A0\u3057\u3066\u3044\u307E\u3059 -label.adding.failed=\u8FFD\u52A0\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F -label.adding.pod=\u30DD\u30C3\u30C9\u3092\u8FFD\u52A0\u3057\u3066\u3044\u307E\u3059 -label.adding.processing=\u8FFD\u52A0\u3057\u3066\u3044\u307E\u3059... -label.add.ingress.rule=\u53D7\u4FE1\u898F\u5247\u306E\u8FFD\u52A0 -label.adding.succeeded=\u8FFD\u52A0\u3057\u307E\u3057\u305F -label.adding=\u8FFD\u52A0\u3057\u3066\u3044\u307E\u3059 -label.adding.user=\u30E6\u30FC\u30B6\u30FC\u3092\u8FFD\u52A0\u3057\u3066\u3044\u307E\u3059 -label.adding.zone=\u30BE\u30FC\u30F3\u3092\u8FFD\u52A0\u3057\u3066\u3044\u307E\u3059 -label.add.ip.range=IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u306E\u8FFD\u52A0 -label.additional.networks=\u8FFD\u52A0\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.add.load.balancer=\u8CA0\u8377\u5206\u6563\u88C5\u7F6E\u306E\u8FFD\u52A0 -label.add.more=\u305D\u306E\u307B\u304B\u306E\u9805\u76EE\u306E\u8FFD\u52A0 -label.add.netScaler.device=Netscaler \u30C7\u30D0\u30A4\u30B9\u306E\u8FFD\u52A0 -label.add.network.ACL=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF ACL \u306E\u8FFD\u52A0 -label.add.network.device=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30C7\u30D0\u30A4\u30B9\u306E\u8FFD\u52A0 -label.add.network.offering=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u8FFD\u52A0 -label.add.network=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u8FFD\u52A0 -label.add.new.F5=\u65B0\u3057\u3044 F5 \u306E\u8FFD\u52A0 -label.add.new.gateway=\u65B0\u3057\u3044\u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u306E\u8FFD\u52A0 -label.add.new.NetScaler=\u65B0\u3057\u3044 NetScaler \u306E\u8FFD\u52A0 -label.add.new.SRX=\u65B0\u3057\u3044 SRX \u306E\u8FFD\u52A0 -label.add.new.tier=\u65B0\u3057\u3044\u968E\u5C64\u306E\u8FFD\u52A0 +extractable=\u62bd\u51fa\u53ef\u80fd +force.delete.domain.warning=\u8b66\u544a\: \u3053\u306e\u30aa\u30d7\u30b7\u30e7\u30f3\u3092\u9078\u629e\u3059\u308b\u3068\u3001\u3059\u3079\u3066\u306e\u5b50\u30c9\u30e1\u30a4\u30f3\u304a\u3088\u3073\u95a2\u9023\u3059\u308b\u3059\u3079\u3066\u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u3068\u305d\u306e\u30ea\u30bd\u30fc\u30b9\u304c\u524a\u9664\u3055\u308c\u307e\u3059\u3002 +force.delete=\u5f37\u5236\u524a\u9664 +force.remove.host.warning=\u8b66\u544a\: \u3053\u306e\u30aa\u30d7\u30b7\u30e7\u30f3\u3092\u9078\u629e\u3059\u308b\u3068\u3001\u5b9f\u884c\u4e2d\u306e\u3059\u3079\u3066\u306e\u4eee\u60f3\u30de\u30b7\u30f3\u304c\u5f37\u5236\u7684\u306b\u505c\u6b62\u3055\u308c\u3001\u30af\u30e9\u30b9\u30bf\u30fc\u304b\u3089\u3053\u306e\u30db\u30b9\u30c8\u304c\u5f37\u5236\u7684\u306b\u89e3\u9664\u3055\u308c\u307e\u3059\u3002 +force.remove=\u5f37\u5236\u89e3\u9664 +force.stop.instance.warning=\u8b66\u544a\: \u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u5f37\u5236\u505c\u6b62\u306f\u3001\u6700\u7d42\u624b\u6bb5\u306b\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u30c7\u30fc\u30bf\u3092\u640d\u5931\u3059\u308b\u3060\u3051\u3067\u306a\u304f\u3001\u4eee\u60f3\u30de\u30b7\u30f3\u306e\u52d5\u4f5c\u304c\u4e00\u8cab\u3057\u306a\u304f\u306a\u308b\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002 +force.stop=\u5f37\u5236\u505c\u6b62 +ICMP.code=ICMP \u30b3\u30fc\u30c9 +ICMP.type=ICMP \u306e\u7a2e\u985e +image.directory=\u753b\u50cf\u30c7\u30a3\u30ec\u30af\u30c8\u30ea +inline=\u76f4\u5217 +instances.actions.reboot.label=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u518d\u8d77\u52d5 +label.accept.project.invitation=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3078\u306e\u62db\u5f85\u306e\u627f\u8afe +label.account.and.security.group=\u30a2\u30ab\u30a6\u30f3\u30c8\u3001\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7 +label.account.id=\u30a2\u30ab\u30a6\u30f3\u30c8 ID +label.account.name=\u30a2\u30ab\u30a6\u30f3\u30c8\u540d +label.account.specific=\u30a2\u30ab\u30a6\u30f3\u30c8\u56fa\u6709 +label.accounts=\u30a2\u30ab\u30a6\u30f3\u30c8 +label.account=\u30a2\u30ab\u30a6\u30f3\u30c8 +label.acquire.new.ip=\u65b0\u3057\u3044 IP \u30a2\u30c9\u30ec\u30b9\u306e\u53d6\u5f97 +label.action.attach.disk.processing=\u30c7\u30a3\u30b9\u30af\u3092\u30a2\u30bf\u30c3\u30c1\u3057\u3066\u3044\u307e\u3059... +label.action.attach.disk=\u30c7\u30a3\u30b9\u30af\u306e\u30a2\u30bf\u30c3\u30c1 +label.action.attach.iso=ISO \u306e\u30a2\u30bf\u30c3\u30c1 +label.action.attach.iso.processing=ISO \u3092\u30a2\u30bf\u30c3\u30c1\u3057\u3066\u3044\u307e\u3059... +label.action.cancel.maintenance.mode.processing=\u4fdd\u5b88\u30e2\u30fc\u30c9\u3092\u30ad\u30e3\u30f3\u30bb\u30eb\u3057\u3066\u3044\u307e\u3059... +label.action.cancel.maintenance.mode=\u4fdd\u5b88\u30e2\u30fc\u30c9\u306e\u30ad\u30e3\u30f3\u30bb\u30eb +label.action.change.password=\u30d1\u30b9\u30ef\u30fc\u30c9\u306e\u5909\u66f4 +label.action.change.service.processing=\u30b5\u30fc\u30d3\u30b9\u3092\u5909\u66f4\u3057\u3066\u3044\u307e\u3059... +label.action.change.service=\u30b5\u30fc\u30d3\u30b9\u306e\u5909\u66f4 +label.action.copy.ISO=ISO \u306e\u30b3\u30d4\u30fc +label.action.copy.ISO.processing=ISO \u3092\u30b3\u30d4\u30fc\u3057\u3066\u3044\u307e\u3059... +label.action.copy.template.processing=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u30b3\u30d4\u30fc\u3057\u3066\u3044\u307e\u3059... +label.action.copy.template=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u30b3\u30d4\u30fc +label.action.create.template.from.vm=VM \u304b\u3089\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u4f5c\u6210 +label.action.create.template.from.volume=\u30dc\u30ea\u30e5\u30fc\u30e0\u304b\u3089\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u4f5c\u6210 +label.action.create.template.processing=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059... +label.action.create.template=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u4f5c\u6210 +label.action.create.vm.processing=VM \u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059... +label.action.create.vm=VM \u306e\u4f5c\u6210 +label.action.create.volume.processing=\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059... +label.action.create.volume=\u30dc\u30ea\u30e5\u30fc\u30e0\u306e\u4f5c\u6210 +label.action.delete.account.processing=\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.account=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u524a\u9664 +label.action.delete.cluster.processing=\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.cluster=\u30af\u30e9\u30b9\u30bf\u30fc\u306e\u524a\u9664 +label.action.delete.disk.offering.processing=\u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.disk.offering=\u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u524a\u9664 +label.action.delete.domain.processing=\u30c9\u30e1\u30a4\u30f3\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.domain=\u30c9\u30e1\u30a4\u30f3\u306e\u524a\u9664 +label.action.delete.firewall.processing=\u30d5\u30a1\u30a4\u30a2\u30a6\u30a9\u30fc\u30eb\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.firewall=\u30d5\u30a1\u30a4\u30a2\u30a6\u30a9\u30fc\u30eb\u898f\u5247\u306e\u524a\u9664 +label.action.delete.ingress.rule.processing=\u53d7\u4fe1\u898f\u5247\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.ingress.rule=\u53d7\u4fe1\u898f\u5247\u306e\u524a\u9664 +label.action.delete.IP.range=IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u306e\u524a\u9664 +label.action.delete.IP.range.processing=IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.ISO=ISO \u306e\u524a\u9664 +label.action.delete.ISO.processing=ISO \u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.load.balancer.processing=\u8ca0\u8377\u5206\u6563\u88c5\u7f6e\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.load.balancer=\u8ca0\u8377\u5206\u6563\u898f\u5247\u306e\u524a\u9664 +label.action.delete.network.processing=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.network=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u524a\u9664 +label.action.delete.nexusVswitch=Nexus 1000V \u306e\u524a\u9664 +label.action.delete.physical.network=\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u524a\u9664 +label.action.delete.pod.processing=\u30dd\u30c3\u30c9\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.pod=\u30dd\u30c3\u30c9\u306e\u524a\u9664 +label.action.delete.primary.storage.processing=\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.primary.storage=\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u306e\u524a\u9664 +label.action.delete.secondary.storage.processing=\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.secondary.storage=\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u306e\u524a\u9664 +label.action.delete.security.group.processing=\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.security.group=\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u306e\u524a\u9664 +label.action.delete.service.offering.processing=\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.service.offering=\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u524a\u9664 +label.action.delete.snapshot.processing=\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.snapshot=\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u306e\u524a\u9664 +label.action.delete.system.service.offering=\u30b7\u30b9\u30c6\u30e0 \u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u524a\u9664 +label.action.delete.template.processing=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.template=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u524a\u9664 +label.action.delete.user.processing=\u30e6\u30fc\u30b6\u30fc\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.user=\u30e6\u30fc\u30b6\u30fc\u306e\u524a\u9664 +label.action.delete.volume.processing=\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.volume=\u30dc\u30ea\u30e5\u30fc\u30e0\u306e\u524a\u9664 +label.action.delete.zone.processing=\u30be\u30fc\u30f3\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.delete.zone=\u30be\u30fc\u30f3\u306e\u524a\u9664 +label.action.destroy.instance.processing=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u7834\u68c4\u3057\u3066\u3044\u307e\u3059... +label.action.destroy.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u7834\u68c4 +label.action.destroy.systemvm.processing=\u30b7\u30b9\u30c6\u30e0 VM \u3092\u7834\u68c4\u3057\u3066\u3044\u307e\u3059... +label.action.destroy.systemvm=\u30b7\u30b9\u30c6\u30e0 VM \u306e\u7834\u68c4 +label.action.detach.disk.processing=\u30c7\u30a3\u30b9\u30af\u3092\u30c7\u30bf\u30c3\u30c1\u3057\u3066\u3044\u307e\u3059... +label.action.detach.disk=\u30c7\u30a3\u30b9\u30af\u306e\u30c7\u30bf\u30c3\u30c1 +label.action.detach.iso=ISO \u306e\u30c7\u30bf\u30c3\u30c1 +label.action.detach.iso.processing=ISO \u3092\u30c7\u30bf\u30c3\u30c1\u3057\u3066\u3044\u307e\u3059... +label.action.disable.account.processing=\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u7121\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.disable.account=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u7121\u52b9\u5316 +label.action.disable.cluster.processing=\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u7121\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.disable.cluster=\u30af\u30e9\u30b9\u30bf\u30fc\u306e\u7121\u52b9\u5316 +label.action.disable.nexusVswitch=Nexus 1000V \u306e\u7121\u52b9\u5316 +label.action.disable.physical.network=\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u7121\u52b9\u5316 +label.action.disable.pod.processing=\u30dd\u30c3\u30c9\u3092\u7121\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.disable.pod=\u30dd\u30c3\u30c9\u306e\u7121\u52b9\u5316 +label.action.disable.static.NAT.processing=\u9759\u7684 NAT \u3092\u7121\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.disable.static.NAT=\u9759\u7684 NAT \u306e\u7121\u52b9\u5316 +label.action.disable.user.processing=\u30e6\u30fc\u30b6\u30fc\u3092\u7121\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.disable.user=\u30e6\u30fc\u30b6\u30fc\u306e\u7121\u52b9\u5316 +label.action.disable.zone.processing=\u30be\u30fc\u30f3\u3092\u7121\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.disable.zone=\u30be\u30fc\u30f3\u306e\u7121\u52b9\u5316 +label.action.download.ISO=ISO \u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9 +label.action.download.template=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9 +label.action.download.volume.processing=\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u3044\u307e\u3059... +label.action.download.volume=\u30dc\u30ea\u30e5\u30fc\u30e0\u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9 +label.action.edit.account=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u7de8\u96c6 +label.action.edit.disk.offering=\u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u7de8\u96c6 +label.action.edit.domain=\u30c9\u30e1\u30a4\u30f3\u306e\u7de8\u96c6 +label.action.edit.global.setting=\u30b0\u30ed\u30fc\u30d0\u30eb\u8a2d\u5b9a\u306e\u7de8\u96c6 +label.action.edit.host=\u30db\u30b9\u30c8\u306e\u7de8\u96c6 +label.action.edit.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u7de8\u96c6 +label.action.edit.ISO=ISO \u306e\u7de8\u96c6 +label.action.edit.network.offering=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u7de8\u96c6 +label.action.edit.network.processing=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u7de8\u96c6\u3057\u3066\u3044\u307e\u3059... +label.action.edit.network=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u7de8\u96c6 +label.action.edit.pod=\u30dd\u30c3\u30c9\u306e\u7de8\u96c6 +label.action.edit.primary.storage=\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u306e\u7de8\u96c6 +label.action.edit.resource.limits=\u30ea\u30bd\u30fc\u30b9\u5236\u9650\u306e\u7de8\u96c6 +label.action.edit.service.offering=\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u7de8\u96c6 +label.action.edit.template=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u7de8\u96c6 +label.action.edit.user=\u30e6\u30fc\u30b6\u30fc\u306e\u7de8\u96c6 +label.action.edit.zone=\u30be\u30fc\u30f3\u306e\u7de8\u96c6 +label.action.enable.account.processing=\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u6709\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.enable.account=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u6709\u52b9\u5316 +label.action.enable.cluster.processing=\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u6709\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.enable.cluster=\u30af\u30e9\u30b9\u30bf\u30fc\u306e\u6709\u52b9\u5316 +label.action.enable.maintenance.mode.processing=\u4fdd\u5b88\u30e2\u30fc\u30c9\u3092\u6709\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.enable.maintenance.mode=\u4fdd\u5b88\u30e2\u30fc\u30c9\u306e\u6709\u52b9\u5316 +label.action.enable.nexusVswitch=Nexus 1000V \u306e\u6709\u52b9\u5316 +label.action.enable.physical.network=\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u6709\u52b9\u5316 +label.action.enable.pod.processing=\u30dd\u30c3\u30c9\u3092\u6709\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.enable.pod=\u30dd\u30c3\u30c9\u306e\u6709\u52b9\u5316 +label.action.enable.static.NAT.processing=\u9759\u7684 NAT \u3092\u6709\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.enable.static.NAT=\u9759\u7684 NAT \u306e\u6709\u52b9\u5316 +label.action.enable.user.processing=\u30e6\u30fc\u30b6\u30fc\u3092\u6709\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.enable.user=\u30e6\u30fc\u30b6\u30fc\u306e\u6709\u52b9\u5316 +label.action.enable.zone.processing=\u30be\u30fc\u30f3\u3092\u6709\u52b9\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.enable.zone=\u30be\u30fc\u30f3\u306e\u6709\u52b9\u5316 +label.action.force.reconnect.processing=\u518d\u63a5\u7d9a\u3057\u3066\u3044\u307e\u3059... +label.action.force.reconnect=\u5f37\u5236\u518d\u63a5\u7d9a +label.action.generate.keys.processing=\u30ad\u30fc\u3092\u751f\u6210\u3057\u3066\u3044\u307e\u3059... +label.action.generate.keys=\u30ad\u30fc\u306e\u751f\u6210 +label.action.list.nexusVswitch=Nexus 1000V \u306e\u4e00\u89a7\u8868\u793a +label.action.lock.account.processing=\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u30ed\u30c3\u30af\u3057\u3066\u3044\u307e\u3059... +label.action.lock.account=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u30ed\u30c3\u30af +label.action.manage.cluster.processing=\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u7ba1\u7406\u5bfe\u8c61\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.manage.cluster=\u30af\u30e9\u30b9\u30bf\u30fc\u306e\u7ba1\u7406\u5bfe\u8c61\u5316 +label.action.migrate.instance.processing=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u79fb\u884c\u3057\u3066\u3044\u307e\u3059... +label.action.migrate.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u79fb\u884c +label.action.migrate.router.processing=\u30eb\u30fc\u30bf\u30fc\u3092\u79fb\u884c\u3057\u3066\u3044\u307e\u3059... +label.action.migrate.router=\u30eb\u30fc\u30bf\u30fc\u306e\u79fb\u884c +label.action.migrate.systemvm.processing=\u30b7\u30b9\u30c6\u30e0 VM \u3092\u79fb\u884c\u3057\u3066\u3044\u307e\u3059... +label.action.migrate.systemvm=\u30b7\u30b9\u30c6\u30e0 VM \u306e\u79fb\u884c +label.action.reboot.instance.processing=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u518d\u8d77\u52d5\u3057\u3066\u3044\u307e\u3059... +label.action.reboot.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u518d\u8d77\u52d5 +label.action.reboot.router.processing=\u30eb\u30fc\u30bf\u30fc\u3092\u518d\u8d77\u52d5\u3057\u3066\u3044\u307e\u3059... +label.action.reboot.router=\u30eb\u30fc\u30bf\u30fc\u306e\u518d\u8d77\u52d5 +label.action.reboot.systemvm.processing=\u30b7\u30b9\u30c6\u30e0 VM \u3092\u518d\u8d77\u52d5\u3057\u3066\u3044\u307e\u3059... +label.action.reboot.systemvm=\u30b7\u30b9\u30c6\u30e0 VM \u306e\u518d\u8d77\u52d5 +label.action.recurring.snapshot=\u5b9a\u671f\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8 +label.action.register.iso=ISO \u306e\u767b\u9332 +label.action.register.template=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u767b\u9332 +label.action.release.ip=IP \u30a2\u30c9\u30ec\u30b9\u306e\u89e3\u653e +label.action.release.ip.processing=IP \u30a2\u30c9\u30ec\u30b9\u3092\u89e3\u653e\u3057\u3066\u3044\u307e\u3059... +label.action.remove.host.processing=\u30db\u30b9\u30c8\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.action.remove.host=\u30db\u30b9\u30c8\u306e\u524a\u9664 +label.action.reset.password.processing=\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u30ea\u30bb\u30c3\u30c8\u3057\u3066\u3044\u307e\u3059... +label.action.reset.password=\u30d1\u30b9\u30ef\u30fc\u30c9\u306e\u30ea\u30bb\u30c3\u30c8 +label.action.resource.limits=\u30ea\u30bd\u30fc\u30b9\u5236\u9650 +label.action.restore.instance.processing=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u5fa9\u5143\u3057\u3066\u3044\u307e\u3059... +label.action.restore.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u5fa9\u5143 +label.action.start.instance.processing=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u8d77\u52d5\u3057\u3066\u3044\u307e\u3059... +label.action.start.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u8d77\u52d5 +label.action.start.router.processing=\u30eb\u30fc\u30bf\u30fc\u3092\u8d77\u52d5\u3057\u3066\u3044\u307e\u3059... +label.action.start.router=\u30eb\u30fc\u30bf\u30fc\u306e\u8d77\u52d5 +label.action.start.systemvm.processing=\u30b7\u30b9\u30c6\u30e0 VM \u3092\u8d77\u52d5\u3057\u3066\u3044\u307e\u3059... +label.action.start.systemvm=\u30b7\u30b9\u30c6\u30e0 VM \u306e\u8d77\u52d5 +label.action.stop.instance.processing=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u505c\u6b62\u3057\u3066\u3044\u307e\u3059... +label.action.stop.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u505c\u6b62 +label.action.stop.router.processing=\u30eb\u30fc\u30bf\u30fc\u3092\u505c\u6b62\u3057\u3066\u3044\u307e\u3059... +label.action.stop.router=\u30eb\u30fc\u30bf\u30fc\u306e\u505c\u6b62 +label.action.stop.systemvm.processing=\u30b7\u30b9\u30c6\u30e0 VM \u3092\u505c\u6b62\u3057\u3066\u3044\u307e\u3059... +label.action.stop.systemvm=\u30b7\u30b9\u30c6\u30e0 VM \u306e\u505c\u6b62 +label.actions=\u64cd\u4f5c +label.action.take.snapshot.processing=\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059.... +label.action.take.snapshot=\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u306e\u4f5c\u6210 +label.action.unmanage.cluster.processing=\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u975e\u7ba1\u7406\u5bfe\u8c61\u306b\u3057\u3066\u3044\u307e\u3059... +label.action.unmanage.cluster=\u30af\u30e9\u30b9\u30bf\u30fc\u306e\u975e\u7ba1\u7406\u5bfe\u8c61\u5316 +label.action.update.OS.preference=OS \u57fa\u672c\u8a2d\u5b9a\u306e\u66f4\u65b0 +label.action.update.OS.preference.processing=OS \u57fa\u672c\u8a2d\u5b9a\u3092\u66f4\u65b0\u3057\u3066\u3044\u307e\u3059... +label.action.update.resource.count.processing=\u30ea\u30bd\u30fc\u30b9\u6570\u3092\u66f4\u65b0\u3057\u3066\u3044\u307e\u3059... +label.action.update.resource.count=\u30ea\u30bd\u30fc\u30b9\u6570\u306e\u66f4\u65b0 +label.activate.project=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u30a2\u30af\u30c6\u30a3\u30d6\u5316 +label.active.sessions=\u30a2\u30af\u30c6\u30a3\u30d6\u306a\u30bb\u30c3\u30b7\u30e7\u30f3 +label.add.accounts.to=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u8ffd\u52a0\u5148\: +label.add.accounts=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u8ffd\u52a0 +label.add.account.to.project=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3078\u306e\u8ffd\u52a0 +label.add.account=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u8ffd\u52a0 +label.add.ACL=ACL \u306e\u8ffd\u52a0 +label.add.by.cidr=CIDR \u3067\u8ffd\u52a0 +label.add.by.group=\u30b0\u30eb\u30fc\u30d7\u3067\u8ffd\u52a0 +label.add.by=\u8ffd\u52a0\u5358\u4f4d +label.add.cluster=\u30af\u30e9\u30b9\u30bf\u30fc\u306e\u8ffd\u52a0 +label.add.compute.offering=\u30b3\u30f3\u30d4\u30e5\u30fc\u30c6\u30a3\u30f3\u30b0 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u8ffd\u52a0 +label.add.direct.iprange=\u76f4\u63a5 IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u306e\u8ffd\u52a0 +label.add.disk.offering=\u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u8ffd\u52a0 +label.add.domain=\u30c9\u30e1\u30a4\u30f3\u306e\u8ffd\u52a0 +label.add.egress.rule=\u9001\u4fe1\u898f\u5247\u306e\u8ffd\u52a0 +label.add.F5.device=F5 \u30c7\u30d0\u30a4\u30b9\u306e\u8ffd\u52a0 +label.add.firewall=\u30d5\u30a1\u30a4\u30a2\u30a6\u30a9\u30fc\u30eb\u898f\u5247\u306e\u8ffd\u52a0 +label.add.guest.network=\u30b2\u30b9\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u8ffd\u52a0 +label.add.host=\u30db\u30b9\u30c8\u306e\u8ffd\u52a0 +label.adding.cluster=\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u8ffd\u52a0\u3057\u3066\u3044\u307e\u3059 +label.adding.failed=\u8ffd\u52a0\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f +label.adding.pod=\u30dd\u30c3\u30c9\u3092\u8ffd\u52a0\u3057\u3066\u3044\u307e\u3059 +label.adding.processing=\u8ffd\u52a0\u3057\u3066\u3044\u307e\u3059... +label.add.ingress.rule=\u53d7\u4fe1\u898f\u5247\u306e\u8ffd\u52a0 +label.adding.succeeded=\u8ffd\u52a0\u3057\u307e\u3057\u305f +label.adding=\u8ffd\u52a0\u3057\u3066\u3044\u307e\u3059 +label.adding.user=\u30e6\u30fc\u30b6\u30fc\u3092\u8ffd\u52a0\u3057\u3066\u3044\u307e\u3059 +label.adding.zone=\u30be\u30fc\u30f3\u3092\u8ffd\u52a0\u3057\u3066\u3044\u307e\u3059 +label.add.ip.range=IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u306e\u8ffd\u52a0 +label.additional.networks=\u8ffd\u52a0\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.add.load.balancer=\u8ca0\u8377\u5206\u6563\u88c5\u7f6e\u306e\u8ffd\u52a0 +label.add.more=\u305d\u306e\u307b\u304b\u306e\u9805\u76ee\u306e\u8ffd\u52a0 +label.add.netScaler.device=Netscaler \u30c7\u30d0\u30a4\u30b9\u306e\u8ffd\u52a0 +label.add.network.ACL=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af ACL \u306e\u8ffd\u52a0 +label.add.network.device=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30c7\u30d0\u30a4\u30b9\u306e\u8ffd\u52a0 +label.add.network.offering=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u8ffd\u52a0 +label.add.network=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u8ffd\u52a0 +label.add.new.F5=\u65b0\u3057\u3044 F5 \u306e\u8ffd\u52a0 +label.add.new.gateway=\u65b0\u3057\u3044\u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u306e\u8ffd\u52a0 +label.add.new.NetScaler=\u65b0\u3057\u3044 NetScaler \u306e\u8ffd\u52a0 +label.add.new.SRX=\u65b0\u3057\u3044 SRX \u306e\u8ffd\u52a0 +label.add.new.tier=\u65b0\u3057\u3044\u968e\u5c64\u306e\u8ffd\u52a0 label.add.NiciraNvp.device=NVP\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u306e\u8ffd\u52a0 -label.add.physical.network=\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u8FFD\u52A0 -label.add.pod=\u30DD\u30C3\u30C9\u306E\u8FFD\u52A0 -label.add.port.forwarding.rule=\u30DD\u30FC\u30C8\u8EE2\u9001\u898F\u5247\u306E\u8FFD\u52A0 -label.add.primary.storage=\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u306E\u8FFD\u52A0 -label.add.resources=\u30EA\u30BD\u30FC\u30B9\u306E\u8FFD\u52A0 -label.add.route=\u30EB\u30FC\u30C8\u306E\u8FFD\u52A0 -label.add.rule=\u898F\u5247\u306E\u8FFD\u52A0 -label.add.secondary.storage=\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u306E\u8FFD\u52A0 -label.add.security.group=\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u306E\u8FFD\u52A0 -label.add.service.offering=\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u8FFD\u52A0 -label.add.SRX.device=SRX \u30C7\u30D0\u30A4\u30B9\u306E\u8FFD\u52A0 -label.add.static.nat.rule=\u9759\u7684 NAT \u898F\u5247\u306E\u8FFD\u52A0 -label.add.static.route=\u9759\u7684\u30EB\u30FC\u30C8\u306E\u8FFD\u52A0 -label.add.system.service.offering=\u30B7\u30B9\u30C6\u30E0 \u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u8FFD\u52A0 -label.add.template=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u8FFD\u52A0 -label.add.to.group=\u30B0\u30EB\u30FC\u30D7\u3078\u306E\u8FFD\u52A0 -label.add=\u8FFD\u52A0 -label.add.user=\u30E6\u30FC\u30B6\u30FC\u306E\u8FFD\u52A0 -label.add.vlan=VLAN \u306E\u8FFD\u52A0 -label.add.vms.to.lb=\u8CA0\u8377\u5206\u6563\u898F\u5247\u3078\u306E VM \u306E\u8FFD\u52A0 -label.add.vms=VM \u306E\u8FFD\u52A0 -label.add.VM.to.tier=\u968E\u5C64\u3078\u306E VM \u306E\u8FFD\u52A0 -label.add.vm=VM \u306E\u8FFD\u52A0 -label.add.volume=\u30DC\u30EA\u30E5\u30FC\u30E0\u306E\u8FFD\u52A0 -label.add.vpc=VPC \u306E\u8FFD\u52A0 -label.add.vpn.customer.gateway=VPN \u30AB\u30B9\u30BF\u30DE\u30FC \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u306E\u8FFD\u52A0 -label.add.VPN.gateway=VPN \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u306E\u8FFD\u52A0 -label.add.vpn.user=VPN \u30E6\u30FC\u30B6\u30FC\u306E\u8FFD\u52A0 -label.add.zone=\u30BE\u30FC\u30F3\u306E\u8FFD\u52A0 -label.admin.accounts=\u7BA1\u7406\u8005\u30A2\u30AB\u30A6\u30F3\u30C8 -label.admin=\u7BA1\u7406\u8005 -label.advanced.mode=\u62E1\u5F35\u30E2\u30FC\u30C9 -label.advanced.search=\u9AD8\u5EA6\u306A\u691C\u7D22 -label.advanced=\u62E1\u5F35 -label.agent.password=\u30A8\u30FC\u30B8\u30A7\u30F3\u30C8 \u30D1\u30B9\u30EF\u30FC\u30C9 -label.agent.username=\u30A8\u30FC\u30B8\u30A7\u30F3\u30C8 \u30E6\u30FC\u30B6\u30FC\u540D -label.agree=\u540C\u610F\u3059\u308B -label.alert=\u30A2\u30E9\u30FC\u30C8 -label.algorithm=\u30A2\u30EB\u30B4\u30EA\u30BA\u30E0 -label.allocated=\u5272\u308A\u5F53\u3066\u6E08\u307F -label.allocation.state=\u5272\u308A\u5F53\u3066\u72B6\u614B -label.api.key=API \u30AD\u30FC +label.add.physical.network=\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u8ffd\u52a0 +label.add.pod=\u30dd\u30c3\u30c9\u306e\u8ffd\u52a0 +label.add.port.forwarding.rule=\u30dd\u30fc\u30c8\u8ee2\u9001\u898f\u5247\u306e\u8ffd\u52a0 +label.add.primary.storage=\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u306e\u8ffd\u52a0 +label.add.resources=\u30ea\u30bd\u30fc\u30b9\u306e\u8ffd\u52a0 +label.add.route=\u30eb\u30fc\u30c8\u306e\u8ffd\u52a0 +label.add.rule=\u898f\u5247\u306e\u8ffd\u52a0 +label.add.secondary.storage=\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u306e\u8ffd\u52a0 +label.add.security.group=\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u306e\u8ffd\u52a0 +label.add.service.offering=\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u8ffd\u52a0 +label.add.SRX.device=SRX \u30c7\u30d0\u30a4\u30b9\u306e\u8ffd\u52a0 +label.add.static.nat.rule=\u9759\u7684 NAT \u898f\u5247\u306e\u8ffd\u52a0 +label.add.static.route=\u9759\u7684\u30eb\u30fc\u30c8\u306e\u8ffd\u52a0 +label.add.system.service.offering=\u30b7\u30b9\u30c6\u30e0 \u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u8ffd\u52a0 +label.add.template=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u8ffd\u52a0 +label.add.to.group=\u30b0\u30eb\u30fc\u30d7\u3078\u306e\u8ffd\u52a0 +label.add=\u8ffd\u52a0 +label.add.user=\u30e6\u30fc\u30b6\u30fc\u306e\u8ffd\u52a0 +label.add.vlan=VLAN \u306e\u8ffd\u52a0 +label.add.vms.to.lb=\u8ca0\u8377\u5206\u6563\u898f\u5247\u3078\u306e VM \u306e\u8ffd\u52a0 +label.add.vms=VM \u306e\u8ffd\u52a0 +label.add.VM.to.tier=\u968e\u5c64\u3078\u306e VM \u306e\u8ffd\u52a0 +label.add.vm=VM \u306e\u8ffd\u52a0 +label.add.volume=\u30dc\u30ea\u30e5\u30fc\u30e0\u306e\u8ffd\u52a0 +label.add.vpc=VPC \u306e\u8ffd\u52a0 +label.add.vpn.customer.gateway=VPN \u30ab\u30b9\u30bf\u30de\u30fc \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u306e\u8ffd\u52a0 +label.add.VPN.gateway=VPN \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u306e\u8ffd\u52a0 +label.add.vpn.user=VPN \u30e6\u30fc\u30b6\u30fc\u306e\u8ffd\u52a0 +label.add.zone=\u30be\u30fc\u30f3\u306e\u8ffd\u52a0 +label.admin.accounts=\u7ba1\u7406\u8005\u30a2\u30ab\u30a6\u30f3\u30c8 +label.admin=\u7ba1\u7406\u8005 +label.advanced.mode=\u62e1\u5f35\u30e2\u30fc\u30c9 +label.advanced.search=\u9ad8\u5ea6\u306a\u691c\u7d22 +label.advanced=\u62e1\u5f35 +label.agent.password=\u30a8\u30fc\u30b8\u30a7\u30f3\u30c8 \u30d1\u30b9\u30ef\u30fc\u30c9 +label.agent.username=\u30a8\u30fc\u30b8\u30a7\u30f3\u30c8 \u30e6\u30fc\u30b6\u30fc\u540d +label.agree=\u540c\u610f\u3059\u308b +label.alert=\u30a2\u30e9\u30fc\u30c8 +label.algorithm=\u30a2\u30eb\u30b4\u30ea\u30ba\u30e0 +label.allocated=\u5272\u308a\u5f53\u3066\u6e08\u307f +label.allocation.state=\u5272\u308a\u5f53\u3066\u72b6\u614b +label.api.key=API \u30ad\u30fc label.apply=\u9069\u7528 -label.assign.to.load.balancer=\u8CA0\u8377\u5206\u6563\u88C5\u7F6E\u306B\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u5272\u308A\u5F53\u3066\u3066\u3044\u307E\u3059 -label.assign=\u5272\u308A\u5F53\u3066 -label.associated.network.id=\u95A2\u9023\u3065\u3051\u3089\u308C\u305F\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF ID -label.associated.network=\u95A2\u9023\u3065\u3051\u3089\u308C\u305F\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.attached.iso=\u30A2\u30BF\u30C3\u30C1\u3055\u308C\u305F ISO -label.availability=\u53EF\u7528\u6027 -label.availability.zone=\u5229\u7528\u53EF\u80FD\u30BE\u30FC\u30F3 -label.available.public.ips=\u4F7F\u7528\u3067\u304D\u308B\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9 -label.available=\u4F7F\u7528\u53EF\u80FD -label.back=\u623B\u308B -label.bandwidth=\u5E2F\u57DF\u5E45 -label.basic.mode=\u57FA\u672C\u30E2\u30FC\u30C9 -label.basic=\u57FA\u672C -label.bootable=\u8D77\u52D5\u53EF\u80FD -label.broadcast.domain.range=\u30D6\u30ED\u30FC\u30C9\u30AD\u30E3\u30B9\u30C8 \u30C9\u30E1\u30A4\u30F3\u306E\u7BC4\u56F2 -label.broadcast.domain.type=\u30D6\u30ED\u30FC\u30C9\u30AD\u30E3\u30B9\u30C8 \u30C9\u30E1\u30A4\u30F3\u306E\u7A2E\u985E +label.assign.to.load.balancer=\u8ca0\u8377\u5206\u6563\u88c5\u7f6e\u306b\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u5272\u308a\u5f53\u3066\u3066\u3044\u307e\u3059 +label.assign=\u5272\u308a\u5f53\u3066 +label.associated.network.id=\u95a2\u9023\u3065\u3051\u3089\u308c\u305f\u30cd\u30c3\u30c8\u30ef\u30fc\u30af ID +label.associated.network=\u95a2\u9023\u3065\u3051\u3089\u308c\u305f\u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.attached.iso=\u30a2\u30bf\u30c3\u30c1\u3055\u308c\u305f ISO +label.availability=\u53ef\u7528\u6027 +label.availability.zone=\u5229\u7528\u53ef\u80fd\u30be\u30fc\u30f3 +label.available.public.ips=\u4f7f\u7528\u3067\u304d\u308b\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9 +label.available=\u4f7f\u7528\u53ef\u80fd +label.back=\u623b\u308b +label.bandwidth=\u5e2f\u57df\u5e45 +label.basic.mode=\u57fa\u672c\u30e2\u30fc\u30c9 +label.basic=\u57fa\u672c +label.bootable=\u8d77\u52d5\u53ef\u80fd +label.broadcast.domain.range=\u30d6\u30ed\u30fc\u30c9\u30ad\u30e3\u30b9\u30c8 \u30c9\u30e1\u30a4\u30f3\u306e\u7bc4\u56f2 +label.broadcast.domain.type=\u30d6\u30ed\u30fc\u30c9\u30ad\u30e3\u30b9\u30c8 \u30c9\u30e1\u30a4\u30f3\u306e\u7a2e\u985e label.broadcast.uri=Broadcast URI -label.by.account=\u30A2\u30AB\u30A6\u30F3\u30C8 -label.by.availability=\u53EF\u7528\u6027 -label.by.domain=\u30C9\u30E1\u30A4\u30F3 -label.by.end.date=\u7D42\u4E86\u65E5 -label.by.level=\u30EC\u30D9\u30EB -label.by.pod=\u30DD\u30C3\u30C9 -label.by.role=\u5F79\u5272 -label.by.start.date=\u958B\u59CB\u65E5 -label.by.state=\u72B6\u614B -label.bytes.received=\u53D7\u4FE1\u30D0\u30A4\u30C8 -label.bytes.sent=\u9001\u4FE1\u30D0\u30A4\u30C8 -label.by.traffic.type=\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u7A2E\u985E -label.by.type.id=\u7A2E\u985E ID -label.by.type=\u7A2E\u985E -label.by.zone=\u30BE\u30FC\u30F3 -label.cancel=\u30AD\u30E3\u30F3\u30BB\u30EB -label.capacity=\u51E6\u7406\u80FD\u529B -label.certificate=\u8A3C\u660E\u66F8 -label.change.service.offering=\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u5909\u66F4 -label.change.value=\u5024\u306E\u5909\u66F4 -label.character=\u6587\u5B57 -label.checksum=MD5 \u30C1\u30A7\u30C3\u30AF\u30B5\u30E0 -label.cidr.account=CIDR \u307E\u305F\u306F\u30A2\u30AB\u30A6\u30F3\u30C8/\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7 +label.by.account=\u30a2\u30ab\u30a6\u30f3\u30c8 +label.by.availability=\u53ef\u7528\u6027 +label.by.domain=\u30c9\u30e1\u30a4\u30f3 +label.by.end.date=\u7d42\u4e86\u65e5 +label.by.level=\u30ec\u30d9\u30eb +label.by.pod=\u30dd\u30c3\u30c9 +label.by.role=\u5f79\u5272 +label.by.start.date=\u958b\u59cb\u65e5 +label.by.state=\u72b6\u614b +label.bytes.received=\u53d7\u4fe1\u30d0\u30a4\u30c8 +label.bytes.sent=\u9001\u4fe1\u30d0\u30a4\u30c8 +label.by.traffic.type=\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u7a2e\u985e +label.by.type.id=\u7a2e\u985e ID +label.by.type=\u7a2e\u985e +label.by.zone=\u30be\u30fc\u30f3 +label.cancel=\u30ad\u30e3\u30f3\u30bb\u30eb +label.capacity=\u51e6\u7406\u80fd\u529b +label.certificate=\u8a3c\u660e\u66f8 +label.change.service.offering=\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u5909\u66f4 +label.change.value=\u5024\u306e\u5909\u66f4 +label.character=\u6587\u5b57 +label.checksum=MD5 \u30c1\u30a7\u30c3\u30af\u30b5\u30e0 +label.cidr.account=CIDR \u307e\u305f\u306f\u30a2\u30ab\u30a6\u30f3\u30c8/\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7 label.cidr=CIDR -label.CIDR.list=CIDR \u4E00\u89A7 -label.cidr.list=\u9001\u4FE1\u5143 CIDR -label.CIDR.of.destination.network=\u5B9B\u5148\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E CIDR -label.clean.up=\u30AF\u30EA\u30FC\u30F3 \u30A2\u30C3\u30D7 -label.clear.list=\u4E00\u89A7\u306E\u6D88\u53BB -label.close=\u9589\u3058\u308B -label.cloud.console=\u30AF\u30E9\u30A6\u30C9\u7BA1\u7406\u30B3\u30F3\u30BD\u30FC\u30EB -label.cloud.managed=Cloud.com \u306B\u3088\u308B\u7BA1\u7406 -label.cluster.name=\u30AF\u30E9\u30B9\u30BF\u30FC\u540D -label.clusters=\u30AF\u30E9\u30B9\u30BF\u30FC -label.cluster.type=\u30AF\u30E9\u30B9\u30BF\u30FC\u306E\u7A2E\u985E -label.cluster=\u30AF\u30E9\u30B9\u30BF\u30FC +label.CIDR.list=CIDR \u4e00\u89a7 +label.cidr.list=\u9001\u4fe1\u5143 CIDR +label.CIDR.of.destination.network=\u5b9b\u5148\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e CIDR +label.clean.up=\u30af\u30ea\u30fc\u30f3 \u30a2\u30c3\u30d7 +label.clear.list=\u4e00\u89a7\u306e\u6d88\u53bb +label.close=\u9589\u3058\u308b +label.cloud.console=\u30af\u30e9\u30a6\u30c9\u7ba1\u7406\u30b3\u30f3\u30bd\u30fc\u30eb +label.cloud.managed=Cloud.com \u306b\u3088\u308b\u7ba1\u7406 +label.cluster.name=\u30af\u30e9\u30b9\u30bf\u30fc\u540d +label.clusters=\u30af\u30e9\u30b9\u30bf\u30fc +label.cluster.type=\u30af\u30e9\u30b9\u30bf\u30fc\u306e\u7a2e\u985e +label.cluster=\u30af\u30e9\u30b9\u30bf\u30fc label.clvm=CLVM -label.code=\u30B3\u30FC\u30C9 -label.community=\u30B3\u30DF\u30E5\u30CB\u30C6\u30A3 -label.compute.and.storage=\u30B3\u30F3\u30D4\u30E5\u30FC\u30C6\u30A3\u30F3\u30B0\u3068\u30B9\u30C8\u30EC\u30FC\u30B8 -label.compute.offerings=\u30B3\u30F3\u30D4\u30E5\u30FC\u30C6\u30A3\u30F3\u30B0 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.compute.offering=\u30B3\u30F3\u30D4\u30E5\u30FC\u30C6\u30A3\u30F3\u30B0 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.compute=\u30B3\u30F3\u30D4\u30E5\u30FC\u30C6\u30A3\u30F3\u30B0 -label.configuration=\u69CB\u6210 -label.configure.network.ACLs=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF ACL \u306E\u69CB\u6210 -label.configure=\u69CB\u6210 -label.configure.vpc=VPC \u306E\u69CB\u6210 -label.confirmation=\u78BA\u8A8D -label.confirm.password=\u30D1\u30B9\u30EF\u30FC\u30C9\u306E\u78BA\u8A8D\u5165\u529B -label.congratulations=\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u306F\u3053\u308C\u3067\u5B8C\u4E86\u3067\u3059\u3002 -label.conserve.mode=\u7BC0\u7D04\u30E2\u30FC\u30C9 -label.console.proxy=\u30B3\u30F3\u30BD\u30FC\u30EB \u30D7\u30ED\u30AD\u30B7 -label.continue.basic.install=\u57FA\u672C\u30A4\u30F3\u30B9\u30C8\u30FC\u30EB\u3092\u7D9A\u884C\u3059\u308B -label.continue=\u7D9A\u884C -label.corrections.saved=\u63A5\u7D9A\u304C\u4FDD\u5B58\u3055\u308C\u307E\u3057\u305F -label.cpu.allocated.for.VMs=VM \u306B\u5272\u308A\u5F53\u3066\u6E08\u307F\u306E CPU -label.cpu.allocated=\u5272\u308A\u5F53\u3066\u6E08\u307F\u306E CPU +label.code=\u30b3\u30fc\u30c9 +label.community=\u30b3\u30df\u30e5\u30cb\u30c6\u30a3 +label.compute.and.storage=\u30b3\u30f3\u30d4\u30e5\u30fc\u30c6\u30a3\u30f3\u30b0\u3068\u30b9\u30c8\u30ec\u30fc\u30b8 +label.compute.offerings=\u30b3\u30f3\u30d4\u30e5\u30fc\u30c6\u30a3\u30f3\u30b0 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.compute.offering=\u30b3\u30f3\u30d4\u30e5\u30fc\u30c6\u30a3\u30f3\u30b0 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.compute=\u30b3\u30f3\u30d4\u30e5\u30fc\u30c6\u30a3\u30f3\u30b0 +label.configuration=\u69cb\u6210 +label.configure.network.ACLs=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af ACL \u306e\u69cb\u6210 +label.configure=\u69cb\u6210 +label.configure.vpc=VPC \u306e\u69cb\u6210 +label.confirmation=\u78ba\u8a8d +label.confirm.password=\u30d1\u30b9\u30ef\u30fc\u30c9\u306e\u78ba\u8a8d\u5165\u529b +label.congratulations=\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u306f\u3053\u308c\u3067\u5b8c\u4e86\u3067\u3059\u3002 +label.conserve.mode=\u7bc0\u7d04\u30e2\u30fc\u30c9 +label.console.proxy=\u30b3\u30f3\u30bd\u30fc\u30eb \u30d7\u30ed\u30ad\u30b7 +label.continue.basic.install=\u57fa\u672c\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3092\u7d9a\u884c\u3059\u308b +label.continue=\u7d9a\u884c +label.corrections.saved=\u63a5\u7d9a\u304c\u4fdd\u5b58\u3055\u308c\u307e\u3057\u305f +label.cpu.allocated.for.VMs=VM \u306b\u5272\u308a\u5f53\u3066\u6e08\u307f\u306e CPU +label.cpu.allocated=\u5272\u308a\u5f53\u3066\u6e08\u307f\u306e CPU label.CPU.cap=CPU \u5236\u9650 label.cpu=CPU label.cpu.mhz=CPU (MHz) -label.cpu.utilized=CPU \u4F7F\u7528\u7387 -label.created.by.system=\u30B7\u30B9\u30C6\u30E0\u4F5C\u6210 -label.created=\u4F5C\u6210\u65E5\u6642 -label.create.project=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u4F5C\u6210 -label.create.template=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u4F5C\u6210 -label.create.VPN.connection=VPN \u63A5\u7D9A\u306E\u4F5C\u6210 -label.cross.zones=\u30AF\u30ED\u30B9 \u30BE\u30FC\u30F3 -label.custom.disk.size=\u30AB\u30B9\u30BF\u30E0 \u30C7\u30A3\u30B9\u30AF \u30B5\u30A4\u30BA -label.daily=\u6BCE\u65E5 -label.data.disk.offering=\u30C7\u30FC\u30BF \u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.date=\u65E5\u6642 -label.day.of.month=\u6BCE\u6708\u6307\u5B9A\u65E5 -label.day.of.week=\u6BCE\u9031\u6307\u5B9A\u65E5 -label.dead.peer.detection=\u505C\u6B62\u30D4\u30A2\u306E\u691C\u51FA -label.decline.invitation=\u62DB\u5F85\u306E\u8F9E\u9000 -label.dedicated=\u5C02\u7528 -label.default=\u30C7\u30D5\u30A9\u30EB\u30C8 -label.default.use=\u30C7\u30D5\u30A9\u30EB\u30C8\u4F7F\u7528 -label.default.view=\u30C7\u30D5\u30A9\u30EB\u30C8 \u30D3\u30E5\u30FC -label.delete.F5=F5 \u306E\u524A\u9664 -label.delete.gateway=\u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u306E\u524A\u9664 -label.delete.NetScaler=NetScaler \u306E\u524A\u9664 +label.cpu.utilized=CPU \u4f7f\u7528\u7387 +label.created.by.system=\u30b7\u30b9\u30c6\u30e0\u4f5c\u6210 +label.created=\u4f5c\u6210\u65e5\u6642 +label.create.project=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u4f5c\u6210 +label.create.template=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u4f5c\u6210 +label.create.VPN.connection=VPN \u63a5\u7d9a\u306e\u4f5c\u6210 +label.cross.zones=\u30af\u30ed\u30b9 \u30be\u30fc\u30f3 +label.custom.disk.size=\u30ab\u30b9\u30bf\u30e0 \u30c7\u30a3\u30b9\u30af \u30b5\u30a4\u30ba +label.daily=\u6bce\u65e5 +label.data.disk.offering=\u30c7\u30fc\u30bf \u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.date=\u65e5\u6642 +label.day.of.month=\u6bce\u6708\u6307\u5b9a\u65e5 +label.day.of.week=\u6bce\u9031\u6307\u5b9a\u65e5 +label.dead.peer.detection=\u505c\u6b62\u30d4\u30a2\u306e\u691c\u51fa +label.decline.invitation=\u62db\u5f85\u306e\u8f9e\u9000 +label.dedicated=\u5c02\u7528 +label.default=\u30c7\u30d5\u30a9\u30eb\u30c8 +label.default.use=\u30c7\u30d5\u30a9\u30eb\u30c8\u4f7f\u7528 +label.default.view=\u30c7\u30d5\u30a9\u30eb\u30c8 \u30d3\u30e5\u30fc +label.delete.F5=F5 \u306e\u524a\u9664 +label.delete.gateway=\u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u306e\u524a\u9664 +label.delete.NetScaler=NetScaler \u306e\u524a\u9664 label.delete.NiciraNvp=NVP\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u306e\u524a\u9664 -label.delete.project=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u524A\u9664 -label.delete.SRX=SRX \u306E\u524A\u9664 -label.delete=\u524A\u9664 -label.delete.VPN.connection=VPN \u63A5\u7D9A\u306E\u524A\u9664 -label.delete.VPN.customer.gateway=VPN \u30AB\u30B9\u30BF\u30DE\u30FC \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u306E\u524A\u9664 -label.delete.VPN.gateway=VPN \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u306E\u524A\u9664 -label.delete.vpn.user=VPN \u30E6\u30FC\u30B6\u30FC\u306E\u524A\u9664 -label.deleting.failed=\u524A\u9664\u3067\u304D\u307E\u305B\u3093\u3067\u3057\u305F -label.deleting.processing=\u524A\u9664\u3057\u3066\u3044\u307E\u3059... -label.description=\u8AAC\u660E -label.destination.physical.network.id=\u30D6\u30EA\u30C3\u30B8\u5148\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF ID -label.destination.zone=\u30B3\u30D4\u30FC\u5148\u30BE\u30FC\u30F3 -label.destroy.router=\u30EB\u30FC\u30BF\u30FC\u306E\u7834\u68C4 +label.delete.project=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u524a\u9664 +label.delete.SRX=SRX \u306e\u524a\u9664 +label.delete=\u524a\u9664 +label.delete.VPN.connection=VPN \u63a5\u7d9a\u306e\u524a\u9664 +label.delete.VPN.customer.gateway=VPN \u30ab\u30b9\u30bf\u30de\u30fc \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u306e\u524a\u9664 +label.delete.VPN.gateway=VPN \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u306e\u524a\u9664 +label.delete.vpn.user=VPN \u30e6\u30fc\u30b6\u30fc\u306e\u524a\u9664 +label.deleting.failed=\u524a\u9664\u3067\u304d\u307e\u305b\u3093\u3067\u3057\u305f +label.deleting.processing=\u524a\u9664\u3057\u3066\u3044\u307e\u3059... +label.description=\u8aac\u660e +label.destination.physical.network.id=\u30d6\u30ea\u30c3\u30b8\u5148\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af ID +label.destination.zone=\u30b3\u30d4\u30fc\u5148\u30be\u30fc\u30f3 +label.destroy.router=\u30eb\u30fc\u30bf\u30fc\u306e\u7834\u68c4 label.destroy=\u7834\u68c4 -label.detaching.disk=\u30C7\u30A3\u30B9\u30AF\u3092\u30C7\u30BF\u30C3\u30C1\u3057\u3066\u3044\u307E\u3059 -label.details=\u8A73\u7D30 -label.device.id=\u30C7\u30D0\u30A4\u30B9 ID -label.devices=\u30C7\u30D0\u30A4\u30B9 +label.detaching.disk=\u30c7\u30a3\u30b9\u30af\u3092\u30c7\u30bf\u30c3\u30c1\u3057\u3066\u3044\u307e\u3059 +label.details=\u8a73\u7d30 +label.device.id=\u30c7\u30d0\u30a4\u30b9 ID +label.devices=\u30c7\u30d0\u30a4\u30b9 label.dhcp=DHCP -label.DHCP.server.type=DHCP \u30B5\u30FC\u30D0\u30FC\u306E\u7A2E\u985E -label.direct.ips=\u76F4\u63A5 IP \u30A2\u30C9\u30EC\u30B9 -label.disabled=\u7121\u52B9 -label.disable.provider=\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E\u7121\u52B9\u5316 -label.disable.vpn=VPN \u306E\u7121\u52B9\u5316 -label.disabling.vpn.access=VPN \u30A2\u30AF\u30BB\u30B9\u3092\u7121\u52B9\u306B\u3057\u3066\u3044\u307E\u3059 -label.disk.allocated=\u5272\u308A\u5F53\u3066\u6E08\u307F\u306E\u30C7\u30A3\u30B9\u30AF -label.disk.offering=\u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.disk.size.gb=\u30C7\u30A3\u30B9\u30AF \u30B5\u30A4\u30BA (GB \u5358\u4F4D) -label.disk.size=\u30C7\u30A3\u30B9\u30AF \u30B5\u30A4\u30BA -label.disk.total=\u30C7\u30A3\u30B9\u30AF\u5408\u8A08 -label.disk.volume=\u30C7\u30A3\u30B9\u30AF \u30DC\u30EA\u30E5\u30FC\u30E0 -label.display.name=\u8868\u793A\u540D -label.display.text=\u8868\u793A\u30C6\u30AD\u30B9\u30C8 +label.DHCP.server.type=DHCP \u30b5\u30fc\u30d0\u30fc\u306e\u7a2e\u985e +label.direct.ips=\u76f4\u63a5 IP \u30a2\u30c9\u30ec\u30b9 +label.disabled=\u7121\u52b9 +label.disable.provider=\u30d7\u30ed\u30d0\u30a4\u30c0\u30fc\u306e\u7121\u52b9\u5316 +label.disable.vpn=VPN \u306e\u7121\u52b9\u5316 +label.disabling.vpn.access=VPN \u30a2\u30af\u30bb\u30b9\u3092\u7121\u52b9\u306b\u3057\u3066\u3044\u307e\u3059 +label.disk.allocated=\u5272\u308a\u5f53\u3066\u6e08\u307f\u306e\u30c7\u30a3\u30b9\u30af +label.disk.offering=\u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.disk.size.gb=\u30c7\u30a3\u30b9\u30af \u30b5\u30a4\u30ba (GB \u5358\u4f4d) +label.disk.size=\u30c7\u30a3\u30b9\u30af \u30b5\u30a4\u30ba +label.disk.total=\u30c7\u30a3\u30b9\u30af\u5408\u8a08 +label.disk.volume=\u30c7\u30a3\u30b9\u30af \u30dc\u30ea\u30e5\u30fc\u30e0 +label.display.name=\u8868\u793a\u540d +label.display.text=\u8868\u793a\u30c6\u30ad\u30b9\u30c8 label.dns.1=DNS 1 label.dns.2=DNS 2 label.dns=DNS -label.DNS.domain.for.guest.networks=\u30B2\u30B9\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E DNS \u30C9\u30E1\u30A4\u30F3 -label.domain.admin=\u30C9\u30E1\u30A4\u30F3\u7BA1\u7406\u8005 -label.domain.id=\u30C9\u30E1\u30A4\u30F3 ID -label.domain.name=\u30C9\u30E1\u30A4\u30F3\u540D -label.domain.router=\u30C9\u30E1\u30A4\u30F3 \u30EB\u30FC\u30BF\u30FC -label.domain.suffix=DNS \u30C9\u30E1\u30A4\u30F3 \u30B5\u30D5\u30A3\u30C3\u30AF\u30B9 (\u4F8B\: xyz.com) -label.domain=\u30C9\u30E1\u30A4\u30F3 -label.done=\u5B8C\u4E86 -label.double.quotes.are.not.allowed=\u4E8C\u91CD\u5F15\u7528\u7B26\u306F\u4F7F\u7528\u3067\u304D\u307E\u305B\u3093 -label.download.progress=\u30C0\u30A6\u30F3\u30ED\u30FC\u30C9\u306E\u9032\u6357\u72B6\u6CC1 -label.drag.new.position=\u65B0\u3057\u3044\u4F4D\u7F6E\u306B\u30C9\u30E9\u30C3\u30B0 -label.edit.lb.rule=\u8CA0\u8377\u5206\u6563\u898F\u5247\u306E\u7DE8\u96C6 -label.edit.network.details=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u8A73\u7D30\u306E\u7DE8\u96C6 -label.edit.project.details=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u8A73\u7D30\u306E\u7DE8\u96C6 -label.edit.tags=\u30BF\u30B0\u306E\u7DE8\u96C6 -label.edit.traffic.type=\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u7A2E\u985E\u306E\u7DE8\u96C6 -label.edit=\u7DE8\u96C6 -label.edit.vpc=VPC \u306E\u7DE8\u96C6 +label.DNS.domain.for.guest.networks=\u30b2\u30b9\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e DNS \u30c9\u30e1\u30a4\u30f3 +label.domain.admin=\u30c9\u30e1\u30a4\u30f3\u7ba1\u7406\u8005 +label.domain.id=\u30c9\u30e1\u30a4\u30f3 ID +label.domain.name=\u30c9\u30e1\u30a4\u30f3\u540d +label.domain.router=\u30c9\u30e1\u30a4\u30f3 \u30eb\u30fc\u30bf\u30fc +label.domain.suffix=DNS \u30c9\u30e1\u30a4\u30f3 \u30b5\u30d5\u30a3\u30c3\u30af\u30b9 (\u4f8b\: xyz.com) +label.domain=\u30c9\u30e1\u30a4\u30f3 +label.done=\u5b8c\u4e86 +label.double.quotes.are.not.allowed=\u4e8c\u91cd\u5f15\u7528\u7b26\u306f\u4f7f\u7528\u3067\u304d\u307e\u305b\u3093 +label.download.progress=\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u306e\u9032\u6357\u72b6\u6cc1 +label.drag.new.position=\u65b0\u3057\u3044\u4f4d\u7f6e\u306b\u30c9\u30e9\u30c3\u30b0 +label.edit.lb.rule=\u8ca0\u8377\u5206\u6563\u898f\u5247\u306e\u7de8\u96c6 +label.edit.network.details=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u8a73\u7d30\u306e\u7de8\u96c6 +label.edit.project.details=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u8a73\u7d30\u306e\u7de8\u96c6 +label.edit.tags=\u30bf\u30b0\u306e\u7de8\u96c6 +label.edit.traffic.type=\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u7a2e\u985e\u306e\u7de8\u96c6 +label.edit=\u7de8\u96c6 +label.edit.vpc=VPC \u306e\u7de8\u96c6 label.egress.rules=\u9001\u4fe1\u30eb\u30fc\u30eb -label.egress.rule=\u9001\u4FE1\u898F\u5247 -label.elastic.IP=\u30A8\u30E9\u30B9\u30C6\u30A3\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9 -label.elastic.LB=\u30A8\u30E9\u30B9\u30C6\u30A3\u30C3\u30AF\u8CA0\u8377\u5206\u6563 -label.elastic=\u30A8\u30E9\u30B9\u30C6\u30A3\u30C3\u30AF -label.email=\u96FB\u5B50\u30E1\u30FC\u30EB -label.enable.provider=\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E\u6709\u52B9\u5316 +label.egress.rule=\u9001\u4fe1\u898f\u5247 +label.elastic.IP=\u30a8\u30e9\u30b9\u30c6\u30a3\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9 +label.elastic.LB=\u30a8\u30e9\u30b9\u30c6\u30a3\u30c3\u30af\u8ca0\u8377\u5206\u6563 +label.elastic=\u30a8\u30e9\u30b9\u30c6\u30a3\u30c3\u30af +label.email=\u96fb\u5b50\u30e1\u30fc\u30eb +label.enable.provider=\u30d7\u30ed\u30d0\u30a4\u30c0\u30fc\u306e\u6709\u52b9\u5316 label.enable.s3=S3\u57fa\u76e4\u30bb\u30ab\u30f3\u30c0\u30ea\u30b9\u30c8\u30ec\u30fc\u30b8\u306e\u6709\u52b9\u5316 -label.enable.swift=Swift \u306E\u6709\u52B9\u5316 -label.enable.vpn=VPN \u306E\u6709\u52B9\u5316 -label.enabling.vpn.access=VPN \u30A2\u30AF\u30BB\u30B9\u3092\u6709\u52B9\u306B\u3057\u3066\u3044\u307E\u3059 -label.enabling.vpn=VPN \u3092\u6709\u52B9\u306B\u3057\u3066\u3044\u307E\u3059 -label.end.IP=\u7D42\u4E86 IP \u30A2\u30C9\u30EC\u30B9 -label.endpoint.or.operation=\u30A8\u30F3\u30C9\u30DD\u30A4\u30F3\u30C8\u307E\u305F\u306F\u64CD\u4F5C +label.enable.swift=Swift \u306e\u6709\u52b9\u5316 +label.enable.vpn=VPN \u306e\u6709\u52b9\u5316 +label.enabling.vpn.access=VPN \u30a2\u30af\u30bb\u30b9\u3092\u6709\u52b9\u306b\u3057\u3066\u3044\u307e\u3059 +label.enabling.vpn=VPN \u3092\u6709\u52b9\u306b\u3057\u3066\u3044\u307e\u3059 +label.end.IP=\u7d42\u4e86 IP \u30a2\u30c9\u30ec\u30b9 +label.endpoint.or.operation=\u30a8\u30f3\u30c9\u30dd\u30a4\u30f3\u30c8\u307e\u305f\u306f\u64cd\u4f5c label.endpoint=\u30a8\u30f3\u30c9\u30dd\u30a4\u30f3\u30c8 -label.end.port=\u7D42\u4E86\u30DD\u30FC\u30C8 -label.end.reserved.system.IP=\u4E88\u7D04\u6E08\u307F\u7D42\u4E86\u30B7\u30B9\u30C6\u30E0 IP \u30A2\u30C9\u30EC\u30B9 -label.end.vlan=\u7D42\u4E86 VLAN -label.enter.token=\u30C8\u30FC\u30AF\u30F3\u306E\u5165\u529B -label.error.code=\u30A8\u30E9\u30FC \u30B3\u30FC\u30C9 -label.error=\u30A8\u30E9\u30FC -label.ESP.encryption=ESP \u6697\u53F7\u5316 -label.ESP.hash=ESP \u30CF\u30C3\u30B7\u30E5 -label.ESP.policy=ESP \u30DD\u30EA\u30B7\u30FC -label.esx.host=ESX/ESXi \u30DB\u30B9\u30C8 -label.example=\u4F8B +label.end.port=\u7d42\u4e86\u30dd\u30fc\u30c8 +label.end.reserved.system.IP=\u4e88\u7d04\u6e08\u307f\u7d42\u4e86\u30b7\u30b9\u30c6\u30e0 IP \u30a2\u30c9\u30ec\u30b9 +label.end.vlan=\u7d42\u4e86 VLAN +label.enter.token=\u30c8\u30fc\u30af\u30f3\u306e\u5165\u529b +label.error.code=\u30a8\u30e9\u30fc \u30b3\u30fc\u30c9 +label.error=\u30a8\u30e9\u30fc +label.ESP.encryption=ESP \u6697\u53f7\u5316 +label.ESP.hash=ESP \u30cf\u30c3\u30b7\u30e5 +label.ESP.policy=ESP \u30dd\u30ea\u30b7\u30fc +label.esx.host=ESX/ESXi \u30db\u30b9\u30c8 +label.example=\u4f8b label.f5=F5 label.failed=\u5931\u6557 -label.featured=\u304A\u3059\u3059\u3081 -label.fetch.latest=\u6700\u65B0\u60C5\u5831\u306E\u53D6\u5F97 -label.filterBy=\u30D5\u30A3\u30EB\u30BF\u30FC -label.firewall=\u30D5\u30A1\u30A4\u30A2\u30A6\u30A9\u30FC\u30EB -label.first.name=\u540D -label.format=\u5F62\u5F0F -label.friday=\u91D1\u66DC\u65E5 -label.full.path=\u30D5\u30EB \u30D1\u30B9 -label.full=\u5B8C\u5168 -label.gateway=\u30B2\u30FC\u30C8\u30A6\u30A7\u30A4 -label.general.alerts=\u4E00\u822C\u30A2\u30E9\u30FC\u30C8 -label.generating.url=URL \u3092\u751F\u6210\u3057\u3066\u3044\u307E\u3059 -label.go.step.2=\u624B\u9806 2 \u306B\u9032\u3080 -label.go.step.3=\u624B\u9806 3 \u306B\u9032\u3080 -label.go.step.4=\u624B\u9806 4 \u306B\u9032\u3080 -label.go.step.5=\u624B\u9806 5 \u306B\u9032\u3080 -label.group.optional=\u30B0\u30EB\u30FC\u30D7 (\u30AA\u30D7\u30B7\u30E7\u30F3) -label.group=\u30B0\u30EB\u30FC\u30D7 -label.guest.cidr=\u30B2\u30B9\u30C8 CIDR -label.guest.end.ip=\u30B2\u30B9\u30C8\u306E\u7D42\u4E86 IP \u30A2\u30C9\u30EC\u30B9 -label.guest.gateway=\u30B2\u30B9\u30C8 \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4 -label.guest.ip.range=\u30B2\u30B9\u30C8 IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2 -label.guest.ip=\u30B2\u30B9\u30C8 IP \u30A2\u30C9\u30EC\u30B9 -label.guest.netmask=\u30B2\u30B9\u30C8 \u30CD\u30C3\u30C8\u30DE\u30B9\u30AF -label.guest.networks=\u30B2\u30B9\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.guest.start.ip=\u30B2\u30B9\u30C8\u306E\u958B\u59CB IP \u30A2\u30C9\u30EC\u30B9 -label.guest.traffic=\u30B2\u30B9\u30C8 \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF -label.guest.type=\u30B2\u30B9\u30C8\u306E\u7A2E\u985E -label.guest=\u30B2\u30B9\u30C8 -label.ha.enabled=\u9AD8\u53EF\u7528\u6027\u6709\u52B9 -label.help=\u30D8\u30EB\u30D7 -label.hide.ingress.rule=\u53D7\u4FE1\u898F\u5247\u3092\u96A0\u3059 -label.hints=\u30D2\u30F3\u30C8 -label.host.alerts=\u30DB\u30B9\u30C8 \u30A2\u30E9\u30FC\u30C8 -label.host.MAC=\u30DB\u30B9\u30C8\u306E MAC -label.host.name=\u30DB\u30B9\u30C8\u540D -label.hosts=\u30DB\u30B9\u30C8 +label.featured=\u304a\u3059\u3059\u3081 +label.fetch.latest=\u6700\u65b0\u60c5\u5831\u306e\u53d6\u5f97 +label.filterBy=\u30d5\u30a3\u30eb\u30bf\u30fc +label.firewall=\u30d5\u30a1\u30a4\u30a2\u30a6\u30a9\u30fc\u30eb +label.first.name=\u540d +label.format=\u5f62\u5f0f +label.friday=\u91d1\u66dc\u65e5 +label.full.path=\u30d5\u30eb \u30d1\u30b9 +label.full=\u5b8c\u5168 +label.gateway=\u30b2\u30fc\u30c8\u30a6\u30a7\u30a4 +label.general.alerts=\u4e00\u822c\u30a2\u30e9\u30fc\u30c8 +label.generating.url=URL \u3092\u751f\u6210\u3057\u3066\u3044\u307e\u3059 +label.go.step.2=\u624b\u9806 2 \u306b\u9032\u3080 +label.go.step.3=\u624b\u9806 3 \u306b\u9032\u3080 +label.go.step.4=\u624b\u9806 4 \u306b\u9032\u3080 +label.go.step.5=\u624b\u9806 5 \u306b\u9032\u3080 +label.group.optional=\u30b0\u30eb\u30fc\u30d7 (\u30aa\u30d7\u30b7\u30e7\u30f3) +label.group=\u30b0\u30eb\u30fc\u30d7 +label.guest.cidr=\u30b2\u30b9\u30c8 CIDR +label.guest.end.ip=\u30b2\u30b9\u30c8\u306e\u7d42\u4e86 IP \u30a2\u30c9\u30ec\u30b9 +label.guest.gateway=\u30b2\u30b9\u30c8 \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4 +label.guest.ip.range=\u30b2\u30b9\u30c8 IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2 +label.guest.ip=\u30b2\u30b9\u30c8 IP \u30a2\u30c9\u30ec\u30b9 +label.guest.netmask=\u30b2\u30b9\u30c8 \u30cd\u30c3\u30c8\u30de\u30b9\u30af +label.guest.networks=\u30b2\u30b9\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.guest.start.ip=\u30b2\u30b9\u30c8\u306e\u958b\u59cb IP \u30a2\u30c9\u30ec\u30b9 +label.guest.traffic=\u30b2\u30b9\u30c8 \u30c8\u30e9\u30d5\u30a3\u30c3\u30af +label.guest.type=\u30b2\u30b9\u30c8\u306e\u7a2e\u985e +label.guest=\u30b2\u30b9\u30c8 +label.ha.enabled=\u9ad8\u53ef\u7528\u6027\u6709\u52b9 +label.help=\u30d8\u30eb\u30d7 +label.hide.ingress.rule=\u53d7\u4fe1\u898f\u5247\u3092\u96a0\u3059 +label.hints=\u30d2\u30f3\u30c8 +label.host.alerts=\u30db\u30b9\u30c8 \u30a2\u30e9\u30fc\u30c8 +label.host.MAC=\u30db\u30b9\u30c8\u306e MAC +label.host.name=\u30db\u30b9\u30c8\u540d +label.hosts=\u30db\u30b9\u30c8 label.host.tags=\u00e3\u0083\u009b\u00e3\u0082\u00b9\u00e3\u0083\u0088\u00e3\u0082\u00bf\u00e3\u0082\u00b0 -label.host=\u30DB\u30B9\u30C8 -label.hourly=\u6BCE\u6642 -label.hypervisor.capabilities=\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u306E\u6A5F\u80FD -label.hypervisor.type=\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u306E\u7A2E\u985E -label.hypervisor=\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC -label.hypervisor.version=\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u306E\u30D0\u30FC\u30B8\u30E7\u30F3 +label.host=\u30db\u30b9\u30c8 +label.hourly=\u6bce\u6642 +label.hypervisor.capabilities=\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc\u306e\u6a5f\u80fd +label.hypervisor.type=\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc\u306e\u7a2e\u985e +label.hypervisor=\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc +label.hypervisor.version=\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc\u306e\u30d0\u30fc\u30b8\u30e7\u30f3 label.id=ID label.IKE.DH=IKE DH -label.IKE.encryption=IKE \u6697\u53F7\u5316 -label.IKE.hash=IKE \u30CF\u30C3\u30B7\u30E5 -label.IKE.policy=IKE \u30DD\u30EA\u30B7\u30FC -label.info=\u60C5\u5831 -label.ingress.rule=\u53D7\u4FE1\u898F\u5247 -label.initiated.by=\u958B\u59CB\u30E6\u30FC\u30B6\u30FC -label.installWizard.addClusterIntro.subtitle=\u30AF\u30E9\u30B9\u30BF\u30FC\u306B\u3064\u3044\u3066 -label.installWizard.addClusterIntro.title=\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u8FFD\u52A0\u3057\u307E\u3057\u3087\u3046 -label.installWizard.addHostIntro.subtitle=\u30DB\u30B9\u30C8\u306B\u3064\u3044\u3066 -label.installWizard.addHostIntro.title=\u30DB\u30B9\u30C8\u3092\u8FFD\u52A0\u3057\u307E\u3057\u3087\u3046 -label.installWizard.addPodIntro.subtitle=\u30DD\u30C3\u30C9\u306B\u3064\u3044\u3066 -label.installWizard.addPodIntro.title=\u30DD\u30C3\u30C9\u3092\u8FFD\u52A0\u3057\u307E\u3057\u3087\u3046 -label.installWizard.addPrimaryStorageIntro.subtitle=\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u306B\u3064\u3044\u3066 -label.installWizard.addPrimaryStorageIntro.title=\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u8FFD\u52A0\u3057\u307E\u3057\u3087\u3046 +label.IKE.encryption=IKE \u6697\u53f7\u5316 +label.IKE.hash=IKE \u30cf\u30c3\u30b7\u30e5 +label.IKE.policy=IKE \u30dd\u30ea\u30b7\u30fc +label.info=\u60c5\u5831 +label.ingress.rule=\u53d7\u4fe1\u898f\u5247 +label.initiated.by=\u958b\u59cb\u30e6\u30fc\u30b6\u30fc +label.installWizard.addClusterIntro.subtitle=\u30af\u30e9\u30b9\u30bf\u30fc\u306b\u3064\u3044\u3066 +label.installWizard.addClusterIntro.title=\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u8ffd\u52a0\u3057\u307e\u3057\u3087\u3046 +label.installWizard.addHostIntro.subtitle=\u30db\u30b9\u30c8\u306b\u3064\u3044\u3066 +label.installWizard.addHostIntro.title=\u30db\u30b9\u30c8\u3092\u8ffd\u52a0\u3057\u307e\u3057\u3087\u3046 +label.installWizard.addPodIntro.subtitle=\u30dd\u30c3\u30c9\u306b\u3064\u3044\u3066 +label.installWizard.addPodIntro.title=\u30dd\u30c3\u30c9\u3092\u8ffd\u52a0\u3057\u307e\u3057\u3087\u3046 +label.installWizard.addPrimaryStorageIntro.subtitle=\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u306b\u3064\u3044\u3066 +label.installWizard.addPrimaryStorageIntro.title=\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u8ffd\u52a0\u3057\u307e\u3057\u3087\u3046 label.installWizard.addSecondaryStorageIntro.subtitle=\u30bb\u30ab\u30f3\u30c0\u30ea\u30fc\u30b9\u30c8\u30ec\u30fc\u30b8\u3068\u306f\uff1f -label.installWizard.addSecondaryStorageIntro.title=\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u8FFD\u52A0\u3057\u307E\u3057\u3087\u3046 -label.installWizard.addZoneIntro.subtitle=\u30BE\u30FC\u30F3\u306B\u3064\u3044\u3066 -label.installWizard.addZoneIntro.title=\u30BE\u30FC\u30F3\u3092\u8FFD\u52A0\u3057\u307E\u3057\u3087\u3046 -label.installWizard.addZone.title=\u30BE\u30FC\u30F3\u306E\u8FFD\u52A0 -label.installWizard.click.launch=[\u8D77\u52D5] \u3092\u30AF\u30EA\u30C3\u30AF\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -label.installWizard.subtitle=\u3053\u306E\u30AC\u30A4\u30C9 \u30C4\u30A2\u30FC\u306F CloudStack&\#8482; \u74B0\u5883\u306E\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u306B\u5F79\u7ACB\u3061\u307E\u3059 -label.installWizard.title=CloudStack&\#8482; \u3078\u3088\u3046\u3053\u305D -label.instance.limits=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u5236\u9650 -label.instance.name=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u540D -label.instances=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9 -label.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9 -label.internal.dns.1=\u5185\u90E8 DNS 1 -label.internal.dns.2=\u5185\u90E8 DNS 2 -label.internal.name=\u5185\u90E8\u540D -label.interval.type=\u9593\u9694\u306E\u7A2E\u985E -label.introduction.to.cloudstack=CloudStack&\#8482; \u306E\u7D39\u4ECB -label.invalid.integer=\u7121\u52B9\u306A\u6574\u6570 -label.invalid.number=\u7121\u52B9\u306A\u6570 -label.invitations=\u62DB\u5F85\u72B6 -label.invited.accounts=\u62DB\u5F85\u6E08\u307F\u30A2\u30AB\u30A6\u30F3\u30C8 -label.invite.to=\u62DB\u5F85\u3059\u308B\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\: -label.invite=\u62DB\u5F85 -label.ip.address=IP \u30A2\u30C9\u30EC\u30B9 -label.ipaddress=IP \u30A2\u30C9\u30EC\u30B9 -label.ip.allocations=IP \u30A2\u30C9\u30EC\u30B9\u306E\u5272\u308A\u5F53\u3066 +label.installWizard.addSecondaryStorageIntro.title=\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u8ffd\u52a0\u3057\u307e\u3057\u3087\u3046 +label.installWizard.addZoneIntro.subtitle=\u30be\u30fc\u30f3\u306b\u3064\u3044\u3066 +label.installWizard.addZoneIntro.title=\u30be\u30fc\u30f3\u3092\u8ffd\u52a0\u3057\u307e\u3057\u3087\u3046 +label.installWizard.addZone.title=\u30be\u30fc\u30f3\u306e\u8ffd\u52a0 +label.installWizard.click.launch=[\u8d77\u52d5] \u3092\u30af\u30ea\u30c3\u30af\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +label.installWizard.subtitle=\u3053\u306e\u30ac\u30a4\u30c9 \u30c4\u30a2\u30fc\u306f CloudStack&\#8482; \u74b0\u5883\u306e\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u306b\u5f79\u7acb\u3061\u307e\u3059 +label.installWizard.title=CloudStack&\#8482; \u3078\u3088\u3046\u3053\u305d +label.instance.limits=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u5236\u9650 +label.instance.name=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u540d +label.instances=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9 +label.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9 +label.internal.dns.1=\u5185\u90e8 DNS 1 +label.internal.dns.2=\u5185\u90e8 DNS 2 +label.internal.name=\u5185\u90e8\u540d +label.interval.type=\u9593\u9694\u306e\u7a2e\u985e +label.introduction.to.cloudstack=CloudStack&\#8482; \u306e\u7d39\u4ecb +label.invalid.integer=\u7121\u52b9\u306a\u6574\u6570 +label.invalid.number=\u7121\u52b9\u306a\u6570 +label.invitations=\u62db\u5f85\u72b6 +label.invited.accounts=\u62db\u5f85\u6e08\u307f\u30a2\u30ab\u30a6\u30f3\u30c8 +label.invite.to=\u62db\u5f85\u3059\u308b\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\: +label.invite=\u62db\u5f85 +label.ip.address=IP \u30a2\u30c9\u30ec\u30b9 +label.ipaddress=IP \u30a2\u30c9\u30ec\u30b9 +label.ip.allocations=IP \u30a2\u30c9\u30ec\u30b9\u306e\u5272\u308a\u5f53\u3066 label.ip=IP -label.ip.limits=\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9\u306E\u5236\u9650 -label.ip.or.fqdn=IP \u30A2\u30C9\u30EC\u30B9\u307E\u305F\u306F FQDN -label.ip.range=IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2 -label.ip.ranges=IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2 -label.IPsec.preshared.key=IPsec \u4E8B\u524D\u5171\u6709\u30AD\u30FC +label.ip.limits=\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9\u306e\u5236\u9650 +label.ip.or.fqdn=IP \u30a2\u30c9\u30ec\u30b9\u307e\u305f\u306f FQDN +label.ip.range=IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2 +label.ip.ranges=IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2 +label.IPsec.preshared.key=IPsec \u4e8b\u524d\u5171\u6709\u30ad\u30fc label.ips=IP label.iscsi=iSCSI -label.is.default=\u30C7\u30D5\u30A9\u30EB\u30C8 -label.iso.boot=ISO \u8D77\u52D5 +label.is.default=\u30c7\u30d5\u30a9\u30eb\u30c8 +label.iso.boot=ISO \u8d77\u52d5 label.iso=ISO -label.isolated.networks=\u5206\u96E2\u3055\u308C\u305F\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.isolation.method=\u5206\u96E2\u65B9\u6CD5 -label.isolation.mode=\u5206\u96E2\u30E2\u30FC\u30C9 +label.isolated.networks=\u5206\u96e2\u3055\u308c\u305f\u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.isolation.method=\u5206\u96e2\u65b9\u6cd5 +label.isolation.mode=\u5206\u96e2\u30e2\u30fc\u30c9 label.isolation.uri=Isolation URI label.is.redundant.router=\u5197\u9577 label.is.shared=\u5171\u6709 -label.is.system=\u30B7\u30B9\u30C6\u30E0 -label.item.listing=\u9805\u76EE\u4E00\u89A7 -label.keep=\u7DAD\u6301 -label.keyboard.type=\u30AD\u30FC\u30DC\u30FC\u30C9\u306E\u7A2E\u985E -label.key=\u30AD\u30FC -label.kvm.traffic.label=KVM \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u30E9\u30D9\u30EB -label.label=\u30E9\u30D9\u30EB +label.is.system=\u30b7\u30b9\u30c6\u30e0 +label.item.listing=\u9805\u76ee\u4e00\u89a7 +label.keep=\u7dad\u6301 +label.keyboard.type=\u30ad\u30fc\u30dc\u30fc\u30c9\u306e\u7a2e\u985e +label.key=\u30ad\u30fc +label.kvm.traffic.label=KVM \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u30e9\u30d9\u30eb +label.label=\u30e9\u30d9\u30eb label.lang.brportugese=Brazilian Portugese -label.lang.chinese=\u7C21\u4F53\u5B57\u4E2D\u56FD\u8A9E -label.lang.english=\u82F1\u8A9E +label.lang.chinese=\u7c21\u4f53\u5b57\u4e2d\u56fd\u8a9e +label.lang.english=\u82f1\u8a9e label.lang.french=French -label.lang.japanese=\u65E5\u672C\u8A9E +label.lang.japanese=\u65e5\u672c\u8a9e label.lang.russian=Russian -label.lang.spanish=\u30B9\u30DA\u30A4\u30F3\u8A9E -label.last.disconnected=\u6700\u7D42\u5207\u65AD\u65E5\u6642 -label.last.name=\u59D3 -label.latest.events=\u6700\u65B0\u30A4\u30D9\u30F3\u30C8 -label.launch=\u8D77\u52D5 -label.launch.vm=VM \u306E\u8D77\u52D5 -label.LB.isolation=\u8CA0\u8377\u5206\u6563\u5206\u96E2 -label.least.connections=\u6700\u5C0F\u63A5\u7D9A -label.level=\u30EC\u30D9\u30EB -label.linklocal.ip=\u30EA\u30F3\u30AF \u30ED\u30FC\u30AB\u30EB IP \u30A2\u30C9\u30EC\u30B9 -label.load.balancer=\u8CA0\u8377\u5206\u6563\u88C5\u7F6E -label.load.balancing.policies=\u8CA0\u8377\u5206\u6563\u30DD\u30EA\u30B7\u30FC -label.load.balancing=\u8CA0\u8377\u5206\u6563 -label.loading=\u30ED\u30FC\u30C9\u3057\u3066\u3044\u307E\u3059 -label.local.storage.enabled=\u30ED\u30FC\u30AB\u30EB \u30B9\u30C8\u30EC\u30FC\u30B8\u306F\u6709\u52B9\u3067\u3059 -label.local.storage=\u30ED\u30FC\u30AB\u30EB \u30B9\u30C8\u30EC\u30FC\u30B8 -label.local=\u30ED\u30FC\u30AB\u30EB -label.login=\u30ED\u30B0\u30AA\u30F3 -label.logout=\u30ED\u30B0\u30AA\u30D5 +label.lang.spanish=\u30b9\u30da\u30a4\u30f3\u8a9e +label.last.disconnected=\u6700\u7d42\u5207\u65ad\u65e5\u6642 +label.last.name=\u59d3 +label.latest.events=\u6700\u65b0\u30a4\u30d9\u30f3\u30c8 +label.launch=\u8d77\u52d5 +label.launch.vm=VM \u306e\u8d77\u52d5 +label.LB.isolation=\u8ca0\u8377\u5206\u6563\u5206\u96e2 +label.least.connections=\u6700\u5c0f\u63a5\u7d9a +label.level=\u30ec\u30d9\u30eb +label.linklocal.ip=\u30ea\u30f3\u30af \u30ed\u30fc\u30ab\u30eb IP \u30a2\u30c9\u30ec\u30b9 +label.load.balancer=\u8ca0\u8377\u5206\u6563\u88c5\u7f6e +label.load.balancing.policies=\u8ca0\u8377\u5206\u6563\u30dd\u30ea\u30b7\u30fc +label.load.balancing=\u8ca0\u8377\u5206\u6563 +label.loading=\u30ed\u30fc\u30c9\u3057\u3066\u3044\u307e\u3059 +label.local.storage.enabled=\u30ed\u30fc\u30ab\u30eb \u30b9\u30c8\u30ec\u30fc\u30b8\u306f\u6709\u52b9\u3067\u3059 +label.local.storage=\u30ed\u30fc\u30ab\u30eb \u30b9\u30c8\u30ec\u30fc\u30b8 +label.local=\u30ed\u30fc\u30ab\u30eb +label.login=\u30ed\u30b0\u30aa\u30f3 +label.logout=\u30ed\u30b0\u30aa\u30d5 label.lun=LUN -label.LUN.number=LUN \u756A\u53F7 -label.make.project.owner=\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u6240\u6709\u8005\u5316 -label.management.ips=\u7BA1\u7406 IP \u30A2\u30C9\u30EC\u30B9 -label.management=\u7BA1\u7406 -label.manage.resources=\u30EA\u30BD\u30FC\u30B9\u306E\u7BA1\u7406 -label.manage=\u7BA1\u7406 -label.max.guest.limit=\u6700\u5927\u30B2\u30B9\u30C8\u5236\u9650 +label.LUN.number=LUN \u756a\u53f7 +label.make.project.owner=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u6240\u6709\u8005\u5316 +label.management.ips=\u7ba1\u7406 IP \u30a2\u30c9\u30ec\u30b9 +label.management=\u7ba1\u7406 +label.manage.resources=\u30ea\u30bd\u30fc\u30b9\u306e\u7ba1\u7406 +label.manage=\u7ba1\u7406 +label.max.guest.limit=\u6700\u5927\u30b2\u30b9\u30c8\u5236\u9650 label.maximum=\u6700\u5927 -label.max.networks=\u6700\u5927\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u6570 -label.max.public.ips=\u6700\u5927\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9\u6570 -label.max.snapshots=\u6700\u5927\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u6570 -label.max.templates=\u6700\u5927\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u6570 -label.max.vms=\u6700\u5927\u30E6\u30FC\u30B6\u30FC VM \u6570 -label.max.volumes=\u6700\u5927\u30DC\u30EA\u30E5\u30FC\u30E0\u6570 +label.max.networks=\u6700\u5927\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u6570 +label.max.public.ips=\u6700\u5927\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9\u6570 +label.max.snapshots=\u6700\u5927\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u6570 +label.max.templates=\u6700\u5927\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u6570 +label.max.vms=\u6700\u5927\u30e6\u30fc\u30b6\u30fc VM \u6570 +label.max.volumes=\u6700\u5927\u30dc\u30ea\u30e5\u30fc\u30e0\u6570 label.max.vpcs=Max. VPCs -label.may.continue=\u7D9A\u884C\u3067\u304D\u307E\u3059\u3002 -label.memory.allocated=\u5272\u308A\u5F53\u3066\u6E08\u307F\u306E\u30E1\u30E2\u30EA -label.memory.mb=\u30E1\u30E2\u30EA (MB) -label.memory.total=\u30E1\u30E2\u30EA\u5408\u8A08 -label.memory=\u30E1\u30E2\u30EA -label.memory.used=\u30E1\u30E2\u30EA\u4F7F\u7528\u91CF -label.menu.accounts=\u30A2\u30AB\u30A6\u30F3\u30C8 -label.menu.alerts=\u30A2\u30E9\u30FC\u30C8 -label.menu.all.accounts=\u3059\u3079\u3066\u306E\u30A2\u30AB\u30A6\u30F3\u30C8 -label.menu.all.instances=\u3059\u3079\u3066\u306E\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9 -label.menu.community.isos=\u30B3\u30DF\u30E5\u30CB\u30C6\u30A3 ISO -label.menu.community.templates=\u30B3\u30DF\u30E5\u30CB\u30C6\u30A3 \u30C6\u30F3\u30D7\u30EC\u30FC\u30C8 -label.menu.configuration=\u69CB\u6210 -label.menu.dashboard=\u30C0\u30C3\u30B7\u30E5\u30DC\u30FC\u30C9 -label.menu.destroyed.instances=\u7834\u68C4\u3055\u308C\u305F\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9 -label.menu.disk.offerings=\u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.menu.domains=\u30C9\u30E1\u30A4\u30F3 -label.menu.events=\u30A4\u30D9\u30F3\u30C8 -label.menu.featured.isos=\u304A\u3059\u3059\u3081\u306E ISO -label.menu.featured.templates=\u304A\u3059\u3059\u3081\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8 -label.menu.global.settings=\u30B0\u30ED\u30FC\u30D0\u30EB\u8A2D\u5B9A -label.menu.infrastructure=\u30A4\u30F3\u30D5\u30E9\u30B9\u30C8\u30E9\u30AF\u30C1\u30E3 -label.menu.instances=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9 -label.menu.ipaddresses=IP \u30A2\u30C9\u30EC\u30B9 +label.may.continue=\u7d9a\u884c\u3067\u304d\u307e\u3059\u3002 +label.memory.allocated=\u5272\u308a\u5f53\u3066\u6e08\u307f\u306e\u30e1\u30e2\u30ea +label.memory.mb=\u30e1\u30e2\u30ea (MB) +label.memory.total=\u30e1\u30e2\u30ea\u5408\u8a08 +label.memory=\u30e1\u30e2\u30ea +label.memory.used=\u30e1\u30e2\u30ea\u4f7f\u7528\u91cf +label.menu.accounts=\u30a2\u30ab\u30a6\u30f3\u30c8 +label.menu.alerts=\u30a2\u30e9\u30fc\u30c8 +label.menu.all.accounts=\u3059\u3079\u3066\u306e\u30a2\u30ab\u30a6\u30f3\u30c8 +label.menu.all.instances=\u3059\u3079\u3066\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9 +label.menu.community.isos=\u30b3\u30df\u30e5\u30cb\u30c6\u30a3 ISO +label.menu.community.templates=\u30b3\u30df\u30e5\u30cb\u30c6\u30a3 \u30c6\u30f3\u30d7\u30ec\u30fc\u30c8 +label.menu.configuration=\u69cb\u6210 +label.menu.dashboard=\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9 +label.menu.destroyed.instances=\u7834\u68c4\u3055\u308c\u305f\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9 +label.menu.disk.offerings=\u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.menu.domains=\u30c9\u30e1\u30a4\u30f3 +label.menu.events=\u30a4\u30d9\u30f3\u30c8 +label.menu.featured.isos=\u304a\u3059\u3059\u3081\u306e ISO +label.menu.featured.templates=\u304a\u3059\u3059\u3081\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8 +label.menu.global.settings=\u30b0\u30ed\u30fc\u30d0\u30eb\u8a2d\u5b9a +label.menu.infrastructure=\u30a4\u30f3\u30d5\u30e9\u30b9\u30c8\u30e9\u30af\u30c1\u30e3 +label.menu.instances=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9 +label.menu.ipaddresses=IP \u30a2\u30c9\u30ec\u30b9 label.menu.isos=ISO -label.menu.my.accounts=\u30DE\u30A4 \u30A2\u30AB\u30A6\u30F3\u30C8 -label.menu.my.instances=\u30DE\u30A4 \u30A4\u30F3\u30B9\u30BF\u30F3\u30B9 -label.menu.my.isos=\u30DE\u30A4 ISO -label.menu.my.templates=\u30DE\u30A4 \u30C6\u30F3\u30D7\u30EC\u30FC\u30C8 -label.menu.network.offerings=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.menu.network=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.menu.physical.resources=\u7269\u7406\u30EA\u30BD\u30FC\u30B9 -label.menu.running.instances=\u5B9F\u884C\u4E2D\u306E\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9 -label.menu.security.groups=\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7 -label.menu.service.offerings=\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.menu.snapshots=\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8 -label.menu.stopped.instances=\u505C\u6B62\u3055\u308C\u305F\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9 -label.menu.storage=\u30B9\u30C8\u30EC\u30FC\u30B8 -label.menu.system.service.offerings=\u30B7\u30B9\u30C6\u30E0 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.menu.system=\u30B7\u30B9\u30C6\u30E0 -label.menu.system.vms=\u30B7\u30B9\u30C6\u30E0 VM -label.menu.templates=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8 -label.menu.virtual.appliances=\u4EEE\u60F3\u30A2\u30D7\u30E9\u30A4\u30A2\u30F3\u30B9 -label.menu.virtual.resources=\u4EEE\u60F3\u30EA\u30BD\u30FC\u30B9 -label.menu.volumes=\u30DC\u30EA\u30E5\u30FC\u30E0 -label.migrate.instance.to.host=\u5225\u306E\u30DB\u30B9\u30C8\u3078\u306E\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u79FB\u884C -label.migrate.instance.to.ps=\u5225\u306E\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3078\u306E\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u79FB\u884C -label.migrate.instance.to=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u79FB\u884C\u5148\: -label.migrate.router.to=\u30EB\u30FC\u30BF\u30FC\u306E\u79FB\u884C\u5148\: -label.migrate.systemvm.to=\u30B7\u30B9\u30C6\u30E0 VM \u306E\u79FB\u884C\u5148\: +label.menu.my.accounts=\u30de\u30a4 \u30a2\u30ab\u30a6\u30f3\u30c8 +label.menu.my.instances=\u30de\u30a4 \u30a4\u30f3\u30b9\u30bf\u30f3\u30b9 +label.menu.my.isos=\u30de\u30a4 ISO +label.menu.my.templates=\u30de\u30a4 \u30c6\u30f3\u30d7\u30ec\u30fc\u30c8 +label.menu.network.offerings=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.menu.network=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.menu.physical.resources=\u7269\u7406\u30ea\u30bd\u30fc\u30b9 +label.menu.running.instances=\u5b9f\u884c\u4e2d\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9 +label.menu.security.groups=\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7 +label.menu.service.offerings=\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.menu.snapshots=\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8 +label.menu.stopped.instances=\u505c\u6b62\u3055\u308c\u305f\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9 +label.menu.storage=\u30b9\u30c8\u30ec\u30fc\u30b8 +label.menu.system.service.offerings=\u30b7\u30b9\u30c6\u30e0 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.menu.system=\u30b7\u30b9\u30c6\u30e0 +label.menu.system.vms=\u30b7\u30b9\u30c6\u30e0 VM +label.menu.templates=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8 +label.menu.virtual.appliances=\u4eee\u60f3\u30a2\u30d7\u30e9\u30a4\u30a2\u30f3\u30b9 +label.menu.virtual.resources=\u4eee\u60f3\u30ea\u30bd\u30fc\u30b9 +label.menu.volumes=\u30dc\u30ea\u30e5\u30fc\u30e0 +label.migrate.instance.to.host=\u5225\u306e\u30db\u30b9\u30c8\u3078\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u79fb\u884c +label.migrate.instance.to.ps=\u5225\u306e\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3078\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u79fb\u884c +label.migrate.instance.to=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u79fb\u884c\u5148\: +label.migrate.router.to=\u30eb\u30fc\u30bf\u30fc\u306e\u79fb\u884c\u5148\: +label.migrate.systemvm.to=\u30b7\u30b9\u30c6\u30e0 VM \u306e\u79fb\u884c\u5148\: label.migrate.to.host=\u30db\u30b9\u30c8\u3078\u79fb\u884c label.migrate.to.storage=\u30b9\u30c8\u30ec\u30fc\u30b8\u3078\u79fb\u884c -label.migrate.volume=\u5225\u306E\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3078\u306E\u30DC\u30EA\u30E5\u30FC\u30E0\u306E\u79FB\u884C -label.minimum=\u6700\u5C0F -label.minute.past.hour=\u5206 (\u6BCE\u6642) -label.monday=\u6708\u66DC\u65E5 -label.monthly=\u6BCE\u6708 -label.more.templates=\u305D\u306E\u307B\u304B\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8 -label.move.down.row=1 \u884C\u4E0B\u306B\u79FB\u52D5 -label.move.to.bottom=\u6700\u4E0B\u4F4D\u306B\u79FB\u52D5 -label.move.to.top=\u6700\u4E0A\u4F4D\u306B\u79FB\u52D5 -label.move.up.row=1 \u884C\u4E0A\u306B\u79FB\u52D5 -label.my.account=\u30DE\u30A4 \u30A2\u30AB\u30A6\u30F3\u30C8 -label.my.network=\u30DE\u30A4 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.my.templates=\u30DE\u30A4 \u30C6\u30F3\u30D7\u30EC\u30FC\u30C8 -label.name.optional=\u540D\u524D (\u30AA\u30D7\u30B7\u30E7\u30F3) -label.name=\u540D\u524D -label.nat.port.range=NAT \u30DD\u30FC\u30C8\u306E\u7BC4\u56F2 -label.netmask=\u30CD\u30C3\u30C8\u30DE\u30B9\u30AF +label.migrate.volume=\u5225\u306e\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3078\u306e\u30dc\u30ea\u30e5\u30fc\u30e0\u306e\u79fb\u884c +label.minimum=\u6700\u5c0f +label.minute.past.hour=\u5206 (\u6bce\u6642) +label.monday=\u6708\u66dc\u65e5 +label.monthly=\u6bce\u6708 +label.more.templates=\u305d\u306e\u307b\u304b\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8 +label.move.down.row=1 \u884c\u4e0b\u306b\u79fb\u52d5 +label.move.to.bottom=\u6700\u4e0b\u4f4d\u306b\u79fb\u52d5 +label.move.to.top=\u6700\u4e0a\u4f4d\u306b\u79fb\u52d5 +label.move.up.row=1 \u884c\u4e0a\u306b\u79fb\u52d5 +label.my.account=\u30de\u30a4 \u30a2\u30ab\u30a6\u30f3\u30c8 +label.my.network=\u30de\u30a4 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.my.templates=\u30de\u30a4 \u30c6\u30f3\u30d7\u30ec\u30fc\u30c8 +label.name.optional=\u540d\u524d (\u30aa\u30d7\u30b7\u30e7\u30f3) +label.name=\u540d\u524d +label.nat.port.range=NAT \u30dd\u30fc\u30c8\u306e\u7bc4\u56f2 +label.netmask=\u30cd\u30c3\u30c8\u30de\u30b9\u30af label.netScaler=NetScaler -label.network.ACLs=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF ACL -label.network.ACL.total=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF ACL \u5408\u8A08 -label.network.ACL=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF ACL -label.network.desc=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u8AAC\u660E -label.network.device.type=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30C7\u30D0\u30A4\u30B9\u306E\u7A2E\u985E -label.network.device=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30C7\u30D0\u30A4\u30B9 -label.network.domain.text=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30C9\u30E1\u30A4\u30F3 -label.network.domain=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30C9\u30E1\u30A4\u30F3 -label.network.id=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF ID -label.networking.and.security=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3068\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 -label.network.label.display.for.blank.value=\u30C7\u30D5\u30A9\u30EB\u30C8 \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u3092\u4F7F\u7528 -label.network.name=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u540D -label.network.offering.display.text=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u8868\u793A\u30C6\u30AD\u30B9\u30C8 -label.network.offering.id=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 ID -label.network.offering.name=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u540D -label.network.offering=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.network.rate.megabytes=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u901F\u5EA6 (MB/\u79D2) -label.network.rate=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u901F\u5EA6 -label.network.read=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u8AAD\u307F\u53D6\u308A -label.network.service.providers=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30B5\u30FC\u30D3\u30B9 \u30D7\u30ED\u30D0\u30A4\u30C0\u30FC -label.networks=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.network.type=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u7A2E\u985E -label.network=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.network.write=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u66F8\u304D\u8FBC\u307F -label.new.password=\u65B0\u3057\u3044\u30D1\u30B9\u30EF\u30FC\u30C9 -label.new.project=\u65B0\u3057\u3044\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8 -label.new=\u65B0\u898F -label.new.vm=\u65B0\u3057\u3044 VM -label.next=\u6B21\u3078 +label.network.ACLs=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af ACL +label.network.ACL.total=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af ACL \u5408\u8a08 +label.network.ACL=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af ACL +label.network.desc=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u8aac\u660e +label.network.device.type=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30c7\u30d0\u30a4\u30b9\u306e\u7a2e\u985e +label.network.device=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30c7\u30d0\u30a4\u30b9 +label.network.domain.text=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30c9\u30e1\u30a4\u30f3 +label.network.domain=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30c9\u30e1\u30a4\u30f3 +label.network.id=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af ID +label.networking.and.security=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3068\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 +label.network.label.display.for.blank.value=\u30c7\u30d5\u30a9\u30eb\u30c8 \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u3092\u4f7f\u7528 +label.network.name=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u540d +label.network.offering.display.text=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u8868\u793a\u30c6\u30ad\u30b9\u30c8 +label.network.offering.id=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 ID +label.network.offering.name=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u540d +label.network.offering=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.network.rate.megabytes=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u901f\u5ea6 (MB/\u79d2) +label.network.rate=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u901f\u5ea6 +label.network.read=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u8aad\u307f\u53d6\u308a +label.network.service.providers=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30b5\u30fc\u30d3\u30b9 \u30d7\u30ed\u30d0\u30a4\u30c0\u30fc +label.networks=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.network.type=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u7a2e\u985e +label.network=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.network.write=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u66f8\u304d\u8fbc\u307f +label.new.password=\u65b0\u3057\u3044\u30d1\u30b9\u30ef\u30fc\u30c9 +label.new.project=\u65b0\u3057\u3044\u30d7\u30ed\u30b8\u30a7\u30af\u30c8 +label.new=\u65b0\u898f +label.new.vm=\u65b0\u3057\u3044 VM +label.next=\u6b21\u3078 label.nexusVswitch=Nexus 1000V label.nfs=NFS -label.nfs.server=NFS \u30B5\u30FC\u30D0\u30FC -label.nfs.storage=NFS \u30B9\u30C8\u30EC\u30FC\u30B8 -label.nic.adapter.type=NIC \u30A2\u30C0\u30D7\u30BF\u30FC\u306E\u7A2E\u985E +label.nfs.server=NFS \u30b5\u30fc\u30d0\u30fc +label.nfs.storage=NFS \u30b9\u30c8\u30ec\u30fc\u30b8 +label.nic.adapter.type=NIC \u30a2\u30c0\u30d7\u30bf\u30fc\u306e\u7a2e\u985e label.nicira.controller.address=\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc\u306e\u30a2\u30c9\u30ec\u30b9 label.nicira.l3gatewayserviceuuid=L3 \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u30b5\u30fc\u30d3\u30b9UUID label.nicira.transportzoneuuid=Transport Zone Uuid label.nics=NIC -label.no.actions=\u5B9F\u884C\u3067\u304D\u308B\u64CD\u4F5C\u306F\u3042\u308A\u307E\u305B\u3093 -label.no.alerts=\u6700\u8FD1\u306E\u30A2\u30E9\u30FC\u30C8\u306F\u3042\u308A\u307E\u305B\u3093 -label.no.data=\u8868\u793A\u3059\u308B\u30C7\u30FC\u30BF\u304C\u3042\u308A\u307E\u305B\u3093 -label.no.errors=\u6700\u8FD1\u306E\u30A8\u30E9\u30FC\u306F\u3042\u308A\u307E\u305B\u3093 -label.no.isos=\u4F7F\u7528\u3067\u304D\u308B ISO \u306F\u3042\u308A\u307E\u305B\u3093 -label.no.items=\u4F7F\u7528\u3067\u304D\u308B\u9805\u76EE\u306F\u3042\u308A\u307E\u305B\u3093 -label.none=\u306A\u3057 -label.no.security.groups=\u4F7F\u7528\u3067\u304D\u308B\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u306F\u3042\u308A\u307E\u305B\u3093 -label.not.found=\u898B\u3064\u304B\u308A\u307E\u305B\u3093 -label.no.thanks=\u8A2D\u5B9A\u3057\u306A\u3044 -label.notifications=\u901A\u77E5 +label.no.actions=\u5b9f\u884c\u3067\u304d\u308b\u64cd\u4f5c\u306f\u3042\u308a\u307e\u305b\u3093 +label.no.alerts=\u6700\u8fd1\u306e\u30a2\u30e9\u30fc\u30c8\u306f\u3042\u308a\u307e\u305b\u3093 +label.no.data=\u8868\u793a\u3059\u308b\u30c7\u30fc\u30bf\u304c\u3042\u308a\u307e\u305b\u3093 +label.no.errors=\u6700\u8fd1\u306e\u30a8\u30e9\u30fc\u306f\u3042\u308a\u307e\u305b\u3093 +label.no.isos=\u4f7f\u7528\u3067\u304d\u308b ISO \u306f\u3042\u308a\u307e\u305b\u3093 +label.no.items=\u4f7f\u7528\u3067\u304d\u308b\u9805\u76ee\u306f\u3042\u308a\u307e\u305b\u3093 +label.none=\u306a\u3057 +label.no.security.groups=\u4f7f\u7528\u3067\u304d\u308b\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u306f\u3042\u308a\u307e\u305b\u3093 +label.not.found=\u898b\u3064\u304b\u308a\u307e\u305b\u3093 +label.no.thanks=\u8a2d\u5b9a\u3057\u306a\u3044 +label.notifications=\u901a\u77e5 label.no=\u3044\u3044\u3048 -label.number.of.clusters=\u30AF\u30E9\u30B9\u30BF\u30FC\u6570 -label.number.of.hosts=\u30DB\u30B9\u30C8\u6570 -label.number.of.pods=\u30DD\u30C3\u30C9\u6570 -label.number.of.system.vms=\u30B7\u30B9\u30C6\u30E0 VM \u6570 -label.number.of.virtual.routers=\u4EEE\u60F3\u30EB\u30FC\u30BF\u30FC\u6570 -label.number.of.zones=\u30BE\u30FC\u30F3\u6570 -label.num.cpu.cores=CPU \u30B3\u30A2\u6570 -label.numretries=\u518D\u8A66\u884C\u56DE\u6570 +label.number.of.clusters=\u30af\u30e9\u30b9\u30bf\u30fc\u6570 +label.number.of.hosts=\u30db\u30b9\u30c8\u6570 +label.number.of.pods=\u30dd\u30c3\u30c9\u6570 +label.number.of.system.vms=\u30b7\u30b9\u30c6\u30e0 VM \u6570 +label.number.of.virtual.routers=\u4eee\u60f3\u30eb\u30fc\u30bf\u30fc\u6570 +label.number.of.zones=\u30be\u30fc\u30f3\u6570 +label.num.cpu.cores=CPU \u30b3\u30a2\u6570 +label.numretries=\u518d\u8a66\u884c\u56de\u6570 label.ocfs2=OCFS2 -label.offer.ha=\u9AD8\u53EF\u7528\u6027\u306E\u63D0\u4F9B +label.offer.ha=\u9ad8\u53ef\u7528\u6027\u306e\u63d0\u4f9b label.ok=OK -label.optional=\u30AA\u30D7\u30B7\u30E7\u30F3 -label.order=\u9806\u5E8F -label.os.preference=OS \u57FA\u672C\u8A2D\u5B9A -label.os.type=OS \u306E\u7A2E\u985E -label.owned.public.ips=\u6240\u6709\u3059\u308B\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9 -label.owner.account=\u6240\u6709\u8005\u30A2\u30AB\u30A6\u30F3\u30C8 -label.owner.domain=\u00e6\u0089\u0080\u00e6\u009c\u0089\u00e8\u0080\u0085\u00e3\u0083\u0089\u00e3\u0083\u00a1\u00e3\u0082\u00a4\u00e3\u0083\u00b3 -label.parent.domain=\u89AA\u30C9\u30E1\u30A4\u30F3 -label.password.enabled=\u30D1\u30B9\u30EF\u30FC\u30C9\u7BA1\u7406\u6709\u52B9 -label.password=\u30D1\u30B9\u30EF\u30FC\u30C9 -label.path=\u30D1\u30B9 +label.optional=\u30aa\u30d7\u30b7\u30e7\u30f3 +label.order=\u9806\u5e8f +label.os.preference=OS \u57fa\u672c\u8a2d\u5b9a +label.os.type=OS \u306e\u7a2e\u985e +label.owned.public.ips=\u6240\u6709\u3059\u308b\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9 +label.owner.account=\u6240\u6709\u8005\u30a2\u30ab\u30a6\u30f3\u30c8 +label.owner.domain=\u00e6\u0089\u0080\u00e6\u009c\u0089\u00e8\u0080 +label.parent.domain=\u89aa\u30c9\u30e1\u30a4\u30f3 +label.password.enabled=\u30d1\u30b9\u30ef\u30fc\u30c9\u7ba1\u7406\u6709\u52b9 +label.password=\u30d1\u30b9\u30ef\u30fc\u30c9 +label.path=\u30d1\u30b9 label.perfect.forward.secrecy=Perfect Forward Secrecy -label.physical.network.ID=\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF ID -label.PING.CIFS.password=PING CIFS \u30D1\u30B9\u30EF\u30FC\u30C9 -label.PING.CIFS.username=PING CIFS \u30E6\u30FC\u30B6\u30FC\u540D -label.PING.dir=PING \u30C7\u30A3\u30EC\u30AF\u30C8\u30EA -label.PING.storage.IP=PING \u5BFE\u8C61\u306E\u30B9\u30C8\u30EC\u30FC\u30B8 IP \u30A2\u30C9\u30EC\u30B9 -label.please.specify.netscaler.info=Netscaler \u60C5\u5831\u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044 -label.please.wait=\u304A\u5F85\u3061\u304F\u3060\u3055\u3044 -label.pod.name=\u30DD\u30C3\u30C9\u540D -label.pods=\u30DD\u30C3\u30C9 -label.pod=\u30DD\u30C3\u30C9 -label.port.forwarding.policies=\u30DD\u30FC\u30C8\u8EE2\u9001\u30DD\u30EA\u30B7\u30FC -label.port.forwarding=\u30DD\u30FC\u30C8\u8EE2\u9001 -label.port.range=\u30DD\u30FC\u30C8\u306E\u7BC4\u56F2 +label.physical.network.ID=\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af ID +label.PING.CIFS.password=PING CIFS \u30d1\u30b9\u30ef\u30fc\u30c9 +label.PING.CIFS.username=PING CIFS \u30e6\u30fc\u30b6\u30fc\u540d +label.PING.dir=PING \u30c7\u30a3\u30ec\u30af\u30c8\u30ea +label.PING.storage.IP=PING \u5bfe\u8c61\u306e\u30b9\u30c8\u30ec\u30fc\u30b8 IP \u30a2\u30c9\u30ec\u30b9 +label.please.specify.netscaler.info=Netscaler \u60c5\u5831\u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044 +label.please.wait=\u304a\u5f85\u3061\u304f\u3060\u3055\u3044 +label.pod.name=\u30dd\u30c3\u30c9\u540d +label.pods=\u30dd\u30c3\u30c9 +label.pod=\u30dd\u30c3\u30c9 +label.port.forwarding.policies=\u30dd\u30fc\u30c8\u8ee2\u9001\u30dd\u30ea\u30b7\u30fc +label.port.forwarding=\u30dd\u30fc\u30c8\u8ee2\u9001 +label.port.range=\u30dd\u30fc\u30c8\u306e\u7bc4\u56f2 label.PreSetup=PreSetup -label.previous=\u623B\u308B -label.prev=\u623B\u308B -label.primary.allocated=\u5272\u308A\u5F53\u3066\u6E08\u307F\u306E\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 -label.primary.network=\u30D7\u30E9\u30A4\u30DE\u30EA \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.primary.storage.count=\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 \u30D7\u30FC\u30EB -label.primary.storage=\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 -label.primary.used=\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u4F7F\u7528\u91CF -label.private.Gateway=\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4 -label.private.interface=\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 \u30A4\u30F3\u30BF\u30FC\u30D5\u30A7\u30A4\u30B9 -label.private.ip.range=\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2 -label.private.ips=\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 IP \u30A2\u30C9\u30EC\u30B9 -label.private.ip=\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 IP \u30A2\u30C9\u30EC\u30B9 -label.privatekey=PKC\#8 \u79D8\u5BC6\u30AD\u30FC -label.private.network=\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.private.port=\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 \u30DD\u30FC\u30C8 -label.private.zone=\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 \u30BE\u30FC\u30F3 -label.project.dashboard=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8 \u30C0\u30C3\u30B7\u30E5\u30DC\u30FC\u30C9 -label.project.id=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8 ID -label.project.invite=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u3078\u306E\u62DB\u5F85 -label.project.name=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u540D -label.projects=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8 -label.project=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8 -label.project.view=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8 \u30D3\u30E5\u30FC -label.protocol=\u30D7\u30ED\u30C8\u30B3\u30EB -label.providers=\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC -label.public.interface=\u30D1\u30D6\u30EA\u30C3\u30AF \u30A4\u30F3\u30BF\u30FC\u30D5\u30A7\u30A4\u30B9 -label.public.ips=\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9 -label.public.ip=\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9 -label.public.network=\u30D1\u30D6\u30EA\u30C3\u30AF \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.public.port=\u30D1\u30D6\u30EA\u30C3\u30AF \u30DD\u30FC\u30C8 -label.public=\u30D1\u30D6\u30EA\u30C3\u30AF -label.public.zone=\u30D1\u30D6\u30EA\u30C3\u30AF \u30BE\u30FC\u30F3 -label.purpose=\u76EE\u7684 -label.Pxe.server.type=PXE \u30B5\u30FC\u30D0\u30FC\u306E\u7A2E\u985E +label.previous=\u623b\u308b +label.prev=\u623b\u308b +label.primary.allocated=\u5272\u308a\u5f53\u3066\u6e08\u307f\u306e\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 +label.primary.network=\u30d7\u30e9\u30a4\u30de\u30ea \u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.primary.storage.count=\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 \u30d7\u30fc\u30eb +label.primary.storage=\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 +label.primary.used=\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u4f7f\u7528\u91cf +label.private.Gateway=\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4 +label.private.interface=\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 \u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9 +label.private.ip.range=\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2 +label.private.ips=\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 IP \u30a2\u30c9\u30ec\u30b9 +label.private.ip=\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 IP \u30a2\u30c9\u30ec\u30b9 +label.privatekey=PKC\#8 \u79d8\u5bc6\u30ad\u30fc +label.private.network=\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.private.port=\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 \u30dd\u30fc\u30c8 +label.private.zone=\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 \u30be\u30fc\u30f3 +label.project.dashboard=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8 \u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9 +label.project.id=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8 ID +label.project.invite=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3078\u306e\u62db\u5f85 +label.project.name=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u540d +label.projects=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8 +label.project=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8 +label.project.view=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8 \u30d3\u30e5\u30fc +label.protocol=\u30d7\u30ed\u30c8\u30b3\u30eb +label.providers=\u30d7\u30ed\u30d0\u30a4\u30c0\u30fc +label.public.interface=\u30d1\u30d6\u30ea\u30c3\u30af \u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9 +label.public.ips=\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9 +label.public.ip=\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9 +label.public.network=\u30d1\u30d6\u30ea\u30c3\u30af \u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.public.port=\u30d1\u30d6\u30ea\u30c3\u30af \u30dd\u30fc\u30c8 +label.public=\u30d1\u30d6\u30ea\u30c3\u30af +label.public.zone=\u30d1\u30d6\u30ea\u30c3\u30af \u30be\u30fc\u30f3 +label.purpose=\u76ee\u7684 +label.Pxe.server.type=PXE \u30b5\u30fc\u30d0\u30fc\u306e\u7a2e\u985e label.quickview=\u30af\u30a4\u30c3\u30af\u30d3\u30e5\u30fc label.reboot=\u518d\u8d77\u52d5 -label.recent.errors=\u6700\u8FD1\u306E\u30A8\u30E9\u30FC -label.redundant.router.capability=\u5197\u9577\u30EB\u30FC\u30BF\u30FC\u6A5F\u80FD -label.redundant.router=\u5197\u9577\u30EB\u30FC\u30BF\u30FC -label.redundant.state=\u5197\u9577\u72B6\u614B -label.refresh=\u66F4\u65B0 -label.related=\u95A2\u9023 -label.remind.later=\u30A2\u30E9\u30FC\u30E0\u3092\u8868\u793A\u3059\u308B -label.remove.ACL=ACL \u306E\u524A\u9664 -label.remove.egress.rule=\u9001\u4FE1\u898F\u5247\u306E\u524A\u9664 -label.remove.from.load.balancer=\u8CA0\u8377\u5206\u6563\u88C5\u7F6E\u304B\u3089\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059 -label.remove.ingress.rule=\u53D7\u4FE1\u898F\u5247\u306E\u524A\u9664 -label.remove.ip.range=IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u306E\u524A\u9664 -label.remove.pf=\u30DD\u30FC\u30C8\u8EE2\u9001\u898F\u5247\u306E\u524A\u9664 -label.remove.rule=\u898F\u5247\u306E\u524A\u9664 -label.remove.static.nat.rule=\u9759\u7684 NAT \u898F\u5247\u306E\u524A\u9664 -label.remove.static.route=\u9759\u7684\u30EB\u30FC\u30C8\u306E\u524A\u9664 -label.remove.tier=\u968E\u5C64\u306E\u524A\u9664 -label.remove.vm.from.lb=\u8CA0\u8377\u5206\u6563\u898F\u5247\u304B\u3089\u306E VM \u306E\u524A\u9664 -label.remove.vpc=VPC \u306E\u524A\u9664 -label.removing=\u524A\u9664\u3057\u3066\u3044\u307E\u3059 -label.removing.user=\u30E6\u30FC\u30B6\u30FC\u3092\u524A\u9664\u3057\u3066\u3044\u307E\u3059 -label.required=\u5FC5\u9808\u3067\u3059 -label.reserved.system.gateway=\u4E88\u7D04\u6E08\u307F\u30B7\u30B9\u30C6\u30E0 \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4 -label.reserved.system.ip=\u4E88\u7D04\u6E08\u307F\u30B7\u30B9\u30C6\u30E0 IP \u30A2\u30C9\u30EC\u30B9 -label.reserved.system.netmask=\u4E88\u7D04\u6E08\u307F\u30B7\u30B9\u30C6\u30E0 \u30CD\u30C3\u30C8\u30DE\u30B9\u30AF -label.reset.VPN.connection=VPN \u63A5\u7D9A\u306E\u30EA\u30BB\u30C3\u30C8 -label.resource.limits=\u30EA\u30BD\u30FC\u30B9\u5236\u9650 -label.resource.state=\u30EA\u30BD\u30FC\u30B9\u306E\u72B6\u614B -label.resources=\u30EA\u30BD\u30FC\u30B9 -label.resource=\u30EA\u30BD\u30FC\u30B9 -label.restart.network=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u518D\u8D77\u52D5 -label.restart.required=\u518D\u8D77\u52D5\u304C\u5FC5\u8981 -label.restart.vpc=VPC \u306E\u518D\u8D77\u52D5 +label.recent.errors=\u6700\u8fd1\u306e\u30a8\u30e9\u30fc +label.redundant.router.capability=\u5197\u9577\u30eb\u30fc\u30bf\u30fc\u6a5f\u80fd +label.redundant.router=\u5197\u9577\u30eb\u30fc\u30bf\u30fc +label.redundant.state=\u5197\u9577\u72b6\u614b +label.refresh=\u66f4\u65b0 +label.related=\u95a2\u9023 +label.remind.later=\u30a2\u30e9\u30fc\u30e0\u3092\u8868\u793a\u3059\u308b +label.remove.ACL=ACL \u306e\u524a\u9664 +label.remove.egress.rule=\u9001\u4fe1\u898f\u5247\u306e\u524a\u9664 +label.remove.from.load.balancer=\u8ca0\u8377\u5206\u6563\u88c5\u7f6e\u304b\u3089\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059 +label.remove.ingress.rule=\u53d7\u4fe1\u898f\u5247\u306e\u524a\u9664 +label.remove.ip.range=IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u306e\u524a\u9664 +label.remove.pf=\u30dd\u30fc\u30c8\u8ee2\u9001\u898f\u5247\u306e\u524a\u9664 +label.remove.rule=\u898f\u5247\u306e\u524a\u9664 +label.remove.static.nat.rule=\u9759\u7684 NAT \u898f\u5247\u306e\u524a\u9664 +label.remove.static.route=\u9759\u7684\u30eb\u30fc\u30c8\u306e\u524a\u9664 +label.remove.tier=\u968e\u5c64\u306e\u524a\u9664 +label.remove.vm.from.lb=\u8ca0\u8377\u5206\u6563\u898f\u5247\u304b\u3089\u306e VM \u306e\u524a\u9664 +label.remove.vpc=VPC \u306e\u524a\u9664 +label.removing=\u524a\u9664\u3057\u3066\u3044\u307e\u3059 +label.removing.user=\u30e6\u30fc\u30b6\u30fc\u3092\u524a\u9664\u3057\u3066\u3044\u307e\u3059 +label.required=\u5fc5\u9808\u3067\u3059 +label.reserved.system.gateway=\u4e88\u7d04\u6e08\u307f\u30b7\u30b9\u30c6\u30e0 \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4 +label.reserved.system.ip=\u4e88\u7d04\u6e08\u307f\u30b7\u30b9\u30c6\u30e0 IP \u30a2\u30c9\u30ec\u30b9 +label.reserved.system.netmask=\u4e88\u7d04\u6e08\u307f\u30b7\u30b9\u30c6\u30e0 \u30cd\u30c3\u30c8\u30de\u30b9\u30af +label.reset.VPN.connection=VPN \u63a5\u7d9a\u306e\u30ea\u30bb\u30c3\u30c8 +label.resource.limits=\u30ea\u30bd\u30fc\u30b9\u5236\u9650 +label.resource.state=\u30ea\u30bd\u30fc\u30b9\u306e\u72b6\u614b +label.resources=\u30ea\u30bd\u30fc\u30b9 +label.resource=\u30ea\u30bd\u30fc\u30b9 +label.restart.network=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u518d\u8d77\u52d5 +label.restart.required=\u518d\u8d77\u52d5\u304c\u5fc5\u8981 +label.restart.vpc=VPC \u306e\u518d\u8d77\u52d5 label.restore=\u30ea\u30b9\u30c8\u30a2 -label.review=\u78BA\u8A8D -label.revoke.project.invite=\u62DB\u5F85\u306E\u53D6\u308A\u6D88\u3057 -label.role=\u5F79\u5272 -label.root.disk.controller=\u30EB\u30FC\u30C8 \u30C7\u30A3\u30B9\u30AF \u30B3\u30F3\u30C8\u30ED\u30FC\u30E9\u30FC -label.root.disk.offering=\u30EB\u30FC\u30C8 \u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.round.robin=\u30E9\u30A6\u30F3\u30C9\u30ED\u30D3\u30F3 -label.rules=\u898F\u5247 -label.running.vms=\u5B9F\u884C\u4E2D\u306E VM +label.review=\u78ba\u8a8d +label.revoke.project.invite=\u62db\u5f85\u306e\u53d6\u308a\u6d88\u3057 +label.role=\u5f79\u5272 +label.root.disk.controller=\u30eb\u30fc\u30c8 \u30c7\u30a3\u30b9\u30af \u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u30fc +label.root.disk.offering=\u30eb\u30fc\u30c8 \u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.round.robin=\u30e9\u30a6\u30f3\u30c9\u30ed\u30d3\u30f3 +label.rules=\u898f\u5247 +label.running.vms=\u5b9f\u884c\u4e2d\u306e VM label.s3.access_key=\u30a2\u30af\u30bb\u30b9\u30ad\u30fc label.s3.bucket=\u30d0\u30b1\u30c3\u30c8 label.s3.connection_timeout=\u30b3\u30cd\u30af\u30b7\u30e7\u30f3\u30bf\u30a4\u30e0\u30a2\u30a6\u30c8 @@ -890,569 +891,565 @@ label.s3.max_error_retry=\u30a8\u30e9\u30fc\u6642\u306e\u6700\u5927\u30ea\u30c8\ label.s3.secret_key=\u79d8\u5bc6\u9375 label.s3.socket_timeout=\u30bd\u30b1\u30c3\u30c8\u30bf\u30a4\u30e0\u30a2\u30a6\u30c8 label.s3.use_https=HTTPS\u306e\u4f7f\u7528 -label.saturday=\u571F\u66DC\u65E5 -label.save.and.continue=\u4FDD\u5B58\u3057\u3066\u7D9A\u884C -label.save=\u4FDD\u5B58 -label.saving.processing=\u4FDD\u5B58\u3057\u3066\u3044\u307E\u3059... -label.scope=\u30B9\u30B3\u30FC\u30D7 -label.search=\u691C\u7D22 -label.secondary.storage.count=\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 \u30D7\u30FC\u30EB -label.secondary.storage=\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 -label.secondary.storage.vm=\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 VM -label.secondary.used=\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u4F7F\u7528\u91CF +label.saturday=\u571f\u66dc\u65e5 +label.save.and.continue=\u4fdd\u5b58\u3057\u3066\u7d9a\u884c +label.save=\u4fdd\u5b58 +label.saving.processing=\u4fdd\u5b58\u3057\u3066\u3044\u307e\u3059... +label.scope=\u30b9\u30b3\u30fc\u30d7 +label.search=\u691c\u7d22 +label.secondary.storage.count=\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 \u30d7\u30fc\u30eb +label.secondary.storage=\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 +label.secondary.storage.vm=\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 VM +label.secondary.used=\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u4f7f\u7528\u91cf label.secret.key=\u79d8\u5bc6\u9375 -label.security.group.name=\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u540D -label.security.groups.enabled=\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u6709\u52B9 -label.security.groups=\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7 -label.security.group=\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7 -label.select.a.template=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u9078\u629E -label.select.a.zone=\u30BE\u30FC\u30F3\u306E\u9078\u629E -label.select.instance.to.attach.volume.to=\u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u30A2\u30BF\u30C3\u30C1\u3059\u308B\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044 -label.select.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u9078\u629E -label.select.iso.or.template=ISO \u307E\u305F\u306F\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u9078\u629E -label.select.offering=\u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u9078\u629E -label.select.project=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u9078\u629E -label.select.tier=\u968E\u5C64\u306E\u9078\u629E -label.select=\u9078\u629E -label.select-view=\u30D3\u30E5\u30FC\u306E\u9078\u629E -label.select.vm.for.static.nat=\u9759\u7684 NAT \u7528 VM \u306E\u9078\u629E -label.sent=\u9001\u4FE1\u6E08\u307F -label.server=\u30B5\u30FC\u30D0\u30FC -label.service.capabilities=\u30B5\u30FC\u30D3\u30B9\u306E\u6A5F\u80FD -label.service.offering=\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.session.expired=\u30BB\u30C3\u30B7\u30E7\u30F3\u306E\u6709\u52B9\u671F\u9650\u304C\u5207\u308C\u307E\u3057\u305F -label.setup.network=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7 -label.setup=\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7 -label.set.up.zone.type=\u30BE\u30FC\u30F3\u306E\u7A2E\u985E\u306E\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7 -label.setup.zone=\u30BE\u30FC\u30F3\u306E\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7 +label.security.group.name=\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u540d +label.security.groups.enabled=\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u6709\u52b9 +label.security.groups=\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7 +label.security.group=\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7 +label.select.a.template=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u9078\u629e +label.select.a.zone=\u30be\u30fc\u30f3\u306e\u9078\u629e +label.select.instance.to.attach.volume.to=\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u30a2\u30bf\u30c3\u30c1\u3059\u308b\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044 +label.select.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u9078\u629e +label.select.iso.or.template=ISO \u307e\u305f\u306f\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u9078\u629e +label.select.offering=\u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u9078\u629e +label.select.project=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u9078\u629e +label.select.tier=\u968e\u5c64\u306e\u9078\u629e +label.select=\u9078\u629e +label.select-view=\u30d3\u30e5\u30fc\u306e\u9078\u629e +label.select.vm.for.static.nat=\u9759\u7684 NAT \u7528 VM \u306e\u9078\u629e +label.sent=\u9001\u4fe1\u6e08\u307f +label.server=\u30b5\u30fc\u30d0\u30fc +label.service.capabilities=\u30b5\u30fc\u30d3\u30b9\u306e\u6a5f\u80fd +label.service.offering=\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.session.expired=\u30bb\u30c3\u30b7\u30e7\u30f3\u306e\u6709\u52b9\u671f\u9650\u304c\u5207\u308c\u307e\u3057\u305f +label.setup.network=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7 +label.setup=\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7 +label.set.up.zone.type=\u30be\u30fc\u30f3\u306e\u7a2e\u985e\u306e\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7 +label.setup.zone=\u30be\u30fc\u30f3\u306e\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7 label.SharedMountPoint=SharedMountPoint label.shared=\u5171\u6709 -label.show.ingress.rule=\u53D7\u4FE1\u898F\u5247\u306E\u8868\u793A -label.shutdown.provider=\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u306E\u30B7\u30E3\u30C3\u30C8\u30C0\u30A6\u30F3 -label.site.to.site.VPN=\u30B5\u30A4\u30C8\u9593 VPN -label.size=\u30B5\u30A4\u30BA -label.skip.guide=CloudStack \u3092\u4F7F\u7528\u3057\u305F\u3053\u3068\u304C\u3042\u308B\u306E\u3067\u3001\u3053\u306E\u30AC\u30A4\u30C9\u3092\u30B9\u30AD\u30C3\u30D7\u3059\u308B -label.snapshot.limits=\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u5236\u9650 -label.snapshot.name=\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u540D -label.snapshot.schedule=\u5B9A\u671F\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u306E\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7 -label.snapshot.s=\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8 -label.snapshots=\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8 -label.snapshot=\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8 -label.source.nat=\u9001\u4FE1\u5143 NAT -label.source=\u9001\u4FE1\u5143 -label.specify.IP.ranges=IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u306E\u6307\u5B9A -label.specify.vlan=VLAN \u306E\u6307\u5B9A -label.SR.name = SR \u540D\u30E9\u30D9\u30EB +label.show.ingress.rule=\u53d7\u4fe1\u898f\u5247\u306e\u8868\u793a +label.shutdown.provider=\u30d7\u30ed\u30d0\u30a4\u30c0\u30fc\u306e\u30b7\u30e3\u30c3\u30c8\u30c0\u30a6\u30f3 +label.site.to.site.VPN=\u30b5\u30a4\u30c8\u9593 VPN +label.size=\u30b5\u30a4\u30ba +label.skip.guide=CloudStack \u3092\u4f7f\u7528\u3057\u305f\u3053\u3068\u304c\u3042\u308b\u306e\u3067\u3001\u3053\u306e\u30ac\u30a4\u30c9\u3092\u30b9\u30ad\u30c3\u30d7\u3059\u308b +label.snapshot.limits=\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u5236\u9650 +label.snapshot.name=\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u540d +label.snapshot.schedule=\u5b9a\u671f\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u306e\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7 +label.snapshot.s=\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8 +label.snapshots=\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8 +label.snapshot=\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8 +label.source.nat=\u9001\u4fe1\u5143 NAT +label.source=\u9001\u4fe1\u5143 +label.specify.IP.ranges=IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u306e\u6307\u5b9a +label.specify.vlan=VLAN \u306e\u6307\u5b9a +label.SR.name = SR \u540d\u30e9\u30d9\u30eb label.srx=SRX -label.start.IP=\u958B\u59CB IP \u30A2\u30C9\u30EC\u30B9 -label.start.port=\u958B\u59CB\u30DD\u30FC\u30C8 -label.start.reserved.system.IP=\u4E88\u7D04\u6E08\u307F\u958B\u59CB\u30B7\u30B9\u30C6\u30E0 IP \u30A2\u30C9\u30EC\u30B9 -label.start.vlan=\u958B\u59CB VLAN -label.state=\u72B6\u614B -label.static.nat.enabled=\u9759\u7684 NAT \u6709\u52B9 -label.static.nat.to=\u9759\u7684 NAT \u306E\u8A2D\u5B9A\u5148\: +label.start.IP=\u958b\u59cb IP \u30a2\u30c9\u30ec\u30b9 +label.start.port=\u958b\u59cb\u30dd\u30fc\u30c8 +label.start.reserved.system.IP=\u4e88\u7d04\u6e08\u307f\u958b\u59cb\u30b7\u30b9\u30c6\u30e0 IP \u30a2\u30c9\u30ec\u30b9 +label.start.vlan=\u958b\u59cb VLAN +label.state=\u72b6\u614b +label.static.nat.enabled=\u9759\u7684 NAT \u6709\u52b9 +label.static.nat.to=\u9759\u7684 NAT \u306e\u8a2d\u5b9a\u5148\: label.static.nat=\u9759\u7684 NAT -label.static.nat.vm.details=\u9759\u7684 NAT VM \u306E\u8A73\u7D30 -label.statistics=\u7D71\u8A08 -label.status=\u72B6\u614B -label.step.1.title=\u624B\u9806 1. \u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u9078\u629E -label.step.1=\u624B\u9806 1 -label.step.2.title=\u624B\u9806 2. \u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.step.2=\u624B\u9806 2 -label.step.3.title=\u624B\u9806 3. \u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u306E\u9078\u629E -label.step.3=\u624B\u9806 3 -label.step.4.title=\u624B\u9806 4. \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.step.4=\u624B\u9806 4 -label.step.5.title=\u624B\u9806 5. \u78BA\u8A8D -label.step.5=\u624B\u9806 5 -label.stickiness=\u6301\u7D9A\u6027 -label.sticky.cookie-name=Cookie \u540D -label.sticky.domain=\u30C9\u30E1\u30A4\u30F3 -label.sticky.expire=\u5931\u52B9 -label.sticky.holdtime=\u4FDD\u6301\u6642\u9593 -label.sticky.indirect=\u9593\u63A5 +label.static.nat.vm.details=\u9759\u7684 NAT VM \u306e\u8a73\u7d30 +label.statistics=\u7d71\u8a08 +label.status=\u72b6\u614b +label.step.1.title=\u624b\u9806 1. \u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u9078\u629e +label.step.1=\u624b\u9806 1 +label.step.2.title=\u624b\u9806 2. \u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.step.2=\u624b\u9806 2 +label.step.3.title=\u624b\u9806 3. \u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u306e\u9078\u629e +label.step.3=\u624b\u9806 3 +label.step.4.title=\u624b\u9806 4. \u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.step.4=\u624b\u9806 4 +label.step.5.title=\u624b\u9806 5. \u78ba\u8a8d +label.step.5=\u624b\u9806 5 +label.stickiness=\u6301\u7d9a\u6027 +label.sticky.cookie-name=Cookie \u540d +label.sticky.domain=\u30c9\u30e1\u30a4\u30f3 +label.sticky.expire=\u5931\u52b9 +label.sticky.holdtime=\u4fdd\u6301\u6642\u9593 +label.sticky.indirect=\u9593\u63a5 label.sticky.length=\u9577\u3055 -label.sticky.mode=\u30E2\u30FC\u30C9 -label.sticky.nocache=\u30AD\u30E3\u30C3\u30B7\u30E5\u306A\u3057 -label.sticky.postonly=\u30DD\u30B9\u30C8\u306E\u307F -label.sticky.prefix=\u30D7\u30EC\u30D5\u30A3\u30C3\u30AF\u30B9 -label.sticky.request-learn=\u30E9\u30FC\u30CB\u30F3\u30B0\u306E\u8981\u6C42 -label.sticky.tablesize=\u30C6\u30FC\u30D6\u30EB \u30B5\u30A4\u30BA -label.stopped.vms=\u505C\u6B62\u4E2D\u306E VM +label.sticky.mode=\u30e2\u30fc\u30c9 +label.sticky.nocache=\u30ad\u30e3\u30c3\u30b7\u30e5\u306a\u3057 +label.sticky.postonly=\u30dd\u30b9\u30c8\u306e\u307f +label.sticky.prefix=\u30d7\u30ec\u30d5\u30a3\u30c3\u30af\u30b9 +label.sticky.request-learn=\u30e9\u30fc\u30cb\u30f3\u30b0\u306e\u8981\u6c42 +label.sticky.tablesize=\u30c6\u30fc\u30d6\u30eb \u30b5\u30a4\u30ba +label.stopped.vms=\u505c\u6b62\u4e2d\u306e VM label.stop=\u505c\u6b62 -label.storage.tags=\u30B9\u30C8\u30EC\u30FC\u30B8 \u30BF\u30B0 -label.storage.traffic=\u30B9\u30C8\u30EC\u30FC\u30B8 \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF -label.storage.type=\u30B9\u30C8\u30EC\u30FC\u30B8\u306E\u7A2E\u985E -label.storage=\u30B9\u30C8\u30EC\u30FC\u30B8 -label.subdomain.access=\u30B5\u30D6\u30C9\u30E1\u30A4\u30F3 \u30A2\u30AF\u30BB\u30B9 -label.submitted.by=[\u9001\u4FE1\u30E6\u30FC\u30B6\u30FC\: ] -label.submit=\u9001\u4FE1 -label.succeeded=\u6210\u529F -label.sunday=\u65E5\u66DC\u65E5 -label.super.cidr.for.guest.networks=\u30B2\u30B9\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u30B9\u30FC\u30D1\u30FC CIDR -label.supported.services=\u30B5\u30DD\u30FC\u30C8\u3055\u308C\u308B\u30B5\u30FC\u30D3\u30B9 -label.supported.source.NAT.type=\u30B5\u30DD\u30FC\u30C8\u3055\u308C\u308B\u9001\u4FE1\u5143 NAT \u306E\u7A2E\u985E -label.suspend.project=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u4E00\u6642\u505C\u6B62 -label.system.capacity=\u30B7\u30B9\u30C6\u30E0\u306E\u51E6\u7406\u80FD\u529B -label.system.offering=\u30B7\u30B9\u30C6\u30E0 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.system.service.offering=\u30B7\u30B9\u30C6\u30E0 \u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0 -label.system.vms=\u30B7\u30B9\u30C6\u30E0 VM -label.system.vm.type=\u30B7\u30B9\u30C6\u30E0 VM \u306E\u7A2E\u985E -label.system.vm=\u30B7\u30B9\u30C6\u30E0 VM -label.system.wide.capacity=\u30B7\u30B9\u30C6\u30E0\u5168\u4F53\u306E\u51E6\u7406\u80FD\u529B -label.tagged=\u30BF\u30B0\u3042\u308A -label.tags=\u30BF\u30B0 -label.target.iqn=\u30BF\u30FC\u30B2\u30C3\u30C8 IQN -label.task.completed=\u30BF\u30B9\u30AF\u304C\u5B8C\u4E86\u3057\u307E\u3057\u305F -label.template.limits=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u5236\u9650 -label.template=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8 -label.TFTP.dir=TFTP \u30C7\u30A3\u30EC\u30AF\u30C8\u30EA -label.theme.default=\u30C7\u30D5\u30A9\u30EB\u30C8 \u30C6\u30FC\u30DE -label.theme.grey=\u30AB\u30B9\u30BF\u30E0 - \u30B0\u30EC\u30FC -label.theme.lightblue=\u30AB\u30B9\u30BF\u30E0 - \u30E9\u30A4\u30C8 \u30D6\u30EB\u30FC -label.thursday=\u6728\u66DC\u65E5 -label.tier.details=\u968E\u5C64\u306E\u8A73\u7D30 -label.tier=\u968E\u5C64 -label.timeout.in.second = \u30BF\u30A4\u30E0\u30A2\u30A6\u30C8 (\u79D2) -label.timeout=\u30BF\u30A4\u30E0\u30A2\u30A6\u30C8 -label.time=\u6642\u523B -label.time.zone=\u30BF\u30A4\u30E0\u30BE\u30FC\u30F3 -label.timezone=\u30BF\u30A4\u30E0\u30BE\u30FC\u30F3 -label.token=\u30C8\u30FC\u30AF\u30F3 -label.total.cpu=CPU \u5408\u8A08 -label.total.CPU=CPU \u5408\u8A08 -label.total.hosts=\u30DB\u30B9\u30C8\u5408\u8A08 -label.total.memory=\u30E1\u30E2\u30EA\u5408\u8A08 -label.total.of.ip=IP \u30A2\u30C9\u30EC\u30B9\u5408\u8A08 -label.total.of.vm=VM \u5408\u8A08 -label.total.storage=\u30B9\u30C8\u30EC\u30FC\u30B8\u5408\u8A08 -label.total.vms=VM \u5408\u8A08 -label.traffic.label=\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF \u30E9\u30D9\u30EB -label.traffic.types=\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u7A2E\u985E -label.traffic.type=\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u7A2E\u985E -label.tuesday=\u706B\u66DC\u65E5 -label.type.id=\u7A2E\u985E ID -label.type=\u7A2E\u985E -label.unavailable=\u4F7F\u7528\u4E0D\u80FD +label.storage.tags=\u30b9\u30c8\u30ec\u30fc\u30b8 \u30bf\u30b0 +label.storage.traffic=\u30b9\u30c8\u30ec\u30fc\u30b8 \u30c8\u30e9\u30d5\u30a3\u30c3\u30af +label.storage.type=\u30b9\u30c8\u30ec\u30fc\u30b8\u306e\u7a2e\u985e +label.storage=\u30b9\u30c8\u30ec\u30fc\u30b8 +label.subdomain.access=\u30b5\u30d6\u30c9\u30e1\u30a4\u30f3 \u30a2\u30af\u30bb\u30b9 +label.submitted.by=[\u9001\u4fe1\u30e6\u30fc\u30b6\u30fc\: ] +label.submit=\u9001\u4fe1 +label.succeeded=\u6210\u529f +label.sunday=\u65e5\u66dc\u65e5 +label.super.cidr.for.guest.networks=\u30b2\u30b9\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u30b9\u30fc\u30d1\u30fc CIDR +label.supported.services=\u30b5\u30dd\u30fc\u30c8\u3055\u308c\u308b\u30b5\u30fc\u30d3\u30b9 +label.supported.source.NAT.type=\u30b5\u30dd\u30fc\u30c8\u3055\u308c\u308b\u9001\u4fe1\u5143 NAT \u306e\u7a2e\u985e +label.suspend.project=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u4e00\u6642\u505c\u6b62 +label.system.capacity=\u30b7\u30b9\u30c6\u30e0\u306e\u51e6\u7406\u80fd\u529b +label.system.offering=\u30b7\u30b9\u30c6\u30e0 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.system.service.offering=\u30b7\u30b9\u30c6\u30e0 \u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0 +label.system.vms=\u30b7\u30b9\u30c6\u30e0 VM +label.system.vm.type=\u30b7\u30b9\u30c6\u30e0 VM \u306e\u7a2e\u985e +label.system.vm=\u30b7\u30b9\u30c6\u30e0 VM +label.system.wide.capacity=\u30b7\u30b9\u30c6\u30e0\u5168\u4f53\u306e\u51e6\u7406\u80fd\u529b +label.tagged=\u30bf\u30b0\u3042\u308a +label.tags=\u30bf\u30b0 +label.target.iqn=\u30bf\u30fc\u30b2\u30c3\u30c8 IQN +label.task.completed=\u30bf\u30b9\u30af\u304c\u5b8c\u4e86\u3057\u307e\u3057\u305f +label.template.limits=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u5236\u9650 +label.template=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8 +label.TFTP.dir=TFTP \u30c7\u30a3\u30ec\u30af\u30c8\u30ea +label.theme.default=\u30c7\u30d5\u30a9\u30eb\u30c8 \u30c6\u30fc\u30de +label.theme.grey=\u30ab\u30b9\u30bf\u30e0 - \u30b0\u30ec\u30fc +label.theme.lightblue=\u30ab\u30b9\u30bf\u30e0 - \u30e9\u30a4\u30c8 \u30d6\u30eb\u30fc +label.thursday=\u6728\u66dc\u65e5 +label.tier.details=\u968e\u5c64\u306e\u8a73\u7d30 +label.tier=\u968e\u5c64 +label.timeout.in.second = \u30bf\u30a4\u30e0\u30a2\u30a6\u30c8 (\u79d2) +label.timeout=\u30bf\u30a4\u30e0\u30a2\u30a6\u30c8 +label.time=\u6642\u523b +label.time.zone=\u30bf\u30a4\u30e0\u30be\u30fc\u30f3 +label.timezone=\u30bf\u30a4\u30e0\u30be\u30fc\u30f3 +label.token=\u30c8\u30fc\u30af\u30f3 +label.total.cpu=CPU \u5408\u8a08 +label.total.CPU=CPU \u5408\u8a08 +label.total.hosts=\u30db\u30b9\u30c8\u5408\u8a08 +label.total.memory=\u30e1\u30e2\u30ea\u5408\u8a08 +label.total.of.ip=IP \u30a2\u30c9\u30ec\u30b9\u5408\u8a08 +label.total.of.vm=VM \u5408\u8a08 +label.total.storage=\u30b9\u30c8\u30ec\u30fc\u30b8\u5408\u8a08 +label.total.vms=VM \u5408\u8a08 +label.traffic.label=\u30c8\u30e9\u30d5\u30a3\u30c3\u30af \u30e9\u30d9\u30eb +label.traffic.types=\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u7a2e\u985e +label.traffic.type=\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u7a2e\u985e +label.tuesday=\u706b\u66dc\u65e5 +label.type.id=\u7a2e\u985e ID +label.type=\u7a2e\u985e +label.unavailable=\u4f7f\u7528\u4e0d\u80fd label.unlimited=\u7121\u5236\u9650 -label.untagged=\u30BF\u30B0\u306A\u3057 -label.update.project.resources=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8 \u30EA\u30BD\u30FC\u30B9\u306E\u66F4\u65B0 -label.update.ssl.cert= SSL \u8A3C\u660E\u66F8\u306E\u66F4\u65B0 -label.update.ssl= SSL \u8A3C\u660E\u66F8\u306E\u66F4\u65B0 -label.updating=\u66F4\u65B0\u3057\u3066\u3044\u307E\u3059 -label.upload=\u30A2\u30C3\u30D7\u30ED\u30FC\u30C9 -label.upload.volume=\u30DC\u30EA\u30E5\u30FC\u30E0\u306E\u30A2\u30C3\u30D7\u30ED\u30FC\u30C9 +label.untagged=\u30bf\u30b0\u306a\u3057 +label.update.project.resources=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8 \u30ea\u30bd\u30fc\u30b9\u306e\u66f4\u65b0 +label.update.ssl.cert= SSL \u8a3c\u660e\u66f8\u306e\u66f4\u65b0 +label.update.ssl= SSL \u8a3c\u660e\u66f8\u306e\u66f4\u65b0 +label.updating=\u66f4\u65b0\u3057\u3066\u3044\u307e\u3059 +label.upload=\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9 +label.upload.volume=\u30dc\u30ea\u30e5\u30fc\u30e0\u306e\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9 label.url=URL -label.usage.interface=\u4F7F\u7528\u72B6\u6CC1\u6E2C\u5B9A\u30A4\u30F3\u30BF\u30FC\u30D5\u30A7\u30A4\u30B9 -label.used=\u4F7F\u7528\u4E2D -label.username=\u30E6\u30FC\u30B6\u30FC\u540D -label.users=\u30E6\u30FC\u30B6\u30FC -label.user=\u30E6\u30FC\u30B6\u30FC +label.usage.interface=\u4f7f\u7528\u72b6\u6cc1\u6e2c\u5b9a\u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9 +label.used=\u4f7f\u7528\u4e2d +label.username=\u30e6\u30fc\u30b6\u30fc\u540d +label.users=\u30e6\u30fc\u30b6\u30fc +label.user=\u30e6\u30fc\u30b6\u30fc label.value=\u5024 -label.vcdcname=vCenter DC \u540D -label.vcenter.cluster=vCenter \u30AF\u30E9\u30B9\u30BF\u30FC -label.vcenter.datacenter=vCenter \u30C7\u30FC\u30BF\u30BB\u30F3\u30BF\u30FC -label.vcenter.datastore=vCenter \u30C7\u30FC\u30BF\u30B9\u30C8\u30A2 -label.vcenter.host=vCenter \u30DB\u30B9\u30C8 -label.vcenter.password=vCenter \u30D1\u30B9\u30EF\u30FC\u30C9 -label.vcenter.username=vCenter \u30E6\u30FC\u30B6\u30FC\u540D -label.vcipaddress=vCenter IP \u30A2\u30C9\u30EC\u30B9 -label.version=\u30D0\u30FC\u30B8\u30E7\u30F3 -label.view.all=\u3059\u3079\u3066\u8868\u793A -label.view.console=\u30B3\u30F3\u30BD\u30FC\u30EB\u306E\u8868\u793A -label.viewing=\u8868\u793A\u9805\u76EE\: -label.view.more=\u8A73\u7D30\u8868\u793A -label.view=\u8868\u793A - -label.virtual.appliances=\u4EEE\u60F3\u30A2\u30D7\u30E9\u30A4\u30A2\u30F3\u30B9 -label.virtual.appliance=\u4EEE\u60F3\u30A2\u30D7\u30E9\u30A4\u30A2\u30F3\u30B9 -label.virtual.machines=\u4EEE\u60F3\u30DE\u30B7\u30F3 -label.virtual.network=\u4EEE\u60F3\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF -label.virtual.routers=\u4EEE\u60F3\u30EB\u30FC\u30BF\u30FC -label.virtual.router=\u4EEE\u60F3\u30EB\u30FC\u30BF\u30FC +label.vcdcname=vCenter DC \u540d +label.vcenter.cluster=vCenter \u30af\u30e9\u30b9\u30bf\u30fc +label.vcenter.datacenter=vCenter \u30c7\u30fc\u30bf\u30bb\u30f3\u30bf\u30fc +label.vcenter.datastore=vCenter \u30c7\u30fc\u30bf\u30b9\u30c8\u30a2 +label.vcenter.host=vCenter \u30db\u30b9\u30c8 +label.vcenter.password=vCenter \u30d1\u30b9\u30ef\u30fc\u30c9 +label.vcenter.username=vCenter \u30e6\u30fc\u30b6\u30fc\u540d +label.vcipaddress=vCenter IP \u30a2\u30c9\u30ec\u30b9 +label.version=\u30d0\u30fc\u30b8\u30e7\u30f3 +label.view.all=\u3059\u3079\u3066\u8868\u793a +label.view.console=\u30b3\u30f3\u30bd\u30fc\u30eb\u306e\u8868\u793a +label.viewing=\u8868\u793a\u9805\u76ee\: +label.view.more=\u8a73\u7d30\u8868\u793a +label.view=\u8868\u793a - +label.virtual.appliances=\u4eee\u60f3\u30a2\u30d7\u30e9\u30a4\u30a2\u30f3\u30b9 +label.virtual.appliance=\u4eee\u60f3\u30a2\u30d7\u30e9\u30a4\u30a2\u30f3\u30b9 +label.virtual.machines=\u4eee\u60f3\u30de\u30b7\u30f3 +label.virtual.network=\u4eee\u60f3\u30cd\u30c3\u30c8\u30ef\u30fc\u30af +label.virtual.routers=\u4eee\u60f3\u30eb\u30fc\u30bf\u30fc +label.virtual.router=\u4eee\u60f3\u30eb\u30fc\u30bf\u30fc label.vlan.id=VLAN ID -label.vlan.range=VLAN \u306E\u7BC4\u56F2 +label.vlan.range=VLAN \u306e\u7bc4\u56f2 label.vlan=VLAN -label.vm.add=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u8FFD\u52A0 +label.vm.add=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u8ffd\u52a0 label.vm.destroy=\u7834\u68c4 -label.vm.display.name=VM \u8868\u793A\u540D -label.VMFS.datastore=VMFS \u30C7\u30FC\u30BF\u30B9\u30C8\u30A2 +label.vm.display.name=VM \u8868\u793a\u540d +label.VMFS.datastore=VMFS \u30c7\u30fc\u30bf\u30b9\u30c8\u30a2 label.vmfs=VMFS -label.vm.name=VM \u540D +label.vm.name=VM \u540d label.vm.reboot=\u518d\u8d77\u52d5 -label.VMs.in.tier=\u968E\u5C64\u5185\u306E VM -label.vmsnapshot.type=\u7A2E\u985E -label.vm.start=\u8D77\u52D5 -label.vm.state=VM \u306E\u72B6\u614B +label.VMs.in.tier=\u968e\u5c64\u5185\u306e VM +label.vmsnapshot.type=\u7a2e\u985e +label.vm.start=\u8d77\u52d5 +label.vm.state=VM \u306e\u72b6\u614b label.vm.stop=\u505c\u6b62 label.vms=VM -label.vmware.traffic.label=VMware \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u30E9\u30D9\u30EB -label.volgroup=\u30DC\u30EA\u30E5\u30FC\u30E0 \u30B0\u30EB\u30FC\u30D7 -label.volume.limits=\u30DC\u30EA\u30E5\u30FC\u30E0\u5236\u9650 -label.volume.name=\u30DC\u30EA\u30E5\u30FC\u30E0\u540D -label.volumes=\u30DC\u30EA\u30E5\u30FC\u30E0 -label.volume=\u30DC\u30EA\u30E5\u30FC\u30E0 +label.vmware.traffic.label=VMware \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u30e9\u30d9\u30eb +label.volgroup=\u30dc\u30ea\u30e5\u30fc\u30e0 \u30b0\u30eb\u30fc\u30d7 +label.volume.limits=\u30dc\u30ea\u30e5\u30fc\u30e0\u5236\u9650 +label.volume.name=\u30dc\u30ea\u30e5\u30fc\u30e0\u540d +label.volumes=\u30dc\u30ea\u30e5\u30fc\u30e0 +label.volume=\u30dc\u30ea\u30e5\u30fc\u30e0 label.vpc.id=VPC ID -label.VPC.router.details=VPC \u30EB\u30FC\u30BF\u30FC\u306E\u8A73\u7D30 +label.VPC.router.details=VPC \u30eb\u30fc\u30bf\u30fc\u306e\u8a73\u7d30 label.vpc=VPC -label.VPN.connection=VPN \u63A5\u7D9A -label.vpn.customer.gateway=VPN \u30AB\u30B9\u30BF\u30DE\u30FC \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4 -label.VPN.customer.gateway=VPN \u30AB\u30B9\u30BF\u30DE\u30FC \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4 -label.VPN.gateway=VPN \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4 +label.VPN.connection=VPN \u63a5\u7d9a +label.vpn.customer.gateway=VPN \u30ab\u30b9\u30bf\u30de\u30fc \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4 +label.VPN.customer.gateway=VPN \u30ab\u30b9\u30bf\u30de\u30fc \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4 +label.VPN.gateway=VPN \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4 label.vpn=VPN -label.vsmctrlvlanid=\u30B3\u30F3\u30C8\u30ED\u30FC\u30EB VLAN ID -label.vsmpktvlanid=\u30D1\u30B1\u30C3\u30C8 VLAN ID -label.vsmstoragevlanid=\u30B9\u30C8\u30EC\u30FC\u30B8 VLAN ID -label.vsphere.managed=vSphere \u306B\u3088\u308B\u7BA1\u7406 -label.waiting=\u5F85\u6A5F\u3057\u3066\u3044\u307E\u3059 -label.warn=\u8B66\u544A -label.wednesday=\u6C34\u66DC\u65E5 -label.weekly=\u6BCE\u9031 -label.welcome.cloud.console=\u7BA1\u7406\u30B3\u30F3\u30BD\u30FC\u30EB\u3078\u3088\u3046\u3053\u305D -label.welcome=\u3088\u3046\u3053\u305D -label.what.is.cloudstack=CloudStack&\#8482; \u306B\u3064\u3044\u3066 -label.xen.traffic.label=XenServer \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u30E9\u30D9\u30EB -label.yes=\u306F\u3044 -label.zone.details=\u30BE\u30FC\u30F3\u306E\u8A73\u7D30 -label.zone.id=\u30BE\u30FC\u30F3 ID -label.zone.name=\u30BE\u30FC\u30F3\u540D -label.zone.step.1.title=\u624B\u9806 1. \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u9078\u629E -label.zone.step.2.title=\u624B\u9806 2. \u30BE\u30FC\u30F3\u306E\u8FFD\u52A0 -label.zone.step.3.title=\u624B\u9806 3. \u30DD\u30C3\u30C9\u306E\u8FFD\u52A0 -label.zone.step.4.title=\u624B\u9806 4. IP \u30A2\u30C9\u30EC\u30B9\u7BC4\u56F2\u306E\u8FFD\u52A0 -label.zones=\u30BE\u30FC\u30F3 -label.zone.type=\u30BE\u30FC\u30F3\u306E\u7A2E\u985E -label.zone=\u30BE\u30FC\u30F3 -label.zone.wide=\u30BE\u30FC\u30F3\u5168\u4F53 +label.vsmctrlvlanid=\u30b3\u30f3\u30c8\u30ed\u30fc\u30eb VLAN ID +label.vsmpktvlanid=\u30d1\u30b1\u30c3\u30c8 VLAN ID +label.vsmstoragevlanid=\u30b9\u30c8\u30ec\u30fc\u30b8 VLAN ID +label.vsphere.managed=vSphere \u306b\u3088\u308b\u7ba1\u7406 +label.waiting=\u5f85\u6a5f\u3057\u3066\u3044\u307e\u3059 +label.warn=\u8b66\u544a +label.wednesday=\u6c34\u66dc\u65e5 +label.weekly=\u6bce\u9031 +label.welcome.cloud.console=\u7ba1\u7406\u30b3\u30f3\u30bd\u30fc\u30eb\u3078\u3088\u3046\u3053\u305d +label.welcome=\u3088\u3046\u3053\u305d +label.what.is.cloudstack=CloudStack&\#8482; \u306b\u3064\u3044\u3066 +label.xen.traffic.label=XenServer \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u30e9\u30d9\u30eb +label.yes=\u306f\u3044 +label.zone.details=\u30be\u30fc\u30f3\u306e\u8a73\u7d30 +label.zone.id=\u30be\u30fc\u30f3 ID +label.zone.name=\u30be\u30fc\u30f3\u540d +label.zone.step.1.title=\u624b\u9806 1. \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u9078\u629e +label.zone.step.2.title=\u624b\u9806 2. \u30be\u30fc\u30f3\u306e\u8ffd\u52a0 +label.zone.step.3.title=\u624b\u9806 3. \u30dd\u30c3\u30c9\u306e\u8ffd\u52a0 +label.zone.step.4.title=\u624b\u9806 4. IP \u30a2\u30c9\u30ec\u30b9\u7bc4\u56f2\u306e\u8ffd\u52a0 +label.zones=\u30be\u30fc\u30f3 +label.zone.type=\u30be\u30fc\u30f3\u306e\u7a2e\u985e +label.zone=\u30be\u30fc\u30f3 +label.zone.wide=\u30be\u30fc\u30f3\u5168\u4f53 label.zoneWizard.trafficType.guest=\u30b2\u30b9\u30c8\: \u30a8\u30f3\u30c9\u30e6\u30fc\u30b6\u30fc\u4eee\u60f3\u30de\u30b7\u30f3\u9593\u306e\u30c8\u30e9\u30d5\u30a3\u30c3\u30af -label.zoneWizard.trafficType.management=\u7ba1\u7406\: \u30db\u30b9\u30c8\u3084\u30b7\u30b9\u30c6\u30e0VM\u306a\u3069\u3001\u7ba1\u7406\u30b5\u30fc\u30d0\u30fc\u3068\u901a\u4fe1\u3059\u308b\u3042\u3089\u3086\u308b\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3092\u542b\u3081\u305f\u3001CloudStack\u5185\u90e8\u306e\u30ea\u30bd\u30fc\u30b9\u9593\u306e\u30c8\u30e9\u30d5\u30a3\u30c3\u30af label.zoneWizard.trafficType.public=\u30d1\u30d6\u30ea\u30c3\u30af\: \u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8\u3068\u30af\u30e9\u30a6\u30c9\u5185\u306e\u4eee\u60f3\u30de\u30b7\u30f3\u306e\u9593\u306e\u30c8\u30e9\u30d5\u30a3\u30c3\u30af label.zoneWizard.trafficType.storage=\u30b9\u30c8\u30ec\u30fc\u30b8\: VM\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3068\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u306e\u3088\u3046\u306a\u3001\u30d7\u30e9\u30a4\u30de\u30ea\u3068\u30bb\u30ab\u30f3\u30c0\u30ea\u306e\u30b9\u30c8\u30ec\u30fc\u30b8\u30b5\u30fc\u30d0\u30fc\u9593\u306e\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u3002 -managed.state=\u7BA1\u7406\u5BFE\u8C61\u72B6\u614B -message.acquire.new.ip=\u3053\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u65B0\u3057\u3044 IP \u30A2\u30C9\u30EC\u30B9\u3092\u53D6\u5F97\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? +managed.state=\u7ba1\u7406\u5bfe\u8c61\u72b6\u614b +message.acquire.new.ip=\u3053\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u65b0\u3057\u3044 IP \u30a2\u30c9\u30ec\u30b9\u3092\u53d6\u5f97\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? message.acquire.new.ip.vpc=VPC\u306e\u65b0\u3057\u3044IP\u3092\u53d6\u5f97\u3059\u308b\u3053\u3068\u3092\u78ba\u8a8d\u3057\u3066\u304f\u3060\u3055\u3044\u3002 -message.acquire.public.ip=\u65B0\u3057\u3044 IP \u30A2\u30C9\u30EC\u30B9\u3092\u53D6\u5F97\u3059\u308B\u30BE\u30FC\u30F3\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.action.cancel.maintenance.mode=\u3053\u306E\u4FDD\u5B88\u3092\u30AD\u30E3\u30F3\u30BB\u30EB\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.cancel.maintenance=\u30DB\u30B9\u30C8\u306E\u4FDD\u5B88\u306F\u6B63\u5E38\u306B\u30AD\u30E3\u30F3\u30BB\u30EB\u3055\u308C\u307E\u3057\u305F\u3002\u3053\u306E\u51E6\u7406\u306B\u306F\u6570\u5206\u304B\u304B\u308B\u53EF\u80FD\u6027\u304C\u3042\u308A\u307E\u3059\u3002 -message.action.change.service.warning.for.instance=\u73FE\u5728\u306E\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u5909\u66F4\u3059\u308B\u524D\u306B\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u505C\u6B62\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.action.change.service.warning.for.router=\u73FE\u5728\u306E\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u5909\u66F4\u3059\u308B\u524D\u306B\u30EB\u30FC\u30BF\u30FC\u3092\u505C\u6B62\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.action.delete.cluster=\u3053\u306E\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.disk.offering=\u3053\u306E\u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.domain=\u3053\u306E\u30C9\u30E1\u30A4\u30F3\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.external.firewall=\u3053\u306E\u5916\u90E8\u30D5\u30A1\u30A4\u30A2\u30A6\u30A9\u30FC\u30EB\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? \u8B66\u544A\: \u540C\u3058\u5916\u90E8\u30D5\u30A1\u30A4\u30A2\u30A6\u30A9\u30FC\u30EB\u3092\u518D\u5EA6\u8FFD\u52A0\u3059\u308B\u4E88\u5B9A\u3067\u3042\u308B\u5834\u5408\u306F\u3001\u30C7\u30D0\u30A4\u30B9\u306E\u4F7F\u7528\u72B6\u6CC1\u30C7\u30FC\u30BF\u3092\u30EA\u30BB\u30C3\u30C8\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.action.delete.external.load.balancer=\u3053\u306E\u5916\u90E8\u8CA0\u8377\u5206\u6563\u88C5\u7F6E\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? \u8B66\u544A\: \u540C\u3058\u5916\u90E8\u8CA0\u8377\u5206\u6563\u88C5\u7F6E\u3092\u518D\u5EA6\u8FFD\u52A0\u3059\u308B\u4E88\u5B9A\u3067\u3042\u308B\u5834\u5408\u306F\u3001\u30C7\u30D0\u30A4\u30B9\u306E\u4F7F\u7528\u72B6\u6CC1\u30C7\u30FC\u30BF\u3092\u30EA\u30BB\u30C3\u30C8\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.action.delete.ingress.rule=\u3053\u306E\u53D7\u4FE1\u898F\u5247\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.ISO.for.all.zones=\u305D\u306E ISO \u306F\u3059\u3079\u3066\u306E\u30BE\u30FC\u30F3\u3067\u4F7F\u7528\u3055\u308C\u3066\u3044\u307E\u3059\u3002\u3059\u3079\u3066\u306E\u30BE\u30FC\u30F3\u304B\u3089\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.ISO=\u3053\u306E ISO \u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.network=\u3053\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.nexusVswitch=\u3053\u306E Nexus 1000V \u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.physical.network=\u3053\u306E\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.pod=\u3053\u306E\u30DD\u30C3\u30C9\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.primary.storage=\u3053\u306E\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.secondary.storage=\u3053\u306E\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.security.group=\u3053\u306E\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.service.offering=\u3053\u306E\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.snapshot=\u3053\u306E\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.system.service.offering=\u3053\u306E\u30B7\u30B9\u30C6\u30E0 \u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.template.for.all.zones=\u305D\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306F\u3059\u3079\u3066\u306E\u30BE\u30FC\u30F3\u3067\u4F7F\u7528\u3055\u308C\u3066\u3044\u307E\u3059\u3002\u3059\u3079\u3066\u306E\u30BE\u30FC\u30F3\u304B\u3089\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.template=\u3053\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.volume=\u3053\u306E\u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.delete.zone=\u3053\u306E\u30BE\u30FC\u30F3\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.destroy.instance=\u3053\u306E\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u7834\u68C4\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.destroy.systemvm=\u3053\u306E\u30B7\u30B9\u30C6\u30E0 VM \u3092\u7834\u68C4\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.disable.cluster=\u3053\u306E\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u7121\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.disable.nexusVswitch=\u3053\u306E Nexus 1000V \u3092\u7121\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.disable.physical.network=\u3053\u306E\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u7121\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.disable.pod=\u3053\u306E\u30DD\u30C3\u30C9\u3092\u7121\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.disable.static.NAT=\u9759\u7684 NAT \u3092\u7121\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.disable.zone=\u3053\u306E\u30BE\u30FC\u30F3\u3092\u7121\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.download.iso=\u3053\u306E ISO \u3092\u30C0\u30A6\u30F3\u30ED\u30FC\u30C9\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.download.template=\u3053\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u30C0\u30A6\u30F3\u30ED\u30FC\u30C9\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.enable.cluster=\u3053\u306E\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u6709\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.enable.maintenance=\u30DB\u30B9\u30C8\u3092\u4FDD\u5B88\u3059\u308B\u6E96\u5099\u304C\u3067\u304D\u307E\u3057\u305F\u3002\u3053\u306E\u30DB\u30B9\u30C8\u4E0A\u306E VM \u6570\u306B\u3088\u3063\u3066\u306F\u3001\u3053\u306E\u51E6\u7406\u306B\u306F\u6570\u5206\u4EE5\u4E0A\u304B\u304B\u308B\u53EF\u80FD\u6027\u304C\u3042\u308A\u307E\u3059\u3002 -message.action.enable.nexusVswitch=\u3053\u306E Nexus 1000V \u3092\u6709\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.enable.physical.network=\u3053\u306E\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u6709\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.enable.pod=\u3053\u306E\u30DD\u30C3\u30C9\u3092\u6709\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.enable.zone=\u3053\u306E\u30BE\u30FC\u30F3\u3092\u6709\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.force.reconnect=\u30DB\u30B9\u30C8\u306F\u5F37\u5236\u7684\u306B\u518D\u63A5\u7D9A\u3057\u307E\u3057\u305F\u3002\u3053\u306E\u51E6\u7406\u306B\u306F\u6570\u5206\u304B\u304B\u308B\u53EF\u80FD\u6027\u304C\u3042\u308A\u307E\u3059\u3002 -message.action.host.enable.maintenance.mode=\u4FDD\u5B88\u30E2\u30FC\u30C9\u3092\u6709\u52B9\u306B\u3059\u308B\u3068\u3001\u3053\u306E\u30DB\u30B9\u30C8\u3067\u5B9F\u884C\u4E2D\u306E\u3059\u3079\u3066\u306E\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u304C\u307B\u304B\u306E\u4F7F\u7528\u3067\u304D\u308B\u30DB\u30B9\u30C8\u306B\u30E9\u30A4\u30D6 \u30DE\u30A4\u30B0\u30EC\u30FC\u30B7\u30E7\u30F3\u3055\u308C\u307E\u3059\u3002 +message.acquire.public.ip=\u65b0\u3057\u3044 IP \u30a2\u30c9\u30ec\u30b9\u3092\u53d6\u5f97\u3059\u308b\u30be\u30fc\u30f3\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.action.cancel.maintenance.mode=\u3053\u306e\u4fdd\u5b88\u3092\u30ad\u30e3\u30f3\u30bb\u30eb\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.cancel.maintenance=\u30db\u30b9\u30c8\u306e\u4fdd\u5b88\u306f\u6b63\u5e38\u306b\u30ad\u30e3\u30f3\u30bb\u30eb\u3055\u308c\u307e\u3057\u305f\u3002\u3053\u306e\u51e6\u7406\u306b\u306f\u6570\u5206\u304b\u304b\u308b\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002 +message.action.change.service.warning.for.instance=\u73fe\u5728\u306e\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u5909\u66f4\u3059\u308b\u524d\u306b\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u505c\u6b62\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.action.change.service.warning.for.router=\u73fe\u5728\u306e\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u5909\u66f4\u3059\u308b\u524d\u306b\u30eb\u30fc\u30bf\u30fc\u3092\u505c\u6b62\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.action.delete.cluster=\u3053\u306e\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.disk.offering=\u3053\u306e\u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.domain=\u3053\u306e\u30c9\u30e1\u30a4\u30f3\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.external.firewall=\u3053\u306e\u5916\u90e8\u30d5\u30a1\u30a4\u30a2\u30a6\u30a9\u30fc\u30eb\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? \u8b66\u544a\: \u540c\u3058\u5916\u90e8\u30d5\u30a1\u30a4\u30a2\u30a6\u30a9\u30fc\u30eb\u3092\u518d\u5ea6\u8ffd\u52a0\u3059\u308b\u4e88\u5b9a\u3067\u3042\u308b\u5834\u5408\u306f\u3001\u30c7\u30d0\u30a4\u30b9\u306e\u4f7f\u7528\u72b6\u6cc1\u30c7\u30fc\u30bf\u3092\u30ea\u30bb\u30c3\u30c8\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.action.delete.external.load.balancer=\u3053\u306e\u5916\u90e8\u8ca0\u8377\u5206\u6563\u88c5\u7f6e\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? \u8b66\u544a\: \u540c\u3058\u5916\u90e8\u8ca0\u8377\u5206\u6563\u88c5\u7f6e\u3092\u518d\u5ea6\u8ffd\u52a0\u3059\u308b\u4e88\u5b9a\u3067\u3042\u308b\u5834\u5408\u306f\u3001\u30c7\u30d0\u30a4\u30b9\u306e\u4f7f\u7528\u72b6\u6cc1\u30c7\u30fc\u30bf\u3092\u30ea\u30bb\u30c3\u30c8\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.action.delete.ingress.rule=\u3053\u306e\u53d7\u4fe1\u898f\u5247\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.ISO.for.all.zones=\u305d\u306e ISO \u306f\u3059\u3079\u3066\u306e\u30be\u30fc\u30f3\u3067\u4f7f\u7528\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u3059\u3079\u3066\u306e\u30be\u30fc\u30f3\u304b\u3089\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.ISO=\u3053\u306e ISO \u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.network=\u3053\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.nexusVswitch=\u3053\u306e Nexus 1000V \u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.physical.network=\u3053\u306e\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.pod=\u3053\u306e\u30dd\u30c3\u30c9\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.primary.storage=\u3053\u306e\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.secondary.storage=\u3053\u306e\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.security.group=\u3053\u306e\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.service.offering=\u3053\u306e\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.snapshot=\u3053\u306e\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.system.service.offering=\u3053\u306e\u30b7\u30b9\u30c6\u30e0 \u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.template.for.all.zones=\u305d\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306f\u3059\u3079\u3066\u306e\u30be\u30fc\u30f3\u3067\u4f7f\u7528\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u3059\u3079\u3066\u306e\u30be\u30fc\u30f3\u304b\u3089\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.template=\u3053\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.volume=\u3053\u306e\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.delete.zone=\u3053\u306e\u30be\u30fc\u30f3\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.destroy.instance=\u3053\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u7834\u68c4\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.destroy.systemvm=\u3053\u306e\u30b7\u30b9\u30c6\u30e0 VM \u3092\u7834\u68c4\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.disable.cluster=\u3053\u306e\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u7121\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.disable.nexusVswitch=\u3053\u306e Nexus 1000V \u3092\u7121\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.disable.physical.network=\u3053\u306e\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u7121\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.disable.pod=\u3053\u306e\u30dd\u30c3\u30c9\u3092\u7121\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.disable.static.NAT=\u9759\u7684 NAT \u3092\u7121\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.disable.zone=\u3053\u306e\u30be\u30fc\u30f3\u3092\u7121\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.download.iso=\u3053\u306e ISO \u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.download.template=\u3053\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.enable.cluster=\u3053\u306e\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u6709\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.enable.maintenance=\u30db\u30b9\u30c8\u3092\u4fdd\u5b88\u3059\u308b\u6e96\u5099\u304c\u3067\u304d\u307e\u3057\u305f\u3002\u3053\u306e\u30db\u30b9\u30c8\u4e0a\u306e VM \u6570\u306b\u3088\u3063\u3066\u306f\u3001\u3053\u306e\u51e6\u7406\u306b\u306f\u6570\u5206\u4ee5\u4e0a\u304b\u304b\u308b\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002 +message.action.enable.nexusVswitch=\u3053\u306e Nexus 1000V \u3092\u6709\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.enable.physical.network=\u3053\u306e\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u6709\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.enable.pod=\u3053\u306e\u30dd\u30c3\u30c9\u3092\u6709\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.enable.zone=\u3053\u306e\u30be\u30fc\u30f3\u3092\u6709\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.force.reconnect=\u30db\u30b9\u30c8\u306f\u5f37\u5236\u7684\u306b\u518d\u63a5\u7d9a\u3057\u307e\u3057\u305f\u3002\u3053\u306e\u51e6\u7406\u306b\u306f\u6570\u5206\u304b\u304b\u308b\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002 +message.action.host.enable.maintenance.mode=\u4fdd\u5b88\u30e2\u30fc\u30c9\u3092\u6709\u52b9\u306b\u3059\u308b\u3068\u3001\u3053\u306e\u30db\u30b9\u30c8\u3067\u5b9f\u884c\u4e2d\u306e\u3059\u3079\u3066\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u304c\u307b\u304b\u306e\u4f7f\u7528\u3067\u304d\u308b\u30db\u30b9\u30c8\u306b\u30e9\u30a4\u30d6 \u30de\u30a4\u30b0\u30ec\u30fc\u30b7\u30e7\u30f3\u3055\u308c\u307e\u3059\u3002 message.action.instance.reset.password=\u00e3\u0081\u0093\u00e3\u0081\u00ae\u00e4\u00bb\u00ae\u00e6\u0083\u00b3\u00e3\u0083\u009e\u00e3\u0082\u00b7\u00e3\u0083\u00b3\u00e3\u0081\u00ae\u00e3\u0083\u00ab\u00e3\u0083\u00bc\u00e3\u0083\u0088\u00e3\u0083\u0091\u00e3\u0082\u00b9\u00e3\u0083\u00af\u00e3\u0083\u00bc\u00e3\u0083\u0089\u00e3\u0082\u0092\u00e5\u00a4\u0089\u00e6\u009b\u00b4\u00e3\u0081\u0097\u00e3\u0081\u00a6\u00e3\u0082\u0082\u00e3\u0082\u0088\u00e3\u0082\u008d\u00e3\u0081\u0097\u00e3\u0081\u0084\u00e3\u0081\u00a7\u00e3\u0081\u0099\u00e3\u0081\u008b? -message.action.manage.cluster=\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u7BA1\u7406\u5BFE\u8C61\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.primarystorage.enable.maintenance.mode=\u8B66\u544A\: \u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u4FDD\u5B88\u30E2\u30FC\u30C9\u306B\u3059\u308B\u3068\u3001\u305D\u306E\u30B9\u30C8\u30EC\u30FC\u30B8\u4E0A\u306E\u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u4F7F\u7528\u3059\u308B\u3059\u3079\u3066\u306E VM \u304C\u505C\u6B62\u3057\u307E\u3059\u3002\u7D9A\u884C\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.reboot.instance=\u3053\u306E\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u518D\u8D77\u52D5\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.reboot.router=\u3053\u306E\u4EEE\u60F3\u30EB\u30FC\u30BF\u30FC\u3067\u63D0\u4F9B\u3059\u308B\u3059\u3079\u3066\u306E\u30B5\u30FC\u30D3\u30B9\u304C\u4E2D\u65AD\u3055\u308C\u307E\u3059\u3002\u3053\u306E\u30EB\u30FC\u30BF\u30FC\u3092\u518D\u8D77\u52D5\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.reboot.systemvm=\u3053\u306E\u30B7\u30B9\u30C6\u30E0 VM \u3092\u518D\u8D77\u52D5\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.release.ip=\u3053\u306E IP \u30A2\u30C9\u30EC\u30B9\u3092\u89E3\u653E\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.remove.host=\u3053\u306E\u30DB\u30B9\u30C8\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.reset.password.off=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306F\u73FE\u5728\u3053\u306E\u6A5F\u80FD\u3092\u30B5\u30DD\u30FC\u30C8\u3057\u3066\u3044\u307E\u305B\u3093\u3002 -message.action.reset.password.warning=\u73FE\u5728\u306E\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u5909\u66F4\u3059\u308B\u524D\u306B\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u505C\u6B62\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.action.restore.instance=\u3053\u306E\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u5FA9\u5143\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.start.instance=\u3053\u306E\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u8D77\u52D5\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.start.router=\u3053\u306E\u30EB\u30FC\u30BF\u30FC\u3092\u8D77\u52D5\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.start.systemvm=\u3053\u306E\u30B7\u30B9\u30C6\u30E0 VM \u3092\u8D77\u52D5\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.stop.instance=\u3053\u306E\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u505C\u6B62\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.stop.router=\u3053\u306E\u4EEE\u60F3\u30EB\u30FC\u30BF\u30FC\u3067\u63D0\u4F9B\u3059\u308B\u3059\u3079\u3066\u306E\u30B5\u30FC\u30D3\u30B9\u304C\u4E2D\u65AD\u3055\u308C\u307E\u3059\u3002\u3053\u306E\u30EB\u30FC\u30BF\u30FC\u3092\u505C\u6B62\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.stop.systemvm=\u3053\u306E\u30B7\u30B9\u30C6\u30E0 VM \u3092\u505C\u6B62\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.take.snapshot=\u3053\u306E\u30DC\u30EA\u30E5\u30FC\u30E0\u306E\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u3092\u4F5C\u6210\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.action.unmanage.cluster=\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u975E\u7BA1\u7406\u5BFE\u8C61\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.activate.project=\u3053\u306E\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u3092\u30A2\u30AF\u30C6\u30A3\u30D6\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.add.cluster=\u30BE\u30FC\u30F3 \u306E\u30DD\u30C3\u30C9 \u306B\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u3067\u7BA1\u7406\u3055\u308C\u308B\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u8FFD\u52A0\u3057\u307E\u3059 -message.add.cluster.zone=\u30BE\u30FC\u30F3 \u306B\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u3067\u7BA1\u7406\u3055\u308C\u308B\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u8FFD\u52A0\u3057\u307E\u3059 -message.add.disk.offering=\u65B0\u3057\u3044\u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u8FFD\u52A0\u3059\u308B\u305F\u3081\u306B\u3001\u6B21\u306E\u30D1\u30E9\u30E1\u30FC\u30BF\u30FC\u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.add.domain=\u3053\u306E\u30C9\u30E1\u30A4\u30F3\u306B\u4F5C\u6210\u3059\u308B\u30B5\u30D6\u30C9\u30E1\u30A4\u30F3\u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.add.firewall=\u30BE\u30FC\u30F3\u306B\u30D5\u30A1\u30A4\u30A2\u30A6\u30A9\u30FC\u30EB\u3092\u8FFD\u52A0\u3057\u307E\u3059 -message.add.guest.network=\u30B2\u30B9\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u8FFD\u52A0\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.add.host=\u65B0\u3057\u3044\u30DB\u30B9\u30C8\u3092\u8FFD\u52A0\u3059\u308B\u305F\u3081\u306B\u3001\u6B21\u306E\u30D1\u30E9\u30E1\u30FC\u30BF\u30FC\u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.adding.host=\u30DB\u30B9\u30C8\u3092\u8FFD\u52A0\u3057\u3066\u3044\u307E\u3059 -message.adding.Netscaler.device=Netscaler \u30C7\u30D0\u30A4\u30B9\u3092\u8FFD\u52A0\u3057\u3066\u3044\u307E\u3059 -message.adding.Netscaler.provider=Netscaler \u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u3092\u8FFD\u52A0\u3057\u3066\u3044\u307E\u3059 -message.add.ip.range.direct.network=\u30BE\u30FC\u30F3 \u306E\u76F4\u63A5\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u306B IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3092\u8FFD\u52A0\u3057\u307E\u3059 -message.add.ip.range.to.pod=

\u30DD\u30C3\u30C9 \u306B IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3092\u8FFD\u52A0\u3057\u307E\u3059

-message.add.ip.range=\u30BE\u30FC\u30F3\u306E\u30D1\u30D6\u30EA\u30C3\u30AF \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306B IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3092\u8FFD\u52A0\u3057\u307E\u3059 -message.additional.networks.desc=\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u304C\u63A5\u7D9A\u3059\u308B\u8FFD\u52A0\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.add.load.balancer=\u30BE\u30FC\u30F3\u306B\u8CA0\u8377\u5206\u6563\u88C5\u7F6E\u3092\u8FFD\u52A0\u3057\u307E\u3059 -message.add.load.balancer.under.ip=\u8CA0\u8377\u5206\u6563\u898F\u5247\u304C\u6B21\u306E IP \u30A2\u30C9\u30EC\u30B9\u306B\u5BFE\u3057\u3066\u8FFD\u52A0\u3055\u308C\u307E\u3057\u305F\: -message.add.network=\u30BE\u30FC\u30F3 \u306B\u65B0\u3057\u3044\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u8FFD\u52A0\u3057\u307E\u3059 -message.add.new.gateway.to.vpc=\u3053\u306E VPC \u306B\u65B0\u3057\u3044\u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u3092\u8FFD\u52A0\u3059\u308B\u305F\u3081\u306E\u60C5\u5831\u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.add.pod.during.zone.creation=\u5404\u30BE\u30FC\u30F3\u306B\u306F 1 \u3064\u4EE5\u4E0A\u306E\u30DD\u30C3\u30C9\u304C\u5FC5\u8981\u3067\u3059\u3002\u4ECA\u3053\u3053\u3067\u6700\u521D\u306E\u30DD\u30C3\u30C9\u3092\u8FFD\u52A0\u3057\u307E\u3059\u3002\u30DD\u30C3\u30C9\u306F\u30DB\u30B9\u30C8\u3068\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 \u30B5\u30FC\u30D0\u30FC\u304B\u3089\u69CB\u6210\u3055\u308C\u307E\u3059\u304C\u3001\u3053\u308C\u3089\u306F\u5F8C\u306E\u624B\u9806\u3067\u8FFD\u52A0\u3057\u307E\u3059\u3002\u6700\u521D\u306B\u3001CloudStack \u306E\u5185\u90E8\u7BA1\u7406\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u305F\u3081\u306B IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3092\u4E88\u7D04\u3057\u307E\u3059\u3002IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u306F\u3001\u30AF\u30E9\u30A6\u30C9\u5185\u306E\u5404\u30BE\u30FC\u30F3\u3067\u91CD\u8907\u3057\u306A\u3044\u3088\u3046\u306B\u4E88\u7D04\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.add.pod=\u30BE\u30FC\u30F3 \u306B\u65B0\u3057\u3044\u30DD\u30C3\u30C9\u3092\u8FFD\u52A0\u3057\u307E\u3059 -message.add.primary.storage=\u30BE\u30FC\u30F3 \u306E\u30DD\u30C3\u30C9 \u306B\u65B0\u3057\u3044\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u8FFD\u52A0\u3057\u307E\u3059 -message.add.primary=\u65B0\u3057\u3044\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u8FFD\u52A0\u3059\u308B\u305F\u3081\u306B\u3001\u6B21\u306E\u30D1\u30E9\u30E1\u30FC\u30BF\u30FC\u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.add.secondary.storage=\u30BE\u30FC\u30F3 \u306B\u65B0\u3057\u3044\u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u8FFD\u52A0\u3057\u307E\u3059 -message.add.service.offering=\u65B0\u3057\u3044\u30B3\u30F3\u30D4\u30E5\u30FC\u30C6\u30A3\u30F3\u30B0 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u8FFD\u52A0\u3059\u308B\u305F\u3081\u306B\u3001\u6B21\u306E\u30C7\u30FC\u30BF\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.add.system.service.offering=\u65B0\u3057\u3044\u30B7\u30B9\u30C6\u30E0 \u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u8FFD\u52A0\u3059\u308B\u305F\u3081\u306B\u3001\u6B21\u306E\u30C7\u30FC\u30BF\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.add.template=\u65B0\u3057\u3044\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u4F5C\u6210\u3059\u308B\u305F\u3081\u306B\u3001\u6B21\u306E\u30C7\u30FC\u30BF\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.add.volume=\u65B0\u3057\u3044\u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u8FFD\u52A0\u3059\u308B\u305F\u3081\u306B\u3001\u6B21\u306E\u30C7\u30FC\u30BF\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.add.VPN.gateway=VPN \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u3092\u8FFD\u52A0\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.advanced.mode.desc=VLAN \u30B5\u30DD\u30FC\u30C8\u3092\u6709\u52B9\u306B\u3059\u308B\u5834\u5408\u306F\u3001\u3053\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30E2\u30C7\u30EB\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u3053\u306E\u30E2\u30C7\u30EB\u3067\u306F\u6700\u3082\u67D4\u8EDF\u306B\u30AB\u30B9\u30BF\u30E0 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u63D0\u4F9B\u3067\u304D\u3001\u30D5\u30A1\u30A4\u30A2\u30A6\u30A9\u30FC\u30EB\u3001VPN\u3001\u8CA0\u8377\u5206\u6563\u88C5\u7F6E\u306E\u30B5\u30DD\u30FC\u30C8\u306E\u307B\u304B\u306B\u3001\u76F4\u63A5\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3068\u4EEE\u60F3\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3082\u6709\u52B9\u306B\u3059\u308B\u3053\u3068\u304C\u3067\u304D\u307E\u3059\u3002 -message.advanced.security.group=\u30B2\u30B9\u30C8 VM \u3092\u5206\u96E2\u3059\u308B\u305F\u3081\u306B\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u3092\u4F7F\u7528\u3059\u308B\u5834\u5408\u306F\u3001\u3053\u306E\u30AA\u30D7\u30B7\u30E7\u30F3\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.advanced.virtual=\u30B2\u30B9\u30C8 VM \u3092\u5206\u96E2\u3059\u308B\u305F\u3081\u306B\u30BE\u30FC\u30F3\u5168\u4F53\u306E VLAN \u3092\u4F7F\u7528\u3059\u308B\u5834\u5408\u306F\u3001\u3053\u306E\u30AA\u30D7\u30B7\u30E7\u30F3\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 +message.action.manage.cluster=\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u7ba1\u7406\u5bfe\u8c61\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.primarystorage.enable.maintenance.mode=\u8b66\u544a\: \u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u4fdd\u5b88\u30e2\u30fc\u30c9\u306b\u3059\u308b\u3068\u3001\u305d\u306e\u30b9\u30c8\u30ec\u30fc\u30b8\u4e0a\u306e\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u4f7f\u7528\u3059\u308b\u3059\u3079\u3066\u306e VM \u304c\u505c\u6b62\u3057\u307e\u3059\u3002\u7d9a\u884c\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.reboot.instance=\u3053\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u518d\u8d77\u52d5\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.reboot.router=\u3053\u306e\u4eee\u60f3\u30eb\u30fc\u30bf\u30fc\u3067\u63d0\u4f9b\u3059\u308b\u3059\u3079\u3066\u306e\u30b5\u30fc\u30d3\u30b9\u304c\u4e2d\u65ad\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u30eb\u30fc\u30bf\u30fc\u3092\u518d\u8d77\u52d5\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.reboot.systemvm=\u3053\u306e\u30b7\u30b9\u30c6\u30e0 VM \u3092\u518d\u8d77\u52d5\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.release.ip=\u3053\u306e IP \u30a2\u30c9\u30ec\u30b9\u3092\u89e3\u653e\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.remove.host=\u3053\u306e\u30db\u30b9\u30c8\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.reset.password.off=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306f\u73fe\u5728\u3053\u306e\u6a5f\u80fd\u3092\u30b5\u30dd\u30fc\u30c8\u3057\u3066\u3044\u307e\u305b\u3093\u3002 +message.action.reset.password.warning=\u73fe\u5728\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u5909\u66f4\u3059\u308b\u524d\u306b\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u505c\u6b62\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.action.restore.instance=\u3053\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u5fa9\u5143\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.start.instance=\u3053\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u8d77\u52d5\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.start.router=\u3053\u306e\u30eb\u30fc\u30bf\u30fc\u3092\u8d77\u52d5\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.start.systemvm=\u3053\u306e\u30b7\u30b9\u30c6\u30e0 VM \u3092\u8d77\u52d5\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.stop.instance=\u3053\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u505c\u6b62\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.stop.router=\u3053\u306e\u4eee\u60f3\u30eb\u30fc\u30bf\u30fc\u3067\u63d0\u4f9b\u3059\u308b\u3059\u3079\u3066\u306e\u30b5\u30fc\u30d3\u30b9\u304c\u4e2d\u65ad\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u30eb\u30fc\u30bf\u30fc\u3092\u505c\u6b62\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.stop.systemvm=\u3053\u306e\u30b7\u30b9\u30c6\u30e0 VM \u3092\u505c\u6b62\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.take.snapshot=\u3053\u306e\u30dc\u30ea\u30e5\u30fc\u30e0\u306e\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u3092\u4f5c\u6210\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.action.unmanage.cluster=\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u975e\u7ba1\u7406\u5bfe\u8c61\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.activate.project=\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u30a2\u30af\u30c6\u30a3\u30d6\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.add.cluster=\u30be\u30fc\u30f3 \u306e\u30dd\u30c3\u30c9 \u306b\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc\u3067\u7ba1\u7406\u3055\u308c\u308b\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u8ffd\u52a0\u3057\u307e\u3059 +message.add.cluster.zone=\u30be\u30fc\u30f3 \u306b\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc\u3067\u7ba1\u7406\u3055\u308c\u308b\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u8ffd\u52a0\u3057\u307e\u3059 +message.add.disk.offering=\u65b0\u3057\u3044\u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u8ffd\u52a0\u3059\u308b\u305f\u3081\u306b\u3001\u6b21\u306e\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.add.domain=\u3053\u306e\u30c9\u30e1\u30a4\u30f3\u306b\u4f5c\u6210\u3059\u308b\u30b5\u30d6\u30c9\u30e1\u30a4\u30f3\u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.add.firewall=\u30be\u30fc\u30f3\u306b\u30d5\u30a1\u30a4\u30a2\u30a6\u30a9\u30fc\u30eb\u3092\u8ffd\u52a0\u3057\u307e\u3059 +message.add.guest.network=\u30b2\u30b9\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u8ffd\u52a0\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.add.host=\u65b0\u3057\u3044\u30db\u30b9\u30c8\u3092\u8ffd\u52a0\u3059\u308b\u305f\u3081\u306b\u3001\u6b21\u306e\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.adding.host=\u30db\u30b9\u30c8\u3092\u8ffd\u52a0\u3057\u3066\u3044\u307e\u3059 +message.adding.Netscaler.device=Netscaler \u30c7\u30d0\u30a4\u30b9\u3092\u8ffd\u52a0\u3057\u3066\u3044\u307e\u3059 +message.adding.Netscaler.provider=Netscaler \u30d7\u30ed\u30d0\u30a4\u30c0\u30fc\u3092\u8ffd\u52a0\u3057\u3066\u3044\u307e\u3059 +message.add.ip.range.direct.network=\u30be\u30fc\u30f3 \u306e\u76f4\u63a5\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u306b IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3092\u8ffd\u52a0\u3057\u307e\u3059 +message.add.ip.range.to.pod=

\u30dd\u30c3\u30c9 \u306b IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3092\u8ffd\u52a0\u3057\u307e\u3059

+message.add.ip.range=\u30be\u30fc\u30f3\u306e\u30d1\u30d6\u30ea\u30c3\u30af \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306b IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3092\u8ffd\u52a0\u3057\u307e\u3059 +message.additional.networks.desc=\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u304c\u63a5\u7d9a\u3059\u308b\u8ffd\u52a0\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.add.load.balancer=\u30be\u30fc\u30f3\u306b\u8ca0\u8377\u5206\u6563\u88c5\u7f6e\u3092\u8ffd\u52a0\u3057\u307e\u3059 +message.add.load.balancer.under.ip=\u8ca0\u8377\u5206\u6563\u898f\u5247\u304c\u6b21\u306e IP \u30a2\u30c9\u30ec\u30b9\u306b\u5bfe\u3057\u3066\u8ffd\u52a0\u3055\u308c\u307e\u3057\u305f\: +message.add.network=\u30be\u30fc\u30f3 \u306b\u65b0\u3057\u3044\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u8ffd\u52a0\u3057\u307e\u3059 +message.add.new.gateway.to.vpc=\u3053\u306e VPC \u306b\u65b0\u3057\u3044\u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u3092\u8ffd\u52a0\u3059\u308b\u305f\u3081\u306e\u60c5\u5831\u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.add.pod=\u30be\u30fc\u30f3 \u306b\u65b0\u3057\u3044\u30dd\u30c3\u30c9\u3092\u8ffd\u52a0\u3057\u307e\u3059 +message.add.primary.storage=\u30be\u30fc\u30f3 \u306e\u30dd\u30c3\u30c9 \u306b\u65b0\u3057\u3044\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u8ffd\u52a0\u3057\u307e\u3059 +message.add.primary=\u65b0\u3057\u3044\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u8ffd\u52a0\u3059\u308b\u305f\u3081\u306b\u3001\u6b21\u306e\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.add.secondary.storage=\u30be\u30fc\u30f3 \u306b\u65b0\u3057\u3044\u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u8ffd\u52a0\u3057\u307e\u3059 +message.add.service.offering=\u65b0\u3057\u3044\u30b3\u30f3\u30d4\u30e5\u30fc\u30c6\u30a3\u30f3\u30b0 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u8ffd\u52a0\u3059\u308b\u305f\u3081\u306b\u3001\u6b21\u306e\u30c7\u30fc\u30bf\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.add.system.service.offering=\u65b0\u3057\u3044\u30b7\u30b9\u30c6\u30e0 \u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u8ffd\u52a0\u3059\u308b\u305f\u3081\u306b\u3001\u6b21\u306e\u30c7\u30fc\u30bf\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.add.template=\u65b0\u3057\u3044\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u4f5c\u6210\u3059\u308b\u305f\u3081\u306b\u3001\u6b21\u306e\u30c7\u30fc\u30bf\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.add.volume=\u65b0\u3057\u3044\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u8ffd\u52a0\u3059\u308b\u305f\u3081\u306b\u3001\u6b21\u306e\u30c7\u30fc\u30bf\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.add.VPN.gateway=VPN \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u3092\u8ffd\u52a0\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.advanced.mode.desc=VLAN \u30b5\u30dd\u30fc\u30c8\u3092\u6709\u52b9\u306b\u3059\u308b\u5834\u5408\u306f\u3001\u3053\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30e2\u30c7\u30eb\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u3053\u306e\u30e2\u30c7\u30eb\u3067\u306f\u6700\u3082\u67d4\u8edf\u306b\u30ab\u30b9\u30bf\u30e0 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u63d0\u4f9b\u3067\u304d\u3001\u30d5\u30a1\u30a4\u30a2\u30a6\u30a9\u30fc\u30eb\u3001VPN\u3001\u8ca0\u8377\u5206\u6563\u88c5\u7f6e\u306e\u30b5\u30dd\u30fc\u30c8\u306e\u307b\u304b\u306b\u3001\u76f4\u63a5\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3068\u4eee\u60f3\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3082\u6709\u52b9\u306b\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002 +message.advanced.security.group=\u30b2\u30b9\u30c8 VM \u3092\u5206\u96e2\u3059\u308b\u305f\u3081\u306b\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u3092\u4f7f\u7528\u3059\u308b\u5834\u5408\u306f\u3001\u3053\u306e\u30aa\u30d7\u30b7\u30e7\u30f3\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.advanced.virtual=\u30b2\u30b9\u30c8 VM \u3092\u5206\u96e2\u3059\u308b\u305f\u3081\u306b\u30be\u30fc\u30f3\u5168\u4f53\u306e VLAN \u3092\u4f7f\u7528\u3059\u308b\u5834\u5408\u306f\u3001\u3053\u306e\u30aa\u30d7\u30b7\u30e7\u30f3\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 message.after.enable.s3=S3\u57fa\u76e4\u30bb\u30ab\u30f3\u30c0\u30ea\u30b9\u30c8\u30ec\u30fc\u30b8\u304c\u8a2d\u5b9a\u3055\u308c\u307e\u3057\u305f\u3002 \u30ce\u30fc\u30c8\:\u3053\u306e\u30da\u30fc\u30b8\u3092\u9589\u3058\u308b\u3068S3\u3092\u518d\u8a2d\u5b9a\u3067\u304d\u307e\u305b\u3093\u3002 -message.after.enable.swift=Swift \u304C\u69CB\u6210\u3055\u308C\u307E\u3057\u305F\u3002\u6CE8\: \u3053\u306E\u30DA\u30FC\u30B8\u3092\u9589\u3058\u308B\u3068\u3001Swift \u3092\u518D\u69CB\u6210\u3059\u308B\u3053\u3068\u306F\u3067\u304D\u307E\u305B\u3093\u3002 -message.alert.state.detected=\u30A2\u30E9\u30FC\u30C8\u72B6\u614B\u304C\u691C\u51FA\u3055\u308C\u307E\u3057\u305F -message.allow.vpn.access=VPN \u30A2\u30AF\u30BB\u30B9\u3092\u8A31\u53EF\u3059\u308B\u30E6\u30FC\u30B6\u30FC\u306E\u30E6\u30FC\u30B6\u30FC\u540D\u3068\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.apply.snapshot.policy=\u73FE\u5728\u306E\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8 \u30DD\u30EA\u30B7\u30FC\u3092\u66F4\u65B0\u3057\u307E\u3057\u305F\u3002 -message.attach.iso.confirm=\u3053\u306E\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306B ISO \u30D5\u30A1\u30A4\u30EB\u3092\u30A2\u30BF\u30C3\u30C1\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.attach.volume=\u65B0\u3057\u3044\u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u30A2\u30BF\u30C3\u30C1\u3059\u308B\u305F\u3081\u306B\u3001\u6B21\u306E\u30C7\u30FC\u30BF\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002Windows \u30D9\u30FC\u30B9\u306E\u4EEE\u60F3\u30DE\u30B7\u30F3\u306B\u30C7\u30A3\u30B9\u30AF \u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u30A2\u30BF\u30C3\u30C1\u3059\u308B\u5834\u5408\u306F\u3001\u30A2\u30BF\u30C3\u30C1\u3057\u305F\u30C7\u30A3\u30B9\u30AF\u3092\u8A8D\u8B58\u3059\u308B\u305F\u3081\u306B\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u518D\u8D77\u52D5\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.basic.mode.desc=VLAN \u30B5\u30DD\u30FC\u30C8\u304C\u4E0D\u8981\u3067\u3042\u308B\u5834\u5408\u306F\u3001\u3053\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30E2\u30C7\u30EB\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u3053\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30E2\u30C7\u30EB\u3067\u4F5C\u6210\u3055\u308C\u308B\u3059\u3079\u3066\u306E\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306B\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u304B\u3089\u76F4\u63A5 IP \u30A2\u30C9\u30EC\u30B9\u304C\u5272\u308A\u5F53\u3066\u3089\u308C\u3001\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u3092\u4F7F\u7528\u3057\u3066\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3\u3068\u5206\u96E2\u304C\u63D0\u4F9B\u3055\u308C\u307E\u3059\u3002 -message.change.offering.confirm=\u3053\u306E\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u5909\u66F4\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.change.password=\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u5909\u66F4\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.configure.all.traffic.types=\u8907\u6570\u306E\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u304C\u3042\u308A\u307E\u3059\u3002[\u7DE8\u96C6] \u3092\u30AF\u30EA\u30C3\u30AF\u3057\u3066\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u7A2E\u985E\u3054\u3068\u306B\u30E9\u30D9\u30EB\u3092\u69CB\u6210\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.configuring.guest.traffic=\u30B2\u30B9\u30C8 \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u3092\u69CB\u6210\u3057\u3066\u3044\u307E\u3059 -message.configuring.physical.networks=\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u69CB\u6210\u3057\u3066\u3044\u307E\u3059 -message.configuring.public.traffic=\u30D1\u30D6\u30EA\u30C3\u30AF \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u3092\u69CB\u6210\u3057\u3066\u3044\u307E\u3059 -message.configuring.storage.traffic=\u30B9\u30C8\u30EC\u30FC\u30B8 \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u3092\u69CB\u6210\u3057\u3066\u3044\u307E\u3059 -message.confirm.action.force.reconnect=\u3053\u306E\u30DB\u30B9\u30C8\u3092\u5F37\u5236\u518D\u63A5\u7D9A\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.confirm.delete.F5=F5 \u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.confirm.delete.NetScaler=NetScaler \u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.confirm.delete.SRX=SRX \u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.confirm.destroy.router=\u3053\u306E\u30EB\u30FC\u30BF\u30FC\u3092\u7834\u68C4\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.confirm.disable.provider=\u3053\u306E\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u3092\u7121\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.confirm.enable.provider=\u3053\u306E\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u3092\u6709\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.confirm.join.project=\u3053\u306E\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306B\u53C2\u52A0\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.confirm.remove.IP.range=\u3053\u306E IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.confirm.shutdown.provider=\u3053\u306E\u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u3092\u30B7\u30E3\u30C3\u30C8\u30C0\u30A6\u30F3\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.copy.iso.confirm=ISO \u3092\u6B21\u306E\u5834\u6240\u306B\u30B3\u30D4\u30FC\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.copy.template=\u30BE\u30FC\u30F3 \u304B\u3089\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8 XXX \u3092\u6B21\u306E\u5834\u6240\u306B\u30B3\u30D4\u30FC\u3057\u307E\u3059\: -message.create.template=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u4F5C\u6210\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.create.template.vm=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8 \u304B\u3089 VM \u3092\u4F5C\u6210\u3057\u307E\u3059 -message.create.template.volume=\u30C7\u30A3\u30B9\u30AF \u30DC\u30EA\u30E5\u30FC\u30E0 \u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u4F5C\u6210\u3059\u308B\u524D\u306B\u3001\u6B21\u306E\u60C5\u5831\u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u30DC\u30EA\u30E5\u30FC\u30E0 \u30B5\u30A4\u30BA\u306B\u3088\u3063\u3066\u306F\u3001\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u4F5C\u6210\u306B\u306F\u6570\u5206\u4EE5\u4E0A\u304B\u304B\u308B\u53EF\u80FD\u6027\u304C\u3042\u308A\u307E\u3059\u3002 -message.creating.cluster=\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u4F5C\u6210\u3057\u3066\u3044\u307E\u3059 -message.creating.guest.network=\u30B2\u30B9\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u4F5C\u6210\u3057\u3066\u3044\u307E\u3059 -message.creating.physical.networks=\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u4F5C\u6210\u3057\u3066\u3044\u307E\u3059 -message.creating.pod=\u30DD\u30C3\u30C9\u3092\u4F5C\u6210\u3057\u3066\u3044\u307E\u3059 -message.creating.primary.storage=\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u4F5C\u6210\u3057\u3066\u3044\u307E\u3059 -message.creating.secondary.storage=\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u4F5C\u6210\u3057\u3066\u3044\u307E\u3059 -message.creating.zone=\u30BE\u30FC\u30F3\u3092\u4F5C\u6210\u3057\u3066\u3044\u307E\u3059 -message.decline.invitation=\u3053\u306E\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u3078\u306E\u62DB\u5F85\u3092\u8F9E\u9000\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.delete.account=\u3053\u306E\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.delete.gateway=\u3053\u306E\u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.delete.project=\u3053\u306E\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.delete.user=\u3053\u306E\u30E6\u30FC\u30B6\u30FC\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.delete.VPN.connection=VPN \u63A5\u7D9A\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.delete.VPN.customer.gateway=\u3053\u306E VPN \u30AB\u30B9\u30BF\u30DE\u30FC \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.delete.VPN.gateway=\u3053\u306E VPN \u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.desc.advanced.zone=\u3088\u308A\u6D17\u7DF4\u3055\u308C\u305F\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u6280\u8853\u3092\u30B5\u30DD\u30FC\u30C8\u3057\u307E\u3059\u3002\u3053\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30E2\u30C7\u30EB\u3092\u9078\u629E\u3059\u308B\u3068\u3001\u3088\u308A\u67D4\u8EDF\u306B\u30B2\u30B9\u30C8\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u5B9A\u7FA9\u3057\u3001\u30D5\u30A1\u30A4\u30A2\u30A6\u30A9\u30FC\u30EB\u3001VPN\u3001\u8CA0\u8377\u5206\u6563\u88C5\u7F6E\u306E\u30B5\u30DD\u30FC\u30C8\u306E\u3088\u3046\u306A\u30AB\u30B9\u30BF\u30DE\u30A4\u30BA\u3057\u305F\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u63D0\u4F9B\u3067\u304D\u307E\u3059\u3002 -message.desc.basic.zone=\u5404 VM \u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306B IP \u30A2\u30C9\u30EC\u30B9\u304C\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u304B\u3089\u76F4\u63A5\u5272\u308A\u5F53\u3066\u3089\u308C\u308B\u3001\u5358\u4E00\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u63D0\u4F9B\u3057\u307E\u3059\u3002\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7 (\u9001\u4FE1\u5143 IP \u30A2\u30C9\u30EC\u30B9\u306E\u30D5\u30A3\u30EB\u30BF\u30FC) \u306E\u3088\u3046\u306A\u30EC\u30A4\u30E4\u30FC 3 \u30EC\u30D9\u30EB\u306E\u65B9\u6CD5\u3067\u30B2\u30B9\u30C8\u3092\u5206\u96E2\u3067\u304D\u307E\u3059\u3002 -message.desc.cluster=\u5404\u30DD\u30C3\u30C9\u306B\u306F 1 \u3064\u4EE5\u4E0A\u306E\u30AF\u30E9\u30B9\u30BF\u30FC\u304C\u5FC5\u8981\u3067\u3059\u3002\u4ECA\u3053\u3053\u3067\u6700\u521D\u306E\u30AF\u30E9\u30B9\u30BF\u30FC\u3092\u8FFD\u52A0\u3057\u307E\u3059\u3002\u30AF\u30E9\u30B9\u30BF\u30FC\u306F\u30DB\u30B9\u30C8\u3092\u30B0\u30EB\u30FC\u30D7\u5316\u3059\u308B\u65B9\u6CD5\u3067\u3059\u30021 \u3064\u306E\u30AF\u30E9\u30B9\u30BF\u30FC\u5185\u306E\u30DB\u30B9\u30C8\u306F\u3059\u3079\u3066\u540C\u4E00\u306E\u30CF\u30FC\u30C9\u30A6\u30A7\u30A2\u304B\u3089\u69CB\u6210\u3055\u308C\u3001\u540C\u3058\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u3092\u5B9F\u884C\u3057\u3001\u540C\u3058\u30B5\u30D6\u30CD\u30C3\u30C8\u4E0A\u306B\u3042\u308A\u3001\u540C\u3058\u5171\u6709\u30B9\u30C8\u30EC\u30FC\u30B8\u306B\u30A2\u30AF\u30BB\u30B9\u3057\u307E\u3059\u3002\u5404\u30AF\u30E9\u30B9\u30BF\u30FC\u306F 1 \u3064\u4EE5\u4E0A\u306E\u30DB\u30B9\u30C8\u3068 1 \u3064\u4EE5\u4E0A\u306E\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 \u30B5\u30FC\u30D0\u30FC\u304B\u3089\u69CB\u6210\u3055\u308C\u307E\u3059\u3002 -message.desc.host=\u5404\u30AF\u30E9\u30B9\u30BF\u30FC\u306B\u306F\u5C11\u306A\u304F\u3068\u3082 1 \u3064\u3001\u30B2\u30B9\u30C8 VM \u3092\u5B9F\u884C\u3059\u308B\u305F\u3081\u306E\u30DB\u30B9\u30C8 (\u30B3\u30F3\u30D4\u30E5\u30FC\u30BF\u30FC) \u304C\u5FC5\u8981\u3067\u3059\u3002\u4ECA\u3053\u3053\u3067\u6700\u521D\u306E\u30DB\u30B9\u30C8\u3092\u8FFD\u52A0\u3057\u307E\u3059\u3002CloudStack \u3067\u30DB\u30B9\u30C8\u3092\u6A5F\u80FD\u3055\u305B\u308B\u306B\u306F\u3001\u30DB\u30B9\u30C8\u306B\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u3092\u30A4\u30F3\u30B9\u30C8\u30FC\u30EB\u3057\u3066 IP \u30A2\u30C9\u30EC\u30B9\u3092\u5272\u308A\u5F53\u3066\u3001\u30DB\u30B9\u30C8\u304C CloudStack \u7BA1\u7406\u30B5\u30FC\u30D0\u30FC\u306B\u63A5\u7D9A\u3057\u3066\u3044\u308B\u3053\u3068\u3092\u78BA\u8A8D\u3057\u307E\u3059\u3002

\u30DB\u30B9\u30C8\u306E DNS \u540D\u307E\u305F\u306F IP \u30A2\u30C9\u30EC\u30B9\u3001\u30E6\u30FC\u30B6\u30FC\u540D (\u901A\u5E38\u306F root) \u3068\u30D1\u30B9\u30EF\u30FC\u30C9\u3001\u304A\u3088\u3073\u30DB\u30B9\u30C8\u306E\u5206\u985E\u306B\u4F7F\u7528\u3059\u308B\u30E9\u30D9\u30EB\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.desc.primary.storage=\u5404\u30AF\u30E9\u30B9\u30BF\u30FC\u306B\u306F\u5C11\u306A\u304F\u3068\u3082 1 \u3064\u3001\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 \u30B5\u30FC\u30D0\u30FC\u304C\u5FC5\u8981\u3067\u3059\u3002\u4ECA\u3053\u3053\u3067\u6700\u521D\u306E\u30B5\u30FC\u30D0\u30FC\u3092\u8FFD\u52A0\u3057\u307E\u3059\u3002\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u306F\u3001\u30AF\u30E9\u30B9\u30BF\u30FC\u5185\u306E\u30DB\u30B9\u30C8\u4E0A\u3067\u52D5\u4F5C\u3059\u308B\u3059\u3079\u3066\u306E VM \u306E\u30C7\u30A3\u30B9\u30AF \u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u683C\u7D0D\u3057\u307E\u3059\u3002\u57FA\u790E\u3068\u306A\u308B\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u3067\u30B5\u30DD\u30FC\u30C8\u3055\u308C\u308B\u3001\u6A19\u6E96\u306B\u6E96\u62E0\u3057\u305F\u30D7\u30ED\u30C8\u30B3\u30EB\u3092\u4F7F\u7528\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.desc.secondary.storage=\u5404\u30BE\u30FC\u30F3\u306B\u306F\u5C11\u306A\u304F\u3068\u3082 1 \u3064\u3001NFS \u3064\u307E\u308A\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 \u30B5\u30FC\u30D0\u30FC\u304C\u5FC5\u8981\u3067\u3059\u3002\u4ECA\u3053\u3053\u3067\u6700\u521D\u306E\u30B5\u30FC\u30D0\u30FC\u3092\u8FFD\u52A0\u3057\u307E\u3059\u3002\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u306F VM \u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3001ISO \u30A4\u30E1\u30FC\u30B8\u3001\u304A\u3088\u3073VM \u30C7\u30A3\u30B9\u30AF \u30DC\u30EA\u30E5\u30FC\u30E0\u306E\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u3092\u683C\u7D0D\u3057\u307E\u3059\u3002\u3053\u306E\u30B5\u30FC\u30D0\u30FC\u306F\u30BE\u30FC\u30F3\u5185\u306E\u3059\u3079\u3066\u306E\u30DB\u30B9\u30C8\u3067\u4F7F\u7528\u3067\u304D\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002

IP \u30A2\u30C9\u30EC\u30B9\u3068\u30A8\u30AF\u30B9\u30DD\u30FC\u30C8\u3055\u308C\u305F\u30D1\u30B9\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.desc.zone=\u30BE\u30FC\u30F3\u306F CloudStack \u74B0\u5883\u5185\u306E\u6700\u5927\u306E\u7D44\u7E54\u5358\u4F4D\u3067\u3001\u901A\u5E38\u3001\u5358\u4E00\u306E\u30C7\u30FC\u30BF\u30BB\u30F3\u30BF\u30FC\u306B\u76F8\u5F53\u3057\u307E\u3059\u3002\u30BE\u30FC\u30F3\u306B\u3088\u3063\u3066\u7269\u7406\u7684\u306A\u5206\u96E2\u3068\u5197\u9577\u6027\u304C\u63D0\u4F9B\u3055\u308C\u307E\u3059\u3002\u30BE\u30FC\u30F3\u306F 1 \u3064\u4EE5\u4E0A\u306E\u30DD\u30C3\u30C9 (\u5404\u30DD\u30C3\u30C9\u306F\u30DB\u30B9\u30C8\u3068\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 \u30B5\u30FC\u30D0\u30FC\u304B\u3089\u69CB\u6210\u3055\u308C\u307E\u3059) \u3068\u3001\u30BE\u30FC\u30F3\u5185\u306E\u3059\u3079\u3066\u306E\u30DD\u30C3\u30C9\u3067\u5171\u6709\u3055\u308C\u308B\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 \u30B5\u30FC\u30D0\u30FC\u304B\u3089\u69CB\u6210\u3055\u308C\u307E\u3059\u3002 -message.detach.disk=\u3053\u306E\u30C7\u30A3\u30B9\u30AF\u3092\u30C7\u30BF\u30C3\u30C1\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.detach.iso.confirm=\u3053\u306E\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u304B\u3089 ISO \u30D5\u30A1\u30A4\u30EB\u3092\u30C7\u30BF\u30C3\u30C1\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? +message.after.enable.swift=Swift \u304c\u69cb\u6210\u3055\u308c\u307e\u3057\u305f\u3002\u6ce8\: \u3053\u306e\u30da\u30fc\u30b8\u3092\u9589\u3058\u308b\u3068\u3001Swift \u3092\u518d\u69cb\u6210\u3059\u308b\u3053\u3068\u306f\u3067\u304d\u307e\u305b\u3093\u3002 +message.alert.state.detected=\u30a2\u30e9\u30fc\u30c8\u72b6\u614b\u304c\u691c\u51fa\u3055\u308c\u307e\u3057\u305f +message.allow.vpn.access=VPN \u30a2\u30af\u30bb\u30b9\u3092\u8a31\u53ef\u3059\u308b\u30e6\u30fc\u30b6\u30fc\u306e\u30e6\u30fc\u30b6\u30fc\u540d\u3068\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.apply.snapshot.policy=\u73fe\u5728\u306e\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8 \u30dd\u30ea\u30b7\u30fc\u3092\u66f4\u65b0\u3057\u307e\u3057\u305f\u3002 +message.attach.iso.confirm=\u3053\u306e\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306b ISO \u30d5\u30a1\u30a4\u30eb\u3092\u30a2\u30bf\u30c3\u30c1\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.attach.volume=\u65b0\u3057\u3044\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u30a2\u30bf\u30c3\u30c1\u3059\u308b\u305f\u3081\u306b\u3001\u6b21\u306e\u30c7\u30fc\u30bf\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002Windows \u30d9\u30fc\u30b9\u306e\u4eee\u60f3\u30de\u30b7\u30f3\u306b\u30c7\u30a3\u30b9\u30af \u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u30a2\u30bf\u30c3\u30c1\u3059\u308b\u5834\u5408\u306f\u3001\u30a2\u30bf\u30c3\u30c1\u3057\u305f\u30c7\u30a3\u30b9\u30af\u3092\u8a8d\u8b58\u3059\u308b\u305f\u3081\u306b\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u518d\u8d77\u52d5\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.basic.mode.desc=VLAN \u30b5\u30dd\u30fc\u30c8\u304c\u4e0d\u8981\u3067\u3042\u308b\u5834\u5408\u306f\u3001\u3053\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30e2\u30c7\u30eb\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u3053\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30e2\u30c7\u30eb\u3067\u4f5c\u6210\u3055\u308c\u308b\u3059\u3079\u3066\u306e\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306b\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u304b\u3089\u76f4\u63a5 IP \u30a2\u30c9\u30ec\u30b9\u304c\u5272\u308a\u5f53\u3066\u3089\u308c\u3001\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u3092\u4f7f\u7528\u3057\u3066\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u3068\u5206\u96e2\u304c\u63d0\u4f9b\u3055\u308c\u307e\u3059\u3002 +message.change.offering.confirm=\u3053\u306e\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u5909\u66f4\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.change.password=\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u5909\u66f4\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.configure.all.traffic.types=\u8907\u6570\u306e\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u304c\u3042\u308a\u307e\u3059\u3002[\u7de8\u96c6] \u3092\u30af\u30ea\u30c3\u30af\u3057\u3066\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u7a2e\u985e\u3054\u3068\u306b\u30e9\u30d9\u30eb\u3092\u69cb\u6210\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.configuring.guest.traffic=\u30b2\u30b9\u30c8 \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u3092\u69cb\u6210\u3057\u3066\u3044\u307e\u3059 +message.configuring.physical.networks=\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u69cb\u6210\u3057\u3066\u3044\u307e\u3059 +message.configuring.public.traffic=\u30d1\u30d6\u30ea\u30c3\u30af \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u3092\u69cb\u6210\u3057\u3066\u3044\u307e\u3059 +message.configuring.storage.traffic=\u30b9\u30c8\u30ec\u30fc\u30b8 \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u3092\u69cb\u6210\u3057\u3066\u3044\u307e\u3059 +message.confirm.action.force.reconnect=\u3053\u306e\u30db\u30b9\u30c8\u3092\u5f37\u5236\u518d\u63a5\u7d9a\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.confirm.delete.F5=F5 \u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.confirm.delete.NetScaler=NetScaler \u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.confirm.delete.SRX=SRX \u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.confirm.destroy.router=\u3053\u306e\u30eb\u30fc\u30bf\u30fc\u3092\u7834\u68c4\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.confirm.disable.provider=\u3053\u306e\u30d7\u30ed\u30d0\u30a4\u30c0\u30fc\u3092\u7121\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.confirm.enable.provider=\u3053\u306e\u30d7\u30ed\u30d0\u30a4\u30c0\u30fc\u3092\u6709\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.confirm.join.project=\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306b\u53c2\u52a0\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.confirm.remove.IP.range=\u3053\u306e IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.confirm.shutdown.provider=\u3053\u306e\u30d7\u30ed\u30d0\u30a4\u30c0\u30fc\u3092\u30b7\u30e3\u30c3\u30c8\u30c0\u30a6\u30f3\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.copy.iso.confirm=ISO \u3092\u6b21\u306e\u5834\u6240\u306b\u30b3\u30d4\u30fc\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.copy.template=\u30be\u30fc\u30f3 \u304b\u3089\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8 XXX \u3092\u6b21\u306e\u5834\u6240\u306b\u30b3\u30d4\u30fc\u3057\u307e\u3059\: +message.create.template=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u4f5c\u6210\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.create.template.vm=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8 \u304b\u3089 VM \u3092\u4f5c\u6210\u3057\u307e\u3059 +message.create.template.volume=\u30c7\u30a3\u30b9\u30af \u30dc\u30ea\u30e5\u30fc\u30e0 \u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u4f5c\u6210\u3059\u308b\u524d\u306b\u3001\u6b21\u306e\u60c5\u5831\u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u30dc\u30ea\u30e5\u30fc\u30e0 \u30b5\u30a4\u30ba\u306b\u3088\u3063\u3066\u306f\u3001\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u4f5c\u6210\u306b\u306f\u6570\u5206\u4ee5\u4e0a\u304b\u304b\u308b\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002 +message.creating.cluster=\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059 +message.creating.guest.network=\u30b2\u30b9\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059 +message.creating.physical.networks=\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059 +message.creating.pod=\u30dd\u30c3\u30c9\u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059 +message.creating.primary.storage=\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059 +message.creating.secondary.storage=\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059 +message.creating.zone=\u30be\u30fc\u30f3\u3092\u4f5c\u6210\u3057\u3066\u3044\u307e\u3059 +message.decline.invitation=\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3078\u306e\u62db\u5f85\u3092\u8f9e\u9000\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.delete.account=\u3053\u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.delete.gateway=\u3053\u306e\u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.delete.project=\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.delete.user=\u3053\u306e\u30e6\u30fc\u30b6\u30fc\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.delete.VPN.connection=VPN \u63a5\u7d9a\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.delete.VPN.customer.gateway=\u3053\u306e VPN \u30ab\u30b9\u30bf\u30de\u30fc \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.delete.VPN.gateway=\u3053\u306e VPN \u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.desc.advanced.zone=\u3088\u308a\u6d17\u7df4\u3055\u308c\u305f\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u6280\u8853\u3092\u30b5\u30dd\u30fc\u30c8\u3057\u307e\u3059\u3002\u3053\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30e2\u30c7\u30eb\u3092\u9078\u629e\u3059\u308b\u3068\u3001\u3088\u308a\u67d4\u8edf\u306b\u30b2\u30b9\u30c8\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u5b9a\u7fa9\u3057\u3001\u30d5\u30a1\u30a4\u30a2\u30a6\u30a9\u30fc\u30eb\u3001VPN\u3001\u8ca0\u8377\u5206\u6563\u88c5\u7f6e\u306e\u30b5\u30dd\u30fc\u30c8\u306e\u3088\u3046\u306a\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u3057\u305f\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u63d0\u4f9b\u3067\u304d\u307e\u3059\u3002 +message.desc.basic.zone=\u5404 VM \u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306b IP \u30a2\u30c9\u30ec\u30b9\u304c\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u304b\u3089\u76f4\u63a5\u5272\u308a\u5f53\u3066\u3089\u308c\u308b\u3001\u5358\u4e00\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u63d0\u4f9b\u3057\u307e\u3059\u3002\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7 (\u9001\u4fe1\u5143 IP \u30a2\u30c9\u30ec\u30b9\u306e\u30d5\u30a3\u30eb\u30bf\u30fc) \u306e\u3088\u3046\u306a\u30ec\u30a4\u30e4\u30fc 3 \u30ec\u30d9\u30eb\u306e\u65b9\u6cd5\u3067\u30b2\u30b9\u30c8\u3092\u5206\u96e2\u3067\u304d\u307e\u3059\u3002 +message.desc.cluster=\u5404\u30dd\u30c3\u30c9\u306b\u306f 1 \u3064\u4ee5\u4e0a\u306e\u30af\u30e9\u30b9\u30bf\u30fc\u304c\u5fc5\u8981\u3067\u3059\u3002\u4eca\u3053\u3053\u3067\u6700\u521d\u306e\u30af\u30e9\u30b9\u30bf\u30fc\u3092\u8ffd\u52a0\u3057\u307e\u3059\u3002\u30af\u30e9\u30b9\u30bf\u30fc\u306f\u30db\u30b9\u30c8\u3092\u30b0\u30eb\u30fc\u30d7\u5316\u3059\u308b\u65b9\u6cd5\u3067\u3059\u30021 \u3064\u306e\u30af\u30e9\u30b9\u30bf\u30fc\u5185\u306e\u30db\u30b9\u30c8\u306f\u3059\u3079\u3066\u540c\u4e00\u306e\u30cf\u30fc\u30c9\u30a6\u30a7\u30a2\u304b\u3089\u69cb\u6210\u3055\u308c\u3001\u540c\u3058\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc\u3092\u5b9f\u884c\u3057\u3001\u540c\u3058\u30b5\u30d6\u30cd\u30c3\u30c8\u4e0a\u306b\u3042\u308a\u3001\u540c\u3058\u5171\u6709\u30b9\u30c8\u30ec\u30fc\u30b8\u306b\u30a2\u30af\u30bb\u30b9\u3057\u307e\u3059\u3002\u5404\u30af\u30e9\u30b9\u30bf\u30fc\u306f 1 \u3064\u4ee5\u4e0a\u306e\u30db\u30b9\u30c8\u3068 1 \u3064\u4ee5\u4e0a\u306e\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 \u30b5\u30fc\u30d0\u30fc\u304b\u3089\u69cb\u6210\u3055\u308c\u307e\u3059\u3002 +message.desc.primary.storage=\u5404\u30af\u30e9\u30b9\u30bf\u30fc\u306b\u306f\u5c11\u306a\u304f\u3068\u3082 1 \u3064\u3001\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 \u30b5\u30fc\u30d0\u30fc\u304c\u5fc5\u8981\u3067\u3059\u3002\u4eca\u3053\u3053\u3067\u6700\u521d\u306e\u30b5\u30fc\u30d0\u30fc\u3092\u8ffd\u52a0\u3057\u307e\u3059\u3002\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u306f\u3001\u30af\u30e9\u30b9\u30bf\u30fc\u5185\u306e\u30db\u30b9\u30c8\u4e0a\u3067\u52d5\u4f5c\u3059\u308b\u3059\u3079\u3066\u306e VM \u306e\u30c7\u30a3\u30b9\u30af \u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u683c\u7d0d\u3057\u307e\u3059\u3002\u57fa\u790e\u3068\u306a\u308b\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc\u3067\u30b5\u30dd\u30fc\u30c8\u3055\u308c\u308b\u3001\u6a19\u6e96\u306b\u6e96\u62e0\u3057\u305f\u30d7\u30ed\u30c8\u30b3\u30eb\u3092\u4f7f\u7528\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.desc.secondary.storage=\u5404\u30be\u30fc\u30f3\u306b\u306f\u5c11\u306a\u304f\u3068\u3082 1 \u3064\u3001NFS \u3064\u307e\u308a\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 \u30b5\u30fc\u30d0\u30fc\u304c\u5fc5\u8981\u3067\u3059\u3002\u4eca\u3053\u3053\u3067\u6700\u521d\u306e\u30b5\u30fc\u30d0\u30fc\u3092\u8ffd\u52a0\u3057\u307e\u3059\u3002\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u306f VM \u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3001ISO \u30a4\u30e1\u30fc\u30b8\u3001\u304a\u3088\u3073VM \u30c7\u30a3\u30b9\u30af \u30dc\u30ea\u30e5\u30fc\u30e0\u306e\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u3092\u683c\u7d0d\u3057\u307e\u3059\u3002\u3053\u306e\u30b5\u30fc\u30d0\u30fc\u306f\u30be\u30fc\u30f3\u5185\u306e\u3059\u3079\u3066\u306e\u30db\u30b9\u30c8\u3067\u4f7f\u7528\u3067\u304d\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002

IP \u30a2\u30c9\u30ec\u30b9\u3068\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3055\u308c\u305f\u30d1\u30b9\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.desc.zone=\u30be\u30fc\u30f3\u306f CloudStack \u74b0\u5883\u5185\u306e\u6700\u5927\u306e\u7d44\u7e54\u5358\u4f4d\u3067\u3001\u901a\u5e38\u3001\u5358\u4e00\u306e\u30c7\u30fc\u30bf\u30bb\u30f3\u30bf\u30fc\u306b\u76f8\u5f53\u3057\u307e\u3059\u3002\u30be\u30fc\u30f3\u306b\u3088\u3063\u3066\u7269\u7406\u7684\u306a\u5206\u96e2\u3068\u5197\u9577\u6027\u304c\u63d0\u4f9b\u3055\u308c\u307e\u3059\u3002\u30be\u30fc\u30f3\u306f 1 \u3064\u4ee5\u4e0a\u306e\u30dd\u30c3\u30c9 (\u5404\u30dd\u30c3\u30c9\u306f\u30db\u30b9\u30c8\u3068\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 \u30b5\u30fc\u30d0\u30fc\u304b\u3089\u69cb\u6210\u3055\u308c\u307e\u3059) \u3068\u3001\u30be\u30fc\u30f3\u5185\u306e\u3059\u3079\u3066\u306e\u30dd\u30c3\u30c9\u3067\u5171\u6709\u3055\u308c\u308b\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 \u30b5\u30fc\u30d0\u30fc\u304b\u3089\u69cb\u6210\u3055\u308c\u307e\u3059\u3002 +message.detach.disk=\u3053\u306e\u30c7\u30a3\u30b9\u30af\u3092\u30c7\u30bf\u30c3\u30c1\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.detach.iso.confirm=\u3053\u306e\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u304b\u3089 ISO \u30d5\u30a1\u30a4\u30eb\u3092\u30c7\u30bf\u30c3\u30c1\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? message.disable.account=\u00e3\u0081\u0093\u00e3\u0081\u00ae\u00e3\u0082\u00a2\u00e3\u0082\u00ab\u00e3\u0082\u00a6\u00e3\u0083\u00b3\u00e3\u0083\u0088\u00e3\u0082\u0092\u00e7\u0084\u00a1\u00e5\u008a\u00b9\u00e3\u0081\u00ab\u00e3\u0081\u0097\u00e3\u0081\u00a6\u00e3\u0082\u0082\u00e3\u0082\u0088\u00e3\u0082\u008d\u00e3\u0081\u0097\u00e3\u0081\u0084\u00e3\u0081\u00a7\u00e3\u0081\u0099\u00e3\u0081\u008b? \u00e3\u0082\u00a2\u00e3\u0082\u00ab\u00e3\u0082\u00a6\u00e3\u0083\u00b3\u00e3\u0083\u0088\u00e3\u0082\u0092\u00e7\u0084\u00a1\u00e5\u008a\u00b9\u00e3\u0081\u00ab\u00e3\u0081\u0099\u00e3\u0082\u008b\u00e3\u0081\u0093\u00e3\u0081\u00a8\u00e3\u0081\u00ab\u00e3\u0082\u0088\u00e3\u0082\u008a\u00e3\u0080\u0081\u00e3\u0081\u0093\u00e3\u0081\u00ae\u00e3\u0082\u00a2\u00e3\u0082\u00ab\u00e3\u0082\u00a6\u00e3\u0083\u00b3\u00e3\u0083\u0088\u00e3\u0081\u00ae\u00e3\u0081\u0099\u00e3\u0081\u00b9\u00e3\u0081\u00a6\u00e3\u0081\u00ae\u00e3\u0083\u00a6\u00e3\u0083\u00bc\u00e3\u0082\u00b6\u00e3\u0083\u00bc\u00e3\u0081\u00af\u00e3\u0082\u00af\u00e3\u0083\u00a9\u00e3\u0082\u00a6\u00e3\u0083\u0089\u00e3\u0083\u00aa\u00e3\u0082\u00bd\u00e3\u0083\u00bc\u00e3\u0082\u00b9\u00e3\u0081\u00ab\u00e3\u0082\u00a2\u00e3\u0082\u00af\u00e3\u0082\u00bb\u00e3\u0082\u00b9\u00e3\u0081\u00a7\u00e3\u0081\u008d\u00e3\u0081\u00aa\u00e3\u0081\u008f\u00e3\u0081\u00aa\u00e3\u0082\u008a\u00e3\u0081\u00be\u00e3\u0081\u0099\u00e3\u0080\u0082\u00e5\u00ae\u009f\u00e8\u00a1\u008c\u00e4\u00b8\u00ad\u00e3\u0081\u00ae\u00e3\u0081\u0099\u00e3\u0081\u00b9\u00e3\u0081\u00a6\u00e3\u0081\u00ae\u00e4\u00bb\u00ae\u00e6\u0083\u00b3\u00e3\u0083\u009e\u00e3\u0082\u00b7\u00e3\u0083\u00b3\u00e3\u0081\u00af\u00e3\u0081\u0099\u00e3\u0081\u0090\u00e3\u0081\u00ab\u00e3\u0082\u00b7\u00e3\u0083\u00a3\u00e3\u0083\u0083\u00e3\u0083\u0088\u00e3\u0083\u0080\u00e3\u0082\u00a6\u00e3\u0083\u00b3\u00e3\u0081\u0095\u00e3\u0082\u008c\u00e3\u0081\u00be\u00e3\u0081\u0099\u00e3\u0080\u0082 -message.disable.snapshot.policy=\u73FE\u5728\u306E\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8 \u30DD\u30EA\u30B7\u30FC\u3092\u7121\u52B9\u306B\u3057\u307E\u3057\u305F\u3002 -message.disable.user=\u3053\u306E\u30E6\u30FC\u30B6\u30FC\u3092\u7121\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.disable.vpn.access=VPN \u30A2\u30AF\u30BB\u30B9\u3092\u7121\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.disable.vpn=VPN \u3092\u7121\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? +message.disable.snapshot.policy=\u73fe\u5728\u306e\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8 \u30dd\u30ea\u30b7\u30fc\u3092\u7121\u52b9\u306b\u3057\u307e\u3057\u305f\u3002 +message.disable.user=\u3053\u306e\u30e6\u30fc\u30b6\u30fc\u3092\u7121\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.disable.vpn.access=VPN \u30a2\u30af\u30bb\u30b9\u3092\u7121\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.disable.vpn=VPN \u3092\u7121\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? message.download.ISO=ISO\u00e3\u0082\u0092\u00e3\u0083\u0080\u00e3\u0082\u00a6\u00e3\u0083\u00b3\u00e3\u0083\u00ad\u00e3\u0083\u00bc\u00e3\u0083\u0089\u00e3\u0081\u0099\u00e3\u0082\u008b\u00e3\u0081\u009f\u00e3\u0082\u0081\u00e3\u0081\u00ab00000\u00e3\u0082\u0092\u00e3\u0082\u00af\u00e3\u0083\u00aa\u00e3\u0083\u0083\u00e3\u0082\u00af\u00e3\u0081\u0097\u00e3\u0081\u00a6\u00e3\u0081\u008f\u00e3\u0081\u00a0\u00e3\u0081\u0095\u00e3\u0081\u0084\u00e3\u0080\u0082 message.download.template=\u00e3\u0083\u0086\u00e3\u0083\u00b3\u00e3\u0083\u0097\u00e3\u0083\u00ac\u00e3\u0083\u00bc\u00e3\u0083\u0088\u00e3\u0082\u0092\u00e3\u0083\u0080\u00e3\u0082\u00a6\u00e3\u0083\u00b3\u00e3\u0083\u00ad\u00e3\u0083\u00bc\u00e3\u0083\u0089\u00e3\u0081\u0099\u00e3\u0082\u008b\u00e3\u0081\u009f\u00e3\u0082\u0081\u00e3\u0081\u00ab00000\u00e3\u0082\u0092\u00e3\u0082\u00af\u00e3\u0083\u00aa\u00e3\u0083\u0083\u00e3\u0082\u00af\u00e3\u0081\u0097\u00e3\u0081\u00a6\u00e3\u0081\u008f\u00e3\u0081\u00a0\u00e3\u0081\u0095\u00e3\u0081\u0084\u00e3\u0080\u0082 -message.download.volume.confirm=\u3053\u306E\u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u30C0\u30A6\u30F3\u30ED\u30FC\u30C9\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.download.volume=\u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u30C0\u30A6\u30F3\u30ED\u30FC\u30C9\u3059\u308B\u306B\u306F 00000 \u3092\u30AF\u30EA\u30C3\u30AF\u3057\u307E\u3059 -message.edit.account=\u7DE8\u96C6 ("-1" \u306F\u3001\u30EA\u30BD\u30FC\u30B9\u4F5C\u6210\u306E\u91CF\u306B\u5236\u9650\u304C\u306A\u3044\u3053\u3068\u3092\u793A\u3057\u307E\u3059) -message.edit.confirm=[\u4FDD\u5B58] \u3092\u30AF\u30EA\u30C3\u30AF\u3059\u308B\u524D\u306B\u5909\u66F4\u5185\u5BB9\u3092\u78BA\u8A8D\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.edit.limits=\u6B21\u306E\u30EA\u30BD\u30FC\u30B9\u306B\u5236\u9650\u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u300C-1\u300D\u306F\u3001\u30EA\u30BD\u30FC\u30B9\u4F5C\u6210\u306B\u5236\u9650\u304C\u306A\u3044\u3053\u3068\u3092\u793A\u3057\u307E\u3059\u3002 -message.edit.traffic.type=\u3053\u306E\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u7A2E\u985E\u306B\u95A2\u9023\u4ED8\u3051\u308B\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF \u30E9\u30D9\u30EB\u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.enable.account=\u3053\u306E\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u6709\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.enabled.vpn.ip.sec=IPSec \u4E8B\u524D\u5171\u6709\u30AD\u30FC\: -message.enabled.vpn=\u73FE\u5728\u3001VPN \u30A2\u30AF\u30BB\u30B9\u304C\u6709\u52B9\u306B\u306A\u3063\u3066\u3044\u307E\u3059\u3002\u6B21\u306E IP \u30A2\u30C9\u30EC\u30B9\u7D4C\u7531\u3067\u30A2\u30AF\u30BB\u30B9\u3067\u304D\u307E\u3059\u3002 -message.enable.user=\u3053\u306E\u30E6\u30FC\u30B6\u30FC\u3092\u6709\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.enable.vpn.access=\u73FE\u5728\u3053\u306E IP \u30A2\u30C9\u30EC\u30B9\u306B\u5BFE\u3059\u308B VPN \u306F\u7121\u52B9\u3067\u3059\u3002VPN \u30A2\u30AF\u30BB\u30B9\u3092\u6709\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.enable.vpn=\u3053\u306E IP \u30A2\u30C9\u30EC\u30B9\u306B\u5BFE\u3059\u308B VPN \u30A2\u30AF\u30BB\u30B9\u3092\u6709\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.enabling.security.group.provider=\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7 \u30D7\u30ED\u30D0\u30A4\u30C0\u30FC\u3092\u6709\u52B9\u306B\u3057\u3066\u3044\u307E\u3059 -message.enabling.zone=\u30BE\u30FC\u30F3\u3092\u6709\u52B9\u306B\u3057\u3066\u3044\u307E\u3059 -message.enter.token=\u96FB\u5B50\u30E1\u30FC\u30EB\u306E\u62DB\u5F85\u72B6\u306B\u8A18\u8F09\u3055\u308C\u3066\u3044\u308B\u30C8\u30FC\u30AF\u30F3\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.generate.keys=\u3053\u306E\u30E6\u30FC\u30B6\u30FC\u306B\u65B0\u3057\u3044\u30AD\u30FC\u3092\u751F\u6210\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.guest.traffic.in.advanced.zone=\u30B2\u30B9\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306F\u3001\u30A8\u30F3\u30C9 \u30E6\u30FC\u30B6\u30FC\u306E\u4EEE\u60F3\u30DE\u30B7\u30F3\u9593\u306E\u901A\u4FE1\u3067\u3059\u3002\u5404\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u30B2\u30B9\u30C8 \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u3092\u901A\u4FE1\u3059\u308B\u305F\u3081\u306E VLAN ID \u306E\u7BC4\u56F2\u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.guest.traffic.in.basic.zone=\u30B2\u30B9\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306F\u3001\u30A8\u30F3\u30C9 \u30E6\u30FC\u30B6\u30FC\u306E\u4EEE\u60F3\u30DE\u30B7\u30F3\u9593\u306E\u901A\u4FE1\u3067\u3059\u3002CloudStack \u3067\u30B2\u30B9\u30C8 VM \u306B\u5272\u308A\u5F53\u3066\u3089\u308C\u308B IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u3053\u306E\u7BC4\u56F2\u304C\u4E88\u7D04\u6E08\u307F\u306E\u30B7\u30B9\u30C6\u30E0 IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3068\u91CD\u8907\u3057\u306A\u3044\u3088\u3046\u306B\u6CE8\u610F\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.installWizard.click.retry=\u8D77\u52D5\u3092\u518D\u8A66\u884C\u3059\u308B\u306B\u306F\u30DC\u30BF\u30F3\u3092\u30AF\u30EA\u30C3\u30AF\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.installWizard.copy.whatIsAPod=\u901A\u5E38\u30011 \u3064\u306E\u30DD\u30C3\u30C9\u306F\u5358\u4E00\u306E\u30E9\u30C3\u30AF\u3092\u8868\u3057\u307E\u3059\u3002\u540C\u3058\u30DD\u30C3\u30C9\u5185\u306E\u30DB\u30B9\u30C8\u306F\u540C\u3058\u30B5\u30D6\u30CD\u30C3\u30C8\u306B\u542B\u307E\u308C\u307E\u3059\u3002

\u30DD\u30C3\u30C9\u306F CloudStack&\#8482; \u74B0\u5883\u5185\u306E 2 \u756A\u76EE\u306B\u5927\u304D\u306A\u7D44\u7E54\u5358\u4F4D\u3067\u3059\u3002\u30DD\u30C3\u30C9\u306F\u30BE\u30FC\u30F3\u306B\u542B\u307E\u308C\u307E\u3059\u3002\u5404\u30BE\u30FC\u30F3\u306F 1 \u3064\u4EE5\u4E0A\u306E\u30DD\u30C3\u30C9\u3092\u542B\u3080\u3053\u3068\u304C\u3067\u304D\u307E\u3059\u3002\u57FA\u672C\u30A4\u30F3\u30B9\u30C8\u30FC\u30EB\u3067\u306F\u3001\u30BE\u30FC\u30F3\u5185\u306E\u30DD\u30C3\u30C9\u306F 1 \u3064\u3067\u3059\u3002 -message.installWizard.copy.whatIsAZone=\u30BE\u30FC\u30F3\u306F CloudStack&\#8482; \u74B0\u5883\u5185\u306E\u6700\u5927\u306E\u7D44\u7E54\u5358\u4F4D\u3067\u3059\u30021 \u3064\u306E\u30C7\u30FC\u30BF\u30BB\u30F3\u30BF\u30FC\u5185\u306B\u8907\u6570\u306E\u30BE\u30FC\u30F3\u3092\u8A2D\u5B9A\u3067\u304D\u307E\u3059\u304C\u3001\u901A\u5E38\u3001\u30BE\u30FC\u30F3\u306F\u5358\u4E00\u306E\u30C7\u30FC\u30BF\u30BB\u30F3\u30BF\u30FC\u306B\u76F8\u5F53\u3057\u307E\u3059\u3002\u30A4\u30F3\u30D5\u30E9\u30B9\u30C8\u30E9\u30AF\u30C1\u30E3\u3092\u30BE\u30FC\u30F3\u306B\u7D44\u7E54\u5316\u3059\u308B\u3068\u3001\u30BE\u30FC\u30F3\u3092\u7269\u7406\u7684\u306B\u5206\u96E2\u3057\u3066\u5197\u9577\u5316\u3059\u308B\u3053\u3068\u304C\u3067\u304D\u307E\u3059\u3002\u305F\u3068\u3048\u3070\u3001\u5404\u30BE\u30FC\u30F3\u306B\u96FB\u6E90\u3068\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30A2\u30C3\u30D7\u30EA\u30F3\u30AF\u3092\u914D\u5099\u3057\u307E\u3059\u3002\u5FC5\u9808\u3067\u306F\u3042\u308A\u307E\u305B\u3093\u304C\u3001\u30BE\u30FC\u30F3\u306F\u9060\u9694\u5730\u306B\u5206\u6563\u3059\u308B\u3053\u3068\u304C\u3067\u304D\u307E\u3059\u3002 -message.installWizard.copy.whatIsSecondaryStorage=\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u306F\u30BE\u30FC\u30F3\u3068\u95A2\u9023\u4ED8\u3051\u3089\u308C\u3001\u6B21\u306E\u9805\u76EE\u3092\u683C\u7D0D\u3057\u307E\u3059\u3002
  • \u30C6\u30F3\u30D7\u30EC\u30FC\u30C8 - VM \u306E\u8D77\u52D5\u306B\u4F7F\u7528\u3067\u304D\u308B OS \u30A4\u30E1\u30FC\u30B8\u3067\u3001\u30A2\u30D7\u30EA\u30B1\u30FC\u30B7\u30E7\u30F3\u306E\u30A4\u30F3\u30B9\u30C8\u30FC\u30EB\u306A\u3069\u8FFD\u52A0\u306E\u69CB\u6210\u3092\u542B\u3081\u308B\u3053\u3068\u304C\u3067\u304D\u307E\u3059\u3002
  • ISO \u30A4\u30E1\u30FC\u30B8 - \u8D77\u52D5\u53EF\u80FD\u307E\u305F\u306F\u8D77\u52D5\u4E0D\u53EF\u306E OS \u30A4\u30E1\u30FC\u30B8\u3067\u3059\u3002
  • \u30C7\u30A3\u30B9\u30AF \u30DC\u30EA\u30E5\u30FC\u30E0\u306E\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8 - VM \u30C7\u30FC\u30BF\u306E\u4FDD\u5B58\u30B3\u30D4\u30FC\u3067\u3059\u3002\u30C7\u30FC\u30BF\u306E\u5FA9\u5143\u307E\u305F\u306F\u65B0\u3057\u3044\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u4F5C\u6210\u306B\u4F7F\u7528\u3067\u304D\u307E\u3059\u3002
-message.installWizard.tooltip.addCluster.name=\u30AF\u30E9\u30B9\u30BF\u30FC\u306E\u540D\u524D\u3067\u3059\u3002CloudStack \u3067\u4F7F\u7528\u3055\u308C\u3066\u3044\u306A\u3044\u3001\u4EFB\u610F\u306E\u30C6\u30AD\u30B9\u30C8\u3092\u6307\u5B9A\u3067\u304D\u307E\u3059\u3002 -message.installWizard.tooltip.addHost.hostname=\u30DB\u30B9\u30C8\u306E DNS \u540D\u307E\u305F\u306F IP \u30A2\u30C9\u30EC\u30B9\u3067\u3059\u3002 -message.installWizard.tooltip.addHost.password=XenServer \u5074\u3067\u6307\u5B9A\u3057\u305F\u3001\u4E0A\u306E\u30E6\u30FC\u30B6\u30FC\u540D\u306B\u5BFE\u3059\u308B\u30D1\u30B9\u30EF\u30FC\u30C9\u3067\u3059\u3002 -message.installWizard.tooltip.addHost.username=\u901A\u5E38\u306F root \u3067\u3059\u3002 -message.installWizard.tooltip.addPod.name=\u30DD\u30C3\u30C9\u306E\u540D\u524D\u3067\u3059\u3002 -message.installWizard.tooltip.addPod.reservedSystemEndIp=\u3053\u308C\u306F\u3001\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 VM \u304A\u3088\u3073\u30B3\u30F3\u30BD\u30FC\u30EB \u30D7\u30ED\u30AD\u30B7 VM \u3092\u7BA1\u7406\u3059\u308B\u305F\u3081\u306B CloudStack \u3067\u4F7F\u7528\u3059\u308B\u3001\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u5185\u306E IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3067\u3059\u3002\u3053\u308C\u3089\u306E IP \u30A2\u30C9\u30EC\u30B9\u306F\u30B3\u30F3\u30D4\u30E5\u30FC\u30C6\u30A3\u30F3\u30B0 \u30B5\u30FC\u30D0\u30FC\u3068\u540C\u3058\u30B5\u30D6\u30CD\u30C3\u30C8\u304B\u3089\u5272\u308A\u5F53\u3066\u307E\u3059\u3002 -message.installWizard.tooltip.addPod.reservedSystemGateway=\u3053\u306E\u30DD\u30C3\u30C9\u5185\u306E\u30DB\u30B9\u30C8\u306E\u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u3067\u3059\u3002 -message.installWizard.tooltip.addPod.reservedSystemNetmask=\u30B2\u30B9\u30C8\u306E\u4F7F\u7528\u3059\u308B\u30B5\u30D6\u30CD\u30C3\u30C8\u4E0A\u3067\u4F7F\u7528\u3055\u308C\u308B\u30CD\u30C3\u30C8\u30DE\u30B9\u30AF\u3067\u3059\u3002 -message.installWizard.tooltip.addPod.reservedSystemStartIp=\u3053\u308C\u306F\u3001\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 VM \u304A\u3088\u3073\u30B3\u30F3\u30BD\u30FC\u30EB \u30D7\u30ED\u30AD\u30B7 VM \u3092\u7BA1\u7406\u3059\u308B\u305F\u3081\u306B CloudStack \u3067\u4F7F\u7528\u3059\u308B\u3001\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u5185\u306E IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3067\u3059\u3002\u3053\u308C\u3089\u306E IP \u30A2\u30C9\u30EC\u30B9\u306F\u30B3\u30F3\u30D4\u30E5\u30FC\u30C6\u30A3\u30F3\u30B0 \u30B5\u30FC\u30D0\u30FC\u3068\u540C\u3058\u30B5\u30D6\u30CD\u30C3\u30C8\u304B\u3089\u5272\u308A\u5F53\u3066\u307E\u3059\u3002 -message.installWizard.tooltip.addPrimaryStorage.name=\u30B9\u30C8\u30EC\u30FC\u30B8 \u30C7\u30D0\u30A4\u30B9\u306E\u540D\u524D\u3067\u3059\u3002 -message.installWizard.tooltip.addPrimaryStorage.path=(NFS \u306E\u5834\u5408) \u30B5\u30FC\u30D0\u30FC\u304B\u3089\u30A8\u30AF\u30B9\u30DD\u30FC\u30C8\u3055\u308C\u305F\u30D1\u30B9\u3067\u3059\u3002(SharedMountPoint \u306E\u5834\u5408) \u30D1\u30B9\u3067\u3059\u3002KVM \u3067\u306F\u3053\u306E\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u304C\u30DE\u30A6\u30F3\u30C8\u3055\u308C\u308B\u5404\u30DB\u30B9\u30C8\u4E0A\u306E\u30D1\u30B9\u3067\u3059\u3002\u305F\u3068\u3048\u3070\u3001/mnt/primary \u3067\u3059\u3002 -message.installWizard.tooltip.addPrimaryStorage.server=(NFS\u3001iSCSI\u3001\u307E\u305F\u306F PreSetup \u306E\u5834\u5408) \u30B9\u30C8\u30EC\u30FC\u30B8 \u30C7\u30D0\u30A4\u30B9\u306E IP \u30A2\u30C9\u30EC\u30B9\u307E\u305F\u306F DNS \u540D\u3067\u3059\u3002 -message.installWizard.tooltip.addSecondaryStorage.nfsServer=\u30BB\u30AB\u30F3\u30C0\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u30DB\u30B9\u30C8\u3059\u308B NFS \u30B5\u30FC\u30D0\u30FC\u306E IP \u30A2\u30C9\u30EC\u30B9\u3067\u3059\u3002 -message.installWizard.tooltip.addSecondaryStorage.path=\u4E0A\u306B\u6307\u5B9A\u3057\u305F\u30B5\u30FC\u30D0\u30FC\u306B\u5B58\u5728\u3059\u308B\u3001\u30A8\u30AF\u30B9\u30DD\u30FC\u30C8\u3055\u308C\u305F\u30D1\u30B9\u3067\u3059\u3002 -message.installWizard.tooltip.addZone.dns1=\u30BE\u30FC\u30F3\u5185\u306E\u30B2\u30B9\u30C8 VM \u3067\u4F7F\u7528\u3059\u308B DNS \u30B5\u30FC\u30D0\u30FC\u3067\u3059\u3002\u3053\u308C\u3089\u306E DNS \u30B5\u30FC\u30D0\u30FC\u306B\u306F\u3001\u5F8C\u3067\u8FFD\u52A0\u3059\u308B\u30D1\u30D6\u30EA\u30C3\u30AF \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u7D4C\u7531\u3067\u30A2\u30AF\u30BB\u30B9\u3057\u307E\u3059\u3002\u30BE\u30FC\u30F3\u306E\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9\u304B\u3089\u3001\u3053\u3053\u3067\u6307\u5B9A\u3059\u308B\u30D1\u30D6\u30EA\u30C3\u30AF DNS \u30B5\u30FC\u30D0\u30FC\u306B\u901A\u4FE1\u3067\u304D\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.installWizard.tooltip.addZone.dns2=\u30BE\u30FC\u30F3\u5185\u306E\u30B2\u30B9\u30C8 VM \u3067\u4F7F\u7528\u3059\u308B DNS \u30B5\u30FC\u30D0\u30FC\u3067\u3059\u3002\u3053\u308C\u3089\u306E DNS \u30B5\u30FC\u30D0\u30FC\u306B\u306F\u3001\u5F8C\u3067\u8FFD\u52A0\u3059\u308B\u30D1\u30D6\u30EA\u30C3\u30AF \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u7D4C\u7531\u3067\u30A2\u30AF\u30BB\u30B9\u3057\u307E\u3059\u3002\u30BE\u30FC\u30F3\u306E\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9\u304B\u3089\u3001\u3053\u3053\u3067\u6307\u5B9A\u3059\u308B\u30D1\u30D6\u30EA\u30C3\u30AF DNS \u30B5\u30FC\u30D0\u30FC\u306B\u901A\u4FE1\u3067\u304D\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.installWizard.tooltip.addZone.internaldns1=\u30BE\u30FC\u30F3\u5185\u306E\u30B7\u30B9\u30C6\u30E0 VM \u3067\u4F7F\u7528\u3059\u308B DNS \u30B5\u30FC\u30D0\u30FC\u3067\u3059\u3002\u3053\u308C\u3089\u306E DNS \u30B5\u30FC\u30D0\u30FC\u306F\u3001\u30B7\u30B9\u30C6\u30E0 VM \u306E\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30A4\u30F3\u30BF\u30FC\u30D5\u30A7\u30A4\u30B9\u3092\u4ECB\u3057\u3066\u30A2\u30AF\u30BB\u30B9\u3055\u308C\u307E\u3059\u3002\u30DD\u30C3\u30C9\u306E\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 IP \u30A2\u30C9\u30EC\u30B9\u304B\u3089\u3001\u3053\u3053\u3067\u6307\u5B9A\u3059\u308B DNS \u30B5\u30FC\u30D0\u30FC\u306B\u901A\u4FE1\u3067\u304D\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.installWizard.tooltip.addZone.internaldns2=\u30BE\u30FC\u30F3\u5185\u306E\u30B7\u30B9\u30C6\u30E0 VM \u3067\u4F7F\u7528\u3059\u308B DNS \u30B5\u30FC\u30D0\u30FC\u3067\u3059\u3002\u3053\u308C\u3089\u306E DNS \u30B5\u30FC\u30D0\u30FC\u306F\u3001\u30B7\u30B9\u30C6\u30E0 VM \u306E\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30A4\u30F3\u30BF\u30FC\u30D5\u30A7\u30A4\u30B9\u3092\u4ECB\u3057\u3066\u30A2\u30AF\u30BB\u30B9\u3055\u308C\u307E\u3059\u3002\u30DD\u30C3\u30C9\u306E\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 IP \u30A2\u30C9\u30EC\u30B9\u304B\u3089\u3001\u3053\u3053\u3067\u6307\u5B9A\u3059\u308B DNS \u30B5\u30FC\u30D0\u30FC\u306B\u901A\u4FE1\u3067\u304D\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.installWizard.tooltip.addZone.name=\u30BE\u30FC\u30F3\u306E\u540D\u524D\u3067\u3059\u3002 -message.installWizard.tooltip.configureGuestTraffic.description=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u8AAC\u660E\u3067\u3059\u3002 -message.installWizard.tooltip.configureGuestTraffic.guestEndIp=\u3053\u306E\u30BE\u30FC\u30F3\u306E\u30B2\u30B9\u30C8\u306B\u5272\u308A\u5F53\u3066\u308B\u3053\u3068\u304C\u3067\u304D\u308B IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3067\u3059\u3002\u4F7F\u7528\u3059\u308B NIC \u304C 1 \u3064\u306E\u5834\u5408\u306F\u3001\u3053\u308C\u3089\u306E IP \u30A2\u30C9\u30EC\u30B9\u306F\u30DD\u30C3\u30C9\u306E CIDR \u3068\u540C\u3058 CIDR \u306B\u542B\u307E\u308C\u3066\u3044\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.installWizard.tooltip.configureGuestTraffic.guestGateway=\u30B2\u30B9\u30C8\u306E\u4F7F\u7528\u3059\u308B\u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u3067\u3059\u3002 -message.installWizard.tooltip.configureGuestTraffic.guestNetmask=\u30B2\u30B9\u30C8\u306E\u4F7F\u7528\u3059\u308B\u30B5\u30D6\u30CD\u30C3\u30C8\u4E0A\u3067\u4F7F\u7528\u3055\u308C\u308B\u30CD\u30C3\u30C8\u30DE\u30B9\u30AF\u3067\u3059\u3002 -message.installWizard.tooltip.configureGuestTraffic.guestStartIp=\u3053\u306E\u30BE\u30FC\u30F3\u306E\u30B2\u30B9\u30C8\u306B\u5272\u308A\u5F53\u3066\u308B\u3053\u3068\u304C\u3067\u304D\u308B IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3067\u3059\u3002\u4F7F\u7528\u3059\u308B NIC \u304C 1 \u3064\u306E\u5834\u5408\u306F\u3001\u3053\u308C\u3089\u306E IP \u30A2\u30C9\u30EC\u30B9\u306F\u30DD\u30C3\u30C9\u306E CIDR \u3068\u540C\u3058 CIDR \u306B\u542B\u307E\u308C\u3066\u3044\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.installWizard.tooltip.configureGuestTraffic.name=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u540D\u524D\u3067\u3059\u3002 -message.instanceWizard.noTemplates=\u4F7F\u7528\u53EF\u80FD\u306A\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u304C\u3042\u308A\u307E\u305B\u3093\u3002\u4E92\u63DB\u6027\u306E\u3042\u308B\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u8FFD\u52A0\u3057\u3066\u3001\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9 \u30A6\u30A3\u30B6\u30FC\u30C9\u3092\u518D\u8D77\u52D5\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.ip.address.changed=\u304A\u4F7F\u3044\u306E IP \u30A2\u30C9\u30EC\u30B9\u304C\u5909\u66F4\u3055\u308C\u3066\u3044\u308B\u53EF\u80FD\u6027\u304C\u3042\u308A\u307E\u3059\u3002\u4E00\u89A7\u3092\u66F4\u65B0\u3057\u307E\u3059\u304B? \u305D\u306E\u5834\u5408\u306F\u3001\u8A73\u7D30\u30DA\u30A4\u30F3\u304C\u9589\u3058\u308B\u3053\u3068\u306B\u6CE8\u610F\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.iso.desc=\u30C7\u30FC\u30BF\u307E\u305F\u306F OS \u8D77\u52D5\u53EF\u80FD\u30E1\u30C7\u30A3\u30A2\u3092\u542B\u3080\u30C7\u30A3\u30B9\u30AF \u30A4\u30E1\u30FC\u30B8 -message.join.project=\u3053\u308C\u3067\u3001\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306B\u53C2\u52A0\u3057\u307E\u3057\u305F\u3002\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u3092\u53C2\u7167\u3059\u308B\u306B\u306F\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8 \u30D3\u30E5\u30FC\u306B\u5207\u308A\u66FF\u3048\u3066\u304F\u3060\u3055\u3044\u3002 -message.launch.zone=\u30BE\u30FC\u30F3\u3092\u8D77\u52D5\u3059\u308B\u6E96\u5099\u304C\u3067\u304D\u307E\u3057\u305F\u3002\u6B21\u306E\u624B\u9806\u306B\u9032\u3093\u3067\u304F\u3060\u3055\u3044\u3002 -message.lock.account=\u3053\u306E\u30A2\u30AB\u30A6\u30F3\u30C8\u3092\u30ED\u30C3\u30AF\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? \u3053\u306E\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u3059\u3079\u3066\u306E\u30E6\u30FC\u30B6\u30FC\u304C\u30AF\u30E9\u30A6\u30C9 \u30EA\u30BD\u30FC\u30B9\u3092\u7BA1\u7406\u3067\u304D\u306A\u304F\u306A\u308A\u307E\u3059\u3002\u305D\u306E\u5F8C\u3082\u65E2\u5B58\u306E\u30EA\u30BD\u30FC\u30B9\u306B\u306F\u30A2\u30AF\u30BB\u30B9\u3067\u304D\u307E\u3059\u3002 -message.migrate.instance.confirm=\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u79FB\u884C\u5148\u306F\u6B21\u306E\u30DB\u30B9\u30C8\u3067\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.migrate.instance.to.host=\u5225\u306E\u30DB\u30B9\u30C8\u306B\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u79FB\u884C\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.migrate.instance.to.ps=\u5225\u306E\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u306B\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u79FB\u884C\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.migrate.router.confirm=\u30EB\u30FC\u30BF\u30FC\u306E\u79FB\u884C\u5148\u306F\u6B21\u306E\u30DB\u30B9\u30C8\u3067\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.migrate.systemvm.confirm=\u30B7\u30B9\u30C6\u30E0 VM \u306E\u79FB\u884C\u5148\u306F\u6B21\u306E\u30DB\u30B9\u30C8\u3067\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.migrate.volume=\u5225\u306E\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u306B\u30DC\u30EA\u30E5\u30FC\u30E0\u3092\u79FB\u884C\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.new.user=\u00e3\u0082\u00a2\u00e3\u0082\u00ab\u00e3\u0082\u00a6\u00e3\u0083\u00b3\u00e3\u0083\u0088\u00e3\u0081\u00ab\u00e6\u0096\u00b0\u00e3\u0081\u0097\u00e3\u0081\u0084\u00e3\u0083\u00a6\u00e3\u0083\u00bc\u00e3\u0082\u00b6\u00e3\u0083\u00bc\u00e3\u0082\u0092\u00e8\u00bf\u00bd\u00e5\u008a\u00a0\u00e3\u0081\u0099\u00e3\u0082\u008b\u00e3\u0081\u009f\u00e3\u0082\u0081\u00e3\u0081\u00ab\u00e3\u0080\u0081\u00e6\u00ac\u00a1\u00e3\u0081\u00ae\u00e6\u0083\u0085\u00e5\u00a0\u00b1\u00e3\u0082\u0092\u00e8\u00a8\u00ad\u00e5\u00ae\u009a\u00e3\u0081\u0097\u00e3\u0081\u00a6\u00e3\u0081\u008f\u00e3\u0081\u00a0\u00e3\u0081\u0095\u00e3\u0081\u0084 -message.no.network.support.configuration.not.true=\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u304C\u6709\u52B9\u306A\u30BE\u30FC\u30F3\u304C\u7121\u3044\u305F\u3081\u3001\u8FFD\u52A0\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u6A5F\u80FD\u306F\u3042\u308A\u307E\u305B\u3093\u3002\u624B\u9806 5. \u306B\u9032\u3093\u3067\u304F\u3060\u3055\u3044\u3002 -message.no.network.support=\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u3068\u3057\u3066 vSphere \u3092\u9078\u629E\u3057\u307E\u3057\u305F\u304C\u3001\u3053\u306E\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u306B\u8FFD\u52A0\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u6A5F\u80FD\u306F\u3042\u308A\u307E\u305B\u3093\u3002\u624B\u9806 5. \u306B\u9032\u3093\u3067\u304F\u3060\u3055\u3044\u3002 -message.no.projects.adminOnly=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u304C\u3042\u308A\u307E\u305B\u3093\u3002
\u7BA1\u7406\u8005\u306B\u65B0\u3057\u3044\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306E\u4F5C\u6210\u3092\u4F9D\u983C\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.no.projects=\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u304C\u3042\u308A\u307E\u305B\u3093\u3002
\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8 \u30BB\u30AF\u30B7\u30E7\u30F3\u304B\u3089\u65B0\u3057\u3044\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u3092\u4F5C\u6210\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.number.clusters=

\u30AF\u30E9\u30B9\u30BF\u30FC\u6570

-message.number.hosts=

\u30DB\u30B9\u30C8\u6570

-message.number.pods=

\u30DD\u30C3\u30C9\u6570

-message.number.storage=

\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8 \u30DC\u30EA\u30E5\u30FC\u30E0\u6570

-message.number.zones=

\u30BE\u30FC\u30F3\u6570

-message.pending.projects.1=\u4FDD\u7559\u4E2D\u306E\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u62DB\u5F85\u72B6\u304C\u3042\u308A\u307E\u3059\u3002 -message.pending.projects.2=\u8868\u793A\u3059\u308B\u306B\u306F\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8 \u30BB\u30AF\u30B7\u30E7\u30F3\u306B\u79FB\u52D5\u3057\u3066\u3001\u4E00\u89A7\u304B\u3089\u62DB\u5F85\u72B6\u3092\u9078\u629E\u3057\u307E\u3059\u3002 -message.please.add.at.lease.one.traffic.range=\u5C11\u306A\u304F\u3068\u3082 1 \u3064\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u7BC4\u56F2\u3092\u8FFD\u52A0\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.please.proceed=\u6B21\u306E\u624B\u9806\u306B\u9032\u3093\u3067\u304F\u3060\u3055\u3044\u3002 -message.please.select.a.configuration.for.your.zone=\u30BE\u30FC\u30F3\u306E\u69CB\u6210\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.please.select.a.different.public.and.management.network.before.removing=\u524A\u9664\u306E\u524D\u306B\u7570\u306A\u308B\u30D1\u30D6\u30EA\u30C3\u30AF\u304A\u3088\u3073\u7BA1\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.please.select.networks=\u4EEE\u60F3\u30DE\u30B7\u30F3\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.please.wait.while.zone.is.being.created=\u30BE\u30FC\u30F3\u304C\u4F5C\u6210\u3055\u308C\u308B\u307E\u3067\u3057\u3070\u3089\u304F\u304A\u5F85\u3061\u304F\u3060\u3055\u3044... -message.project.invite.sent=\u30E6\u30FC\u30B6\u30FC\u306B\u62DB\u5F85\u72B6\u304C\u9001\u4FE1\u3055\u308C\u307E\u3057\u305F\u3002\u30E6\u30FC\u30B6\u30FC\u304C\u62DB\u5F85\u3092\u627F\u8AFE\u3059\u308B\u3068\u3001\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u306B\u8FFD\u52A0\u3055\u308C\u307E\u3059\u3002 -message.public.traffic.in.advanced.zone=\u30AF\u30E9\u30A6\u30C9\u5185\u306E VM \u304C\u30A4\u30F3\u30BF\u30FC\u30CD\u30C3\u30C8\u306B\u30A2\u30AF\u30BB\u30B9\u3059\u308B\u3068\u3001\u30D1\u30D6\u30EA\u30C3\u30AF \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u304C\u751F\u6210\u3055\u308C\u307E\u3059\u3002\u3053\u306E\u305F\u3081\u306B\u3001\u4E00\u822C\u306B\u30A2\u30AF\u30BB\u30B9\u53EF\u80FD\u306A IP \u30A2\u30C9\u30EC\u30B9\u3092\u5272\u308A\u5F53\u3066\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002\u30A8\u30F3\u30C9 \u30E6\u30FC\u30B6\u30FC\u306F CloudStack \u306E\u30E6\u30FC\u30B6\u30FC \u30A4\u30F3\u30BF\u30FC\u30D5\u30A7\u30A4\u30B9\u3092\u4F7F\u7528\u3057\u3066\u3053\u308C\u3089\u306E IP \u30A2\u30C9\u30EC\u30B9\u3092\u53D6\u5F97\u3057\u3001\u30B2\u30B9\u30C8 \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3068\u30D1\u30D6\u30EA\u30C3\u30AF \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u9593\u306B NAT \u3092\u5B9F\u88C5\u3059\u308B\u3053\u3068\u304C\u3067\u304D\u307E\u3059\u3002

\u30A4\u30F3\u30BF\u30FC\u30CD\u30C3\u30C8 \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u305F\u3081\u306B\u3001\u5C11\u306A\u304F\u3068\u3082 1 \u3064 IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.public.traffic.in.basic.zone=\u30AF\u30E9\u30A6\u30C9\u5185\u306E VM \u304C\u30A4\u30F3\u30BF\u30FC\u30CD\u30C3\u30C8\u306B\u30A2\u30AF\u30BB\u30B9\u3059\u308B\u304B\u30A4\u30F3\u30BF\u30FC\u30CD\u30C3\u30C8\u7D4C\u7531\u3067\u30AF\u30E9\u30A4\u30A2\u30F3\u30C8\u306B\u30B5\u30FC\u30D3\u30B9\u3092\u63D0\u4F9B\u3059\u308B\u3068\u3001\u30D1\u30D6\u30EA\u30C3\u30AF \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u304C\u751F\u6210\u3055\u308C\u307E\u3059\u3002\u3053\u306E\u305F\u3081\u306B\u3001\u4E00\u822C\u306B\u30A2\u30AF\u30BB\u30B9\u53EF\u80FD\u306A IP \u30A2\u30C9\u30EC\u30B9\u3092\u5272\u308A\u5F53\u3066\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u4F5C\u6210\u3059\u308B\u3068\u3001\u30B2\u30B9\u30C8 IP \u30A2\u30C9\u30EC\u30B9\u306E\u307B\u304B\u306B\u3053\u306E\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9\u306E\u7BC4\u56F2\u304B\u3089\u30A2\u30C9\u30EC\u30B9\u304C 1 \u3064\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306B\u5272\u308A\u5F53\u3066\u3089\u308C\u307E\u3059\u3002\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9\u3068\u30B2\u30B9\u30C8 IP \u30A2\u30C9\u30EC\u30B9\u306E\u9593\u306B\u3001\u9759\u7684\u306A 1 \u5BFE 1 \u306E NAT \u304C\u81EA\u52D5\u7684\u306B\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u3055\u308C\u307E\u3059\u3002\u30A8\u30F3\u30C9 \u30E6\u30FC\u30B6\u30FC\u306F CloudStack \u306E\u30E6\u30FC\u30B6\u30FC \u30A4\u30F3\u30BF\u30FC\u30D5\u30A7\u30A4\u30B9\u3092\u4F7F\u7528\u3057\u3066\u8FFD\u52A0\u306E IP \u30A2\u30C9\u30EC\u30B9\u3092\u53D6\u5F97\u3057\u3001\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3068\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9\u306E\u9593\u306B\u9759\u7684 NAT \u3092\u5B9F\u88C5\u3059\u308B\u3053\u3068\u3082\u3067\u304D\u307E\u3059\u3002 -message.remove.vpc=VPC \u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.remove.vpn.access=\u6B21\u306E\u30E6\u30FC\u30B6\u30FC\u304B\u3089 VPN \u30A2\u30AF\u30BB\u30B9\u3092\u524A\u9664\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.reset.password.warning.notPasswordEnabled=\u3053\u306E\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306F\u3001\u30D1\u30B9\u30EF\u30FC\u30C9\u7BA1\u7406\u3092\u6709\u52B9\u306B\u305B\u305A\u306B\u4F5C\u6210\u3055\u308C\u307E\u3057\u305F\u3002 -message.reset.password.warning.notStopped=\u73FE\u5728\u306E\u30D1\u30B9\u30EF\u30FC\u30C9\u3092\u5909\u66F4\u3059\u308B\u524D\u306B\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u505C\u6B62\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.reset.VPN.connection=VPN \u63A5\u7D9A\u3092\u30EA\u30BB\u30C3\u30C8\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.restart.mgmt.server=\u65B0\u3057\u3044\u8A2D\u5B9A\u3092\u6709\u52B9\u306B\u3059\u308B\u305F\u3081\u306B\u3001\u7BA1\u7406\u30B5\u30FC\u30D0\u30FC\u3092\u518D\u8D77\u52D5\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.restart.mgmt.usage.server=\u65B0\u3057\u3044\u8A2D\u5B9A\u3092\u6709\u52B9\u306B\u3059\u308B\u305F\u3081\u306B\u3001\u7BA1\u7406\u30B5\u30FC\u30D0\u30FC\u3068\u4F7F\u7528\u72B6\u6CC1\u6E2C\u5B9A\u30B5\u30FC\u30D0\u30FC\u3092\u518D\u8D77\u52D5\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.restart.network=\u3053\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3067\u63D0\u4F9B\u3059\u308B\u3059\u3079\u3066\u306E\u30B5\u30FC\u30D3\u30B9\u304C\u4E2D\u65AD\u3055\u308C\u307E\u3059\u3002\u3053\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u518D\u8D77\u52D5\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.restart.vpc=VPC \u3092\u518D\u8D77\u52D5\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.security.group.usage=(\u8A72\u5F53\u3059\u308B\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u3092\u3059\u3079\u3066\u9078\u629E\u3059\u308B\u306B\u306F\u3001Ctrl \u30AD\u30FC\u3092\u62BC\u3057\u306A\u304C\u3089\u30AF\u30EA\u30C3\u30AF\u3057\u3066\u304F\u3060\u3055\u3044) -message.select.a.zone=\u30BE\u30FC\u30F3\u306F\u901A\u5E38\u3001\u5358\u4E00\u306E\u30C7\u30FC\u30BF\u30BB\u30F3\u30BF\u30FC\u306B\u76F8\u5F53\u3057\u307E\u3059\u3002\u8907\u6570\u306E\u30BE\u30FC\u30F3\u3092\u8A2D\u5B9A\u3057\u3001\u7269\u7406\u7684\u306B\u5206\u96E2\u3057\u3066\u5197\u9577\u6027\u3092\u6301\u305F\u305B\u308B\u3053\u3068\u306B\u3088\u308A\u3001\u30AF\u30E9\u30A6\u30C9\u306E\u4FE1\u983C\u6027\u3092\u9AD8\u3081\u307E\u3059\u3002 -message.select.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.select.iso=\u65B0\u3057\u3044\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E ISO \u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.select.item=\u9805\u76EE\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.select.security.groups=\u65B0\u3057\u3044\u4EEE\u60F3\u30DE\u30B7\u30F3\u306E\u30BB\u30AD\u30E5\u30EA\u30C6\u30A3 \u30B0\u30EB\u30FC\u30D7\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.select.template=\u65B0\u3057\u3044\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.setup.physical.network.during.zone.creation.basic=\u57FA\u672C\u30BE\u30FC\u30F3\u3092\u8FFD\u52A0\u3059\u308B\u3068\u304D\u306F\u3001\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u4E0A\u306E NIC \u306B\u5BFE\u5FDC\u3059\u308B 1 \u3064\u306E\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u3067\u304D\u307E\u3059\u3002\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306F\u3044\u304F\u3064\u304B\u306E\u7A2E\u985E\u306E\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u3092\u4F1D\u9001\u3057\u307E\u3059\u3002

\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306B\u307B\u304B\u306E\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u7A2E\u985E\u3092\u30C9\u30E9\u30C3\u30B0 \u30A2\u30F3\u30C9 \u30C9\u30ED\u30C3\u30D7\u3059\u308B\u3053\u3068\u3082\u3067\u304D\u307E\u3059\u3002 -message.setup.physical.network.during.zone.creation=\u62E1\u5F35\u30BE\u30FC\u30F3\u3092\u8FFD\u52A0\u3059\u308B\u3068\u304D\u306F\u30011 \u3064\u4EE5\u4E0A\u306E\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002\u5404\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306F\u30CF\u30A4\u30D1\u30FC\u30D0\u30A4\u30B6\u30FC\u4E0A\u306E 1 \u3064\u306E NIC \u306B\u5BFE\u5FDC\u3057\u307E\u3059\u3002\u5404\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3067\u306F\u3001\u7D44\u307F\u5408\u308F\u305B\u306B\u5236\u9650\u304C\u3042\u308A\u307E\u3059\u304C\u30011 \u3064\u4EE5\u4E0A\u306E\u7A2E\u985E\u306E\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u3092\u901A\u4FE1\u3067\u304D\u307E\u3059\u3002

\u5404\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306B\u5BFE\u3057\u3066\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u306E\u7A2E\u985E\u3092\u30C9\u30E9\u30C3\u30B0 \u30A2\u30F3\u30C9 \u30C9\u30ED\u30C3\u30D7\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.setup.successful=\u30AF\u30E9\u30A6\u30C9\u304C\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u3055\u308C\u307E\u3057\u305F\u3002 -message.snapshot.schedule=\u6B21\u306E\u30AA\u30D7\u30B7\u30E7\u30F3\u304B\u3089\u9078\u629E\u3057\u3066\u30DD\u30EA\u30B7\u30FC\u306E\u57FA\u672C\u8A2D\u5B9A\u3092\u9069\u7528\u3059\u308B\u3053\u3068\u306B\u3088\u308A\u3001\u5B9A\u671F\u30B9\u30CA\u30C3\u30D7\u30B7\u30E7\u30C3\u30C8\u306E\u30B9\u30B1\u30B8\u30E5\u30FC\u30EB\u3092\u30BB\u30C3\u30C8\u30A2\u30C3\u30D7\u3067\u304D\u307E\u3059\u3002 -message.specify.url=URL \u3092\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044 -message.step.1.continue=\u7D9A\u884C\u3059\u308B\u306B\u306F\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u307E\u305F\u306F ISO \u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044 -message.step.1.desc=\u65B0\u3057\u3044\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u7528\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002ISO \u3092\u30A4\u30F3\u30B9\u30C8\u30FC\u30EB\u3067\u304D\u308B\u7A7A\u767D\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u9078\u629E\u3059\u308B\u3053\u3068\u3082\u3067\u304D\u307E\u3059\u3002 -message.step.2.continue=\u7D9A\u884C\u3059\u308B\u306B\u306F\u30B5\u30FC\u30D3\u30B9 \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044 +message.download.volume.confirm=\u3053\u306e\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.download.volume=\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3059\u308b\u306b\u306f 00000 \u3092\u30af\u30ea\u30c3\u30af\u3057\u307e\u3059 +message.edit.account=\u7de8\u96c6 ("-1" \u306f\u3001\u30ea\u30bd\u30fc\u30b9\u4f5c\u6210\u306e\u91cf\u306b\u5236\u9650\u304c\u306a\u3044\u3053\u3068\u3092\u793a\u3057\u307e\u3059) +message.edit.confirm=[\u4fdd\u5b58] \u3092\u30af\u30ea\u30c3\u30af\u3059\u308b\u524d\u306b\u5909\u66f4\u5185\u5bb9\u3092\u78ba\u8a8d\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.edit.limits=\u6b21\u306e\u30ea\u30bd\u30fc\u30b9\u306b\u5236\u9650\u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u300c-1\u300d\u306f\u3001\u30ea\u30bd\u30fc\u30b9\u4f5c\u6210\u306b\u5236\u9650\u304c\u306a\u3044\u3053\u3068\u3092\u793a\u3057\u307e\u3059\u3002 +message.edit.traffic.type=\u3053\u306e\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u7a2e\u985e\u306b\u95a2\u9023\u4ed8\u3051\u308b\u30c8\u30e9\u30d5\u30a3\u30c3\u30af \u30e9\u30d9\u30eb\u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.enable.account=\u3053\u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u6709\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.enabled.vpn.ip.sec=IPSec \u4e8b\u524d\u5171\u6709\u30ad\u30fc\: +message.enabled.vpn=\u73fe\u5728\u3001VPN \u30a2\u30af\u30bb\u30b9\u304c\u6709\u52b9\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002\u6b21\u306e IP \u30a2\u30c9\u30ec\u30b9\u7d4c\u7531\u3067\u30a2\u30af\u30bb\u30b9\u3067\u304d\u307e\u3059\u3002 +message.enable.user=\u3053\u306e\u30e6\u30fc\u30b6\u30fc\u3092\u6709\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.enable.vpn.access=\u73fe\u5728\u3053\u306e IP \u30a2\u30c9\u30ec\u30b9\u306b\u5bfe\u3059\u308b VPN \u306f\u7121\u52b9\u3067\u3059\u3002VPN \u30a2\u30af\u30bb\u30b9\u3092\u6709\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.enable.vpn=\u3053\u306e IP \u30a2\u30c9\u30ec\u30b9\u306b\u5bfe\u3059\u308b VPN \u30a2\u30af\u30bb\u30b9\u3092\u6709\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.enabling.security.group.provider=\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7 \u30d7\u30ed\u30d0\u30a4\u30c0\u30fc\u3092\u6709\u52b9\u306b\u3057\u3066\u3044\u307e\u3059 +message.enabling.zone=\u30be\u30fc\u30f3\u3092\u6709\u52b9\u306b\u3057\u3066\u3044\u307e\u3059 +message.enter.token=\u96fb\u5b50\u30e1\u30fc\u30eb\u306e\u62db\u5f85\u72b6\u306b\u8a18\u8f09\u3055\u308c\u3066\u3044\u308b\u30c8\u30fc\u30af\u30f3\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.generate.keys=\u3053\u306e\u30e6\u30fc\u30b6\u30fc\u306b\u65b0\u3057\u3044\u30ad\u30fc\u3092\u751f\u6210\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.guest.traffic.in.advanced.zone=\u30b2\u30b9\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306f\u3001\u30a8\u30f3\u30c9 \u30e6\u30fc\u30b6\u30fc\u306e\u4eee\u60f3\u30de\u30b7\u30f3\u9593\u306e\u901a\u4fe1\u3067\u3059\u3002\u5404\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u30b2\u30b9\u30c8 \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u3092\u901a\u4fe1\u3059\u308b\u305f\u3081\u306e VLAN ID \u306e\u7bc4\u56f2\u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.guest.traffic.in.basic.zone=\u30b2\u30b9\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306f\u3001\u30a8\u30f3\u30c9 \u30e6\u30fc\u30b6\u30fc\u306e\u4eee\u60f3\u30de\u30b7\u30f3\u9593\u306e\u901a\u4fe1\u3067\u3059\u3002CloudStack \u3067\u30b2\u30b9\u30c8 VM \u306b\u5272\u308a\u5f53\u3066\u3089\u308c\u308b IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u3053\u306e\u7bc4\u56f2\u304c\u4e88\u7d04\u6e08\u307f\u306e\u30b7\u30b9\u30c6\u30e0 IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3068\u91cd\u8907\u3057\u306a\u3044\u3088\u3046\u306b\u6ce8\u610f\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.installWizard.click.retry=\u8d77\u52d5\u3092\u518d\u8a66\u884c\u3059\u308b\u306b\u306f\u30dc\u30bf\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.installWizard.copy.whatIsAPod=\u901a\u5e38\u30011 \u3064\u306e\u30dd\u30c3\u30c9\u306f\u5358\u4e00\u306e\u30e9\u30c3\u30af\u3092\u8868\u3057\u307e\u3059\u3002\u540c\u3058\u30dd\u30c3\u30c9\u5185\u306e\u30db\u30b9\u30c8\u306f\u540c\u3058\u30b5\u30d6\u30cd\u30c3\u30c8\u306b\u542b\u307e\u308c\u307e\u3059\u3002

\u30dd\u30c3\u30c9\u306f CloudStack&\#8482; \u74b0\u5883\u5185\u306e 2 \u756a\u76ee\u306b\u5927\u304d\u306a\u7d44\u7e54\u5358\u4f4d\u3067\u3059\u3002\u30dd\u30c3\u30c9\u306f\u30be\u30fc\u30f3\u306b\u542b\u307e\u308c\u307e\u3059\u3002\u5404\u30be\u30fc\u30f3\u306f 1 \u3064\u4ee5\u4e0a\u306e\u30dd\u30c3\u30c9\u3092\u542b\u3080\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u57fa\u672c\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3067\u306f\u3001\u30be\u30fc\u30f3\u5185\u306e\u30dd\u30c3\u30c9\u306f 1 \u3064\u3067\u3059\u3002 +message.installWizard.copy.whatIsAZone=\u30be\u30fc\u30f3\u306f CloudStack&\#8482; \u74b0\u5883\u5185\u306e\u6700\u5927\u306e\u7d44\u7e54\u5358\u4f4d\u3067\u3059\u30021 \u3064\u306e\u30c7\u30fc\u30bf\u30bb\u30f3\u30bf\u30fc\u5185\u306b\u8907\u6570\u306e\u30be\u30fc\u30f3\u3092\u8a2d\u5b9a\u3067\u304d\u307e\u3059\u304c\u3001\u901a\u5e38\u3001\u30be\u30fc\u30f3\u306f\u5358\u4e00\u306e\u30c7\u30fc\u30bf\u30bb\u30f3\u30bf\u30fc\u306b\u76f8\u5f53\u3057\u307e\u3059\u3002\u30a4\u30f3\u30d5\u30e9\u30b9\u30c8\u30e9\u30af\u30c1\u30e3\u3092\u30be\u30fc\u30f3\u306b\u7d44\u7e54\u5316\u3059\u308b\u3068\u3001\u30be\u30fc\u30f3\u3092\u7269\u7406\u7684\u306b\u5206\u96e2\u3057\u3066\u5197\u9577\u5316\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u305f\u3068\u3048\u3070\u3001\u5404\u30be\u30fc\u30f3\u306b\u96fb\u6e90\u3068\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30a2\u30c3\u30d7\u30ea\u30f3\u30af\u3092\u914d\u5099\u3057\u307e\u3059\u3002\u5fc5\u9808\u3067\u306f\u3042\u308a\u307e\u305b\u3093\u304c\u3001\u30be\u30fc\u30f3\u306f\u9060\u9694\u5730\u306b\u5206\u6563\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002 +message.installWizard.copy.whatIsSecondaryStorage=\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u306f\u30be\u30fc\u30f3\u3068\u95a2\u9023\u4ed8\u3051\u3089\u308c\u3001\u6b21\u306e\u9805\u76ee\u3092\u683c\u7d0d\u3057\u307e\u3059\u3002
  • \u30c6\u30f3\u30d7\u30ec\u30fc\u30c8 - VM \u306e\u8d77\u52d5\u306b\u4f7f\u7528\u3067\u304d\u308b OS \u30a4\u30e1\u30fc\u30b8\u3067\u3001\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u306a\u3069\u8ffd\u52a0\u306e\u69cb\u6210\u3092\u542b\u3081\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002
  • ISO \u30a4\u30e1\u30fc\u30b8 - \u8d77\u52d5\u53ef\u80fd\u307e\u305f\u306f\u8d77\u52d5\u4e0d\u53ef\u306e OS \u30a4\u30e1\u30fc\u30b8\u3067\u3059\u3002
  • \u30c7\u30a3\u30b9\u30af \u30dc\u30ea\u30e5\u30fc\u30e0\u306e\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8 - VM \u30c7\u30fc\u30bf\u306e\u4fdd\u5b58\u30b3\u30d4\u30fc\u3067\u3059\u3002\u30c7\u30fc\u30bf\u306e\u5fa9\u5143\u307e\u305f\u306f\u65b0\u3057\u3044\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u4f5c\u6210\u306b\u4f7f\u7528\u3067\u304d\u307e\u3059\u3002
+message.installWizard.tooltip.addCluster.name=\u30af\u30e9\u30b9\u30bf\u30fc\u306e\u540d\u524d\u3067\u3059\u3002CloudStack \u3067\u4f7f\u7528\u3055\u308c\u3066\u3044\u306a\u3044\u3001\u4efb\u610f\u306e\u30c6\u30ad\u30b9\u30c8\u3092\u6307\u5b9a\u3067\u304d\u307e\u3059\u3002 +message.installWizard.tooltip.addHost.hostname=\u30db\u30b9\u30c8\u306e DNS \u540d\u307e\u305f\u306f IP \u30a2\u30c9\u30ec\u30b9\u3067\u3059\u3002 +message.installWizard.tooltip.addHost.password=XenServer \u5074\u3067\u6307\u5b9a\u3057\u305f\u3001\u4e0a\u306e\u30e6\u30fc\u30b6\u30fc\u540d\u306b\u5bfe\u3059\u308b\u30d1\u30b9\u30ef\u30fc\u30c9\u3067\u3059\u3002 +message.installWizard.tooltip.addHost.username=\u901a\u5e38\u306f root \u3067\u3059\u3002 +message.installWizard.tooltip.addPod.name=\u30dd\u30c3\u30c9\u306e\u540d\u524d\u3067\u3059\u3002 +message.installWizard.tooltip.addPod.reservedSystemEndIp=\u3053\u308c\u306f\u3001\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 VM \u304a\u3088\u3073\u30b3\u30f3\u30bd\u30fc\u30eb \u30d7\u30ed\u30ad\u30b7 VM \u3092\u7ba1\u7406\u3059\u308b\u305f\u3081\u306b CloudStack \u3067\u4f7f\u7528\u3059\u308b\u3001\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u5185\u306e IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3067\u3059\u3002\u3053\u308c\u3089\u306e IP \u30a2\u30c9\u30ec\u30b9\u306f\u30b3\u30f3\u30d4\u30e5\u30fc\u30c6\u30a3\u30f3\u30b0 \u30b5\u30fc\u30d0\u30fc\u3068\u540c\u3058\u30b5\u30d6\u30cd\u30c3\u30c8\u304b\u3089\u5272\u308a\u5f53\u3066\u307e\u3059\u3002 +message.installWizard.tooltip.addPod.reservedSystemGateway=\u3053\u306e\u30dd\u30c3\u30c9\u5185\u306e\u30db\u30b9\u30c8\u306e\u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u3067\u3059\u3002 +message.installWizard.tooltip.addPod.reservedSystemNetmask=\u30b2\u30b9\u30c8\u306e\u4f7f\u7528\u3059\u308b\u30b5\u30d6\u30cd\u30c3\u30c8\u4e0a\u3067\u4f7f\u7528\u3055\u308c\u308b\u30cd\u30c3\u30c8\u30de\u30b9\u30af\u3067\u3059\u3002 +message.installWizard.tooltip.addPod.reservedSystemStartIp=\u3053\u308c\u306f\u3001\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 VM \u304a\u3088\u3073\u30b3\u30f3\u30bd\u30fc\u30eb \u30d7\u30ed\u30ad\u30b7 VM \u3092\u7ba1\u7406\u3059\u308b\u305f\u3081\u306b CloudStack \u3067\u4f7f\u7528\u3059\u308b\u3001\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u5185\u306e IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3067\u3059\u3002\u3053\u308c\u3089\u306e IP \u30a2\u30c9\u30ec\u30b9\u306f\u30b3\u30f3\u30d4\u30e5\u30fc\u30c6\u30a3\u30f3\u30b0 \u30b5\u30fc\u30d0\u30fc\u3068\u540c\u3058\u30b5\u30d6\u30cd\u30c3\u30c8\u304b\u3089\u5272\u308a\u5f53\u3066\u307e\u3059\u3002 +message.installWizard.tooltip.addPrimaryStorage.name=\u30b9\u30c8\u30ec\u30fc\u30b8 \u30c7\u30d0\u30a4\u30b9\u306e\u540d\u524d\u3067\u3059\u3002 +message.installWizard.tooltip.addPrimaryStorage.path=(NFS \u306e\u5834\u5408) \u30b5\u30fc\u30d0\u30fc\u304b\u3089\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3055\u308c\u305f\u30d1\u30b9\u3067\u3059\u3002(SharedMountPoint \u306e\u5834\u5408) \u30d1\u30b9\u3067\u3059\u3002KVM \u3067\u306f\u3053\u306e\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u304c\u30de\u30a6\u30f3\u30c8\u3055\u308c\u308b\u5404\u30db\u30b9\u30c8\u4e0a\u306e\u30d1\u30b9\u3067\u3059\u3002\u305f\u3068\u3048\u3070\u3001/mnt/primary \u3067\u3059\u3002 +message.installWizard.tooltip.addPrimaryStorage.server=(NFS\u3001iSCSI\u3001\u307e\u305f\u306f PreSetup \u306e\u5834\u5408) \u30b9\u30c8\u30ec\u30fc\u30b8 \u30c7\u30d0\u30a4\u30b9\u306e IP \u30a2\u30c9\u30ec\u30b9\u307e\u305f\u306f DNS \u540d\u3067\u3059\u3002 +message.installWizard.tooltip.addSecondaryStorage.nfsServer=\u30bb\u30ab\u30f3\u30c0\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u30db\u30b9\u30c8\u3059\u308b NFS \u30b5\u30fc\u30d0\u30fc\u306e IP \u30a2\u30c9\u30ec\u30b9\u3067\u3059\u3002 +message.installWizard.tooltip.addSecondaryStorage.path=\u4e0a\u306b\u6307\u5b9a\u3057\u305f\u30b5\u30fc\u30d0\u30fc\u306b\u5b58\u5728\u3059\u308b\u3001\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3055\u308c\u305f\u30d1\u30b9\u3067\u3059\u3002 +message.installWizard.tooltip.addZone.dns1=\u30be\u30fc\u30f3\u5185\u306e\u30b2\u30b9\u30c8 VM \u3067\u4f7f\u7528\u3059\u308b DNS \u30b5\u30fc\u30d0\u30fc\u3067\u3059\u3002\u3053\u308c\u3089\u306e DNS \u30b5\u30fc\u30d0\u30fc\u306b\u306f\u3001\u5f8c\u3067\u8ffd\u52a0\u3059\u308b\u30d1\u30d6\u30ea\u30c3\u30af \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u7d4c\u7531\u3067\u30a2\u30af\u30bb\u30b9\u3057\u307e\u3059\u3002\u30be\u30fc\u30f3\u306e\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9\u304b\u3089\u3001\u3053\u3053\u3067\u6307\u5b9a\u3059\u308b\u30d1\u30d6\u30ea\u30c3\u30af DNS \u30b5\u30fc\u30d0\u30fc\u306b\u901a\u4fe1\u3067\u304d\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.installWizard.tooltip.addZone.dns2=\u30be\u30fc\u30f3\u5185\u306e\u30b2\u30b9\u30c8 VM \u3067\u4f7f\u7528\u3059\u308b DNS \u30b5\u30fc\u30d0\u30fc\u3067\u3059\u3002\u3053\u308c\u3089\u306e DNS \u30b5\u30fc\u30d0\u30fc\u306b\u306f\u3001\u5f8c\u3067\u8ffd\u52a0\u3059\u308b\u30d1\u30d6\u30ea\u30c3\u30af \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u7d4c\u7531\u3067\u30a2\u30af\u30bb\u30b9\u3057\u307e\u3059\u3002\u30be\u30fc\u30f3\u306e\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9\u304b\u3089\u3001\u3053\u3053\u3067\u6307\u5b9a\u3059\u308b\u30d1\u30d6\u30ea\u30c3\u30af DNS \u30b5\u30fc\u30d0\u30fc\u306b\u901a\u4fe1\u3067\u304d\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.installWizard.tooltip.addZone.internaldns1=\u30be\u30fc\u30f3\u5185\u306e\u30b7\u30b9\u30c6\u30e0 VM \u3067\u4f7f\u7528\u3059\u308b DNS \u30b5\u30fc\u30d0\u30fc\u3067\u3059\u3002\u3053\u308c\u3089\u306e DNS \u30b5\u30fc\u30d0\u30fc\u306f\u3001\u30b7\u30b9\u30c6\u30e0 VM \u306e\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9\u3092\u4ecb\u3057\u3066\u30a2\u30af\u30bb\u30b9\u3055\u308c\u307e\u3059\u3002\u30dd\u30c3\u30c9\u306e\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 IP \u30a2\u30c9\u30ec\u30b9\u304b\u3089\u3001\u3053\u3053\u3067\u6307\u5b9a\u3059\u308b DNS \u30b5\u30fc\u30d0\u30fc\u306b\u901a\u4fe1\u3067\u304d\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.installWizard.tooltip.addZone.internaldns2=\u30be\u30fc\u30f3\u5185\u306e\u30b7\u30b9\u30c6\u30e0 VM \u3067\u4f7f\u7528\u3059\u308b DNS \u30b5\u30fc\u30d0\u30fc\u3067\u3059\u3002\u3053\u308c\u3089\u306e DNS \u30b5\u30fc\u30d0\u30fc\u306f\u3001\u30b7\u30b9\u30c6\u30e0 VM \u306e\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9\u3092\u4ecb\u3057\u3066\u30a2\u30af\u30bb\u30b9\u3055\u308c\u307e\u3059\u3002\u30dd\u30c3\u30c9\u306e\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 IP \u30a2\u30c9\u30ec\u30b9\u304b\u3089\u3001\u3053\u3053\u3067\u6307\u5b9a\u3059\u308b DNS \u30b5\u30fc\u30d0\u30fc\u306b\u901a\u4fe1\u3067\u304d\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.installWizard.tooltip.addZone.name=\u30be\u30fc\u30f3\u306e\u540d\u524d\u3067\u3059\u3002 +message.installWizard.tooltip.configureGuestTraffic.description=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u8aac\u660e\u3067\u3059\u3002 +message.installWizard.tooltip.configureGuestTraffic.guestEndIp=\u3053\u306e\u30be\u30fc\u30f3\u306e\u30b2\u30b9\u30c8\u306b\u5272\u308a\u5f53\u3066\u308b\u3053\u3068\u304c\u3067\u304d\u308b IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3067\u3059\u3002\u4f7f\u7528\u3059\u308b NIC \u304c 1 \u3064\u306e\u5834\u5408\u306f\u3001\u3053\u308c\u3089\u306e IP \u30a2\u30c9\u30ec\u30b9\u306f\u30dd\u30c3\u30c9\u306e CIDR \u3068\u540c\u3058 CIDR \u306b\u542b\u307e\u308c\u3066\u3044\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.installWizard.tooltip.configureGuestTraffic.guestGateway=\u30b2\u30b9\u30c8\u306e\u4f7f\u7528\u3059\u308b\u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u3067\u3059\u3002 +message.installWizard.tooltip.configureGuestTraffic.guestNetmask=\u30b2\u30b9\u30c8\u306e\u4f7f\u7528\u3059\u308b\u30b5\u30d6\u30cd\u30c3\u30c8\u4e0a\u3067\u4f7f\u7528\u3055\u308c\u308b\u30cd\u30c3\u30c8\u30de\u30b9\u30af\u3067\u3059\u3002 +message.installWizard.tooltip.configureGuestTraffic.guestStartIp=\u3053\u306e\u30be\u30fc\u30f3\u306e\u30b2\u30b9\u30c8\u306b\u5272\u308a\u5f53\u3066\u308b\u3053\u3068\u304c\u3067\u304d\u308b IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3067\u3059\u3002\u4f7f\u7528\u3059\u308b NIC \u304c 1 \u3064\u306e\u5834\u5408\u306f\u3001\u3053\u308c\u3089\u306e IP \u30a2\u30c9\u30ec\u30b9\u306f\u30dd\u30c3\u30c9\u306e CIDR \u3068\u540c\u3058 CIDR \u306b\u542b\u307e\u308c\u3066\u3044\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.installWizard.tooltip.configureGuestTraffic.name=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u540d\u524d\u3067\u3059\u3002 +message.instanceWizard.noTemplates=\u4f7f\u7528\u53ef\u80fd\u306a\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u304c\u3042\u308a\u307e\u305b\u3093\u3002\u4e92\u63db\u6027\u306e\u3042\u308b\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u8ffd\u52a0\u3057\u3066\u3001\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9 \u30a6\u30a3\u30b6\u30fc\u30c9\u3092\u518d\u8d77\u52d5\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.ip.address.changed=\u304a\u4f7f\u3044\u306e IP \u30a2\u30c9\u30ec\u30b9\u304c\u5909\u66f4\u3055\u308c\u3066\u3044\u308b\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002\u4e00\u89a7\u3092\u66f4\u65b0\u3057\u307e\u3059\u304b? \u305d\u306e\u5834\u5408\u306f\u3001\u8a73\u7d30\u30da\u30a4\u30f3\u304c\u9589\u3058\u308b\u3053\u3068\u306b\u6ce8\u610f\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.iso.desc=\u30c7\u30fc\u30bf\u307e\u305f\u306f OS \u8d77\u52d5\u53ef\u80fd\u30e1\u30c7\u30a3\u30a2\u3092\u542b\u3080\u30c7\u30a3\u30b9\u30af \u30a4\u30e1\u30fc\u30b8 +message.join.project=\u3053\u308c\u3067\u3001\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306b\u53c2\u52a0\u3057\u307e\u3057\u305f\u3002\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u53c2\u7167\u3059\u308b\u306b\u306f\u30d7\u30ed\u30b8\u30a7\u30af\u30c8 \u30d3\u30e5\u30fc\u306b\u5207\u308a\u66ff\u3048\u3066\u304f\u3060\u3055\u3044\u3002 +message.launch.zone=\u30be\u30fc\u30f3\u3092\u8d77\u52d5\u3059\u308b\u6e96\u5099\u304c\u3067\u304d\u307e\u3057\u305f\u3002\u6b21\u306e\u624b\u9806\u306b\u9032\u3093\u3067\u304f\u3060\u3055\u3044\u3002 +message.lock.account=\u3053\u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u30ed\u30c3\u30af\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? \u3053\u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u3059\u3079\u3066\u306e\u30e6\u30fc\u30b6\u30fc\u304c\u30af\u30e9\u30a6\u30c9 \u30ea\u30bd\u30fc\u30b9\u3092\u7ba1\u7406\u3067\u304d\u306a\u304f\u306a\u308a\u307e\u3059\u3002\u305d\u306e\u5f8c\u3082\u65e2\u5b58\u306e\u30ea\u30bd\u30fc\u30b9\u306b\u306f\u30a2\u30af\u30bb\u30b9\u3067\u304d\u307e\u3059\u3002 +message.migrate.instance.confirm=\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u79fb\u884c\u5148\u306f\u6b21\u306e\u30db\u30b9\u30c8\u3067\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.migrate.instance.to.host=\u5225\u306e\u30db\u30b9\u30c8\u306b\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u79fb\u884c\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.migrate.instance.to.ps=\u5225\u306e\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u306b\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u79fb\u884c\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.migrate.router.confirm=\u30eb\u30fc\u30bf\u30fc\u306e\u79fb\u884c\u5148\u306f\u6b21\u306e\u30db\u30b9\u30c8\u3067\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.migrate.systemvm.confirm=\u30b7\u30b9\u30c6\u30e0 VM \u306e\u79fb\u884c\u5148\u306f\u6b21\u306e\u30db\u30b9\u30c8\u3067\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.migrate.volume=\u5225\u306e\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u306b\u30dc\u30ea\u30e5\u30fc\u30e0\u3092\u79fb\u884c\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.new.user=\u00e3\u0082\u00a2\u00e3\u0082\u00ab\u00e3\u0082\u00a6\u00e3\u0083\u00b3\u00e3\u0083\u0088\u00e3\u0081\u00ab\u00e6\u0096\u00b0\u00e3\u0081\u0097\u00e3\u0081\u0084\u00e3\u0083\u00a6\u00e3\u0083\u00bc\u00e3\u0082\u00b6\u00e3\u0083\u00bc\u00e3\u0082\u0092\u00e8\u00bf\u00bd\u00e5\u008a\u00a0\u00e3\u0081\u0099\u00e3\u0082\u008b\u00e3\u0081\u009f\u00e3\u0082\u0081\u00e3\u0081\u00ab\u00e3\u0080\u0081\u00e6\u00ac\u00a1\u00e3\u0081\u00ae\u00e6\u0083 +message.no.network.support.configuration.not.true=\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u304c\u6709\u52b9\u306a\u30be\u30fc\u30f3\u304c\u7121\u3044\u305f\u3081\u3001\u8ffd\u52a0\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u6a5f\u80fd\u306f\u3042\u308a\u307e\u305b\u3093\u3002\u624b\u9806 5. \u306b\u9032\u3093\u3067\u304f\u3060\u3055\u3044\u3002 +message.no.network.support=\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc\u3068\u3057\u3066 vSphere \u3092\u9078\u629e\u3057\u307e\u3057\u305f\u304c\u3001\u3053\u306e\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc\u306b\u8ffd\u52a0\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u6a5f\u80fd\u306f\u3042\u308a\u307e\u305b\u3093\u3002\u624b\u9806 5. \u306b\u9032\u3093\u3067\u304f\u3060\u3055\u3044\u3002 +message.no.projects.adminOnly=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u304c\u3042\u308a\u307e\u305b\u3093\u3002
\u7ba1\u7406\u8005\u306b\u65b0\u3057\u3044\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u4f5c\u6210\u3092\u4f9d\u983c\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.no.projects=\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u304c\u3042\u308a\u307e\u305b\u3093\u3002
\u30d7\u30ed\u30b8\u30a7\u30af\u30c8 \u30bb\u30af\u30b7\u30e7\u30f3\u304b\u3089\u65b0\u3057\u3044\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u4f5c\u6210\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.number.clusters=

\u30af\u30e9\u30b9\u30bf\u30fc\u6570

+message.number.hosts=

\u30db\u30b9\u30c8\u6570

+message.number.pods=

\u30dd\u30c3\u30c9\u6570

+message.number.storage=

\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8 \u30dc\u30ea\u30e5\u30fc\u30e0\u6570

+message.number.zones=

\u30be\u30fc\u30f3\u6570

+message.pending.projects.1=\u4fdd\u7559\u4e2d\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u62db\u5f85\u72b6\u304c\u3042\u308a\u307e\u3059\u3002 +message.pending.projects.2=\u8868\u793a\u3059\u308b\u306b\u306f\u30d7\u30ed\u30b8\u30a7\u30af\u30c8 \u30bb\u30af\u30b7\u30e7\u30f3\u306b\u79fb\u52d5\u3057\u3066\u3001\u4e00\u89a7\u304b\u3089\u62db\u5f85\u72b6\u3092\u9078\u629e\u3057\u307e\u3059\u3002 +message.please.add.at.lease.one.traffic.range=\u5c11\u306a\u304f\u3068\u3082 1 \u3064\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u7bc4\u56f2\u3092\u8ffd\u52a0\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.please.proceed=\u6b21\u306e\u624b\u9806\u306b\u9032\u3093\u3067\u304f\u3060\u3055\u3044\u3002 +message.please.select.a.configuration.for.your.zone=\u30be\u30fc\u30f3\u306e\u69cb\u6210\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.please.select.a.different.public.and.management.network.before.removing=\u524a\u9664\u306e\u524d\u306b\u7570\u306a\u308b\u30d1\u30d6\u30ea\u30c3\u30af\u304a\u3088\u3073\u7ba1\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.please.select.networks=\u4eee\u60f3\u30de\u30b7\u30f3\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.please.wait.while.zone.is.being.created=\u30be\u30fc\u30f3\u304c\u4f5c\u6210\u3055\u308c\u308b\u307e\u3067\u3057\u3070\u3089\u304f\u304a\u5f85\u3061\u304f\u3060\u3055\u3044... +message.project.invite.sent=\u30e6\u30fc\u30b6\u30fc\u306b\u62db\u5f85\u72b6\u304c\u9001\u4fe1\u3055\u308c\u307e\u3057\u305f\u3002\u30e6\u30fc\u30b6\u30fc\u304c\u62db\u5f85\u3092\u627f\u8afe\u3059\u308b\u3068\u3001\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306b\u8ffd\u52a0\u3055\u308c\u307e\u3059\u3002 +message.public.traffic.in.advanced.zone=\u30af\u30e9\u30a6\u30c9\u5185\u306e VM \u304c\u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8\u306b\u30a2\u30af\u30bb\u30b9\u3059\u308b\u3068\u3001\u30d1\u30d6\u30ea\u30c3\u30af \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u304c\u751f\u6210\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u305f\u3081\u306b\u3001\u4e00\u822c\u306b\u30a2\u30af\u30bb\u30b9\u53ef\u80fd\u306a IP \u30a2\u30c9\u30ec\u30b9\u3092\u5272\u308a\u5f53\u3066\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u30a8\u30f3\u30c9 \u30e6\u30fc\u30b6\u30fc\u306f CloudStack \u306e\u30e6\u30fc\u30b6\u30fc \u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9\u3092\u4f7f\u7528\u3057\u3066\u3053\u308c\u3089\u306e IP \u30a2\u30c9\u30ec\u30b9\u3092\u53d6\u5f97\u3057\u3001\u30b2\u30b9\u30c8 \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3068\u30d1\u30d6\u30ea\u30c3\u30af \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u9593\u306b NAT \u3092\u5b9f\u88c5\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002

\u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8 \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u305f\u3081\u306b\u3001\u5c11\u306a\u304f\u3068\u3082 1 \u3064 IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.public.traffic.in.basic.zone=\u30af\u30e9\u30a6\u30c9\u5185\u306e VM \u304c\u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8\u306b\u30a2\u30af\u30bb\u30b9\u3059\u308b\u304b\u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8\u7d4c\u7531\u3067\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306b\u30b5\u30fc\u30d3\u30b9\u3092\u63d0\u4f9b\u3059\u308b\u3068\u3001\u30d1\u30d6\u30ea\u30c3\u30af \u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u304c\u751f\u6210\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u305f\u3081\u306b\u3001\u4e00\u822c\u306b\u30a2\u30af\u30bb\u30b9\u53ef\u80fd\u306a IP \u30a2\u30c9\u30ec\u30b9\u3092\u5272\u308a\u5f53\u3066\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u4f5c\u6210\u3059\u308b\u3068\u3001\u30b2\u30b9\u30c8 IP \u30a2\u30c9\u30ec\u30b9\u306e\u307b\u304b\u306b\u3053\u306e\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9\u306e\u7bc4\u56f2\u304b\u3089\u30a2\u30c9\u30ec\u30b9\u304c 1 \u3064\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306b\u5272\u308a\u5f53\u3066\u3089\u308c\u307e\u3059\u3002\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9\u3068\u30b2\u30b9\u30c8 IP \u30a2\u30c9\u30ec\u30b9\u306e\u9593\u306b\u3001\u9759\u7684\u306a 1 \u5bfe 1 \u306e NAT \u304c\u81ea\u52d5\u7684\u306b\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u3055\u308c\u307e\u3059\u3002\u30a8\u30f3\u30c9 \u30e6\u30fc\u30b6\u30fc\u306f CloudStack \u306e\u30e6\u30fc\u30b6\u30fc \u30a4\u30f3\u30bf\u30fc\u30d5\u30a7\u30a4\u30b9\u3092\u4f7f\u7528\u3057\u3066\u8ffd\u52a0\u306e IP \u30a2\u30c9\u30ec\u30b9\u3092\u53d6\u5f97\u3057\u3001\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3068\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9\u306e\u9593\u306b\u9759\u7684 NAT \u3092\u5b9f\u88c5\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002 +message.remove.vpc=VPC \u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.remove.vpn.access=\u6b21\u306e\u30e6\u30fc\u30b6\u30fc\u304b\u3089 VPN \u30a2\u30af\u30bb\u30b9\u3092\u524a\u9664\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.reset.password.warning.notPasswordEnabled=\u3053\u306e\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306f\u3001\u30d1\u30b9\u30ef\u30fc\u30c9\u7ba1\u7406\u3092\u6709\u52b9\u306b\u305b\u305a\u306b\u4f5c\u6210\u3055\u308c\u307e\u3057\u305f\u3002 +message.reset.password.warning.notStopped=\u73fe\u5728\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u5909\u66f4\u3059\u308b\u524d\u306b\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u505c\u6b62\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.reset.VPN.connection=VPN \u63a5\u7d9a\u3092\u30ea\u30bb\u30c3\u30c8\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.restart.mgmt.server=\u65b0\u3057\u3044\u8a2d\u5b9a\u3092\u6709\u52b9\u306b\u3059\u308b\u305f\u3081\u306b\u3001\u7ba1\u7406\u30b5\u30fc\u30d0\u30fc\u3092\u518d\u8d77\u52d5\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.restart.mgmt.usage.server=\u65b0\u3057\u3044\u8a2d\u5b9a\u3092\u6709\u52b9\u306b\u3059\u308b\u305f\u3081\u306b\u3001\u7ba1\u7406\u30b5\u30fc\u30d0\u30fc\u3068\u4f7f\u7528\u72b6\u6cc1\u6e2c\u5b9a\u30b5\u30fc\u30d0\u30fc\u3092\u518d\u8d77\u52d5\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.restart.network=\u3053\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3067\u63d0\u4f9b\u3059\u308b\u3059\u3079\u3066\u306e\u30b5\u30fc\u30d3\u30b9\u304c\u4e2d\u65ad\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u518d\u8d77\u52d5\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.restart.vpc=VPC \u3092\u518d\u8d77\u52d5\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.security.group.usage=(\u8a72\u5f53\u3059\u308b\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u3092\u3059\u3079\u3066\u9078\u629e\u3059\u308b\u306b\u306f\u3001Ctrl \u30ad\u30fc\u3092\u62bc\u3057\u306a\u304c\u3089\u30af\u30ea\u30c3\u30af\u3057\u3066\u304f\u3060\u3055\u3044) +message.select.a.zone=\u30be\u30fc\u30f3\u306f\u901a\u5e38\u3001\u5358\u4e00\u306e\u30c7\u30fc\u30bf\u30bb\u30f3\u30bf\u30fc\u306b\u76f8\u5f53\u3057\u307e\u3059\u3002\u8907\u6570\u306e\u30be\u30fc\u30f3\u3092\u8a2d\u5b9a\u3057\u3001\u7269\u7406\u7684\u306b\u5206\u96e2\u3057\u3066\u5197\u9577\u6027\u3092\u6301\u305f\u305b\u308b\u3053\u3068\u306b\u3088\u308a\u3001\u30af\u30e9\u30a6\u30c9\u306e\u4fe1\u983c\u6027\u3092\u9ad8\u3081\u307e\u3059\u3002 +message.select.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.select.iso=\u65b0\u3057\u3044\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e ISO \u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.select.item=\u9805\u76ee\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.select.security.groups=\u65b0\u3057\u3044\u4eee\u60f3\u30de\u30b7\u30f3\u306e\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3 \u30b0\u30eb\u30fc\u30d7\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.select.template=\u65b0\u3057\u3044\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.setup.physical.network.during.zone.creation.basic=\u57fa\u672c\u30be\u30fc\u30f3\u3092\u8ffd\u52a0\u3059\u308b\u3068\u304d\u306f\u3001\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc\u4e0a\u306e NIC \u306b\u5bfe\u5fdc\u3059\u308b 1 \u3064\u306e\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u3067\u304d\u307e\u3059\u3002\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u3044\u304f\u3064\u304b\u306e\u7a2e\u985e\u306e\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u3092\u4f1d\u9001\u3057\u307e\u3059\u3002

\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306b\u307b\u304b\u306e\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u7a2e\u985e\u3092\u30c9\u30e9\u30c3\u30b0 \u30a2\u30f3\u30c9 \u30c9\u30ed\u30c3\u30d7\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002 +message.setup.physical.network.during.zone.creation=\u62e1\u5f35\u30be\u30fc\u30f3\u3092\u8ffd\u52a0\u3059\u308b\u3068\u304d\u306f\u30011 \u3064\u4ee5\u4e0a\u306e\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u5404\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306f\u30cf\u30a4\u30d1\u30fc\u30d0\u30a4\u30b6\u30fc\u4e0a\u306e 1 \u3064\u306e NIC \u306b\u5bfe\u5fdc\u3057\u307e\u3059\u3002\u5404\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3067\u306f\u3001\u7d44\u307f\u5408\u308f\u305b\u306b\u5236\u9650\u304c\u3042\u308a\u307e\u3059\u304c\u30011 \u3064\u4ee5\u4e0a\u306e\u7a2e\u985e\u306e\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u3092\u901a\u4fe1\u3067\u304d\u307e\u3059\u3002

\u5404\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306b\u5bfe\u3057\u3066\u30c8\u30e9\u30d5\u30a3\u30c3\u30af\u306e\u7a2e\u985e\u3092\u30c9\u30e9\u30c3\u30b0 \u30a2\u30f3\u30c9 \u30c9\u30ed\u30c3\u30d7\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.setup.successful=\u30af\u30e9\u30a6\u30c9\u304c\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u3055\u308c\u307e\u3057\u305f\u3002 +message.snapshot.schedule=\u6b21\u306e\u30aa\u30d7\u30b7\u30e7\u30f3\u304b\u3089\u9078\u629e\u3057\u3066\u30dd\u30ea\u30b7\u30fc\u306e\u57fa\u672c\u8a2d\u5b9a\u3092\u9069\u7528\u3059\u308b\u3053\u3068\u306b\u3088\u308a\u3001\u5b9a\u671f\u30b9\u30ca\u30c3\u30d7\u30b7\u30e7\u30c3\u30c8\u306e\u30b9\u30b1\u30b8\u30e5\u30fc\u30eb\u3092\u30bb\u30c3\u30c8\u30a2\u30c3\u30d7\u3067\u304d\u307e\u3059\u3002 +message.specify.url=URL \u3092\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044 +message.step.1.continue=\u7d9a\u884c\u3059\u308b\u306b\u306f\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u307e\u305f\u306f ISO \u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044 +message.step.1.desc=\u65b0\u3057\u3044\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u7528\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002ISO \u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3067\u304d\u308b\u7a7a\u767d\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u9078\u629e\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002 +message.step.2.continue=\u7d9a\u884c\u3059\u308b\u306b\u306f\u30b5\u30fc\u30d3\u30b9 \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044 message.step.2.desc= -message.step.3.continue=\u7D9A\u884C\u3059\u308B\u306B\u306F\u30C7\u30A3\u30B9\u30AF \u30AA\u30D5\u30A1\u30EA\u30F3\u30B0\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044 +message.step.3.continue=\u7d9a\u884c\u3059\u308b\u306b\u306f\u30c7\u30a3\u30b9\u30af \u30aa\u30d5\u30a1\u30ea\u30f3\u30b0\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044 message.step.3.desc= -message.step.4.continue=\u7D9A\u884C\u3059\u308B\u306B\u306F\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u5C11\u306A\u304F\u3068\u3082 1 \u3064\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044 -message.step.4.desc=\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u304C\u63A5\u7D9A\u3059\u308B\u30D7\u30E9\u30A4\u30DE\u30EA \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.storage.traffic=\u30DB\u30B9\u30C8\u3084 CloudStack \u30B7\u30B9\u30C6\u30E0 VM \u306A\u3069\u3001\u7BA1\u7406\u30B5\u30FC\u30D0\u30FC\u3068\u901A\u4FE1\u3059\u308B CloudStack \u306E\u5185\u90E8\u30EA\u30BD\u30FC\u30B9\u9593\u306E\u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u3067\u3059\u3002\u3053\u3053\u3067\u30B9\u30C8\u30EC\u30FC\u30B8 \u30C8\u30E9\u30D5\u30A3\u30C3\u30AF\u3092\u69CB\u6210\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.suspend.project=\u3053\u306E\u30D7\u30ED\u30B8\u30A7\u30AF\u30C8\u3092\u4E00\u6642\u505C\u6B62\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.template.desc=VM \u306E\u8D77\u52D5\u306B\u4F7F\u7528\u3067\u304D\u308B OS \u30A4\u30E1\u30FC\u30B8 -message.tooltip.dns.1=\u30BE\u30FC\u30F3\u5185\u306E VM \u3067\u4F7F\u7528\u3059\u308B DNS \u30B5\u30FC\u30D0\u30FC\u306E\u540D\u524D\u3067\u3059\u3002\u30BE\u30FC\u30F3\u306E\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9\u304B\u3089\u3001\u3053\u306E\u30B5\u30FC\u30D0\u30FC\u306B\u901A\u4FE1\u3067\u304D\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.tooltip.dns.2=\u30BE\u30FC\u30F3\u5185\u306E VM \u3067\u4F7F\u7528\u3059\u308B 2 \u756A\u76EE\u306E DNS \u30B5\u30FC\u30D0\u30FC\u306E\u540D\u524D\u3067\u3059\u3002\u30BE\u30FC\u30F3\u306E\u30D1\u30D6\u30EA\u30C3\u30AF IP \u30A2\u30C9\u30EC\u30B9\u304B\u3089\u3001\u3053\u306E\u30B5\u30FC\u30D0\u30FC\u306B\u901A\u4FE1\u3067\u304D\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.tooltip.internal.dns.1=\u30BE\u30FC\u30F3\u5185\u306E CloudStack \u5185\u90E8\u30B7\u30B9\u30C6\u30E0 VM \u3067\u4F7F\u7528\u3059\u308B DNS \u30B5\u30FC\u30D0\u30FC\u306E\u540D\u524D\u3067\u3059\u3002\u30DD\u30C3\u30C9\u306E\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 IP \u30A2\u30C9\u30EC\u30B9\u304B\u3089\u3001\u3053\u306E\u30B5\u30FC\u30D0\u30FC\u306B\u901A\u4FE1\u3067\u304D\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.tooltip.internal.dns.2=\u30BE\u30FC\u30F3\u5185\u306E CloudStack \u5185\u90E8\u30B7\u30B9\u30C6\u30E0 VM \u3067\u4F7F\u7528\u3059\u308B DNS \u30B5\u30FC\u30D0\u30FC\u306E\u540D\u524D\u3067\u3059\u3002\u30DD\u30C3\u30C9\u306E\u30D7\u30E9\u30A4\u30D9\u30FC\u30C8 IP \u30A2\u30C9\u30EC\u30B9\u304B\u3089\u3001\u3053\u306E\u30B5\u30FC\u30D0\u30FC\u306B\u901A\u4FE1\u3067\u304D\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.tooltip.network.domain=DNS \u30B5\u30D5\u30A3\u30C3\u30AF\u30B9\u3067\u3059\u3002\u3053\u306E\u30B5\u30D5\u30A3\u30C3\u30AF\u30B9\u304B\u3089\u30B2\u30B9\u30C8 VM \u3067\u30A2\u30AF\u30BB\u30B9\u3059\u308B\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u30AB\u30B9\u30BF\u30E0 \u30C9\u30E1\u30A4\u30F3\u540D\u304C\u4F5C\u6210\u3055\u308C\u307E\u3059\u3002 -message.tooltip.pod.name=\u3053\u306E\u30DD\u30C3\u30C9\u306E\u540D\u524D\u3067\u3059\u3002 -message.tooltip.reserved.system.gateway=\u30DD\u30C3\u30C9\u5185\u306E\u30DB\u30B9\u30C8\u306E\u30B2\u30FC\u30C8\u30A6\u30A7\u30A4\u3067\u3059\u3002 -message.tooltip.reserved.system.netmask=\u30DD\u30C3\u30C9\u306E\u30B5\u30D6\u30CD\u30C3\u30C8\u3092\u5B9A\u7FA9\u3059\u308B\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30D7\u30EC\u30D5\u30A3\u30C3\u30AF\u30B9\u3067\u3059\u3002CIDR \u8868\u8A18\u3092\u4F7F\u7528\u3057\u307E\u3059\u3002 -message.tooltip.zone.name=\u30BE\u30FC\u30F3\u306E\u540D\u524D\u3067\u3059\u3002 -message.update.os.preference=\u3053\u306E\u30DB\u30B9\u30C8\u306E OS \u57FA\u672C\u8A2D\u5B9A\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002\u540C\u69D8\u306E\u57FA\u672C\u8A2D\u5B9A\u3092\u6301\u3064\u3059\u3079\u3066\u306E\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306F\u3001\u5225\u306E\u30DB\u30B9\u30C8\u3092\u9078\u629E\u3059\u308B\u524D\u306B\u307E\u305A\u3053\u306E\u30DB\u30B9\u30C8\u306B\u5272\u308A\u5F53\u3066\u3089\u308C\u307E\u3059\u3002 -message.update.resource.count=\u3053\u306E\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u30EA\u30BD\u30FC\u30B9\u6570\u3092\u66F4\u65B0\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.update.ssl=\u5404\u30B3\u30F3\u30BD\u30FC\u30EB \u30D7\u30ED\u30AD\u30B7\u306E\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3067\u66F4\u65B0\u3059\u308B\u3001X.509 \u6E96\u62E0\u306E\u65B0\u3057\u3044 SSL \u8A3C\u660E\u66F8\u3092\u9001\u4FE1\u3057\u3066\u304F\u3060\u3055\u3044\: -message.validate.instance.name=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u540D\u306F 63 \u6587\u5B57\u4EE5\u5185\u3067\u6307\u5B9A\u3057\u3066\u304F\u3060\u3055\u3044\u3002ASCII \u6587\u5B57\u306E a\uFF5Ez\u3001A\uFF5EZ\u3001\u6570\u5B57\u306E 0\uFF5E9\u3001\u304A\u3088\u3073\u30CF\u30A4\u30D5\u30F3\u306E\u307F\u3092\u4F7F\u7528\u3067\u304D\u307E\u3059\u3002\u6587\u5B57\u3067\u59CB\u307E\u308A\u3001\u6587\u5B57\u307E\u305F\u306F\u6570\u5B57\u3067\u7D42\u308F\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002 -message.virtual.network.desc=\u30A2\u30AB\u30A6\u30F3\u30C8\u306E\u5C02\u7528\u4EEE\u60F3\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3067\u3059\u3002\u30D6\u30ED\u30FC\u30C9\u30AD\u30E3\u30B9\u30C8 \u30C9\u30E1\u30A4\u30F3\u306F VLAN \u5185\u306B\u914D\u7F6E\u3055\u308C\u3001\u30D1\u30D6\u30EA\u30C3\u30AF \u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3078\u306E\u30A2\u30AF\u30BB\u30B9\u306F\u3059\u3079\u3066\u4EEE\u60F3\u30EB\u30FC\u30BF\u30FC\u306B\u3088\u3063\u3066\u30EB\u30FC\u30C6\u30A3\u30F3\u30B0\u3055\u308C\u307E\u3059\u3002 -message.vm.create.template.confirm=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u4F5C\u6210\u3059\u308B\u3068 VM \u304C\u81EA\u52D5\u7684\u306B\u518D\u8D77\u52D5\u3055\u308C\u307E\u3059\u3002 -message.vm.review.launch=\u6B21\u306E\u60C5\u5831\u3092\u53C2\u7167\u3057\u3066\u3001\u4EEE\u60F3\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u3092\u6B63\u3057\u304F\u8A2D\u5B9A\u3057\u305F\u3053\u3068\u3092\u78BA\u8A8D\u3057\u3066\u304B\u3089\u8D77\u52D5\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.volume.create.template.confirm=\u3053\u306E\u30C7\u30A3\u30B9\u30AF \u30DC\u30EA\u30E5\u30FC\u30E0\u306E\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u3092\u4F5C\u6210\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? \u30DC\u30EA\u30E5\u30FC\u30E0 \u30B5\u30A4\u30BA\u306B\u3088\u3063\u3066\u306F\u3001\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u4F5C\u6210\u306B\u306F\u6570\u5206\u4EE5\u4E0A\u304B\u304B\u308B\u53EF\u80FD\u6027\u304C\u3042\u308A\u307E\u3059\u3002 -message.you.must.have.at.least.one.physical.network=\u5C11\u306A\u304F\u3068\u3082 1 \u3064\u7269\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u304C\u5FC5\u8981\u3067\u3059 -message.Zone.creation.complete=\u30BE\u30FC\u30F3\u304C\u4F5C\u6210\u3055\u308C\u307E\u3057\u305F -message.zone.creation.complete.would.you.like.to.enable.this.zone=\u30BE\u30FC\u30F3\u304C\u4F5C\u6210\u3055\u308C\u307E\u3057\u305F\u3002\u3053\u306E\u30BE\u30FC\u30F3\u3092\u6709\u52B9\u306B\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -message.zone.no.network.selection=\u9078\u629E\u3057\u305F\u30BE\u30FC\u30F3\u3067\u306F\u3001\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u3092\u9078\u629E\u3067\u304D\u307E\u305B\u3093\u3002 -message.zone.step.1.desc=\u30BE\u30FC\u30F3\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF \u30E2\u30C7\u30EB\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002 -message.zone.step.2.desc=\u00e6\u0096\u00b0\u00e3\u0081\u0097\u00e3\u0081\u0084Zone\u00e3\u0082\u0092\u00e8\u00bf\u00bd\u00e5\u008a\u00a0\u00e3\u0081\u0099\u00e3\u0082\u008b\u00e3\u0081\u009f\u00e3\u0082\u0081\u00e3\u0081\u00ab\u00e3\u0080\u0081\u00e6\u00ac\u00a1\u00e3\u0081\u00ae\u00e6\u0083\u0085\u00e5\u00a0\u00b1\u00e3\u0082\u0092\u00e5\u0085\u00a5\u00e5\u008a\u009b\u00e3\u0081\u0097\u00e3\u0081\u00a6\u00e3\u0081\u008f\u00e3\u0081\u00a0\u00e3\u0081\u0095\u00e3\u0081\u0084\u00e3\u0080\u0082 -message.zone.step.3.desc=\u00e6\u0096\u00b0\u00e3\u0081\u0097\u00e3\u0081\u0084Pod\u00e3\u0082\u0092\u00e8\u00bf\u00bd\u00e5\u008a\u00a0\u00e3\u0081\u0099\u00e3\u0082\u008b\u00e3\u0081\u009f\u00e3\u0082\u0081\u00e3\u0081\u00ab\u00e3\u0080\u0081\u00e6\u00ac\u00a1\u00e3\u0081\u00ae\u00e6\u0083\u0085\u00e5\u00a0\u00b1\u00e3\u0082\u0092\u00e5\u0085\u00a5\u00e5\u008a\u009b\u00e3\u0081\u0097\u00e3\u0081\u00a6\u00e3\u0081\u008f\u00e3\u0081\u00a0\u00e3\u0081\u0095\u00e3\u0081\u0084\u00e3\u0080\u0082 -message.zoneWizard.enable.local.storage=\u8B66\u544A\: \u3053\u306E\u30BE\u30FC\u30F3\u306E\u30ED\u30FC\u30AB\u30EB \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u6709\u52B9\u306B\u3059\u308B\u5834\u5408\u306F\u3001\u30B7\u30B9\u30C6\u30E0 VM \u306E\u8D77\u52D5\u5834\u6240\u306B\u5FDC\u3058\u3066\u6B21\u306E\u64CD\u4F5C\u304C\u5FC5\u8981\u3067\u3059\u3002

1. \u30B7\u30B9\u30C6\u30E0 VM \u3092\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3067\u8D77\u52D5\u3059\u308B\u5FC5\u8981\u304C\u3042\u308B\u5834\u5408\u306F\u3001\u30D7\u30E9\u30A4\u30DE\u30EA \u30B9\u30C8\u30EC\u30FC\u30B8\u3092\u4F5C\u6210\u3057\u305F\u5F8C\u3067\u30BE\u30FC\u30F3\u306B\u8FFD\u52A0\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002\u307E\u305F\u3001\u7121\u52B9\u72B6\u614B\u306E\u30BE\u30FC\u30F3\u3092\u8D77\u52D5\u3059\u308B\u5FC5\u8981\u3082\u3042\u308A\u307E\u3059\u3002

2. \u30B7\u30B9\u30C6\u30E0 VM \u3092\u30ED\u30FC\u30AB\u30EB \u30B9\u30C8\u30EC\u30FC\u30B8\u3067\u8D77\u52D5\u3059\u308B\u5FC5\u8981\u304C\u3042\u308B\u5834\u5408\u306F\u3001system.vm.use.local.storage \u3092 true \u306B\u8A2D\u5B9A\u3057\u3066\u304B\u3089\u30BE\u30FC\u30F3\u3092\u6709\u52B9\u306B\u3059\u308B\u5FC5\u8981\u304C\u3042\u308A\u307E\u3059\u3002


\u7D9A\u884C\u3057\u3066\u3082\u3088\u308D\u3057\u3044\u3067\u3059\u304B? -mode=\u30E2\u30FC\u30C9 -network.rate=\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u901F\u5EA6 -notification.reboot.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u518D\u8D77\u52D5 -notification.start.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u8D77\u52D5 -notification.stop.instance=\u30A4\u30F3\u30B9\u30BF\u30F3\u30B9\u306E\u505C\u6B62 -side.by.side=\u4E26\u5217 -state.Accepted=\u627F\u8AFE\u6E08\u307F -state.Active=\u30A2\u30AF\u30C6\u30A3\u30D6 -state.Allocated=\u5272\u308A\u5F53\u3066\u6E08\u307F -state.Allocating=\u5272\u308A\u5F53\u3066\u4E2D -state.BackedUp=\u30D0\u30C3\u30AF\u30A2\u30C3\u30D7\u6E08\u307F -state.BackingUp=\u30D0\u30C3\u30AF\u30A2\u30C3\u30D7\u4E2D -state.Completed=\u5B8C\u4E86 -state.Creating=\u4F5C\u6210\u4E2D -state.Declined=\u8F9E\u9000 -state.Destroyed=\u7834\u68C4\u6E08\u307F -state.Disabled=\u7121\u52B9 -state.enabled=\u6709\u52B9 -state.Enabled=\u6709\u52B9 -state.Error=\u30A8\u30E9\u30FC -state.Expunging=\u62B9\u6D88\u4E2D -state.Migrating=\u79FB\u884C\u4E2D -state.Pending=\u4FDD\u7559 -state.ready=\u6E96\u5099\u5B8C\u4E86 -state.Ready=\u6E96\u5099\u5B8C\u4E86 -state.Running=\u5B9F\u884C\u4E2D -state.Starting=\u958B\u59CB\u4E2D -state.Stopped=\u505C\u6B62\u6E08\u307F -state.Stopping=\u505C\u6B62\u3057\u3066\u3044\u307E\u3059 -state.Suspended=\u4E00\u6642\u505C\u6B62 +message.step.4.continue=\u7d9a\u884c\u3059\u308b\u306b\u306f\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u5c11\u306a\u304f\u3068\u3082 1 \u3064\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044 +message.step.4.desc=\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u304c\u63a5\u7d9a\u3059\u308b\u30d7\u30e9\u30a4\u30de\u30ea \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.suspend.project=\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u4e00\u6642\u505c\u6b62\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.template.desc=VM \u306e\u8d77\u52d5\u306b\u4f7f\u7528\u3067\u304d\u308b OS \u30a4\u30e1\u30fc\u30b8 +message.tooltip.dns.1=\u30be\u30fc\u30f3\u5185\u306e VM \u3067\u4f7f\u7528\u3059\u308b DNS \u30b5\u30fc\u30d0\u30fc\u306e\u540d\u524d\u3067\u3059\u3002\u30be\u30fc\u30f3\u306e\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9\u304b\u3089\u3001\u3053\u306e\u30b5\u30fc\u30d0\u30fc\u306b\u901a\u4fe1\u3067\u304d\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.tooltip.dns.2=\u30be\u30fc\u30f3\u5185\u306e VM \u3067\u4f7f\u7528\u3059\u308b 2 \u756a\u76ee\u306e DNS \u30b5\u30fc\u30d0\u30fc\u306e\u540d\u524d\u3067\u3059\u3002\u30be\u30fc\u30f3\u306e\u30d1\u30d6\u30ea\u30c3\u30af IP \u30a2\u30c9\u30ec\u30b9\u304b\u3089\u3001\u3053\u306e\u30b5\u30fc\u30d0\u30fc\u306b\u901a\u4fe1\u3067\u304d\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.tooltip.internal.dns.1=\u30be\u30fc\u30f3\u5185\u306e CloudStack \u5185\u90e8\u30b7\u30b9\u30c6\u30e0 VM \u3067\u4f7f\u7528\u3059\u308b DNS \u30b5\u30fc\u30d0\u30fc\u306e\u540d\u524d\u3067\u3059\u3002\u30dd\u30c3\u30c9\u306e\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 IP \u30a2\u30c9\u30ec\u30b9\u304b\u3089\u3001\u3053\u306e\u30b5\u30fc\u30d0\u30fc\u306b\u901a\u4fe1\u3067\u304d\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.tooltip.internal.dns.2=\u30be\u30fc\u30f3\u5185\u306e CloudStack \u5185\u90e8\u30b7\u30b9\u30c6\u30e0 VM \u3067\u4f7f\u7528\u3059\u308b DNS \u30b5\u30fc\u30d0\u30fc\u306e\u540d\u524d\u3067\u3059\u3002\u30dd\u30c3\u30c9\u306e\u30d7\u30e9\u30a4\u30d9\u30fc\u30c8 IP \u30a2\u30c9\u30ec\u30b9\u304b\u3089\u3001\u3053\u306e\u30b5\u30fc\u30d0\u30fc\u306b\u901a\u4fe1\u3067\u304d\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.tooltip.network.domain=DNS \u30b5\u30d5\u30a3\u30c3\u30af\u30b9\u3067\u3059\u3002\u3053\u306e\u30b5\u30d5\u30a3\u30c3\u30af\u30b9\u304b\u3089\u30b2\u30b9\u30c8 VM \u3067\u30a2\u30af\u30bb\u30b9\u3059\u308b\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u306e\u30ab\u30b9\u30bf\u30e0 \u30c9\u30e1\u30a4\u30f3\u540d\u304c\u4f5c\u6210\u3055\u308c\u307e\u3059\u3002 +message.tooltip.pod.name=\u3053\u306e\u30dd\u30c3\u30c9\u306e\u540d\u524d\u3067\u3059\u3002 +message.tooltip.reserved.system.gateway=\u30dd\u30c3\u30c9\u5185\u306e\u30db\u30b9\u30c8\u306e\u30b2\u30fc\u30c8\u30a6\u30a7\u30a4\u3067\u3059\u3002 +message.tooltip.reserved.system.netmask=\u30dd\u30c3\u30c9\u306e\u30b5\u30d6\u30cd\u30c3\u30c8\u3092\u5b9a\u7fa9\u3059\u308b\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30d7\u30ec\u30d5\u30a3\u30c3\u30af\u30b9\u3067\u3059\u3002CIDR \u8868\u8a18\u3092\u4f7f\u7528\u3057\u307e\u3059\u3002 +message.tooltip.zone.name=\u30be\u30fc\u30f3\u306e\u540d\u524d\u3067\u3059\u3002 +message.update.os.preference=\u3053\u306e\u30db\u30b9\u30c8\u306e OS \u57fa\u672c\u8a2d\u5b9a\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u540c\u69d8\u306e\u57fa\u672c\u8a2d\u5b9a\u3092\u6301\u3064\u3059\u3079\u3066\u306e\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306f\u3001\u5225\u306e\u30db\u30b9\u30c8\u3092\u9078\u629e\u3059\u308b\u524d\u306b\u307e\u305a\u3053\u306e\u30db\u30b9\u30c8\u306b\u5272\u308a\u5f53\u3066\u3089\u308c\u307e\u3059\u3002 +message.update.resource.count=\u3053\u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u30ea\u30bd\u30fc\u30b9\u6570\u3092\u66f4\u65b0\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.update.ssl=\u5404\u30b3\u30f3\u30bd\u30fc\u30eb \u30d7\u30ed\u30ad\u30b7\u306e\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3067\u66f4\u65b0\u3059\u308b\u3001X.509 \u6e96\u62e0\u306e\u65b0\u3057\u3044 SSL \u8a3c\u660e\u66f8\u3092\u9001\u4fe1\u3057\u3066\u304f\u3060\u3055\u3044\: +message.validate.instance.name=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u540d\u306f 63 \u6587\u5b57\u4ee5\u5185\u3067\u6307\u5b9a\u3057\u3066\u304f\u3060\u3055\u3044\u3002ASCII \u6587\u5b57\u306e a\uff5ez\u3001A\uff5eZ\u3001\u6570\u5b57\u306e 0\uff5e9\u3001\u304a\u3088\u3073\u30cf\u30a4\u30d5\u30f3\u306e\u307f\u3092\u4f7f\u7528\u3067\u304d\u307e\u3059\u3002\u6587\u5b57\u3067\u59cb\u307e\u308a\u3001\u6587\u5b57\u307e\u305f\u306f\u6570\u5b57\u3067\u7d42\u308f\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002 +message.virtual.network.desc=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u5c02\u7528\u4eee\u60f3\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3067\u3059\u3002\u30d6\u30ed\u30fc\u30c9\u30ad\u30e3\u30b9\u30c8 \u30c9\u30e1\u30a4\u30f3\u306f VLAN \u5185\u306b\u914d\u7f6e\u3055\u308c\u3001\u30d1\u30d6\u30ea\u30c3\u30af \u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3078\u306e\u30a2\u30af\u30bb\u30b9\u306f\u3059\u3079\u3066\u4eee\u60f3\u30eb\u30fc\u30bf\u30fc\u306b\u3088\u3063\u3066\u30eb\u30fc\u30c6\u30a3\u30f3\u30b0\u3055\u308c\u307e\u3059\u3002 +message.vm.create.template.confirm=\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u4f5c\u6210\u3059\u308b\u3068 VM \u304c\u81ea\u52d5\u7684\u306b\u518d\u8d77\u52d5\u3055\u308c\u307e\u3059\u3002 +message.vm.review.launch=\u6b21\u306e\u60c5\u5831\u3092\u53c2\u7167\u3057\u3066\u3001\u4eee\u60f3\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u6b63\u3057\u304f\u8a2d\u5b9a\u3057\u305f\u3053\u3068\u3092\u78ba\u8a8d\u3057\u3066\u304b\u3089\u8d77\u52d5\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.volume.create.template.confirm=\u3053\u306e\u30c7\u30a3\u30b9\u30af \u30dc\u30ea\u30e5\u30fc\u30e0\u306e\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u3092\u4f5c\u6210\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? \u30dc\u30ea\u30e5\u30fc\u30e0 \u30b5\u30a4\u30ba\u306b\u3088\u3063\u3066\u306f\u3001\u30c6\u30f3\u30d7\u30ec\u30fc\u30c8\u306e\u4f5c\u6210\u306b\u306f\u6570\u5206\u4ee5\u4e0a\u304b\u304b\u308b\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u3002 +message.you.must.have.at.least.one.physical.network=\u5c11\u306a\u304f\u3068\u3082 1 \u3064\u7269\u7406\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u304c\u5fc5\u8981\u3067\u3059 +message.Zone.creation.complete=\u30be\u30fc\u30f3\u304c\u4f5c\u6210\u3055\u308c\u307e\u3057\u305f +message.zone.creation.complete.would.you.like.to.enable.this.zone=\u30be\u30fc\u30f3\u304c\u4f5c\u6210\u3055\u308c\u307e\u3057\u305f\u3002\u3053\u306e\u30be\u30fc\u30f3\u3092\u6709\u52b9\u306b\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +message.zone.no.network.selection=\u9078\u629e\u3057\u305f\u30be\u30fc\u30f3\u3067\u306f\u3001\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u3092\u9078\u629e\u3067\u304d\u307e\u305b\u3093\u3002 +message.zone.step.1.desc=\u30be\u30fc\u30f3\u306e\u30cd\u30c3\u30c8\u30ef\u30fc\u30af \u30e2\u30c7\u30eb\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\u3002 +message.zone.step.2.desc=\u00e6\u0096\u00b0\u00e3\u0081\u0097\u00e3\u0081\u0084Zone\u00e3\u0082\u0092\u00e8\u00bf\u00bd\u00e5\u008a\u00a0\u00e3\u0081\u0099\u00e3\u0082\u008b\u00e3\u0081\u009f\u00e3\u0082\u0081\u00e3\u0081\u00ab\u00e3\u0080\u0081\u00e6\u00ac\u00a1\u00e3\u0081\u00ae\u00e6\u0083 +message.zone.step.3.desc=\u00e6\u0096\u00b0\u00e3\u0081\u0097\u00e3\u0081\u0084Pod\u00e3\u0082\u0092\u00e8\u00bf\u00bd\u00e5\u008a\u00a0\u00e3\u0081\u0099\u00e3\u0082\u008b\u00e3\u0081\u009f\u00e3\u0082\u0081\u00e3\u0081\u00ab\u00e3\u0080\u0081\u00e6\u00ac\u00a1\u00e3\u0081\u00ae\u00e6\u0083 +message.zoneWizard.enable.local.storage=\u8b66\u544a\: \u3053\u306e\u30be\u30fc\u30f3\u306e\u30ed\u30fc\u30ab\u30eb \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u6709\u52b9\u306b\u3059\u308b\u5834\u5408\u306f\u3001\u30b7\u30b9\u30c6\u30e0 VM \u306e\u8d77\u52d5\u5834\u6240\u306b\u5fdc\u3058\u3066\u6b21\u306e\u64cd\u4f5c\u304c\u5fc5\u8981\u3067\u3059\u3002

1. \u30b7\u30b9\u30c6\u30e0 VM \u3092\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3067\u8d77\u52d5\u3059\u308b\u5fc5\u8981\u304c\u3042\u308b\u5834\u5408\u306f\u3001\u30d7\u30e9\u30a4\u30de\u30ea \u30b9\u30c8\u30ec\u30fc\u30b8\u3092\u4f5c\u6210\u3057\u305f\u5f8c\u3067\u30be\u30fc\u30f3\u306b\u8ffd\u52a0\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u307e\u305f\u3001\u7121\u52b9\u72b6\u614b\u306e\u30be\u30fc\u30f3\u3092\u8d77\u52d5\u3059\u308b\u5fc5\u8981\u3082\u3042\u308a\u307e\u3059\u3002

2. \u30b7\u30b9\u30c6\u30e0 VM \u3092\u30ed\u30fc\u30ab\u30eb \u30b9\u30c8\u30ec\u30fc\u30b8\u3067\u8d77\u52d5\u3059\u308b\u5fc5\u8981\u304c\u3042\u308b\u5834\u5408\u306f\u3001system.vm.use.local.storage \u3092 true \u306b\u8a2d\u5b9a\u3057\u3066\u304b\u3089\u30be\u30fc\u30f3\u3092\u6709\u52b9\u306b\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002


\u7d9a\u884c\u3057\u3066\u3082\u3088\u308d\u3057\u3044\u3067\u3059\u304b? +mode=\u30e2\u30fc\u30c9 +network.rate=\u30cd\u30c3\u30c8\u30ef\u30fc\u30af\u901f\u5ea6 +notification.reboot.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u518d\u8d77\u52d5 +notification.start.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u8d77\u52d5 +notification.stop.instance=\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306e\u505c\u6b62 +side.by.side=\u4e26\u5217 +state.Accepted=\u627f\u8afe\u6e08\u307f +state.Active=\u30a2\u30af\u30c6\u30a3\u30d6 +state.Allocated=\u5272\u308a\u5f53\u3066\u6e08\u307f +state.Allocating=\u5272\u308a\u5f53\u3066\u4e2d +state.BackedUp=\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u6e08\u307f +state.BackingUp=\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u4e2d +state.Completed=\u5b8c\u4e86 +state.Creating=\u4f5c\u6210\u4e2d +state.Declined=\u8f9e\u9000 +state.Destroyed=\u7834\u68c4\u6e08\u307f +state.Disabled=\u7121\u52b9 +state.enabled=\u6709\u52b9 +state.Enabled=\u6709\u52b9 +state.Error=\u30a8\u30e9\u30fc +state.Expunging=\u62b9\u6d88\u4e2d +state.Migrating=\u79fb\u884c\u4e2d +state.Pending=\u4fdd\u7559 +state.ready=\u6e96\u5099\u5b8c\u4e86 +state.Ready=\u6e96\u5099\u5b8c\u4e86 +state.Running=\u5b9f\u884c\u4e2d +state.Starting=\u958b\u59cb\u4e2d +state.Stopped=\u505c\u6b62\u6e08\u307f +state.Stopping=\u505c\u6b62\u3057\u3066\u3044\u307e\u3059 +state.Suspended=\u4e00\u6642\u505c\u6b62 ui.listView.filters.all=\u3059\u3079\u3066 -ui.listView.filters.mine=\u81EA\u5206\u306E\u3082\u306E +ui.listView.filters.mine=\u81ea\u5206\u306e\u3082\u306e diff --git a/client/WEB-INF/classes/resources/messages_ko_KR.properties b/client/WEB-INF/classes/resources/messages_ko_KR.properties index 757871acde0..766fc607648 100644 --- a/client/WEB-INF/classes/resources/messages_ko_KR.properties +++ b/client/WEB-INF/classes/resources/messages_ko_KR.properties @@ -15,6 +15,7 @@ # specific language governing permissions and limitations # under the License. + changed.item.properties=\ud56d\ubaa9 \uc18d\uc131 \ubcc0\uacbd confirm.enable.swift=Swift \uae30\uc220 \uc9c0\uc6d0\ub97c \uc0ac\uc6a9 \ud558\ub824\uba74 \ub2e4\uc74c \uc815\ubcf4\ub97c \uc785\ub825\ud574 \uc8fc\uc2ed\uc2dc\uc624. error.could.not.enable.zone=Zone\uc744 \uc0ac\uc6a9 \ud560 \uc218 \uc5c6\uc2b5\ub2c8\ub2e4. @@ -1193,7 +1194,6 @@ message.add.load.balancer.under.ip=\ub2e4\uc74c IP \uc8fc\uc18c\uc5d0 \ub300\ud5 message.add.load.balancer=Zone\uc5d0 \ub124\ud2b8\uc6cc\ud06c \ub85c\ub4dc \uacf5\uc720 \uc7a5\uce58\ub97c \ucd94\uac00\ud569\ub2c8\ub2e4. message.add.network=Zone \uc5d0 \uc0c8\ub85c\uc6b4 \ub124\ud2b8\uc6cc\ud06c\ub97c \ucd94\uac00\ud569\ub2c8\ub2e4. message.add.new.gateway.to.vpc=\ud604\uc7ac VPC\uc5d0 \uc0c8\ub85c\uc6b4 \uac8c\uc774\ud2b8\uc6e8\uc774\ub97c \ucd94\uac00\ud558\uae30 \uc704\ud55c \uc815\ubcf4\ub97c \uc9c0\uc815\ud574 \uc8fc\uc2ed\uc2dc\uc624. -message.add.pod.during.zone.creation=\uac01 Zone\uc5d0\ub294 \ud55c \uac1c \uc774\uc0c1 Pod\uac00 \ud544\uc694\ud569\ub2c8\ub2e4. \uc9c0\uae08 \uc5ec\uae30\uc11c \uccab\ubc88\uc9f8 Pod\ub97c \ucd94\uac00\ud569\ub2c8\ub2e4. Pod\ub294 \ud638\uc2a4\ud2b8\uc640 \uae30\ubcf8 \uc2a4\ud1a0\ub9ac\uc9c0 \uc11c\ubc84\uc5d0\uc11c \uad6c\uc131\ud569\ub2c8\ub2e4\ub9cc \uc774\ub294 \ub2e4\uc74c \uc21c\uc11c\ub85c \ucd94\uac00\ud569\ub2c8\ub2e4. \ub9e8 \ucc98\uc74c CloudStack \ub0b4\ubd80 \uad00\ub9ac \ud2b8\ub798\ud53d\uc744 \uc704\ud574\uc11c IP \uc8fc\uc18c \ubc94\uc704\ub97c \uc608\uc57d\ud569\ub2c8\ub2e4. IP \uc8fc\uc18c \ubc94\uc704\ub294 \ud074\ub77c\uc6b0\ub4dc \ub0b4\ubd80 \uac01 Zone\uc5d0\uc11c \uc911\ubcf5 \ud558\uc9c0 \uc54a\uac8c \uc608\uc57d\ud560 \ud544\uc694\uac00 \uc788\uc2b5\ub2c8\ub2e4. message.add.pod=Zone \uc5d0 \uc0c8\ub85c\uc6b4 Pod\ub97c \ucd94\uac00\ud569\ub2c8\ub2e4. message.add.primary.storage=Zone Pod \uc5d0 \uc0c8\ub85c\uc6b4 \uae30\ubcf8 \uc2a4\ud1a0\ub9ac\uc9c0\ub97c \ucd94\uac00\ud569\ub2c8\ub2e4. message.add.primary=\uc0c8\ub85c\uc6b4 \uae30\ubcf8 \uc2a4\ud1a0\ub9ac\uc9c0\ub97c \ucd94\uac00\ud558\uae30 \uc704\ud574 \uc544\ub798 \ud30c\ub77c\ubbf8\ud130\ub97c \uc9c0\uc815\ud574 \uc8fc\uc2ed\uc2dc\uc624. @@ -1253,7 +1253,6 @@ message.delete.VPN.gateway=\ud604\uc7ac VPN \uac8c\uc774\ud2b8\uc6e8\uc774\ub97c message.desc.advanced.zone=\ubcf4\ub2e4 \uc138\ub828\ub41c \ub124\ud2b8\uc6cc\ud06c \uae30\uc220\uc744 \uc9c0\uc6d0\ud569\ub2c8\ub2e4. \uc774 \ub124\ud2b8\uc6cc\ud06c \ubaa8\ub378\uc744 \uc120\ud0dd\ud558\uba74, \ubcf4\ub2e4 \uc720\uc5f0\ud558\uac8c \uac8c\uc2a4\ud2b8 \ub124\ud2b8\uc6cc\ud06c\ub97c \uc815\ud558\uace0 \ubc29\ud654\ubcbd(fire wall), VPN, \ub124\ud2b8\uc6cc\ud06c \ub85c\ub4dc \uacf5\uc720 \uc7a5\uce58 \uae30\uc220 \uc9c0\uc6d0\uc640 \uac19\uc740 \uc0ac\uc6a9\uc790 \uc9c0\uc815 \ud55c \ub124\ud2b8\uc6cc\ud06c \uc81c\uacf5\uc744 \uc81c\uacf5\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4. message.desc.basic.zone=\uac01 VM \uc778\uc2a4\ud134\uc2a4\uc5d0 IP \uc8fc\uc18c\uac00 \ub124\ud2b8\uc6cc\ud06c\uc5d0\uc11c \uc9c1\uc811 \ud560\ub2f9\ud560 \uc218 \uc788\ub294 \ub2e8\uc77c \ub124\ud2b8\uc6cc\ud06c\ub97c \uc81c\uacf5\ud569\ub2c8\ub2e4. \ubcf4\uc548 \uadf8\ub8f9 (\uc804\uc1a1\uc6d0 IP \uc8fc\uc18c \ud544\ud130)\uacfc \uac19\uc740 \uce35 \uc138 \uac00\uc9c0 \ub808\ubca8 \ubc29\ubc95\uc73c\ub85c \uac8c\uc2a4\ud2b8\ub97c \ubd84\ub9ac\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4. message.desc.cluster=\uac01 Pod\uc5d0\ub294 \ud55c \uac1c \uc774\uc0c1 \ud074\ub7ec\uc2a4\ud130\uac00 \ud544\uc694\ud569\ub2c8\ub2e4. \uc9c0\uae08 \uc5ec\uae30\uc11c \ucd5c\ucd08 \ud074\ub7ec\uc2a4\ud130\ub97c \ucd94\uac00\ud569\ub2c8\ub2e4. \ud074\ub7ec\uc2a4\ud130\ub294 \ud638\uc2a4\ud2b8\ub97c \uadf8\ub8f9\ud654 \ud558\ub294 \ubc29\ubc95\uc785\ub2c8\ub2e4. \ud55c \ud074\ub7ec\uc2a4\ud130 \ub0b4\ubd80 \ud638\uc2a4\ud2b8\ub294 \ubaa8\ub450 \ub3d9\uc77c\ud55c \ud558\ub4dc\uc6e8\uc5b4\uc5d0\uc11c \uad6c\uc131\ub418\uc5b4 \uac19\uc740 \ud558\uc774\ud37c \ubc14\uc774\uc800\ub97c \uc2e4\ud589\ud558\uace0 \uac19\uc740 \uc11c\ube0c \ub124\ud2b8\uc6cc\ud06c\uc0c1\uc5d0 \uc788\uc5b4 \uac19\uc740 \uacf5\uc720 \uc2a4\ud1a0\ub9ac\uc9c0\uc5d0 \uc811\uadfc \ud569\ub2c8\ub2e4. \uac01 \ud074\ub7ec\uc2a4\ud130\ub294 \ud55c \uac1c \uc774\uc0c1 \ud638\uc2a4\ud2b8\uc640 \ud55c \uac1c \uc774\uc0c1 \uae30\ubcf8 \uc2a4\ud1a0\ub9ac\uc9c0 \uc11c\ubc84\uc5d0\uc11c \uad6c\uc131\ub429\ub2c8\ub2e4. -message.desc.host=\uac01 \ud074\ub7ec\uc2a4\ud130\uc5d0\ub294 \uc801\uc5b4\ub3c4 \ud55c \uac1c \uc774\uc0c1 \uac8c\uc2a4\ud2b8 VM\ub97c \uc2e4\ud589\ud558\uae30 \uc704\ud55c \ud638\uc2a4\ud2b8 (\ucef4\ud4e8\ud130)\uac00 \ud544\uc694\ud569\ub2c8\ub2e4. \uc9c0\uae08 \uc5ec\uae30\uc11c \uccab\ubc88\uc9f8 \ud638\uc2a4\ud2b8\ub97c \ucd94\uac00\ud569\ub2c8\ub2e4. CloudStack\uc73c\ub85c \ud638\uc2a4\ud2b8\ub97c \ub3d9\uc791\ud558\ub824\uba74 \ud638\uc2a4\ud2b8\uc5d0\uac8c \ud558\uc774\ud37c \ubc14\uc774\uc800\ub97c \uc124\uce58\ud558\uace0 IP \uc8fc\uc18c\ub97c \ud560\ub2f9\ud574 \ud638\uc2a4\ud2b8\uac00 CloudStack \uad00\ub9ac \uc11c\ubc84\uc5d0 \uc811\uc18d\ud558\ub3c4\ub85d \ud569\ub2c8\ub2e4.

\ud638\uc2a4\ud2b8 DNS \uba85 \ub610\ub294 IP \uc8fc\uc18c, \uc0ac\uc6a9\uc790\uba85(\uc6d0\ub798 root)\uacfc \uc554\ud638 \ubc0f \ud638\uc2a4\ud2b8 \ubd84\ub958\uc5d0 \uc0ac\uc6a9\ud558\ub294 \ub77c\ubca8\uc744 \uc785\ub825\ud574 \uc8fc\uc2ed\uc2dc\uc624. message.desc.primary.storage=\uac01 \ud074\ub7ec\uc2a4\ud130\uc5d0\ub294 \uc801\uc5b4\ub3c4 \ud55c \uac1c \uc774\uc0c1\uc758 \uae30\ubcf8 \uc2a4\ud1a0\ub9ac\uc9c0 \uc11c\ubc84\uac00 \ud544\uc694\ud569\ub2c8\ub2e4. \uc9c0\uae08 \uc5ec\uae30\uc11c \uccab\ubc88\uc9f8 \uc11c\ubc84\ub97c \ucd94\uac00\ud569\ub2c8\ub2e4. \uae30\ubcf8 \uc2a4\ud1a0\ub9ac\uc9c0\ub294 \ud074\ub7ec\uc2a4\ud130 \ub0b4 \ubd80 \ud638\uc2a4\ud2b8\uc0c1\uc5d0\uc11c \ub3d9\uc791\ud558\ub294 \ubaa8\ub4e0 VM \ub514\uc2a4\ud06c \ubcfc\ub968\uc744 \ud3ec\ud568\ud569\ub2c8\ub2e4. \uae30\ubcf8\uc801\uc73c\ub85c \ud558\uc774\ud37c \ubc14\uc774\uc800\uc5d0\uc11c \uae30\uc220 \uc9c0\uc6d0\ub418\ub294 \ud45c\uc900\uc5d0 \uc900\uac70\ud55c \ud504\ub85c\ud1a0\ucf5c\uc744 \uc0ac\uc6a9\ud574 \uc8fc\uc2ed\uc2dc\uc624. message.desc.secondary.storage=\uac01 Zone\uc5d0\ub294 \uc801\uc5b4\ub3c4 \ud55c \uac1c \uc774\uc0c1\uc758 NFS \uc989 2\ucc28 \uc2a4\ud1a0\ub9ac\uc9c0 \uc11c\ubc84\uac00 \ud544\uc694\ud569\ub2c8\ub2e4. \uc9c0\uae08 \uc5ec\uae30\uc11c \uccab\ubc88\uc9f8 \uc11c\ubc84\ub97c \ucd94\uac00\ud569\ub2c8\ub2e4. 2\ucc28 \uc2a4\ud1a0\ub9ac\uc9c0\ub294 VM \ud15c\ud50c\ub9bf, ISO \uc774\ubbf8\uc9c0 \ubc0f VM \ub514\uc2a4\ud06c \ubcfc\ub968 \uc2a4\ub0c5\uc0f7\uc744 \ud3ec\ud568\ud569\ub2c8\ub2e4. \uc774 \uc11c\ubc84\ub294 Zone\ub0b4 \ubaa8\ub4e0 \ud638\uc2a4\ud2b8\uc5d0\uc11c \uc0ac\uc6a9\ud560 \uc218 \uc788\uc5b4\uc57c \ud569\ub2c8\ub2e4.

IP \uc8fc\uc18c\uc640 \ub0b4\ubcf4\ub0b4\ub0bc \uacbd\ub85c\ub97c \uc785\ub825\ud574 \uc8fc\uc2ed\uc2dc\uc624. message.desc.zone=Zone\uc740 CloudStack \ud658\uacbd\ub0b4 \ucd5c\ub300 \uc870\uc9c1 \ub2e8\uc704\ub85c \uc6d0\ub798 \ub2e8\uc77c \ub370\uc774\ud130 \uc13c\ud130\uc5d0 \ud574\ub2f9\ud569\ub2c8\ub2e4. Zone\uc5d0 \ud574\uc11c \ubb3c\ub9ac\uc801\uc778 \ubd84\ub9ac\uc640 \uc911\ubcf5\uc131\uc774 \uc81c\uacf5\ub429\ub2c8\ub2e4. Zone\uc740 \ud55c \uac1c \uc774\uc0c1 Pod( \uac01 Pod\ub294 \ud638\uc2a4\ud2b8\uc640 \uae30\ubcf8 \uc2a4\ud1a0\ub9ac\uc9c0 \uc11c\ubc84\uc5d0\uc11c \uad6c\uc131)\uc640 Zone\ub0b4 \ubaa8\ub4e0 Pod\ub85c \uacf5\uc720\ub418\ub294 2\ucc28 \uc2a4\ud1a0\ub9ac\uc9c0 \uc11c\ubc84\ub85c \uad6c\uc131\ub429\ub2c8\ub2e4. @@ -1381,7 +1380,6 @@ message.step.3.continue=\uc2e4\ud589\ud558\ub824\uba74 \ub514\uc2a4\ud06c\uc81c\ message.step.3.desc= message.step.4.continue=\uc2e4\ud589\ud558\ub824\uba74 \ub124\ud2b8\uc6cc\ud06c\ub97c \uc801\uc5b4\ub3c4 \ud55c \uac1c \uc774\uc0c1 \uc120\ud0dd\ud574 \uc8fc\uc2ed\uc2dc\uc624. message.step.4.desc=\uac00\uc0c1 \uc778\uc2a4\ud134\uc2a4\uac00 \uc811\uc18d\ud558\ub294 \uae30\ubcf8 \ub124\ud2b8\uc6cc\ud06c\ub97c \uc120\ud0dd\ud574 \uc8fc\uc2ed\uc2dc\uc624. -message.storage.traffic=\ud638\uc2a4\ud2b8\ub098 CloudStack \uc2dc\uc2a4\ud15c VM \ub4f1 \uad00\ub9ac \uc11c\ubc84\uc640 \ud1b5\uc2e0\ud558\ub294 CloudStack \ub0b4\ubd80 \uc790\uc6d0\uac04 \ud2b8\ub798\ud53d\uc785\ub2c8\ub2e4. \uc5ec\uae30\uc11c \uc2a4\ud1a0\ub9ac\uc9c0 \ud2b8\ub798\ud53d\uc744 \uad6c\uc131\ud574 \uc8fc\uc2ed\uc2dc\uc624. message.suspend.project=\ud604\uc7ac \ud504\ub85c\uc81d\ud2b8\ub97c \uc77c\uc2dc\uc815\uc9c0\ud558\uc2dc\uaca0\uc2b5\ub2c8\uae4c? message.template.desc=VM\uc758 \uc2dc\uc791\uc5d0 \uc0ac\uc6a9\ud560 \uc218 \uc788\ub294 OS \uc774\ubbf8\uc9c0 message.tooltip.dns.1=Zone\ub0b4 VM \ub85c \uc0ac\uc6a9\ud558\ub294 DNS \uc11c\ubc84 \uc774\ub984\uc785\ub2c8\ub2e4. Zone \uacf5\uac1c IP \uc8fc\uc18c\uc5d0\uc11c \uc774 \uc11c\ubc84\uc5d0 \ud1b5\uc2e0\ud560 \uc218 \uc788\uc5b4\uc57c \ud569\ub2c8\ub2e4. diff --git a/client/WEB-INF/classes/resources/messages_nb_NO.properties b/client/WEB-INF/classes/resources/messages_nb_NO.properties index be412449398..8fba48ca9c4 100644 --- a/client/WEB-INF/classes/resources/messages_nb_NO.properties +++ b/client/WEB-INF/classes/resources/messages_nb_NO.properties @@ -15,6 +15,7 @@ # specific language governing permissions and limitations # under the License. + changed.item.properties=Endrede egenskaper error.could.not.enable.zone=Kunne ikke aktivere sonen error.installWizard.message=Noe gikk galt. G\u00e5 tilbake og korriger feilene. diff --git a/client/WEB-INF/classes/resources/messages_pt_BR.properties b/client/WEB-INF/classes/resources/messages_pt_BR.properties index fd24f542e8d..23123c16764 100644 --- a/client/WEB-INF/classes/resources/messages_pt_BR.properties +++ b/client/WEB-INF/classes/resources/messages_pt_BR.properties @@ -15,6 +15,7 @@ # specific language governing permissions and limitations # under the License. + changed.item.properties=Alteradas propriedades do item confirm.enable.s3=Por favor preencha as informa\u00e7\u00f5es abaixo para habilitar suporte a storage secund\u00e1ria fornecida por S3 confirm.enable.swift=Por favor preencha as informa\u00e7\u00f5es abaixo para habilitar suporte ao Swift @@ -1112,7 +1113,6 @@ label.zones=Zonas label.zone.type=Tipo de Zona label.zone.wide=Zone-Wide label.zoneWizard.trafficType.guest=H\u00f3spede\: tr\u00e1fego entre m\u00e1quinas virtuais de usu\u00e1rios finais -label.zoneWizard.trafficType.management=Ger\u00eancia\: tr\u00e1fego entre recursos internos do CloudStack, incluindo quaisquer componentes que se comunicam com o servidor de gerenciamento, tais como hosts e m\u00e1quinas virtuais de sistema do CloudStack label.zoneWizard.trafficType.public=P\u00fablico\: tr\u00e1fego entre a internet e m\u00e1quinas virtuais na nuvem. label.zoneWizard.trafficType.storage=Storage\: tr\u00e1fego entre servidores de storage prim\u00e1ria e secund\u00e1ria, tais como templates de m\u00e1quinas virtuais e snapshots label.zone=Zona diff --git a/client/WEB-INF/classes/resources/messages_ru_RU.properties b/client/WEB-INF/classes/resources/messages_ru_RU.properties index b28f6b69e6f..5818abc9199 100644 --- a/client/WEB-INF/classes/resources/messages_ru_RU.properties +++ b/client/WEB-INF/classes/resources/messages_ru_RU.properties @@ -15,6 +15,7 @@ # specific language governing permissions and limitations # under the License. + changed.item.properties=\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u044b confirm.enable.swift=\u0417\u0430\u043f\u043e\u043b\u043d\u0438\u0442\u0435 \u043d\u0438\u0436\u0435\u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u0434\u043b\u044f \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438 Swift error.could.not.enable.zone=\u041d\u0435 \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0437\u043e\u043d\u0443 @@ -1130,7 +1131,6 @@ message.additional.networks.desc=\u041f\u043e\u0436\u0430\u043b\u0443\u0439\u044 message.add.load.balancer=\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0443 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0432 \u0437\u043e\u043d\u0443 message.add.load.balancer.under.ip=\u041f\u0440\u0430\u0432\u0438\u043b\u043e \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0438 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0431\u044b\u043b \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d \u0432 IP\: message.add.network=\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043d\u043e\u0432\u0443\u044e \u0441\u0435\u0442\u044c \u0434\u043b\u044f \u0437\u043e\u043d\u044b\: -message.add.pod.during.zone.creation=\u041a\u0430\u0436\u0434\u0430\u044f \u0437\u043e\u043d\u0430 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043e\u0434\u0438\u043d \u0438\u043b\u0438 \u0431\u043e\u043b\u0435\u0435 \u0441\u0442\u0435\u043d\u0434\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b \u0441\u0435\u0439\u0447\u0430\u0441 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u0435 \u043f\u0435\u0440\u0432\u044b\u043c. \u0421\u0442\u0435\u043d\u0434 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0443\u0437\u043b\u044b \u0438 \u0441\u0435\u0440\u0432\u0435\u0440\u044b \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0433\u043e \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u044b \u0432 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0435\u043c \u0448\u0430\u0433\u0435. \u0414\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d \u0440\u0435\u0437\u0435\u0440\u0432\u043d\u044b\u0445 \u0430\u0434\u0440\u0435\u0441\u043e\u0432 IP \u0434\u043b\u044f \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0435\u0439 \u0441\u0435\u0442\u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f. \u0414\u0438\u0430\u043f\u0430\u0437\u043e\u043d \u0440\u0435\u0437\u0435\u0440\u0432\u043d\u044b\u0445 IP \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0443\u043d\u0438\u043a\u0430\u043b\u044c\u043d\u044b\u043c \u0434\u043b\u044f \u043a\u0430\u0436\u0434\u043e\u0439 \u0437\u043e\u043d\u044b \u043e\u0431\u043b\u0430\u043a\u0430. message.add.pod=\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043d\u043e\u0432\u044b\u0439 \u0441\u0442\u0435\u043d\u0434 \u0434\u043b\u044f \u0437\u043e\u043d\u044b message.add.primary.storage=\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0435 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435 \u0434\u043b\u044f \u0437\u043e\u043d\u044b , \u0441\u0442\u0435\u043d\u0434\u0430 message.add.primary=\u0423\u043a\u0430\u0436\u0438\u0442\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0434\u043b\u044f \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043d\u043e\u0432\u043e\u0433\u043e \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0433\u043e \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430 @@ -1185,7 +1185,6 @@ message.delete.user=\u041f\u043e\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442 message.desc.advanced.zone=\u0414\u043b\u044f \u0431\u043e\u043b\u0435\u0435 \u0441\u043b\u043e\u0436\u043d\u044b\u0445 \u0441\u0435\u0442\u0435\u0432\u044b\u0445 \u0442\u043e\u043f\u043e\u043b\u043e\u0433\u0438\u0439. \u042d\u0442\u0430 \u0441\u0435\u0442\u0435\u0432\u0430\u044f \u043c\u043e\u0434\u0435\u043b\u044c \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0432\u0430\u0435\u0442 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u0443\u044e \u0433\u0438\u0431\u043a\u043e\u0441\u0442\u044c \u0432 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0438 \u0433\u043e\u0441\u0442\u0435\u0432\u043e\u0439 \u0441\u0435\u0442\u0438 \u0438 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0443\u0441\u043b\u0443\u0433, \u0442\u0430\u043a\u0438\u0445 \u043a\u0430\u043a \u043c\u0435\u0436\u0441\u0435\u0442\u0435\u0432\u043e\u0439 \u044d\u043a\u0440\u0430\u043d, VPN, \u0438\u043b\u0438 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u043a\u0438 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438. message.desc.basic.zone=\u041f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0435\u0434\u0438\u0441\u0442\u0432\u0435\u043d\u043d\u0443\u044e \u0441\u0435\u0442\u044c, \u0433\u0434\u0435 \u043a\u0430\u0436\u0434\u0430\u044f \u0412\u041c \u0438\u043c\u0435\u0435\u0442 \u00ab\u0431\u0435\u043b\u044b\u0439\u00bb IP-\u0430\u0434\u0440\u0435\u0441 \u0441\u0435\u0442\u0438. \u0418\u0437\u043e\u043b\u044f\u0446\u0438\u0438 \u0433\u043e\u0441\u0442\u0435\u0439 \u043c\u043e\u0436\u043d\u043e \u0434\u043e\u0431\u0438\u0442\u044c\u0441\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0441\u0435\u0442\u0438 3-\u0433\u043e \u0443\u0440\u043e\u0432\u043d\u044f, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0433\u0440\u0443\u043f\u043f\u044b \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u0438 (\u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u044f IP-\u0432\u0434\u0440\u0435\u0441\u043e\u0432) message.desc.cluster=\u041a\u0430\u0436\u0434\u044b\u0439 \u0441\u0442\u0435\u043d\u0434 \u0434\u043e\u043b\u0436\u0435\u043d \u0438\u043c\u0435\u0442\u044c \u043e\u0434\u0438\u043d \u0438\u043b\u0438 \u0431\u043e\u043b\u0435\u0435 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u043e\u0432, \u043f\u0435\u0440\u0432\u044b\u0439 \u0438\u0437 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0432\u044b \u0441\u0435\u0439\u0447\u0430\u0441 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u0435. \u041a\u043b\u0430\u0441\u0442\u0435\u0440 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0433\u0440\u0443\u043f\u043f\u0443 \u0443\u0437\u043b\u043e\u0432. \u0423\u0437\u043b\u044b \u0432 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0435 \u0438\u043c\u0435\u044e\u0442 \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u043e\u0435 \u043e\u0431\u043e\u0440\u0443\u0434\u043e\u0432\u0430\u043d\u0438\u0435, \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u0442\u0441\u044f \u0447\u0435\u0440\u0435\u0437 \u043e\u0434\u0438\u043d \u0433\u0438\u043f\u0435\u0440\u0432\u0438\u0437\u043e\u0440, \u043d\u0430\u0445\u043e\u0434\u044f\u0442\u0441\u044f \u0432 \u043e\u0434\u043d\u043e\u0439 \u0441\u0435\u0442\u0438 \u0438 \u0438\u043c\u0435\u044e\u0442 \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043e\u0434\u043d\u043e\u043c\u0443 \u0438 \u0442\u043e\u043c\u0443 \u0436\u0435 \u043e\u0442\u043a\u0440\u044b\u0442\u043e\u043c\u0443 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0443. \u041a\u0430\u0436\u0434\u044b\u0439 \u043a\u043b\u0430\u0441\u0442\u0435\u0440 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043e\u0434\u0438\u043d \u0438\u043b\u0438 \u0431\u043e\u043b\u0435\u0435 \u0443\u0437\u043b\u043e\u0432, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0438\u0435\u0442\u044c \u043e\u0434\u0438\u043d \u0438\u043b\u0438 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0445 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449. -message.desc.host=\u041a\u0430\u0436\u0434\u044b\u0439 \u043a\u043b\u0430\u0441\u0442\u0435\u0440 \u0434\u043e\u043b\u0436\u0435\u043d \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u043a\u0430\u043a \u043c\u0438\u043d\u0438\u043c\u0443\u043c \u043e\u0434\u0438\u043d \u0443\u0437\u0435\u043b (\u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440) \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0412\u041c, \u043f\u0435\u0440\u0432\u044b\u0439 \u0438\u0437 \u043a\u043b\u0430\u0441\u0442\u0435\u0440 \u0432\u044b \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u0435 \u0441\u0435\u0439\u0447\u0430\u0441. \u0414\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0443\u0437\u043b\u0430 \u0432 CloudStack \u0432\u0430\u0436\u043d\u0430 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0433\u0438\u043f\u0435\u0440\u0432\u0438\u0437\u043e\u0440\u0430 \u043d\u0430 \u0443\u0437\u0435\u043b, \u043f\u0440\u0438\u0432\u044f\u0437\u043a\u0430 IP \u043a \u0443\u0437\u043b\u0443 \u0438 \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u0443\u0437\u043b\u0430 \u0441 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u043c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f CloudStack.

\u0423\u043a\u0430\u0436\u0438\u0442\u0435 \u0438\u043c\u044f DNS \u0438\u043b\u0438 \u0430\u0434\u0440\u0435\u0441 IP, \u0438\u043c\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0438 \u043f\u0430\u0440\u043e\u043b\u044c \u043a \u041e\u0421 (\u043e\u0431\u044b\u0447\u043d\u043e root), \u0430 \u0442\u0430\u043a\u0436\u0435 \u043c\u0435\u0442\u043a\u0438 \u0434\u043b\u044f \u0433\u0440\u0443\u043f\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0443\u0437\u043b\u043e\u0432. message.desc.primary.storage=\u041a\u0430\u0436\u0434\u0430\u044f \u0433\u0440\u0443\u043f\u043f\u0430 \u0434\u043e\u043b\u0436\u043d\u0430 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0442\u044c \u043e\u0434\u0438\u043d \u0438\u043b\u0438 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u0435\u0440\u0432\u0438\u0447\u043d\u044b\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432 \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445, \u0438 \u043c\u044b \u0434\u043e\u0431\u0430\u0432\u0438\u043c \u043f\u0435\u0440\u0432\u044b\u0439 \u0441\u0435\u0439\u0447\u0430\u0441. \u041f\u0435\u0440\u0432\u0438\u0447\u043d\u0430\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0440\u0430\u0437\u0434\u0435\u043b\u044b \u0436\u0435\u0441\u0442\u043a\u043e\u0433\u043e \u0434\u0438\u0441\u043a\u0430 \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0445 \u043c\u0430\u0448\u0438\u043d, \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0449\u0438\u0445 \u043d\u0430 \u0443\u0437\u043b\u0430\u0445 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u043b\u044e\u0431\u043e\u0439 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0439 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0435 \u0433\u0438\u043f\u0435\u0440\u0432\u0438\u0437\u043e\u0440\u0430. message.desc.secondary.storage=\u041a\u0430\u0436\u0434\u0430\u044f \u0437\u043e\u043d\u0430 \u0434\u043e\u043b\u0436\u043d\u0430 \u043e\u0431\u043b\u0430\u0434\u0430\u0442\u044c \u0445\u043e\u0442\u044f \u0431\u044b \u043e\u0434\u043d\u0438\u043c \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u043c NFS \u0438\u043b\u0438 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u043c \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435\u043c \u0438 \u0438\u0445 \u043d\u0430\u0434\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0432 \u043f\u0435\u0440\u0432\u0443\u044e \u043e\u0447\u0435\u0440\u0435\u0434\u044c. \u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0435 \u043f\u0440\u0435\u0434\u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u043e \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u0412\u041c, \u043e\u0431\u0440\u0430\u0437\u043e\u0432 ISO \u0438 \u0441\u043d\u0438\u043c\u043a\u043e\u0432 \u0412\u041c. \u042d\u0442\u043e\u0442 \u0441\u0435\u0440\u0432\u0435\u0440 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u0434\u043b\u044f \u0432\u0441\u0435\u0445 \u0443\u0437\u043b\u043e\u0432 \u0437\u043e\u043d\u044b.

\u041f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c IP-\u0430\u0434\u0440\u0435\u0441 \u0438 \u043f\u0443\u0442\u044c. message.desc.zone=layer 3 @@ -1310,7 +1309,6 @@ message.step.3.continue=\u0412\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u0434\ message.step.3.desc= message.step.4.continue=\u0412\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u0445\u043e\u0442\u044f \u0431\u044b \u043e\u0434\u043d\u0443 \u0441\u0435\u0442\u044c \u0434\u043b\u044f \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0435\u043d\u0438\u044f. message.step.4.desc=\u0412\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u043e\u0441\u043d\u043e\u0432\u043d\u0443\u044e \u0441\u0435\u0442\u044c, \u043a \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0430 \u043c\u0430\u0448\u0438\u043d\u0430. -message.storage.traffic=\u0422\u0440\u0430\u0444\u0438\u043a \u043c\u0435\u0436\u0434\u0443 \u0432\u043d\u0443\u0442\u0440\u0435\u043d\u043d\u0438\u043c\u0438 \u0440\u0435\u0441\u0443\u0440\u0441\u0430\u043c\u0438 CloudStack, \u0432\u043a\u043b\u044e\u0447\u0430\u044f \u0432\u0441\u0435 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0443\u044e\u0442 \u0441 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u043c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f, \u0442\u0430\u043a\u0438\u0435 \u043a\u0430\u043a \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0435 \u0445\u043e\u0441\u0442\u044b \u0438 CloudStack \u0441\u0438\u0441\u0442\u0435\u043c\u044b. \u041d\u0430\u0441\u0442\u0440\u043e\u0439\u0442\u0435 \u0442\u0440\u0430\u0444\u0438\u043a \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0437\u0434\u0435\u0441\u044c. message.suspend.project=\u0412\u044b \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0445\u043e\u0442\u0438\u0442\u0435 \u043f\u0440\u0438\u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043f\u0440\u043e\u0435\u043a\u0442? message.template.desc=\u041e\u0431\u0440\u0430\u0437 \u041e\u0421, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0437\u0430\u0433\u0440\u0443\u0437\u043e\u0447\u043d\u043e\u0439 \u0432 \u0412\u041c message.tooltip.dns.1=\u0418\u043c\u044f \u0441\u0435\u0440\u0432\u0435\u0440\u0430 DNS \u0434\u043b\u044f \u0412\u041c \u044d\u0442\u043e\u0439 \u0437\u043e\u043d\u044b. \u041f\u0443\u0431\u043b\u0438\u0447\u043d\u044b\u0435 IP-\u0430\u0434\u0440\u0435\u0441\u0430 \u044d\u0442\u043e\u0439 \u0437\u043e\u043d\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u0438\u043c\u0435\u0442\u044c \u043c\u0430\u0440\u0448\u0440\u0443\u0442 \u0434\u043e \u044d\u0442\u043e\u0433\u043e \u0441\u0435\u0440\u0432\u0435\u0440\u0430. diff --git a/client/WEB-INF/classes/resources/messages_zh_CN.properties b/client/WEB-INF/classes/resources/messages_zh_CN.properties index f62439d460d..687ef60b3c1 100644 --- a/client/WEB-INF/classes/resources/messages_zh_CN.properties +++ b/client/WEB-INF/classes/resources/messages_zh_CN.properties @@ -15,6 +15,7 @@ # specific language governing permissions and limitations # under the License. + changed.item.properties=\u66f4\u6539\u9879\u76ee\u5c5e\u6027 confirm.enable.s3=\u8bf7\u586b\u5199\u4e0b\u5217\u4fe1\u606f\u4ee5\u542f\u7528\u652f\u6301S3\u7684\u4e8c\u7ea7\u5b58\u50a8 confirm.enable.swift=\u8bf7\u586b\u5199\u4ee5\u4e0b\u4fe1\u606f\u4ee5\u542f\u7528\u5bf9 SWIFT \u7684\u652f\u6301 @@ -1164,7 +1165,6 @@ label.zone.type=\u533a\u57df\u7c7b\u578b label.zone=\u533a\u57df label.zone.wide=\u6574\u4e2a\u533a\u57df label.zoneWizard.trafficType.guest=\u6765\u5bbe\u7f51\u7edc\: \u5ba2\u6237\u865a\u62df\u673a\u4e4b\u95f4\u7684\u7f51\u7edc\u6d41\u91cf -label.zoneWizard.trafficType.management=\u7ba1\u7406\u7f51\: CloudStack\u5185\u90e8\u8d44\u6e90\u4e4b\u95f4\u7684\u7f51\u7edc\u6d41\u91cf, \u5305\u62ec\u4e0e\u7ba1\u7406\u670d\u52a1\u5668\u4ea4\u4e92\u7684\u4efb\u4f55\u7ec4\u4ef6, \u6bd4\u5982\u4e3b\u673a\u548cCloudStack\u7cfb\u7edf\u865a\u62df\u673a label.zoneWizard.trafficType.public=\u516c\u5171\u7f51\u7edc\: \u4e91\u73af\u5883\u4e2d\u865a\u62df\u673a\u4e0e\u56e0\u7279\u7f51\u4e4b\u95f4\u7684\u7f51\u7edc\u6d41\u91cf. label.zoneWizard.trafficType.storage=\u5b58\u50a8\u7f51\: \u4e3b\u5b58\u50a8\u4e0e\u4e8c\u7ea7\u5b58\u50a8\u670d\u52a1\u5668\u4e4b\u95f4\u7684\u6d41\u91cf, \u6bd4\u5982\u865a\u673a\u6a21\u677f\u548c\u5feb\u7167 managed.state=\u6258\u7ba1\u72b6\u6001 @@ -1255,7 +1255,6 @@ message.add.load.balancer=\u5411\u533a\u57df\u4e2d\u6dfb\u52a0\u4e00\u4e2a\u8d1f message.add.load.balancer.under.ip=\u5df2\u5728\u4ee5\u4e0b IP \u4e0b\u6dfb\u52a0\u8d1f\u8f7d\u5e73\u8861\u5668\u89c4\u5219\: message.add.network=\u4e3a\u533a\u57df\u6dfb\u52a0\u4e00\u4e2a\u65b0\u7f51\u7edc\: message.add.new.gateway.to.vpc=\u8bf7\u6307\u5b9a\u5c06\u65b0\u7f51\u5173\u6dfb\u52a0\u5230\u6b64 VPC \u6240\u9700\u7684\u4fe1\u606f\u3002 -message.add.pod.during.zone.creation=\u6bcf\u4e2a\u533a\u57df\u4e2d\u5fc5\u987b\u5305\u542b\u4e00\u4e2a\u6216\u591a\u4e2a\u63d0\u4f9b\u70b9\uff0c\u73b0\u5728\u6211\u4eec\u5c06\u6dfb\u52a0\u7b2c\u4e00\u4e2a\u63d0\u4f9b\u70b9\u3002\u63d0\u4f9b\u70b9\u4e2d\u5305\u542b\u4e3b\u673a\u548c\u4e3b\u5b58\u50a8\u670d\u52a1\u5668\uff0c\u60a8\u5c06\u5728\u968f\u540e\u7684\u67d0\u4e2a\u6b65\u9aa4\u4e2d\u6dfb\u52a0\u8fd9\u4e9b\u4e3b\u673a\u548c\u670d\u52a1\u5668\u3002\u9996\u5148\uff0c\u8bf7\u4e3a CloudStack \u7684\u5185\u90e8\u7ba1\u7406\u6d41\u91cf\u914d\u7f6e\u4e00\u4e2a\u9884\u7559 IP \u5730\u5740\u8303\u56f4\u3002\u9884\u7559\u7684 IP \u8303\u56f4\u5bf9\u4e91\u4e2d\u7684\u6bcf\u4e2a\u533a\u57df\u6765\u8bf4\u5fc5\u987b\u552f\u4e00\u3002 message.add.pod=\u4e3a\u533a\u57df \u6dfb\u52a0\u4e00\u4e2a\u65b0\u63d0\u4f9b\u70b9 message.add.primary.storage=\u4e3a\u533a\u57df \u3001\u63d0\u4f9b\u70b9 \u6dfb\u52a0\u4e00\u4e2a\u65b0\u7684\u4e3b\u5b58\u50a8 message.add.primary=\u8bf7\u6307\u5b9a\u4ee5\u4e0b\u53c2\u6570\u4ee5\u6dfb\u52a0\u4e00\u4e2a\u65b0\u4e3b\u5b58\u50a8 @@ -1317,7 +1316,6 @@ message.delete.VPN.gateway=\u8bf7\u786e\u8ba4\u60a8\u786e\u5b9e\u8981\u5220\u966 message.desc.advanced.zone=\u9002\u7528\u4e8e\u66f4\u52a0\u590d\u6742\u7684\u7f51\u7edc\u62d3\u6251\u3002\u6b64\u7f51\u7edc\u6a21\u5f0f\u5728\u5b9a\u4e49\u6765\u5bbe\u7f51\u7edc\u5e76\u63d0\u4f9b\u9632\u706b\u5899\u3001VPN \u6216\u8d1f\u8f7d\u5e73\u8861\u5668\u652f\u6301\u7b49\u81ea\u5b9a\u4e49\u7f51\u7edc\u65b9\u6848\u65b9\u9762\u63d0\u4f9b\u4e86\u6700\u5927\u7684\u7075\u6d3b\u6027\u3002 message.desc.basic.zone=\u63d0\u4f9b\u4e00\u4e2a\u7f51\u7edc\uff0c\u5c06\u76f4\u63a5\u4ece\u6b64\u7f51\u7edc\u4e2d\u4e3a\u6bcf\u4e2a VM \u5b9e\u4f8b\u5206\u914d\u4e00\u4e2a IP\u3002\u53ef\u4ee5\u901a\u8fc7\u5b89\u5168\u7ec4\u7b49\u7b2c 3 \u5c42\u65b9\u5f0f\u63d0\u4f9b\u6765\u5bbe\u9694\u79bb(IP \u5730\u5740\u6e90\u8fc7\u6ee4)\u3002 message.desc.cluster=\u6bcf\u4e2a\u63d0\u4f9b\u70b9\u4e2d\u5fc5\u987b\u5305\u542b\u4e00\u4e2a\u6216\u591a\u4e2a\u7fa4\u96c6\uff0c\u73b0\u5728\u6211\u4eec\u5c06\u6dfb\u52a0\u7b2c\u4e00\u4e2a\u7fa4\u96c6\u3002\u7fa4\u96c6\u63d0\u4f9b\u4e86\u4e00\u79cd\u7f16\u7ec4\u4e3b\u673a\u7684\u65b9\u6cd5\u3002\u7fa4\u96c6\u4e2d\u7684\u6240\u6709\u4e3b\u673a\u90fd\u5177\u6709\u76f8\u540c\u7684\u786c\u4ef6\uff0c\u8fd0\u884c\u76f8\u540c\u7684\u865a\u62df\u673a\u7ba1\u7406\u7a0b\u5e8f\uff0c\u4f4d\u4e8e\u76f8\u540c\u7684\u5b50\u7f51\u4e2d\uff0c\u5e76\u8bbf\u95ee\u76f8\u540c\u7684\u5171\u4eab\u5b58\u50a8\u3002\u6bcf\u4e2a\u7fa4\u96c6\u7531\u4e00\u4e2a\u6216\u591a\u4e2a\u4e3b\u673a\u4ee5\u53ca\u4e00\u4e2a\u6216\u591a\u4e2a\u4e3b\u5b58\u50a8\u670d\u52a1\u5668\u7ec4\u6210\u3002 -message.desc.host=\u6bcf\u4e2a\u7fa4\u96c6\u4e2d\u5fc5\u987b\u81f3\u5c11\u5305\u542b\u4e00\u4e2a\u4e3b\u673a\u4ee5\u4f9b\u6765\u5bbe VM \u5728\u4e0a\u9762\u8fd0\u884c\uff0c\u73b0\u5728\u6211\u4eec\u5c06\u6dfb\u52a0\u7b2c\u4e00\u4e2a\u4e3b\u673a\u3002\u8981\u4f7f\u4e3b\u673a\u5728 CloudStack \u4e2d\u8fd0\u884c\uff0c\u5fc5\u987b\u5728\u6b64\u4e3b\u673a\u4e0a\u5b89\u88c5\u865a\u62df\u673a\u7ba1\u7406\u7a0b\u5e8f\u8f6f\u4ef6\uff0c\u4e3a\u5176\u5206\u914d\u4e00\u4e2a IP \u5730\u5740\uff0c\u5e76\u786e\u4fdd\u5c06\u5176\u8fde\u63a5\u5230 CloudStack \u7ba1\u7406\u670d\u52a1\u5668\u3002

\u8bf7\u63d0\u4f9b\u4e3b\u673a\u7684 DNS \u6216 IP \u5730\u5740\u3001\u7528\u6237\u540d(\u901a\u5e38\u4e3a root)\u548c\u5bc6\u7801\uff0c\u4ee5\u53ca\u7528\u4e8e\u5bf9\u4e3b\u673a\u8fdb\u884c\u5206\u7c7b\u7684\u4efb\u4f55\u6807\u7b7e\u3002 message.desc.primary.storage=\u6bcf\u4e2a\u7fa4\u96c6\u4e2d\u5fc5\u987b\u5305\u542b\u4e00\u4e2a\u6216\u591a\u4e2a\u4e3b\u5b58\u50a8\u670d\u52a1\u5668\uff0c\u73b0\u5728\u6211\u4eec\u5c06\u6dfb\u52a0\u7b2c\u4e00\u4e2a\u4e3b\u5b58\u50a8\u670d\u52a1\u5668\u3002\u4e3b\u5b58\u50a8\u4e2d\u5305\u542b\u5728\u7fa4\u96c6\u4e2d\u7684\u4e3b\u673a\u4e0a\u8fd0\u884c\u7684\u6240\u6709 VM \u7684\u78c1\u76d8\u5377\u3002\u8bf7\u4f7f\u7528\u5e95\u5c42\u865a\u62df\u673a\u7ba1\u7406\u7a0b\u5e8f\u652f\u6301\u7684\u7b26\u5408\u6807\u51c6\u7684\u534f\u8bae\u3002 message.desc.secondary.storage=\u6bcf\u4e2a\u533a\u57df\u4e2d\u5fc5\u987b\u81f3\u5c11\u5305\u542b\u4e00\u4e2a NFS \u6216\u8f85\u52a9\u5b58\u50a8\u670d\u52a1\u5668\uff0c\u73b0\u5728\u6211\u4eec\u5c06\u6dfb\u52a0\u7b2c\u4e00\u4e2a NFS \u6216\u8f85\u52a9\u5b58\u50a8\u670d\u52a1\u5668\u3002\u8f85\u52a9\u5b58\u50a8\u7528\u4e8e\u5b58\u50a8 VM \u6a21\u677f\u3001ISO \u6620\u50cf\u548c VM \u78c1\u76d8\u5377\u5feb\u7167\u3002\u6b64\u670d\u52a1\u5668\u5fc5\u987b\u5bf9\u533a\u57df\u4e2d\u7684\u6240\u6709\u670d\u52a1\u5668\u53ef\u7528\u3002

\u8bf7\u63d0\u4f9b IP \u5730\u5740\u548c\u5bfc\u51fa\u8def\u5f84\u3002 message.desc.zone=\u533a\u57df\u662f CloudStack \u4e2d\u6700\u5927\u7684\u7ec4\u7ec7\u5355\u4f4d\uff0c\u4e00\u4e2a\u533a\u57df\u901a\u5e38\u4e0e\u4e00\u4e2a\u6570\u636e\u4e2d\u5fc3\u76f8\u5bf9\u5e94\u3002\u533a\u57df\u53ef\u63d0\u4f9b\u7269\u7406\u9694\u79bb\u548c\u5197\u4f59\u3002\u4e00\u4e2a\u533a\u57df\u7531\u4e00\u4e2a\u6216\u591a\u4e2a\u63d0\u4f9b\u70b9\u4ee5\u53ca\u7531\u533a\u57df\u4e2d\u7684\u6240\u6709\u63d0\u4f9b\u70b9\u5171\u4eab\u7684\u4e00\u4e2a\u8f85\u52a9\u5b58\u50a8\u670d\u52a1\u5668\u7ec4\u6210\uff0c\u5176\u4e2d\u6bcf\u4e2a\u63d0\u4f9b\u70b9\u4e2d\u5305\u542b\u591a\u4e2a\u4e3b\u673a\u548c\u4e3b\u5b58\u50a8\u670d\u52a1\u5668\u3002 @@ -1447,7 +1445,6 @@ message.step.3.continue=\u8bf7\u9009\u62e9\u4e00\u79cd\u78c1\u76d8\u65b9\u6848\u message.step.3.desc= message.step.4.continue=\u8bf7\u81f3\u5c11\u9009\u62e9\u4e00\u4e2a\u7f51\u7edc\u4ee5\u7ee7\u7eed message.step.4.desc=\u8bf7\u9009\u62e9\u865a\u62df\u5b9e\u4f8b\u8981\u8fde\u63a5\u5230\u7684\u4e3b\u7f51\u7edc\u3002 -message.storage.traffic=CloudStack \u5185\u90e8\u8d44\u6e90(\u5305\u62ec\u4e0e\u7ba1\u7406\u670d\u52a1\u5668\u901a\u4fe1\u7684\u4efb\u4f55\u7ec4\u4ef6\uff0c\u4f8b\u5982\u4e3b\u673a\u548c CloudStack \u7cfb\u7edf VM)\u4e4b\u95f4\u7684\u6d41\u91cf\u3002\u8bf7\u5728\u6b64\u5904\u914d\u7f6e\u5b58\u50a8\u6d41\u91cf\u3002 message.suspend.project=\u662f\u5426\u786e\u5b9e\u8981\u6682\u505c\u6b64\u9879\u76ee? message.template.desc=\u53ef\u7528\u4e8e\u542f\u52a8 VM \u7684\u64cd\u4f5c\u7cfb\u7edf\u6620\u50cf message.tooltip.dns.1=\u4f9b\u533a\u57df\u4e2d\u7684 VM \u4f7f\u7528\u7684 DNS \u670d\u52a1\u5668\u540d\u79f0\u3002\u533a\u57df\u7684\u516c\u7528 IP \u5730\u5740\u5fc5\u987b\u8def\u7531\u5230\u6b64\u670d\u52a1\u5668\u3002 diff --git a/client/pom.xml b/client/pom.xml index a7c7009ffc2..197ba27975c 100644 --- a/client/pom.xml +++ b/client/pom.xml @@ -85,6 +85,11 @@ cloud-plugin-network-midonet ${project.version} + + org.apache.cloudstack + cloud-plugin-network-internallb + ${project.version} + org.apache.cloudstack cloud-plugin-hypervisor-xen @@ -239,6 +244,11 @@ cloud-plugin-host-anti-affinity ${project.version} + + org.apache.cloudstack + cloud-console-proxy + ${project.version} + install diff --git a/client/tomcatconf/applicationContext.xml.in b/client/tomcatconf/applicationContext.xml.in index 46a3e8656f4..813769b0dda 100644 --- a/client/tomcatconf/applicationContext.xml.in +++ b/client/tomcatconf/applicationContext.xml.in @@ -82,7 +82,7 @@ - + diff --git a/client/tomcatconf/commands.properties.in b/client/tomcatconf/commands.properties.in index 6427546aa5f..32561847f4f 100644 --- a/client/tomcatconf/commands.properties.in +++ b/client/tomcatconf/commands.properties.in @@ -67,7 +67,7 @@ getVMPassword=15 restoreVirtualMachine=15 changeServiceForVirtualMachine=15 scaleVirtualMachine=15 -assignVirtualMachine=1 +assignVirtualMachine=7 migrateVirtualMachine=1 migrateVirtualMachineWithVolume=1 recoverVirtualMachine=7 @@ -127,6 +127,9 @@ deleteVlanIpRange=1 listVlanIpRanges=1 dedicatePublicIpRange=1 releasePublicIpRange=1 +dedicateGuestVlanRange=1 +releaseDedicatedGuestVlanRange=1 +listDedicatedGuestVlanRanges=1 #### address commands associateIpAddress=15 @@ -569,11 +572,22 @@ removeFromGlobalLoadBalancerRule=15 listVMSnapshot=15 createVMSnapshot=15 deleteVMSnapshot=15 -revertToSnapshot=15 +revertToVMSnapshot=15 #### Baremetal commands addBaremetalHost=1 +#### New Load Balancer commands +createLoadBalancer=15 +listLoadBalancers=15 +deleteLoadBalancer=15 + +#Internal Load Balancer Element commands +configureInternalLoadBalancerElement=1 +createInternalLoadBalancerElement=1 +listInternalLoadBalancerElements=1 + + #### Affinity group commands createAffinityGroup=15 deleteAffinityGroup=15 @@ -595,3 +609,12 @@ listCiscoAsa1000vResources=1 createPortableIpRange=1 deletePortableIpRange=1 listPortableIpRanges=1 + +#### Internal LB VM commands +stopInternalLoadBalancerVM=1 +startInternalLoadBalancerVM=1 +listInternalLoadBalancerVMs=1 + +### Network Isolation methods listing +listNetworkIsolationMethods=1 + diff --git a/client/tomcatconf/componentContext.xml.in b/client/tomcatconf/componentContext.xml.in index 7a469816f82..8a45e5fea85 100644 --- a/client/tomcatconf/componentContext.xml.in +++ b/client/tomcatconf/componentContext.xml.in @@ -198,6 +198,7 @@ + @@ -241,6 +242,7 @@ + - + @@ -294,6 +294,7 @@ + @@ -343,6 +344,7 @@ + + + + + + diff --git a/docs/en-US/MidoNet_Plugin_Guide.xml b/docs/en-US/MidoNet_Plugin_Guide.xml new file mode 100644 index 00000000000..86182e60b71 --- /dev/null +++ b/docs/en-US/MidoNet_Plugin_Guide.xml @@ -0,0 +1,52 @@ + + +%BOOK_ENTITIES; + +%xinclude; +]> + + + + + + &PRODUCT; Plugin Guide for the MidoNet Plugin + Apache CloudStack + 4.2.0 + 1 + + + + Plugin Guide for the MidoNet Plugin. + + + + + + + + + + + + + + + + diff --git a/docs/en-US/Release_Notes.xml b/docs/en-US/Release_Notes.xml index cda8d724e9f..dca95d37c16 100644 --- a/docs/en-US/Release_Notes.xml +++ b/docs/en-US/Release_Notes.xml @@ -5113,7 +5113,7 @@ service cloudstack-agent start Start the first Management Server. Do not start any other Management Server nodes yet. - # service cloud-management start + # service cloudstack-management start Wait until the databases are upgraded. Ensure that the database upgrade is complete. After confirmation, start the other Management Servers one at a time by running the same command on each node. @@ -5126,7 +5126,7 @@ service cloudstack-agent start Start all Usage Servers (if they were running on your previous version). Perform this on each Usage Server host. - # service cloud-usage start + # service cloudstack-usage start @@ -5152,7 +5152,7 @@ service cloudstack-agent start Start the agent. - # service cloud-agent start + # service cloudstack-agent start Edit /etc/cloud/agent/agent.properties to change the @@ -5742,7 +5742,7 @@ service cloudstack-agent start Start the first Management Server. Do not start any other Management Server nodes yet. - # service cloud-management start + # service cloudstack-management start Wait until the databases are upgraded. Ensure that the database upgrade is complete. You should see a message like "Complete! Done." After confirmation, start the other Management Servers one at a time by running the same command on each node. @@ -5750,7 +5750,7 @@ service cloudstack-agent start Start all Usage Servers (if they were running on your previous version). Perform this on each Usage Server host. - # service cloud-usage start + # service cloudstack-usage start (KVM only) Additional steps are required for each KVM host. These steps will not @@ -5776,7 +5776,7 @@ service cloudstack-agent start Start the agent. - # service cloud-agent start + # service cloudstack-agent start Copy the contents of the agent.properties file to the new diff --git a/docs/en-US/added-API-commands-4.2.xml b/docs/en-US/added-API-commands-4.2.xml index 34716240657..3abb780663e 100644 --- a/docs/en-US/added-API-commands-4.2.xml +++ b/docs/en-US/added-API-commands-4.2.xml @@ -63,5 +63,59 @@ more IDs separated by comma); type (string); olderthan (yyyy-mm-dd format). The response parameters are: true, false + + createGlobalLoadBalancerRule + Creates a GSLB rule. The request parameters are name (the name of the global load + balancer rule); domain name ( the preferred domain name for the service); lb algorithm (the + algorithm used to load balance the traffic across the zones); session persistence (source IP + and HTTP cookie); account name; and domain Id. + + + assignToGlobalLoadBalancerRule + Assigns a load balancing rule or list of load balancing rules to GSLB. The request + parameters are: id (the UUID of global load balancer rule); loadbalancerrulelist (the list + load balancer rules that will be assigned to global load balancer rule. These are second + tier load balancing rules created with createLoadBalancerRule API. Weight is optional, the + default is 1). + + + removeFromGlobalLoadBalancerRule + Removes a load balancer rule association with global load balancer rule. The request + parameters are id (the UUID of global load balancer rule); loadbalancerrulelist (the list + load balancer rules that will be assigned to global load balancer rule). + + + deleteGlobalLoadBalancerRule + Deletes a global load balancer rule. The request parameters is: id (the unique ID of the + global load balancer rule). + + + listGlobalLoadBalancerRule + Lists load balancer rules. + The request parameters are: account (lists resources by account. Use with the domainid + parameter); domainid (lists only resources belonging to the domain specified); id (the + unique ID of the global load balancer rule); isrecursive (defaults to false; but if true, + lists all the resources from the parent specified by the domainid); keyword (lists by + keyword); listall (if set to false, lists only resources belonging to the command's caller; + if set to true, lists resources that the caller is authorized to see. Default value is + false); page; pagesize; projectid (lists objects by project); regionid ; tags (lists + resources by tags: key/value pairs). + + + updateGlobalLoadBalancerRule + Updates global load balancer rules. + The request parameters are: id (the unique ID of the global load balancer rule); account + (lists resources by account. Use with the domainid parameter); description (the description + of the load balancer rule); domainid (lists only resources belonging to the domain + specified); gslblbmethod (the load balancer algorithm that is used to distributed traffic + across the zones participating in global server load balancing, if not specified defaults to + round robin); gslbstickysessionmethodname (the session sticky method; if not specified + defaults to sourceip); isrecursive (defaults to false, but if true, lists all resources from + the parent specified by the domainid till leaves); keyword (lists by keyword); listall (if + set to false, list only those resources belonging to the command's caller; if set to true, + lists resources that the caller is authorized to see. Default value is false); page; + pagesize; projectid (lists objects by project); regionid; tags (lists resources by tags: + key/value pairs) + diff --git a/docs/en-US/aws-ec2-configuration.xml b/docs/en-US/aws-ec2-configuration.xml index dd7732ebced..d6dd2b5467e 100644 --- a/docs/en-US/aws-ec2-configuration.xml +++ b/docs/en-US/aws-ec2-configuration.xml @@ -35,7 +35,7 @@ Be sure you have included the Amazon default service offering, m1.small. As well as any EC2 instance types that you will use. If you did not already do so when you set the configuration parameter in step , restart the Management Server. - # service cloud-management restart + # service cloudstack-management restart The following sections provides details to perform these steps diff --git a/docs/en-US/change-database-password.xml b/docs/en-US/change-database-password.xml index 0ab52675e3c..b0021a42a13 100644 --- a/docs/en-US/change-database-password.xml +++ b/docs/en-US/change-database-password.xml @@ -29,8 +29,8 @@ Before changing the password, you'll need to stop CloudStack's management server and the usage engine if you've deployed that component. -# service cloud-management stop -# service cloud-usage stop +# service cloudstack-management stop +# service cloudstack-usage stop @@ -68,7 +68,7 @@ db.usage.password=ENC(encrypted_password_from_above) After copying the new password over, you can now start CloudStack (and the usage engine, if necessary). - # service cloud-management start + # service cloudstack-management start # service cloud-usage start diff --git a/docs/en-US/changed-API-commands-4.2.xml b/docs/en-US/changed-API-commands-4.2.xml index 26f10ff6037..2dd5a3b05ea 100644 --- a/docs/en-US/changed-API-commands-4.2.xml +++ b/docs/en-US/changed-API-commands-4.2.xml @@ -29,6 +29,15 @@ + + createVlanIpRange + + No new parameter has been added. However, the current functionality has been + extended to add guest IPs from a different subnet in shared networks in a Basic zone. + Ensure that you provide netmask and gateway if you are adding guest IPs from a + different subnet. + + updateResourceLimit @@ -113,8 +122,10 @@ removelan (removes the specified VLAN range) - The removevlan and vlan parameters can be used together. If the VLAN range that you are trying - to remove is in use, the operation will not succeed. + + The removevlan and vlan parameters can be used together. If the VLAN range that + you are trying to remove is in use, the operation will not succeed. + diff --git a/docs/en-US/citrix-xenserver-installation.xml b/docs/en-US/citrix-xenserver-installation.xml index 2cd39a41368..a5118d751d4 100644 --- a/docs/en-US/citrix-xenserver-installation.xml +++ b/docs/en-US/citrix-xenserver-installation.xml @@ -610,7 +610,7 @@ master-password=[your password] Restart the Management Server and Usage Server. You only need to do this once for all clusters. - # service cloud-management start + # service cloudstack-management start # service cloud-usage start diff --git a/docs/en-US/configure-usage-server.xml b/docs/en-US/configure-usage-server.xml index 173f4a5306d..83bed07b349 100644 --- a/docs/en-US/configure-usage-server.xml +++ b/docs/en-US/configure-usage-server.xml @@ -32,8 +32,8 @@ In Actions, click the Edit icon. Type the desired value and click the Save icon. Restart the Management Server (as usual with any global configuration change) and also the Usage Server: - # service cloud-management restart -# service cloud-usage restart + # service cloudstack-management restart +# service cloudstack-usage restart The following table shows the global configuration settings that control the behavior of the Usage Server. diff --git a/docs/en-US/creating-network-offerings.xml b/docs/en-US/creating-network-offerings.xml index 2b23ca89a1f..260751ea079 100644 --- a/docs/en-US/creating-network-offerings.xml +++ b/docs/en-US/creating-network-offerings.xml @@ -253,7 +253,7 @@ mode. In this mode, network resources are allocated only when the first virtual machine starts in the network. When conservative mode is off, the public IP can only be used for a single service. For example, a public IP used for a port forwarding rule cannot be - used for defining other services, such as SaticNAT or load balancing. When the conserve + used for defining other services, such as StaticNAT or load balancing. When the conserve mode is on, you can define more than one service on the same public IP. If StaticNAT is enabled, irrespective of the status of the conserve mode, no port diff --git a/docs/en-US/database-replication.xml b/docs/en-US/database-replication.xml index 718c34959da..bb144579ddf 100644 --- a/docs/en-US/database-replication.xml +++ b/docs/en-US/database-replication.xml @@ -121,14 +121,14 @@ mysql> start slave; Failover This will provide for a replicated database that can be used to implement manual failover for the Management Servers. &PRODUCT; failover from one MySQL instance to another is performed by the administrator. In the event of a database failure you should: - Stop the Management Servers (via service cloud-management stop). + Stop the Management Servers (via service cloudstack-management stop). Change the replica's configuration to be a master and restart it. Ensure that the replica's port 3306 is open to the Management Servers. - Make a change so that the Management Server uses the new database. The simplest process here is to put the IP address of the new database server into each Management Server's /etc/cloud/management/db.properties. + Make a change so that the Management Server uses the new database. The simplest process here is to put the IP address of the new database server into each Management Server's /etc/cloudstack/management/db.properties. Restart the Management Servers: -# service cloud-management start +# service cloudstack-management start diff --git a/docs/en-US/elastic-ip.xml b/docs/en-US/elastic-ip.xml index b09d37d43e1..8ecbd75be70 100644 --- a/docs/en-US/elastic-ip.xml +++ b/docs/en-US/elastic-ip.xml @@ -21,16 +21,31 @@
About Elastic IP Elastic IP (EIP) addresses are the IP addresses that are associated with an account, and act - as static IP addresses. The account owner has complete control over the Elastic IP addresses - that belong to the account. You can allocate an Elastic IP to a VM of your choice from the EIP - pool of your account. Later if required you can reassign the IP address to a different VM. This - feature is extremely helpful during VM failure. Instead of replacing the VM which is down, the - IP address can be reassigned to a new VM in your account. Elastic IP service provides Static NAT - (1:1) service in an EIP-enabled basic zone. The default network offering, + as static IP addresses. The account owner has the complete control over the Elastic IP addresses + that belong to the account. As an account owner, you can allocate an Elastic IP to a VM of your + choice from the EIP pool of your account. Later if required you can reassign the IP address to a + different VM. This feature is extremely helpful during VM failure. Instead of replacing the VM + which is down, the IP address can be reassigned to a new VM in your account. + Similar to the public IP address, Elastic IP addresses are mapped to their associated + private IP addresses by using StaticNAT. The EIP service is equipped with StaticNAT (1:1) + service in an EIP-enabled basic zone. The default network offering, DefaultSharedNetscalerEIPandELBNetworkOffering, provides your network with EIP and ELB network - services if a NetScaler device is deployed in your zone. Similar to the public IP address, - Elastic IP addresses are also mapped to their associated private IP addresses by using Stactic - NAT. + services if a NetScaler device is deployed in your zone. Consider the following illustration for + more details. + + + + + + eip-ns-basiczone.png: Elastic IP in a NetScaler-enabled Basic Zone. + + + In the illustration, a NetScaler appliance is the default entry or exit point for the + &PRODUCT; instances, and firewall is the default entry or exit point for the rest of the data + center. Netscaler provides LB services and staticNAT service to the guest networks. The guest + traffic in the pods and the Management Server are on different subnets / VLANs. The policy-based + routing in the data center core switch sends the public traffic through the NetScaler, whereas + the rest of the data center goes through the firewall. The EIP work flow is as follows: @@ -48,7 +63,6 @@ supported by NetScaler, in which the source IP address is replaced in the packets generated by a VM in the private network with the public IP address. - This default public IP will be released in two cases: @@ -68,12 +82,12 @@ - However, for the deployments where public IPs are limited resources, you have the - flexibility to choose not to allocate a public IP by default. You can use the Associate Public - IP option to turn on or off the automatic public IP assignment in the EIP-enabled Basic zones. - If you turn off the automatic public IP assignment while creating a network offering, only a - private IP is assigned to a VM when the VM is deployed with that network offering. Later, the - user can acquire an IP for the VM and enable static NAT. + For the deployments where public IPs are limited resources, you have the flexibility to + choose not to allocate a public IP by default. You can use the Associate Public IP option to + turn on or off the automatic public IP assignment in the EIP-enabled Basic zones. If you turn + off the automatic public IP assignment while creating a network offering, only a private IP is + assigned to a VM when the VM is deployed with that network offering. Later, the user can acquire + an IP for the VM and enable static NAT. For more information on the Associate Public IP option, see . For more information on the Associate Public IP option, see the @@ -83,7 +97,6 @@ continue to get both public IP and private by default, irrespective of the network offering configuration. - New deployments which use the default shared network offering with EIP and ELB services to create a shared network in the Basic zone will continue allocating public IPs to each user VM. diff --git a/docs/en-US/external-firewalls-and-load-balancers.xml b/docs/en-US/external-firewalls-and-load-balancers.xml index b947daf7361..42ecacf9f75 100644 --- a/docs/en-US/external-firewalls-and-load-balancers.xml +++ b/docs/en-US/external-firewalls-and-load-balancers.xml @@ -29,5 +29,6 @@ xmlns:xi="http://www.w3.org/2001/XInclude"/> +
diff --git a/docs/en-US/gslb.xml b/docs/en-US/gslb.xml new file mode 100644 index 00000000000..23033317381 --- /dev/null +++ b/docs/en-US/gslb.xml @@ -0,0 +1,499 @@ + + +%BOOK_ENTITIES; +]> + + +
+ Global Server Load Balancing Support + &PRODUCT; supports Global Server Load Balancing (GSLB) functionalities to provide business + continuity, and enable seamless resource movement within a &PRODUCT; environment. &PRODUCT; + achieve this by extending its functionality of integrating with NetScaler Application Delivery + Controller (ADC), which also provides various GSLB capabilities, such as disaster recovery and + load balancing. The DNS redirection technique is used to achieve GSLB in &PRODUCT;. + In order to support this functionality, region level services and service provider are + introduced. A new service 'GSLB' is introduced as a region level service. The GSLB service + provider is introduced that will provider the GSLB service. Currently, NetScaler is the + supported GSLB provider in &PRODUCT;. GSLB functionality works in an Active-Active data center + environment. +
+ About Global Server Load Balancing + Global Server Load Balancing (GSLB) is an extension of load balancing functionality, which + is highly efficient in avoiding downtime. Based on the nature of deployment, GSLB represents a + set of technologies that is used for various purposes, such as load sharing, disaster + recovery, performance, and legal obligations. With GSLB, workloads can be distributed across + multiple data centers situated at geographically separated locations. GSLB can also provide an + alternate location for accessing a resource in the event of a failure, or to provide a means + of shifting traffic easily to simplify maintenance, or both. +
+ Components of GSLB + A typical GSLB environment is comprised of the following components: + + + GSLB Site: In &PRODUCT;terminology, GSLB sites are + represented by zones that are mapped to data centers, each of which has various network + appliances. Each GSLB site is managed by a NetScaler appliance that is local to that + site. Each of these appliances treats its own site as the local site and all other + sites, managed by other appliances, as remote sites. It is the central entity in a GSLB + deployment, and is represented by a name and an IP address. + + + GSLB Services: A GSLB service is typically + represented by a load balancing or content switching virtual server. In a GSLB + environment, you can have a local as well as remote GSLB services. A local GSLB service + represents a local load balancing or content switching virtual server. A remote GSLB + service is the one configured at one of the other sites in the GSLB setup. At each site + in the GSLB setup, you can create one local GSLB service and any number of remote GSLB + services. + + + GSLB Virtual Servers: A GSLB virtual server refers + to one or more GSLB services and balances traffic between traffic across the VMs in + multiple zones by using the &PRODUCT; functionality. It evaluates the configured GSLB + methods or algorithms to select a GSLB service to which to send the client requests. One + or more virtual servers from different zones are bound to the GSLB virtual server. GSLB + virtual server does not have a public IP associated with it, instead it will have a FQDN + DNS name. + + + Load Balancing or Content Switching Virtual + Servers: According to Citrix NetScaler terminology, a load balancing or + content switching virtual server represents one or many servers on the local network. + Clients send their requests to the load balancing or content switching virtual server’s + virtual IP (VIP) address, and the virtual server balances the load across the local + servers. After a GSLB virtual server selects a GSLB service representing either a local + or a remote load balancing or content switching virtual server, the client sends the + request to that virtual server’s VIP address. + + + DNS VIPs: DNS virtual IP represents a load + balancing DNS virtual server on the GSLB service provider. The DNS requests for domains + for which the GSLB service provider is authoritative can be sent to a DNS VIP. + + + Authoritative DNS: ADNS (Authoritative Domain Name + Server) is a service that provides actual answer to DNS queries, such as web site IP + address. In a GSLB environment, an ADNS service responds only to DNS requests for + domains for which the GSLB service provider is authoritative. When an ADNS service is + configured, the service provider owns that IP address and advertises it. When you create + an ADNS service, the NetScaler responds to DNS queries on the configured ADNS service IP + and port. + + +
+
+ How Does GSLB Works in &PRODUCT;? + Global server load balancing is used to manage the traffic flow to a web site hosted on + two separate zones that ideally are in different geographic locations. The following is an + illustration of how GLSB functionality is provided in &PRODUCT;: An organization, xyztelco, + has set up a public cloud that spans two zones, Zone-1 and Zone-2, across geographically + separated data centers that are managed by &PRODUCT;. Tenant-A of the cloud launches a + highly available solution by using xyztelco cloud. For that purpose, they launch two + instances each in both the zones: VM1 and VM2 in Zone-1 and VM5 and VM6 in Zone-2. Tenant-A + acquires a public IP, IP-1 in Zone-1, and configures a load balancer rule to load balance + the traffic between VM1 and VM2 instances. &PRODUCT; orchestrates setting up a virtual + server on the LB service provider in Zone-1. Virtual server 1 that is set up on the LB + service provider in Zone-1 represents a publicly accessible virtual server that client + reaches at IP-1. The client traffic to virtual server 1 at IP-1 will be load balanced across + VM1 and VM2 instances. + Tenant-A acquires another public IP, IP-2 in Zone-2 and sets up a load balancer rule to + load balance the traffic between VM5 and VM6 instances. Similarly in Zone-2, &PRODUCT; + orchestrates setting up a virtual server on the LB service provider. Virtual server 2 that + is setup on the LB service provider in Zone-2 represents a publicly accessible virtual + server that client reaches at IP-2. The client traffic that reaches virtual server 2 at IP-2 + is load balanced across VM5 and VM6 instances. At this point Tenant-A has the service + enabled in both the zones, but has no means to set up a disaster recovery plan if one of the + zone fails. Additionally, there is no way for Tenant-A to load balance the traffic + intelligently to one of the zones based on load, proximity and so on. The cloud + administrator of xyztelco provisions a GSLB service provider to both the zones. A GSLB + provider is typically an ADC that has the ability to act as an ADNS (Authoritative Domain + Name Server) and has the mechanism to monitor health of virtual servers both at local and + remote sites. The cloud admin enables GSLB as a service to the tenants that use zones 1 and + 2. + + + + + + gslb.png: GSLB architecture + + + Tenant-A wishes to leverage the GSLB service provided by the xyztelco cloud. Tenant-A + configures a GSLB rule to load balance traffic across virtual server 1 at Zone-1 and virtual + server 2 at Zone-2. The domain name is provided as A.xyztelco.com. &PRODUCT; orchestrates + setting up GSLB virtual server 1 on the GSLB service provider at Zone-1. &PRODUCT; binds + virtual server 1 of Zone-1 and virtual server 2 of Zone-2 to GLSB virtual server 1. GSLB + virtual server 1 is configured to start monitoring the health of virtual server 1 and 2 in + Zone-1. &PRODUCT; will also orchestrate setting up GSLB virtual server 2 on GSLB service + provider at Zone-2. &PRODUCT; will bind virtual server 1 of Zone-1 and virtual server 2 of + Zone-2 to GLSB virtual server 2. GSLB virtual server 2 is configured to start monitoring the + health of virtual server 1 and 2. &PRODUCT; will bind the domain A.xyztelco.com to both the + GSLB virtual server 1 and 2. At this point, Tenant-A service will be globally reachable at + A.xyztelco.com. The private DNS server for the domain xyztelcom.com is configured by the + admin out-of-band to resolve the domain A.xyztelco.com to the GSLB providers at both the + zones, which are configured as ADNS for the domain A.xyztelco.com. A client when sends a DNS + request to resolve A.xyztelcom.com, will eventually get DNS delegation to the address of + GSLB providers at zone 1 and 2. A client DNS request will be received by the GSLB provider. + The GSLB provider, depending on the domain for which it needs to resolve, will pick up the + GSLB virtual server associated with the domain. Depending on the health of the virtual + servers being load balanced, DNS request for the domain will be resolved to the public IP + associated with the selected virtual server. +
+
+
+ Configuring GSLB + A GSLB deployment is the logical collection of GSLB virtual server, GSLB service, LB + virtual server, service, domain, and ADNS service. To create a GSLB site, you must configure + load balancing in the zone. You must create GSLB vservers and GSLB services for each site. You + must bind GSLB services to GSLB vservers. You must then create an ADNS service that provides + the IP address of the best performing site to the client's request. A GSLB vserver is an + entity that performs load balancing for the domains bound to it by returning the IP address of + the best GSLB service. A GSLB service is a representation of the load balancing/content + switching vserver. An LB vserver load balances incoming traffic by identifying the best + server, then directs traffic to the corresponding service. It can also load-balance external + DNS name servers. Services are entities that represent the servers. The domain is the domain + name for which the system is the authoritative DNS server. By creating an ADNS service, the + system can be configured as an authoritative DNS server. + To configure GSLB in your cloud environment, as a cloud administrator you must perform the + following. + To configure such a GSLB setup, you must first configure a standard load balancing setup + for each zone. This enables you to balance load across the different servers in each zone in + the region. Then, configure both NetScaler appliances that you plan to add to each zone as + authoritative DNS (ADNS) servers. Next, create a GSLB site for each zone, configure GSLB + virtual servers for each site, create GLSB services, and bind the GSLB services to the GSLB + virtual servers. Finally, bind the domain to the GSLB virtual servers. The GSLB configurations + on the two appliances at the two different sites are identical, although each sites + load-balancing configuration is specific to that site. + Perform the following as a cloud administrator. As per the above example, the + administrator of xyztelco is the one who sets up GSLB: + + + In the cloud.dns.name global parameter, specify the DNS name of your tenant's cloud + that make use of the GSLB service. + + + On the NetScaler side, configure GSLB as given in Configuring Global Server Load Balancing (GSLB): + + + Configuring a standard load balancing setup. + + + Configure Authoritative DNS, as explained in Configuring an Authoritative DNS Service. + + + Configure a GSLB site with site name formed from the domain name details. + For more information, see Configuring a Basic GSLB Site. + + + Configure a GSLB virtual server. + For more information, see Configuring a GSLB Virtual Server. + + + Configure a GSLB service for each virtual server. + For more information, see Configuring a GSLB Service. + + + Bind the GSLB services to the GSLB virtual server. + For more information, see Binding GSLB Services to a GSLB Virtual Server. + + + Bind domain name to GSLB virtual server. Domain name is obtained from the domain + details. + For more information, see Binding a Domain to a GSLB Virtual Server. + + + + + In each zone that are participating in GSLB, add GSLB-enabled NetScaler device. + For more information, see . + + + As a domain administrator/ user perform the following: + + + Add a GSLB rule on both the sites. + See . + + + Assign load balancer rules. + See . + + +
+ Prerequisites and Guidelines + + + The GSLB functionality is supported both Basic and Advanced zones. + + + GSLB is added as a new network service. + + + GSLB service provider can be added to a physical network in a zone. + + + The admin is allowed to enable or disable GSLB functionality at region level. + + + The admin is allowed to configure a zone as GSLB capable or enabled. + A zone shall be considered as GSLB capable only if a GSLB service provider is + provisioned in the zone. + + + When users have VMs deployed in multiple availability zones which are GSLB enabled, + they can use the GSLB functionality to load balance traffic across the VMs in multiple + zones. + + + The users can use GSLB to load balance across the VMs across zones in a region only + if the admin has enabled GSLB in that region. + + + The users can load balance traffic across the availability zones in the same region + or different regions. + + + The admin can configure DNS name for the entire cloud. + + + The users can specify an unique name across the cloud for a globally load balanced + service. The provided name is used as the domain name under the DNS name associated with + the cloud. + The user-provided name along with the admin-provided DNS name is used to produce a + globally resolvable FQDN for the globally load balanced service of the user. For + example, if the admin has configured xyztelco.com as the DNS name for the cloud, and + user specifies 'foo' for the GSLB virtual service, then the FQDN name of the GSLB + virtual service is foo.xyztelco.com. + + + While setting up GSLB, users can select a load balancing method, such as round + robin, for using across the zones that are part of GSLB. + + + The user shall be able to set weight to zone-level virtual server. Weight shall be + considered by the load balancing method for distributing the traffic. + + + The GSLB functionality shall support session persistence, where series of client + requests for particular domain name is sent to a virtual server on the same zone. + Statistics is collected from each GSLB virtual server. + + +
+
+ Enabling GSLB in NetScaler + In each zone, add GSLB-enabled NetScaler device for load balancing. + + + Log in as administrator to the &PRODUCT; UI. + + + In the left navigation bar, click Infrastructure. + + + In Zones, click View More. + + + Choose the zone you want to work with. + + + Click the Physical Network tab, then click the name of the physical network. + + + In the Network Service Providers node of the diagram, click Configure. + You might have to scroll down to see this. + + + Click NetScaler. + + + Click Add NetScaler device and provide the following: + For NetScaler: + + + IP Address: The IP address of the SRX. + + + Username/Password: The authentication + credentials to access the device. &PRODUCT; uses these credentials to access the + device. + + + Type: The type of device that is being added. + It could be F5 Big Ip Load Balancer, NetScaler VPX, NetScaler MPX, or NetScaler SDX. + For a comparison of the NetScaler types, see the &PRODUCT; Administration + Guide. + + + Public interface: Interface of device that is + configured to be part of the public network. + + + Private interface: Interface of device that is + configured to be part of the private network. + + + GSLB service: Select this option. + + + GSLB service Public IP: The public IP address + of the NAT translator for a GSLB service that is on a private network. + + + GSLB service Private IP: The private IP of the + GSLB service. + + + Number of Retries. Number of times to attempt a + command on the device before considering the operation failed. Default is 2. + + + Capacity: The number of networks the device can + handle. + + + Dedicated: When marked as dedicated, this + device will be dedicated to a single account. When Dedicated is checked, the value + in the Capacity field has no significance implicitly, its value is 1. + + + + + Click OK. + + +
+
+ Adding a GSLB Rule + + + Log in to the &PRODUCT; UI as a domain administrator or user. + + + In the left navigation pane, click Region. + + + Select the region for which you want to create a GSLB rule. + + + In the Details tab, click View GSLB. + + + Click Add GSLB. + The Add GSLB page is displayed as follows: + + + + + + gslb-add.png: adding a gslb rule + + + + + Specify the following: + + + Name: Name for the GSLB rule. + + + Description: (Optional) A short description of + the GSLB rule that can be displayed to users. + + + GSLB Domain Name: A preferred domain name for + the service. + + + Algorithm: (Optional) The algorithm to use to + load balance the traffic across the zones. The options are Round Robin, Least + Connection, and Proximity. + + + Service Type: The transport protocol to use for + GSLB. The options are TCP and UDP. + + + Domain: (Optional) The domain for which you + want to create the GSLB rule. + + + Account: (Optional) The account on which you + want to apply the GSLB rule. + + + + + Click OK to confirm. + + +
+
+ Assigning Load Balancing Rules to GSLB + + + + Log in to the &PRODUCT; UI as a domain administrator or user. + + + In the left navigation pane, click Region. + + + Select the region for which you want to create a GSLB rule. + + + In the Details tab, click View GSLB. + + + Select the desired GSLB. + + + Click view assigned load balancing. + + + Click assign more load balancing. + + + Select the load balancing rule you have created for the zone. + + + Click OK to confirm. + + +
+
+
+ Known Limitation + Currently, &PRODUCT; does not support orchestration of services across the zones. The + notion of services and service providers in region are to be introduced. +
+
diff --git a/docs/en-US/guest-ip-ranges.xml b/docs/en-US/guest-ip-ranges.xml index 1f8c8a1a4b1..b3ebd761394 100644 --- a/docs/en-US/guest-ip-ranges.xml +++ b/docs/en-US/guest-ip-ranges.xml @@ -21,8 +21,12 @@ specific language governing permissions and limitations under the License. --> -
- Guest IP Ranges - The IP ranges for guest network traffic are set on a per-account basis by the user. This allows the users to configure their network in a fashion that will enable VPN linking between their guest network and their clients. + Guest IP Ranges + The IP ranges for guest network traffic are set on a per-account basis by the user. This + allows the users to configure their network in a fashion that will enable VPN linking between + their guest network and their clients. + In shared networks in Basic zone and Security Group-enabled Advanced networks, you will have + the flexibility to add multiple guest IP ranges from different subnets. You can add or remove + one IP range at a time.
diff --git a/docs/en-US/hypervisor-host-install-agent.xml b/docs/en-US/hypervisor-host-install-agent.xml index e5bfa37fb6d..41b6719bbaf 100644 --- a/docs/en-US/hypervisor-host-install-agent.xml +++ b/docs/en-US/hypervisor-host-install-agent.xml @@ -27,8 +27,8 @@ To manage KVM instances on the host &PRODUCT; uses a Agent. This Agent communicates with the Management server and controls all the instances on the host. First we start by installing the agent: In RHEL or CentOS: - $ yum install cloud-agent + $ yum install cloudstack-agent In Ubuntu: - $ apt-get install cloud-agent + $ apt-get install cloudstack-agent The host is now ready to be added to a cluster. This is covered in a later section, see . It is recommended that you continue to read the documentation before adding the host! - \ No newline at end of file + diff --git a/docs/en-US/hypervisor-host-install-libvirt.xml b/docs/en-US/hypervisor-host-install-libvirt.xml index f3ff090463c..d3d6b9b4e80 100644 --- a/docs/en-US/hypervisor-host-install-libvirt.xml +++ b/docs/en-US/hypervisor-host-install-libvirt.xml @@ -24,7 +24,7 @@
Install and Configure libvirt - &PRODUCT; uses libvirt for managing virtual machines. Therefore it is vital that libvirt is configured correctly. Libvirt is a dependency of cloud-agent and should already be installed. + &PRODUCT; uses libvirt for managing virtual machines. Therefore it is vital that libvirt is configured correctly. Libvirt is a dependency of cloudstack-agent and should already be installed. In order to have live migration working libvirt has to listen for unsecured TCP connections. We also need to turn off libvirts attempt to use Multicast DNS advertising. Both of these settings are in /etc/libvirt/libvirtd.conf diff --git a/docs/en-US/images/add-gslb.png b/docs/en-US/images/add-gslb.png new file mode 100644 index 00000000000..827a913093b Binary files /dev/null and b/docs/en-US/images/add-gslb.png differ diff --git a/docs/en-US/images/eip-ns-basiczone.png b/docs/en-US/images/eip-ns-basiczone.png index 315ff55dab9..bc88570531a 100644 Binary files a/docs/en-US/images/eip-ns-basiczone.png and b/docs/en-US/images/eip-ns-basiczone.png differ diff --git a/docs/en-US/images/gslb.png b/docs/en-US/images/gslb.png new file mode 100644 index 00000000000..9f13580c560 Binary files /dev/null and b/docs/en-US/images/gslb.png differ diff --git a/docs/en-US/increase-management-server-max-memory.xml b/docs/en-US/increase-management-server-max-memory.xml index 16d18e75830..51c8724a020 100644 --- a/docs/en-US/increase-management-server-max-memory.xml +++ b/docs/en-US/increase-management-server-max-memory.xml @@ -28,7 +28,7 @@ Edit the Tomcat configuration file:/etc/cloud/management/tomcat6.conf Change the command-line parameter -XmxNNNm to a higher value of N.For example, if the current value is -Xmx128m, change it to -Xmx1024m or higher. - To put the new setting into effect, restart the Management Server.# service cloud-management restart + To put the new setting into effect, restart the Management Server.# service cloudstack-management restart For more information about memory issues, see "FAQ: Memory" at Tomcat Wiki.
diff --git a/docs/en-US/install-usage-server.xml b/docs/en-US/install-usage-server.xml index 9dde5523f5e..ffd748d758e 100644 --- a/docs/en-US/install-usage-server.xml +++ b/docs/en-US/install-usage-server.xml @@ -52,7 +52,7 @@ Once installed, start the Usage Server with the following command. -# service cloud-usage start +# service cloudstack-usage start diff --git a/docs/en-US/libcloud-examples.xml b/docs/en-US/libcloud-examples.xml new file mode 100644 index 00000000000..d2db5269eb9 --- /dev/null +++ b/docs/en-US/libcloud-examples.xml @@ -0,0 +1,75 @@ + + +%BOOK_ENTITIES; +]> + + + +
+ Apache Libcloud + There are many tools available to interface with the &PRODUCT; API. Apache Libcloud is one of those. In this section + we provide a basic example of how to use Libcloud with &PRODUCT;. It assumes that you have access to a &PRODUCT; endpoint and that you have the API access key and secret key of a user. + To install Libcloud refer to the libcloud website. If you are familiar with Pypi simply do: + pip install apache-libcloud + You should see the following output: + +pip install apache-libcloud +Downloading/unpacking apache-libcloud + Downloading apache-libcloud-0.12.4.tar.bz2 (376kB): 376kB downloaded + Running setup.py egg_info for package apache-libcloud + +Installing collected packages: apache-libcloud + Running setup.py install for apache-libcloud + +Successfully installed apache-libcloud +Cleaning up... + + + You can then open a Python interactive shell, create an instance of a &PRODUCT; driver and call the available methods via the libcloud API. + + + >> from libcloud.compute.types import Provider +>>> from libcloud.compute.providers import get_driver +>>> Driver = get_driver(Provider.CLOUDSTACK) +>>> apikey='plgWJfZK4gyS3mOMTVmjUVg-X-jlWlnfaUJ9GAbBbf9EdM-kAYMmAiLqzzq1ElZLYq_u38zCm0bewzGUdP66mg' +>>> secretkey='VDaACYb0LV9eNjTetIOElcVQkvJck_J_QljX_FcHRj87ZKiy0z0ty0ZsYBkoXkY9b7eq1EhwJaw7FF3akA3KBQ' +>>> host='http://localhost:8080' +>>> path='/client/api' +>>> conn=Driver(apikey,secretkey,secure='False',host='localhost:8080',path=path) +>>> conn=Driver(key=apikey,secret=secretkey,secure=False,host='localhost',port='8080',path=path) +>>> conn.list_images() +[] +>>> conn.list_sizes() +[, , ] +>>> images=conn.list_images() +>>> offerings=conn.list_sizes() +>>> node=conn.create_node(name='toto',image=images[0],size=offerings[0]) +>>> help(node) +>>> node.get_uuid() +'b1aa381ba1de7f2d5048e248848993d5a900984f' +>>> node.name +u'toto' +]]> + + + One of the interesting use cases of Libcloud is that you can use multiple Cloud Providers, such as AWS, Rackspace, OpenNebula, vCloud and so on. You can then create Driver instances to each of these clouds and create your own multi cloud application. + +
diff --git a/docs/en-US/lxc-install.xml b/docs/en-US/lxc-install.xml index a80c18afdd6..40f6a0aaa69 100644 --- a/docs/en-US/lxc-install.xml +++ b/docs/en-US/lxc-install.xml @@ -74,9 +74,9 @@ To manage LXC instances on the host &PRODUCT; uses a Agent. This Agent communicates with the Management server and controls all the instances on the host. First we start by installing the agent: In RHEL or CentOS: - $ yum install cloud-agent + $ yum install cloudstack-agent In Ubuntu: - $ apt-get install cloud-agent + $ apt-get install cloudstack-agent Next step is to update the Agent configuration setttings. The settings are in /etc/cloudstack/agent/agent.properties diff --git a/docs/en-US/networks.xml b/docs/en-US/networks.xml index c2090d2b1b4..8a7405a63ac 100644 --- a/docs/en-US/networks.xml +++ b/docs/en-US/networks.xml @@ -36,7 +36,8 @@ - + diff --git a/docs/en-US/plugin-midonet-about.xml b/docs/en-US/plugin-midonet-about.xml new file mode 100644 index 00000000000..dd9b3ad08e0 --- /dev/null +++ b/docs/en-US/plugin-midonet-about.xml @@ -0,0 +1,27 @@ + + +%BOOK_ENTITIES; + +%xinclude; +]> + + + The MidoNet Plugin + + + diff --git a/docs/en-US/plugin-midonet-features.xml b/docs/en-US/plugin-midonet-features.xml new file mode 100644 index 00000000000..f242d63d0ee --- /dev/null +++ b/docs/en-US/plugin-midonet-features.xml @@ -0,0 +1,57 @@ + + +%BOOK_ENTITIES; + +%xinclude; +]> + +
+ Features of the MidoNet Plugin + + + + In &PRODUCT; 4.2.0 only the KVM hypervisor is supported for use in combination with MidoNet. + + + + In &PRODUCT; release 4.2.0 this plugin supports several services in the Advanced Isolated network mode. + + + + When tenants create new isolated layer 3 networks, instead of spinning up extra Virtual Router VMs, the relevant L3 elements (routers etc) are created in the MidoNet virtual topology by making the appropriate calls to the MidoNet API. Instead of using VLANs, isolation is provided by MidoNet. + + + + Aside from the above service (Connectivity), several extra features are supported in the 4.2.0 release: + + + + DHCP + Firewall (ingress) + Source NAT + Static NAT + Port Forwarding + + + + The plugin has been tested with MidoNet version 12.12. (Caddo). + + + + +
diff --git a/docs/en-US/plugin-midonet-introduction.xml b/docs/en-US/plugin-midonet-introduction.xml new file mode 100644 index 00000000000..7793ecbc884 --- /dev/null +++ b/docs/en-US/plugin-midonet-introduction.xml @@ -0,0 +1,26 @@ + + +%BOOK_ENTITIES; + +%xinclude; +]> + +
+ Introduction to the MidoNet Plugin + The MidoNet plugin allows &PRODUCT; to use the MidoNet virtualized networking solution as a provider for &PRODUCT; networks and services. For more information on MidoNet and how it works, see http://www.midokura.com/midonet/. +
diff --git a/docs/en-US/plugin-midonet-preparations.xml b/docs/en-US/plugin-midonet-preparations.xml new file mode 100644 index 00000000000..cf78774ec2b --- /dev/null +++ b/docs/en-US/plugin-midonet-preparations.xml @@ -0,0 +1,90 @@ + + +%BOOK_ENTITIES; + +%xinclude; +]> + +
+ Prerequisites + + In order to use the MidoNet plugin, the compute hosts must be running the MidoNet Agent, and the MidoNet API server must be available. Please consult the MidoNet User Guide for more information. The following section describes the &PRODUCT; side setup. + + + + &PRODUCT; needs to have at least one physical network with the isolation method set to "MIDO". This network should be enabled for the Guest and Public traffic types. + + + + Next, we need to set the following &PRODUCT; settings under "Global Settings" in the UI: + +&PRODUCT; settings + + + + Setting Name + Description + Example + + + + + midonet.apiserver.address + Specify the address at which the Midonet API server can be contacted + http://192.168.1.144:8081/midolmanj-mgmt + + + midonet.providerrouter.id + Specifies the UUID of the Midonet provider router + d7c5e6a3-e2f4-426b-b728-b7ce6a0448e5 + + + +
+
+ + + + We also want MidoNet to take care of public traffic, so in componentContext.xml we need to replace this line: + + ]]> + + + With this: + + ]]> + + + +
+ + + + On the compute host, MidoNet takes advantage of per-traffic type VIF driver support in &PRODUCT; KVM. + + + In agent.properties, we set the following to make MidoNet take care of Guest and Public traffic: + +libvirt.vif.driver.Guest=com.cloud.network.resource.MidoNetVifDriver +libvirt.vif.driver.Public=com.cloud.network.resource.MidoNetVifDriver + + This is explained further in MidoNet User Guide. + + + +
diff --git a/docs/en-US/plugin-midonet-provider.xml b/docs/en-US/plugin-midonet-provider.xml new file mode 100644 index 00000000000..904828caecd --- /dev/null +++ b/docs/en-US/plugin-midonet-provider.xml @@ -0,0 +1,39 @@ + + +%BOOK_ENTITIES; + +%xinclude; +]> + +
+ Enabling the MidoNet service provider via the API + + To enable via the API, use the following API calls: + addNetworkServiceProvider + + name = "MidoNet" + physicalnetworkid = <the uuid of the physical network> + + updateNetworkServiceProvider + + id = <the provider uuid returned by the previous call> + state = "Enabled" + + + +
\ No newline at end of file diff --git a/docs/en-US/plugin-midonet-revisions.xml b/docs/en-US/plugin-midonet-revisions.xml new file mode 100644 index 00000000000..73def2325b5 --- /dev/null +++ b/docs/en-US/plugin-midonet-revisions.xml @@ -0,0 +1,45 @@ + + +%BOOK_ENTITIES; +]> + + + + + Revision History + + + + 0-0 + Wed Mar 13 2013 + + Dave + Cahill + dcahill@midokura.com + + + + Documentation created for 4.2.0 version of the MidoNet Plugin + + + + + + diff --git a/docs/en-US/plugin-midonet-ui.xml b/docs/en-US/plugin-midonet-ui.xml new file mode 100644 index 00000000000..8ee9850e5a7 --- /dev/null +++ b/docs/en-US/plugin-midonet-ui.xml @@ -0,0 +1,65 @@ + + +%BOOK_ENTITIES; + +%xinclude; +]> + +
+ Enabling the MidoNet service provider via the UI + To allow &PRODUCT; to use the MidoNet Plugin the network service provider needs to be enabled on the physical network. + + + + The steps to enable via the UI are as follows: + + + In the left navbar, click Infrastructure + + + + In Zones, click View All + + + + Click the name of the Zone on which you are setting up MidoNet + + + + Click the Physical Network tab + + + + Click the Name of the Network on which you are setting up MidoNet + + + + Click Configure on the Network Service Providers box + + + + Click on the name MidoNet + + + + Click the Enable Provider button in the Network tab + + + + +
diff --git a/docs/en-US/plugin-midonet-usage.xml b/docs/en-US/plugin-midonet-usage.xml new file mode 100644 index 00000000000..a314581dcda --- /dev/null +++ b/docs/en-US/plugin-midonet-usage.xml @@ -0,0 +1,29 @@ + + +%BOOK_ENTITIES; + +%xinclude; +]> + + + Using the MidoNet Plugin + + + + + diff --git a/docs/en-US/set-database-buffer-pool-size.xml b/docs/en-US/set-database-buffer-pool-size.xml index 1c7503101ca..8265ae544f2 100644 --- a/docs/en-US/set-database-buffer-pool-size.xml +++ b/docs/en-US/set-database-buffer-pool-size.xml @@ -26,7 +26,7 @@ Set Database Buffer Pool Size It is important to provide enough memory space for the MySQL database to cache data and indexes: - Edit the Tomcat configuration file:/etc/my.cnf + Edit the MySQL configuration file:/etc/my.cnf Insert the following line in the [mysqld] section, below the datadir line. Use a value that is appropriate for your situation. We recommend setting the buffer pool at 40% of RAM if MySQL is on the same server as the management server or 70% of RAM if MySQL has a dedicated server. The following example assumes a dedicated server with 1024M of RAM. innodb_buffer_pool_size=700M Restart the MySQL service.# service mysqld restart diff --git a/docs/en-US/set-global-project-resource-limits.xml b/docs/en-US/set-global-project-resource-limits.xml index d91942ad8db..8ec13259051 100644 --- a/docs/en-US/set-global-project-resource-limits.xml +++ b/docs/en-US/set-global-project-resource-limits.xml @@ -76,7 +76,7 @@
Restart the Management Server. - # service cloud-management restart + # service cloudstack-management restart
diff --git a/docs/en-US/set-projects-creator-permissions.xml b/docs/en-US/set-projects-creator-permissions.xml index 9b272f6bc7e..dd9cfe95d56 100644 --- a/docs/en-US/set-projects-creator-permissions.xml +++ b/docs/en-US/set-projects-creator-permissions.xml @@ -56,7 +56,7 @@
Restart the Management Server. - # service cloud-management restart + # service cloudstack-management restart diff --git a/docs/en-US/set-up-invitations.xml b/docs/en-US/set-up-invitations.xml index c1303cf5e92..180c041e87e 100644 --- a/docs/en-US/set-up-invitations.xml +++ b/docs/en-US/set-up-invitations.xml @@ -89,7 +89,7 @@
Restart the Management Server: - service cloud-management restart + service cloudstack-management restart diff --git a/docs/en-US/signing-api-calls-python.xml b/docs/en-US/signing-api-calls-python.xml new file mode 100644 index 00000000000..a2f897f6df1 --- /dev/null +++ b/docs/en-US/signing-api-calls-python.xml @@ -0,0 +1,101 @@ + + +%BOOK_ENTITIES; +]> + + + +
+ How to sign an API call with Python + To illustrate the procedure used to sign API calls we present a step by step interactive session + using Python. + + First import the required modules: + + + >> import urllib2 +>>> import urllib +>>> import hashlib +>>> import hmac +>>> import base64 + ]]> + + + Define the endpoint of the Cloud, the command that you want to execute and the keys of the user. + + >> baseurl='http://localhost:8080/client/api?' +>>> request={} +>>> request['command']='listUsers' +>>> request['response']='json' +>>> request['apikey']='plgWJfZK4gyS3mOMTVmjUVg-X-jlWlnfaUJ9GAbBbf9EdM-kAYMmAiLqzzq1ElZLYq_u38zCm0bewzGUdP66mg' +>>> secretkey='VDaACYb0LV9eNjTetIOElcVQkvJck_J_QljX_FcHRj87ZKiy0z0ty0ZsYBkoXkY9b7eq1EhwJaw7FF3akA3KBQ' + ]]> + + Build the request string: + + >> request_str='&'.join(['='.join([k,urllib.quote_plus(request[k])]) for k in request.keys()]) +>>> request_str +'apikey=plgWJfZK4gyS3mOMTVmjUVg-X-jlWlnfaUJ9GAbBbf9EdM-kAYMmAiLqzzq1ElZLYq_u38zCm0bewzGUdP66mg&command=listUsers&response=json' + ]]> + + + Compute the signature with hmac, do a 64 bit encoding and a url encoding: + + >> sig_str='&'.join(['='.join([k.lower(),urllib.quote_plus(request[k].lower().replace('+','%20'))])for k in sorted(request.iterkeys())]) +>>> sig_str +'apikey=plgwjfzk4gys3momtvmjuvg-x-jlwlnfauj9gabbbf9edm-kaymmailqzzq1elzlyq_u38zcm0bewzgudp66mg&command=listusers&response=json' +>>> sig=hmac.new(secretkey,sig_str,hashlib.sha1) +>>> sig + +>>> sig=hmac.new(secretkey,sig_str,hashlib.sha1).digest() +>>> sig +'M:]\x0e\xaf\xfb\x8f\xf2y\xf1p\x91\x1e\x89\x8a\xa1\x05\xc4A\xdb' +>>> sig=base64.encodestring(hmac.new(secretkey,sig_str,hashlib.sha1).digest()) +>>> sig +'TTpdDq/7j/J58XCRHomKoQXEQds=\n' +>>> sig=base64.encodestring(hmac.new(secretkey,sig_str,hashlib.sha1).digest()).strip() +>>> sig +'TTpdDq/7j/J58XCRHomKoQXEQds=' +>>> sig=urllib.quote_plus(base64.encodestring(hmac.new(secretkey,sig_str,hashlib.sha1).digest()).strip()) + ]]> + + + Finally, build the entire string and do an http GET: + + >> req=baseurl+request_str+'&signature='+sig +>>> req +'http://localhost:8080/client/api?apikey=plgWJfZK4gyS3mOMTVmjUVg-X-jlWlnfaUJ9GAbBbf9EdM-kAYMmAiLqzzq1ElZLYq_u38zCm0bewzGUdP66mg&command=listUsers&response=json&signature=TTpdDq%2F7j%2FJ58XCRHomKoQXEQds%3D' +>>> res=urllib2.urlopen(req) +>>> res.read() +'{ "listusersresponse" : { "count":3 ,"user" : [ {"id":"7ed6d5da-93b2-4545-a502-23d20b48ef2a","username":"admin","firstname":"admin","lastname":"cloud","created":"2012-07-05T12:18:27-0700","state":"enabled","account":"admin","accounttype":1,"domainid":"8a111e58-e155-4482-93ce-84efff3c7c77","domain":"ROOT","apikey":"plgWJfZK4gyS3mOMTVmjUVg-X-jlWlnfaUJ9GAbBbf9EdM-kAYMmAiLqzzq1ElZLYq_u38zCm0bewzGUdP66mg","secretkey":"VDaACYb0LV9eNjTetIOElcVQkvJck_J_QljX_FcHRj87ZKiy0z0ty0ZsYBkoXkY9b7eq1EhwJaw7FF3akA3KBQ","accountid":"7548ac03-af1d-4c1c-9064-2f3e2c0eda0d"}, {"id":"1fea6418-5576-4989-a21e-4790787bbee3","username":"runseb","firstname":"foobar","lastname":"goa","email":"joe@smith.com","created":"2013-04-10T16:52:06-0700","state":"enabled","account":"admin","accounttype":1,"domainid":"8a111e58-e155-4482-93ce-84efff3c7c77","domain":"ROOT","apikey":"Xhsb3MewjJQaXXMszRcLvQI9_NPy_UcbDj1QXikkVbDC9MDSPwWdtZ1bUY1H7JBEYTtDDLY3yuchCeW778GkBA","secretkey":"gIsgmi8C5YwxMHjX5o51pSe0kqs6JnKriw0jJBLceY5bgnfzKjL4aM6ctJX-i1ddQIHJLbLJDK9MRzsKk6xZ_w","accountid":"7548ac03-af1d-4c1c-9064-2f3e2c0eda0d"}, {"id":"52f65396-183c-4473-883f-a37e7bb93967","username":"toto","firstname":"john","lastname":"smith","email":"john@smith.com","created":"2013-04-23T04:27:22-0700","state":"enabled","account":"admin","accounttype":1,"domainid":"8a111e58-e155-4482-93ce-84efff3c7c77","domain":"ROOT","apikey":"THaA6fFWS_OmvU8od201omxFC8yKNL_Hc5ZCS77LFCJsRzSx48JyZucbUul6XYbEg-ZyXMl_wuEpECzK-wKnow","secretkey":"O5ywpqJorAsEBKR_5jEvrtGHfWL1Y_j1E4Z_iCr8OKCYcsPIOdVcfzjJQ8YqK0a5EzSpoRrjOFiLsG0hQrYnDA","accountid":"7548ac03-af1d-4c1c-9064-2f3e2c0eda0d"} ] } }' + ]]> + + +
diff --git a/docs/en-US/signing-api-requests.xml b/docs/en-US/signing-api-requests.xml index 581b32a41ba..fc8773b92c8 100644 --- a/docs/en-US/signing-api-requests.xml +++ b/docs/en-US/signing-api-requests.xml @@ -57,4 +57,7 @@ http://localhost:8080/client/api?command=deployVirtualMachine&serviceOfferingId=1&diskOfferingId=1&templateId=2&zoneId=4&apiKey=miVr6X7u6bN_sdahOBpjNejPgEsT35eXq-jB8CG20YI3yaxXcgpyuaIRmFI_EJTVwZ0nUkkJbPmY3y2bciKwFQ&signature=Lxx1DM40AjcXU%2FcaiK8RAP0O1hU%3D + + + diff --git a/docs/en-US/stop-restart-management-server.xml b/docs/en-US/stop-restart-management-server.xml index 5c1bcecbc00..74a687c23a1 100644 --- a/docs/en-US/stop-restart-management-server.xml +++ b/docs/en-US/stop-restart-management-server.xml @@ -26,9 +26,9 @@ The root administrator will need to stop and restart the Management Server from time to time. For example, after changing a global configuration parameter, a restart is required. If you have multiple Management Server nodes, restart all of them to put the new parameter value into effect consistently throughout the cloud.. To stop the Management Server, issue the following command at the operating system prompt on the Management Server node: - # service cloud-management stop + # service cloudstack-management stop To start the Management Server: - # service cloud-management start + # service cloudstack-management start To stop the Management Server: - # service cloud-management stop + # service cloudstack-management stop diff --git a/docs/en-US/sys-offering-sysvm.xml b/docs/en-US/sys-offering-sysvm.xml index cccf3e04796..563dd6f5ebf 100644 --- a/docs/en-US/sys-offering-sysvm.xml +++ b/docs/en-US/sys-offering-sysvm.xml @@ -65,7 +65,7 @@ Restart &PRODUCT; Management Server. Restarting is required because the default offerings are loaded into the memory at startup. - service cloud-management restart + service cloudstack-management restart Destroy the existing CPVM or SSVM offerings and wait for them to be recreated. The new diff --git a/docs/en-US/tools.xml b/docs/en-US/tools.xml index db6a510d593..8cddf28014f 100644 --- a/docs/en-US/tools.xml +++ b/docs/en-US/tools.xml @@ -27,4 +27,5 @@ + diff --git a/docs/en-US/zone-add.xml b/docs/en-US/zone-add.xml index 4f6606fce03..3ca5789cd99 100644 --- a/docs/en-US/zone-add.xml +++ b/docs/en-US/zone-add.xml @@ -42,7 +42,7 @@ Restart the Management Server. - # service cloud-management restart + # service cloudstack-management restart Refresh the &PRODUCT; UI browser tab and log back in. diff --git a/docs/publican-plugin-midonet.cfg b/docs/publican-plugin-midonet.cfg new file mode 100644 index 00000000000..6558d99e897 --- /dev/null +++ b/docs/publican-plugin-midonet.cfg @@ -0,0 +1,28 @@ +# Publican configuration file for CloudStack Complete Documentation Set +# Contains all technical docs except release notes +# Config::Simple 4.58 +# Tue May 29 00:57:27 2012 +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information# +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +xml_lang: en-US +type: Book +docname: MidoNet_Plugin_Guide +brand: cloudstack +chunk_first: 1 +chunk_section_depth: 1 +condition: install diff --git a/engine/api/pom.xml b/engine/api/pom.xml index 1e8e8c3eb38..1b8f26c2320 100644 --- a/engine/api/pom.xml +++ b/engine/api/pom.xml @@ -30,11 +30,6 @@ cloud-api ${project.version} - - org.apache.cloudstack - cloud-framework-api - ${project.version} - org.apache.cxf cxf-bundle-jaxrs @@ -55,6 +50,11 @@ cloud-framework-rest ${project.version} + + org.apache.cloudstack + cloud-framework-ipc + ${project.version} + install diff --git a/engine/pom.xml b/engine/pom.xml index 1a3d896d50d..169425ae14e 100644 --- a/engine/pom.xml +++ b/engine/pom.xml @@ -29,8 +29,6 @@ install - src - test api diff --git a/core/src/com/cloud/alert/AlertVO.java b/engine/schema/src/com/cloud/alert/AlertVO.java similarity index 100% rename from core/src/com/cloud/alert/AlertVO.java rename to engine/schema/src/com/cloud/alert/AlertVO.java diff --git a/server/src/com/cloud/alert/dao/AlertDao.java b/engine/schema/src/com/cloud/alert/dao/AlertDao.java similarity index 100% rename from server/src/com/cloud/alert/dao/AlertDao.java rename to engine/schema/src/com/cloud/alert/dao/AlertDao.java diff --git a/server/src/com/cloud/alert/dao/AlertDaoImpl.java b/engine/schema/src/com/cloud/alert/dao/AlertDaoImpl.java similarity index 100% rename from server/src/com/cloud/alert/dao/AlertDaoImpl.java rename to engine/schema/src/com/cloud/alert/dao/AlertDaoImpl.java diff --git a/core/src/com/cloud/capacity/CapacityVO.java b/engine/schema/src/com/cloud/capacity/CapacityVO.java similarity index 100% rename from core/src/com/cloud/capacity/CapacityVO.java rename to engine/schema/src/com/cloud/capacity/CapacityVO.java diff --git a/server/src/com/cloud/capacity/dao/CapacityDao.java b/engine/schema/src/com/cloud/capacity/dao/CapacityDao.java similarity index 97% rename from server/src/com/cloud/capacity/dao/CapacityDao.java rename to engine/schema/src/com/cloud/capacity/dao/CapacityDao.java index 0132f69cd50..04466f4adb2 100755 --- a/server/src/com/cloud/capacity/dao/CapacityDao.java +++ b/engine/schema/src/com/cloud/capacity/dao/CapacityDao.java @@ -41,5 +41,5 @@ public interface CapacityDao extends GenericDao { List listCapacitiesGroupedByLevelAndType(Integer capacityType, Long zoneId, Long podId, Long clusterId, int level, Long limit); void updateCapacityState(Long dcId, Long podId, Long clusterId, Long hostId, String capacityState); - List listClustersCrossingThreshold(short capacityType, Long zoneId, Float disableThreshold, long computeRequested); + List listClustersCrossingThreshold(short capacityType, Long zoneId, String ConfigName, long computeRequested); } diff --git a/server/src/com/cloud/capacity/dao/CapacityDaoImpl.java b/engine/schema/src/com/cloud/capacity/dao/CapacityDaoImpl.java similarity index 95% rename from server/src/com/cloud/capacity/dao/CapacityDaoImpl.java rename to engine/schema/src/com/cloud/capacity/dao/CapacityDaoImpl.java index c3d98173a5c..0b9ff1a5ece 100755 --- a/server/src/com/cloud/capacity/dao/CapacityDaoImpl.java +++ b/engine/schema/src/com/cloud/capacity/dao/CapacityDaoImpl.java @@ -115,12 +115,20 @@ public class CapacityDaoImpl extends GenericDaoBase implements private static final String LIST_CAPACITY_GROUP_BY_CLUSTER_TYPE_PART2 = " GROUP BY cluster_id, capacity_type order by percent desc limit "; private static final String UPDATE_CAPACITY_STATE = "UPDATE `cloud`.`op_host_capacity` SET capacity_state = ? WHERE "; - private static final String LIST_CLUSTERS_CROSSING_THRESHOLD = "SELECT cluster_id " + - "FROM (SELECT cluster_id, ( (sum(capacity.used_capacity) + sum(capacity.reserved_capacity) + ?)/sum(total_capacity) ) ratio "+ - "FROM `cloud`.`op_host_capacity` capacity "+ - "WHERE capacity.data_center_id = ? AND capacity.capacity_type = ? AND capacity.total_capacity > 0 "+ - "GROUP BY cluster_id) tmp " + - "WHERE tmp.ratio > ? "; + + private static final String LIST_CLUSTERS_CROSSING_THRESHOLD = "SELECT clusterList.cluster_id " + + "FROM ( SELECT cluster.cluster_id cluster_id, ( (sum(cluster.used) + sum(cluster.reserved) + ?)/sum(cluster.total) ) ratio, cluster.configValue value " + + "FROM ( SELECT capacity.cluster_id cluster_id, capacity.used_capacity used, capacity.reserved_capacity reserved, capacity.total_capacity total, " + + "CASE (SELECT count(*) FROM `cloud`.`cluster_details` details WHERE details.cluster_id = capacity.cluster_id AND details.name = ? ) " + + "WHEN 1 THEN ( SELECT details.value FROM `cloud`.`cluster_details` details WHERE details.cluster_id = capacity.cluster_id AND details.name = ? ) " + + "ELSE ( SELECT config.value FROM `cloud`.`configuration` config WHERE config.name = ?) " + + "END configValue " + + "FROM `cloud`.`op_host_capacity` capacity " + + "WHERE capacity.data_center_id = ? AND capacity.capacity_type = ? AND capacity.total_capacity > 0) cluster " + + + "GROUP BY cluster.cluster_id) clusterList " + + "WHERE clusterList.ratio > clusterList.value; "; + public CapacityDaoImpl() { @@ -146,20 +154,22 @@ public class CapacityDaoImpl extends GenericDaoBase implements } @Override - public List listClustersCrossingThreshold(short capacityType, Long zoneId, Float disableThreshold, long compute_requested){ + public List listClustersCrossingThreshold(short capacityType, Long zoneId, String configName, long compute_requested){ Transaction txn = Transaction.currentTxn(); PreparedStatement pstmt = null; List result = new ArrayList(); StringBuilder sql = new StringBuilder(LIST_CLUSTERS_CROSSING_THRESHOLD); - - + // during listing the clusters that cross the threshold + // we need to check with disabled thresholds of each cluster if not defined at cluster consider the global value try { pstmt = txn.prepareAutoCloseStatement(sql.toString()); pstmt.setLong(1,compute_requested); - pstmt.setShort(2,capacityType); - pstmt.setFloat(3,disableThreshold); - pstmt.setLong(4,zoneId); + pstmt.setString(2, configName); + pstmt.setString(3, configName); + pstmt.setString(4, configName); + pstmt.setLong(5,zoneId); + pstmt.setShort(6,capacityType); ResultSet rs = pstmt.executeQuery(); while (rs.next()) { diff --git a/core/src/com/cloud/certificate/CertificateVO.java b/engine/schema/src/com/cloud/certificate/CertificateVO.java similarity index 100% rename from core/src/com/cloud/certificate/CertificateVO.java rename to engine/schema/src/com/cloud/certificate/CertificateVO.java diff --git a/server/src/com/cloud/certificate/dao/CertificateDao.java b/engine/schema/src/com/cloud/certificate/dao/CertificateDao.java similarity index 100% rename from server/src/com/cloud/certificate/dao/CertificateDao.java rename to engine/schema/src/com/cloud/certificate/dao/CertificateDao.java diff --git a/server/src/com/cloud/certificate/dao/CertificateDaoImpl.java b/engine/schema/src/com/cloud/certificate/dao/CertificateDaoImpl.java similarity index 100% rename from server/src/com/cloud/certificate/dao/CertificateDaoImpl.java rename to engine/schema/src/com/cloud/certificate/dao/CertificateDaoImpl.java diff --git a/server/src/com/cloud/cluster/ClusterInvalidSessionException.java b/engine/schema/src/com/cloud/cluster/ClusterInvalidSessionException.java similarity index 100% rename from server/src/com/cloud/cluster/ClusterInvalidSessionException.java rename to engine/schema/src/com/cloud/cluster/ClusterInvalidSessionException.java diff --git a/server/src/com/cloud/cluster/ManagementServerHostPeerVO.java b/engine/schema/src/com/cloud/cluster/ManagementServerHostPeerVO.java similarity index 100% rename from server/src/com/cloud/cluster/ManagementServerHostPeerVO.java rename to engine/schema/src/com/cloud/cluster/ManagementServerHostPeerVO.java diff --git a/server/src/com/cloud/cluster/ManagementServerHostVO.java b/engine/schema/src/com/cloud/cluster/ManagementServerHostVO.java similarity index 100% rename from server/src/com/cloud/cluster/ManagementServerHostVO.java rename to engine/schema/src/com/cloud/cluster/ManagementServerHostVO.java diff --git a/server/src/com/cloud/cluster/agentlb/HostTransferMapVO.java b/engine/schema/src/com/cloud/cluster/agentlb/HostTransferMapVO.java similarity index 100% rename from server/src/com/cloud/cluster/agentlb/HostTransferMapVO.java rename to engine/schema/src/com/cloud/cluster/agentlb/HostTransferMapVO.java diff --git a/server/src/com/cloud/cluster/agentlb/dao/HostTransferMapDao.java b/engine/schema/src/com/cloud/cluster/agentlb/dao/HostTransferMapDao.java similarity index 100% rename from server/src/com/cloud/cluster/agentlb/dao/HostTransferMapDao.java rename to engine/schema/src/com/cloud/cluster/agentlb/dao/HostTransferMapDao.java diff --git a/server/src/com/cloud/cluster/agentlb/dao/HostTransferMapDaoImpl.java b/engine/schema/src/com/cloud/cluster/agentlb/dao/HostTransferMapDaoImpl.java similarity index 100% rename from server/src/com/cloud/cluster/agentlb/dao/HostTransferMapDaoImpl.java rename to engine/schema/src/com/cloud/cluster/agentlb/dao/HostTransferMapDaoImpl.java diff --git a/server/src/com/cloud/cluster/dao/ManagementServerHostDao.java b/engine/schema/src/com/cloud/cluster/dao/ManagementServerHostDao.java similarity index 100% rename from server/src/com/cloud/cluster/dao/ManagementServerHostDao.java rename to engine/schema/src/com/cloud/cluster/dao/ManagementServerHostDao.java diff --git a/server/src/com/cloud/cluster/dao/ManagementServerHostDaoImpl.java b/engine/schema/src/com/cloud/cluster/dao/ManagementServerHostDaoImpl.java similarity index 100% rename from server/src/com/cloud/cluster/dao/ManagementServerHostDaoImpl.java rename to engine/schema/src/com/cloud/cluster/dao/ManagementServerHostDaoImpl.java diff --git a/server/src/com/cloud/cluster/dao/ManagementServerHostPeerDao.java b/engine/schema/src/com/cloud/cluster/dao/ManagementServerHostPeerDao.java similarity index 100% rename from server/src/com/cloud/cluster/dao/ManagementServerHostPeerDao.java rename to engine/schema/src/com/cloud/cluster/dao/ManagementServerHostPeerDao.java diff --git a/server/src/com/cloud/cluster/dao/ManagementServerHostPeerDaoImpl.java b/engine/schema/src/com/cloud/cluster/dao/ManagementServerHostPeerDaoImpl.java similarity index 100% rename from server/src/com/cloud/cluster/dao/ManagementServerHostPeerDaoImpl.java rename to engine/schema/src/com/cloud/cluster/dao/ManagementServerHostPeerDaoImpl.java diff --git a/core/src/com/cloud/configuration/ConfigurationVO.java b/engine/schema/src/com/cloud/configuration/ConfigurationVO.java similarity index 100% rename from core/src/com/cloud/configuration/ConfigurationVO.java rename to engine/schema/src/com/cloud/configuration/ConfigurationVO.java diff --git a/core/src/com/cloud/configuration/ResourceCountVO.java b/engine/schema/src/com/cloud/configuration/ResourceCountVO.java similarity index 100% rename from core/src/com/cloud/configuration/ResourceCountVO.java rename to engine/schema/src/com/cloud/configuration/ResourceCountVO.java diff --git a/core/src/com/cloud/configuration/ResourceLimitVO.java b/engine/schema/src/com/cloud/configuration/ResourceLimitVO.java similarity index 100% rename from core/src/com/cloud/configuration/ResourceLimitVO.java rename to engine/schema/src/com/cloud/configuration/ResourceLimitVO.java diff --git a/server/src/com/cloud/configuration/dao/ConfigurationDao.java b/engine/schema/src/com/cloud/configuration/dao/ConfigurationDao.java similarity index 100% rename from server/src/com/cloud/configuration/dao/ConfigurationDao.java rename to engine/schema/src/com/cloud/configuration/dao/ConfigurationDao.java diff --git a/server/src/com/cloud/configuration/dao/ConfigurationDaoImpl.java b/engine/schema/src/com/cloud/configuration/dao/ConfigurationDaoImpl.java similarity index 100% rename from server/src/com/cloud/configuration/dao/ConfigurationDaoImpl.java rename to engine/schema/src/com/cloud/configuration/dao/ConfigurationDaoImpl.java diff --git a/server/src/com/cloud/configuration/dao/ResourceCountDao.java b/engine/schema/src/com/cloud/configuration/dao/ResourceCountDao.java similarity index 100% rename from server/src/com/cloud/configuration/dao/ResourceCountDao.java rename to engine/schema/src/com/cloud/configuration/dao/ResourceCountDao.java diff --git a/server/src/com/cloud/configuration/dao/ResourceCountDaoImpl.java b/engine/schema/src/com/cloud/configuration/dao/ResourceCountDaoImpl.java similarity index 100% rename from server/src/com/cloud/configuration/dao/ResourceCountDaoImpl.java rename to engine/schema/src/com/cloud/configuration/dao/ResourceCountDaoImpl.java diff --git a/server/src/com/cloud/configuration/dao/ResourceLimitDao.java b/engine/schema/src/com/cloud/configuration/dao/ResourceLimitDao.java similarity index 100% rename from server/src/com/cloud/configuration/dao/ResourceLimitDao.java rename to engine/schema/src/com/cloud/configuration/dao/ResourceLimitDao.java diff --git a/server/src/com/cloud/configuration/dao/ResourceLimitDaoImpl.java b/engine/schema/src/com/cloud/configuration/dao/ResourceLimitDaoImpl.java similarity index 100% rename from server/src/com/cloud/configuration/dao/ResourceLimitDaoImpl.java rename to engine/schema/src/com/cloud/configuration/dao/ResourceLimitDaoImpl.java diff --git a/server/src/com/cloud/dc/AccountVlanMapVO.java b/engine/schema/src/com/cloud/dc/AccountVlanMapVO.java similarity index 100% rename from server/src/com/cloud/dc/AccountVlanMapVO.java rename to engine/schema/src/com/cloud/dc/AccountVlanMapVO.java diff --git a/server/src/com/cloud/dc/ClusterDetailsDao.java b/engine/schema/src/com/cloud/dc/ClusterDetailsDao.java similarity index 100% rename from server/src/com/cloud/dc/ClusterDetailsDao.java rename to engine/schema/src/com/cloud/dc/ClusterDetailsDao.java diff --git a/server/src/com/cloud/dc/ClusterDetailsDaoImpl.java b/engine/schema/src/com/cloud/dc/ClusterDetailsDaoImpl.java similarity index 92% rename from server/src/com/cloud/dc/ClusterDetailsDaoImpl.java rename to engine/schema/src/com/cloud/dc/ClusterDetailsDaoImpl.java index 4c8591870bd..d14e0e42af2 100755 --- a/server/src/com/cloud/dc/ClusterDetailsDaoImpl.java +++ b/engine/schema/src/com/cloud/dc/ClusterDetailsDaoImpl.java @@ -50,9 +50,17 @@ public class ClusterDetailsDaoImpl extends GenericDaoBase sc = DetailSearch.create(); + // This is temporary fix to support list/update configuration api for cpu and memory overprovisioning ratios + if(name.equalsIgnoreCase("cpu.overprovisioning.factor")) { + name = "cpuOvercommitRatio"; + } + if (name.equalsIgnoreCase("mem.overprovisioning.factor")) { + name = "memoryOvercommitRatio"; + } sc.setParameters("clusterId", clusterId); sc.setParameters("name", name); + ClusterDetailsVO detail = findOneIncludingRemovedBy(sc); if("password".equals(name) && detail != null){ detail.setValue(DBEncryptionUtil.decrypt(detail.getValue())); diff --git a/server/src/com/cloud/dc/ClusterDetailsVO.java b/engine/schema/src/com/cloud/dc/ClusterDetailsVO.java similarity index 100% rename from server/src/com/cloud/dc/ClusterDetailsVO.java rename to engine/schema/src/com/cloud/dc/ClusterDetailsVO.java diff --git a/server/src/com/cloud/dc/ClusterVO.java b/engine/schema/src/com/cloud/dc/ClusterVO.java similarity index 100% rename from server/src/com/cloud/dc/ClusterVO.java rename to engine/schema/src/com/cloud/dc/ClusterVO.java diff --git a/server/src/com/cloud/dc/ClusterVSMMapVO.java b/engine/schema/src/com/cloud/dc/ClusterVSMMapVO.java similarity index 100% rename from server/src/com/cloud/dc/ClusterVSMMapVO.java rename to engine/schema/src/com/cloud/dc/ClusterVSMMapVO.java diff --git a/server/src/com/cloud/dc/DataCenterIpAddressVO.java b/engine/schema/src/com/cloud/dc/DataCenterIpAddressVO.java similarity index 100% rename from server/src/com/cloud/dc/DataCenterIpAddressVO.java rename to engine/schema/src/com/cloud/dc/DataCenterIpAddressVO.java diff --git a/server/src/com/cloud/dc/DataCenterLinkLocalIpAddressVO.java b/engine/schema/src/com/cloud/dc/DataCenterLinkLocalIpAddressVO.java similarity index 100% rename from server/src/com/cloud/dc/DataCenterLinkLocalIpAddressVO.java rename to engine/schema/src/com/cloud/dc/DataCenterLinkLocalIpAddressVO.java diff --git a/server/src/com/cloud/dc/DataCenterVO.java b/engine/schema/src/com/cloud/dc/DataCenterVO.java similarity index 100% rename from server/src/com/cloud/dc/DataCenterVO.java rename to engine/schema/src/com/cloud/dc/DataCenterVO.java diff --git a/server/src/com/cloud/dc/DataCenterVnetVO.java b/engine/schema/src/com/cloud/dc/DataCenterVnetVO.java similarity index 90% rename from server/src/com/cloud/dc/DataCenterVnetVO.java rename to engine/schema/src/com/cloud/dc/DataCenterVnetVO.java index 52d7ad2067b..9bae132fb16 100755 --- a/server/src/com/cloud/dc/DataCenterVnetVO.java +++ b/engine/schema/src/com/cloud/dc/DataCenterVnetVO.java @@ -56,6 +56,9 @@ public class DataCenterVnetVO implements InternalIdentity { @Column(name="reservation_id") protected String reservationId; + + @Column(name="account_vnet_map_id") + protected Long accountGuestVlanMapId; public Date getTakenAt() { return takenAt; @@ -103,6 +106,14 @@ public class DataCenterVnetVO implements InternalIdentity { public long getPhysicalNetworkId() { return physicalNetworkId; } + + public void setAccountGuestVlanMapId(Long accountGuestVlanMapId) { + this.accountGuestVlanMapId = accountGuestVlanMapId; + } + + public Long getAccountGuestVlanMapId() { + return accountGuestVlanMapId; + } protected DataCenterVnetVO() { } diff --git a/server/src/com/cloud/dc/DcDetailVO.java b/engine/schema/src/com/cloud/dc/DcDetailVO.java similarity index 100% rename from server/src/com/cloud/dc/DcDetailVO.java rename to engine/schema/src/com/cloud/dc/DcDetailVO.java diff --git a/server/src/com/cloud/dc/HostPodVO.java b/engine/schema/src/com/cloud/dc/HostPodVO.java similarity index 100% rename from server/src/com/cloud/dc/HostPodVO.java rename to engine/schema/src/com/cloud/dc/HostPodVO.java diff --git a/server/src/com/cloud/dc/PodCluster.java b/engine/schema/src/com/cloud/dc/PodCluster.java similarity index 100% rename from server/src/com/cloud/dc/PodCluster.java rename to engine/schema/src/com/cloud/dc/PodCluster.java diff --git a/server/src/com/cloud/dc/PodVlanMapVO.java b/engine/schema/src/com/cloud/dc/PodVlanMapVO.java similarity index 100% rename from server/src/com/cloud/dc/PodVlanMapVO.java rename to engine/schema/src/com/cloud/dc/PodVlanMapVO.java diff --git a/server/src/com/cloud/dc/PodVlanVO.java b/engine/schema/src/com/cloud/dc/PodVlanVO.java similarity index 100% rename from server/src/com/cloud/dc/PodVlanVO.java rename to engine/schema/src/com/cloud/dc/PodVlanVO.java diff --git a/server/src/com/cloud/dc/StorageNetworkIpAddressVO.java b/engine/schema/src/com/cloud/dc/StorageNetworkIpAddressVO.java similarity index 100% rename from server/src/com/cloud/dc/StorageNetworkIpAddressVO.java rename to engine/schema/src/com/cloud/dc/StorageNetworkIpAddressVO.java diff --git a/server/src/com/cloud/dc/StorageNetworkIpRangeVO.java b/engine/schema/src/com/cloud/dc/StorageNetworkIpRangeVO.java similarity index 100% rename from server/src/com/cloud/dc/StorageNetworkIpRangeVO.java rename to engine/schema/src/com/cloud/dc/StorageNetworkIpRangeVO.java diff --git a/server/src/com/cloud/dc/VlanVO.java b/engine/schema/src/com/cloud/dc/VlanVO.java similarity index 100% rename from server/src/com/cloud/dc/VlanVO.java rename to engine/schema/src/com/cloud/dc/VlanVO.java diff --git a/server/src/com/cloud/dc/dao/AccountVlanMapDao.java b/engine/schema/src/com/cloud/dc/dao/AccountVlanMapDao.java similarity index 100% rename from server/src/com/cloud/dc/dao/AccountVlanMapDao.java rename to engine/schema/src/com/cloud/dc/dao/AccountVlanMapDao.java diff --git a/server/src/com/cloud/dc/dao/AccountVlanMapDaoImpl.java b/engine/schema/src/com/cloud/dc/dao/AccountVlanMapDaoImpl.java similarity index 100% rename from server/src/com/cloud/dc/dao/AccountVlanMapDaoImpl.java rename to engine/schema/src/com/cloud/dc/dao/AccountVlanMapDaoImpl.java diff --git a/server/src/com/cloud/dc/dao/ClusterDao.java b/engine/schema/src/com/cloud/dc/dao/ClusterDao.java similarity index 100% rename from server/src/com/cloud/dc/dao/ClusterDao.java rename to engine/schema/src/com/cloud/dc/dao/ClusterDao.java diff --git a/server/src/com/cloud/dc/dao/ClusterDaoImpl.java b/engine/schema/src/com/cloud/dc/dao/ClusterDaoImpl.java similarity index 100% rename from server/src/com/cloud/dc/dao/ClusterDaoImpl.java rename to engine/schema/src/com/cloud/dc/dao/ClusterDaoImpl.java diff --git a/server/src/com/cloud/dc/dao/ClusterVSMMapDao.java b/engine/schema/src/com/cloud/dc/dao/ClusterVSMMapDao.java similarity index 100% rename from server/src/com/cloud/dc/dao/ClusterVSMMapDao.java rename to engine/schema/src/com/cloud/dc/dao/ClusterVSMMapDao.java diff --git a/server/src/com/cloud/dc/dao/ClusterVSMMapDaoImpl.java b/engine/schema/src/com/cloud/dc/dao/ClusterVSMMapDaoImpl.java similarity index 100% rename from server/src/com/cloud/dc/dao/ClusterVSMMapDaoImpl.java rename to engine/schema/src/com/cloud/dc/dao/ClusterVSMMapDaoImpl.java diff --git a/server/src/com/cloud/dc/dao/DataCenterDao.java b/engine/schema/src/com/cloud/dc/dao/DataCenterDao.java similarity index 100% rename from server/src/com/cloud/dc/dao/DataCenterDao.java rename to engine/schema/src/com/cloud/dc/dao/DataCenterDao.java diff --git a/server/src/com/cloud/dc/dao/DataCenterDaoImpl.java b/engine/schema/src/com/cloud/dc/dao/DataCenterDaoImpl.java similarity index 94% rename from server/src/com/cloud/dc/dao/DataCenterDaoImpl.java rename to engine/schema/src/com/cloud/dc/dao/DataCenterDaoImpl.java index 4afd640d314..4d9d01065ca 100755 --- a/server/src/com/cloud/dc/dao/DataCenterDaoImpl.java +++ b/engine/schema/src/com/cloud/dc/dao/DataCenterDaoImpl.java @@ -16,6 +16,7 @@ // under the License. package com.cloud.dc.dao; +import java.util.ArrayList; import java.util.List; import java.util.Map; import java.util.Random; @@ -33,6 +34,8 @@ import com.cloud.dc.DataCenterLinkLocalIpAddressVO; import com.cloud.dc.DataCenterVO; import com.cloud.dc.DataCenterVnetVO; import com.cloud.dc.PodVlanVO; +import com.cloud.network.dao.AccountGuestVlanMapDao; +import com.cloud.network.dao.AccountGuestVlanMapVO; import com.cloud.org.Grouping; import com.cloud.utils.NumbersUtil; import com.cloud.utils.Pair; @@ -68,6 +71,7 @@ public class DataCenterDaoImpl extends GenericDaoBase implem @Inject protected DataCenterVnetDao _vnetAllocDao = null; @Inject protected PodVlanDao _podVlanAllocDao = null; @Inject protected DcDetailsDao _detailsDao = null; + @Inject protected AccountGuestVlanMapDao _accountGuestVlanMapDao = null; protected long _prefix; protected Random _rand = new Random(System.currentTimeMillis()); @@ -189,11 +193,20 @@ public class DataCenterDaoImpl extends GenericDaoBase implem @Override public String allocateVnet(long dataCenterId, long physicalNetworkId, long accountId, String reservationId) { - DataCenterVnetVO vo = _vnetAllocDao.take(physicalNetworkId, accountId, reservationId); + ArrayList dedicatedVlanDbIds = new ArrayList(); + List maps = _accountGuestVlanMapDao.listAccountGuestVlanMapsByAccount(accountId); + for (AccountGuestVlanMapVO map : maps) { + dedicatedVlanDbIds.add(map.getId()); + } + if (dedicatedVlanDbIds != null && !dedicatedVlanDbIds.isEmpty()) { + DataCenterVnetVO vo = _vnetAllocDao.take(physicalNetworkId, accountId, reservationId, dedicatedVlanDbIds); + if (vo != null) + return vo.getVnet(); + } + DataCenterVnetVO vo = _vnetAllocDao.take(physicalNetworkId, accountId, reservationId, null); if (vo == null) { return null; } - return vo.getVnet(); } diff --git a/server/src/com/cloud/dc/dao/DataCenterIpAddressDao.java b/engine/schema/src/com/cloud/dc/dao/DataCenterIpAddressDao.java similarity index 100% rename from server/src/com/cloud/dc/dao/DataCenterIpAddressDao.java rename to engine/schema/src/com/cloud/dc/dao/DataCenterIpAddressDao.java diff --git a/server/src/com/cloud/dc/dao/DataCenterIpAddressDaoImpl.java b/engine/schema/src/com/cloud/dc/dao/DataCenterIpAddressDaoImpl.java similarity index 100% rename from server/src/com/cloud/dc/dao/DataCenterIpAddressDaoImpl.java rename to engine/schema/src/com/cloud/dc/dao/DataCenterIpAddressDaoImpl.java diff --git a/server/src/com/cloud/dc/dao/DataCenterLinkLocalIpAddressDao.java b/engine/schema/src/com/cloud/dc/dao/DataCenterLinkLocalIpAddressDao.java similarity index 100% rename from server/src/com/cloud/dc/dao/DataCenterLinkLocalIpAddressDao.java rename to engine/schema/src/com/cloud/dc/dao/DataCenterLinkLocalIpAddressDao.java diff --git a/server/src/com/cloud/dc/dao/DataCenterLinkLocalIpAddressDaoImpl.java b/engine/schema/src/com/cloud/dc/dao/DataCenterLinkLocalIpAddressDaoImpl.java similarity index 100% rename from server/src/com/cloud/dc/dao/DataCenterLinkLocalIpAddressDaoImpl.java rename to engine/schema/src/com/cloud/dc/dao/DataCenterLinkLocalIpAddressDaoImpl.java diff --git a/server/src/com/cloud/dc/dao/DataCenterVnetDao.java b/engine/schema/src/com/cloud/dc/dao/DataCenterVnetDao.java similarity index 87% rename from server/src/com/cloud/dc/dao/DataCenterVnetDao.java rename to engine/schema/src/com/cloud/dc/dao/DataCenterVnetDao.java index 7fb68dcd7ac..778498d8898 100644 --- a/server/src/com/cloud/dc/dao/DataCenterVnetDao.java +++ b/engine/schema/src/com/cloud/dc/dao/DataCenterVnetDao.java @@ -37,8 +37,13 @@ public interface DataCenterVnetDao extends GenericDao { public void lockRange(long dcId, long physicalNetworkId, Integer start, Integer end); - public DataCenterVnetVO take(long physicalNetworkId, long accountId, String reservationId); + public DataCenterVnetVO take(long physicalNetworkId, long accountId, String reservationId, List vlanDbIds); public void release(String vnet, long physicalNetworkId, long accountId, String reservationId); + public void releaseDedicatedGuestVlans(Long dedicatedGuestVlanRangeId); + + public int countVnetsAllocatedToAccount(long dcId, long accountId); + + public int countVnetsDedicatedToAccount(long dcId, long accountId); } diff --git a/server/src/com/cloud/dc/dao/DataCenterVnetDaoImpl.java b/engine/schema/src/com/cloud/dc/dao/DataCenterVnetDaoImpl.java similarity index 69% rename from server/src/com/cloud/dc/dao/DataCenterVnetDaoImpl.java rename to engine/schema/src/com/cloud/dc/dao/DataCenterVnetDaoImpl.java index 2e044394ddc..e97f2c62ee3 100755 --- a/server/src/com/cloud/dc/dao/DataCenterVnetDaoImpl.java +++ b/engine/schema/src/com/cloud/dc/dao/DataCenterVnetDaoImpl.java @@ -20,15 +20,22 @@ import java.sql.PreparedStatement; import java.sql.SQLException; import java.util.Date; import java.util.List; +import java.util.Map; + +import javax.inject.Inject; +import javax.naming.ConfigurationException; import com.cloud.exception.InvalidParameterValueException; import org.springframework.stereotype.Component; import com.cloud.dc.DataCenterVnetVO; +import com.cloud.network.dao.AccountGuestVlanMapDao; +import com.cloud.network.dao.AccountGuestVlanMapVO; import com.cloud.utils.db.DB; import com.cloud.utils.db.GenericDao; import com.cloud.utils.db.GenericDaoBase; import com.cloud.utils.db.GenericSearchBuilder; +import com.cloud.utils.db.JoinBuilder; import com.cloud.utils.db.SearchBuilder; import com.cloud.utils.db.SearchCriteria; import com.cloud.utils.db.SearchCriteria.Func; @@ -43,7 +50,9 @@ import com.cloud.utils.exception.CloudRuntimeException; @Component @DB(txn=false) public class DataCenterVnetDaoImpl extends GenericDaoBase implements DataCenterVnetDao { + private final SearchBuilder FreeVnetSearch; + private final SearchBuilder FreeDedicatedVnetSearch; private final SearchBuilder VnetDcSearch; private final SearchBuilder VnetDcSearchAllocated; private final SearchBuilder DcSearchAllocated; @@ -51,6 +60,12 @@ public class DataCenterVnetDaoImpl extends GenericDaoBase countZoneVlans; private final GenericSearchBuilder countAllocatedZoneVlans; private final SearchBuilder SearchRange; + private final SearchBuilder DedicatedGuestVlanRangeSearch; + private final GenericSearchBuilder countVnetsAllocatedToAccount; + protected GenericSearchBuilder countVnetsDedicatedToAccount; + protected SearchBuilder AccountGuestVlanMapSearch; + + @Inject protected AccountGuestVlanMapDao _accountGuestVlanMapDao; public List listAllocatedVnets(long physicalNetworkId) { SearchCriteria sc = DcSearchAllocated.create(); @@ -141,9 +156,15 @@ public class DataCenterVnetDaoImpl extends GenericDaoBase sc = FreeVnetSearch.create(); - sc.setParameters("physicalNetworkId", physicalNetworkId); + public DataCenterVnetVO take(long physicalNetworkId, long accountId, String reservationId, List vlanDbIds) { + SearchCriteria sc; + if (vlanDbIds != null) { + sc = FreeDedicatedVnetSearch.create(); + sc.setParameters("accountGuestVlanMapId", vlanDbIds.toArray()); + } else { + sc = FreeVnetSearch.create(); + } + sc.setParameters("physicalNetworkId", physicalNetworkId); Date now = new Date(); Transaction txn = Transaction.currentTxn(); txn.start(); @@ -160,6 +181,7 @@ public class DataCenterVnetDaoImpl extends GenericDaoBase sc = VnetDcSearchAllocated.create(); sc.setParameters("vnet", vnet); @@ -178,6 +200,51 @@ public class DataCenterVnetDaoImpl extends GenericDaoBase sc = DedicatedGuestVlanRangeSearch.create(); + sc.setParameters("dedicatedGuestVlanRangeId", dedicatedGuestVlanRangeId); + List vnets = listBy(sc); + for(DataCenterVnetVO vnet : vnets) { + vnet.setAccountGuestVlanMapId(null); + update(vnet.getId(), vnet); + } + } + + @Override + public int countVnetsAllocatedToAccount(long dcId, long accountId) { + SearchCriteria sc = countVnetsAllocatedToAccount.create(); + sc.setParameters("dc", dcId); + sc.setParameters("accountId", accountId); + return customSearch(sc, null).get(0); + } + + @Override + public int countVnetsDedicatedToAccount(long dcId, long accountId) { + SearchCriteria sc = countVnetsDedicatedToAccount.create(); + sc.setParameters("dc", dcId); + sc.setParameters("accountId", accountId); + return customSearch(sc, null).get(0); + } + + @Override + public boolean configure(String name, Map params) throws ConfigurationException { + boolean result = super.configure(name, params); + + countVnetsDedicatedToAccount = createSearchBuilder(Integer.class); + countVnetsDedicatedToAccount.and("dc", countVnetsDedicatedToAccount.entity().getDataCenterId(), SearchCriteria.Op.EQ); + countVnetsDedicatedToAccount.and("accountGuestVlanMapId", countVnetsDedicatedToAccount.entity().getAccountGuestVlanMapId(), Op.NNULL); + AccountGuestVlanMapSearch = _accountGuestVlanMapDao.createSearchBuilder(); + AccountGuestVlanMapSearch.and("accountId", AccountGuestVlanMapSearch.entity().getAccountId(), SearchCriteria.Op.EQ); + countVnetsDedicatedToAccount.join("AccountGuestVlanMapSearch", AccountGuestVlanMapSearch, countVnetsDedicatedToAccount.entity().getAccountGuestVlanMapId(), + AccountGuestVlanMapSearch.entity().getId(), JoinBuilder.JoinType.INNER); + countVnetsDedicatedToAccount.select(null, Func.COUNT, countVnetsDedicatedToAccount.entity().getId()); + countVnetsDedicatedToAccount.done(); + AccountGuestVlanMapSearch.done(); + + return result; + } + public DataCenterVnetDaoImpl() { super(); DcSearchAllocated = createSearchBuilder(); @@ -202,7 +269,15 @@ public class DataCenterVnetDaoImpl extends GenericDaoBase { - + public List listLatestEvents(Date endDate); public List getLatestEvent(); - - List getRecentEvents(Date endDate) throws UsageServerException; + + List getRecentEvents(Date endDate); List listDirectIpEvents(Date startDate, Date endDate, long zoneId); diff --git a/core/src/com/cloud/event/dao/UsageEventDaoImpl.java b/engine/schema/src/com/cloud/event/dao/UsageEventDaoImpl.java similarity index 92% rename from core/src/com/cloud/event/dao/UsageEventDaoImpl.java rename to engine/schema/src/com/cloud/event/dao/UsageEventDaoImpl.java index dafc8d4d5ec..004ab7c381f 100644 --- a/core/src/com/cloud/event/dao/UsageEventDaoImpl.java +++ b/engine/schema/src/com/cloud/event/dao/UsageEventDaoImpl.java @@ -30,7 +30,6 @@ import org.springframework.stereotype.Component; import com.cloud.dc.Vlan; import com.cloud.event.EventTypes; import com.cloud.event.UsageEventVO; -import com.cloud.exception.UsageServerException; import com.cloud.utils.DateUtil; import com.cloud.utils.db.DB; import com.cloud.utils.db.Filter; @@ -38,6 +37,7 @@ import com.cloud.utils.db.GenericDaoBase; import com.cloud.utils.db.SearchBuilder; import com.cloud.utils.db.SearchCriteria; import com.cloud.utils.db.Transaction; +import com.cloud.utils.exception.CloudRuntimeException; @Component @Local(value={UsageEventDao.class}) @@ -58,8 +58,8 @@ public class UsageEventDaoImpl extends GenericDaoBase implem latestEventsSearch.and("processed", latestEventsSearch.entity().isProcessed(), SearchCriteria.Op.EQ); latestEventsSearch.and("enddate", latestEventsSearch.entity().getCreateDate(), SearchCriteria.Op.LTEQ); latestEventsSearch.done(); - - IpeventsSearch = createSearchBuilder(); + + IpeventsSearch = createSearchBuilder(); IpeventsSearch.and("startdate", IpeventsSearch.entity().getCreateDate(), SearchCriteria.Op.GTEQ); IpeventsSearch.and("enddate", IpeventsSearch.entity().getCreateDate(), SearchCriteria.Op.LTEQ); IpeventsSearch.and("zoneid", IpeventsSearch.entity().getZoneId(), SearchCriteria.Op.EQ); @@ -84,10 +84,10 @@ public class UsageEventDaoImpl extends GenericDaoBase implem Filter filter = new Filter(UsageEventVO.class, "id", Boolean.FALSE, Long.valueOf(0), Long.valueOf(1)); return listAll(filter); } - + @Override @DB - public synchronized List getRecentEvents(Date endDate) throws UsageServerException { + public synchronized List getRecentEvents(Date endDate) { long recentEventId = getMostRecentEventId(); long maxEventId = getMaxEventId(endDate); Transaction txn = Transaction.open(Transaction.USAGE_DB); @@ -114,12 +114,12 @@ public class UsageEventDaoImpl extends GenericDaoBase implem } catch (Exception ex) { txn.rollback(); s_logger.error("error copying events from cloud db to usage db", ex); - throw new UsageServerException(ex.getMessage()); + throw new CloudRuntimeException(ex.getMessage()); } } @DB - private long getMostRecentEventId() throws UsageServerException { + private long getMostRecentEventId() { Transaction txn = Transaction.open(Transaction.USAGE_DB); try { List latestEvents = getLatestEvent(); @@ -133,25 +133,25 @@ public class UsageEventDaoImpl extends GenericDaoBase implem return 0; } catch (Exception ex) { s_logger.error("error getting most recent event id", ex); - throw new UsageServerException(ex.getMessage()); + throw new CloudRuntimeException(ex.getMessage()); } finally { txn.close(); } } - private List findRecentEvents(Date endDate) throws UsageServerException { + private List findRecentEvents(Date endDate) { Transaction txn = Transaction.open(Transaction.USAGE_DB); try { return listLatestEvents(endDate); } catch (Exception ex) { s_logger.error("error getting most recent event date", ex); - throw new UsageServerException(ex.getMessage()); + throw new CloudRuntimeException(ex.getMessage()); } finally { txn.close(); } } - - private long getMaxEventId(Date endDate) throws UsageServerException { + + private long getMaxEventId(Date endDate) { Transaction txn = Transaction.currentTxn(); PreparedStatement pstmt = null; try { @@ -165,7 +165,7 @@ public class UsageEventDaoImpl extends GenericDaoBase implem return 0; } catch (Exception ex) { s_logger.error("error getting max event id", ex); - throw new UsageServerException(ex.getMessage()); + throw new CloudRuntimeException(ex.getMessage()); } finally { txn.close(); } diff --git a/core/src/com/cloud/host/DetailVO.java b/engine/schema/src/com/cloud/host/DetailVO.java similarity index 100% rename from core/src/com/cloud/host/DetailVO.java rename to engine/schema/src/com/cloud/host/DetailVO.java diff --git a/core/src/com/cloud/host/HostTagVO.java b/engine/schema/src/com/cloud/host/HostTagVO.java similarity index 100% rename from core/src/com/cloud/host/HostTagVO.java rename to engine/schema/src/com/cloud/host/HostTagVO.java diff --git a/core/src/com/cloud/host/HostVO.java b/engine/schema/src/com/cloud/host/HostVO.java similarity index 100% rename from core/src/com/cloud/host/HostVO.java rename to engine/schema/src/com/cloud/host/HostVO.java diff --git a/server/src/com/cloud/host/dao/HostDao.java b/engine/schema/src/com/cloud/host/dao/HostDao.java similarity index 100% rename from server/src/com/cloud/host/dao/HostDao.java rename to engine/schema/src/com/cloud/host/dao/HostDao.java diff --git a/server/src/com/cloud/host/dao/HostDaoImpl.java b/engine/schema/src/com/cloud/host/dao/HostDaoImpl.java similarity index 100% rename from server/src/com/cloud/host/dao/HostDaoImpl.java rename to engine/schema/src/com/cloud/host/dao/HostDaoImpl.java diff --git a/server/src/com/cloud/host/dao/HostDetailsDao.java b/engine/schema/src/com/cloud/host/dao/HostDetailsDao.java similarity index 100% rename from server/src/com/cloud/host/dao/HostDetailsDao.java rename to engine/schema/src/com/cloud/host/dao/HostDetailsDao.java diff --git a/server/src/com/cloud/host/dao/HostDetailsDaoImpl.java b/engine/schema/src/com/cloud/host/dao/HostDetailsDaoImpl.java similarity index 100% rename from server/src/com/cloud/host/dao/HostDetailsDaoImpl.java rename to engine/schema/src/com/cloud/host/dao/HostDetailsDaoImpl.java diff --git a/server/src/com/cloud/host/dao/HostTagsDao.java b/engine/schema/src/com/cloud/host/dao/HostTagsDao.java similarity index 100% rename from server/src/com/cloud/host/dao/HostTagsDao.java rename to engine/schema/src/com/cloud/host/dao/HostTagsDao.java diff --git a/server/src/com/cloud/host/dao/HostTagsDaoImpl.java b/engine/schema/src/com/cloud/host/dao/HostTagsDaoImpl.java similarity index 100% rename from server/src/com/cloud/host/dao/HostTagsDaoImpl.java rename to engine/schema/src/com/cloud/host/dao/HostTagsDaoImpl.java diff --git a/core/src/com/cloud/hypervisor/HypervisorCapabilitiesVO.java b/engine/schema/src/com/cloud/hypervisor/HypervisorCapabilitiesVO.java similarity index 100% rename from core/src/com/cloud/hypervisor/HypervisorCapabilitiesVO.java rename to engine/schema/src/com/cloud/hypervisor/HypervisorCapabilitiesVO.java diff --git a/server/src/com/cloud/hypervisor/dao/HypervisorCapabilitiesDao.java b/engine/schema/src/com/cloud/hypervisor/dao/HypervisorCapabilitiesDao.java similarity index 100% rename from server/src/com/cloud/hypervisor/dao/HypervisorCapabilitiesDao.java rename to engine/schema/src/com/cloud/hypervisor/dao/HypervisorCapabilitiesDao.java diff --git a/server/src/com/cloud/hypervisor/dao/HypervisorCapabilitiesDaoImpl.java b/engine/schema/src/com/cloud/hypervisor/dao/HypervisorCapabilitiesDaoImpl.java similarity index 100% rename from server/src/com/cloud/hypervisor/dao/HypervisorCapabilitiesDaoImpl.java rename to engine/schema/src/com/cloud/hypervisor/dao/HypervisorCapabilitiesDaoImpl.java diff --git a/server/src/com/cloud/keystore/KeystoreDao.java b/engine/schema/src/com/cloud/keystore/KeystoreDao.java similarity index 100% rename from server/src/com/cloud/keystore/KeystoreDao.java rename to engine/schema/src/com/cloud/keystore/KeystoreDao.java diff --git a/server/src/com/cloud/keystore/KeystoreDaoImpl.java b/engine/schema/src/com/cloud/keystore/KeystoreDaoImpl.java similarity index 100% rename from server/src/com/cloud/keystore/KeystoreDaoImpl.java rename to engine/schema/src/com/cloud/keystore/KeystoreDaoImpl.java diff --git a/server/src/com/cloud/keystore/KeystoreVO.java b/engine/schema/src/com/cloud/keystore/KeystoreVO.java similarity index 100% rename from server/src/com/cloud/keystore/KeystoreVO.java rename to engine/schema/src/com/cloud/keystore/KeystoreVO.java diff --git a/server/src/com/cloud/migration/DiskOffering20Dao.java b/engine/schema/src/com/cloud/migration/DiskOffering20Dao.java similarity index 100% rename from server/src/com/cloud/migration/DiskOffering20Dao.java rename to engine/schema/src/com/cloud/migration/DiskOffering20Dao.java diff --git a/server/src/com/cloud/migration/DiskOffering20DaoImpl.java b/engine/schema/src/com/cloud/migration/DiskOffering20DaoImpl.java similarity index 100% rename from server/src/com/cloud/migration/DiskOffering20DaoImpl.java rename to engine/schema/src/com/cloud/migration/DiskOffering20DaoImpl.java diff --git a/server/src/com/cloud/migration/DiskOffering20VO.java b/engine/schema/src/com/cloud/migration/DiskOffering20VO.java similarity index 100% rename from server/src/com/cloud/migration/DiskOffering20VO.java rename to engine/schema/src/com/cloud/migration/DiskOffering20VO.java diff --git a/server/src/com/cloud/migration/DiskOffering21Dao.java b/engine/schema/src/com/cloud/migration/DiskOffering21Dao.java similarity index 100% rename from server/src/com/cloud/migration/DiskOffering21Dao.java rename to engine/schema/src/com/cloud/migration/DiskOffering21Dao.java diff --git a/server/src/com/cloud/migration/DiskOffering21DaoImpl.java b/engine/schema/src/com/cloud/migration/DiskOffering21DaoImpl.java similarity index 100% rename from server/src/com/cloud/migration/DiskOffering21DaoImpl.java rename to engine/schema/src/com/cloud/migration/DiskOffering21DaoImpl.java diff --git a/server/src/com/cloud/migration/DiskOffering21VO.java b/engine/schema/src/com/cloud/migration/DiskOffering21VO.java similarity index 100% rename from server/src/com/cloud/migration/DiskOffering21VO.java rename to engine/schema/src/com/cloud/migration/DiskOffering21VO.java diff --git a/server/src/com/cloud/migration/ServiceOffering20Dao.java b/engine/schema/src/com/cloud/migration/ServiceOffering20Dao.java similarity index 100% rename from server/src/com/cloud/migration/ServiceOffering20Dao.java rename to engine/schema/src/com/cloud/migration/ServiceOffering20Dao.java diff --git a/server/src/com/cloud/migration/ServiceOffering20DaoImpl.java b/engine/schema/src/com/cloud/migration/ServiceOffering20DaoImpl.java similarity index 100% rename from server/src/com/cloud/migration/ServiceOffering20DaoImpl.java rename to engine/schema/src/com/cloud/migration/ServiceOffering20DaoImpl.java diff --git a/server/src/com/cloud/migration/ServiceOffering20VO.java b/engine/schema/src/com/cloud/migration/ServiceOffering20VO.java similarity index 100% rename from server/src/com/cloud/migration/ServiceOffering20VO.java rename to engine/schema/src/com/cloud/migration/ServiceOffering20VO.java diff --git a/server/src/com/cloud/migration/ServiceOffering21Dao.java b/engine/schema/src/com/cloud/migration/ServiceOffering21Dao.java similarity index 100% rename from server/src/com/cloud/migration/ServiceOffering21Dao.java rename to engine/schema/src/com/cloud/migration/ServiceOffering21Dao.java diff --git a/server/src/com/cloud/migration/ServiceOffering21DaoImpl.java b/engine/schema/src/com/cloud/migration/ServiceOffering21DaoImpl.java similarity index 100% rename from server/src/com/cloud/migration/ServiceOffering21DaoImpl.java rename to engine/schema/src/com/cloud/migration/ServiceOffering21DaoImpl.java diff --git a/server/src/com/cloud/migration/ServiceOffering21VO.java b/engine/schema/src/com/cloud/migration/ServiceOffering21VO.java similarity index 100% rename from server/src/com/cloud/migration/ServiceOffering21VO.java rename to engine/schema/src/com/cloud/migration/ServiceOffering21VO.java diff --git a/server/src/com/cloud/network/LBHealthCheckPolicyVO.java b/engine/schema/src/com/cloud/network/LBHealthCheckPolicyVO.java similarity index 100% rename from server/src/com/cloud/network/LBHealthCheckPolicyVO.java rename to engine/schema/src/com/cloud/network/LBHealthCheckPolicyVO.java diff --git a/server/src/com/cloud/network/UserIpv6AddressVO.java b/engine/schema/src/com/cloud/network/UserIpv6AddressVO.java similarity index 100% rename from server/src/com/cloud/network/UserIpv6AddressVO.java rename to engine/schema/src/com/cloud/network/UserIpv6AddressVO.java diff --git a/core/src/com/cloud/network/VpnUserVO.java b/engine/schema/src/com/cloud/network/VpnUserVO.java similarity index 100% rename from core/src/com/cloud/network/VpnUserVO.java rename to engine/schema/src/com/cloud/network/VpnUserVO.java diff --git a/server/src/com/cloud/network/as/AutoScalePolicyConditionMapVO.java b/engine/schema/src/com/cloud/network/as/AutoScalePolicyConditionMapVO.java similarity index 100% rename from server/src/com/cloud/network/as/AutoScalePolicyConditionMapVO.java rename to engine/schema/src/com/cloud/network/as/AutoScalePolicyConditionMapVO.java diff --git a/server/src/com/cloud/network/as/AutoScalePolicyVO.java b/engine/schema/src/com/cloud/network/as/AutoScalePolicyVO.java similarity index 100% rename from server/src/com/cloud/network/as/AutoScalePolicyVO.java rename to engine/schema/src/com/cloud/network/as/AutoScalePolicyVO.java diff --git a/server/src/com/cloud/network/as/AutoScaleVmGroupPolicyMapVO.java b/engine/schema/src/com/cloud/network/as/AutoScaleVmGroupPolicyMapVO.java similarity index 100% rename from server/src/com/cloud/network/as/AutoScaleVmGroupPolicyMapVO.java rename to engine/schema/src/com/cloud/network/as/AutoScaleVmGroupPolicyMapVO.java diff --git a/server/src/com/cloud/network/as/AutoScaleVmGroupVO.java b/engine/schema/src/com/cloud/network/as/AutoScaleVmGroupVO.java similarity index 100% rename from server/src/com/cloud/network/as/AutoScaleVmGroupVO.java rename to engine/schema/src/com/cloud/network/as/AutoScaleVmGroupVO.java diff --git a/server/src/com/cloud/network/as/AutoScaleVmProfileVO.java b/engine/schema/src/com/cloud/network/as/AutoScaleVmProfileVO.java similarity index 100% rename from server/src/com/cloud/network/as/AutoScaleVmProfileVO.java rename to engine/schema/src/com/cloud/network/as/AutoScaleVmProfileVO.java diff --git a/server/src/com/cloud/network/as/ConditionVO.java b/engine/schema/src/com/cloud/network/as/ConditionVO.java similarity index 100% rename from server/src/com/cloud/network/as/ConditionVO.java rename to engine/schema/src/com/cloud/network/as/ConditionVO.java diff --git a/server/src/com/cloud/network/as/CounterVO.java b/engine/schema/src/com/cloud/network/as/CounterVO.java similarity index 100% rename from server/src/com/cloud/network/as/CounterVO.java rename to engine/schema/src/com/cloud/network/as/CounterVO.java diff --git a/server/src/com/cloud/network/as/dao/AutoScalePolicyConditionMapDao.java b/engine/schema/src/com/cloud/network/as/dao/AutoScalePolicyConditionMapDao.java similarity index 100% rename from server/src/com/cloud/network/as/dao/AutoScalePolicyConditionMapDao.java rename to engine/schema/src/com/cloud/network/as/dao/AutoScalePolicyConditionMapDao.java diff --git a/server/src/com/cloud/network/as/dao/AutoScalePolicyConditionMapDaoImpl.java b/engine/schema/src/com/cloud/network/as/dao/AutoScalePolicyConditionMapDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/as/dao/AutoScalePolicyConditionMapDaoImpl.java rename to engine/schema/src/com/cloud/network/as/dao/AutoScalePolicyConditionMapDaoImpl.java diff --git a/server/src/com/cloud/network/as/dao/AutoScalePolicyDao.java b/engine/schema/src/com/cloud/network/as/dao/AutoScalePolicyDao.java similarity index 100% rename from server/src/com/cloud/network/as/dao/AutoScalePolicyDao.java rename to engine/schema/src/com/cloud/network/as/dao/AutoScalePolicyDao.java diff --git a/server/src/com/cloud/network/as/dao/AutoScalePolicyDaoImpl.java b/engine/schema/src/com/cloud/network/as/dao/AutoScalePolicyDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/as/dao/AutoScalePolicyDaoImpl.java rename to engine/schema/src/com/cloud/network/as/dao/AutoScalePolicyDaoImpl.java diff --git a/server/src/com/cloud/network/as/dao/AutoScaleVmGroupDao.java b/engine/schema/src/com/cloud/network/as/dao/AutoScaleVmGroupDao.java similarity index 100% rename from server/src/com/cloud/network/as/dao/AutoScaleVmGroupDao.java rename to engine/schema/src/com/cloud/network/as/dao/AutoScaleVmGroupDao.java diff --git a/server/src/com/cloud/network/as/dao/AutoScaleVmGroupDaoImpl.java b/engine/schema/src/com/cloud/network/as/dao/AutoScaleVmGroupDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/as/dao/AutoScaleVmGroupDaoImpl.java rename to engine/schema/src/com/cloud/network/as/dao/AutoScaleVmGroupDaoImpl.java diff --git a/server/src/com/cloud/network/as/dao/AutoScaleVmGroupPolicyMapDao.java b/engine/schema/src/com/cloud/network/as/dao/AutoScaleVmGroupPolicyMapDao.java similarity index 100% rename from server/src/com/cloud/network/as/dao/AutoScaleVmGroupPolicyMapDao.java rename to engine/schema/src/com/cloud/network/as/dao/AutoScaleVmGroupPolicyMapDao.java diff --git a/server/src/com/cloud/network/as/dao/AutoScaleVmGroupPolicyMapDaoImpl.java b/engine/schema/src/com/cloud/network/as/dao/AutoScaleVmGroupPolicyMapDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/as/dao/AutoScaleVmGroupPolicyMapDaoImpl.java rename to engine/schema/src/com/cloud/network/as/dao/AutoScaleVmGroupPolicyMapDaoImpl.java diff --git a/server/src/com/cloud/network/as/dao/AutoScaleVmProfileDao.java b/engine/schema/src/com/cloud/network/as/dao/AutoScaleVmProfileDao.java similarity index 100% rename from server/src/com/cloud/network/as/dao/AutoScaleVmProfileDao.java rename to engine/schema/src/com/cloud/network/as/dao/AutoScaleVmProfileDao.java diff --git a/server/src/com/cloud/network/as/dao/AutoScaleVmProfileDaoImpl.java b/engine/schema/src/com/cloud/network/as/dao/AutoScaleVmProfileDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/as/dao/AutoScaleVmProfileDaoImpl.java rename to engine/schema/src/com/cloud/network/as/dao/AutoScaleVmProfileDaoImpl.java diff --git a/server/src/com/cloud/network/as/dao/ConditionDao.java b/engine/schema/src/com/cloud/network/as/dao/ConditionDao.java similarity index 100% rename from server/src/com/cloud/network/as/dao/ConditionDao.java rename to engine/schema/src/com/cloud/network/as/dao/ConditionDao.java diff --git a/server/src/com/cloud/network/as/dao/ConditionDaoImpl.java b/engine/schema/src/com/cloud/network/as/dao/ConditionDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/as/dao/ConditionDaoImpl.java rename to engine/schema/src/com/cloud/network/as/dao/ConditionDaoImpl.java diff --git a/server/src/com/cloud/network/as/dao/CounterDao.java b/engine/schema/src/com/cloud/network/as/dao/CounterDao.java similarity index 100% rename from server/src/com/cloud/network/as/dao/CounterDao.java rename to engine/schema/src/com/cloud/network/as/dao/CounterDao.java diff --git a/server/src/com/cloud/network/as/dao/CounterDaoImpl.java b/engine/schema/src/com/cloud/network/as/dao/CounterDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/as/dao/CounterDaoImpl.java rename to engine/schema/src/com/cloud/network/as/dao/CounterDaoImpl.java diff --git a/engine/schema/src/com/cloud/network/dao/AccountGuestVlanMapDao.java b/engine/schema/src/com/cloud/network/dao/AccountGuestVlanMapDao.java new file mode 100644 index 00000000000..dc1ec895d80 --- /dev/null +++ b/engine/schema/src/com/cloud/network/dao/AccountGuestVlanMapDao.java @@ -0,0 +1,34 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.network.dao; + +import com.cloud.network.dao.AccountGuestVlanMapVO; +import com.cloud.utils.db.GenericDao; + +import java.util.List; + +public interface AccountGuestVlanMapDao extends GenericDao { + + public List listAccountGuestVlanMapsByAccount(long accountId); + + public List listAccountGuestVlanMapsByVlan(long guestVlanId); + + public List listAccountGuestVlanMapsByPhysicalNetwork(long physicalNetworkId); + + public int removeByAccountId(long accountId); + +} diff --git a/engine/schema/src/com/cloud/network/dao/AccountGuestVlanMapDaoImpl.java b/engine/schema/src/com/cloud/network/dao/AccountGuestVlanMapDaoImpl.java new file mode 100644 index 00000000000..e7a7b34d9bd --- /dev/null +++ b/engine/schema/src/com/cloud/network/dao/AccountGuestVlanMapDaoImpl.java @@ -0,0 +1,83 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.network.dao; + +import com.cloud.network.dao.AccountGuestVlanMapVO; +import com.cloud.network.dao.AccountGuestVlanMapDao; + +import java.util.List; +import javax.ejb.Local; +import org.springframework.stereotype.Component; + +import com.cloud.utils.db.DB; +import com.cloud.utils.db.GenericDaoBase; +import com.cloud.utils.db.SearchBuilder; +import com.cloud.utils.db.SearchCriteria; + +@Component +@Local(value={AccountGuestVlanMapDao.class}) +@DB(txn=false) +public class AccountGuestVlanMapDaoImpl extends GenericDaoBase implements AccountGuestVlanMapDao { + + protected SearchBuilder AccountSearch; + protected SearchBuilder GuestVlanSearch; + protected SearchBuilder PhysicalNetworkSearch; + + @Override + public List listAccountGuestVlanMapsByAccount(long accountId) { + SearchCriteria sc = AccountSearch.create(); + sc.setParameters("accountId", accountId); + return listIncludingRemovedBy(sc); + } + + @Override + public List listAccountGuestVlanMapsByVlan(long guestVlanId) { + SearchCriteria sc = GuestVlanSearch.create(); + sc.setParameters("guestVlanId", guestVlanId); + return listIncludingRemovedBy(sc); + } + + @Override + public List listAccountGuestVlanMapsByPhysicalNetwork(long physicalNetworkId) { + SearchCriteria sc = GuestVlanSearch.create(); + sc.setParameters("physicalNetworkId", physicalNetworkId); + return listIncludingRemovedBy(sc); + } + + @Override + public int removeByAccountId(long accountId) { + SearchCriteria sc = AccountSearch.create(); + sc.setParameters("accountId", accountId); + return expunge(sc); + } + + public AccountGuestVlanMapDaoImpl() { + super(); + AccountSearch = createSearchBuilder(); + AccountSearch.and("accountId", AccountSearch.entity().getAccountId(), SearchCriteria.Op.EQ); + AccountSearch.done(); + + GuestVlanSearch = createSearchBuilder(); + GuestVlanSearch.and("guestVlanId", GuestVlanSearch.entity().getId(), SearchCriteria.Op.EQ); + GuestVlanSearch.done(); + + PhysicalNetworkSearch = createSearchBuilder(); + PhysicalNetworkSearch.and("physicalNetworkId", PhysicalNetworkSearch.entity().getId(), SearchCriteria.Op.EQ); + PhysicalNetworkSearch.done(); + } + +} diff --git a/engine/schema/src/com/cloud/network/dao/AccountGuestVlanMapVO.java b/engine/schema/src/com/cloud/network/dao/AccountGuestVlanMapVO.java new file mode 100644 index 00000000000..17c941a7e36 --- /dev/null +++ b/engine/schema/src/com/cloud/network/dao/AccountGuestVlanMapVO.java @@ -0,0 +1,94 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.network.dao; + +import com.cloud.network.GuestVlan; + +import javax.persistence.*; +import java.util.UUID; + +@Entity +@Table(name="account_vnet_map") +public class AccountGuestVlanMapVO implements GuestVlan { + + @Id + @GeneratedValue(strategy=GenerationType.IDENTITY) + @Column(name="id") + private long id; + + @Column(name="account_id") + private long accountId; + + @Column(name="uuid") + private String uuid; + + @Column(name="vnet_range") + private String guestVlanRange; + + @Column(name="physical_network_id") + private long physicalNetworkId; + + public AccountGuestVlanMapVO(long accountId,long physicalNetworkId) { + this.accountId = accountId; + this.physicalNetworkId = physicalNetworkId; + this.guestVlanRange = null; + this.uuid = UUID.randomUUID().toString(); + } + + public AccountGuestVlanMapVO() { + + } + + @Override + public long getId() { + return id; + } + + @Override + public long getAccountId() { + return accountId; + } + + @Override + public String getGuestVlanRange() { + return guestVlanRange; + } + + + public void setGuestVlanRange(String guestVlanRange) { + this.guestVlanRange = guestVlanRange; + } + + @Override + public String getUuid() { + return this.uuid; + } + + public void setUuid(String uuid) { + this.uuid = uuid; + } + + @Override + public long getPhysicalNetworkId() { + return this.physicalNetworkId; + } + + public void setPhysicalNetworkId(long physicalNetworkId) { + this.physicalNetworkId = physicalNetworkId; + } + +} diff --git a/server/src/com/cloud/network/dao/ExternalFirewallDeviceDao.java b/engine/schema/src/com/cloud/network/dao/ExternalFirewallDeviceDao.java similarity index 100% rename from server/src/com/cloud/network/dao/ExternalFirewallDeviceDao.java rename to engine/schema/src/com/cloud/network/dao/ExternalFirewallDeviceDao.java diff --git a/server/src/com/cloud/network/dao/ExternalFirewallDeviceDaoImpl.java b/engine/schema/src/com/cloud/network/dao/ExternalFirewallDeviceDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/ExternalFirewallDeviceDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/ExternalFirewallDeviceDaoImpl.java diff --git a/server/src/com/cloud/network/dao/ExternalFirewallDeviceVO.java b/engine/schema/src/com/cloud/network/dao/ExternalFirewallDeviceVO.java similarity index 100% rename from server/src/com/cloud/network/dao/ExternalFirewallDeviceVO.java rename to engine/schema/src/com/cloud/network/dao/ExternalFirewallDeviceVO.java diff --git a/server/src/com/cloud/network/dao/ExternalLoadBalancerDeviceDao.java b/engine/schema/src/com/cloud/network/dao/ExternalLoadBalancerDeviceDao.java similarity index 100% rename from server/src/com/cloud/network/dao/ExternalLoadBalancerDeviceDao.java rename to engine/schema/src/com/cloud/network/dao/ExternalLoadBalancerDeviceDao.java diff --git a/server/src/com/cloud/network/dao/ExternalLoadBalancerDeviceDaoImpl.java b/engine/schema/src/com/cloud/network/dao/ExternalLoadBalancerDeviceDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/ExternalLoadBalancerDeviceDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/ExternalLoadBalancerDeviceDaoImpl.java diff --git a/server/src/com/cloud/network/dao/ExternalLoadBalancerDeviceVO.java b/engine/schema/src/com/cloud/network/dao/ExternalLoadBalancerDeviceVO.java similarity index 100% rename from server/src/com/cloud/network/dao/ExternalLoadBalancerDeviceVO.java rename to engine/schema/src/com/cloud/network/dao/ExternalLoadBalancerDeviceVO.java diff --git a/server/src/com/cloud/network/dao/FirewallRulesCidrsDao.java b/engine/schema/src/com/cloud/network/dao/FirewallRulesCidrsDao.java similarity index 100% rename from server/src/com/cloud/network/dao/FirewallRulesCidrsDao.java rename to engine/schema/src/com/cloud/network/dao/FirewallRulesCidrsDao.java diff --git a/server/src/com/cloud/network/dao/FirewallRulesCidrsDaoImpl.java b/engine/schema/src/com/cloud/network/dao/FirewallRulesCidrsDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/FirewallRulesCidrsDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/FirewallRulesCidrsDaoImpl.java diff --git a/server/src/com/cloud/network/dao/FirewallRulesCidrsVO.java b/engine/schema/src/com/cloud/network/dao/FirewallRulesCidrsVO.java similarity index 100% rename from server/src/com/cloud/network/dao/FirewallRulesCidrsVO.java rename to engine/schema/src/com/cloud/network/dao/FirewallRulesCidrsVO.java diff --git a/server/src/com/cloud/network/dao/FirewallRulesDao.java b/engine/schema/src/com/cloud/network/dao/FirewallRulesDao.java similarity index 98% rename from server/src/com/cloud/network/dao/FirewallRulesDao.java rename to engine/schema/src/com/cloud/network/dao/FirewallRulesDao.java index 0bbaa93363d..6b9b3bb83e5 100644 --- a/server/src/com/cloud/network/dao/FirewallRulesDao.java +++ b/engine/schema/src/com/cloud/network/dao/FirewallRulesDao.java @@ -18,7 +18,6 @@ package com.cloud.network.dao; import java.util.List; -import com.cloud.host.HostVO; import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.FirewallRuleVO; import com.cloud.utils.db.GenericDao; diff --git a/server/src/com/cloud/network/dao/FirewallRulesDaoImpl.java b/engine/schema/src/com/cloud/network/dao/FirewallRulesDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/FirewallRulesDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/FirewallRulesDaoImpl.java diff --git a/server/src/com/cloud/network/dao/IPAddressDao.java b/engine/schema/src/com/cloud/network/dao/IPAddressDao.java similarity index 100% rename from server/src/com/cloud/network/dao/IPAddressDao.java rename to engine/schema/src/com/cloud/network/dao/IPAddressDao.java diff --git a/server/src/com/cloud/network/dao/IPAddressDaoImpl.java b/engine/schema/src/com/cloud/network/dao/IPAddressDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/IPAddressDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/IPAddressDaoImpl.java diff --git a/server/src/com/cloud/network/dao/IPAddressVO.java b/engine/schema/src/com/cloud/network/dao/IPAddressVO.java similarity index 98% rename from server/src/com/cloud/network/dao/IPAddressVO.java rename to engine/schema/src/com/cloud/network/dao/IPAddressVO.java index 1c8d749603b..a7dcf6ae39e 100644 --- a/server/src/com/cloud/network/dao/IPAddressVO.java +++ b/engine/schema/src/com/cloud/network/dao/IPAddressVO.java @@ -31,12 +31,8 @@ import javax.persistence.Temporal; import javax.persistence.TemporalType; import javax.persistence.Transient; -import org.apache.cloudstack.api.Identity; - import com.cloud.network.IpAddress; -import com.cloud.network.IpAddress.State; import com.cloud.utils.net.Ip; -import org.apache.cloudstack.api.InternalIdentity; /** * A bean representing a public IP Address @@ -315,4 +311,9 @@ public class IPAddressVO implements IpAddress { public void setVmIp(String vmIp) { this.vmIp = vmIp; } + + @Override + public Long getNetworkId() { + return sourceNetworkId; + } } diff --git a/server/src/com/cloud/network/dao/InlineLoadBalancerNicMapDao.java b/engine/schema/src/com/cloud/network/dao/InlineLoadBalancerNicMapDao.java similarity index 100% rename from server/src/com/cloud/network/dao/InlineLoadBalancerNicMapDao.java rename to engine/schema/src/com/cloud/network/dao/InlineLoadBalancerNicMapDao.java diff --git a/server/src/com/cloud/network/dao/InlineLoadBalancerNicMapDaoImpl.java b/engine/schema/src/com/cloud/network/dao/InlineLoadBalancerNicMapDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/InlineLoadBalancerNicMapDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/InlineLoadBalancerNicMapDaoImpl.java diff --git a/server/src/com/cloud/network/dao/InlineLoadBalancerNicMapVO.java b/engine/schema/src/com/cloud/network/dao/InlineLoadBalancerNicMapVO.java similarity index 100% rename from server/src/com/cloud/network/dao/InlineLoadBalancerNicMapVO.java rename to engine/schema/src/com/cloud/network/dao/InlineLoadBalancerNicMapVO.java diff --git a/server/src/com/cloud/network/dao/LBHealthCheckPolicyDao.java b/engine/schema/src/com/cloud/network/dao/LBHealthCheckPolicyDao.java similarity index 100% rename from server/src/com/cloud/network/dao/LBHealthCheckPolicyDao.java rename to engine/schema/src/com/cloud/network/dao/LBHealthCheckPolicyDao.java diff --git a/server/src/com/cloud/network/dao/LBHealthCheckPolicyDaoImpl.java b/engine/schema/src/com/cloud/network/dao/LBHealthCheckPolicyDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/LBHealthCheckPolicyDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/LBHealthCheckPolicyDaoImpl.java diff --git a/server/src/com/cloud/network/dao/LBStickinessPolicyDao.java b/engine/schema/src/com/cloud/network/dao/LBStickinessPolicyDao.java similarity index 100% rename from server/src/com/cloud/network/dao/LBStickinessPolicyDao.java rename to engine/schema/src/com/cloud/network/dao/LBStickinessPolicyDao.java diff --git a/server/src/com/cloud/network/dao/LBStickinessPolicyDaoImpl.java b/engine/schema/src/com/cloud/network/dao/LBStickinessPolicyDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/LBStickinessPolicyDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/LBStickinessPolicyDaoImpl.java diff --git a/server/src/com/cloud/network/dao/LBStickinessPolicyVO.java b/engine/schema/src/com/cloud/network/dao/LBStickinessPolicyVO.java similarity index 100% rename from server/src/com/cloud/network/dao/LBStickinessPolicyVO.java rename to engine/schema/src/com/cloud/network/dao/LBStickinessPolicyVO.java diff --git a/server/src/com/cloud/network/dao/LoadBalancerDao.java b/engine/schema/src/com/cloud/network/dao/LoadBalancerDao.java similarity index 74% rename from server/src/com/cloud/network/dao/LoadBalancerDao.java rename to engine/schema/src/com/cloud/network/dao/LoadBalancerDao.java index 611282e5693..331f7555d81 100644 --- a/server/src/com/cloud/network/dao/LoadBalancerDao.java +++ b/engine/schema/src/com/cloud/network/dao/LoadBalancerDao.java @@ -18,19 +18,15 @@ package com.cloud.network.dao; import java.util.List; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.utils.db.GenericDao; public interface LoadBalancerDao extends GenericDao { - List listInstancesByLoadBalancer(long loadBalancerId); List listByIpAddress(long ipAddressId); - LoadBalancerVO findByIpAddressAndPublicPort(long ipAddressId, String publicPort); + List listByNetworkIdAndScheme(long networkId, Scheme scheme); - LoadBalancerVO findByAccountAndName(Long accountId, String name); - - List listByNetworkId(long networkId); - - List listInTransitionStateByNetworkId(long networkId); + List listInTransitionStateByNetworkIdAndScheme(long networkId, Scheme scheme); } diff --git a/engine/schema/src/com/cloud/network/dao/LoadBalancerDaoImpl.java b/engine/schema/src/com/cloud/network/dao/LoadBalancerDaoImpl.java new file mode 100644 index 00000000000..c20d8b23d6a --- /dev/null +++ b/engine/schema/src/com/cloud/network/dao/LoadBalancerDaoImpl.java @@ -0,0 +1,79 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.network.dao; + +import java.util.List; + +import javax.ejb.Local; +import javax.inject.Inject; + +import org.springframework.stereotype.Component; + +import com.cloud.network.rules.FirewallRule.State; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.utils.db.GenericDaoBase; +import com.cloud.utils.db.SearchBuilder; +import com.cloud.utils.db.SearchCriteria; +import com.cloud.utils.db.SearchCriteria.Op; + +@Component +@Local(value = { LoadBalancerDao.class }) +public class LoadBalancerDaoImpl extends GenericDaoBase implements LoadBalancerDao { + private final SearchBuilder ListByIp; + protected final SearchBuilder TransitionStateSearch; + + @Inject protected FirewallRulesCidrsDao _portForwardingRulesCidrsDao; + + protected LoadBalancerDaoImpl() { + ListByIp = createSearchBuilder(); + ListByIp.and("ipAddressId", ListByIp.entity().getSourceIpAddressId(), SearchCriteria.Op.EQ); + ListByIp.and("networkId", ListByIp.entity().getNetworkId(), SearchCriteria.Op.EQ); + ListByIp.and("scheme", ListByIp.entity().getScheme(), SearchCriteria.Op.EQ); + ListByIp.done(); + + TransitionStateSearch = createSearchBuilder(); + TransitionStateSearch.and("networkId", TransitionStateSearch.entity().getNetworkId(), Op.EQ); + TransitionStateSearch.and("state", TransitionStateSearch.entity().getState(), Op.IN); + TransitionStateSearch.and("scheme", TransitionStateSearch.entity().getScheme(), Op.EQ); + TransitionStateSearch.done(); + } + + @Override + public List listByIpAddress(long ipAddressId) { + SearchCriteria sc = ListByIp.create(); + sc.setParameters("ipAddressId", ipAddressId); + return listBy(sc); + } + + @Override + public List listByNetworkIdAndScheme(long networkId, Scheme scheme) { + SearchCriteria sc = ListByIp.create(); + sc.setParameters("networkId", networkId); + sc.setParameters("scheme", scheme); + return listBy(sc); + } + + @Override + public List listInTransitionStateByNetworkIdAndScheme(long networkId, Scheme scheme) { + SearchCriteria sc = TransitionStateSearch.create(); + sc.setParameters("networkId", networkId); + sc.setParameters("state", State.Add.toString(), State.Revoke.toString()); + sc.setParameters("scheme", scheme); + return listBy(sc); + } + +} diff --git a/server/src/com/cloud/network/dao/LoadBalancerVMMapDao.java b/engine/schema/src/com/cloud/network/dao/LoadBalancerVMMapDao.java similarity index 100% rename from server/src/com/cloud/network/dao/LoadBalancerVMMapDao.java rename to engine/schema/src/com/cloud/network/dao/LoadBalancerVMMapDao.java diff --git a/server/src/com/cloud/network/dao/LoadBalancerVMMapDaoImpl.java b/engine/schema/src/com/cloud/network/dao/LoadBalancerVMMapDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/LoadBalancerVMMapDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/LoadBalancerVMMapDaoImpl.java diff --git a/server/src/com/cloud/network/dao/LoadBalancerVMMapVO.java b/engine/schema/src/com/cloud/network/dao/LoadBalancerVMMapVO.java similarity index 100% rename from server/src/com/cloud/network/dao/LoadBalancerVMMapVO.java rename to engine/schema/src/com/cloud/network/dao/LoadBalancerVMMapVO.java diff --git a/server/src/com/cloud/network/dao/LoadBalancerVO.java b/engine/schema/src/com/cloud/network/dao/LoadBalancerVO.java similarity index 86% rename from server/src/com/cloud/network/dao/LoadBalancerVO.java rename to engine/schema/src/com/cloud/network/dao/LoadBalancerVO.java index 5422f41774b..fee88cf7b0a 100644 --- a/server/src/com/cloud/network/dao/LoadBalancerVO.java +++ b/engine/schema/src/com/cloud/network/dao/LoadBalancerVO.java @@ -19,6 +19,8 @@ package com.cloud.network.dao; import javax.persistence.Column; import javax.persistence.DiscriminatorValue; import javax.persistence.Entity; +import javax.persistence.EnumType; +import javax.persistence.Enumerated; import javax.persistence.PrimaryKeyJoinColumn; import javax.persistence.Table; @@ -26,6 +28,12 @@ import com.cloud.network.rules.FirewallRuleVO; import com.cloud.network.rules.LoadBalancer; import com.cloud.utils.net.NetUtils; +/** + * This VO represent Public Load Balancer + * It references source ip address by its Id. + * To get the VO for Internal Load Balancer rule, please refer to LoadBalancerRuleVO + * + */ @Entity @Table(name=("load_balancing_rules")) @DiscriminatorValue(value="LoadBalancing") @@ -46,6 +54,10 @@ public class LoadBalancerVO extends FirewallRuleVO implements LoadBalancer { @Column(name="default_port_end") private int defaultPortEnd; + + @Enumerated(value=EnumType.STRING) + @Column(name="scheme") + Scheme scheme = Scheme.Public; public LoadBalancerVO() { } @@ -57,6 +69,7 @@ public class LoadBalancerVO extends FirewallRuleVO implements LoadBalancer { this.algorithm = algorithm; this.defaultPortStart = dstPort; this.defaultPortEnd = dstPort; + this.scheme = Scheme.Public; } @Override @@ -94,5 +107,10 @@ public class LoadBalancerVO extends FirewallRuleVO implements LoadBalancer { public void setDescription(String description) { this.description = description; + } + + @Override + public Scheme getScheme() { + return scheme; } } diff --git a/server/src/com/cloud/network/dao/NetworkAccountDao.java b/engine/schema/src/com/cloud/network/dao/NetworkAccountDao.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkAccountDao.java rename to engine/schema/src/com/cloud/network/dao/NetworkAccountDao.java diff --git a/server/src/com/cloud/network/dao/NetworkAccountDaoImpl.java b/engine/schema/src/com/cloud/network/dao/NetworkAccountDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkAccountDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/NetworkAccountDaoImpl.java diff --git a/server/src/com/cloud/network/dao/NetworkAccountVO.java b/engine/schema/src/com/cloud/network/dao/NetworkAccountVO.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkAccountVO.java rename to engine/schema/src/com/cloud/network/dao/NetworkAccountVO.java diff --git a/server/src/com/cloud/network/dao/NetworkDao.java b/engine/schema/src/com/cloud/network/dao/NetworkDao.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkDao.java rename to engine/schema/src/com/cloud/network/dao/NetworkDao.java diff --git a/server/src/com/cloud/network/dao/NetworkDaoImpl.java b/engine/schema/src/com/cloud/network/dao/NetworkDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/NetworkDaoImpl.java diff --git a/server/src/com/cloud/network/dao/NetworkDomainDao.java b/engine/schema/src/com/cloud/network/dao/NetworkDomainDao.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkDomainDao.java rename to engine/schema/src/com/cloud/network/dao/NetworkDomainDao.java diff --git a/server/src/com/cloud/network/dao/NetworkDomainDaoImpl.java b/engine/schema/src/com/cloud/network/dao/NetworkDomainDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkDomainDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/NetworkDomainDaoImpl.java diff --git a/server/src/com/cloud/network/dao/NetworkDomainVO.java b/engine/schema/src/com/cloud/network/dao/NetworkDomainVO.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkDomainVO.java rename to engine/schema/src/com/cloud/network/dao/NetworkDomainVO.java diff --git a/server/src/com/cloud/network/dao/NetworkExternalFirewallDao.java b/engine/schema/src/com/cloud/network/dao/NetworkExternalFirewallDao.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkExternalFirewallDao.java rename to engine/schema/src/com/cloud/network/dao/NetworkExternalFirewallDao.java diff --git a/server/src/com/cloud/network/dao/NetworkExternalFirewallDaoImpl.java b/engine/schema/src/com/cloud/network/dao/NetworkExternalFirewallDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkExternalFirewallDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/NetworkExternalFirewallDaoImpl.java diff --git a/server/src/com/cloud/network/dao/NetworkExternalFirewallVO.java b/engine/schema/src/com/cloud/network/dao/NetworkExternalFirewallVO.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkExternalFirewallVO.java rename to engine/schema/src/com/cloud/network/dao/NetworkExternalFirewallVO.java diff --git a/server/src/com/cloud/network/dao/NetworkExternalLoadBalancerDao.java b/engine/schema/src/com/cloud/network/dao/NetworkExternalLoadBalancerDao.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkExternalLoadBalancerDao.java rename to engine/schema/src/com/cloud/network/dao/NetworkExternalLoadBalancerDao.java diff --git a/server/src/com/cloud/network/dao/NetworkExternalLoadBalancerDaoImpl.java b/engine/schema/src/com/cloud/network/dao/NetworkExternalLoadBalancerDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkExternalLoadBalancerDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/NetworkExternalLoadBalancerDaoImpl.java diff --git a/server/src/com/cloud/network/dao/NetworkExternalLoadBalancerVO.java b/engine/schema/src/com/cloud/network/dao/NetworkExternalLoadBalancerVO.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkExternalLoadBalancerVO.java rename to engine/schema/src/com/cloud/network/dao/NetworkExternalLoadBalancerVO.java diff --git a/server/src/com/cloud/network/dao/NetworkOpDao.java b/engine/schema/src/com/cloud/network/dao/NetworkOpDao.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkOpDao.java rename to engine/schema/src/com/cloud/network/dao/NetworkOpDao.java diff --git a/server/src/com/cloud/network/dao/NetworkOpDaoImpl.java b/engine/schema/src/com/cloud/network/dao/NetworkOpDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkOpDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/NetworkOpDaoImpl.java diff --git a/server/src/com/cloud/network/dao/NetworkOpVO.java b/engine/schema/src/com/cloud/network/dao/NetworkOpVO.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkOpVO.java rename to engine/schema/src/com/cloud/network/dao/NetworkOpVO.java diff --git a/server/src/com/cloud/network/dao/NetworkRuleConfigDao.java b/engine/schema/src/com/cloud/network/dao/NetworkRuleConfigDao.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkRuleConfigDao.java rename to engine/schema/src/com/cloud/network/dao/NetworkRuleConfigDao.java diff --git a/server/src/com/cloud/network/dao/NetworkRuleConfigDaoImpl.java b/engine/schema/src/com/cloud/network/dao/NetworkRuleConfigDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkRuleConfigDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/NetworkRuleConfigDaoImpl.java diff --git a/server/src/com/cloud/network/dao/NetworkRuleConfigVO.java b/engine/schema/src/com/cloud/network/dao/NetworkRuleConfigVO.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkRuleConfigVO.java rename to engine/schema/src/com/cloud/network/dao/NetworkRuleConfigVO.java diff --git a/server/src/com/cloud/network/dao/NetworkServiceMapDao.java b/engine/schema/src/com/cloud/network/dao/NetworkServiceMapDao.java similarity index 95% rename from server/src/com/cloud/network/dao/NetworkServiceMapDao.java rename to engine/schema/src/com/cloud/network/dao/NetworkServiceMapDao.java index 79b97bec0f1..6d401c40d8b 100644 --- a/server/src/com/cloud/network/dao/NetworkServiceMapDao.java +++ b/engine/schema/src/com/cloud/network/dao/NetworkServiceMapDao.java @@ -35,4 +35,5 @@ public interface NetworkServiceMapDao extends GenericDao getDistinctProviders(long networkId); String isProviderForNetwork(long networkId, Provider provider); + List getProvidersForServiceInNetwork(long networkId, Service service); } diff --git a/server/src/com/cloud/network/dao/NetworkServiceMapDaoImpl.java b/engine/schema/src/com/cloud/network/dao/NetworkServiceMapDaoImpl.java similarity index 93% rename from server/src/com/cloud/network/dao/NetworkServiceMapDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/NetworkServiceMapDaoImpl.java index 13fbfbc401f..3cdd73885c8 100644 --- a/server/src/com/cloud/network/dao/NetworkServiceMapDaoImpl.java +++ b/engine/schema/src/com/cloud/network/dao/NetworkServiceMapDaoImpl.java @@ -56,6 +56,7 @@ public class NetworkServiceMapDaoImpl extends GenericDaoBase getProvidersForServiceInNetwork(long networkId, Service service) { + SearchCriteria sc = DistinctProvidersSearch.create(); + sc.setParameters("networkId", networkId); + sc.setParameters("service", service.getName()); + return customSearch(sc, null); + } } diff --git a/server/src/com/cloud/network/dao/NetworkServiceMapVO.java b/engine/schema/src/com/cloud/network/dao/NetworkServiceMapVO.java similarity index 100% rename from server/src/com/cloud/network/dao/NetworkServiceMapVO.java rename to engine/schema/src/com/cloud/network/dao/NetworkServiceMapVO.java diff --git a/server/src/com/cloud/network/dao/NetworkVO.java b/engine/schema/src/com/cloud/network/dao/NetworkVO.java similarity index 99% rename from server/src/com/cloud/network/dao/NetworkVO.java rename to engine/schema/src/com/cloud/network/dao/NetworkVO.java index 77b40c8a5c9..8e728abd984 100644 --- a/server/src/com/cloud/network/dao/NetworkVO.java +++ b/engine/schema/src/com/cloud/network/dao/NetworkVO.java @@ -32,9 +32,6 @@ import javax.persistence.Transient; import org.apache.cloudstack.acl.ControlledEntity; import com.cloud.network.Network; -import com.cloud.network.Networks; -import com.cloud.network.Network.GuestType; -import com.cloud.network.Network.State; import com.cloud.network.Networks.BroadcastDomainType; import com.cloud.network.Networks.Mode; import com.cloud.network.Networks.TrafficType; diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkDao.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkDao.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkDao.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkDao.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkDaoImpl.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkDaoImpl.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkIsolationMethodDaoImpl.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkIsolationMethodDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkIsolationMethodDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkIsolationMethodDaoImpl.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkIsolationMethodVO.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkIsolationMethodVO.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkIsolationMethodVO.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkIsolationMethodVO.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkServiceProviderDao.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkServiceProviderDao.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkServiceProviderDao.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkServiceProviderDao.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkServiceProviderDaoImpl.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkServiceProviderDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkServiceProviderDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkServiceProviderDaoImpl.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkServiceProviderVO.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkServiceProviderVO.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkServiceProviderVO.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkServiceProviderVO.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkTagDaoImpl.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkTagDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkTagDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkTagDaoImpl.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkTagVO.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkTagVO.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkTagVO.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkTagVO.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeDao.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeDao.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeDao.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeDao.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeDaoImpl.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeDaoImpl.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeVO.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeVO.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeVO.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkTrafficTypeVO.java diff --git a/server/src/com/cloud/network/dao/PhysicalNetworkVO.java b/engine/schema/src/com/cloud/network/dao/PhysicalNetworkVO.java similarity index 100% rename from server/src/com/cloud/network/dao/PhysicalNetworkVO.java rename to engine/schema/src/com/cloud/network/dao/PhysicalNetworkVO.java diff --git a/server/src/com/cloud/network/dao/PortProfileDao.java b/engine/schema/src/com/cloud/network/dao/PortProfileDao.java similarity index 100% rename from server/src/com/cloud/network/dao/PortProfileDao.java rename to engine/schema/src/com/cloud/network/dao/PortProfileDao.java diff --git a/server/src/com/cloud/network/dao/PortProfileDaoImpl.java b/engine/schema/src/com/cloud/network/dao/PortProfileDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/PortProfileDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/PortProfileDaoImpl.java diff --git a/server/src/com/cloud/network/dao/PortProfileVO.java b/engine/schema/src/com/cloud/network/dao/PortProfileVO.java similarity index 100% rename from server/src/com/cloud/network/dao/PortProfileVO.java rename to engine/schema/src/com/cloud/network/dao/PortProfileVO.java diff --git a/server/src/com/cloud/network/dao/RemoteAccessVpnDao.java b/engine/schema/src/com/cloud/network/dao/RemoteAccessVpnDao.java similarity index 100% rename from server/src/com/cloud/network/dao/RemoteAccessVpnDao.java rename to engine/schema/src/com/cloud/network/dao/RemoteAccessVpnDao.java diff --git a/server/src/com/cloud/network/dao/RemoteAccessVpnDaoImpl.java b/engine/schema/src/com/cloud/network/dao/RemoteAccessVpnDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/RemoteAccessVpnDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/RemoteAccessVpnDaoImpl.java diff --git a/server/src/com/cloud/network/dao/RemoteAccessVpnVO.java b/engine/schema/src/com/cloud/network/dao/RemoteAccessVpnVO.java similarity index 100% rename from server/src/com/cloud/network/dao/RemoteAccessVpnVO.java rename to engine/schema/src/com/cloud/network/dao/RemoteAccessVpnVO.java diff --git a/server/src/com/cloud/network/dao/RouterNetworkDao.java b/engine/schema/src/com/cloud/network/dao/RouterNetworkDao.java similarity index 100% rename from server/src/com/cloud/network/dao/RouterNetworkDao.java rename to engine/schema/src/com/cloud/network/dao/RouterNetworkDao.java diff --git a/server/src/com/cloud/network/dao/RouterNetworkDaoImpl.java b/engine/schema/src/com/cloud/network/dao/RouterNetworkDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/RouterNetworkDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/RouterNetworkDaoImpl.java diff --git a/server/src/com/cloud/network/dao/RouterNetworkVO.java b/engine/schema/src/com/cloud/network/dao/RouterNetworkVO.java similarity index 100% rename from server/src/com/cloud/network/dao/RouterNetworkVO.java rename to engine/schema/src/com/cloud/network/dao/RouterNetworkVO.java diff --git a/server/src/com/cloud/network/dao/Site2SiteCustomerGatewayDao.java b/engine/schema/src/com/cloud/network/dao/Site2SiteCustomerGatewayDao.java similarity index 100% rename from server/src/com/cloud/network/dao/Site2SiteCustomerGatewayDao.java rename to engine/schema/src/com/cloud/network/dao/Site2SiteCustomerGatewayDao.java diff --git a/server/src/com/cloud/network/dao/Site2SiteCustomerGatewayDaoImpl.java b/engine/schema/src/com/cloud/network/dao/Site2SiteCustomerGatewayDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/Site2SiteCustomerGatewayDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/Site2SiteCustomerGatewayDaoImpl.java diff --git a/server/src/com/cloud/network/dao/Site2SiteCustomerGatewayVO.java b/engine/schema/src/com/cloud/network/dao/Site2SiteCustomerGatewayVO.java similarity index 100% rename from server/src/com/cloud/network/dao/Site2SiteCustomerGatewayVO.java rename to engine/schema/src/com/cloud/network/dao/Site2SiteCustomerGatewayVO.java diff --git a/server/src/com/cloud/network/dao/Site2SiteVpnConnectionDao.java b/engine/schema/src/com/cloud/network/dao/Site2SiteVpnConnectionDao.java similarity index 100% rename from server/src/com/cloud/network/dao/Site2SiteVpnConnectionDao.java rename to engine/schema/src/com/cloud/network/dao/Site2SiteVpnConnectionDao.java diff --git a/server/src/com/cloud/network/dao/Site2SiteVpnConnectionDaoImpl.java b/engine/schema/src/com/cloud/network/dao/Site2SiteVpnConnectionDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/Site2SiteVpnConnectionDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/Site2SiteVpnConnectionDaoImpl.java diff --git a/server/src/com/cloud/network/dao/Site2SiteVpnConnectionVO.java b/engine/schema/src/com/cloud/network/dao/Site2SiteVpnConnectionVO.java similarity index 100% rename from server/src/com/cloud/network/dao/Site2SiteVpnConnectionVO.java rename to engine/schema/src/com/cloud/network/dao/Site2SiteVpnConnectionVO.java diff --git a/server/src/com/cloud/network/dao/Site2SiteVpnGatewayDao.java b/engine/schema/src/com/cloud/network/dao/Site2SiteVpnGatewayDao.java similarity index 100% rename from server/src/com/cloud/network/dao/Site2SiteVpnGatewayDao.java rename to engine/schema/src/com/cloud/network/dao/Site2SiteVpnGatewayDao.java diff --git a/server/src/com/cloud/network/dao/Site2SiteVpnGatewayDaoImpl.java b/engine/schema/src/com/cloud/network/dao/Site2SiteVpnGatewayDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/Site2SiteVpnGatewayDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/Site2SiteVpnGatewayDaoImpl.java diff --git a/server/src/com/cloud/network/dao/Site2SiteVpnGatewayVO.java b/engine/schema/src/com/cloud/network/dao/Site2SiteVpnGatewayVO.java similarity index 100% rename from server/src/com/cloud/network/dao/Site2SiteVpnGatewayVO.java rename to engine/schema/src/com/cloud/network/dao/Site2SiteVpnGatewayVO.java diff --git a/server/src/com/cloud/network/dao/UserIpv6AddressDao.java b/engine/schema/src/com/cloud/network/dao/UserIpv6AddressDao.java similarity index 100% rename from server/src/com/cloud/network/dao/UserIpv6AddressDao.java rename to engine/schema/src/com/cloud/network/dao/UserIpv6AddressDao.java diff --git a/server/src/com/cloud/network/dao/UserIpv6AddressDaoImpl.java b/engine/schema/src/com/cloud/network/dao/UserIpv6AddressDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/UserIpv6AddressDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/UserIpv6AddressDaoImpl.java diff --git a/server/src/com/cloud/network/dao/VirtualRouterProviderDao.java b/engine/schema/src/com/cloud/network/dao/VirtualRouterProviderDao.java similarity index 100% rename from server/src/com/cloud/network/dao/VirtualRouterProviderDao.java rename to engine/schema/src/com/cloud/network/dao/VirtualRouterProviderDao.java diff --git a/server/src/com/cloud/network/dao/VirtualRouterProviderDaoImpl.java b/engine/schema/src/com/cloud/network/dao/VirtualRouterProviderDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/VirtualRouterProviderDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/VirtualRouterProviderDaoImpl.java diff --git a/server/src/com/cloud/network/dao/VpnUserDao.java b/engine/schema/src/com/cloud/network/dao/VpnUserDao.java similarity index 100% rename from server/src/com/cloud/network/dao/VpnUserDao.java rename to engine/schema/src/com/cloud/network/dao/VpnUserDao.java diff --git a/server/src/com/cloud/network/dao/VpnUserDaoImpl.java b/engine/schema/src/com/cloud/network/dao/VpnUserDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/dao/VpnUserDaoImpl.java rename to engine/schema/src/com/cloud/network/dao/VpnUserDaoImpl.java diff --git a/server/src/com/cloud/network/element/VirtualRouterProviderVO.java b/engine/schema/src/com/cloud/network/element/VirtualRouterProviderVO.java similarity index 100% rename from server/src/com/cloud/network/element/VirtualRouterProviderVO.java rename to engine/schema/src/com/cloud/network/element/VirtualRouterProviderVO.java diff --git a/server/src/com/cloud/network/rules/FirewallRuleVO.java b/engine/schema/src/com/cloud/network/rules/FirewallRuleVO.java similarity index 98% rename from server/src/com/cloud/network/rules/FirewallRuleVO.java rename to engine/schema/src/com/cloud/network/rules/FirewallRuleVO.java index a761520ccfe..9f73029349f 100644 --- a/server/src/com/cloud/network/rules/FirewallRuleVO.java +++ b/engine/schema/src/com/cloud/network/rules/FirewallRuleVO.java @@ -20,7 +20,6 @@ import java.util.Date; import java.util.List; import java.util.UUID; -import javax.inject.Inject; import javax.persistence.Column; import javax.persistence.DiscriminatorColumn; import javax.persistence.DiscriminatorType; @@ -35,7 +34,6 @@ import javax.persistence.InheritanceType; import javax.persistence.Table; import javax.persistence.Transient; -import com.cloud.network.dao.FirewallRulesCidrsDao; import com.cloud.utils.db.GenericDao; import com.cloud.utils.net.NetUtils; diff --git a/server/src/com/cloud/network/rules/PortForwardingRuleVO.java b/engine/schema/src/com/cloud/network/rules/PortForwardingRuleVO.java similarity index 100% rename from server/src/com/cloud/network/rules/PortForwardingRuleVO.java rename to engine/schema/src/com/cloud/network/rules/PortForwardingRuleVO.java diff --git a/server/src/com/cloud/network/rules/dao/PortForwardingRulesDao.java b/engine/schema/src/com/cloud/network/rules/dao/PortForwardingRulesDao.java similarity index 100% rename from server/src/com/cloud/network/rules/dao/PortForwardingRulesDao.java rename to engine/schema/src/com/cloud/network/rules/dao/PortForwardingRulesDao.java diff --git a/server/src/com/cloud/network/rules/dao/PortForwardingRulesDaoImpl.java b/engine/schema/src/com/cloud/network/rules/dao/PortForwardingRulesDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/rules/dao/PortForwardingRulesDaoImpl.java rename to engine/schema/src/com/cloud/network/rules/dao/PortForwardingRulesDaoImpl.java diff --git a/core/src/com/cloud/network/security/SecurityGroupRuleVO.java b/engine/schema/src/com/cloud/network/security/SecurityGroupRuleVO.java similarity index 100% rename from core/src/com/cloud/network/security/SecurityGroupRuleVO.java rename to engine/schema/src/com/cloud/network/security/SecurityGroupRuleVO.java diff --git a/core/src/com/cloud/network/security/SecurityGroupRulesVO.java b/engine/schema/src/com/cloud/network/security/SecurityGroupRulesVO.java similarity index 91% rename from core/src/com/cloud/network/security/SecurityGroupRulesVO.java rename to engine/schema/src/com/cloud/network/security/SecurityGroupRulesVO.java index 82060efce12..c74152e453c 100644 --- a/core/src/com/cloud/network/security/SecurityGroupRulesVO.java +++ b/engine/schema/src/com/cloud/network/security/SecurityGroupRulesVO.java @@ -54,6 +54,9 @@ public class SecurityGroupRulesVO implements SecurityGroupRules { @Column(name = "id", table = "security_group_rule", insertable = false, updatable = false) private Long ruleId; + @Column(name = "uuid", table = "security_group_rule", insertable = false, updatable = false) + private String ruleUuid; + @Column(name = "start_port", table = "security_group_rule", insertable = false, updatable = false) private int startPort; @@ -75,7 +78,11 @@ public class SecurityGroupRulesVO implements SecurityGroupRules { public SecurityGroupRulesVO() { } - public SecurityGroupRulesVO(long id, String name, String description, Long domainId, Long accountId, Long ruleId, int startPort, int endPort, String protocol, Long allowedNetworkId, + public SecurityGroupRulesVO(long id) { + this.id = id; + } + + public SecurityGroupRulesVO(long id, String name, String description, Long domainId, Long accountId, Long ruleId, String ruleUuid, int startPort, int endPort, String protocol, Long allowedNetworkId, String allowedSourceIpCidr) { this.id = id; this.name = name; @@ -83,6 +90,7 @@ public class SecurityGroupRulesVO implements SecurityGroupRules { this.domainId = domainId; this.accountId = accountId; this.ruleId = ruleId; + this.ruleUuid = ruleUuid; this.startPort = startPort; this.endPort = endPort; this.protocol = protocol; @@ -120,6 +128,11 @@ public class SecurityGroupRulesVO implements SecurityGroupRules { return ruleId; } + @Override + public String getRuleUuid() { + return ruleUuid; + } + @Override public int getStartPort() { return startPort; diff --git a/core/src/com/cloud/network/security/SecurityGroupVMMapVO.java b/engine/schema/src/com/cloud/network/security/SecurityGroupVMMapVO.java similarity index 100% rename from core/src/com/cloud/network/security/SecurityGroupVMMapVO.java rename to engine/schema/src/com/cloud/network/security/SecurityGroupVMMapVO.java diff --git a/core/src/com/cloud/network/security/SecurityGroupVO.java b/engine/schema/src/com/cloud/network/security/SecurityGroupVO.java similarity index 100% rename from core/src/com/cloud/network/security/SecurityGroupVO.java rename to engine/schema/src/com/cloud/network/security/SecurityGroupVO.java diff --git a/core/src/com/cloud/network/security/SecurityGroupWork.java b/engine/schema/src/com/cloud/network/security/SecurityGroupWork.java similarity index 100% rename from core/src/com/cloud/network/security/SecurityGroupWork.java rename to engine/schema/src/com/cloud/network/security/SecurityGroupWork.java diff --git a/core/src/com/cloud/network/security/SecurityGroupWorkVO.java b/engine/schema/src/com/cloud/network/security/SecurityGroupWorkVO.java similarity index 100% rename from core/src/com/cloud/network/security/SecurityGroupWorkVO.java rename to engine/schema/src/com/cloud/network/security/SecurityGroupWorkVO.java diff --git a/core/src/com/cloud/network/security/VmRulesetLogVO.java b/engine/schema/src/com/cloud/network/security/VmRulesetLogVO.java similarity index 100% rename from core/src/com/cloud/network/security/VmRulesetLogVO.java rename to engine/schema/src/com/cloud/network/security/VmRulesetLogVO.java diff --git a/server/src/com/cloud/network/security/dao/SecurityGroupDao.java b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupDao.java similarity index 100% rename from server/src/com/cloud/network/security/dao/SecurityGroupDao.java rename to engine/schema/src/com/cloud/network/security/dao/SecurityGroupDao.java diff --git a/server/src/com/cloud/network/security/dao/SecurityGroupDaoImpl.java b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/security/dao/SecurityGroupDaoImpl.java rename to engine/schema/src/com/cloud/network/security/dao/SecurityGroupDaoImpl.java diff --git a/server/src/com/cloud/network/security/dao/SecurityGroupRuleDao.java b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupRuleDao.java similarity index 100% rename from server/src/com/cloud/network/security/dao/SecurityGroupRuleDao.java rename to engine/schema/src/com/cloud/network/security/dao/SecurityGroupRuleDao.java diff --git a/server/src/com/cloud/network/security/dao/SecurityGroupRuleDaoImpl.java b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupRuleDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/security/dao/SecurityGroupRuleDaoImpl.java rename to engine/schema/src/com/cloud/network/security/dao/SecurityGroupRuleDaoImpl.java diff --git a/server/src/com/cloud/network/security/dao/SecurityGroupRulesDao.java b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupRulesDao.java similarity index 100% rename from server/src/com/cloud/network/security/dao/SecurityGroupRulesDao.java rename to engine/schema/src/com/cloud/network/security/dao/SecurityGroupRulesDao.java diff --git a/server/src/com/cloud/network/security/dao/SecurityGroupRulesDaoImpl.java b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupRulesDaoImpl.java similarity index 89% rename from server/src/com/cloud/network/security/dao/SecurityGroupRulesDaoImpl.java rename to engine/schema/src/com/cloud/network/security/dao/SecurityGroupRulesDaoImpl.java index f08ca05cd7a..18ef57fbcd8 100644 --- a/server/src/com/cloud/network/security/dao/SecurityGroupRulesDaoImpl.java +++ b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupRulesDaoImpl.java @@ -84,4 +84,13 @@ public class SecurityGroupRulesDaoImpl extends GenericDaoBase sc = createSearchCriteria(); + sc.addAnd("ruleUuid", SearchCriteria.Op.EQ, uuid); + SecurityGroupRulesVO rule = findOneIncludingRemovedBy(sc); + SecurityGroupRulesVO newRule = new SecurityGroupRulesVO(rule.getRuleId()); + return newRule; + } } diff --git a/server/src/com/cloud/network/security/dao/SecurityGroupVMMapDao.java b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupVMMapDao.java similarity index 100% rename from server/src/com/cloud/network/security/dao/SecurityGroupVMMapDao.java rename to engine/schema/src/com/cloud/network/security/dao/SecurityGroupVMMapDao.java diff --git a/server/src/com/cloud/network/security/dao/SecurityGroupVMMapDaoImpl.java b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupVMMapDaoImpl.java similarity index 100% rename from server/src/com/cloud/network/security/dao/SecurityGroupVMMapDaoImpl.java rename to engine/schema/src/com/cloud/network/security/dao/SecurityGroupVMMapDaoImpl.java diff --git a/server/src/com/cloud/network/security/dao/SecurityGroupWorkDao.java b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupWorkDao.java similarity index 100% rename from server/src/com/cloud/network/security/dao/SecurityGroupWorkDao.java rename to engine/schema/src/com/cloud/network/security/dao/SecurityGroupWorkDao.java diff --git a/server/src/com/cloud/network/security/dao/SecurityGroupWorkDaoImpl.java b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupWorkDaoImpl.java similarity index 93% rename from server/src/com/cloud/network/security/dao/SecurityGroupWorkDaoImpl.java rename to engine/schema/src/com/cloud/network/security/dao/SecurityGroupWorkDaoImpl.java index dcd1238186e..3154ffeb873 100644 --- a/server/src/com/cloud/network/security/dao/SecurityGroupWorkDaoImpl.java +++ b/engine/schema/src/com/cloud/network/security/dao/SecurityGroupWorkDaoImpl.java @@ -24,17 +24,16 @@ import javax.ejb.Local; import org.apache.log4j.Logger; import org.springframework.stereotype.Component; -import com.cloud.ha.HaWorkVO; import com.cloud.network.security.SecurityGroupWork; -import com.cloud.network.security.SecurityGroupWorkVO; import com.cloud.network.security.SecurityGroupWork.Step; +import com.cloud.network.security.SecurityGroupWorkVO; import com.cloud.utils.db.DB; import com.cloud.utils.db.Filter; import com.cloud.utils.db.GenericDaoBase; import com.cloud.utils.db.SearchBuilder; import com.cloud.utils.db.SearchCriteria; -import com.cloud.utils.db.Transaction; import com.cloud.utils.db.SearchCriteria.Op; +import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; @Component @@ -42,12 +41,12 @@ import com.cloud.utils.exception.CloudRuntimeException; public class SecurityGroupWorkDaoImpl extends GenericDaoBase implements SecurityGroupWorkDao { private static final Logger s_logger = Logger.getLogger(SecurityGroupWorkDaoImpl.class); - private SearchBuilder VmIdTakenSearch; - private SearchBuilder VmIdSeqNumSearch; - private SearchBuilder VmIdUnTakenSearch; - private SearchBuilder UntakenWorkSearch; - private SearchBuilder VmIdStepSearch; - private SearchBuilder CleanupSearch; + private final SearchBuilder VmIdTakenSearch; + private final SearchBuilder VmIdSeqNumSearch; + private final SearchBuilder VmIdUnTakenSearch; + private final SearchBuilder UntakenWorkSearch; + private final SearchBuilder VmIdStepSearch; + private final SearchBuilder CleanupSearch; protected SecurityGroupWorkDaoImpl() { @@ -56,38 +55,38 @@ public class SecurityGroupWorkDaoImpl extends GenericDaoBase sc = VmIdSeqNumSearch.create(); sc.setParameters("vmId", vmId); sc.setParameters("seqno", logSequenceNumber); - - final Filter filter = new Filter(HaWorkVO.class, null, true, 0l, 1l); + + final Filter filter = new Filter(SecurityGroupWorkVO.class, null, true, 0l, 1l); final List vos = lockRows(sc, filter, true); if (vos.size() == 0) { @@ -183,7 +182,7 @@ public class SecurityGroupWorkDaoImpl extends GenericDaoBase result = listIncludingRemovedBy(sc); - + return result; } - + @Override public List findAndCleanupUnfinishedWork(Date timeBefore) { final SearchCriteria sc = CleanupSearch.create(); @@ -230,7 +229,7 @@ public class SecurityGroupWorkDaoImpl extends GenericDaoBase findScheduledWork() { final SearchCriteria sc = UntakenWorkSearch.create(); @@ -238,5 +237,5 @@ public class SecurityGroupWorkDaoImpl extends GenericDaoBase List listByTrafficTypeGuestTypeAndState(NetworkOffering.State state, TrafficType trafficType, Network.GuestType type); + NetworkOfferingVO persist(NetworkOfferingVO off, Map details); + } diff --git a/server/src/com/cloud/offerings/dao/NetworkOfferingDaoImpl.java b/engine/schema/src/com/cloud/offerings/dao/NetworkOfferingDaoImpl.java similarity index 89% rename from server/src/com/cloud/offerings/dao/NetworkOfferingDaoImpl.java rename to engine/schema/src/com/cloud/offerings/dao/NetworkOfferingDaoImpl.java index d1e44242d2a..ef8237a48f5 100644 --- a/server/src/com/cloud/offerings/dao/NetworkOfferingDaoImpl.java +++ b/engine/schema/src/com/cloud/offerings/dao/NetworkOfferingDaoImpl.java @@ -17,8 +17,10 @@ package com.cloud.offerings.dao; import java.util.List; +import java.util.Map; import javax.ejb.Local; +import javax.inject.Inject; import javax.persistence.EntityExistsException; import org.springframework.stereotype.Component; @@ -27,6 +29,8 @@ import com.cloud.network.Network; import com.cloud.network.Networks.TrafficType; import com.cloud.offering.NetworkOffering; import com.cloud.offering.NetworkOffering.Availability; +import com.cloud.offering.NetworkOffering.Detail; +import com.cloud.offerings.NetworkOfferingDetailsVO; import com.cloud.offerings.NetworkOfferingVO; import com.cloud.utils.db.DB; import com.cloud.utils.db.GenericDaoBase; @@ -45,6 +49,7 @@ public class NetworkOfferingDaoImpl extends GenericDaoBase AvailabilitySearch; final SearchBuilder AllFieldsSearch; private final GenericSearchBuilder UpgradeSearch; + @Inject NetworkOfferingDetailsDao _detailsDao; protected NetworkOfferingDaoImpl() { super(); @@ -165,5 +170,24 @@ public class NetworkOfferingDaoImpl extends GenericDaoBase details) { + Transaction txn = Transaction.currentTxn(); + txn.start(); + //1) persist the offering + NetworkOfferingVO vo = super.persist(off); + + //2) persist the details + if (details != null && !details.isEmpty()) { + for (NetworkOffering.Detail detail : details.keySet()) { + _detailsDao.persist(new NetworkOfferingDetailsVO(off.getId(), detail, details.get(detail))); + } + } + + txn.commit(); + return vo; + } } diff --git a/server/src/com/cloud/maint/dao/AgentUpgradeDaoImpl.java b/engine/schema/src/com/cloud/offerings/dao/NetworkOfferingDetailsDao.java similarity index 63% rename from server/src/com/cloud/maint/dao/AgentUpgradeDaoImpl.java rename to engine/schema/src/com/cloud/offerings/dao/NetworkOfferingDetailsDao.java index 80c6d851aef..ce209e04694 100644 --- a/server/src/com/cloud/maint/dao/AgentUpgradeDaoImpl.java +++ b/engine/schema/src/com/cloud/offerings/dao/NetworkOfferingDetailsDao.java @@ -14,16 +14,18 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -package com.cloud.maint.dao; +package com.cloud.offerings.dao; -import javax.ejb.Local; -import org.springframework.stereotype.Component; +import java.util.Map; -import com.cloud.maint.AgentUpgradeVO; -import com.cloud.utils.db.GenericDaoBase; +import com.cloud.offering.NetworkOffering; +import com.cloud.offering.NetworkOffering.Detail; +import com.cloud.offerings.NetworkOfferingDetailsVO; +import com.cloud.utils.db.GenericDao; -@Component -@Local(AgentUpgradeDao.class) -public class AgentUpgradeDaoImpl extends GenericDaoBase implements AgentUpgradeDao { +public interface NetworkOfferingDetailsDao extends GenericDao{ + + Map getNtwkOffDetails(long offeringId); + String getDetail(long offeringId, Detail detailName); } diff --git a/engine/schema/src/com/cloud/offerings/dao/NetworkOfferingDetailsDaoImpl.java b/engine/schema/src/com/cloud/offerings/dao/NetworkOfferingDetailsDaoImpl.java new file mode 100644 index 00000000000..068f3908b8d --- /dev/null +++ b/engine/schema/src/com/cloud/offerings/dao/NetworkOfferingDetailsDaoImpl.java @@ -0,0 +1,79 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.offerings.dao; + +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import com.cloud.offering.NetworkOffering; +import com.cloud.offering.NetworkOffering.Detail; +import com.cloud.offerings.NetworkOfferingDetailsVO; +import com.cloud.utils.db.GenericDaoBase; +import com.cloud.utils.db.GenericSearchBuilder; +import com.cloud.utils.db.SearchBuilder; +import com.cloud.utils.db.SearchCriteria; +import com.cloud.utils.db.SearchCriteria.Func; +import com.cloud.utils.db.SearchCriteria.Op; + +public class NetworkOfferingDetailsDaoImpl extends GenericDaoBase implements NetworkOfferingDetailsDao{ + protected final SearchBuilder DetailSearch; + private final GenericSearchBuilder ValueSearch; + + + public NetworkOfferingDetailsDaoImpl() { + + DetailSearch = createSearchBuilder(); + DetailSearch.and("offeringId", DetailSearch.entity().getOfferingId(), SearchCriteria.Op.EQ); + DetailSearch.and("name", DetailSearch.entity().getName(), SearchCriteria.Op.EQ); + DetailSearch.done(); + + ValueSearch = createSearchBuilder(String.class); + ValueSearch.select(null, Func.DISTINCT, ValueSearch.entity().getValue()); + ValueSearch.and("offeringId", ValueSearch.entity().getOfferingId(), SearchCriteria.Op.EQ); + ValueSearch.and("name", ValueSearch.entity().getName(), Op.EQ); + ValueSearch.done(); + } + + @Override + public Map getNtwkOffDetails(long offeringId) { + SearchCriteria sc = DetailSearch.create(); + sc.setParameters("offeringId", offeringId); + + List results = search(sc, null); + Map details = new HashMap(results.size()); + for (NetworkOfferingDetailsVO result : results) { + details.put(result.getName(), result.getValue()); + } + + return details; + } + + @Override + public String getDetail(long offeringId, Detail detailName) { + SearchCriteria sc = ValueSearch.create(); + sc.setParameters("name", detailName); + sc.setParameters("offeringId", offeringId); + List results = customSearch(sc, null); + if (results.isEmpty()) { + return null; + } else { + return results.get(0); + } + } + +} diff --git a/server/src/com/cloud/offerings/dao/NetworkOfferingServiceMapDao.java b/engine/schema/src/com/cloud/offerings/dao/NetworkOfferingServiceMapDao.java similarity index 100% rename from server/src/com/cloud/offerings/dao/NetworkOfferingServiceMapDao.java rename to engine/schema/src/com/cloud/offerings/dao/NetworkOfferingServiceMapDao.java diff --git a/server/src/com/cloud/offerings/dao/NetworkOfferingServiceMapDaoImpl.java b/engine/schema/src/com/cloud/offerings/dao/NetworkOfferingServiceMapDaoImpl.java similarity index 100% rename from server/src/com/cloud/offerings/dao/NetworkOfferingServiceMapDaoImpl.java rename to engine/schema/src/com/cloud/offerings/dao/NetworkOfferingServiceMapDaoImpl.java diff --git a/server/src/com/cloud/projects/ProjectAccountVO.java b/engine/schema/src/com/cloud/projects/ProjectAccountVO.java similarity index 100% rename from server/src/com/cloud/projects/ProjectAccountVO.java rename to engine/schema/src/com/cloud/projects/ProjectAccountVO.java diff --git a/server/src/com/cloud/projects/ProjectInvitationVO.java b/engine/schema/src/com/cloud/projects/ProjectInvitationVO.java similarity index 100% rename from server/src/com/cloud/projects/ProjectInvitationVO.java rename to engine/schema/src/com/cloud/projects/ProjectInvitationVO.java diff --git a/server/src/com/cloud/projects/ProjectVO.java b/engine/schema/src/com/cloud/projects/ProjectVO.java similarity index 100% rename from server/src/com/cloud/projects/ProjectVO.java rename to engine/schema/src/com/cloud/projects/ProjectVO.java diff --git a/server/src/com/cloud/projects/dao/ProjectAccountDao.java b/engine/schema/src/com/cloud/projects/dao/ProjectAccountDao.java similarity index 100% rename from server/src/com/cloud/projects/dao/ProjectAccountDao.java rename to engine/schema/src/com/cloud/projects/dao/ProjectAccountDao.java diff --git a/server/src/com/cloud/projects/dao/ProjectAccountDaoImpl.java b/engine/schema/src/com/cloud/projects/dao/ProjectAccountDaoImpl.java similarity index 100% rename from server/src/com/cloud/projects/dao/ProjectAccountDaoImpl.java rename to engine/schema/src/com/cloud/projects/dao/ProjectAccountDaoImpl.java diff --git a/server/src/com/cloud/projects/dao/ProjectDao.java b/engine/schema/src/com/cloud/projects/dao/ProjectDao.java similarity index 100% rename from server/src/com/cloud/projects/dao/ProjectDao.java rename to engine/schema/src/com/cloud/projects/dao/ProjectDao.java diff --git a/server/src/com/cloud/projects/dao/ProjectDaoImpl.java b/engine/schema/src/com/cloud/projects/dao/ProjectDaoImpl.java similarity index 100% rename from server/src/com/cloud/projects/dao/ProjectDaoImpl.java rename to engine/schema/src/com/cloud/projects/dao/ProjectDaoImpl.java diff --git a/server/src/com/cloud/projects/dao/ProjectInvitationDao.java b/engine/schema/src/com/cloud/projects/dao/ProjectInvitationDao.java similarity index 100% rename from server/src/com/cloud/projects/dao/ProjectInvitationDao.java rename to engine/schema/src/com/cloud/projects/dao/ProjectInvitationDao.java diff --git a/server/src/com/cloud/projects/dao/ProjectInvitationDaoImpl.java b/engine/schema/src/com/cloud/projects/dao/ProjectInvitationDaoImpl.java similarity index 100% rename from server/src/com/cloud/projects/dao/ProjectInvitationDaoImpl.java rename to engine/schema/src/com/cloud/projects/dao/ProjectInvitationDaoImpl.java diff --git a/server/src/com/cloud/secstorage/CommandExecLogDao.java b/engine/schema/src/com/cloud/secstorage/CommandExecLogDao.java similarity index 100% rename from server/src/com/cloud/secstorage/CommandExecLogDao.java rename to engine/schema/src/com/cloud/secstorage/CommandExecLogDao.java diff --git a/server/src/com/cloud/secstorage/CommandExecLogDaoImpl.java b/engine/schema/src/com/cloud/secstorage/CommandExecLogDaoImpl.java similarity index 100% rename from server/src/com/cloud/secstorage/CommandExecLogDaoImpl.java rename to engine/schema/src/com/cloud/secstorage/CommandExecLogDaoImpl.java diff --git a/server/src/com/cloud/secstorage/CommandExecLogVO.java b/engine/schema/src/com/cloud/secstorage/CommandExecLogVO.java similarity index 100% rename from server/src/com/cloud/secstorage/CommandExecLogVO.java rename to engine/schema/src/com/cloud/secstorage/CommandExecLogVO.java diff --git a/server/src/com/cloud/service/ServiceOfferingVO.java b/engine/schema/src/com/cloud/service/ServiceOfferingVO.java similarity index 100% rename from server/src/com/cloud/service/ServiceOfferingVO.java rename to engine/schema/src/com/cloud/service/ServiceOfferingVO.java diff --git a/server/src/com/cloud/service/dao/ServiceOfferingDao.java b/engine/schema/src/com/cloud/service/dao/ServiceOfferingDao.java similarity index 100% rename from server/src/com/cloud/service/dao/ServiceOfferingDao.java rename to engine/schema/src/com/cloud/service/dao/ServiceOfferingDao.java diff --git a/server/src/com/cloud/service/dao/ServiceOfferingDaoImpl.java b/engine/schema/src/com/cloud/service/dao/ServiceOfferingDaoImpl.java similarity index 100% rename from server/src/com/cloud/service/dao/ServiceOfferingDaoImpl.java rename to engine/schema/src/com/cloud/service/dao/ServiceOfferingDaoImpl.java diff --git a/core/src/com/cloud/storage/DiskOfferingVO.java b/engine/schema/src/com/cloud/storage/DiskOfferingVO.java similarity index 100% rename from core/src/com/cloud/storage/DiskOfferingVO.java rename to engine/schema/src/com/cloud/storage/DiskOfferingVO.java diff --git a/core/src/com/cloud/storage/GuestOSCategoryVO.java b/engine/schema/src/com/cloud/storage/GuestOSCategoryVO.java similarity index 100% rename from core/src/com/cloud/storage/GuestOSCategoryVO.java rename to engine/schema/src/com/cloud/storage/GuestOSCategoryVO.java diff --git a/core/src/com/cloud/storage/GuestOSVO.java b/engine/schema/src/com/cloud/storage/GuestOSVO.java similarity index 100% rename from core/src/com/cloud/storage/GuestOSVO.java rename to engine/schema/src/com/cloud/storage/GuestOSVO.java diff --git a/core/src/com/cloud/storage/LaunchPermissionVO.java b/engine/schema/src/com/cloud/storage/LaunchPermissionVO.java similarity index 100% rename from core/src/com/cloud/storage/LaunchPermissionVO.java rename to engine/schema/src/com/cloud/storage/LaunchPermissionVO.java diff --git a/core/src/com/cloud/storage/S3VO.java b/engine/schema/src/com/cloud/storage/S3VO.java similarity index 100% rename from core/src/com/cloud/storage/S3VO.java rename to engine/schema/src/com/cloud/storage/S3VO.java diff --git a/core/src/com/cloud/storage/SnapshotPolicyVO.java b/engine/schema/src/com/cloud/storage/SnapshotPolicyVO.java similarity index 100% rename from core/src/com/cloud/storage/SnapshotPolicyVO.java rename to engine/schema/src/com/cloud/storage/SnapshotPolicyVO.java diff --git a/core/src/com/cloud/storage/SnapshotScheduleVO.java b/engine/schema/src/com/cloud/storage/SnapshotScheduleVO.java similarity index 100% rename from core/src/com/cloud/storage/SnapshotScheduleVO.java rename to engine/schema/src/com/cloud/storage/SnapshotScheduleVO.java diff --git a/core/src/com/cloud/storage/SnapshotVO.java b/engine/schema/src/com/cloud/storage/SnapshotVO.java similarity index 100% rename from core/src/com/cloud/storage/SnapshotVO.java rename to engine/schema/src/com/cloud/storage/SnapshotVO.java diff --git a/core/src/com/cloud/storage/StoragePoolHostAssoc.java b/engine/schema/src/com/cloud/storage/StoragePoolHostAssoc.java similarity index 100% rename from core/src/com/cloud/storage/StoragePoolHostAssoc.java rename to engine/schema/src/com/cloud/storage/StoragePoolHostAssoc.java diff --git a/core/src/com/cloud/storage/StoragePoolHostVO.java b/engine/schema/src/com/cloud/storage/StoragePoolHostVO.java similarity index 94% rename from core/src/com/cloud/storage/StoragePoolHostVO.java rename to engine/schema/src/com/cloud/storage/StoragePoolHostVO.java index a8a2bac4886..1b02f6d9754 100644 --- a/core/src/com/cloud/storage/StoragePoolHostVO.java +++ b/engine/schema/src/com/cloud/storage/StoragePoolHostVO.java @@ -28,7 +28,6 @@ import javax.persistence.Temporal; import javax.persistence.TemporalType; import com.cloud.utils.db.GenericDaoBase; -import org.apache.cloudstack.api.InternalIdentity; /** * Join table for storage pools and hosts @@ -40,24 +39,24 @@ public class StoragePoolHostVO implements StoragePoolHostAssoc { @Id @GeneratedValue(strategy=GenerationType.IDENTITY) private Long id; - + @Column(name="pool_id") private long poolId; - + @Column(name="host_id") private long hostId; - + @Column(name="local_path") private String localPath; - + @Column(name=GenericDaoBase.CREATED_COLUMN) - private Date created = null; - + private Date created = null; + @Column(name="last_updated") @Temporal(value=TemporalType.TIMESTAMP) - private Date lastUpdated = null; - - + private Date lastUpdated = null; + + public StoragePoolHostVO() { super(); } @@ -76,6 +75,7 @@ public class StoragePoolHostVO implements StoragePoolHostAssoc { } + @Override public long getId() { return id; } diff --git a/core/src/com/cloud/storage/StoragePoolWorkVO.java b/engine/schema/src/com/cloud/storage/StoragePoolWorkVO.java similarity index 100% rename from core/src/com/cloud/storage/StoragePoolWorkVO.java rename to engine/schema/src/com/cloud/storage/StoragePoolWorkVO.java diff --git a/core/src/com/cloud/storage/SwiftVO.java b/engine/schema/src/com/cloud/storage/SwiftVO.java similarity index 100% rename from core/src/com/cloud/storage/SwiftVO.java rename to engine/schema/src/com/cloud/storage/SwiftVO.java diff --git a/core/src/com/cloud/storage/UploadVO.java b/engine/schema/src/com/cloud/storage/UploadVO.java similarity index 100% rename from core/src/com/cloud/storage/UploadVO.java rename to engine/schema/src/com/cloud/storage/UploadVO.java diff --git a/core/src/com/cloud/storage/VMTemplateDetailVO.java b/engine/schema/src/com/cloud/storage/VMTemplateDetailVO.java similarity index 100% rename from core/src/com/cloud/storage/VMTemplateDetailVO.java rename to engine/schema/src/com/cloud/storage/VMTemplateDetailVO.java diff --git a/core/src/com/cloud/storage/VMTemplateHostVO.java b/engine/schema/src/com/cloud/storage/VMTemplateHostVO.java similarity index 100% rename from core/src/com/cloud/storage/VMTemplateHostVO.java rename to engine/schema/src/com/cloud/storage/VMTemplateHostVO.java diff --git a/core/src/com/cloud/storage/VMTemplateS3VO.java b/engine/schema/src/com/cloud/storage/VMTemplateS3VO.java similarity index 100% rename from core/src/com/cloud/storage/VMTemplateS3VO.java rename to engine/schema/src/com/cloud/storage/VMTemplateS3VO.java diff --git a/core/src/com/cloud/storage/VMTemplateStoragePoolVO.java b/engine/schema/src/com/cloud/storage/VMTemplateStoragePoolVO.java similarity index 100% rename from core/src/com/cloud/storage/VMTemplateStoragePoolVO.java rename to engine/schema/src/com/cloud/storage/VMTemplateStoragePoolVO.java diff --git a/core/src/com/cloud/storage/VMTemplateSwiftVO.java b/engine/schema/src/com/cloud/storage/VMTemplateSwiftVO.java similarity index 100% rename from core/src/com/cloud/storage/VMTemplateSwiftVO.java rename to engine/schema/src/com/cloud/storage/VMTemplateSwiftVO.java diff --git a/core/src/com/cloud/storage/VMTemplateVO.java b/engine/schema/src/com/cloud/storage/VMTemplateVO.java similarity index 100% rename from core/src/com/cloud/storage/VMTemplateVO.java rename to engine/schema/src/com/cloud/storage/VMTemplateVO.java diff --git a/core/src/com/cloud/storage/VMTemplateZoneVO.java b/engine/schema/src/com/cloud/storage/VMTemplateZoneVO.java similarity index 100% rename from core/src/com/cloud/storage/VMTemplateZoneVO.java rename to engine/schema/src/com/cloud/storage/VMTemplateZoneVO.java diff --git a/core/src/com/cloud/storage/VolumeHostVO.java b/engine/schema/src/com/cloud/storage/VolumeHostVO.java similarity index 100% rename from core/src/com/cloud/storage/VolumeHostVO.java rename to engine/schema/src/com/cloud/storage/VolumeHostVO.java diff --git a/core/src/com/cloud/storage/VolumeVO.java b/engine/schema/src/com/cloud/storage/VolumeVO.java similarity index 100% rename from core/src/com/cloud/storage/VolumeVO.java rename to engine/schema/src/com/cloud/storage/VolumeVO.java diff --git a/server/src/com/cloud/storage/dao/DiskOfferingDao.java b/engine/schema/src/com/cloud/storage/dao/DiskOfferingDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/DiskOfferingDao.java rename to engine/schema/src/com/cloud/storage/dao/DiskOfferingDao.java diff --git a/server/src/com/cloud/storage/dao/DiskOfferingDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/DiskOfferingDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/DiskOfferingDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/DiskOfferingDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/GuestOSCategoryDao.java b/engine/schema/src/com/cloud/storage/dao/GuestOSCategoryDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/GuestOSCategoryDao.java rename to engine/schema/src/com/cloud/storage/dao/GuestOSCategoryDao.java diff --git a/server/src/com/cloud/storage/dao/GuestOSCategoryDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/GuestOSCategoryDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/GuestOSCategoryDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/GuestOSCategoryDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/GuestOSDao.java b/engine/schema/src/com/cloud/storage/dao/GuestOSDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/GuestOSDao.java rename to engine/schema/src/com/cloud/storage/dao/GuestOSDao.java diff --git a/server/src/com/cloud/storage/dao/GuestOSDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/GuestOSDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/GuestOSDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/GuestOSDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/LaunchPermissionDao.java b/engine/schema/src/com/cloud/storage/dao/LaunchPermissionDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/LaunchPermissionDao.java rename to engine/schema/src/com/cloud/storage/dao/LaunchPermissionDao.java diff --git a/server/src/com/cloud/storage/dao/LaunchPermissionDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/LaunchPermissionDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/LaunchPermissionDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/LaunchPermissionDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/S3Dao.java b/engine/schema/src/com/cloud/storage/dao/S3Dao.java similarity index 100% rename from server/src/com/cloud/storage/dao/S3Dao.java rename to engine/schema/src/com/cloud/storage/dao/S3Dao.java diff --git a/server/src/com/cloud/storage/dao/S3DaoImpl.java b/engine/schema/src/com/cloud/storage/dao/S3DaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/S3DaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/S3DaoImpl.java diff --git a/server/src/com/cloud/storage/dao/SnapshotDao.java b/engine/schema/src/com/cloud/storage/dao/SnapshotDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/SnapshotDao.java rename to engine/schema/src/com/cloud/storage/dao/SnapshotDao.java diff --git a/server/src/com/cloud/storage/dao/SnapshotDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/SnapshotDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/SnapshotDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/SnapshotDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/SnapshotPolicyDao.java b/engine/schema/src/com/cloud/storage/dao/SnapshotPolicyDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/SnapshotPolicyDao.java rename to engine/schema/src/com/cloud/storage/dao/SnapshotPolicyDao.java diff --git a/server/src/com/cloud/storage/dao/SnapshotPolicyDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/SnapshotPolicyDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/SnapshotPolicyDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/SnapshotPolicyDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/SnapshotScheduleDao.java b/engine/schema/src/com/cloud/storage/dao/SnapshotScheduleDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/SnapshotScheduleDao.java rename to engine/schema/src/com/cloud/storage/dao/SnapshotScheduleDao.java diff --git a/server/src/com/cloud/storage/dao/SnapshotScheduleDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/SnapshotScheduleDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/SnapshotScheduleDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/SnapshotScheduleDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/StoragePoolDetailsDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/StoragePoolDetailsDaoImpl.java similarity index 97% rename from server/src/com/cloud/storage/dao/StoragePoolDetailsDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/StoragePoolDetailsDaoImpl.java index a0d5d0e6e97..38b525330f2 100644 --- a/server/src/com/cloud/storage/dao/StoragePoolDetailsDaoImpl.java +++ b/engine/schema/src/com/cloud/storage/dao/StoragePoolDetailsDaoImpl.java @@ -41,6 +41,7 @@ public class StoragePoolDetailsDaoImpl extends GenericDaoBase, StateDao< VMTemplateVO findSystemVMTemplate(long zoneId); VMTemplateVO findSystemVMTemplate(long zoneId, HypervisorType hType); - VMTemplateVO findRoutingTemplate(HypervisorType type); + VMTemplateVO findRoutingTemplate(HypervisorType type, String templateName); List listPrivateTemplatesByHost(Long hostId); public Long countTemplatesForAccount(long accountId); diff --git a/server/src/com/cloud/storage/dao/VMTemplateDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/VMTemplateDaoImpl.java similarity index 98% rename from server/src/com/cloud/storage/dao/VMTemplateDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplateDaoImpl.java index 3b37f24c5cb..25ae933740d 100755 --- a/server/src/com/cloud/storage/dao/VMTemplateDaoImpl.java +++ b/engine/schema/src/com/cloud/storage/dao/VMTemplateDaoImpl.java @@ -353,6 +353,7 @@ public class VMTemplateDaoImpl extends GenericDaoBase implem tmpltTypeHyperSearch2 = createSearchBuilder(); tmpltTypeHyperSearch2.and("templateType", tmpltTypeHyperSearch2.entity().getTemplateType(), SearchCriteria.Op.EQ); tmpltTypeHyperSearch2.and("hypervisorType", tmpltTypeHyperSearch2.entity().getHypervisorType(), SearchCriteria.Op.EQ); + tmpltTypeHyperSearch2.and("templateName", tmpltTypeHyperSearch2.entity().getName(), SearchCriteria.Op.EQ); tmpltTypeSearch = createSearchBuilder(); @@ -561,10 +562,15 @@ public class VMTemplateDaoImpl extends GenericDaoBase implem sql = SELECT_TEMPLATE_HOST_REF; groupByClause = " GROUP BY t.id, h.data_center_id "; } - if (((templateFilter == TemplateFilter.featured) || (templateFilter == TemplateFilter.community)) ||(zoneType != null && zoneId != null)) { + if ((templateFilter == TemplateFilter.featured) || (templateFilter == TemplateFilter.community)) { dataCenterJoin = " INNER JOIN data_center dc on (h.data_center_id = dc.id)"; } - + + if (zoneType != null) { + dataCenterJoin = " INNER JOIN template_host_ref thr on (t.id = thr.template_id) INNER JOIN host h on (thr.host_id = h.id)"; + dataCenterJoin += " INNER JOIN data_center dc on (h.data_center_id = dc.id)"; + } + if (templateFilter == TemplateFilter.sharedexecutable || templateFilter == TemplateFilter.shared ){ lpjoin = " INNER JOIN launch_permission lp ON t.id = lp.template_id "; } @@ -782,13 +788,15 @@ public class VMTemplateDaoImpl extends GenericDaoBase implem sql += " AND h.data_center_id = " +zoneId; } }else if (zoneId != null){ - sql += " AND tzr.zone_id = " +zoneId+ " AND tzr.removed is null" ; - if (zoneType != null){ - sql += " AND dc.networktype = " + zoneType; - } + sql += " AND tzr.zone_id = " +zoneId+ " AND tzr.removed is null" ; }else{ sql += " AND tzr.removed is null "; } + + if (zoneType != null){ + sql += " AND dc.networktype = '" + zoneType + "'"; + } + if (!showDomr){ sql += " AND t.type != '" +Storage.TemplateType.SYSTEM.toString() + "'"; } @@ -897,10 +905,13 @@ public class VMTemplateDaoImpl extends GenericDaoBase implem } @Override - public VMTemplateVO findRoutingTemplate(HypervisorType hType) { + public VMTemplateVO findRoutingTemplate(HypervisorType hType, String templateName) { SearchCriteria sc = tmpltTypeHyperSearch2.create(); sc.setParameters("templateType", Storage.TemplateType.SYSTEM); sc.setParameters("hypervisorType", hType); + if (templateName != null) { + sc.setParameters("templateName", templateName); + } //order by descending order of id and select the first (this is going to be the latest) List tmplts = listBy(sc, new Filter(VMTemplateVO.class, "id", false, null, 1l)); diff --git a/server/src/com/cloud/storage/dao/VMTemplateDetailsDao.java b/engine/schema/src/com/cloud/storage/dao/VMTemplateDetailsDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplateDetailsDao.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplateDetailsDao.java diff --git a/server/src/com/cloud/storage/dao/VMTemplateDetailsDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/VMTemplateDetailsDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplateDetailsDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplateDetailsDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/VMTemplateHostDao.java b/engine/schema/src/com/cloud/storage/dao/VMTemplateHostDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplateHostDao.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplateHostDao.java diff --git a/server/src/com/cloud/storage/dao/VMTemplateHostDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/VMTemplateHostDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplateHostDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplateHostDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/VMTemplatePoolDao.java b/engine/schema/src/com/cloud/storage/dao/VMTemplatePoolDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplatePoolDao.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplatePoolDao.java diff --git a/server/src/com/cloud/storage/dao/VMTemplatePoolDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/VMTemplatePoolDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplatePoolDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplatePoolDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/VMTemplateS3Dao.java b/engine/schema/src/com/cloud/storage/dao/VMTemplateS3Dao.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplateS3Dao.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplateS3Dao.java diff --git a/server/src/com/cloud/storage/dao/VMTemplateS3DaoImpl.java b/engine/schema/src/com/cloud/storage/dao/VMTemplateS3DaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplateS3DaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplateS3DaoImpl.java diff --git a/server/src/com/cloud/storage/dao/VMTemplateSwiftDao.java b/engine/schema/src/com/cloud/storage/dao/VMTemplateSwiftDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplateSwiftDao.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplateSwiftDao.java diff --git a/server/src/com/cloud/storage/dao/VMTemplateSwiftDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/VMTemplateSwiftDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplateSwiftDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplateSwiftDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/VMTemplateZoneDao.java b/engine/schema/src/com/cloud/storage/dao/VMTemplateZoneDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplateZoneDao.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplateZoneDao.java diff --git a/server/src/com/cloud/storage/dao/VMTemplateZoneDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/VMTemplateZoneDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/VMTemplateZoneDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/VMTemplateZoneDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/VolumeDao.java b/engine/schema/src/com/cloud/storage/dao/VolumeDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/VolumeDao.java rename to engine/schema/src/com/cloud/storage/dao/VolumeDao.java diff --git a/server/src/com/cloud/storage/dao/VolumeDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/VolumeDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/VolumeDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/VolumeDaoImpl.java diff --git a/server/src/com/cloud/storage/dao/VolumeHostDao.java b/engine/schema/src/com/cloud/storage/dao/VolumeHostDao.java similarity index 100% rename from server/src/com/cloud/storage/dao/VolumeHostDao.java rename to engine/schema/src/com/cloud/storage/dao/VolumeHostDao.java diff --git a/server/src/com/cloud/storage/dao/VolumeHostDaoImpl.java b/engine/schema/src/com/cloud/storage/dao/VolumeHostDaoImpl.java similarity index 100% rename from server/src/com/cloud/storage/dao/VolumeHostDaoImpl.java rename to engine/schema/src/com/cloud/storage/dao/VolumeHostDaoImpl.java diff --git a/server/src/com/cloud/tags/ResourceTagVO.java b/engine/schema/src/com/cloud/tags/ResourceTagVO.java similarity index 100% rename from server/src/com/cloud/tags/ResourceTagVO.java rename to engine/schema/src/com/cloud/tags/ResourceTagVO.java diff --git a/server/src/com/cloud/tags/dao/ResourceTagDao.java b/engine/schema/src/com/cloud/tags/dao/ResourceTagDao.java similarity index 100% rename from server/src/com/cloud/tags/dao/ResourceTagDao.java rename to engine/schema/src/com/cloud/tags/dao/ResourceTagDao.java diff --git a/server/src/com/cloud/tags/dao/ResourceTagsDaoImpl.java b/engine/schema/src/com/cloud/tags/dao/ResourceTagsDaoImpl.java similarity index 100% rename from server/src/com/cloud/tags/dao/ResourceTagsDaoImpl.java rename to engine/schema/src/com/cloud/tags/dao/ResourceTagsDaoImpl.java diff --git a/server/src/com/cloud/upgrade/DatabaseCreator.java b/engine/schema/src/com/cloud/upgrade/DatabaseCreator.java similarity index 100% rename from server/src/com/cloud/upgrade/DatabaseCreator.java rename to engine/schema/src/com/cloud/upgrade/DatabaseCreator.java diff --git a/server/src/com/cloud/upgrade/DatabaseIntegrityChecker.java b/engine/schema/src/com/cloud/upgrade/DatabaseIntegrityChecker.java similarity index 100% rename from server/src/com/cloud/upgrade/DatabaseIntegrityChecker.java rename to engine/schema/src/com/cloud/upgrade/DatabaseIntegrityChecker.java diff --git a/server/src/com/cloud/upgrade/DatabaseUpgradeChecker.java b/engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java similarity index 98% rename from server/src/com/cloud/upgrade/DatabaseUpgradeChecker.java rename to engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java index 8f9be0f5d57..9bc0ba599c2 100755 --- a/server/src/com/cloud/upgrade/DatabaseUpgradeChecker.java +++ b/engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java @@ -34,7 +34,6 @@ import javax.ejb.Local; import org.apache.log4j.Logger; -import com.cloud.cluster.ClusterManagerImpl; import com.cloud.maint.Version; import com.cloud.upgrade.dao.DbUpgrade; import com.cloud.upgrade.dao.Upgrade217to218; @@ -63,7 +62,6 @@ import com.cloud.upgrade.dao.VersionDao; import com.cloud.upgrade.dao.VersionDaoImpl; import com.cloud.upgrade.dao.VersionVO; import com.cloud.upgrade.dao.VersionVO.Step; - import com.cloud.utils.component.SystemIntegrityChecker; import com.cloud.utils.db.GlobalLock; import com.cloud.utils.db.ScriptRunner; @@ -212,7 +210,8 @@ public class DatabaseUpgradeChecker implements SystemIntegrityChecker { } } - if (!supportsRollingUpgrade && ClusterManagerImpl.arePeersRunning(null)) { + if (!supportsRollingUpgrade && false) { // FIXME: Needs to detect if there are management servers running + // ClusterManagerImpl.arePeersRunning(null)) { s_logger.error("Unable to run upgrade because the upgrade sequence does not support rolling update and there are other management server nodes running"); throw new CloudRuntimeException("Unable to run upgrade because the upgrade sequence does not support rolling update and there are other management server nodes running"); } @@ -267,7 +266,8 @@ public class DatabaseUpgradeChecker implements SystemIntegrityChecker { } } - if (!ClusterManagerImpl.arePeersRunning(trimmedCurrentVersion)) { + if (true) { // FIXME Needs to detect if management servers are running + // !ClusterManagerImpl.arePeersRunning(trimmedCurrentVersion)) { s_logger.info("Cleaning upgrades because all management server are now at the same version"); TreeMap> upgradedVersions = new TreeMap>(); diff --git a/server/src/com/cloud/upgrade/PremiumDatabaseUpgradeChecker.java b/engine/schema/src/com/cloud/upgrade/PremiumDatabaseUpgradeChecker.java similarity index 100% rename from server/src/com/cloud/upgrade/PremiumDatabaseUpgradeChecker.java rename to engine/schema/src/com/cloud/upgrade/PremiumDatabaseUpgradeChecker.java diff --git a/server/src/com/cloud/upgrade/dao/DbUpgrade.java b/engine/schema/src/com/cloud/upgrade/dao/DbUpgrade.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/DbUpgrade.java rename to engine/schema/src/com/cloud/upgrade/dao/DbUpgrade.java diff --git a/server/src/com/cloud/upgrade/dao/DbUpgradeUtils.java b/engine/schema/src/com/cloud/upgrade/dao/DbUpgradeUtils.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/DbUpgradeUtils.java rename to engine/schema/src/com/cloud/upgrade/dao/DbUpgradeUtils.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade217to218.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade217to218.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade217to218.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade217to218.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade218to22.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade218to22.java similarity index 99% rename from server/src/com/cloud/upgrade/dao/Upgrade218to22.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade218to22.java index 01fa2cc9cfa..2ef842ac6d2 100644 --- a/server/src/com/cloud/upgrade/dao/Upgrade218to22.java +++ b/engine/schema/src/com/cloud/upgrade/dao/Upgrade218to22.java @@ -37,12 +37,9 @@ import java.util.UUID; import org.apache.log4j.Logger; import com.cloud.configuration.Resource.ResourceType; -import com.cloud.consoleproxy.ConsoleProxyManager; import com.cloud.event.EventTypes; import com.cloud.event.EventVO; import com.cloud.event.UsageEventVO; -import com.cloud.network.router.VpcVirtualNetworkApplianceManager; -import com.cloud.storage.secondary.SecondaryStorageVmManager; import com.cloud.utils.DateUtil; import com.cloud.utils.NumbersUtil; import com.cloud.utils.exception.CloudRuntimeException; @@ -1146,7 +1143,7 @@ public class Upgrade218to22 implements DbUpgrade { if (!userVmSet.next()) { s_logger.warn("Skipping user_statistics upgrade for account id=" + accountId + " in datacenter id=" + dataCenterId); continue; - } + } deviceId = userVmSet.getLong(1); } else { s_logger.debug("Account id=" + accountId + " doesn't own any user vms and domRs, so skipping user_statistics update"); @@ -1407,9 +1404,9 @@ public class Upgrade218to22 implements DbUpgrade { rs.close(); pstmt.close(); - int proxyRamSize = NumbersUtil.parseInt(getConfigValue(conn, "consoleproxy.ram.size"), ConsoleProxyManager.DEFAULT_PROXY_VM_RAMSIZE); - int domrRamSize = NumbersUtil.parseInt(getConfigValue(conn, "router.ram.size"), VpcVirtualNetworkApplianceManager.DEFAULT_ROUTER_VM_RAMSIZE); - int ssvmRamSize = NumbersUtil.parseInt(getConfigValue(conn, "secstorage.vm.ram.size"), SecondaryStorageVmManager.DEFAULT_SS_VM_RAMSIZE); + int proxyRamSize = NumbersUtil.parseInt(getConfigValue(conn, "consoleproxy.ram.size"), 1024); // ConsoleProxyManager.DEFAULT_PROXY_VM_RAMSIZE); + int domrRamSize = NumbersUtil.parseInt(getConfigValue(conn, "router.ram.size"), 128); // VpcVirtualNetworkApplianceManager.DEFAULT_ROUTER_VM_RAMSIZE); + int ssvmRamSize = NumbersUtil.parseInt(getConfigValue(conn, "secstorage.vm.ram.size"), 256); // SecondaryStorageVmManager.DEFAULT_SS_VM_RAMSIZE); pstmt = conn .prepareStatement("select h.id, count(v.id) from host h, vm_instance v where h.type='Routing' and v.state='Running' and v.`type`='ConsoleProxy' and v.host_id=h.id group by h.id"); @@ -1566,9 +1563,9 @@ public class Upgrade218to22 implements DbUpgrade { rs.close(); pstmt.close(); - int proxyCpuMhz = NumbersUtil.parseInt(getConfigValue(conn, "consoleproxy.cpu.mhz"), ConsoleProxyManager.DEFAULT_PROXY_VM_CPUMHZ); - int domrCpuMhz = NumbersUtil.parseInt(getConfigValue(conn, "router.cpu.mhz"), VpcVirtualNetworkApplianceManager.DEFAULT_ROUTER_CPU_MHZ); - int ssvmCpuMhz = NumbersUtil.parseInt(getConfigValue(conn, "secstorage.vm.cpu.mhz"), SecondaryStorageVmManager.DEFAULT_SS_VM_CPUMHZ); + int proxyCpuMhz = NumbersUtil.parseInt(getConfigValue(conn, "consoleproxy.cpu.mhz"), 500); // ConsoleProxyManager.DEFAULT_PROXY_VM_CPUMHZ); + int domrCpuMhz = NumbersUtil.parseInt(getConfigValue(conn, "router.cpu.mhz"), 500); // VpcVirtualNetworkApplianceManager.DEFAULT_ROUTER_CPU_MHZ); + int ssvmCpuMhz = NumbersUtil.parseInt(getConfigValue(conn, "secstorage.vm.cpu.mhz"), 500); // SecondaryStorageVmManager.DEFAULT_SS_VM_CPUMHZ); pstmt = conn .prepareStatement("select h.id, count(v.id) from host h, vm_instance v where h.type='Routing' and v.state='Running' and v.`type`='ConsoleProxy' and v.host_id=h.id group by h.id"); diff --git a/server/src/com/cloud/upgrade/dao/Upgrade218to224DomainVlans.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade218to224DomainVlans.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade218to224DomainVlans.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade218to224DomainVlans.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade218to22Premium.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade218to22Premium.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade218to22Premium.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade218to22Premium.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade2210to2211.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade2210to2211.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade2210to2211.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade2210to2211.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade2211to2212.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade2211to2212.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade2211to2212.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade2211to2212.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade2211to2212Premium.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade2211to2212Premium.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade2211to2212Premium.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade2211to2212Premium.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade2212to2213.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade2212to2213.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade2212to2213.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade2212to2213.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade2213to2214.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade2213to2214.java similarity index 96% rename from server/src/com/cloud/upgrade/dao/Upgrade2213to2214.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade2213to2214.java index 48b08e41e0a..d3528e3335f 100644 --- a/server/src/com/cloud/upgrade/dao/Upgrade2213to2214.java +++ b/engine/schema/src/com/cloud/upgrade/dao/Upgrade2213to2214.java @@ -26,9 +26,9 @@ import java.util.List; import org.apache.log4j.Logger; -import com.cloud.consoleproxy.ConsoleProxyManagerImpl; import com.cloud.utils.exception.CloudRuntimeException; import com.cloud.utils.script.Script; +import com.cloud.vm.ConsoleProxyVO; public class Upgrade2213to2214 implements DbUpgrade { final static Logger s_logger = Logger.getLogger(Upgrade2213to2214.class); @@ -70,13 +70,13 @@ public class Upgrade2213to2214 implements DbUpgrade { if (privateKeyMd5.equalsIgnoreCase("432ea1370f57ccd774f4f36052c5fd73")) { s_logger.debug("Need to upgrade cloudstack provided certificate"); pstmt = conn.prepareStatement("update `cloud`.`keystore` set `cloud`.`keystore`.key = ?, certificate = ? where name = 'CPVMCertificate'"); - pstmt.setString(1, ConsoleProxyManagerImpl.keyContent); - pstmt.setString(2, ConsoleProxyManagerImpl.certContent); + pstmt.setString(1, ConsoleProxyVO.keyContent); + pstmt.setString(2, ConsoleProxyVO.certContent); pstmt.executeUpdate(); - + pstmt = conn.prepareStatement("insert into `cloud`.`keystore` (name, certificate, seq, domain_suffix) VALUES (?,?,?,?)"); pstmt.setString(1, "root"); - pstmt.setString(2, ConsoleProxyManagerImpl.rootCa); + pstmt.setString(2, ConsoleProxyVO.rootCa); pstmt.setInt(3, 0); pstmt.setString(4, "realhostip.com"); pstmt.executeUpdate(); @@ -87,7 +87,7 @@ public class Upgrade2213to2214 implements DbUpgrade { } catch (SQLException e) { s_logger.debug("Failed to upgrade keystore: " + e.toString()); } - + } @Override @@ -162,10 +162,10 @@ public class Upgrade2213to2214 implements DbUpgrade { pstmt.close(); } catch (SQLException e) { throw new CloudRuntimeException("Unable to execute changes for op_vm_ruleset_log", e); - } + } - //Drop i_async__removed, i_async_job__removed (if exists) and add i_async_job__removed + //Drop i_async__removed, i_async_job__removed (if exists) and add i_async_job__removed keys = new ArrayList(); keys.add("i_async__removed"); keys.add("i_async_job__removed"); @@ -177,21 +177,21 @@ public class Upgrade2213to2214 implements DbUpgrade { } catch (SQLException e) { throw new CloudRuntimeException("Unable to insert index for removed column in async_job", e); } - + keys = new ArrayList(); keys.add("fk_ssh_keypair__account_id"); keys.add("fk_ssh_keypair__domain_id"); keys.add("fk_ssh_keypairs__account_id"); keys.add("fk_ssh_keypairs__domain_id"); DbUpgradeUtils.dropKeysIfExist(conn, "ssh_keypairs", keys, true); - + keys = new ArrayList(); keys.add("fk_ssh_keypair__account_id"); keys.add("fk_ssh_keypair__domain_id"); keys.add("fk_ssh_keypairs__account_id"); keys.add("fk_ssh_keypairs__domain_id"); DbUpgradeUtils.dropKeysIfExist(conn, "ssh_keypairs", keys, false); - + try { PreparedStatement pstmt; pstmt = conn.prepareStatement("ALTER TABLE `cloud`.`ssh_keypairs` ADD CONSTRAINT `fk_ssh_keypairs__account_id` FOREIGN KEY `fk_ssh_keypairs__account_id` (`account_id`) REFERENCES `account` (`id`) ON DELETE CASCADE"); pstmt.executeUpdate(); @@ -199,7 +199,7 @@ public class Upgrade2213to2214 implements DbUpgrade { } catch (SQLException e) { throw new CloudRuntimeException("Unable to execute ssh_keypairs table update for adding account_id foreign key", e); } - + try { PreparedStatement pstmt; pstmt = conn.prepareStatement("ALTER TABLE `cloud`.`ssh_keypairs` ADD CONSTRAINT `fk_ssh_keypairs__domain_id` FOREIGN KEY `fk_ssh_keypairs__domain_id` (`domain_id`) REFERENCES `domain` (`id`) ON DELETE CASCADE"); pstmt.executeUpdate(); @@ -208,7 +208,7 @@ public class Upgrade2213to2214 implements DbUpgrade { throw new CloudRuntimeException("Unable to execute ssh_keypairs table update for adding domain_id foreign key", e); } - //Drop i_async__removed, i_async_job__removed (if exists) and add i_async_job__removed + //Drop i_async__removed, i_async_job__removed (if exists) and add i_async_job__removed keys = new ArrayList(); keys.add("i_async__removed"); keys.add("i_async_job__removed"); @@ -220,7 +220,7 @@ public class Upgrade2213to2214 implements DbUpgrade { } catch (SQLException e) { throw new CloudRuntimeException("Unable to insert index for removed column in async_job", e); } - + //Drop storage pool details keys (if exists) and insert one with correct name keys = new ArrayList(); keys.add("fk_storage_pool__pool_id"); @@ -234,7 +234,7 @@ public class Upgrade2213to2214 implements DbUpgrade { } catch (SQLException e) { throw new CloudRuntimeException("Unable to insert foreign key in storage_pool_details ", e); } - + //Drop securityGroup keys (if exists) and insert one with correct name keys = new ArrayList(); keys.add("fk_security_group___account_id"); @@ -248,21 +248,21 @@ public class Upgrade2213to2214 implements DbUpgrade { } catch (SQLException e) { throw new CloudRuntimeException("Unable to insert foreign key in security_group table ", e); } - + //Drop vmInstance keys (if exists) and insert one with correct name keys = new ArrayList(); keys.add("i_vm_instance__host_id"); keys.add("fk_vm_instance__host_id"); - + keys.add("fk_vm_instance__last_host_id"); keys.add("i_vm_instance__last_host_id"); - + keys.add("fk_vm_instance__service_offering_id"); keys.add("i_vm_instance__service_offering_id"); - + keys.add("fk_vm_instance__account_id"); keys.add("i_vm_instance__account_id"); - + DbUpgradeUtils.dropKeysIfExist(conn, "cloud.vm_instance", keys, true); DbUpgradeUtils.dropKeysIfExist(conn, "cloud.vm_instance", keys, false); try { @@ -278,18 +278,18 @@ public class Upgrade2213to2214 implements DbUpgrade { } catch (SQLException e) { throw new CloudRuntimeException("Unable to insert foreign key in vm_instance table ", e); } - + //Drop user_ip_address keys (if exists) and insert one with correct name keys = new ArrayList(); keys.add("fk_user_ip_address__account_id"); keys.add("i_user_ip_address__account_id"); - + keys.add("fk_user_ip_address__vlan_db_id"); keys.add("i_user_ip_address__vlan_db_id"); - + keys.add("fk_user_ip_address__data_center_id"); keys.add("i_user_ip_address__data_center_id"); - + DbUpgradeUtils.dropKeysIfExist(conn, "cloud.user_ip_address", keys, true); DbUpgradeUtils.dropKeysIfExist(conn, "cloud.user_ip_address", keys, false); try { diff --git a/server/src/com/cloud/upgrade/dao/Upgrade2214to30.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade2214to30.java old mode 100755 new mode 100644 similarity index 97% rename from server/src/com/cloud/upgrade/dao/Upgrade2214to30.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade2214to30.java index c0f827e655e..2d77429367a --- a/server/src/com/cloud/upgrade/dao/Upgrade2214to30.java +++ b/engine/schema/src/com/cloud/upgrade/dao/Upgrade2214to30.java @@ -629,8 +629,8 @@ public class Upgrade2214to30 extends Upgrade30xBase implements DbUpgrade { s_logger.debug("Updating XenSever System Vms"); //XenServer try { - //Get 3.0.0 xenserer system Vm template Id - pstmt = conn.prepareStatement("select id from `cloud`.`vm_template` where name = 'systemvm-xenserver-3.0.0' and removed is null"); + //Get 3.0.0 or later xenserer system Vm template Id + pstmt = conn.prepareStatement("select max(id) from `cloud`.`vm_template` where name like 'systemvm-xenserver-%' and removed is null"); rs = pstmt.executeQuery(); if(rs.next()){ long templateId = rs.getLong(1); @@ -648,9 +648,9 @@ public class Upgrade2214to30 extends Upgrade30xBase implements DbUpgrade { pstmt.close(); } else { if (xenserver){ - throw new CloudRuntimeException("3.0.0 XenServer SystemVm template not found. Cannot upgrade system Vms"); + throw new CloudRuntimeException("3.0.0 or later XenServer SystemVm template not found. Cannot upgrade system Vms"); } else { - s_logger.warn("3.0.0 XenServer SystemVm template not found. XenServer hypervisor is not used, so not failing upgrade"); + s_logger.warn("3.0.0 or later XenServer SystemVm template not found. XenServer hypervisor is not used, so not failing upgrade"); } } } catch (SQLException e) { @@ -660,8 +660,8 @@ public class Upgrade2214to30 extends Upgrade30xBase implements DbUpgrade { //KVM s_logger.debug("Updating KVM System Vms"); try { - //Get 3.0.0 KVM system Vm template Id - pstmt = conn.prepareStatement("select id from `cloud`.`vm_template` where name = 'systemvm-kvm-3.0.0' and removed is null"); + //Get 3.0.0 or later KVM system Vm template Id + pstmt = conn.prepareStatement("select max(id) from `cloud`.`vm_template` where name like 'systemvm-kvm-%' and removed is null"); rs = pstmt.executeQuery(); if(rs.next()){ long templateId = rs.getLong(1); @@ -679,9 +679,9 @@ public class Upgrade2214to30 extends Upgrade30xBase implements DbUpgrade { pstmt.close(); } else { if (kvm){ - throw new CloudRuntimeException("3.0.0 KVM SystemVm template not found. Cannot upgrade system Vms"); + throw new CloudRuntimeException("3.0.0 or later KVM SystemVm template not found. Cannot upgrade system Vms"); } else { - s_logger.warn("3.0.0 KVM SystemVm template not found. KVM hypervisor is not used, so not failing upgrade"); + s_logger.warn("3.0.0 or later KVM SystemVm template not found. KVM hypervisor is not used, so not failing upgrade"); } } } catch (SQLException e) { @@ -691,8 +691,8 @@ public class Upgrade2214to30 extends Upgrade30xBase implements DbUpgrade { //VMware s_logger.debug("Updating VMware System Vms"); try { - //Get 3.0.0 VMware system Vm template Id - pstmt = conn.prepareStatement("select id from `cloud`.`vm_template` where name = 'systemvm-vmware-3.0.0' and removed is null"); + //Get 3.0.0 or later VMware system Vm template Id + pstmt = conn.prepareStatement("select max(id) from `cloud`.`vm_template` where name like 'systemvm-vmware-%' and removed is null"); rs = pstmt.executeQuery(); if(rs.next()){ long templateId = rs.getLong(1); @@ -710,9 +710,9 @@ public class Upgrade2214to30 extends Upgrade30xBase implements DbUpgrade { pstmt.close(); } else { if (VMware){ - throw new CloudRuntimeException("3.0.0 VMware SystemVm template not found. Cannot upgrade system Vms"); + throw new CloudRuntimeException("3.0.0 or later VMware SystemVm template not found. Cannot upgrade system Vms"); } else { - s_logger.warn("3.0.0 VMware SystemVm template not found. VMware hypervisor is not used, so not failing upgrade"); + s_logger.warn("3.0.0 or later VMware SystemVm template not found. VMware hypervisor is not used, so not failing upgrade"); } } } catch (SQLException e) { diff --git a/server/src/com/cloud/upgrade/dao/Upgrade221to222.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade221to222.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade221to222.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade221to222.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade221to222Premium.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade221to222Premium.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade221to222Premium.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade221to222Premium.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade222to224.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade222to224.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade222to224.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade222to224.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade222to224Premium.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade222to224Premium.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade222to224Premium.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade222to224Premium.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade224to225.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade224to225.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade224to225.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade224to225.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade225to226.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade225to226.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade225to226.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade225to226.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade227to228.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade227to228.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade227to228.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade227to228.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade227to228Premium.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade227to228Premium.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade227to228Premium.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade227to228Premium.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade228to229.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade228to229.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade228to229.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade228to229.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade229to2210.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade229to2210.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade229to2210.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade229to2210.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade301to302.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade301to302.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade301to302.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade301to302.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade302to40.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade302to40.java similarity index 95% rename from server/src/com/cloud/upgrade/dao/Upgrade302to40.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade302to40.java index 753f64ec682..ecda872dfa4 100644 --- a/server/src/com/cloud/upgrade/dao/Upgrade302to40.java +++ b/engine/schema/src/com/cloud/upgrade/dao/Upgrade302to40.java @@ -63,6 +63,7 @@ public class Upgrade302to40 extends Upgrade30xBase implements DbUpgrade { @Override public void performDataMigration(Connection conn) { + updateVmWareSystemVms(conn); correctVRProviders(conn); correctMultiplePhysicaNetworkSetups(conn); addHostDetailsUniqueKey(conn); @@ -82,7 +83,55 @@ public class Upgrade302to40 extends Upgrade30xBase implements DbUpgrade { return new File[] { new File(script) }; } - + + private void updateVmWareSystemVms(Connection conn){ + PreparedStatement pstmt = null; + ResultSet rs = null; + boolean VMware = false; + try { + pstmt = conn.prepareStatement("select distinct(hypervisor_type) from `cloud`.`cluster` where removed is null"); + rs = pstmt.executeQuery(); + while(rs.next()){ + if("VMware".equals(rs.getString(1))){ + VMware = true; + } + } + } catch (SQLException e) { + throw new CloudRuntimeException("Error while iterating through list of hypervisors in use", e); + } + // Just update the VMware system template. Other hypervisor templates are unchanged from previous 3.0.x versions. + s_logger.debug("Updating VMware System Vms"); + try { + //Get 4.0 VMware system Vm template Id + pstmt = conn.prepareStatement("select id from `cloud`.`vm_template` where name = 'systemvm-vmware-4.0' and removed is null"); + rs = pstmt.executeQuery(); + if(rs.next()){ + long templateId = rs.getLong(1); + rs.close(); + pstmt.close(); + // change template type to SYSTEM + pstmt = conn.prepareStatement("update `cloud`.`vm_template` set type='SYSTEM' where id = ?"); + pstmt.setLong(1, templateId); + pstmt.executeUpdate(); + pstmt.close(); + // update templete ID of system Vms + pstmt = conn.prepareStatement("update `cloud`.`vm_instance` set vm_template_id = ? where type <> 'User' and hypervisor_type = 'VMware'"); + pstmt.setLong(1, templateId); + pstmt.executeUpdate(); + pstmt.close(); + } else { + if (VMware){ + throw new CloudRuntimeException("4.0 VMware SystemVm template not found. Cannot upgrade system Vms"); + } else { + s_logger.warn("4.0 VMware SystemVm template not found. VMware hypervisor is not used, so not failing upgrade"); + } + } + } catch (SQLException e) { + throw new CloudRuntimeException("Error while updating VMware systemVm template", e); + } + s_logger.debug("Updating System Vm Template IDs Complete"); + } + private void correctVRProviders(Connection conn) { PreparedStatement pstmtVR = null; ResultSet rsVR = null; diff --git a/server/src/com/cloud/upgrade/dao/Upgrade30to301.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade30to301.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade30to301.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade30to301.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade30xBase.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade30xBase.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade30xBase.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade30xBase.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade40to41.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade40to41.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/Upgrade40to41.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade40to41.java diff --git a/server/src/com/cloud/upgrade/dao/Upgrade410to420.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade410to420.java similarity index 81% rename from server/src/com/cloud/upgrade/dao/Upgrade410to420.java rename to engine/schema/src/com/cloud/upgrade/dao/Upgrade410to420.java index 05e2b49ffe4..3a164c413bb 100644 --- a/server/src/com/cloud/upgrade/dao/Upgrade410to420.java +++ b/engine/schema/src/com/cloud/upgrade/dao/Upgrade410to420.java @@ -17,10 +17,6 @@ package com.cloud.upgrade.dao; -import com.cloud.utils.exception.CloudRuntimeException; -import com.cloud.utils.script.Script; -import org.apache.log4j.Logger; - import java.io.File; import java.sql.Connection; import java.sql.PreparedStatement; @@ -28,6 +24,11 @@ import java.sql.ResultSet; import java.sql.SQLException; import java.util.UUID; +import org.apache.log4j.Logger; + +import com.cloud.utils.exception.CloudRuntimeException; +import com.cloud.utils.script.Script; + public class Upgrade410to420 implements DbUpgrade { final static Logger s_logger = Logger.getLogger(Upgrade410to420.class); @@ -66,6 +67,8 @@ public class Upgrade410to420 implements DbUpgrade { updatePrimaryStore(conn); addEgressFwRulesForSRXGuestNw(conn); upgradeEIPNetworkOfferings(conn); + upgradeDefaultVpcOffering(conn); + upgradePhysicalNtwksWithInternalLbProvider(conn); } private void updateSystemVmTemplates(Connection conn) { @@ -399,4 +402,88 @@ public class Upgrade410to420 implements DbUpgrade { } } } + + + private void upgradeDefaultVpcOffering(Connection conn) { + + PreparedStatement pstmt = null; + ResultSet rs = null; + + try { + pstmt = conn.prepareStatement("select distinct map.vpc_offering_id from `cloud`.`vpc_offering_service_map` map, `cloud`.`vpc_offerings` off where off.id=map.vpc_offering_id AND service='Lb'"); + rs = pstmt.executeQuery(); + while (rs.next()) { + long id = rs.getLong(1); + //Add internal LB vm as a supported provider for the load balancer service + pstmt = conn.prepareStatement("INSERT INTO `cloud`.`vpc_offering_service_map` (vpc_offering_id, service, provider) VALUES (?,?,?)"); + pstmt.setLong(1, id); + pstmt.setString(2, "Lb"); + pstmt.setString(3, "InternalLbVm"); + pstmt.executeUpdate(); + } + + } catch (SQLException e) { + throw new CloudRuntimeException("Unable update the default VPC offering with the internal lb service", e); + } finally { + try { + if (rs != null) { + rs.close(); + } + if (pstmt != null) { + pstmt.close(); + } + } catch (SQLException e) { + } + } + } + + + private void upgradePhysicalNtwksWithInternalLbProvider(Connection conn) { + + PreparedStatement pstmt = null; + ResultSet rs = null; + + try { + pstmt = conn.prepareStatement("SELECT id FROM `cloud`.`physical_network` where removed is null"); + rs = pstmt.executeQuery(); + while (rs.next()) { + long pNtwkId = rs.getLong(1); + String uuid = UUID.randomUUID().toString(); + //Add internal LB VM to the list of physical network service providers + pstmt = conn.prepareStatement("INSERT INTO `cloud`.`physical_network_service_providers` " + + "(uuid, physical_network_id, provider_name, state, load_balance_service_provided, destination_physical_network_id)" + + " VALUES (?, ?, 'InternalLbVm', 'Enabled', 1, 0)"); + pstmt.setString(1, uuid); + pstmt.setLong(2, pNtwkId); + pstmt.executeUpdate(); + + //Add internal lb vm to the list of physical network elements + PreparedStatement pstmt1 = conn.prepareStatement("SELECT id FROM `cloud`.`physical_network_service_providers`" + + " WHERE physical_network_id=? AND provider_name='InternalLbVm'"); + ResultSet rs1 = pstmt1.executeQuery(); + while (rs1.next()) { + long providerId = rs1.getLong(1); + uuid = UUID.randomUUID().toString(); + pstmt1 = conn.prepareStatement("INSERT INTO `cloud`.`virtual_router_providers` (nsp_id, uuid, type, enabled) VALUES (?, ?, 'InternalLbVm', 1)"); + pstmt1.setLong(1, providerId); + pstmt1.setString(2, uuid); + pstmt1.executeUpdate(); + } + } + + } catch (SQLException e) { + throw new CloudRuntimeException("Unable existing physical networks with internal lb provider", e); + } finally { + try { + if (rs != null) { + rs.close(); + } + if (pstmt != null) { + pstmt.close(); + } + } catch (SQLException e) { + } + } + + } } diff --git a/server/src/com/cloud/upgrade/dao/UpgradeSnapshot217to224.java b/engine/schema/src/com/cloud/upgrade/dao/UpgradeSnapshot217to224.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/UpgradeSnapshot217to224.java rename to engine/schema/src/com/cloud/upgrade/dao/UpgradeSnapshot217to224.java diff --git a/server/src/com/cloud/upgrade/dao/UpgradeSnapshot223to224.java b/engine/schema/src/com/cloud/upgrade/dao/UpgradeSnapshot223to224.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/UpgradeSnapshot223to224.java rename to engine/schema/src/com/cloud/upgrade/dao/UpgradeSnapshot223to224.java diff --git a/server/src/com/cloud/upgrade/dao/VersionDao.java b/engine/schema/src/com/cloud/upgrade/dao/VersionDao.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/VersionDao.java rename to engine/schema/src/com/cloud/upgrade/dao/VersionDao.java diff --git a/server/src/com/cloud/upgrade/dao/VersionDaoImpl.java b/engine/schema/src/com/cloud/upgrade/dao/VersionDaoImpl.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/VersionDaoImpl.java rename to engine/schema/src/com/cloud/upgrade/dao/VersionDaoImpl.java diff --git a/server/src/com/cloud/upgrade/dao/VersionVO.java b/engine/schema/src/com/cloud/upgrade/dao/VersionVO.java similarity index 100% rename from server/src/com/cloud/upgrade/dao/VersionVO.java rename to engine/schema/src/com/cloud/upgrade/dao/VersionVO.java diff --git a/server/src/com/cloud/usage/ExternalPublicIpStatisticsVO.java b/engine/schema/src/com/cloud/usage/ExternalPublicIpStatisticsVO.java similarity index 100% rename from server/src/com/cloud/usage/ExternalPublicIpStatisticsVO.java rename to engine/schema/src/com/cloud/usage/ExternalPublicIpStatisticsVO.java diff --git a/server/src/com/cloud/usage/UsageIPAddressVO.java b/engine/schema/src/com/cloud/usage/UsageIPAddressVO.java similarity index 100% rename from server/src/com/cloud/usage/UsageIPAddressVO.java rename to engine/schema/src/com/cloud/usage/UsageIPAddressVO.java diff --git a/server/src/com/cloud/usage/UsageJobVO.java b/engine/schema/src/com/cloud/usage/UsageJobVO.java similarity index 100% rename from server/src/com/cloud/usage/UsageJobVO.java rename to engine/schema/src/com/cloud/usage/UsageJobVO.java diff --git a/server/src/com/cloud/usage/UsageLoadBalancerPolicyVO.java b/engine/schema/src/com/cloud/usage/UsageLoadBalancerPolicyVO.java similarity index 100% rename from server/src/com/cloud/usage/UsageLoadBalancerPolicyVO.java rename to engine/schema/src/com/cloud/usage/UsageLoadBalancerPolicyVO.java diff --git a/server/src/com/cloud/usage/UsageNetworkOfferingVO.java b/engine/schema/src/com/cloud/usage/UsageNetworkOfferingVO.java similarity index 100% rename from server/src/com/cloud/usage/UsageNetworkOfferingVO.java rename to engine/schema/src/com/cloud/usage/UsageNetworkOfferingVO.java diff --git a/server/src/com/cloud/usage/UsageNetworkVO.java b/engine/schema/src/com/cloud/usage/UsageNetworkVO.java similarity index 100% rename from server/src/com/cloud/usage/UsageNetworkVO.java rename to engine/schema/src/com/cloud/usage/UsageNetworkVO.java diff --git a/server/src/com/cloud/usage/UsagePortForwardingRuleVO.java b/engine/schema/src/com/cloud/usage/UsagePortForwardingRuleVO.java similarity index 100% rename from server/src/com/cloud/usage/UsagePortForwardingRuleVO.java rename to engine/schema/src/com/cloud/usage/UsagePortForwardingRuleVO.java diff --git a/server/src/com/cloud/usage/UsageSecurityGroupVO.java b/engine/schema/src/com/cloud/usage/UsageSecurityGroupVO.java similarity index 100% rename from server/src/com/cloud/usage/UsageSecurityGroupVO.java rename to engine/schema/src/com/cloud/usage/UsageSecurityGroupVO.java diff --git a/server/src/com/cloud/usage/UsageStorageVO.java b/engine/schema/src/com/cloud/usage/UsageStorageVO.java similarity index 100% rename from server/src/com/cloud/usage/UsageStorageVO.java rename to engine/schema/src/com/cloud/usage/UsageStorageVO.java diff --git a/server/src/com/cloud/usage/UsageVMInstanceVO.java b/engine/schema/src/com/cloud/usage/UsageVMInstanceVO.java similarity index 100% rename from server/src/com/cloud/usage/UsageVMInstanceVO.java rename to engine/schema/src/com/cloud/usage/UsageVMInstanceVO.java diff --git a/server/src/com/cloud/usage/UsageVO.java b/engine/schema/src/com/cloud/usage/UsageVO.java similarity index 100% rename from server/src/com/cloud/usage/UsageVO.java rename to engine/schema/src/com/cloud/usage/UsageVO.java diff --git a/server/src/com/cloud/usage/UsageVPNUserVO.java b/engine/schema/src/com/cloud/usage/UsageVPNUserVO.java similarity index 100% rename from server/src/com/cloud/usage/UsageVPNUserVO.java rename to engine/schema/src/com/cloud/usage/UsageVPNUserVO.java diff --git a/server/src/com/cloud/usage/UsageVolumeVO.java b/engine/schema/src/com/cloud/usage/UsageVolumeVO.java similarity index 100% rename from server/src/com/cloud/usage/UsageVolumeVO.java rename to engine/schema/src/com/cloud/usage/UsageVolumeVO.java diff --git a/server/src/com/cloud/usage/dao/ExternalPublicIpStatisticsDao.java b/engine/schema/src/com/cloud/usage/dao/ExternalPublicIpStatisticsDao.java similarity index 100% rename from server/src/com/cloud/usage/dao/ExternalPublicIpStatisticsDao.java rename to engine/schema/src/com/cloud/usage/dao/ExternalPublicIpStatisticsDao.java diff --git a/server/src/com/cloud/usage/dao/ExternalPublicIpStatisticsDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/ExternalPublicIpStatisticsDaoImpl.java similarity index 100% rename from server/src/com/cloud/usage/dao/ExternalPublicIpStatisticsDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/ExternalPublicIpStatisticsDaoImpl.java diff --git a/server/src/com/cloud/usage/dao/UsageDao.java b/engine/schema/src/com/cloud/usage/dao/UsageDao.java similarity index 70% rename from server/src/com/cloud/usage/dao/UsageDao.java rename to engine/schema/src/com/cloud/usage/dao/UsageDao.java index a25b0dc78ef..6d0c162b52b 100644 --- a/server/src/com/cloud/usage/dao/UsageDao.java +++ b/engine/schema/src/com/cloud/usage/dao/UsageDao.java @@ -16,11 +16,8 @@ // under the License. package com.cloud.usage.dao; -import java.util.Date; import java.util.List; -import com.cloud.event.UsageEventVO; -import com.cloud.exception.UsageServerException; import com.cloud.usage.UsageVO; import com.cloud.user.AccountVO; import com.cloud.user.UserStatisticsVO; @@ -31,11 +28,12 @@ import com.cloud.utils.db.SearchCriteria; public interface UsageDao extends GenericDao { void deleteRecordsForAccount(Long accountId); List searchAllRecords(SearchCriteria sc, Filter filter); - void saveAccounts(List accounts) throws UsageServerException; - void updateAccounts(List accounts) throws UsageServerException; - void saveUserStats(List userStats) throws UsageServerException; - void updateUserStats(List userStats) throws UsageServerException; - Long getLastAccountId() throws UsageServerException; - Long getLastUserStatsId() throws UsageServerException; + + void saveAccounts(List accounts); + void updateAccounts(List accounts); + void saveUserStats(List userStats); + void updateUserStats(List userStats); + Long getLastAccountId(); + Long getLastUserStatsId(); List listPublicTemplatesByAccount(long accountId); } diff --git a/server/src/com/cloud/usage/dao/UsageDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsageDaoImpl.java similarity index 94% rename from server/src/com/cloud/usage/dao/UsageDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsageDaoImpl.java index f9ae70c1f20..a5867f0656e 100644 --- a/server/src/com/cloud/usage/dao/UsageDaoImpl.java +++ b/engine/schema/src/com/cloud/usage/dao/UsageDaoImpl.java @@ -29,7 +29,6 @@ import javax.ejb.Local; import org.apache.log4j.Logger; import org.springframework.stereotype.Component; -import com.cloud.exception.UsageServerException; import com.cloud.usage.UsageVO; import com.cloud.user.AccountVO; import com.cloud.user.UserStatisticsVO; @@ -38,6 +37,7 @@ import com.cloud.utils.db.Filter; import com.cloud.utils.db.GenericDaoBase; import com.cloud.utils.db.SearchCriteria; import com.cloud.utils.db.Transaction; +import com.cloud.utils.exception.CloudRuntimeException; @Component @Local(value={UsageDao.class}) @@ -60,7 +60,8 @@ public class UsageDaoImpl extends GenericDaoBase implements Usage public UsageDaoImpl () {} - public void deleteRecordsForAccount(Long accountId) { + @Override + public void deleteRecordsForAccount(Long accountId) { String sql = ((accountId == null) ? DELETE_ALL : DELETE_ALL_BY_ACCOUNTID); Transaction txn = Transaction.open(Transaction.USAGE_DB); PreparedStatement pstmt = null; @@ -86,7 +87,7 @@ public class UsageDaoImpl extends GenericDaoBase implements Usage } @Override - public void saveAccounts(List accounts) throws UsageServerException { + public void saveAccounts(List accounts) { Transaction txn = Transaction.currentTxn(); try { txn.start(); @@ -115,12 +116,12 @@ public class UsageDaoImpl extends GenericDaoBase implements Usage } catch (Exception ex) { txn.rollback(); s_logger.error("error saving account to cloud_usage db", ex); - throw new UsageServerException(ex.getMessage()); + throw new CloudRuntimeException(ex.getMessage()); } } @Override - public void updateAccounts(List accounts) throws UsageServerException { + public void updateAccounts(List accounts) { Transaction txn = Transaction.currentTxn(); try { txn.start(); @@ -145,12 +146,12 @@ public class UsageDaoImpl extends GenericDaoBase implements Usage } catch (Exception ex) { txn.rollback(); s_logger.error("error saving account to cloud_usage db", ex); - throw new UsageServerException(ex.getMessage()); + throw new CloudRuntimeException(ex.getMessage()); } } @Override - public void saveUserStats(List userStats) throws UsageServerException { + public void saveUserStats(List userStats) { Transaction txn = Transaction.currentTxn(); try { txn.start(); @@ -186,12 +187,12 @@ public class UsageDaoImpl extends GenericDaoBase implements Usage } catch (Exception ex) { txn.rollback(); s_logger.error("error saving user stats to cloud_usage db", ex); - throw new UsageServerException(ex.getMessage()); + throw new CloudRuntimeException(ex.getMessage()); } } @Override - public void updateUserStats(List userStats) throws UsageServerException { + public void updateUserStats(List userStats) { Transaction txn = Transaction.currentTxn(); try { txn.start(); @@ -213,7 +214,7 @@ public class UsageDaoImpl extends GenericDaoBase implements Usage } catch (Exception ex) { txn.rollback(); s_logger.error("error saving user stats to cloud_usage db", ex); - throw new UsageServerException(ex.getMessage()); + throw new CloudRuntimeException(ex.getMessage()); } } @@ -250,7 +251,7 @@ public class UsageDaoImpl extends GenericDaoBase implements Usage } return null; } - + @Override public List listPublicTemplatesByAccount(long accountId) { Transaction txn = Transaction.currentTxn(); diff --git a/server/src/com/cloud/usage/dao/UsageIPAddressDao.java b/engine/schema/src/com/cloud/usage/dao/UsageIPAddressDao.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageIPAddressDao.java rename to engine/schema/src/com/cloud/usage/dao/UsageIPAddressDao.java diff --git a/server/src/com/cloud/usage/dao/UsageIPAddressDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsageIPAddressDaoImpl.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageIPAddressDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsageIPAddressDaoImpl.java diff --git a/server/src/com/cloud/usage/dao/UsageJobDao.java b/engine/schema/src/com/cloud/usage/dao/UsageJobDao.java similarity index 92% rename from server/src/com/cloud/usage/dao/UsageJobDao.java rename to engine/schema/src/com/cloud/usage/dao/UsageJobDao.java index 6921046610b..9ec391804f2 100644 --- a/server/src/com/cloud/usage/dao/UsageJobDao.java +++ b/engine/schema/src/com/cloud/usage/dao/UsageJobDao.java @@ -18,7 +18,6 @@ package com.cloud.usage.dao; import java.util.Date; -import com.cloud.exception.UsageServerException; import com.cloud.usage.UsageJobVO; import com.cloud.utils.db.GenericDao; @@ -30,5 +29,6 @@ public interface UsageJobDao extends GenericDao { long getLastJobSuccessDateMillis(); Date getLastHeartbeat(); UsageJobVO isOwner(String hostname, int pid); - void updateJobSuccess(Long jobId, long startMillis, long endMillis, long execTime, boolean success) throws UsageServerException; + + void updateJobSuccess(Long jobId, long startMillis, long endMillis, long execTime, boolean success); } diff --git a/server/src/com/cloud/usage/dao/UsageJobDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsageJobDaoImpl.java similarity index 97% rename from server/src/com/cloud/usage/dao/UsageJobDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsageJobDaoImpl.java index 3c7a3dc110d..783300faeed 100644 --- a/server/src/com/cloud/usage/dao/UsageJobDaoImpl.java +++ b/engine/schema/src/com/cloud/usage/dao/UsageJobDaoImpl.java @@ -26,12 +26,12 @@ import javax.ejb.Local; import org.apache.log4j.Logger; import org.springframework.stereotype.Component; -import com.cloud.exception.UsageServerException; import com.cloud.usage.UsageJobVO; import com.cloud.utils.db.Filter; import com.cloud.utils.db.GenericDaoBase; import com.cloud.utils.db.SearchCriteria; import com.cloud.utils.db.Transaction; +import com.cloud.utils.exception.CloudRuntimeException; @Component @Local(value={UsageJobDao.class}) @@ -60,7 +60,7 @@ public class UsageJobDaoImpl extends GenericDaoBase implements } @Override - public void updateJobSuccess(Long jobId, long startMillis, long endMillis, long execTime, boolean success) throws UsageServerException { + public void updateJobSuccess(Long jobId, long startMillis, long endMillis, long execTime, boolean success) { Transaction txn = Transaction.open(Transaction.USAGE_DB); try { txn.start(); @@ -79,7 +79,7 @@ public class UsageJobDaoImpl extends GenericDaoBase implements } catch (Exception ex) { txn.rollback(); s_logger.error("error updating job success date", ex); - throw new UsageServerException(ex.getMessage()); + throw new CloudRuntimeException(ex.getMessage()); } finally { txn.close(); } diff --git a/server/src/com/cloud/usage/dao/UsageLoadBalancerPolicyDao.java b/engine/schema/src/com/cloud/usage/dao/UsageLoadBalancerPolicyDao.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageLoadBalancerPolicyDao.java rename to engine/schema/src/com/cloud/usage/dao/UsageLoadBalancerPolicyDao.java diff --git a/server/src/com/cloud/usage/dao/UsageLoadBalancerPolicyDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsageLoadBalancerPolicyDaoImpl.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageLoadBalancerPolicyDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsageLoadBalancerPolicyDaoImpl.java diff --git a/server/src/com/cloud/usage/dao/UsageNetworkDao.java b/engine/schema/src/com/cloud/usage/dao/UsageNetworkDao.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageNetworkDao.java rename to engine/schema/src/com/cloud/usage/dao/UsageNetworkDao.java diff --git a/server/src/com/cloud/usage/dao/UsageNetworkDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsageNetworkDaoImpl.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageNetworkDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsageNetworkDaoImpl.java diff --git a/server/src/com/cloud/usage/dao/UsageNetworkOfferingDao.java b/engine/schema/src/com/cloud/usage/dao/UsageNetworkOfferingDao.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageNetworkOfferingDao.java rename to engine/schema/src/com/cloud/usage/dao/UsageNetworkOfferingDao.java diff --git a/server/src/com/cloud/usage/dao/UsageNetworkOfferingDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsageNetworkOfferingDaoImpl.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageNetworkOfferingDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsageNetworkOfferingDaoImpl.java diff --git a/server/src/com/cloud/usage/dao/UsagePortForwardingRuleDao.java b/engine/schema/src/com/cloud/usage/dao/UsagePortForwardingRuleDao.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsagePortForwardingRuleDao.java rename to engine/schema/src/com/cloud/usage/dao/UsagePortForwardingRuleDao.java diff --git a/server/src/com/cloud/usage/dao/UsagePortForwardingRuleDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsagePortForwardingRuleDaoImpl.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsagePortForwardingRuleDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsagePortForwardingRuleDaoImpl.java diff --git a/server/src/com/cloud/usage/dao/UsageSecurityGroupDao.java b/engine/schema/src/com/cloud/usage/dao/UsageSecurityGroupDao.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageSecurityGroupDao.java rename to engine/schema/src/com/cloud/usage/dao/UsageSecurityGroupDao.java diff --git a/server/src/com/cloud/usage/dao/UsageSecurityGroupDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsageSecurityGroupDaoImpl.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageSecurityGroupDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsageSecurityGroupDaoImpl.java diff --git a/server/src/com/cloud/usage/dao/UsageStorageDao.java b/engine/schema/src/com/cloud/usage/dao/UsageStorageDao.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageStorageDao.java rename to engine/schema/src/com/cloud/usage/dao/UsageStorageDao.java diff --git a/server/src/com/cloud/usage/dao/UsageStorageDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsageStorageDaoImpl.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageStorageDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsageStorageDaoImpl.java diff --git a/server/src/com/cloud/usage/dao/UsageVMInstanceDao.java b/engine/schema/src/com/cloud/usage/dao/UsageVMInstanceDao.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageVMInstanceDao.java rename to engine/schema/src/com/cloud/usage/dao/UsageVMInstanceDao.java diff --git a/server/src/com/cloud/usage/dao/UsageVMInstanceDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsageVMInstanceDaoImpl.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageVMInstanceDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsageVMInstanceDaoImpl.java diff --git a/server/src/com/cloud/usage/dao/UsageVPNUserDao.java b/engine/schema/src/com/cloud/usage/dao/UsageVPNUserDao.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageVPNUserDao.java rename to engine/schema/src/com/cloud/usage/dao/UsageVPNUserDao.java diff --git a/server/src/com/cloud/usage/dao/UsageVPNUserDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsageVPNUserDaoImpl.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageVPNUserDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsageVPNUserDaoImpl.java diff --git a/server/src/com/cloud/usage/dao/UsageVolumeDao.java b/engine/schema/src/com/cloud/usage/dao/UsageVolumeDao.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageVolumeDao.java rename to engine/schema/src/com/cloud/usage/dao/UsageVolumeDao.java diff --git a/server/src/com/cloud/usage/dao/UsageVolumeDaoImpl.java b/engine/schema/src/com/cloud/usage/dao/UsageVolumeDaoImpl.java similarity index 100% rename from server/src/com/cloud/usage/dao/UsageVolumeDaoImpl.java rename to engine/schema/src/com/cloud/usage/dao/UsageVolumeDaoImpl.java diff --git a/server/src/com/cloud/user/AccountDetailVO.java b/engine/schema/src/com/cloud/user/AccountDetailVO.java similarity index 100% rename from server/src/com/cloud/user/AccountDetailVO.java rename to engine/schema/src/com/cloud/user/AccountDetailVO.java diff --git a/server/src/com/cloud/user/AccountDetailsDao.java b/engine/schema/src/com/cloud/user/AccountDetailsDao.java similarity index 100% rename from server/src/com/cloud/user/AccountDetailsDao.java rename to engine/schema/src/com/cloud/user/AccountDetailsDao.java diff --git a/server/src/com/cloud/user/AccountDetailsDaoImpl.java b/engine/schema/src/com/cloud/user/AccountDetailsDaoImpl.java similarity index 100% rename from server/src/com/cloud/user/AccountDetailsDaoImpl.java rename to engine/schema/src/com/cloud/user/AccountDetailsDaoImpl.java diff --git a/core/src/com/cloud/user/AccountVO.java b/engine/schema/src/com/cloud/user/AccountVO.java similarity index 100% rename from core/src/com/cloud/user/AccountVO.java rename to engine/schema/src/com/cloud/user/AccountVO.java diff --git a/core/src/com/cloud/user/SSHKeyPairVO.java b/engine/schema/src/com/cloud/user/SSHKeyPairVO.java similarity index 100% rename from core/src/com/cloud/user/SSHKeyPairVO.java rename to engine/schema/src/com/cloud/user/SSHKeyPairVO.java diff --git a/core/src/com/cloud/user/UserAccountVO.java b/engine/schema/src/com/cloud/user/UserAccountVO.java similarity index 100% rename from core/src/com/cloud/user/UserAccountVO.java rename to engine/schema/src/com/cloud/user/UserAccountVO.java diff --git a/core/src/com/cloud/user/UserStatisticsVO.java b/engine/schema/src/com/cloud/user/UserStatisticsVO.java similarity index 100% rename from core/src/com/cloud/user/UserStatisticsVO.java rename to engine/schema/src/com/cloud/user/UserStatisticsVO.java diff --git a/core/src/com/cloud/user/UserStatsLogVO.java b/engine/schema/src/com/cloud/user/UserStatsLogVO.java similarity index 100% rename from core/src/com/cloud/user/UserStatsLogVO.java rename to engine/schema/src/com/cloud/user/UserStatsLogVO.java diff --git a/core/src/com/cloud/user/UserVO.java b/engine/schema/src/com/cloud/user/UserVO.java similarity index 100% rename from core/src/com/cloud/user/UserVO.java rename to engine/schema/src/com/cloud/user/UserVO.java diff --git a/server/src/com/cloud/user/dao/AccountDao.java b/engine/schema/src/com/cloud/user/dao/AccountDao.java similarity index 100% rename from server/src/com/cloud/user/dao/AccountDao.java rename to engine/schema/src/com/cloud/user/dao/AccountDao.java diff --git a/server/src/com/cloud/user/dao/AccountDaoImpl.java b/engine/schema/src/com/cloud/user/dao/AccountDaoImpl.java similarity index 100% rename from server/src/com/cloud/user/dao/AccountDaoImpl.java rename to engine/schema/src/com/cloud/user/dao/AccountDaoImpl.java diff --git a/server/src/com/cloud/user/dao/SSHKeyPairDao.java b/engine/schema/src/com/cloud/user/dao/SSHKeyPairDao.java similarity index 100% rename from server/src/com/cloud/user/dao/SSHKeyPairDao.java rename to engine/schema/src/com/cloud/user/dao/SSHKeyPairDao.java diff --git a/server/src/com/cloud/user/dao/SSHKeyPairDaoImpl.java b/engine/schema/src/com/cloud/user/dao/SSHKeyPairDaoImpl.java similarity index 100% rename from server/src/com/cloud/user/dao/SSHKeyPairDaoImpl.java rename to engine/schema/src/com/cloud/user/dao/SSHKeyPairDaoImpl.java diff --git a/server/src/com/cloud/user/dao/UserAccountDao.java b/engine/schema/src/com/cloud/user/dao/UserAccountDao.java similarity index 100% rename from server/src/com/cloud/user/dao/UserAccountDao.java rename to engine/schema/src/com/cloud/user/dao/UserAccountDao.java diff --git a/server/src/com/cloud/user/dao/UserAccountDaoImpl.java b/engine/schema/src/com/cloud/user/dao/UserAccountDaoImpl.java similarity index 100% rename from server/src/com/cloud/user/dao/UserAccountDaoImpl.java rename to engine/schema/src/com/cloud/user/dao/UserAccountDaoImpl.java diff --git a/server/src/com/cloud/user/dao/UserDao.java b/engine/schema/src/com/cloud/user/dao/UserDao.java similarity index 100% rename from server/src/com/cloud/user/dao/UserDao.java rename to engine/schema/src/com/cloud/user/dao/UserDao.java diff --git a/server/src/com/cloud/user/dao/UserDaoImpl.java b/engine/schema/src/com/cloud/user/dao/UserDaoImpl.java similarity index 100% rename from server/src/com/cloud/user/dao/UserDaoImpl.java rename to engine/schema/src/com/cloud/user/dao/UserDaoImpl.java diff --git a/server/src/com/cloud/user/dao/UserStatisticsDao.java b/engine/schema/src/com/cloud/user/dao/UserStatisticsDao.java similarity index 100% rename from server/src/com/cloud/user/dao/UserStatisticsDao.java rename to engine/schema/src/com/cloud/user/dao/UserStatisticsDao.java diff --git a/server/src/com/cloud/user/dao/UserStatisticsDaoImpl.java b/engine/schema/src/com/cloud/user/dao/UserStatisticsDaoImpl.java similarity index 100% rename from server/src/com/cloud/user/dao/UserStatisticsDaoImpl.java rename to engine/schema/src/com/cloud/user/dao/UserStatisticsDaoImpl.java diff --git a/server/src/com/cloud/user/dao/UserStatsLogDao.java b/engine/schema/src/com/cloud/user/dao/UserStatsLogDao.java similarity index 100% rename from server/src/com/cloud/user/dao/UserStatsLogDao.java rename to engine/schema/src/com/cloud/user/dao/UserStatsLogDao.java diff --git a/server/src/com/cloud/user/dao/UserStatsLogDaoImpl.java b/engine/schema/src/com/cloud/user/dao/UserStatsLogDaoImpl.java similarity index 100% rename from server/src/com/cloud/user/dao/UserStatsLogDaoImpl.java rename to engine/schema/src/com/cloud/user/dao/UserStatsLogDaoImpl.java diff --git a/engine/schema/src/com/cloud/vm/ConsoleProxyVO.java b/engine/schema/src/com/cloud/vm/ConsoleProxyVO.java new file mode 100644 index 00000000000..5c1da4855cd --- /dev/null +++ b/engine/schema/src/com/cloud/vm/ConsoleProxyVO.java @@ -0,0 +1,287 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.vm; + +import java.util.Date; + +import javax.persistence.Column; +import javax.persistence.DiscriminatorValue; +import javax.persistence.Entity; +import javax.persistence.PrimaryKeyJoinColumn; +import javax.persistence.Table; +import javax.persistence.Temporal; +import javax.persistence.TemporalType; +import javax.persistence.Transient; + +import com.cloud.hypervisor.Hypervisor.HypervisorType; + +/** + * ConsoleProxyVO domain object + */ + +@Entity +@Table(name = "console_proxy") +@PrimaryKeyJoinColumn(name = "id") +@DiscriminatorValue(value = "ConsoleProxy") +public class ConsoleProxyVO extends VMInstanceVO implements ConsoleProxy { + public static final String keyContent = + "-----BEGIN PRIVATE KEY-----\n" + + "MIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQCDT9AtEfs+s/I8QXp6rrCw0iNJ\n" + + "0+GgsybNHheU+JpL39LMTZykCrZhZnyDvwdxCoOfE38Sa32baHKNds+y2SHnMNsOkw8OcNucHEBX\n" + + "1FIpOBGph9D6xC+umx9od6xMWETUv7j6h2u+WC3OhBM8fHCBqIiAol31/IkcqDxxsHlQ8S/oCfTl\n" + + "XJUY6Yn628OA1XijKdRnadV0hZ829cv/PZKljjwQUTyrd0KHQeksBH+YAYSo2JUl8ekNLsOi8/cP\n" + + "tfojnltzRI1GXi0ZONs8VnDzJ0a2gqZY+uxlz+CGbLnGnlN4j9cBpE+MfUE+35Dq121sTpsSgF85\n" + + "Mz+pVhn2S633AgMBAAECggEAH/Szd9RxbVADenCA6wxKSa3KErRyq1YN8ksJeCKMAj0FIt0caruE\n" + + "qO11DebWW8cwQu1Otl/cYI6pmg24/BBldMrp9IELX/tNJo+lhPpRyGAxxC0eSXinFfoASb8d+jJd\n" + + "Bd1mmemM6fSxqRlxSP4LrzIhjhR1g2CiyYuTsiM9UtoVKGyHwe7KfFwirUOJo3Mr18zUVNm7YqY4\n" + + "IVhOSq59zkH3ULBlYq4bG50jpxa5mNSCZ7IpafPY/kE/CbR+FWNt30+rk69T+qb5abg6+XGm+OAm\n" + + "bnQ18yZEqX6nJLk7Ch0cfA5orGgrTMOrM71wK7tBBDQ308kOxDGebx6j0qD36QKBgQDTRDr8kuhA\n" + + "9sUyKr9vk2DQCMpNvEeiwI3JRMqmmxpNAtg01aJ3Ya57vX5Fc+zcuV87kP6FM1xgpHQvnw5LWo2J\n" + + "s7ANwQcP8ricEW5zkZhSjI4ssMeAubmsHOloGxmLFYZqwx0JI7CWViGTLMcUlqKblmHcjeQDeDfP\n" + + "P1TaCItFmwKBgQCfHZwVvIcaDs5vxVpZ4ftvflIrW8qq0uOVK6QIf9A/YTGhCXl2qxxTg2A6+0rg\n" + + "ZqI7zKzUDxIbVv0KlgCbpHDC9d5+sdtDB3wW2pimuJ3p1z4/RHb4n/lDwXCACZl1S5l24yXX2pFZ\n" + + "wdPCXmy5PYkHMssFLNhI24pprUIQs66M1QKBgQDQwjAjWisD3pRXESSfZRsaFkWJcM28hdbVFhPF\n" + + "c6gWhwQLmTp0CuL2RPXcPUPFi6sN2iWWi3zxxi9Eyz+9uBn6AsOpo56N5MME/LiOnETO9TKb+Ib6\n" + + "rQtKhjshcv3XkIqFPo2XdVvOAgglPO7vajX91iiXXuH7h7RmJud6l0y/lwKBgE+bi90gLuPtpoEr\n" + + "VzIDKz40ED5bNYHT80NNy0rpT7J2GVN9nwStRYXPBBVeZq7xCpgqpgmO5LtDAWULeZBlbHlOdBwl\n" + + "NhNKKl5wzdEUKwW0yBL1WSS5PQgWPwgARYP25/ggW22sj+49WIo1neXsEKPGWObk8e050f1fTt92\n" + + "Vo1lAoGAb1gCoyBCzvi7sqFxm4V5oapnJeiQQJFjhoYWqGa26rQ+AvXXNuBcigIeDXNJPctSF0Uc\n" + + "p11KbbCgiruBbckvM1vGsk6Sx4leRk+IFHRpJktFUek4o0eUg0shOsyyvyet48Dfg0a8FvcxROs0\n" + + "gD+IYds5doiob/hcm1hnNB/3vk4=\n" + + "-----END PRIVATE KEY-----\n"; + + public static final String certContent = + "-----BEGIN CERTIFICATE-----\n" + + "MIIFZTCCBE2gAwIBAgIHKBCduBUoKDANBgkqhkiG9w0BAQUFADCByjELMAkGA1UE\n" + + "BhMCVVMxEDAOBgNVBAgTB0FyaXpvbmExEzARBgNVBAcTClNjb3R0c2RhbGUxGjAY\n" + + "BgNVBAoTEUdvRGFkZHkuY29tLCBJbmMuMTMwMQYDVQQLEypodHRwOi8vY2VydGlm\n" + + "aWNhdGVzLmdvZGFkZHkuY29tL3JlcG9zaXRvcnkxMDAuBgNVBAMTJ0dvIERhZGR5\n" + + "IFNlY3VyZSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTERMA8GA1UEBRMIMDc5Njky\n" + + "ODcwHhcNMTIwMjAzMDMzMDQwWhcNMTcwMjA3MDUxMTIzWjBZMRkwFwYDVQQKDBAq\n" + + "LnJlYWxob3N0aXAuY29tMSEwHwYDVQQLDBhEb21haW4gQ29udHJvbCBWYWxpZGF0\n" + + "ZWQxGTAXBgNVBAMMECoucmVhbGhvc3RpcC5jb20wggEiMA0GCSqGSIb3DQEBAQUA\n" + + "A4IBDwAwggEKAoIBAQCDT9AtEfs+s/I8QXp6rrCw0iNJ0+GgsybNHheU+JpL39LM\n" + + "TZykCrZhZnyDvwdxCoOfE38Sa32baHKNds+y2SHnMNsOkw8OcNucHEBX1FIpOBGp\n" + + "h9D6xC+umx9od6xMWETUv7j6h2u+WC3OhBM8fHCBqIiAol31/IkcqDxxsHlQ8S/o\n" + + "CfTlXJUY6Yn628OA1XijKdRnadV0hZ829cv/PZKljjwQUTyrd0KHQeksBH+YAYSo\n" + + "2JUl8ekNLsOi8/cPtfojnltzRI1GXi0ZONs8VnDzJ0a2gqZY+uxlz+CGbLnGnlN4\n" + + "j9cBpE+MfUE+35Dq121sTpsSgF85Mz+pVhn2S633AgMBAAGjggG+MIIBujAPBgNV\n" + + "HRMBAf8EBTADAQEAMB0GA1UdJQQWMBQGCCsGAQUFBwMBBggrBgEFBQcDAjAOBgNV\n" + + "HQ8BAf8EBAMCBaAwMwYDVR0fBCwwKjAooCagJIYiaHR0cDovL2NybC5nb2RhZGR5\n" + + "LmNvbS9nZHMxLTY0LmNybDBTBgNVHSAETDBKMEgGC2CGSAGG/W0BBxcBMDkwNwYI\n" + + "KwYBBQUHAgEWK2h0dHA6Ly9jZXJ0aWZpY2F0ZXMuZ29kYWRkeS5jb20vcmVwb3Np\n" + + "dG9yeS8wgYAGCCsGAQUFBwEBBHQwcjAkBggrBgEFBQcwAYYYaHR0cDovL29jc3Au\n" + + "Z29kYWRkeS5jb20vMEoGCCsGAQUFBzAChj5odHRwOi8vY2VydGlmaWNhdGVzLmdv\n" + + "ZGFkZHkuY29tL3JlcG9zaXRvcnkvZ2RfaW50ZXJtZWRpYXRlLmNydDAfBgNVHSME\n" + + "GDAWgBT9rGEyk2xF1uLuhV+auud2mWjM5zArBgNVHREEJDAighAqLnJlYWxob3N0\n" + + "aXAuY29tgg5yZWFsaG9zdGlwLmNvbTAdBgNVHQ4EFgQUZyJz9/QLy5TWIIscTXID\n" + + "E8Xk47YwDQYJKoZIhvcNAQEFBQADggEBAKiUV3KK16mP0NpS92fmQkCLqm+qUWyN\n" + + "BfBVgf9/M5pcT8EiTZlS5nAtzAE/eRpBeR3ubLlaAogj4rdH7YYVJcDDLLoB2qM3\n" + + "qeCHu8LFoblkb93UuFDWqRaVPmMlJRnhsRkL1oa2gM2hwQTkBDkP7w5FG1BELCgl\n" + + "gZI2ij2yxjge6pOEwSyZCzzbCcg9pN+dNrYyGEtB4k+BBnPA3N4r14CWbk+uxjrQ\n" + + "6j2Ip+b7wOc5IuMEMl8xwTyjuX3lsLbAZyFI9RCyofwA9NqIZ1GeB6Zd196rubQp\n" + + "93cmBqGGjZUs3wMrGlm7xdjlX6GQ9UvmvkMub9+lL99A5W50QgCmFeI=\n" + + "-----END CERTIFICATE-----\n"; + + public static final String rootCa = + "-----BEGIN CERTIFICATE-----\n" + + "MIIE3jCCA8agAwIBAgICAwEwDQYJKoZIhvcNAQEFBQAwYzELMAkGA1UEBhMCVVMx\n" + + "ITAfBgNVBAoTGFRoZSBHbyBEYWRkeSBHcm91cCwgSW5jLjExMC8GA1UECxMoR28g\n" + + "RGFkZHkgQ2xhc3MgMiBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw0wNjExMTYw\n" + + "MTU0MzdaFw0yNjExMTYwMTU0MzdaMIHKMQswCQYDVQQGEwJVUzEQMA4GA1UECBMH\n" + + "QXJpem9uYTETMBEGA1UEBxMKU2NvdHRzZGFsZTEaMBgGA1UEChMRR29EYWRkeS5j\n" + + "b20sIEluYy4xMzAxBgNVBAsTKmh0dHA6Ly9jZXJ0aWZpY2F0ZXMuZ29kYWRkeS5j\n" + + "b20vcmVwb3NpdG9yeTEwMC4GA1UEAxMnR28gRGFkZHkgU2VjdXJlIENlcnRpZmlj\n" + + "YXRpb24gQXV0aG9yaXR5MREwDwYDVQQFEwgwNzk2OTI4NzCCASIwDQYJKoZIhvcN\n" + + "AQEBBQADggEPADCCAQoCggEBAMQt1RWMnCZM7DI161+4WQFapmGBWTtwY6vj3D3H\n" + + "KrjJM9N55DrtPDAjhI6zMBS2sofDPZVUBJ7fmd0LJR4h3mUpfjWoqVTr9vcyOdQm\n" + + "VZWt7/v+WIbXnvQAjYwqDL1CBM6nPwT27oDyqu9SoWlm2r4arV3aLGbqGmu75RpR\n" + + "SgAvSMeYddi5Kcju+GZtCpyz8/x4fKL4o/K1w/O5epHBp+YlLpyo7RJlbmr2EkRT\n" + + "cDCVw5wrWCs9CHRK8r5RsL+H0EwnWGu1NcWdrxcx+AuP7q2BNgWJCJjPOq8lh8BJ\n" + + "6qf9Z/dFjpfMFDniNoW1fho3/Rb2cRGadDAW/hOUoz+EDU8CAwEAAaOCATIwggEu\n" + + "MB0GA1UdDgQWBBT9rGEyk2xF1uLuhV+auud2mWjM5zAfBgNVHSMEGDAWgBTSxLDS\n" + + "kdRMEXGzYcs9of7dqGrU4zASBgNVHRMBAf8ECDAGAQH/AgEAMDMGCCsGAQUFBwEB\n" + + "BCcwJTAjBggrBgEFBQcwAYYXaHR0cDovL29jc3AuZ29kYWRkeS5jb20wRgYDVR0f\n" + + "BD8wPTA7oDmgN4Y1aHR0cDovL2NlcnRpZmljYXRlcy5nb2RhZGR5LmNvbS9yZXBv\n" + + "c2l0b3J5L2dkcm9vdC5jcmwwSwYDVR0gBEQwQjBABgRVHSAAMDgwNgYIKwYBBQUH\n" + + "AgEWKmh0dHA6Ly9jZXJ0aWZpY2F0ZXMuZ29kYWRkeS5jb20vcmVwb3NpdG9yeTAO\n" + + "BgNVHQ8BAf8EBAMCAQYwDQYJKoZIhvcNAQEFBQADggEBANKGwOy9+aG2Z+5mC6IG\n" + + "OgRQjhVyrEp0lVPLN8tESe8HkGsz2ZbwlFalEzAFPIUyIXvJxwqoJKSQ3kbTJSMU\n" + + "A2fCENZvD117esyfxVgqwcSeIaha86ykRvOe5GPLL5CkKSkB2XIsKd83ASe8T+5o\n" + + "0yGPwLPk9Qnt0hCqU7S+8MxZC9Y7lhyVJEnfzuz9p0iRFEUOOjZv2kWzRaJBydTX\n" + + "RE4+uXR21aITVSzGh6O1mawGhId/dQb8vxRMDsxuxN89txJx9OjxUUAiKEngHUuH\n" + + "qDTMBqLdElrRhjZkAzVvb3du6/KFUJheqwNTrZEjYx8WnM25sgVjOuH0aBsXBTWV\n" + + "U+4=\n" + + "-----END CERTIFICATE-----\n" + + "-----BEGIN CERTIFICATE-----\n" + + "MIIE+zCCBGSgAwIBAgICAQ0wDQYJKoZIhvcNAQEFBQAwgbsxJDAiBgNVBAcTG1Zh\n" + + "bGlDZXJ0IFZhbGlkYXRpb24gTmV0d29yazEXMBUGA1UEChMOVmFsaUNlcnQsIElu\n" + + "Yy4xNTAzBgNVBAsTLFZhbGlDZXJ0IENsYXNzIDIgUG9saWN5IFZhbGlkYXRpb24g\n" + + "QXV0aG9yaXR5MSEwHwYDVQQDExhodHRwOi8vd3d3LnZhbGljZXJ0LmNvbS8xIDAe\n" + + "BgkqhkiG9w0BCQEWEWluZm9AdmFsaWNlcnQuY29tMB4XDTA0MDYyOTE3MDYyMFoX\n" + + "DTI0MDYyOTE3MDYyMFowYzELMAkGA1UEBhMCVVMxITAfBgNVBAoTGFRoZSBHbyBE\n" + + "YWRkeSBHcm91cCwgSW5jLjExMC8GA1UECxMoR28gRGFkZHkgQ2xhc3MgMiBDZXJ0\n" + + "aWZpY2F0aW9uIEF1dGhvcml0eTCCASAwDQYJKoZIhvcNAQEBBQADggENADCCAQgC\n" + + "ggEBAN6d1+pXGEmhW+vXX0iG6r7d/+TvZxz0ZWizV3GgXne77ZtJ6XCAPVYYYwhv\n" + + "2vLM0D9/AlQiVBDYsoHUwHU9S3/Hd8M+eKsaA7Ugay9qK7HFiH7Eux6wwdhFJ2+q\n" + + "N1j3hybX2C32qRe3H3I2TqYXP2WYktsqbl2i/ojgC95/5Y0V4evLOtXiEqITLdiO\n" + + "r18SPaAIBQi2XKVlOARFmR6jYGB0xUGlcmIbYsUfb18aQr4CUWWoriMYavx4A6lN\n" + + "f4DD+qta/KFApMoZFv6yyO9ecw3ud72a9nmYvLEHZ6IVDd2gWMZEewo+YihfukEH\n" + + "U1jPEX44dMX4/7VpkI+EdOqXG68CAQOjggHhMIIB3TAdBgNVHQ4EFgQU0sSw0pHU\n" + + "TBFxs2HLPaH+3ahq1OMwgdIGA1UdIwSByjCBx6GBwaSBvjCBuzEkMCIGA1UEBxMb\n" + + "VmFsaUNlcnQgVmFsaWRhdGlvbiBOZXR3b3JrMRcwFQYDVQQKEw5WYWxpQ2VydCwg\n" + + "SW5jLjE1MDMGA1UECxMsVmFsaUNlcnQgQ2xhc3MgMiBQb2xpY3kgVmFsaWRhdGlv\n" + + "biBBdXRob3JpdHkxITAfBgNVBAMTGGh0dHA6Ly93d3cudmFsaWNlcnQuY29tLzEg\n" + + "MB4GCSqGSIb3DQEJARYRaW5mb0B2YWxpY2VydC5jb22CAQEwDwYDVR0TAQH/BAUw\n" + + "AwEB/zAzBggrBgEFBQcBAQQnMCUwIwYIKwYBBQUHMAGGF2h0dHA6Ly9vY3NwLmdv\n" + + "ZGFkZHkuY29tMEQGA1UdHwQ9MDswOaA3oDWGM2h0dHA6Ly9jZXJ0aWZpY2F0ZXMu\n" + + "Z29kYWRkeS5jb20vcmVwb3NpdG9yeS9yb290LmNybDBLBgNVHSAERDBCMEAGBFUd\n" + + "IAAwODA2BggrBgEFBQcCARYqaHR0cDovL2NlcnRpZmljYXRlcy5nb2RhZGR5LmNv\n" + + "bS9yZXBvc2l0b3J5MA4GA1UdDwEB/wQEAwIBBjANBgkqhkiG9w0BAQUFAAOBgQC1\n" + + "QPmnHfbq/qQaQlpE9xXUhUaJwL6e4+PrxeNYiY+Sn1eocSxI0YGyeR+sBjUZsE4O\n" + + "WBsUs5iB0QQeyAfJg594RAoYC5jcdnplDQ1tgMQLARzLrUc+cb53S8wGd9D0Vmsf\n" + + "SxOaFIqII6hR8INMqzW/Rn453HWkrugp++85j09VZw==\n" + + "-----END CERTIFICATE-----\n" + + "-----BEGIN CERTIFICATE-----\n" + + "MIIC5zCCAlACAQEwDQYJKoZIhvcNAQEFBQAwgbsxJDAiBgNVBAcTG1ZhbGlDZXJ0\n" + + "IFZhbGlkYXRpb24gTmV0d29yazEXMBUGA1UEChMOVmFsaUNlcnQsIEluYy4xNTAz\n" + + "BgNVBAsTLFZhbGlDZXJ0IENsYXNzIDIgUG9saWN5IFZhbGlkYXRpb24gQXV0aG9y\n" + + "aXR5MSEwHwYDVQQDExhodHRwOi8vd3d3LnZhbGljZXJ0LmNvbS8xIDAeBgkqhkiG\n" + + "9w0BCQEWEWluZm9AdmFsaWNlcnQuY29tMB4XDTk5MDYyNjAwMTk1NFoXDTE5MDYy\n" + + "NjAwMTk1NFowgbsxJDAiBgNVBAcTG1ZhbGlDZXJ0IFZhbGlkYXRpb24gTmV0d29y\n" + + "azEXMBUGA1UEChMOVmFsaUNlcnQsIEluYy4xNTAzBgNVBAsTLFZhbGlDZXJ0IENs\n" + + "YXNzIDIgUG9saWN5IFZhbGlkYXRpb24gQXV0aG9yaXR5MSEwHwYDVQQDExhodHRw\n" + + "Oi8vd3d3LnZhbGljZXJ0LmNvbS8xIDAeBgkqhkiG9w0BCQEWEWluZm9AdmFsaWNl\n" + + "cnQuY29tMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDOOnHK5avIWZJV16vY\n" + + "dA757tn2VUdZZUcOBVXc65g2PFxTXdMwzzjsvUGJ7SVCCSRrCl6zfN1SLUzm1NZ9\n" + + "WlmpZdRJEy0kTRxQb7XBhVQ7/nHk01xC+YDgkRoKWzk2Z/M/VXwbP7RfZHM047QS\n" + + "v4dk+NoS/zcnwbNDu+97bi5p9wIDAQABMA0GCSqGSIb3DQEBBQUAA4GBADt/UG9v\n" + + "UJSZSWI4OB9L+KXIPqeCgfYrx+jFzug6EILLGACOTb2oWH+heQC1u+mNr0HZDzTu\n" + + "IYEZoDJJKPTEjlbVUjP9UNV+mWwD5MlM/Mtsq2azSiGM5bUMMj4QssxsodyamEwC\n" + + "W/POuZ6lcg5Ktz885hZo+L7tdEy8W9ViH0Pd\n" + + "-----END CERTIFICATE-----\n"; + + @Column(name = "public_ip_address", nullable = false) + private String publicIpAddress; + + @Column(name = "public_mac_address", nullable = false) + private String publicMacAddress; + + @Column(name = "public_netmask", nullable = false) + private String publicNetmask; + + @Column(name = "active_session", updatable = true, nullable = false) + private int activeSession; + + @Temporal(TemporalType.TIMESTAMP) + @Column(name = "last_update", updatable = true, nullable = true) + private Date lastUpdateTime; + + @Column(name = "session_details", updatable = true, nullable = true) + private byte[] sessionDetails; + + @Transient + private boolean sslEnabled = false; + + @Transient + private int port; + + /** + * Correct constructor to use. + * + */ + public ConsoleProxyVO(long id, long serviceOfferingId, String name, long templateId, HypervisorType hypervisorType, long guestOSId, long dataCenterId, long domainId, long accountId, + int activeSession, boolean haEnabled) { + super(id, serviceOfferingId, name, name, Type.ConsoleProxy, templateId, hypervisorType, guestOSId, domainId, accountId, haEnabled); + this.activeSession = activeSession; + } + + protected ConsoleProxyVO() { + super(); + } + + public void setPublicIpAddress(String publicIpAddress) { + this.publicIpAddress = publicIpAddress; + } + + public void setPublicNetmask(String publicNetmask) { + this.publicNetmask = publicNetmask; + } + + public void setPublicMacAddress(String publicMacAddress) { + this.publicMacAddress = publicMacAddress; + } + + public void setActiveSession(int activeSession) { + this.activeSession = activeSession; + } + + public void setLastUpdateTime(Date time) { + this.lastUpdateTime = time; + } + + public void setSessionDetails(byte[] details) { + this.sessionDetails = details; + } + + @Override + public String getPublicIpAddress() { + return this.publicIpAddress; + } + + @Override + public String getPublicNetmask() { + return this.publicNetmask; + } + + @Override + public String getPublicMacAddress() { + return this.publicMacAddress; + } + + @Override + public int getActiveSession() { + return this.activeSession; + } + + @Override + public Date getLastUpdateTime() { + return this.lastUpdateTime; + } + + @Override + public byte[] getSessionDetails() { + return this.sessionDetails; + } + + public boolean isSslEnabled() { + return sslEnabled; + } + + public void setSslEnabled(boolean sslEnabled) { + this.sslEnabled = sslEnabled; + } + + public void setPort(int port) { + this.port = port; + } + + public int getPort() { + return port; + } + +} diff --git a/core/src/com/cloud/vm/DomainRouterVO.java b/engine/schema/src/com/cloud/vm/DomainRouterVO.java similarity index 100% rename from core/src/com/cloud/vm/DomainRouterVO.java rename to engine/schema/src/com/cloud/vm/DomainRouterVO.java diff --git a/core/src/com/cloud/vm/InstanceGroupVMMapVO.java b/engine/schema/src/com/cloud/vm/InstanceGroupVMMapVO.java similarity index 100% rename from core/src/com/cloud/vm/InstanceGroupVMMapVO.java rename to engine/schema/src/com/cloud/vm/InstanceGroupVMMapVO.java diff --git a/core/src/com/cloud/vm/InstanceGroupVO.java b/engine/schema/src/com/cloud/vm/InstanceGroupVO.java similarity index 100% rename from core/src/com/cloud/vm/InstanceGroupVO.java rename to engine/schema/src/com/cloud/vm/InstanceGroupVO.java diff --git a/server/src/com/cloud/vm/ItWorkDao.java b/engine/schema/src/com/cloud/vm/ItWorkDao.java similarity index 100% rename from server/src/com/cloud/vm/ItWorkDao.java rename to engine/schema/src/com/cloud/vm/ItWorkDao.java diff --git a/server/src/com/cloud/vm/ItWorkDaoImpl.java b/engine/schema/src/com/cloud/vm/ItWorkDaoImpl.java similarity index 100% rename from server/src/com/cloud/vm/ItWorkDaoImpl.java rename to engine/schema/src/com/cloud/vm/ItWorkDaoImpl.java diff --git a/server/src/com/cloud/vm/ItWorkVO.java b/engine/schema/src/com/cloud/vm/ItWorkVO.java similarity index 100% rename from server/src/com/cloud/vm/ItWorkVO.java rename to engine/schema/src/com/cloud/vm/ItWorkVO.java diff --git a/server/src/com/cloud/vm/NicVO.java b/engine/schema/src/com/cloud/vm/NicVO.java similarity index 100% rename from server/src/com/cloud/vm/NicVO.java rename to engine/schema/src/com/cloud/vm/NicVO.java diff --git a/core/src/com/cloud/vm/SecondaryStorageVmVO.java b/engine/schema/src/com/cloud/vm/SecondaryStorageVmVO.java similarity index 100% rename from core/src/com/cloud/vm/SecondaryStorageVmVO.java rename to engine/schema/src/com/cloud/vm/SecondaryStorageVmVO.java diff --git a/core/src/com/cloud/vm/UserVmCloneSettingVO.java b/engine/schema/src/com/cloud/vm/UserVmCloneSettingVO.java similarity index 100% rename from core/src/com/cloud/vm/UserVmCloneSettingVO.java rename to engine/schema/src/com/cloud/vm/UserVmCloneSettingVO.java diff --git a/core/src/com/cloud/vm/UserVmDetailVO.java b/engine/schema/src/com/cloud/vm/UserVmDetailVO.java similarity index 100% rename from core/src/com/cloud/vm/UserVmDetailVO.java rename to engine/schema/src/com/cloud/vm/UserVmDetailVO.java diff --git a/core/src/com/cloud/vm/UserVmVO.java b/engine/schema/src/com/cloud/vm/UserVmVO.java similarity index 100% rename from core/src/com/cloud/vm/UserVmVO.java rename to engine/schema/src/com/cloud/vm/UserVmVO.java diff --git a/core/src/com/cloud/vm/VMInstanceVO.java b/engine/schema/src/com/cloud/vm/VMInstanceVO.java similarity index 99% rename from core/src/com/cloud/vm/VMInstanceVO.java rename to engine/schema/src/com/cloud/vm/VMInstanceVO.java index 77e9c0279c9..5ec2712d3d8 100644 --- a/core/src/com/cloud/vm/VMInstanceVO.java +++ b/engine/schema/src/com/cloud/vm/VMInstanceVO.java @@ -153,7 +153,6 @@ public class VMInstanceVO implements VirtualMachine, FiniteStateObject { List listByNetworkId(long networkId); - NicVO findByInstanceIdAndNetworkId(long networkId, long instanceId); + NicVO findByNtwkIdAndInstanceId(long networkId, long instanceId); NicVO findByInstanceIdAndNetworkIdIncludingRemoved(long networkId, long instanceId); diff --git a/server/src/com/cloud/vm/dao/NicDaoImpl.java b/engine/schema/src/com/cloud/vm/dao/NicDaoImpl.java similarity index 99% rename from server/src/com/cloud/vm/dao/NicDaoImpl.java rename to engine/schema/src/com/cloud/vm/dao/NicDaoImpl.java index c70d19432ef..fa30168bf86 100644 --- a/server/src/com/cloud/vm/dao/NicDaoImpl.java +++ b/engine/schema/src/com/cloud/vm/dao/NicDaoImpl.java @@ -113,7 +113,7 @@ public class NicDaoImpl extends GenericDaoBase implements NicDao { } @Override - public NicVO findByInstanceIdAndNetworkId(long networkId, long instanceId) { + public NicVO findByNtwkIdAndInstanceId(long networkId, long instanceId) { SearchCriteria sc = AllFieldsSearch.create(); sc.setParameters("network", networkId); sc.setParameters("instance", instanceId); diff --git a/server/src/com/cloud/vm/dao/NicSecondaryIpDao.java b/engine/schema/src/com/cloud/vm/dao/NicSecondaryIpDao.java similarity index 100% rename from server/src/com/cloud/vm/dao/NicSecondaryIpDao.java rename to engine/schema/src/com/cloud/vm/dao/NicSecondaryIpDao.java diff --git a/server/src/com/cloud/vm/dao/NicSecondaryIpDaoImpl.java b/engine/schema/src/com/cloud/vm/dao/NicSecondaryIpDaoImpl.java similarity index 100% rename from server/src/com/cloud/vm/dao/NicSecondaryIpDaoImpl.java rename to engine/schema/src/com/cloud/vm/dao/NicSecondaryIpDaoImpl.java diff --git a/server/src/com/cloud/vm/dao/NicSecondaryIpVO.java b/engine/schema/src/com/cloud/vm/dao/NicSecondaryIpVO.java similarity index 100% rename from server/src/com/cloud/vm/dao/NicSecondaryIpVO.java rename to engine/schema/src/com/cloud/vm/dao/NicSecondaryIpVO.java diff --git a/server/src/com/cloud/vm/dao/SecondaryStorageVmDao.java b/engine/schema/src/com/cloud/vm/dao/SecondaryStorageVmDao.java similarity index 100% rename from server/src/com/cloud/vm/dao/SecondaryStorageVmDao.java rename to engine/schema/src/com/cloud/vm/dao/SecondaryStorageVmDao.java diff --git a/server/src/com/cloud/vm/dao/SecondaryStorageVmDaoImpl.java b/engine/schema/src/com/cloud/vm/dao/SecondaryStorageVmDaoImpl.java similarity index 100% rename from server/src/com/cloud/vm/dao/SecondaryStorageVmDaoImpl.java rename to engine/schema/src/com/cloud/vm/dao/SecondaryStorageVmDaoImpl.java diff --git a/server/src/com/cloud/vm/dao/UserVmCloneSettingDao.java b/engine/schema/src/com/cloud/vm/dao/UserVmCloneSettingDao.java similarity index 100% rename from server/src/com/cloud/vm/dao/UserVmCloneSettingDao.java rename to engine/schema/src/com/cloud/vm/dao/UserVmCloneSettingDao.java diff --git a/server/src/com/cloud/vm/dao/UserVmCloneSettingDaoImpl.java b/engine/schema/src/com/cloud/vm/dao/UserVmCloneSettingDaoImpl.java similarity index 100% rename from server/src/com/cloud/vm/dao/UserVmCloneSettingDaoImpl.java rename to engine/schema/src/com/cloud/vm/dao/UserVmCloneSettingDaoImpl.java diff --git a/server/src/com/cloud/vm/dao/UserVmDao.java b/engine/schema/src/com/cloud/vm/dao/UserVmDao.java similarity index 100% rename from server/src/com/cloud/vm/dao/UserVmDao.java rename to engine/schema/src/com/cloud/vm/dao/UserVmDao.java diff --git a/server/src/com/cloud/vm/dao/UserVmDaoImpl.java b/engine/schema/src/com/cloud/vm/dao/UserVmDaoImpl.java similarity index 100% rename from server/src/com/cloud/vm/dao/UserVmDaoImpl.java rename to engine/schema/src/com/cloud/vm/dao/UserVmDaoImpl.java diff --git a/server/src/com/cloud/vm/dao/UserVmData.java b/engine/schema/src/com/cloud/vm/dao/UserVmData.java similarity index 100% rename from server/src/com/cloud/vm/dao/UserVmData.java rename to engine/schema/src/com/cloud/vm/dao/UserVmData.java diff --git a/server/src/com/cloud/vm/dao/UserVmDetailsDao.java b/engine/schema/src/com/cloud/vm/dao/UserVmDetailsDao.java similarity index 100% rename from server/src/com/cloud/vm/dao/UserVmDetailsDao.java rename to engine/schema/src/com/cloud/vm/dao/UserVmDetailsDao.java diff --git a/server/src/com/cloud/vm/dao/UserVmDetailsDaoImpl.java b/engine/schema/src/com/cloud/vm/dao/UserVmDetailsDaoImpl.java similarity index 100% rename from server/src/com/cloud/vm/dao/UserVmDetailsDaoImpl.java rename to engine/schema/src/com/cloud/vm/dao/UserVmDetailsDaoImpl.java diff --git a/server/src/com/cloud/vm/dao/VMInstanceDao.java b/engine/schema/src/com/cloud/vm/dao/VMInstanceDao.java similarity index 100% rename from server/src/com/cloud/vm/dao/VMInstanceDao.java rename to engine/schema/src/com/cloud/vm/dao/VMInstanceDao.java diff --git a/server/src/com/cloud/vm/dao/VMInstanceDaoImpl.java b/engine/schema/src/com/cloud/vm/dao/VMInstanceDaoImpl.java similarity index 100% rename from server/src/com/cloud/vm/dao/VMInstanceDaoImpl.java rename to engine/schema/src/com/cloud/vm/dao/VMInstanceDaoImpl.java diff --git a/core/src/com/cloud/vm/snapshot/VMSnapshotVO.java b/engine/schema/src/com/cloud/vm/snapshot/VMSnapshotVO.java similarity index 100% rename from core/src/com/cloud/vm/snapshot/VMSnapshotVO.java rename to engine/schema/src/com/cloud/vm/snapshot/VMSnapshotVO.java diff --git a/server/src/com/cloud/vm/snapshot/dao/VMSnapshotDao.java b/engine/schema/src/com/cloud/vm/snapshot/dao/VMSnapshotDao.java similarity index 100% rename from server/src/com/cloud/vm/snapshot/dao/VMSnapshotDao.java rename to engine/schema/src/com/cloud/vm/snapshot/dao/VMSnapshotDao.java diff --git a/server/src/com/cloud/vm/snapshot/dao/VMSnapshotDaoImpl.java b/engine/schema/src/com/cloud/vm/snapshot/dao/VMSnapshotDaoImpl.java similarity index 100% rename from server/src/com/cloud/vm/snapshot/dao/VMSnapshotDaoImpl.java rename to engine/schema/src/com/cloud/vm/snapshot/dao/VMSnapshotDaoImpl.java diff --git a/server/src/org/apache/cloudstack/affinity/AffinityGroupVMMapVO.java b/engine/schema/src/org/apache/cloudstack/affinity/AffinityGroupVMMapVO.java similarity index 100% rename from server/src/org/apache/cloudstack/affinity/AffinityGroupVMMapVO.java rename to engine/schema/src/org/apache/cloudstack/affinity/AffinityGroupVMMapVO.java diff --git a/server/src/org/apache/cloudstack/affinity/AffinityGroupVO.java b/engine/schema/src/org/apache/cloudstack/affinity/AffinityGroupVO.java similarity index 100% rename from server/src/org/apache/cloudstack/affinity/AffinityGroupVO.java rename to engine/schema/src/org/apache/cloudstack/affinity/AffinityGroupVO.java diff --git a/server/src/org/apache/cloudstack/affinity/dao/AffinityGroupDao.java b/engine/schema/src/org/apache/cloudstack/affinity/dao/AffinityGroupDao.java similarity index 100% rename from server/src/org/apache/cloudstack/affinity/dao/AffinityGroupDao.java rename to engine/schema/src/org/apache/cloudstack/affinity/dao/AffinityGroupDao.java diff --git a/server/src/org/apache/cloudstack/affinity/dao/AffinityGroupDaoImpl.java b/engine/schema/src/org/apache/cloudstack/affinity/dao/AffinityGroupDaoImpl.java similarity index 100% rename from server/src/org/apache/cloudstack/affinity/dao/AffinityGroupDaoImpl.java rename to engine/schema/src/org/apache/cloudstack/affinity/dao/AffinityGroupDaoImpl.java diff --git a/server/src/org/apache/cloudstack/affinity/dao/AffinityGroupVMMapDao.java b/engine/schema/src/org/apache/cloudstack/affinity/dao/AffinityGroupVMMapDao.java similarity index 100% rename from server/src/org/apache/cloudstack/affinity/dao/AffinityGroupVMMapDao.java rename to engine/schema/src/org/apache/cloudstack/affinity/dao/AffinityGroupVMMapDao.java diff --git a/server/src/org/apache/cloudstack/affinity/dao/AffinityGroupVMMapDaoImpl.java b/engine/schema/src/org/apache/cloudstack/affinity/dao/AffinityGroupVMMapDaoImpl.java similarity index 100% rename from server/src/org/apache/cloudstack/affinity/dao/AffinityGroupVMMapDaoImpl.java rename to engine/schema/src/org/apache/cloudstack/affinity/dao/AffinityGroupVMMapDaoImpl.java diff --git a/engine/schema/src/org/apache/cloudstack/lb/ApplicationLoadBalancerRuleVO.java b/engine/schema/src/org/apache/cloudstack/lb/ApplicationLoadBalancerRuleVO.java new file mode 100644 index 00000000000..37a747e4272 --- /dev/null +++ b/engine/schema/src/org/apache/cloudstack/lb/ApplicationLoadBalancerRuleVO.java @@ -0,0 +1,133 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.cloudstack.lb; + +import javax.persistence.Column; +import javax.persistence.DiscriminatorValue; +import javax.persistence.Entity; +import javax.persistence.EnumType; +import javax.persistence.Enumerated; +import javax.persistence.PrimaryKeyJoinColumn; +import javax.persistence.Table; + +import org.apache.cloudstack.network.lb.ApplicationLoadBalancerRule; + +import com.cloud.network.rules.FirewallRuleVO; +import com.cloud.utils.net.Ip; +import com.cloud.utils.net.NetUtils; + +/** + * This VO represent Internal Load Balancer rule. + * Instead of pointing to the public ip address id directly as External Load Balancer rule does, it refers to the ip address by its value/sourceNetworkid + * + */ +@Entity +@Table(name=("load_balancing_rules")) +@DiscriminatorValue(value="LoadBalancing") +@PrimaryKeyJoinColumn(name="id") +public class ApplicationLoadBalancerRuleVO extends FirewallRuleVO implements ApplicationLoadBalancerRule{ + @Column(name="name") + private String name; + + @Column(name="description", length=4096) + private String description; + + @Column(name="algorithm") + private String algorithm; + + @Column(name="default_port_start") + private int defaultPortStart; + + @Column(name="default_port_end") + private int defaultPortEnd; + + @Column(name="source_ip_address_network_id") + Long sourceIpNetworkId; + + @Column(name="source_ip_address") + @Enumerated(value=EnumType.STRING) + private Ip sourceIp = null; + + @Enumerated(value=EnumType.STRING) + @Column(name="scheme") + Scheme scheme; + + + public ApplicationLoadBalancerRuleVO() { + } + + public ApplicationLoadBalancerRuleVO(String name, String description, int srcPort, int instancePort, String algorithm, + long networkId, long accountId, long domainId, Ip sourceIp, long sourceIpNtwkId, Scheme scheme) { + super(null, null, srcPort, srcPort, NetUtils.TCP_PROTO, networkId, accountId, domainId, Purpose.LoadBalancing, null, null,null, null, null); + + this.name = name; + this.description = description; + this.algorithm = algorithm; + this.defaultPortStart = instancePort; + this.defaultPortEnd = instancePort; + this.sourceIp = sourceIp; + this.sourceIpNetworkId = sourceIpNtwkId; + this.scheme = scheme; + } + + + @Override + public Long getSourceIpNetworkId() { + return sourceIpNetworkId; + } + + @Override + public Ip getSourceIp() { + return sourceIp; + } + + @Override + public String getName() { + return name; + } + + @Override + public String getDescription() { + return description; + } + + @Override + public String getAlgorithm() { + return algorithm; + } + + @Override + public int getDefaultPortStart() { + return defaultPortStart; + } + + @Override + public int getDefaultPortEnd() { + return defaultPortEnd; + } + + @Override + public Scheme getScheme() { + return scheme; + } + + @Override + public int getInstancePort() { + return defaultPortStart; + } +} diff --git a/engine/schema/src/org/apache/cloudstack/lb/dao/ApplicationLoadBalancerRuleDao.java b/engine/schema/src/org/apache/cloudstack/lb/dao/ApplicationLoadBalancerRuleDao.java new file mode 100644 index 00000000000..c385e62f6ab --- /dev/null +++ b/engine/schema/src/org/apache/cloudstack/lb/dao/ApplicationLoadBalancerRuleDao.java @@ -0,0 +1,35 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.cloudstack.lb.dao; + +import java.util.List; + +import org.apache.cloudstack.lb.ApplicationLoadBalancerRuleVO; + +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.utils.db.GenericDao; +import com.cloud.utils.net.Ip; + +public interface ApplicationLoadBalancerRuleDao extends GenericDao{ + List listBySrcIpSrcNtwkId(Ip sourceIp, long sourceNetworkId); + List listLbIpsBySourceIpNetworkId(long sourceIpNetworkId); + long countBySourceIp(Ip sourceIp, long sourceIpNetworkId); + List listBySourceIpAndNotRevoked(Ip sourceIp, long sourceNetworkId); + List listLbIpsBySourceIpNetworkIdAndScheme(long sourceIpNetworkId, Scheme scheme); + +} diff --git a/engine/schema/src/org/apache/cloudstack/lb/dao/ApplicationLoadBalancerRuleDaoImpl.java b/engine/schema/src/org/apache/cloudstack/lb/dao/ApplicationLoadBalancerRuleDaoImpl.java new file mode 100644 index 00000000000..880c67e732c --- /dev/null +++ b/engine/schema/src/org/apache/cloudstack/lb/dao/ApplicationLoadBalancerRuleDaoImpl.java @@ -0,0 +1,115 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.cloudstack.lb.dao; + +import java.util.List; + +import javax.ejb.Local; + +import org.apache.cloudstack.lb.ApplicationLoadBalancerRuleVO; +import org.springframework.stereotype.Component; + +import com.cloud.network.rules.FirewallRule; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.utils.db.GenericDaoBase; +import com.cloud.utils.db.GenericSearchBuilder; +import com.cloud.utils.db.SearchBuilder; +import com.cloud.utils.db.SearchCriteria; +import com.cloud.utils.db.SearchCriteria.Func; +import com.cloud.utils.db.SearchCriteria.Op; +import com.cloud.utils.net.Ip; + +@Component +@Local(value = { ApplicationLoadBalancerRuleDao.class }) +public class ApplicationLoadBalancerRuleDaoImpl extends GenericDaoBase implements ApplicationLoadBalancerRuleDao{ + protected final SearchBuilder AllFieldsSearch; + final GenericSearchBuilder listIps; + final GenericSearchBuilder CountBy; + protected final SearchBuilder NotRevokedSearch; + + + + protected ApplicationLoadBalancerRuleDaoImpl() { + AllFieldsSearch = createSearchBuilder(); + AllFieldsSearch.and("sourceIp", AllFieldsSearch.entity().getSourceIp(), SearchCriteria.Op.EQ); + AllFieldsSearch.and("sourceIpNetworkId", AllFieldsSearch.entity().getSourceIpNetworkId(), SearchCriteria.Op.EQ); + AllFieldsSearch.and("networkId", AllFieldsSearch.entity().getNetworkId(), SearchCriteria.Op.EQ); + AllFieldsSearch.and("scheme", AllFieldsSearch.entity().getScheme(), SearchCriteria.Op.EQ); + AllFieldsSearch.done(); + + listIps = createSearchBuilder(String.class); + listIps.select(null, Func.DISTINCT, listIps.entity().getSourceIp()); + listIps.and("sourceIpNetworkId", listIps.entity().getSourceIpNetworkId(), Op.EQ); + listIps.and("scheme", listIps.entity().getScheme(), Op.EQ); + listIps.done(); + + CountBy = createSearchBuilder(Long.class); + CountBy.select(null, Func.COUNT, CountBy.entity().getId()); + CountBy.and("sourceIp", CountBy.entity().getSourceIp(), Op.EQ); + CountBy.and("sourceIpNetworkId", CountBy.entity().getSourceIpNetworkId(), Op.EQ); + CountBy.done(); + + NotRevokedSearch = createSearchBuilder(); + NotRevokedSearch.and("sourceIp", NotRevokedSearch.entity().getSourceIp(), SearchCriteria.Op.EQ); + NotRevokedSearch.and("sourceIpNetworkId", NotRevokedSearch.entity().getSourceIpNetworkId(), SearchCriteria.Op.EQ); + NotRevokedSearch.and("state", NotRevokedSearch.entity().getState(), SearchCriteria.Op.NEQ); + NotRevokedSearch.done(); + } + + @Override + public List listBySrcIpSrcNtwkId(Ip sourceIp, long sourceNetworkId) { + SearchCriteria sc = AllFieldsSearch.create(); + sc.setParameters("sourceIp", sourceIp); + sc.setParameters("sourceIpNetworkId", sourceNetworkId); + return listBy(sc); + } + + @Override + public List listLbIpsBySourceIpNetworkId(long sourceIpNetworkId) { + SearchCriteria sc = listIps.create(); + sc.setParameters("sourceIpNetworkId", sourceIpNetworkId); + return customSearch(sc, null); + } + + @Override + public long countBySourceIp(Ip sourceIp, long sourceIpNetworkId) { + SearchCriteria sc = CountBy.create(); + sc.setParameters("sourceIp", sourceIp); + sc.setParameters("sourceIpNetworkId", sourceIpNetworkId); + List results = customSearch(sc, null); + return results.get(0); + } + + @Override + public List listBySourceIpAndNotRevoked(Ip sourceIp, long sourceNetworkId) { + SearchCriteria sc = NotRevokedSearch.create(); + sc.setParameters("sourceIp", sourceIp); + sc.setParameters("sourceIpNetworkId", sourceNetworkId); + sc.setParameters("state", FirewallRule.State.Revoke); + return listBy(sc); + } + + @Override + public List listLbIpsBySourceIpNetworkIdAndScheme(long sourceIpNetworkId, Scheme scheme) { + SearchCriteria sc = listIps.create(); + sc.setParameters("sourceIpNetworkId", sourceIpNetworkId); + sc.setParameters("scheme", scheme); + return customSearch(sc, null); + } + +} diff --git a/server/src/org/apache/cloudstack/region/RegionSyncVO.java b/engine/schema/src/org/apache/cloudstack/region/RegionSyncVO.java similarity index 100% rename from server/src/org/apache/cloudstack/region/RegionSyncVO.java rename to engine/schema/src/org/apache/cloudstack/region/RegionSyncVO.java diff --git a/server/src/org/apache/cloudstack/region/RegionVO.java b/engine/schema/src/org/apache/cloudstack/region/RegionVO.java similarity index 100% rename from server/src/org/apache/cloudstack/region/RegionVO.java rename to engine/schema/src/org/apache/cloudstack/region/RegionVO.java diff --git a/server/src/org/apache/cloudstack/region/dao/RegionDao.java b/engine/schema/src/org/apache/cloudstack/region/dao/RegionDao.java similarity index 100% rename from server/src/org/apache/cloudstack/region/dao/RegionDao.java rename to engine/schema/src/org/apache/cloudstack/region/dao/RegionDao.java diff --git a/server/src/org/apache/cloudstack/region/dao/RegionDaoImpl.java b/engine/schema/src/org/apache/cloudstack/region/dao/RegionDaoImpl.java similarity index 100% rename from server/src/org/apache/cloudstack/region/dao/RegionDaoImpl.java rename to engine/schema/src/org/apache/cloudstack/region/dao/RegionDaoImpl.java diff --git a/server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerDaoImpl.java b/engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerDaoImpl.java similarity index 100% rename from server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerDaoImpl.java rename to engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerDaoImpl.java diff --git a/server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapDao.java b/engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapDao.java similarity index 100% rename from server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapDao.java rename to engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapDao.java diff --git a/server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapDaoImpl.java b/engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapDaoImpl.java similarity index 100% rename from server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapDaoImpl.java rename to engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapDaoImpl.java diff --git a/server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapVO.java b/engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapVO.java similarity index 100% rename from server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapVO.java rename to engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerLbRuleMapVO.java diff --git a/server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerRuleDao.java b/engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerRuleDao.java similarity index 100% rename from server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerRuleDao.java rename to engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerRuleDao.java diff --git a/server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerRuleVO.java b/engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerRuleVO.java similarity index 100% rename from server/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerRuleVO.java rename to engine/schema/src/org/apache/cloudstack/region/gslb/GlobalLoadBalancerRuleVO.java diff --git a/engine/storage/integration-test/test/org/apache/cloudstack/storage/allocator/StorageAllocatorTestConfiguration.java b/engine/storage/integration-test/test/org/apache/cloudstack/storage/allocator/StorageAllocatorTestConfiguration.java index b815fc13446..4790086b2e1 100644 --- a/engine/storage/integration-test/test/org/apache/cloudstack/storage/allocator/StorageAllocatorTestConfiguration.java +++ b/engine/storage/integration-test/test/org/apache/cloudstack/storage/allocator/StorageAllocatorTestConfiguration.java @@ -20,6 +20,7 @@ import java.io.IOException; import org.apache.cloudstack.storage.allocator.StorageAllocatorTestConfiguration.Library; import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDaoImpl; +import org.apache.cloudstack.test.utils.SpringUtils; import org.mockito.Mockito; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.ComponentScan; @@ -36,7 +37,6 @@ import com.cloud.host.dao.HostDaoImpl; import com.cloud.storage.StorageManager; import com.cloud.storage.dao.StoragePoolDetailsDaoImpl; import com.cloud.storage.dao.VMTemplateDaoImpl; -import com.cloud.utils.component.SpringComponentScanUtils; import com.cloud.vm.UserVmManager; @@ -67,7 +67,7 @@ public class StorageAllocatorTestConfiguration { public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { mdr.getClassMetadata().getClassName(); ComponentScan cs = StorageAllocatorTestConfiguration.class.getAnnotation(ComponentScan.class); - return SpringComponentScanUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); } } } diff --git a/engine/storage/integration-test/test/org/apache/cloudstack/storage/test/ChildTestConfiguration.java b/engine/storage/integration-test/test/org/apache/cloudstack/storage/test/ChildTestConfiguration.java index a063bdda8ad..0dcdebd6553 100644 --- a/engine/storage/integration-test/test/org/apache/cloudstack/storage/test/ChildTestConfiguration.java +++ b/engine/storage/integration-test/test/org/apache/cloudstack/storage/test/ChildTestConfiguration.java @@ -24,6 +24,7 @@ import org.apache.cloudstack.framework.rpc.RpcProvider; import org.apache.cloudstack.storage.HostEndpointRpcServer; import org.apache.cloudstack.storage.endpoint.EndPointSelector; import org.apache.cloudstack.storage.test.ChildTestConfiguration.Library; +import org.apache.cloudstack.test.utils.SpringUtils; import org.mockito.Mockito; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.ComponentScan; @@ -75,7 +76,6 @@ import com.cloud.storage.swift.SwiftManager; import com.cloud.tags.dao.ResourceTagsDaoImpl; import com.cloud.template.TemplateManager; import com.cloud.user.dao.UserDaoImpl; -import com.cloud.utils.component.SpringComponentScanUtils; import com.cloud.vm.VirtualMachineManager; import com.cloud.vm.dao.ConsoleProxyDaoImpl; import com.cloud.vm.dao.DomainRouterDao; @@ -222,7 +222,7 @@ public class ChildTestConfiguration extends TestConfiguration { public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { mdr.getClassMetadata().getClassName(); ComponentScan cs = ChildTestConfiguration.class.getAnnotation(ComponentScan.class); - return SpringComponentScanUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); } } diff --git a/engine/storage/volume/src/org/apache/cloudstack/storage/datastore/provider/DefaultHostListener.java b/engine/storage/volume/src/org/apache/cloudstack/storage/datastore/provider/DefaultHostListener.java index f2cb1c45c82..2f0b43ad9f6 100644 --- a/engine/storage/volume/src/org/apache/cloudstack/storage/datastore/provider/DefaultHostListener.java +++ b/engine/storage/volume/src/org/apache/cloudstack/storage/datastore/provider/DefaultHostListener.java @@ -56,7 +56,7 @@ public class DefaultHostListener implements HypervisorHostListener { } if (!answer.getResult()) { - String msg = "Add host failed due to ModifyStoragePoolCommand failed" + answer.getDetails(); + String msg = "Unable to attach storage pool" + poolId + " to the host" + hostId; alertMgr.sendAlert(AlertManager.ALERT_TYPE_HOST, pool.getDataCenterId(), pool.getPodId(), msg, msg); throw new CloudRuntimeException("Unable establish connection from storage head to storage pool " + pool.getId() + " due to " + answer.getDetails() + pool.getId()); } diff --git a/framework/api/pom.xml b/framework/api/pom.xml deleted file mode 100644 index 5260ebc4bf6..00000000000 --- a/framework/api/pom.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - 4.0.0 - cloud-framework-api - - org.apache.cloudstack - cloudstack-framework - 4.2.0-SNAPSHOT - ../pom.xml - - - - - org.apache.cloudstack - cloud-utils - 4.2.0-SNAPSHOT - - - - - - install - src - ${project.basedir}/test - - - ${project.basedir}/test/resources - - - - diff --git a/framework/events/pom.xml b/framework/events/pom.xml index 7c788c35bbd..747c5a1a667 100644 --- a/framework/events/pom.xml +++ b/framework/events/pom.xml @@ -1,23 +1,14 @@ - + + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 cloud-framework-events Apache CloudStack Framework - Event Notification @@ -30,18 +21,18 @@ org.apache.cloudstack - cloud-utils - ${project.version} - + cloud-utils + ${project.version} + - com.google.code.gson - gson - ${cs.gson.version} + com.google.code.gson + gson + ${cs.gson.version} + + + com.google.guava + guava + ${cs.guava.version} - - install - src - test - diff --git a/framework/ipc/pom.xml b/framework/ipc/pom.xml index b7f4fcc78ce..2c2131f01c1 100644 --- a/framework/ipc/pom.xml +++ b/framework/ipc/pom.xml @@ -20,26 +20,24 @@ ../pom.xml - - org.apache.cloudstack - cloud-core - 4.2.0-SNAPSHOT + cglib + cglib-nodep + ${cs.cglib.version} + + + com.google.code.gson + gson + ${cs.gson.version} - org.apache.cloudstack cloud-utils - 4.2.0-SNAPSHOT + ${project.version} - - install - src - ${project.basedir}/test ${project.basedir}/test/resources diff --git a/framework/api/src/org/apache/cloudstack/framework/async/AsyncCallFuture.java b/framework/ipc/src/org/apache/cloudstack/framework/async/AsyncCallFuture.java similarity index 100% rename from framework/api/src/org/apache/cloudstack/framework/async/AsyncCallFuture.java rename to framework/ipc/src/org/apache/cloudstack/framework/async/AsyncCallFuture.java diff --git a/framework/api/src/org/apache/cloudstack/framework/async/AsyncCompletionCallback.java b/framework/ipc/src/org/apache/cloudstack/framework/async/AsyncCompletionCallback.java similarity index 100% rename from framework/api/src/org/apache/cloudstack/framework/async/AsyncCompletionCallback.java rename to framework/ipc/src/org/apache/cloudstack/framework/async/AsyncCompletionCallback.java diff --git a/framework/ipc/src/org/apache/cloudstack/framework/client/ClientEventBus.java b/framework/ipc/src/org/apache/cloudstack/framework/client/ClientEventBus.java index 7930bf2fea0..d876b01981a 100644 --- a/framework/ipc/src/org/apache/cloudstack/framework/client/ClientEventBus.java +++ b/framework/ipc/src/org/apache/cloudstack/framework/client/ClientEventBus.java @@ -18,10 +18,10 @@ */ package org.apache.cloudstack.framework.client; -import org.apache.cloudstack.framework.eventbus.EventBusBase; +import org.apache.cloudstack.framework.messagebus.MessageBusBase; import org.apache.cloudstack.framework.transport.TransportMultiplexier; -public class ClientEventBus extends EventBusBase implements TransportMultiplexier { +public class ClientEventBus extends MessageBusBase implements TransportMultiplexier { @Override public void onTransportMessage(String senderEndpointAddress, diff --git a/framework/ipc/src/org/apache/cloudstack/framework/client/ClientTransportProvider.java b/framework/ipc/src/org/apache/cloudstack/framework/client/ClientTransportProvider.java index bd93824ea85..023b3181b20 100644 --- a/framework/ipc/src/org/apache/cloudstack/framework/client/ClientTransportProvider.java +++ b/framework/ipc/src/org/apache/cloudstack/framework/client/ClientTransportProvider.java @@ -28,7 +28,7 @@ import org.apache.cloudstack.framework.transport.TransportEndpoint; import org.apache.cloudstack.framework.transport.TransportEndpointSite; import org.apache.cloudstack.framework.transport.TransportProvider; -import com.cloud.utils.concurrency.NamedThreadFactory; +import com.cloud.utils.concurrency.NamedThreadFactory; public class ClientTransportProvider implements TransportProvider { public static final int DEFAULT_WORKER_POOL_SIZE = 5; diff --git a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventBus.java b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageBus.java similarity index 81% rename from framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventBus.java rename to framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageBus.java index 200715c396f..a15dd442937 100644 --- a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventBus.java +++ b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageBus.java @@ -17,16 +17,18 @@ * under the License. */ -package org.apache.cloudstack.framework.eventbus; +package org.apache.cloudstack.framework.messagebus; import org.apache.cloudstack.framework.serializer.MessageSerializer; -public interface EventBus { +public interface MessageBus { void setMessageSerializer(MessageSerializer messageSerializer); MessageSerializer getMessageSerializer(); - void subscribe(String subject, Subscriber subscriber); - void unsubscribe(String subject, Subscriber subscriber); + void subscribe(String subject, MessageSubscriber subscriber); + void unsubscribe(String subject, MessageSubscriber subscriber); + void clearAll(); + void prune(); void publish(String senderAddress, String subject, PublishScope scope, Object args); } diff --git a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventBusBase.java b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageBusBase.java similarity index 63% rename from framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventBusBase.java rename to framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageBusBase.java index 30a847f0f9a..9cf5e77ce6e 100644 --- a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventBusBase.java +++ b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageBusBase.java @@ -17,7 +17,7 @@ * under the License. */ -package org.apache.cloudstack.framework.eventbus; +package org.apache.cloudstack.framework.messagebus; import java.util.ArrayList; import java.util.Arrays; @@ -28,7 +28,7 @@ import java.util.Map; import org.apache.cloudstack.framework.serializer.MessageSerializer; -public class EventBusBase implements EventBus { +public class MessageBusBase implements MessageBus { private Gate _gate; private List _pendingActions; @@ -36,11 +36,11 @@ public class EventBusBase implements EventBus { private SubscriptionNode _subscriberRoot; private MessageSerializer _messageSerializer; - public EventBusBase() { + public MessageBusBase() { _gate = new Gate(); _pendingActions = new ArrayList(); - _subscriberRoot = new SubscriptionNode("/", null); + _subscriberRoot = new SubscriptionNode(null, "/", null); } @Override @@ -54,7 +54,7 @@ public class EventBusBase implements EventBus { } @Override - public void subscribe(String subject, Subscriber subscriber) { + public void subscribe(String subject, MessageSubscriber subscriber) { assert(subject != null); assert(subscriber != null); if(_gate.enter()) { @@ -70,12 +70,15 @@ public class EventBusBase implements EventBus { } @Override - public void unsubscribe(String subject, Subscriber subscriber) { + public void unsubscribe(String subject, MessageSubscriber subscriber) { if(_gate.enter()) { - SubscriptionNode current = locate(subject, null, false); - if(current != null) - current.removeSubscriber(subscriber); - + if(subject != null) { + SubscriptionNode current = locate(subject, null, false); + if(current != null) + current.removeSubscriber(subscriber, false); + } else { + this._subscriberRoot.removeSubscriber(subscriber, true); + } _gate.leave(); } else { synchronized(_pendingActions) { @@ -83,7 +86,48 @@ public class EventBusBase implements EventBus { } } } - + + @Override + public void clearAll() { + if(_gate.enter()) { + _subscriberRoot.clearAll(); + doPrune(); + _gate.leave(); + } else { + synchronized(_pendingActions) { + _pendingActions.add(new ActionRecord(ActionType.ClearAll, null, null)); + } + } + } + + @Override + public void prune() { + if(_gate.enter()) { + doPrune(); + _gate.leave(); + } else { + synchronized(_pendingActions) { + _pendingActions.add(new ActionRecord(ActionType.Prune, null, null)); + } + } + } + + private void doPrune() { + List trimNodes = new ArrayList(); + _subscriberRoot.prune(trimNodes); + + while(trimNodes.size() > 0) { + SubscriptionNode node = trimNodes.remove(0); + SubscriptionNode parent = node.getParent(); + if(parent != null) { + parent.removeChild(node.getNodeKey()); + if(parent.isTrimmable()) { + trimNodes.add(parent); + } + } + } + } + @Override public void publish(String senderAddress, String subject, PublishScope scope, Object args) { @@ -119,12 +163,22 @@ public class EventBusBase implements EventBus { break; case Unsubscribe : - { + if(record.getSubject() != null) { SubscriptionNode current = locate(record.getSubject(), null, false); if(current != null) - current.removeSubscriber(record.getSubscriber()); + current.removeSubscriber(record.getSubscriber(), false); + } else { + this._subscriberRoot.removeSubscriber(record.getSubscriber(), true); } break; + + case ClearAll : + _subscriberRoot.clearAll(); + break; + + case Prune : + doPrune(); + break; default : assert(false); @@ -136,11 +190,13 @@ public class EventBusBase implements EventBus { } } - private SubscriptionNode locate(String subject, List chainFromTop, boolean createPath) { assert(subject != null); + // "/" is special name for root node + if(subject.equals("/")) + return _subscriberRoot; String[] subjectPathTokens = subject.split("\\."); return locate(subjectPathTokens, _subscriberRoot, chainFromTop, createPath); @@ -159,7 +215,7 @@ public class EventBusBase implements EventBus { SubscriptionNode next = current.getChild(subjectPathTokens[0]); if(next == null) { if(createPath) { - next = new SubscriptionNode(subjectPathTokens[0], null); + next = new SubscriptionNode(current, subjectPathTokens[0], null); current.addChild(subjectPathTokens[0], next); } else { return null; @@ -180,15 +236,17 @@ public class EventBusBase implements EventBus { // private static enum ActionType { Subscribe, - Unsubscribe + Unsubscribe, + ClearAll, + Prune } private static class ActionRecord { private ActionType _type; private String _subject; - private Subscriber _subscriber; + private MessageSubscriber _subscriber; - public ActionRecord(ActionType type, String subject, Subscriber subscriber) { + public ActionRecord(ActionType type, String subject, MessageSubscriber subscriber) { _type = type; _subject = subject; _subscriber = subscriber; @@ -202,7 +260,7 @@ public class EventBusBase implements EventBus { return _subject; } - public Subscriber getSubscriber() { + public MessageSubscriber getSubscriber() { return _subscriber; } } @@ -262,15 +320,16 @@ public class EventBusBase implements EventBus { } private static class SubscriptionNode { - @SuppressWarnings("unused") private String _nodeKey; - private List _subscribers; + private List _subscribers; private Map _children; + private SubscriptionNode _parent; - public SubscriptionNode(String nodeKey, Subscriber subscriber) { + public SubscriptionNode(SubscriptionNode parent, String nodeKey, MessageSubscriber subscriber) { assert(nodeKey != null); + _parent = parent; _nodeKey = nodeKey; - _subscribers = new ArrayList(); + _subscribers = new ArrayList(); if(subscriber != null) _subscribers.add(subscriber); @@ -278,16 +337,30 @@ public class EventBusBase implements EventBus { _children = new HashMap(); } + public SubscriptionNode getParent() { + return _parent; + } + + public String getNodeKey() { + return _nodeKey; + } + @SuppressWarnings("unused") - public List getSubscriber() { + public List getSubscriber() { return _subscribers; } - public void addSubscriber(Subscriber subscriber) { - _subscribers.add(subscriber); + public void addSubscriber(MessageSubscriber subscriber) { + if(!_subscribers.contains(subscriber)) + _subscribers.add(subscriber); } - public void removeSubscriber(Subscriber subscriber) { + public void removeSubscriber(MessageSubscriber subscriber, boolean recursively) { + if(recursively) { + for(Map.Entry entry : _children.entrySet()) { + entry.getValue().removeSubscriber(subscriber, true); + } + } _subscribers.remove(subscriber); } @@ -299,10 +372,37 @@ public class EventBusBase implements EventBus { _children.put(key, childNode); } - public void notifySubscribers(String senderAddress, String subject, Object args) { - for(Subscriber subscriber : _subscribers) { - subscriber.onPublishEvent(senderAddress, subject, args); + public void removeChild(String key) { + _children.remove(key); + } + + public void clearAll() { + // depth-first + for(Map.Entry entry : _children.entrySet()) { + entry.getValue().clearAll(); } + _subscribers.clear(); + } + + public void prune(List trimNodes) { + assert(trimNodes != null); + + for(Map.Entry entry : _children.entrySet()) { + entry.getValue().prune(trimNodes); + } + + if(isTrimmable()) + trimNodes.add(this); + } + + public void notifySubscribers(String senderAddress, String subject, Object args) { + for(MessageSubscriber subscriber : _subscribers) { + subscriber.onPublishMessage(senderAddress, subject, args); + } + } + + public boolean isTrimmable() { + return _children.size() == 0 && _subscribers.size() == 0; } } } diff --git a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventBusEndpoint.java b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageBusEndpoint.java similarity index 77% rename from framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventBusEndpoint.java rename to framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageBusEndpoint.java index 19a9b03dad9..0824e131e25 100644 --- a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventBusEndpoint.java +++ b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageBusEndpoint.java @@ -17,26 +17,26 @@ * under the License. */ -package org.apache.cloudstack.framework.eventbus; +package org.apache.cloudstack.framework.messagebus; -public class EventBusEndpoint { - private EventBus _eventBus; +public class MessageBusEndpoint { + private MessageBus _eventBus; private String _sender; private PublishScope _scope; - public EventBusEndpoint(EventBus eventBus, String sender, PublishScope scope) { + public MessageBusEndpoint(MessageBus eventBus, String sender, PublishScope scope) { _eventBus = eventBus; _sender = sender; _scope = scope; } - public EventBusEndpoint setEventBus(EventBus eventBus) { + public MessageBusEndpoint setEventBus(MessageBus eventBus) { _eventBus = eventBus; return this; } - public EventBusEndpoint setScope(PublishScope scope) { + public MessageBusEndpoint setScope(PublishScope scope) { _scope = scope; return this; } @@ -45,7 +45,7 @@ public class EventBusEndpoint { return _scope; } - public EventBusEndpoint setSender(String sender) { + public MessageBusEndpoint setSender(String sender) { _sender = sender; return this; } diff --git a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventDispatcher.java b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageDispatcher.java similarity index 83% rename from framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventDispatcher.java rename to framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageDispatcher.java index 336a994a6cc..ac75afb7c7d 100644 --- a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventDispatcher.java +++ b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageDispatcher.java @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -package org.apache.cloudstack.framework.eventbus; +package org.apache.cloudstack.framework.messagebus; import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; @@ -24,27 +24,27 @@ import java.util.HashMap; import java.util.Map; -public class EventDispatcher implements Subscriber { +public class MessageDispatcher implements MessageSubscriber { private static Map, Method> s_handlerCache = new HashMap, Method>(); - private static Map s_targetMap = new HashMap(); + private static Map s_targetMap = new HashMap(); private Object _targetObject; - public EventDispatcher(Object targetObject) { + public MessageDispatcher(Object targetObject) { _targetObject = targetObject; } @Override - public void onPublishEvent(String senderAddress, String subject, Object args) { + public void onPublishMessage(String senderAddress, String subject, Object args) { dispatch(_targetObject, subject, senderAddress, args); } - public static EventDispatcher getDispatcher(Object targetObject) { - EventDispatcher dispatcher; + public static MessageDispatcher getDispatcher(Object targetObject) { + MessageDispatcher dispatcher; synchronized(s_targetMap) { dispatcher = s_targetMap.get(targetObject); if(dispatcher == null) { - dispatcher = new EventDispatcher(targetObject); + dispatcher = new MessageDispatcher(targetObject); s_targetMap.put(targetObject, dispatcher); } } @@ -85,7 +85,7 @@ public class EventDispatcher implements Subscriber { return handler; for(Method method : handlerClz.getMethods()) { - EventHandler annotation = method.getAnnotation(EventHandler.class); + MessageHandler annotation = method.getAnnotation(MessageHandler.class); if(annotation != null) { if(match(annotation.topic(), subject)) { s_handlerCache.put(handlerClz, method); diff --git a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventHandler.java b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageHandler.java similarity index 92% rename from framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventHandler.java rename to framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageHandler.java index 1ed3a00b96f..d9f51df1a11 100644 --- a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/EventHandler.java +++ b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageHandler.java @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -package org.apache.cloudstack.framework.eventbus; +package org.apache.cloudstack.framework.messagebus; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; @@ -25,6 +25,6 @@ import java.lang.annotation.Target; @Retention(RetentionPolicy.RUNTIME) @Target(ElementType.METHOD) -public @interface EventHandler { +public @interface MessageHandler { public String topic(); } diff --git a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/Subscriber.java b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageSubscriber.java similarity index 83% rename from framework/ipc/src/org/apache/cloudstack/framework/eventbus/Subscriber.java rename to framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageSubscriber.java index 28b86de050e..072f98d9d1e 100644 --- a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/Subscriber.java +++ b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/MessageSubscriber.java @@ -17,8 +17,8 @@ * under the License. */ -package org.apache.cloudstack.framework.eventbus; +package org.apache.cloudstack.framework.messagebus; -public interface Subscriber { - void onPublishEvent(String senderAddress, String subject, Object args); +public interface MessageSubscriber { + void onPublishMessage(String senderAddress, String subject, Object args); } diff --git a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/PublishScope.java b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/PublishScope.java similarity index 94% rename from framework/ipc/src/org/apache/cloudstack/framework/eventbus/PublishScope.java rename to framework/ipc/src/org/apache/cloudstack/framework/messagebus/PublishScope.java index 539a242a55f..2b3d8acc841 100644 --- a/framework/ipc/src/org/apache/cloudstack/framework/eventbus/PublishScope.java +++ b/framework/ipc/src/org/apache/cloudstack/framework/messagebus/PublishScope.java @@ -17,7 +17,7 @@ * under the License. */ -package org.apache.cloudstack.framework.eventbus; +package org.apache.cloudstack.framework.messagebus; public enum PublishScope { LOCAL, GLOBAL diff --git a/framework/ipc/src/org/apache/cloudstack/framework/server/ServerEventBus.java b/framework/ipc/src/org/apache/cloudstack/framework/server/ServerEventBus.java index 11bc428a42b..f3b782d6d35 100644 --- a/framework/ipc/src/org/apache/cloudstack/framework/server/ServerEventBus.java +++ b/framework/ipc/src/org/apache/cloudstack/framework/server/ServerEventBus.java @@ -18,10 +18,10 @@ */ package org.apache.cloudstack.framework.server; -import org.apache.cloudstack.framework.eventbus.EventBusBase; +import org.apache.cloudstack.framework.messagebus.MessageBusBase; import org.apache.cloudstack.framework.transport.TransportMultiplexier; -public class ServerEventBus extends EventBusBase implements TransportMultiplexier { +public class ServerEventBus extends MessageBusBase implements TransportMultiplexier { @Override public void onTransportMessage(String senderEndpointAddress, diff --git a/framework/ipc/test/org/apache/cloudstack/framework/sampleserver/SampleManagerComponent.java b/framework/ipc/test/org/apache/cloudstack/framework/sampleserver/SampleManagerComponent.java index 7b0a2eca192..d59fe42d5ea 100644 --- a/framework/ipc/test/org/apache/cloudstack/framework/sampleserver/SampleManagerComponent.java +++ b/framework/ipc/test/org/apache/cloudstack/framework/sampleserver/SampleManagerComponent.java @@ -24,9 +24,9 @@ import java.util.TimerTask; import javax.annotation.PostConstruct; import javax.inject.Inject; -import org.apache.cloudstack.framework.eventbus.EventBus; -import org.apache.cloudstack.framework.eventbus.EventDispatcher; -import org.apache.cloudstack.framework.eventbus.EventHandler; +import org.apache.cloudstack.framework.messagebus.MessageBus; +import org.apache.cloudstack.framework.messagebus.MessageDispatcher; +import org.apache.cloudstack.framework.messagebus.MessageHandler; import org.apache.cloudstack.framework.rpc.RpcCallbackListener; import org.apache.cloudstack.framework.rpc.RpcException; import org.apache.cloudstack.framework.rpc.RpcProvider; @@ -41,7 +41,7 @@ public class SampleManagerComponent { private static final Logger s_logger = Logger.getLogger(SampleManagerComponent.class); @Inject - private EventBus _eventBus; + private MessageBus _eventBus; @Inject private RpcProvider _rpcProvider; @@ -58,7 +58,7 @@ public class SampleManagerComponent { // subscribe to all network events (for example) _eventBus.subscribe("network", - EventDispatcher.getDispatcher(this)); + MessageDispatcher.getDispatcher(this)); _timer.schedule(new TimerTask() { public void run() { @@ -72,7 +72,7 @@ public class SampleManagerComponent { call.completeCall("NetworkPrepare completed"); } - @EventHandler(topic="network.prepare") + @MessageHandler(topic="network.prepare") void onPrepareNetwork(String sender, String topic, Object args) { } diff --git a/framework/ipc/test/org/apache/cloudstack/framework/sampleserver/SampleManagerComponent2.java b/framework/ipc/test/org/apache/cloudstack/framework/sampleserver/SampleManagerComponent2.java index dc482c035fb..448c37b4c45 100644 --- a/framework/ipc/test/org/apache/cloudstack/framework/sampleserver/SampleManagerComponent2.java +++ b/framework/ipc/test/org/apache/cloudstack/framework/sampleserver/SampleManagerComponent2.java @@ -21,9 +21,9 @@ package org.apache.cloudstack.framework.sampleserver; import javax.annotation.PostConstruct; import javax.inject.Inject; -import org.apache.cloudstack.framework.eventbus.EventBus; -import org.apache.cloudstack.framework.eventbus.EventDispatcher; -import org.apache.cloudstack.framework.eventbus.EventHandler; +import org.apache.cloudstack.framework.messagebus.MessageBus; +import org.apache.cloudstack.framework.messagebus.MessageDispatcher; +import org.apache.cloudstack.framework.messagebus.MessageHandler; import org.apache.cloudstack.framework.rpc.RpcProvider; import org.apache.cloudstack.framework.rpc.RpcServerCall; import org.apache.cloudstack.framework.rpc.RpcServiceDispatcher; @@ -36,7 +36,7 @@ public class SampleManagerComponent2 { private static final Logger s_logger = Logger.getLogger(SampleManagerComponent2.class); @Inject - private EventBus _eventBus; + private MessageBus _eventBus; @Inject private RpcProvider _rpcProvider; @@ -51,7 +51,7 @@ public class SampleManagerComponent2 { // subscribe to all network events (for example) _eventBus.subscribe("storage", - EventDispatcher.getDispatcher(this)); + MessageDispatcher.getDispatcher(this)); } @RpcServiceHandler(command="StoragePrepare") @@ -66,7 +66,7 @@ public class SampleManagerComponent2 { call.completeCall(answer); } - @EventHandler(topic="storage.prepare") + @MessageHandler(topic="storage.prepare") void onPrepareNetwork(String sender, String topic, Object args) { } diff --git a/framework/ipc/test/org/apache/cloudstack/messagebus/TestMessageBus.java b/framework/ipc/test/org/apache/cloudstack/messagebus/TestMessageBus.java new file mode 100644 index 00000000000..dabfdd3b102 --- /dev/null +++ b/framework/ipc/test/org/apache/cloudstack/messagebus/TestMessageBus.java @@ -0,0 +1,116 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package org.apache.cloudstack.messagebus; + +import javax.inject.Inject; + +import junit.framework.TestCase; + +import org.apache.cloudstack.framework.messagebus.MessageBus; +import org.apache.cloudstack.framework.messagebus.MessageSubscriber; +import org.apache.cloudstack.framework.messagebus.PublishScope; +import org.junit.Assert; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.mockito.Mockito; +import org.springframework.test.context.ContextConfiguration; +import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; + +@RunWith(SpringJUnit4ClassRunner.class) +@ContextConfiguration(locations="classpath:/MessageBusTestContext.xml") +public class TestMessageBus extends TestCase { + + @Inject MessageBus _messageBus; + + @Test + public void testExactSubjectMatch() { + _messageBus.subscribe("Host", new MessageSubscriber() { + + @Override + public void onPublishMessage(String senderAddress, String subject, Object args) { + Assert.assertEquals(subject, "Host"); + } + }); + + _messageBus.publish(null, "Host", PublishScope.LOCAL, null); + _messageBus.publish(null, "VM", PublishScope.LOCAL, null); + _messageBus.clearAll(); + } + + @Test + public void testRootSubjectMatch() { + _messageBus.subscribe("/", new MessageSubscriber() { + + @Override + public void onPublishMessage(String senderAddress, String subject, Object args) { + Assert.assertTrue(subject.equals("Host") || subject.equals("VM")); + } + }); + + _messageBus.publish(null, "Host", PublishScope.LOCAL, null); + _messageBus.publish(null, "VM", PublishScope.LOCAL, null); + _messageBus.clearAll(); + } + + @Test + public void testMiscMatch() { + MessageSubscriber subscriberAtParentLevel = new MessageSubscriber() { + @Override + public void onPublishMessage(String senderAddress, String subject, Object args) { + Assert.assertTrue(subject.startsWith(("Host")) || subject.startsWith("VM")); + } + }; + + MessageSubscriber subscriberAtChildLevel = new MessageSubscriber() { + @Override + public void onPublishMessage(String senderAddress, String subject, Object args) { + Assert.assertTrue(subject.equals("Host.123")); + } + }; + + subscriberAtParentLevel = Mockito.spy(subscriberAtParentLevel); + subscriberAtChildLevel = Mockito.spy(subscriberAtChildLevel); + + _messageBus.subscribe("Host", subscriberAtParentLevel); + _messageBus.subscribe("VM", subscriberAtParentLevel); + _messageBus.subscribe("Host.123", subscriberAtChildLevel); + + _messageBus.publish(null, "Host.123", PublishScope.LOCAL, null); + _messageBus.publish(null, "Host.321", PublishScope.LOCAL, null); + _messageBus.publish(null, "VM.123", PublishScope.LOCAL, null); + + Mockito.verify(subscriberAtParentLevel).onPublishMessage(null, "Host.123", null); + Mockito.verify(subscriberAtParentLevel).onPublishMessage(null, "Host.321", null); + Mockito.verify(subscriberAtParentLevel).onPublishMessage(null, "VM.123", null); + Mockito.verify(subscriberAtChildLevel).onPublishMessage(null, "Host.123", null); + + Mockito.reset(subscriberAtParentLevel); + Mockito.reset(subscriberAtChildLevel); + + _messageBus.unsubscribe(null, subscriberAtParentLevel); + _messageBus.publish(null, "Host.123", PublishScope.LOCAL, null); + _messageBus.publish(null, "VM.123", PublishScope.LOCAL, null); + + Mockito.verify(subscriberAtChildLevel).onPublishMessage(null, "Host.123", null); + Mockito.verify(subscriberAtParentLevel, Mockito.times(0)).onPublishMessage(null, "Host.123", null); + Mockito.verify(subscriberAtParentLevel, Mockito.times(0)).onPublishMessage(null, "VM.123", null); + + _messageBus.clearAll(); + } +} diff --git a/framework/ipc/test/resources/MessageBusTestContext.xml b/framework/ipc/test/resources/MessageBusTestContext.xml new file mode 100644 index 00000000000..fcfcb08416b --- /dev/null +++ b/framework/ipc/test/resources/MessageBusTestContext.xml @@ -0,0 +1,51 @@ + + + + + + + + org.apache.cloudstack.framework + + + + + + + + + + + + + diff --git a/framework/jobs/pom.xml b/framework/jobs/pom.xml index 56490216f16..5ae63af77ad 100644 --- a/framework/jobs/pom.xml +++ b/framework/jobs/pom.xml @@ -18,12 +18,31 @@ --> 4.0.0 - org.apache.cloudstack cloud-framework-jobs - 4.0.0-SNAPSHOT - - org.quartz-scheduler - quartz - 2.1.6 - + + org.apache.cloudstack + cloudstack-framework + 4.2.0-SNAPSHOT + ../pom.xml + + + + org.quartz-scheduler + quartz + 2.1.6 + + + org.apache.cloudstack + cloud-utils + ${project.version} + + + org.apache.cloudstack + cloud-api + ${project.version} + + + + install + diff --git a/framework/pom.xml b/framework/pom.xml index 4633dab2b30..ddcdcb0439a 100644 --- a/framework/pom.xml +++ b/framework/pom.xml @@ -33,6 +33,6 @@ ipc rest events - api + jobs diff --git a/patches/systemvm/debian/config/etc/dnsmasq.conf b/patches/systemvm/debian/config/etc/dnsmasq.conf.tmpl similarity index 99% rename from patches/systemvm/debian/config/etc/dnsmasq.conf rename to patches/systemvm/debian/config/etc/dnsmasq.conf.tmpl index 7d656cb2b77..38e5a8bbc96 100644 --- a/patches/systemvm/debian/config/etc/dnsmasq.conf +++ b/patches/systemvm/debian/config/etc/dnsmasq.conf.tmpl @@ -27,7 +27,7 @@ bogus-priv # so don't use it if you use eg Kerberos, SIP, XMMP or Google-talk. # This option only affects forwarding, SRV records originating for # dnsmasq (via srv-host= lines) are not suppressed by it. -filterwin2k +# filterwin2k # Change this line if you want dns to get its upstream servers from # somewhere other that /etc/resolv.conf diff --git a/patches/systemvm/debian/config/etc/init.d/cloud-early-config b/patches/systemvm/debian/config/etc/init.d/cloud-early-config index 6ffd648faeb..a457f228653 100755 --- a/patches/systemvm/debian/config/etc/init.d/cloud-early-config +++ b/patches/systemvm/debian/config/etc/init.d/cloud-early-config @@ -442,6 +442,9 @@ setup_dnsmasq() { [ -z $DHCP_RANGE ] && [ $ETH0_IP ] && DHCP_RANGE=$ETH0_IP [ $ETH0_IP6 ] && DHCP_RANGE_IP6=$ETH0_IP6 [ -z $DOMAIN ] && DOMAIN="cloudnine.internal" + + #get the template + cp /etc/dnsmasq.conf.tmpl /etc/dnsmasq.conf if [ -n "$DOMAIN" ] then @@ -898,6 +901,28 @@ setup_elbvm() { chkconfig portmap off } +setup_ilbvm() { + log_it "Setting up Internal Load Balancer system vm" + local hyp=$1 + setup_common eth0 eth1 + #eth0 = guest network, eth1=control network + + sed -i /$NAME/d /etc/hosts + echo "$ETH0_IP $NAME" >> /etc/hosts + + cp /etc/iptables/iptables-ilbvm /etc/iptables/rules.v4 + cp /etc/iptables/iptables-ilbvm /etc/iptables/rules + setup_sshd $ETH1_IP "eth1" + + enable_fwding 0 + enable_svc haproxy 1 + enable_svc dnsmasq 0 + enable_svc cloud-passwd-srvr 0 + enable_svc cloud 0 + chkconfig nfs-common off + chkconfig portmap off +} + setup_default() { cat > /etc/network/interfaces << EOF auto lo @@ -948,6 +973,10 @@ start() { [ "$NAME" == "" ] && NAME=elb setup_elbvm ;; + ilbvm) + [ "$NAME" == "" ] && NAME=ilb + setup_ilbvm + ;; unknown) [ "$NAME" == "" ] && NAME=systemvm setup_default; diff --git a/patches/systemvm/debian/config/etc/iptables/iptables-ilbvm b/patches/systemvm/debian/config/etc/iptables/iptables-ilbvm new file mode 100755 index 00000000000..8d5ca651c75 --- /dev/null +++ b/patches/systemvm/debian/config/etc/iptables/iptables-ilbvm @@ -0,0 +1,33 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +*nat +:PREROUTING ACCEPT [0:0] +:POSTROUTING ACCEPT [0:0] +:OUTPUT ACCEPT [0:0] +COMMIT +*filter +:INPUT DROP [0:0] +:FORWARD DROP [0:0] +:OUTPUT ACCEPT [0:0] +-A INPUT -i eth0 -m state --state RELATED,ESTABLISHED -j ACCEPT +-A INPUT -i eth1 -m state --state RELATED,ESTABLISHED -j ACCEPT +-A INPUT -p icmp -j ACCEPT +-A INPUT -i lo -j ACCEPT +-A INPUT -i eth1 -p tcp -m state --state NEW --dport 3922 -j ACCEPT +COMMIT + diff --git a/patches/systemvm/debian/config/etc/vpcdnsmasq.conf b/patches/systemvm/debian/config/etc/vpcdnsmasq.conf index 3717fc8a80c..3622d0e7916 100644 --- a/patches/systemvm/debian/config/etc/vpcdnsmasq.conf +++ b/patches/systemvm/debian/config/etc/vpcdnsmasq.conf @@ -460,6 +460,3 @@ log-facility=/var/log/dnsmasq.log # Include a another lot of configuration options. #conf-file=/etc/dnsmasq.more.conf conf-dir=/etc/dnsmasq.d - -# Don't reply Windows's periodical DNS request -filterwin2k diff --git a/patches/systemvm/debian/config/opt/cloud/bin/ilb.sh b/patches/systemvm/debian/config/opt/cloud/bin/ilb.sh new file mode 100755 index 00000000000..2a298925be3 --- /dev/null +++ b/patches/systemvm/debian/config/opt/cloud/bin/ilb.sh @@ -0,0 +1,211 @@ +#!/usr/bin/env bash +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +source /root/func.sh + +lock="biglock" +locked=$(getLockFile $lock) +if [ "$locked" != "1" ] +then + exit 1 +fi + +usage() { + printf "Usage: %s: -a -d -f -s \n" $(basename $0) >&2 +} + +#set -x + +fw_remove_backup() { + logger -t cloud "$(basename $0): Entering fw_remove_backup" + local lb_vif_list=eth0 + for vif in $lb_vif_list; do + sudo iptables -F back_load_balancer_$vif 2> /dev/null + sudo iptables -D INPUT -i $vif -p tcp -j back_load_balancer_$vif 2> /dev/null + sudo iptables -X back_load_balancer_$vif 2> /dev/null + done + sudo iptables -F back_lb_stats 2> /dev/null + sudo iptables -D INPUT -p tcp -j back_lb_stats 2> /dev/null + sudo iptables -X back_lb_stats 2> /dev/null +} + +fw_restore() { + logger -t cloud "$(basename $0): Entering fw_restore" + local lb_vif_list="eth0" + for vif in $lb_vif_list; do + sudo iptables -F load_balancer_$vif 2> /dev/null + sudo iptables -D INPUT -i $vif -p tcp -j load_balancer_$vif 2> /dev/null + sudo iptables -X load_balancer_$vif 2> /dev/null + sudo iptables -E back_load_balancer_$vif load_balancer_$vif 2> /dev/null + done + sudo iptables -F lb_stats 2> /dev/null + sudo iptables -D INPUT -p tcp -j lb_stats 2> /dev/null + sudo iptables -X lb_stats 2> /dev/null + sudo iptables -E back_lb_stats lb_stats 2> /dev/null +} + +# firewall entry to ensure that haproxy can receive on specified port +fw_entry() { + logger -t cloud "$(basename $0): Entering fw_entry" + local added=$1 + local removed=$2 + local stats=$3 + + if [ "$added" == "none" ] + then + added="" + fi + + if [ "$removed" == "none" ] + then + removed="" + fi + + local a=$(echo $added | cut -d, -f1- --output-delimiter=" ") + local r=$(echo $removed | cut -d, -f1- --output-delimiter=" ") + +# back up the iptable rules by renaming before creating new. + local lb_vif_list=eth0 + for vif in $lb_vif_list; do + sudo iptables -E load_balancer_$vif back_load_balancer_$vif 2> /dev/null + sudo iptables -N load_balancer_$vif 2> /dev/null + sudo iptables -A INPUT -i $vif -p tcp -j load_balancer_$vif + done + sudo iptables -E lb_stats back_lb_stats 2> /dev/null + sudo iptables -N lb_stats 2> /dev/null + sudo iptables -A INPUT -p tcp -j lb_stats + + for i in $a + do + local pubIp=$(echo $i | cut -d: -f1) + local dport=$(echo $i | cut -d: -f2) + local lb_vif_list="eth0" + for vif in $lb_vif_list; do + sudo iptables -A load_balancer_$vif -p tcp -d $pubIp --dport $dport -j ACCEPT + if [ $? -gt 0 ] + then + return 1 + fi + done + done + local pubIp=$(echo $stats | cut -d: -f1) + local dport=$(echo $stats | cut -d: -f2) + local cidrs=$(echo $stats | cut -d: -f3 | sed 's/-/,/') + sudo iptables -A lb_stats -s $cidrs -p tcp -m state --state NEW -d $pubIp --dport $dport -j ACCEPT + + return 0 +} + +#Hot reconfigure HA Proxy in the routing domain +reconfig_lb() { + /root/reconfigLB.sh + return $? +} + +# Restore the HA Proxy to its previous state, and revert iptables rules on loadbalancer +restore_lb() { + logger -t cloud "Restoring HA Proxy to previous state" + # Copy the old version of haproxy.cfg into the file that reconfigLB.sh uses + cp /etc/haproxy/haproxy.cfg.old /etc/haproxy/haproxy.cfg.new + + if [ $? -eq 0 ] + then + # Run reconfigLB.sh again + /root/reconfigLB.sh + fi +} + + +logger -t cloud "$(basename $0): Entering $(dirname $0)/$(basename $0)" + +iflag= +aflag= +dflag= +sflag= + +while getopts 'i:a:d:s:' OPTION +do + case $OPTION in + i) iflag=1 + domRIp="$OPTARG" #unused but passed in + ;; + a) aflag=1 + addedIps="$OPTARG" + ;; + d) dflag=1 + removedIps="$OPTARG" + ;; + + s) sflag=1 + statsIp="$OPTARG" + ;; + ?) usage + unlock_exit 2 $lock $locked + ;; + esac +done + +if [[ "$aflag$dflag" != "1" && "$aflag$dflag" != "11" ]] +then + usage + unlock_exit 2 $lock $locked +fi + +if [ "$addedIps" == "" ] +then + addedIps="none" +fi + + +if [ "$removedIps" == "" ] +then + removedIps="none" +fi + + +# hot reconfigure haproxy +reconfig_lb $cfgfile + +if [ $? -gt 0 ] +then + logger -t cloud "Reconfiguring ilb failed" + unlock_exit 1 $lock $locked +fi + +logger -t cloud "HAProxy reconfigured successfully, configuring firewall" + +# iptables entry to ensure that haproxy receives traffic +fw_entry $addedIps $removedIps $statsIp + +if [ $? -gt 0 ] +then + logger -t cloud "Failed to apply firewall rules for internal load balancing, reverting HA Proxy config" + # Restore the LB + restore_lb + + logger -t cloud "Reverting firewall config" + fw_restore + + unlock_exit 1 $lock $locked +else + # Remove backedup iptable rules + logger -t cloud "Firewall configured successfully, deleting backup firewall config" + fw_remove_backup +fi + +unlock_exit 0 $lock $locked diff --git a/patches/systemvm/debian/config/opt/cloud/bin/patchsystemvm.sh b/patches/systemvm/debian/config/opt/cloud/bin/patchsystemvm.sh index 8816ad7c068..9cb02502ef1 100755 --- a/patches/systemvm/debian/config/opt/cloud/bin/patchsystemvm.sh +++ b/patches/systemvm/debian/config/opt/cloud/bin/patchsystemvm.sh @@ -135,6 +135,19 @@ elbvm_svcs() { echo "cloud dnsmasq cloud-passwd-srvr apache2 nfs-common portmap" > /var/cache/cloud/disabled_svcs } + +ilbvm_svcs() { + chkconfig cloud off + chkconfig haproxy on ; + chkconfig ssh on + chkconfig nfs-common off + chkconfig portmap off + chkconfig keepalived off + chkconfig conntrackd off + echo "ssh haproxy" > /var/cache/cloud/enabled_svcs + echo "cloud dnsmasq cloud-passwd-srvr apache2 nfs-common portmap" > /var/cache/cloud/disabled_svcs +} + enable_pcihotplug() { sed -i -e "/acpiphp/d" /etc/modules sed -i -e "/pci_hotplug/d" /etc/modules @@ -253,4 +266,14 @@ then fi fi +if [ "$TYPE" == "ilbvm" ] +then + ilbvm_svcs + if [ $? -gt 0 ] + then + printf "Failed to execute ilbvm svcs\n" >$logfile + exit 9 + fi +fi + exit $? diff --git a/patches/systemvm/debian/config/opt/cloud/bin/vpc_loadbalancer.sh b/patches/systemvm/debian/config/opt/cloud/bin/vpc_loadbalancer.sh index 334c6177392..36a2347a297 100755 --- a/patches/systemvm/debian/config/opt/cloud/bin/vpc_loadbalancer.sh +++ b/patches/systemvm/debian/config/opt/cloud/bin/vpc_loadbalancer.sh @@ -18,6 +18,29 @@ # @VERSION@ +do_ilb_if_ilb () { + local typ="" + local pattern="type=(.*)" + + for keyval in $(cat /var/cache/cloud/cmdline) + do + if [[ $keyval =~ $pattern ]]; then + typ=${BASH_REMATCH[1]}; + fi + done + if [ "$typ" == "ilbvm" ] + then + logger -t cloud "$(basename $0): Detected that we are running in an internal load balancer vm" + $(dirname $0)/ilb.sh "$@" + exit $? + fi + +} + +logger -t cloud "$(basename $0): Entering $(dirname $0)/$(basename $0)" + +do_ilb_if_ilb "$@" + source /root/func.sh source /opt/cloud/bin/vpc_func.sh diff --git a/patches/systemvm/debian/config/opt/cloud/bin/vpc_privateGateway.sh b/patches/systemvm/debian/config/opt/cloud/bin/vpc_privateGateway.sh index a09d8f7e38b..3635e1cd44c 100755 --- a/patches/systemvm/debian/config/opt/cloud/bin/vpc_privateGateway.sh +++ b/patches/systemvm/debian/config/opt/cloud/bin/vpc_privateGateway.sh @@ -91,7 +91,7 @@ fi if [ "$Dflag" == "1" ] then - remove_sat $publicIp + remove_snat $publicIp unlock_exit $? $lock $locked fi diff --git a/patches/systemvm/debian/config/root/edithosts.sh b/patches/systemvm/debian/config/root/edithosts.sh index 1f98fbf96ae..fb0c34fbd42 100755 --- a/patches/systemvm/debian/config/root/edithosts.sh +++ b/patches/systemvm/debian/config/root/edithosts.sh @@ -19,12 +19,6 @@ # edithosts.sh -- edit the dhcphosts file on the routing domain -# $mac : the mac address -# $ip : the associated ip address -# $host : the hostname -# $4 : default router -# $5 : nameserver on default nic -# $6 : comma separated static routes usage() { printf "Usage: %s: -m -4 -6 -h -d -n -s -u [-N]\n" $(basename $0) >&2 @@ -84,6 +78,9 @@ fi grep "redundant_router=1" /var/cache/cloud/cmdline > /dev/null no_redundant=$? +command -v dhcp_release > /dev/null 2>&1 +no_dhcp_release=$? + wait_for_dnsmasq () { local _pid=$(pidof dnsmasq) for i in 0 1 2 3 4 5 6 7 8 9 10 @@ -97,7 +94,15 @@ wait_for_dnsmasq () { return 1 } -logger -t cloud "edithosts: update $1 $2 $3 to hosts" +if [ $no_dhcp_release -eq 0 ] +then + #release previous dhcp lease if present + logger -t cloud "edithosts: releasing $ipv4" + dhcp_release lo $ipv4 $(grep $ipv4 $DHCP_LEASES | awk '{print $2}') > /dev/null 2>&1 + logger -t cloud "edithosts: released $ipv4" +fi + +logger -t cloud "edithosts: update $mac $ipv4 $ipv6 $host to hosts" [ ! -f $DHCP_HOSTS ] && touch $DHCP_HOSTS [ ! -f $DHCP_OPTS ] && touch $DHCP_OPTS @@ -113,7 +118,8 @@ if [ $ipv6 ] then sed -i /$ipv6,/d $DHCP_HOSTS fi -sed -i /$host,/d $DHCP_HOSTS +# don't want to do this in the future, we can have same VM with multiple nics/entries +#sed -i /$host,/d $DHCP_HOSTS #put in the new entry @@ -200,8 +206,13 @@ fi pid=$(pidof dnsmasq) if [ "$pid" != "" ] then - #service dnsmasq restart - kill -HUP $pid + # use SIGHUP to avoid service outage if dhcp_release is available. + if [ $no_dhcp_release -eq 0 ] + then + kill -HUP $pid + else + service dnsmasq restart + fi else if [ $no_redundant -eq 1 ] then diff --git a/plugins/api/discovery/src/org/apache/cloudstack/discovery/ApiDiscoveryServiceImpl.java b/plugins/api/discovery/src/org/apache/cloudstack/discovery/ApiDiscoveryServiceImpl.java index 2d7dbd18671..860240faef0 100755 --- a/plugins/api/discovery/src/org/apache/cloudstack/discovery/ApiDiscoveryServiceImpl.java +++ b/plugins/api/discovery/src/org/apache/cloudstack/discovery/ApiDiscoveryServiceImpl.java @@ -83,6 +83,9 @@ public class ApiDiscoveryServiceImpl implements ApiDiscoveryService { } String apiName = apiCmdAnnotation.name(); + if (s_logger.isTraceEnabled()) { + s_logger.trace("Found api: " + apiName); + } ApiDiscoveryResponse response = getCmdRequestMap(cmdClass, apiCmdAnnotation); String responseName = apiCmdAnnotation.responseObject().getName(); @@ -216,6 +219,7 @@ public class ApiDiscoveryServiceImpl implements ApiDiscoveryService { try { apiChecker.checkAccess(user, name); } catch (Exception ex) { + s_logger.debug("API discovery access check failed for " + name + " with " + ex.getMessage()); return null; } } diff --git a/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java b/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java index 0064edf6a68..8fe8c88d0f8 100755 --- a/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java +++ b/plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/resource/LibvirtComputingResource.java @@ -1756,7 +1756,7 @@ ServerResource { String netmask = Long.toString(NetUtils.getCidrSize(ip.getVlanNetmask())); String subnet = NetUtils.getSubNet(ip.getPublicIp(), ip.getVlanNetmask()); _virtRouterResource.assignVpcIpToRouter(routerIP, ip.isAdd(), ip.getPublicIp(), - nicName, ip.getVlanGateway(), netmask, subnet); + nicName, ip.getVlanGateway(), netmask, subnet, ip.isSourceNat()); results[i++] = ip.getPublicIp() + " - success"; } diff --git a/plugins/hypervisors/simulator/src/com/cloud/agent/manager/SimulatorManagerImpl.java b/plugins/hypervisors/simulator/src/com/cloud/agent/manager/SimulatorManagerImpl.java index c234cc5cb2e..ab6eec3394a 100644 --- a/plugins/hypervisors/simulator/src/com/cloud/agent/manager/SimulatorManagerImpl.java +++ b/plugins/hypervisors/simulator/src/com/cloud/agent/manager/SimulatorManagerImpl.java @@ -16,12 +16,74 @@ // under the License. package com.cloud.agent.manager; -import com.cloud.agent.api.*; +import java.util.HashMap; +import java.util.Map; + +import javax.ejb.Local; +import javax.inject.Inject; +import javax.naming.ConfigurationException; + +import org.apache.log4j.Logger; +import org.springframework.stereotype.Component; + +import com.cloud.agent.api.Answer; +import com.cloud.agent.api.AttachIsoCommand; +import com.cloud.agent.api.AttachVolumeCommand; +import com.cloud.agent.api.BackupSnapshotCommand; +import com.cloud.agent.api.BumpUpPriorityCommand; +import com.cloud.agent.api.CheckHealthCommand; +import com.cloud.agent.api.CheckNetworkCommand; +import com.cloud.agent.api.CheckRouterCommand; +import com.cloud.agent.api.CheckVirtualMachineCommand; +import com.cloud.agent.api.CleanupNetworkRulesCmd; +import com.cloud.agent.api.ClusterSyncCommand; +import com.cloud.agent.api.Command; +import com.cloud.agent.api.ComputeChecksumCommand; +import com.cloud.agent.api.CreatePrivateTemplateFromSnapshotCommand; +import com.cloud.agent.api.CreatePrivateTemplateFromVolumeCommand; +import com.cloud.agent.api.CreateStoragePoolCommand; +import com.cloud.agent.api.CreateVolumeFromSnapshotCommand; +import com.cloud.agent.api.DeleteSnapshotBackupCommand; +import com.cloud.agent.api.DeleteStoragePoolCommand; +import com.cloud.agent.api.GetDomRVersionCmd; +import com.cloud.agent.api.GetHostStatsCommand; +import com.cloud.agent.api.GetStorageStatsCommand; +import com.cloud.agent.api.GetVmStatsCommand; +import com.cloud.agent.api.GetVncPortCommand; +import com.cloud.agent.api.MaintainCommand; +import com.cloud.agent.api.ManageSnapshotCommand; +import com.cloud.agent.api.MigrateCommand; +import com.cloud.agent.api.ModifyStoragePoolCommand; +import com.cloud.agent.api.NetworkUsageCommand; +import com.cloud.agent.api.PingTestCommand; +import com.cloud.agent.api.PrepareForMigrationCommand; +import com.cloud.agent.api.RebootCommand; +import com.cloud.agent.api.SecStorageSetupCommand; +import com.cloud.agent.api.SecStorageVMSetupCommand; +import com.cloud.agent.api.SecurityGroupRulesCmd; +import com.cloud.agent.api.StartCommand; +import com.cloud.agent.api.StopCommand; +import com.cloud.agent.api.StoragePoolInfo; import com.cloud.agent.api.check.CheckSshCommand; import com.cloud.agent.api.proxy.CheckConsoleProxyLoadCommand; import com.cloud.agent.api.proxy.WatchConsoleProxyLoadCommand; -import com.cloud.agent.api.routing.*; -import com.cloud.agent.api.storage.*; +import com.cloud.agent.api.routing.DhcpEntryCommand; +import com.cloud.agent.api.routing.IpAssocCommand; +import com.cloud.agent.api.routing.LoadBalancerConfigCommand; +import com.cloud.agent.api.routing.SavePasswordCommand; +import com.cloud.agent.api.routing.SetFirewallRulesCommand; +import com.cloud.agent.api.routing.SetPortForwardingRulesCommand; +import com.cloud.agent.api.routing.SetStaticNatRulesCommand; +import com.cloud.agent.api.routing.VmDataCommand; +import com.cloud.agent.api.storage.CopyVolumeCommand; +import com.cloud.agent.api.storage.CreateCommand; +import com.cloud.agent.api.storage.DeleteTemplateCommand; +import com.cloud.agent.api.storage.DestroyCommand; +import com.cloud.agent.api.storage.DownloadCommand; +import com.cloud.agent.api.storage.DownloadProgressCommand; +import com.cloud.agent.api.storage.ListTemplateCommand; +import com.cloud.agent.api.storage.ListVolumeCommand; +import com.cloud.agent.api.storage.PrimaryStorageDownloadCommand; import com.cloud.simulator.MockConfigurationVO; import com.cloud.simulator.MockHost; import com.cloud.simulator.MockVMVO; @@ -34,14 +96,6 @@ import com.cloud.utils.db.DB; import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; import com.cloud.vm.VirtualMachine.State; -import org.apache.log4j.Logger; -import org.springframework.stereotype.Component; - -import javax.ejb.Local; -import javax.inject.Inject; -import javax.naming.ConfigurationException; -import java.util.HashMap; -import java.util.Map; @Component @Local(value = { SimulatorManager.class }) @@ -256,7 +310,7 @@ public class SimulatorManagerImpl extends ManagerBase implements SimulatorManage return Answer.createUnsupportedCommandAnswer(cmd); } } catch(Exception e) { - s_logger.error("Failed execute cmd: " + e.toString()); + s_logger.error("Failed execute cmd: ", e); txn.rollback(); return new Answer(cmd, false, e.toString()); } finally { diff --git a/plugins/hypervisors/simulator/src/com/cloud/simulator/MockSecStorageVO.java b/plugins/hypervisors/simulator/src/com/cloud/simulator/MockSecStorageVO.java index 532d2a7ff56..87905eedbd1 100644 --- a/plugins/hypervisors/simulator/src/com/cloud/simulator/MockSecStorageVO.java +++ b/plugins/hypervisors/simulator/src/com/cloud/simulator/MockSecStorageVO.java @@ -48,6 +48,7 @@ public class MockSecStorageVO implements InternalIdentity { } + @Override public long getId() { return this.id; } @@ -57,7 +58,7 @@ public class MockSecStorageVO implements InternalIdentity { } public void setMountPoint(String mountPoint) { - this.mountPoint = mountPoint; + this.mountPoint = mountPoint.replace('\\', '/'); } public String getUrl() { diff --git a/plugins/hypervisors/simulator/src/com/cloud/simulator/MockStoragePoolVO.java b/plugins/hypervisors/simulator/src/com/cloud/simulator/MockStoragePoolVO.java index 06aa169a62a..7f1b7ccf610 100644 --- a/plugins/hypervisors/simulator/src/com/cloud/simulator/MockStoragePoolVO.java +++ b/plugins/hypervisors/simulator/src/com/cloud/simulator/MockStoragePoolVO.java @@ -66,6 +66,7 @@ public class MockStoragePoolVO implements InternalIdentity { this.hostGuid = hostGuid; } + @Override public long getId() { return this.id; } @@ -91,7 +92,7 @@ public class MockStoragePoolVO implements InternalIdentity { } public void setMountPoint(String mountPoint) { - this.mountPoint = mountPoint; + this.mountPoint = mountPoint.replace('\\', '/'); } public long getCapacity() { diff --git a/plugins/hypervisors/simulator/src/com/cloud/simulator/MockVolumeVO.java b/plugins/hypervisors/simulator/src/com/cloud/simulator/MockVolumeVO.java index 6dd59e8507c..b7191b887f6 100644 --- a/plugins/hypervisors/simulator/src/com/cloud/simulator/MockVolumeVO.java +++ b/plugins/hypervisors/simulator/src/com/cloud/simulator/MockVolumeVO.java @@ -66,6 +66,7 @@ public class MockVolumeVO implements InternalIdentity { @Enumerated(value=EnumType.STRING) private VMTemplateStorageResourceAssoc.Status status; + @Override public long getId() { return id; } @@ -90,7 +91,7 @@ public class MockVolumeVO implements InternalIdentity { } public void setPath(String path) { - this.path = path; + this.path = path.replace('\\', '/'); } public long getPoolId() { diff --git a/plugins/hypervisors/vmware/pom.xml b/plugins/hypervisors/vmware/pom.xml index d65ef640655..79779decf62 100644 --- a/plugins/hypervisors/vmware/pom.xml +++ b/plugins/hypervisors/vmware/pom.xml @@ -58,5 +58,15 @@ wsdl4j 1.4 + + junit + junit + 4.10 + + + org.mockito + mockito-all + 1.9.5 + diff --git a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/guru/VMwareGuru.java b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/guru/VMwareGuru.java index ee1b3245126..55bb1e98366 100644 --- a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/guru/VMwareGuru.java +++ b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/guru/VMwareGuru.java @@ -38,6 +38,8 @@ import com.cloud.agent.api.CreatePrivateTemplateFromVolumeCommand; import com.cloud.agent.api.CreateVolumeFromSnapshotCommand; import com.cloud.agent.api.UnregisterVMCommand; import com.cloud.agent.api.storage.CopyVolumeCommand; +import com.cloud.agent.api.storage.CreateVolumeOVACommand; +import com.cloud.agent.api.storage.PrepareOVAPackingCommand; import com.cloud.agent.api.storage.PrimaryStorageDownloadCommand; import com.cloud.agent.api.to.NicTO; import com.cloud.agent.api.to.VirtualMachineTO; @@ -282,10 +284,18 @@ public class VMwareGuru extends HypervisorGuruBase implements HypervisorGuru { cmd instanceof CreatePrivateTemplateFromVolumeCommand || cmd instanceof CreatePrivateTemplateFromSnapshotCommand || cmd instanceof CopyVolumeCommand || + cmd instanceof CreateVolumeOVACommand || + cmd instanceof PrepareOVAPackingCommand || cmd instanceof CreateVolumeFromSnapshotCommand) { needDelegation = true; } + /* Fang: remove this before checking in */ + // needDelegation = false; + if (cmd instanceof PrepareOVAPackingCommand || + cmd instanceof CreateVolumeOVACommand ) { + cmd.setContextParam("hypervisor", HypervisorType.VMware.toString()); + } if(needDelegation) { HostVO host = _hostDao.findById(hostId); assert(host != null); @@ -311,6 +321,8 @@ public class VMwareGuru extends HypervisorGuruBase implements HypervisorGuru { cmd instanceof CreatePrivateTemplateFromVolumeCommand || cmd instanceof CreatePrivateTemplateFromSnapshotCommand || cmd instanceof CopyVolumeCommand || + cmd instanceof CreateVolumeOVACommand || + cmd instanceof PrepareOVAPackingCommand || cmd instanceof CreateVolumeFromSnapshotCommand) { String workerName = _vmwareMgr.composeWorkerName(); diff --git a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java index eb09af0d67e..9f260f1812c 100755 --- a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java +++ b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java @@ -494,7 +494,8 @@ public class VmwareManagerImpl extends ManagerBase implements VmwareManager, Vmw s_logger.info("Inject SSH key pairs before copying systemvm.iso into secondary storage"); _configServer.updateKeyPairs(); - + s_logger.info("Copy System VM patch ISO file to secondary storage. source ISO: " + srcIso.getAbsolutePath() + + ", destination: " + destIso.getAbsolutePath()); try { FileUtil.copyfile(srcIso, destIso); } catch(IOException e) { diff --git a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareStorageManager.java b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareStorageManager.java index a2e517d1fdb..8c0603e29e7 100644 --- a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareStorageManager.java +++ b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareStorageManager.java @@ -25,6 +25,8 @@ import com.cloud.agent.api.CreateVolumeFromSnapshotCommand; import com.cloud.agent.api.DeleteVMSnapshotCommand; import com.cloud.agent.api.RevertToVMSnapshotCommand; import com.cloud.agent.api.storage.CopyVolumeCommand; +import com.cloud.agent.api.storage.PrepareOVAPackingCommand; +import com.cloud.agent.api.storage.CreateVolumeOVACommand; import com.cloud.agent.api.storage.PrimaryStorageDownloadCommand; public interface VmwareStorageManager { @@ -33,6 +35,8 @@ public interface VmwareStorageManager { Answer execute(VmwareHostService hostService, CreatePrivateTemplateFromVolumeCommand cmd); Answer execute(VmwareHostService hostService, CreatePrivateTemplateFromSnapshotCommand cmd); Answer execute(VmwareHostService hostService, CopyVolumeCommand cmd); + Answer execute(VmwareHostService hostService, CreateVolumeOVACommand cmd); + Answer execute(VmwareHostService hostService, PrepareOVAPackingCommand cmd); Answer execute(VmwareHostService hostService, CreateVolumeFromSnapshotCommand cmd); Answer execute(VmwareHostService hostService, CreateVMSnapshotCommand cmd); Answer execute(VmwareHostService hostService, DeleteVMSnapshotCommand cmd); diff --git a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareStorageManagerImpl.java b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareStorageManagerImpl.java index 1f116455761..9f1351e96f3 100644 --- a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareStorageManagerImpl.java +++ b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareStorageManagerImpl.java @@ -18,12 +18,14 @@ package com.cloud.hypervisor.vmware.manager; import java.io.BufferedWriter; import java.io.File; +import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.OutputStreamWriter; import java.rmi.RemoteException; import java.util.ArrayList; import java.util.HashMap; import java.util.List; +import java.util.Properties; import java.util.Map; import java.util.UUID; @@ -44,6 +46,10 @@ import com.cloud.agent.api.RevertToVMSnapshotAnswer; import com.cloud.agent.api.RevertToVMSnapshotCommand; import com.cloud.agent.api.storage.CopyVolumeAnswer; import com.cloud.agent.api.storage.CopyVolumeCommand; +import com.cloud.agent.api.storage.PrepareOVAPackingAnswer; +import com.cloud.agent.api.storage.PrepareOVAPackingCommand; +import com.cloud.agent.api.storage.CreateVolumeOVAAnswer; +import com.cloud.agent.api.storage.CreateVolumeOVACommand; import com.cloud.agent.api.storage.CreatePrivateTemplateAnswer; import com.cloud.agent.api.storage.PrimaryStorageDownloadAnswer; import com.cloud.agent.api.storage.PrimaryStorageDownloadCommand; @@ -102,6 +108,109 @@ public class VmwareStorageManagerImpl implements VmwareStorageManager { _timeout = NumbersUtil.parseInt(value, 1440) * 1000; } + //Fang note: use Answer here instead of the PrepareOVAPackingAnswer + @Override + public Answer execute(VmwareHostService hostService, PrepareOVAPackingCommand cmd) { + String secStorageUrl = ((PrepareOVAPackingCommand) cmd).getSecondaryStorageUrl(); + assert (secStorageUrl != null); + String installPath = cmd.getTemplatePath(); + String details = null; + boolean success = false; + String ovafileName = ""; + s_logger.info("Fang: execute OVAPacking cmd at vmwareMngImpl. "); + String secondaryMountPoint = _mountService.getMountPoint(secStorageUrl); + // String installPath = getTemplateRelativeDirInSecStorage(accountId, templateId); + String installFullPath = secondaryMountPoint + "/" + installPath; + + String templateName = installFullPath; // should be a file ending .ova; + s_logger.info("Fang: execute vmwareMgrImpl: templateNAme " + templateName); + // Fang: Dir list, if there is ova file, done; Fang: add answer cmd; + // if not, from ova.meta, create a new OVA file; + // change the install path to *.ova , not ova.meta; + // VmwareContext context = hostService.getServiceContext(cmd); //Fang: we may not have the CTX here + try { + if (templateName.endsWith(".ova")) { + if(new File(templateName).exists()) { + details = "OVA files exists. succeed. "; + return new Answer(cmd, true, details); + } else { + if (new File(templateName + ".meta").exists()) { //Fang parse the meta file + //execute the tar command; + s_logger.info("Fang: execute vmwareMgrImpl: getfromMeta " + templateName); + ovafileName = getOVAFromMetafile(templateName + ".meta"); + details = "OVA file in meta file is " + ovafileName; + return new Answer(cmd, true, details); + } else { + String msg = "Unable to find ova meta or ova file to prepare template (vmware)"; + s_logger.error(msg); + throw new Exception(msg); + } + } + } + } catch (Throwable e) { + if (e instanceof RemoteException) { + //hostService.invalidateServiceContext(context); do not need context + s_logger.error("Unable to connect to remote service "); + details = "Unable to connect to remote service "; + return new Answer(cmd, false, details); + } + String msg = "Unable to execute PrepareOVAPackingCommand due to exception"; + s_logger.error(msg, e); + return new Answer(cmd, false, details); + } + return new Answer(cmd, true, details); + } + + //Fang: new command added; + // Important! we need to sync file system before we can safely use tar to work around a linux kernal bug(or feature) + @Override + public Answer execute(VmwareHostService hostService, CreateVolumeOVACommand cmd) { + String secStorageUrl = ((CreateVolumeOVACommand) cmd).getSecondaryStorageUrl(); + assert (secStorageUrl != null); + String installPath = cmd.getVolPath(); + String details = null; + boolean success = false; + + s_logger.info("volss: execute CreateVolumeOVA cmd at vmwareMngImpl. "); + String secondaryMountPoint = _mountService.getMountPoint(secStorageUrl); + // String installPath = getTemplateRelativeDirInSecStorage(accountId, templateId); + s_logger.info("volss: mountPoint: " + secondaryMountPoint + "installPath:" + installPath); + String installFullPath = secondaryMountPoint + "/" + installPath; + + String volName = cmd.getVolName(); // should be a UUID, without ova ovf, etc; + s_logger.info("volss: execute vmwareMgrImpl: VolName " + volName); + // Fang: Dir list, if there is ova file, done; Note: add answer cmd; + + try { + if(new File(volName + ".ova").exists()) { + details = "OVA files exists. succeed. "; + return new CreateVolumeOVAAnswer(cmd, true, details); + } else { + File ovaFile = new File(installFullPath); + String exportDir = ovaFile.getParent(); + + s_logger.info("Fang: exportDir is (for VolumeOVA): " + exportDir); + s_logger.info("Sync file system before we package OVA..."); + + Script commandSync = new Script(true, "sync", 0, s_logger); + commandSync.execute(); + + Script command = new Script(false, "tar", 0, s_logger); + command.setWorkDir(exportDir); + command.add("-cf", volName + ".ova"); + command.add(volName + ".ovf"); // OVF file should be the first file in OVA archive + command.add(volName + "-disk0.vmdk"); + + s_logger.info("Package Volume OVA with commmand: " + command.toString()); + command.execute(); + return new CreateVolumeOVAAnswer(cmd, true, details); + } + } catch (Throwable e) { + s_logger.info("Exception for createVolumeOVA"); + } + return new CreateVolumeOVAAnswer(cmd, true, "fail to pack OVA for volume"); + } + @Override public Answer execute(VmwareHostService hostService, PrimaryStorageDownloadCommand cmd) { String secondaryStorageUrl = cmd.getSecondaryStorageUrl(); @@ -570,11 +679,14 @@ public class VmwareStorageManagerImpl implements VmwareStorageManager { String secondaryMountPoint = _mountService.getMountPoint(secStorageUrl); String installPath = getTemplateRelativeDirInSecStorage(accountId, templateId); String installFullPath = secondaryMountPoint + "/" + installPath; - String installFullName = installFullPath + "/" + templateUniqueName + ".ova"; - String snapshotFullName = secondaryMountPoint + "/" + getSnapshotRelativeDirInSecStorage(accountId, volumeId) - + "/" + backedUpSnapshotUuid + ".ova"; + String installFullOVAName = installFullPath + "/" + templateUniqueName + ".ova"; //Note: volss for tmpl + String snapshotRoot = secondaryMountPoint + "/" + getSnapshotRelativeDirInSecStorage(accountId, volumeId); + String snapshotFullOVAName = snapshotRoot + "/" + backedUpSnapshotUuid + ".ova"; + String snapshotFullOvfName = snapshotRoot + "/" + backedUpSnapshotUuid + ".ovf"; String result; Script command; + String templateVMDKName = ""; + String snapshotFullVMDKName = snapshotRoot + "/"; synchronized(installPath.intern()) { command = new Script(false, "mkdir", _timeout, s_logger); @@ -591,40 +703,85 @@ public class VmwareStorageManagerImpl implements VmwareStorageManager { } try { - command = new Script(false, "cp", _timeout, s_logger); - command.add(snapshotFullName); - command.add(installFullName); - result = command.execute(); - if(result != null) { - String msg = "unable to copy snapshot " + snapshotFullName + " to " + installFullPath; + if(new File(snapshotFullOVAName).exists()) { + command = new Script(false, "cp", _timeout, s_logger); + command.add(snapshotFullOVAName); + command.add(installFullOVAName); + result = command.execute(); + if(result != null) { + String msg = "unable to copy snapshot " + snapshotFullOVAName + " to " + installFullPath; + s_logger.error(msg); + throw new Exception(msg); + } + + // untar OVA file at template directory + command = new Script("tar", 0, s_logger); + command.add("--no-same-owner"); + command.add("-xf", installFullOVAName); + command.setWorkDir(installFullPath); + s_logger.info("Executing command: " + command.toString()); + result = command.execute(); + if(result != null) { + String msg = "unable to untar snapshot " + snapshotFullOVAName + " to " + + installFullPath; + s_logger.error(msg); + throw new Exception(msg); + } + + } else { // there is no ova file, only ovf originally; + if(new File(snapshotFullOvfName).exists()) { + command = new Script(false, "cp", _timeout, s_logger); + command.add(snapshotFullOvfName); + //command.add(installFullOvfName); + command.add(installFullPath); + result = command.execute(); + if(result != null) { + String msg = "unable to copy snapshot " + snapshotFullOvfName + " to " + installFullPath; + s_logger.error(msg); + throw new Exception(msg); + } + + File snapshotdir = new File(snapshotRoot); + File[] ssfiles = snapshotdir.listFiles(); + // List filenames = new ArrayList(); + for (int i = 0; i < ssfiles.length; i++) { + String vmdkfile = ssfiles[i].getName(); + if(vmdkfile.toLowerCase().startsWith(backedUpSnapshotUuid) && vmdkfile.toLowerCase().endsWith(".vmdk")) { + snapshotFullVMDKName += vmdkfile; + templateVMDKName += vmdkfile; + break; + } + } + if (snapshotFullVMDKName != null) { + command = new Script(false, "cp", _timeout, s_logger); + command.add(snapshotFullVMDKName); + command.add(installFullPath); + result = command.execute(); + s_logger.info("Copy VMDK file: " + snapshotFullVMDKName); + if(result != null) { + String msg = "unable to copy snapshot vmdk file " + snapshotFullVMDKName + " to " + installFullPath; + s_logger.error(msg); + throw new Exception(msg); + } + } + } else { + String msg = "unable to find any snapshot ova/ovf files" + snapshotFullOVAName + " to " + installFullPath; s_logger.error(msg); throw new Exception(msg); + } } - // untar OVA file at template directory - command = new Script("tar", 0, s_logger); - command.add("--no-same-owner"); - command.add("-xf", installFullName); - command.setWorkDir(installFullPath); - s_logger.info("Executing command: " + command.toString()); - result = command.execute(); - if(result != null) { - String msg = "unable to untar snapshot " + snapshotFullName + " to " - + installFullPath; - s_logger.error(msg); - throw new Exception(msg); - } - - long physicalSize = new File(installFullPath + "/" + templateUniqueName + ".ova").length(); + long physicalSize = new File(installFullPath + "/" + templateVMDKName).length(); VmdkProcessor processor = new VmdkProcessor(); + // long physicalSize = new File(installFullPath + "/" + templateUniqueName + ".ova").length(); Map params = new HashMap(); params.put(StorageLayer.InstanceConfigKey, _storage); processor.configure("VMDK Processor", params); long virtualSize = processor.getTemplateVirtualSize(installFullPath, templateUniqueName); postCreatePrivateTemplate(installFullPath, templateId, templateUniqueName, physicalSize, virtualSize); + writeMetaOvaForTemplate(installFullPath, backedUpSnapshotUuid + ".ovf", templateVMDKName, templateUniqueName, physicalSize); return new Ternary(installPath + "/" + templateUniqueName + ".ova", physicalSize, virtualSize); - } catch(Exception e) { // TODO, clean up left over files throw e; @@ -648,7 +805,8 @@ public class VmwareStorageManagerImpl implements VmwareStorageManager { out.newLine(); out.write("size=" + size); out.newLine(); - out.write("ova=true"); + //out.write("ova=true"); + out.write("ova=false"); //volss: the real ova file is not created out.newLine(); out.write("id=" + templateId); out.newLine(); @@ -670,6 +828,31 @@ public class VmwareStorageManagerImpl implements VmwareStorageManager { } } + private void writeMetaOvaForTemplate(String installFullPath, String ovfFilename, String vmdkFilename, + String templateName, long diskSize) throws Exception { + + // TODO a bit ugly here + BufferedWriter out = null; + try { + out = new BufferedWriter(new OutputStreamWriter(new FileOutputStream(installFullPath + "/" + templateName +".ova.meta"))); + out.write("ova.filename=" + templateName + ".ova"); + out.newLine(); + out.write("version=1.0"); + out.newLine(); + out.write("ovf=" + ovfFilename); + out.newLine(); + out.write("numDisks=1"); + out.newLine(); + out.write("disk1.name=" + vmdkFilename); + out.newLine(); + out.write("disk1.size=" + diskSize); + out.newLine(); + } finally { + if(out != null) + out.close(); + } + } + private String createVolumeFromSnapshot(VmwareHypervisorHost hyperHost, DatastoreMO primaryDsMo, String newVolumeName, long accountId, long volumeId, String secStorageUrl, String snapshotBackupUuid) throws Exception { @@ -688,23 +871,35 @@ public class VmwareStorageManagerImpl implements VmwareStorageManager { if (backupName.contains("/")){ snapshotDir = backupName.split("/")[0]; } - String srcFileName = getOVFFilePath(srcOVAFileName); - if(srcFileName == null) { - Script command = new Script("tar", 0, s_logger); - command.add("--no-same-owner"); - command.add("-xf", srcOVAFileName); - command.setWorkDir(secondaryMountPoint + "/" + secStorageDir + "/" + snapshotDir); - s_logger.info("Executing command: " + command.toString()); - String result = command.execute(); - if(result != null) { - String msg = "Unable to unpack snapshot OVA file at: " + srcOVAFileName; - s_logger.error(msg); - throw new Exception(msg); - } - } - srcFileName = getOVFFilePath(srcOVAFileName); - if(srcFileName == null) { + File ovafile = new File(srcOVAFileName); + String srcOVFFileName = secondaryMountPoint + "/" + secStorageDir + "/" + + backupName + ".ovf"; + File ovfFile = new File(srcOVFFileName); + // String srcFileName = getOVFFilePath(srcOVAFileName); + if (!ovfFile.exists()) { + srcOVFFileName = getOVFFilePath(srcOVAFileName); + if(srcOVFFileName == null && ovafile.exists() ) { // volss: ova file exists; o/w can't do tar + Script command = new Script("tar", 0, s_logger); + command.add("--no-same-owner"); + command.add("-xf", srcOVAFileName); + command.setWorkDir(secondaryMountPoint + "/" + secStorageDir + "/" + snapshotDir); + s_logger.info("Executing command: " + command.toString()); + String result = command.execute(); + if(result != null) { + String msg = "Unable to unpack snapshot OVA file at: " + srcOVAFileName; + s_logger.error(msg); + throw new Exception(msg); + } + } else { + String msg = "Unable to find snapshot OVA file at: " + srcOVAFileName; + s_logger.error(msg); + throw new Exception(msg); + } + + srcOVFFileName = getOVFFilePath(srcOVAFileName); + } + if(srcOVFFileName == null) { String msg = "Unable to locate OVF file in template package directory: " + srcOVAFileName; s_logger.error(msg); throw new Exception(msg); @@ -712,7 +907,7 @@ public class VmwareStorageManagerImpl implements VmwareStorageManager { VirtualMachineMO clonedVm = null; try { - hyperHost.importVmFromOVF(srcFileName, newVolumeName, primaryDsMo, "thin"); + hyperHost.importVmFromOVF(srcOVFFileName, newVolumeName, primaryDsMo, "thin"); clonedVm = hyperHost.findVmOnHyperHost(newVolumeName); if(clonedVm == null) throw new Exception("Unable to create container VM for volume creation"); @@ -774,7 +969,7 @@ public class VmwareStorageManagerImpl implements VmwareStorageManager { throw new Exception(msg); } - clonedVm.exportVm(exportPath, exportName, true, true); + clonedVm.exportVm(exportPath, exportName, false, false); //Note: volss: not to create ova. } finally { if(clonedVm != null) { clonedVm.detachAllDisks(); @@ -787,17 +982,31 @@ public class VmwareStorageManagerImpl implements VmwareStorageManager { String secondaryMountPoint = _mountService.getMountPoint(secStorageUrl); String snapshotMountRoot = secondaryMountPoint + "/" + getSnapshotRelativeDirInSecStorage(accountId, volumeId); - File file = new File(snapshotMountRoot + "/" + backupUuid + ".ova"); + File file = new File(snapshotMountRoot + "/" + backupUuid + ".ovf"); if(file.exists()) { - if(file.delete()) - return null; - - } else { - return "Backup file does not exist. backupUuid: " + backupUuid; - } - - return "Failed to delete snapshot backup file, backupUuid: " + backupUuid; - } + File snapshotdir = new File(snapshotMountRoot); + File[] ssfiles = snapshotdir.listFiles(); + // List filenames = new ArrayList(); + for (int i = 0; i < ssfiles.length; i++) { + String vmdkfile = ssfiles[i].getName(); + if(vmdkfile.toLowerCase().startsWith(backupUuid) && vmdkfile.toLowerCase().endsWith(".vmdk")) { + // filenames.add(vmdkfile); + new File(vmdkfile).delete(); + } + } + if(file.delete()) + return null; + } else { + File file1 = new File(snapshotMountRoot + "/" + backupUuid + ".ova"); + if(file1.exists()) { + if(file1.delete()) + return null; + } else { + return "Backup file does not exist. backupUuid: " + backupUuid; + } + } + return "Failed to delete snapshot backup file, backupUuid: " + backupUuid; + } private Pair copyVolumeToSecStorage(VmwareHostService hostService, VmwareHypervisorHost hyperHost, CopyVolumeCommand cmd, String vmName, long volumeId, String poolId, String volumePath, @@ -881,6 +1090,92 @@ public class VmwareStorageManagerImpl implements VmwareStorageManager { return new Pair(volumeFolder, newVolume); } + //Fang: here I use a method to return the ovf and vmdk file names; Another way to do it: + // create a new class, and like TemplateLocation.java and create templateOvfInfo.java to handle it; + private String getOVAFromMetafile(String metafileName) throws Exception { + File ova_metafile = new File(metafileName); + Properties props = null; + FileInputStream strm = null; + String ovaFileName = ""; + s_logger.info("Fang: getOVAfromMetaFile: metafileName " + metafileName); + try { + strm = new FileInputStream(ova_metafile); + if (null == strm) { + String msg = "Cannot read ova meat file. Error"; + s_logger.error(msg); + throw new Exception(msg); + } + + s_logger.info("Fang: getOVAfromMetaFile: load strm " ); + if (null != ova_metafile) { + props = new Properties(); + props.load(strm); + if (props == null) { + s_logger.info("Fang: getOVAfromMetaFile: props is null. " ); + } + } + if (null != props) { + ovaFileName = props.getProperty("ova.filename"); + s_logger.info("Fang: ovafilename" + ovaFileName); + String ovfFileName = props.getProperty("ovf"); + s_logger.info("Fang: ovffilename" + ovfFileName); + int diskNum = Integer.parseInt(props.getProperty("numDisks")); + if (diskNum <= 0) { + String msg = "VMDK disk file number is 0. Error"; + s_logger.error(msg); + throw new Exception(msg); + } + String[] disks = new String[diskNum]; + for (int i = 0; i < diskNum; i++) { + //String diskNameKey = "disk" + Integer.toString(i+1) + ".name"; // Fang use this + String diskNameKey = "disk1.name"; + disks[i] = props.getProperty(diskNameKey); + s_logger.info("Fang: diskname " + disks[i]); + } + String exportDir = ova_metafile.getParent(); + s_logger.info("Fang: exportDir: " + exportDir); + // Important! we need to sync file system before we can safely use tar to work around a linux kernal bug(or feature) + s_logger.info("Fang: Sync file system before we package OVA..., before tar "); + s_logger.info("Fang: ova: " + ovaFileName+ ", ovf:" + ovfFileName + ", vmdk:" + disks[0] + "."); + Script commandSync = new Script(true, "sync", 0, s_logger); + commandSync.execute(); + Script command = new Script(false, "tar", 0, s_logger); + command.setWorkDir(exportDir); //Fang: pass this in to the method? + command.add("-cf", ovaFileName); + command.add(ovfFileName); // OVF file should be the first file in OVA archive + for(String diskName: disks) { + command.add(diskName); + } + command.execute(); + s_logger.info("Fang: Package OVA for template in dir: " + exportDir + "cmd: " + command.toString()); + // to be safe, physically test existence of the target OVA file + if((new File(exportDir + ovaFileName)).exists()) { + s_logger.info("Fang: ova file is created and ready to extract "); + return (ovaFileName); + } else { + String msg = exportDir + File.separator + ovaFileName + ".ova is not created as expected"; + s_logger.error(msg); + throw new Exception(msg); + } + } else { + String msg = "Error reading the ova meta file: " + metafileName; + s_logger.error(msg); + throw new Exception(msg); + } + } catch (Exception e) { + return null; + //Do something, re-throw the exception + } finally { + if (strm != null) { + try { + strm.close(); + } catch (Exception e) { + } + } + } + + } + private String getOVFFilePath(String srcOVAFileName) { File file = new File(srcOVAFileName); assert(_storage != null); diff --git a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/resource/VmwareResource.java b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/resource/VmwareResource.java index 99ad1ca60b2..6d7e0e7289c 100755 --- a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/resource/VmwareResource.java +++ b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/resource/VmwareResource.java @@ -111,6 +111,8 @@ import com.cloud.agent.api.RebootCommand; import com.cloud.agent.api.RebootRouterCommand; import com.cloud.agent.api.RevertToVMSnapshotAnswer; import com.cloud.agent.api.RevertToVMSnapshotCommand; +import com.cloud.agent.api.ScaleVmCommand; +import com.cloud.agent.api.ScaleVmAnswer; import com.cloud.agent.api.SetupAnswer; import com.cloud.agent.api.SetupCommand; import com.cloud.agent.api.SetupGuestNetworkAnswer; @@ -155,6 +157,10 @@ import com.cloud.agent.api.routing.VmDataCommand; import com.cloud.agent.api.routing.VpnUsersCfgCommand; import com.cloud.agent.api.storage.CopyVolumeAnswer; import com.cloud.agent.api.storage.CopyVolumeCommand; +import com.cloud.agent.api.storage.CreateVolumeOVACommand; +import com.cloud.agent.api.storage.CreateVolumeOVAAnswer; +import com.cloud.agent.api.storage.PrepareOVAPackingAnswer; +import com.cloud.agent.api.storage.PrepareOVAPackingCommand; import com.cloud.agent.api.storage.CreateAnswer; import com.cloud.agent.api.storage.CreateCommand; import com.cloud.agent.api.storage.CreatePrivateTemplateAnswer; @@ -233,6 +239,7 @@ import com.vmware.vim25.ClusterDasConfigInfo; import com.vmware.vim25.ComputeResourceSummary; import com.vmware.vim25.DatastoreSummary; import com.vmware.vim25.DynamicProperty; +import com.vmware.vim25.GuestInfo; import com.vmware.vim25.HostCapability; import com.vmware.vim25.HostFirewallInfo; import com.vmware.vim25.HostFirewallRuleset; @@ -392,6 +399,10 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa answer = execute((DeleteStoragePoolCommand) cmd); } else if (clz == CopyVolumeCommand.class) { answer = execute((CopyVolumeCommand) cmd); + } else if (clz == CreateVolumeOVACommand.class) { + answer = execute((CreateVolumeOVACommand) cmd); + } else if (clz == PrepareOVAPackingCommand.class) { + answer = execute((PrepareOVAPackingCommand) cmd); } else if (clz == AttachVolumeCommand.class) { answer = execute((AttachVolumeCommand) cmd); } else if (clz == AttachIsoCommand.class) { @@ -476,6 +487,8 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa return execute((ResizeVolumeCommand) cmd); } else if (clz == UnregisterVMCommand.class) { return execute((UnregisterVMCommand) cmd); + } else if (clz == ScaleVmCommand.class) { + return execute((ScaleVmCommand) cmd); } else { answer = Answer.createUnsupportedCommandAnswer(cmd); } @@ -1318,6 +1331,12 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa throw new Exception(msg); } + if(!isVMWareToolsInstalled(vmMo)){ + String errMsg = "vmware tools is not installed or not running, cannot add nic to vm " + vmName; + s_logger.debug(errMsg); + return new PlugNicAnswer(cmd, false, "Unable to execute PlugNicCommand due to " + errMsg); + } + // TODO need a way to specify the control of NIC device type VirtualEthernetCardType nicDeviceType = VirtualEthernetCardType.E1000; @@ -1392,6 +1411,12 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa throw new Exception(msg); } + if(!isVMWareToolsInstalled(vmMo)){ + String errMsg = "vmware tools not installed or not running, cannot remove nic from vm " + vmName; + s_logger.debug(errMsg); + return new UnPlugNicAnswer(cmd, false, "Unable to execute unPlugNicCommand due to " + errMsg); + } + VirtualDevice nic = findVirtualNicDevice(vmMo, cmd.getNic().getMac()); if ( nic == null ) { return new UnPlugNicAnswer(cmd, true, "success"); @@ -1433,10 +1458,14 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa } String args = ""; + String snatArgs = ""; + if (ip.isAdd()) { args += " -A "; + snatArgs += " -A "; } else { args += " -D "; + snatArgs += " -D "; } args += " -l "; @@ -1460,6 +1489,21 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa if (!result.first()) { throw new InternalErrorException("Unable to assign public IP address"); } + + if (ip.isSourceNat()) { + snatArgs += " -l "; + snatArgs += ip.getPublicIp(); + snatArgs += " -c "; + snatArgs += "eth" + ethDeviceNum; + + Pair result_gateway = SshHelper.sshExecute(routerIp, DEFAULT_DOMR_SSHPORT, "root", mgr.getSystemVMKeyFile(), null, + "/opt/cloud/bin/vpc_privateGateway.sh " + args); + + if (!result_gateway.first()) { + throw new InternalErrorException("Unable to configure source NAT for public IP address."); + } + + } } protected void assignPublicIpAddress(VirtualMachineMO vmMo, final String vmName, final String privateIpAddress, final String publicIpAddress, final boolean add, final boolean firstIP, @@ -2048,6 +2092,28 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa return validatedDisks.toArray(new VolumeTO[0]); } + protected ScaleVmAnswer execute(ScaleVmCommand cmd) { + + VmwareContext context = getServiceContext(); + VirtualMachineTO vmSpec = cmd.getVirtualMachine(); + try{ + VmwareHypervisorHost hyperHost = getHyperHost(context); + VirtualMachineMO vmMo = hyperHost.findVmOnHyperHost(cmd.getVmName()); + VirtualMachineConfigSpec vmConfigSpec = new VirtualMachineConfigSpec(); + int ramMb = (int) (vmSpec.getMinRam()); + + VmwareHelper.setVmScaleUpConfig(vmConfigSpec, vmSpec.getCpus(), vmSpec.getSpeed(), vmSpec.getSpeed(),(int) (vmSpec.getMaxRam()), ramMb, vmSpec.getLimitCpuUse()); + + if(!vmMo.configureVm(vmConfigSpec)) { + throw new Exception("Unable to execute ScaleVmCommand"); + } + }catch(Exception e) { + s_logger.error("Unexpected exception: ", e); + return new ScaleVmAnswer(cmd, false, "Unable to execute ScaleVmCommand due to " + e.toString()); + } + return new ScaleVmAnswer(cmd, true, null); + } + protected StartAnswer execute(StartCommand cmd) { if (s_logger.isInfoEnabled()) { @@ -2151,7 +2217,10 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa VmwareHelper.setBasicVmConfig(vmConfigSpec, vmSpec.getCpus(), vmSpec.getMaxSpeed(), vmSpec.getMinSpeed(),(int) (vmSpec.getMaxRam()/(1024*1024)), ramMb, translateGuestOsIdentifier(vmSpec.getArch(), vmSpec.getOs()).value(), vmSpec.getLimitCpuUse()); - + + vmConfigSpec.setMemoryHotAddEnabled(true); + vmConfigSpec.setCpuHotAddEnabled(true); + if ("true".equals(vmSpec.getDetails().get(VmDetailConstants.NESTED_VIRTUALIZATION_FLAG))) { s_logger.debug("Nested Virtualization enabled in configuration, checking hypervisor capability"); ManagedObjectReference hostMor = vmMo.getRunningHost().getMor(); @@ -3905,8 +3974,48 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa } } + public CreateVolumeOVAAnswer execute(CreateVolumeOVACommand cmd) { + if (s_logger.isInfoEnabled()) { + s_logger.info("Executing resource CreateVolumeOVACommand: " + _gson.toJson(cmd)); + } + try { + VmwareContext context = getServiceContext(); + VmwareManager mgr = context.getStockObject(VmwareManager.CONTEXT_STOCK_NAME); + return (CreateVolumeOVAAnswer) mgr.getStorageManager().execute(this, cmd); + } catch (Throwable e) { + if (e instanceof RemoteException) { + s_logger.warn("Encounter remote exception to vCenter, invalidate VMware session context"); + invalidateServiceContext(); + } + String msg = "CreateVolumeOVACommand failed due to " + VmwareHelper.getExceptionMessage(e); + s_logger.error(msg, e); + return new CreateVolumeOVAAnswer(cmd, false, msg); + } + } + + protected Answer execute(PrepareOVAPackingCommand cmd) { + if (s_logger.isInfoEnabled()) { + s_logger.info("Executing resource PrepareOVAPackingCommand: " + _gson.toJson(cmd)); + } + + try { + VmwareContext context = getServiceContext(); + VmwareManager mgr = context.getStockObject(VmwareManager.CONTEXT_STOCK_NAME); + + return mgr.getStorageManager().execute(this, cmd); + } catch (Throwable e) { + if (e instanceof RemoteException) { + s_logger.warn("Encounter remote exception to vCenter, invalidate VMware session context"); + invalidateServiceContext(); + } + + String details = "PrepareOVAPacking for template failed due to " + VmwareHelper.getExceptionMessage(e); + s_logger.error(details, e); + return new PrepareOVAPackingAnswer(cmd, false, details); + } + } private boolean createVMFullClone(VirtualMachineMO vmTemplate, DatacenterMO dcMo, DatastoreMO dsMo, String vmdkName, ManagedObjectReference morDatastore, ManagedObjectReference morPool) throws Exception { @@ -5170,4 +5279,9 @@ public class VmwareResource implements StoragePoolResource, ServerResource, Vmwa // TODO Auto-generated method stub } + + private boolean isVMWareToolsInstalled(VirtualMachineMO vmMo) throws Exception{ + GuestInfo guestInfo = vmMo.getVmGuestInfo(); + return (guestInfo != null && guestInfo.getGuestState() != null && guestInfo.getGuestState().equalsIgnoreCase("running")); + } } diff --git a/plugins/hypervisors/vmware/src/com/cloud/storage/resource/VmwareSecondaryStorageResourceHandler.java b/plugins/hypervisors/vmware/src/com/cloud/storage/resource/VmwareSecondaryStorageResourceHandler.java index ce42f67bf1d..95ba317fa2c 100644 --- a/plugins/hypervisors/vmware/src/com/cloud/storage/resource/VmwareSecondaryStorageResourceHandler.java +++ b/plugins/hypervisors/vmware/src/com/cloud/storage/resource/VmwareSecondaryStorageResourceHandler.java @@ -28,6 +28,9 @@ import com.cloud.agent.api.CreatePrivateTemplateFromSnapshotCommand; import com.cloud.agent.api.CreatePrivateTemplateFromVolumeCommand; import com.cloud.agent.api.CreateVolumeFromSnapshotCommand; import com.cloud.agent.api.storage.CopyVolumeCommand; +import com.cloud.agent.api.storage.CreateVolumeOVAAnswer; +import com.cloud.agent.api.storage.CreateVolumeOVACommand; +import com.cloud.agent.api.storage.PrepareOVAPackingCommand; import com.cloud.agent.api.storage.PrimaryStorageDownloadCommand; import com.cloud.hypervisor.vmware.manager.VmwareHostService; import com.cloud.hypervisor.vmware.manager.VmwareStorageManager; @@ -76,6 +79,10 @@ public class VmwareSecondaryStorageResourceHandler implements SecondaryStorageRe answer = execute((CreatePrivateTemplateFromSnapshotCommand)cmd); } else if(cmd instanceof CopyVolumeCommand) { answer = execute((CopyVolumeCommand)cmd); + } else if(cmd instanceof CreateVolumeOVACommand) { + answer = execute((CreateVolumeOVACommand)cmd); + } else if (cmd instanceof PrepareOVAPackingCommand) { + answer = execute((PrepareOVAPackingCommand)cmd); } else if(cmd instanceof CreateVolumeFromSnapshotCommand) { answer = execute((CreateVolumeFromSnapshotCommand)cmd); } else { @@ -138,6 +145,23 @@ public class VmwareSecondaryStorageResourceHandler implements SecondaryStorageRe return _storageMgr.execute(this, cmd); } + private Answer execute(PrepareOVAPackingCommand cmd) { + s_logger.info("Fang: VmwareSecStorageResourceHandler: exec cmd. cmd is " + cmd.toString()); + if (s_logger.isDebugEnabled()) { + s_logger.debug("Executing resource PrepareOVAPackingCommand: " + _gson.toJson(cmd)); + } + + return _storageMgr.execute(this, cmd); + } + + private CreateVolumeOVAAnswer execute(CreateVolumeOVACommand cmd) { + if (s_logger.isDebugEnabled()) { + s_logger.debug("Executing resource CreateVolumeOVACommand: " + _gson.toJson(cmd)); + } + + return (CreateVolumeOVAAnswer) _storageMgr.execute(this, cmd); + } + private Answer execute(CreateVolumeFromSnapshotCommand cmd) { if (s_logger.isDebugEnabled()) { s_logger.debug("Executing resource CreateVolumeFromSnapshotCommand: " + _gson.toJson(cmd)); diff --git a/plugins/hypervisors/vmware/test/com/cloud/hypervisor/vmware/resource/VmwareResourceTest.java b/plugins/hypervisors/vmware/test/com/cloud/hypervisor/vmware/resource/VmwareResourceTest.java new file mode 100644 index 00000000000..3ca0b600e36 --- /dev/null +++ b/plugins/hypervisors/vmware/test/com/cloud/hypervisor/vmware/resource/VmwareResourceTest.java @@ -0,0 +1,82 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.hypervisor.vmware.resource; + +import com.cloud.agent.api.Command; +import com.cloud.agent.api.ScaleVmAnswer; +import com.cloud.agent.api.ScaleVmCommand; +import com.cloud.agent.api.to.VirtualMachineTO; +import com.cloud.hypervisor.vmware.mo.VirtualMachineMO; +import com.cloud.hypervisor.vmware.mo.VmwareHypervisorHost; +import com.cloud.hypervisor.vmware.util.VmwareContext; +import com.cloud.hypervisor.vmware.util.VmwareHelper; +import com.vmware.vim25.VirtualMachineConfigSpec; +import org.junit.Test; +import org.junit.Before; + +import org.mockito.Mock; +import org.mockito.Spy; +import org.mockito.MockitoAnnotations; +import static org.mockito.Mockito.*; + + +public class VmwareResourceTest { + + @Spy VmwareResource _resource = new VmwareResource() { + + @Override + public ScaleVmAnswer execute(ScaleVmCommand cmd) { + return super.execute(cmd); + } + @Override + public VmwareHypervisorHost getHyperHost(VmwareContext context, Command cmd) { + return hyperHost; + } + }; + + @Mock VmwareContext context; + @Mock ScaleVmCommand cmd; + @Mock VirtualMachineTO vmSpec; + @Mock + VmwareHypervisorHost hyperHost; + @Mock VirtualMachineMO vmMo; + @Mock VirtualMachineConfigSpec vmConfigSpec; + + @Before + public void setup(){ + MockitoAnnotations.initMocks(this); + doReturn(context).when(_resource).getServiceContext(null); + when(cmd.getVirtualMachine()).thenReturn(vmSpec); + } + //Test successful scaling up the vm + @Test + public void testScaleVMF1() throws Exception { + when(_resource.getHyperHost(context, null)).thenReturn(hyperHost); + doReturn("i-2-3-VM").when(cmd).getVmName(); + when(hyperHost.findVmOnHyperHost("i-2-3-VM")).thenReturn(vmMo); + doReturn(1024L).when(vmSpec).getMinRam(); + doReturn(1).when(vmSpec).getCpus(); + doReturn(1000).when(vmSpec).getSpeed(); + doReturn(1024L).when(vmSpec).getMaxRam(); + doReturn(false).when(vmSpec).getLimitCpuUse(); + when(vmMo.configureVm(vmConfigSpec)).thenReturn(true); + + ScaleVmAnswer answer = _resource.execute(cmd); + verify(_resource).execute(cmd); + } + +} diff --git a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/discoverer/XcpServerDiscoverer.java b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/discoverer/XcpServerDiscoverer.java index 89bc1cf5708..562a7feb96f 100755 --- a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/discoverer/XcpServerDiscoverer.java +++ b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/discoverer/XcpServerDiscoverer.java @@ -427,8 +427,11 @@ public class XcpServerDiscoverer extends DiscovererBase implements Discoverer, L prodVersion = prodVersion.trim(); } - if(prodBrand.equals("XCP") && (prodVersion.equals("1.0.0") || prodVersion.equals("1.1.0") || prodVersion.equals("5.6.100") || prodVersion.startsWith("1.4") || prodVersion.startsWith("1.6"))) - return new XcpServerResource(); + if(prodBrand.equals("XCP") && (prodVersion.equals("1.0.0") || prodVersion.equals("1.1.0") || prodVersion.equals("5.6.100") || prodVersion.startsWith("1.4"))) { + return new XcpServerResource("1.1"); + } else if (prodBrand.equals("XCP") && prodVersion.startsWith("1.6")) { + return new XcpServerResource("1.6"); + } if(prodBrand.equals("XenServer") && prodVersion.equals("5.6.0")) return new XenServer56Resource(); diff --git a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixHelper.java b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixHelper.java index 828a8279f9a..34b8f2981e2 100644 --- a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixHelper.java +++ b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixHelper.java @@ -28,6 +28,7 @@ import org.apache.log4j.Logger; public class CitrixHelper { private static final Logger s_logger = Logger.getLogger(CitrixHelper.class); private static final HashMap _xcp100GuestOsMap = new HashMap(70); + private static final HashMap _xcp160GuestOsMap = new HashMap(70); private static final HashMap _xenServerGuestOsMap = new HashMap(70); private static final HashMap _xenServer56FP1GuestOsMap = new HashMap(70); private static final HashMap _xenServer56FP2GuestOsMap = new HashMap(70); @@ -114,6 +115,83 @@ public class CitrixHelper { _xcp100GuestOsMap.put("Other PV (64-bit)", "CentOS 5 (64-bit)"); } + static { + _xcp160GuestOsMap.put("CentOS 4.5 (32-bit)", "CentOS 4.5 (32-bit)"); + _xcp160GuestOsMap.put("CentOS 4.6 (32-bit)", "CentOS 4.6 (32-bit)"); + _xcp160GuestOsMap.put("CentOS 4.7 (32-bit)", "CentOS 4.7 (32-bit)"); + _xcp160GuestOsMap.put("CentOS 4.8 (32-bit)", "CentOS 4.8 (32-bit)"); + _xcp160GuestOsMap.put("CentOS 5.0 (32-bit)", "CentOS 5 (32-bit)"); + _xcp160GuestOsMap.put("CentOS 5.0 (64-bit)", "CentOS 5 (64-bit)"); + _xcp160GuestOsMap.put("CentOS 5.1 (32-bit)", "CentOS 5 (32-bit)"); + _xcp160GuestOsMap.put("CentOS 5.1 (64-bit)", "CentOS 5 (64-bit)"); + _xcp160GuestOsMap.put("CentOS 5.2 (32-bit)", "CentOS 5 (32-bit)"); + _xcp160GuestOsMap.put("CentOS 5.2 (64-bit)", "CentOS 5 (64-bit)"); + _xcp160GuestOsMap.put("CentOS 5.3 (32-bit)", "CentOS 5 (32-bit)"); + _xcp160GuestOsMap.put("CentOS 5.3 (64-bit)", "CentOS 5 (64-bit)"); + _xcp160GuestOsMap.put("CentOS 5.4 (32-bit)", "CentOS 5 (32-bit)"); + _xcp160GuestOsMap.put("CentOS 5.4 (64-bit)", "CentOS 5 (64-bit)"); + _xcp160GuestOsMap.put("CentOS 5.5 (32-bit)", "CentOS 5 (32-bit)"); + _xcp160GuestOsMap.put("CentOS 5.5 (64-bit)", "CentOS 5 (64-bit)"); + _xcp160GuestOsMap.put("Debian GNU/Linux 5.0 (32-bit)", "Debian Lenny 5.0 (32-bit)"); + _xcp160GuestOsMap.put("Debian GNU/Linux 6(32-bit)", "Debian Squeeze 6.0 (32-bit)"); + _xcp160GuestOsMap.put("Debian GNU/Linux 6(64-bit)", "Debian Squeeze 6.0 (64-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.0 (32-bit)", "Oracle Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.0 (64-bit)", "Oracle Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.1 (32-bit)", "Oracle Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.1 (64-bit)", "Oracle Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.2 (32-bit)", "Oracle Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.2 (64-bit)", "Oracle Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.3 (32-bit)", "Oracle Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.3 (64-bit)", "Oracle Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.4 (32-bit)", "Oracle Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.4 (64-bit)", "Oracle Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.5 (32-bit)", "Oracle Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Oracle Enterprise Linux 5.5 (64-bit)", "Oracle Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 4.5 (32-bit)", "Red Hat Enterprise Linux 4.5 (32-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 4.6 (32-bit)", "Red Hat Enterprise Linux 4.6 (32-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 4.7 (32-bit)", "Red Hat Enterprise Linux 4.7 (32-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 4.8 (32-bit)", "Red Hat Enterprise Linux 4.8 (32-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.0 (32-bit)", "Red Hat Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.0 (64-bit)", "Red Hat Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.1 (32-bit)", "Red Hat Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.1 (64-bit)", "Red Hat Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.2 (32-bit)", "Red Hat Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.2 (64-bit)", "Red Hat Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.3 (32-bit)", "Red Hat Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.3 (64-bit)", "Red Hat Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.4 (32-bit)", "Red Hat Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.4 (64-bit)", "Red Hat Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.5 (32-bit)", "Red Hat Enterprise Linux 5 (32-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 5.5 (64-bit)", "Red Hat Enterprise Linux 5 (64-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 6.0 (32-bit)", "Red Hat Enterprise Linux 6 (32-bit)"); + _xcp160GuestOsMap.put("Red Hat Enterprise Linux 6.0 (64-bit)", "Red Hat Enterprise Linux 6 (64-bit)"); + _xcp160GuestOsMap.put("SUSE Linux Enterprise Server 9 SP4 (32-bit)", "SUSE Linux Enterprise Server 9 SP4"); + _xcp160GuestOsMap.put("SUSE Linux Enterprise Server 10 SP1 (32-bit)", "SUSE Linux Enterprise Server 10 SP1"); + _xcp160GuestOsMap.put("SUSE Linux Enterprise Server 10 SP1 (64-bit)", "SUSE Linux Enterprise Server 10 SP1 x64"); + _xcp160GuestOsMap.put("SUSE Linux Enterprise Server 10 SP2 (32-bit)", "SUSE Linux Enterprise Server 10 SP2"); + _xcp160GuestOsMap.put("SUSE Linux Enterprise Server 10 SP2 (64-bit)", "SUSE Linux Enterprise Server 10 SP2 x64"); + _xcp160GuestOsMap.put("SUSE Linux Enterprise Server 10 SP3 (64-bit)", "Other install media"); + _xcp160GuestOsMap.put("SUSE Linux Enterprise Server 11 (32-bit)", "SUSE Linux Enterprise Server 11"); + _xcp160GuestOsMap.put("SUSE Linux Enterprise Server 11 (64-bit)", "SUSE Linux Enterprise Server 11 x64"); + _xcp160GuestOsMap.put("SUSE Linux Enterprise Server 11 SP1 (32-bit)", "SUSE Linux Enterprise Server 11 SP1 (32-bit)"); + _xcp160GuestOsMap.put("SUSE Linux Enterprise Server 11 SP1 (64-bit)", "SUSE Linux Enterprise Server 11 SP1 (64-bit)"); + _xcp160GuestOsMap.put("Windows 7 (32-bit)", "Windows 7 (32-bit)"); + _xcp160GuestOsMap.put("Windows 7 (64-bit)", "Windows 7 (64-bit)"); + _xcp160GuestOsMap.put("Windows Server 2003 (32-bit)", "Windows Server 2003 (32-bit)"); + _xcp160GuestOsMap.put("Windows Server 2003 (64-bit)", "Windows Server 2003 (64-bit)"); + _xcp160GuestOsMap.put("Windows Server 2008 (32-bit)", "Windows Server 2008 (32-bit)"); + _xcp160GuestOsMap.put("Windows Server 2008 (64-bit)", "Windows Server 2008 (64-bit)"); + _xcp160GuestOsMap.put("Windows Server 2008 R2 (64-bit)", "Windows Server 2008 R2 (64-bit)"); + _xcp160GuestOsMap.put("Windows XP SP3 (32-bit)", "Windows XP SP3 (32-bit)"); + _xcp160GuestOsMap.put("Windows Vista (32-bit)", "Windows Vista (32-bit)"); + _xcp160GuestOsMap.put("Ubuntu 10.04 (32-bit)", "Ubuntu Lucid Lynx 10.04 (32-bit) (experimental)"); + _xcp160GuestOsMap.put("Ubuntu 10.04 (64-bit)", "Ubuntu Lucid Lynx 10.04 (64-bit) (experimental)"); + _xcp160GuestOsMap.put("Other Linux (32-bit)", "Other install media"); + _xcp160GuestOsMap.put("Other Linux (64-bit)", "Other install media"); + _xcp160GuestOsMap.put("Other PV (32-bit)", "CentOS 5 (32-bit)"); + _xcp160GuestOsMap.put("Other PV (64-bit)", "CentOS 5 (64-bit)"); + } + static { _xenServerGuestOsMap.put("CentOS 4.5 (32-bit)", "CentOS 4.5 (32-bit)"); @@ -648,7 +726,7 @@ public class CitrixHelper { _xenServer610GuestOsMap.put("Windows 7 (32-bit)", "Windows 7 (32-bit)"); _xenServer610GuestOsMap.put("Windows 7 (64-bit)", "Windows 7 (64-bit)"); _xenServer610GuestOsMap.put("Windows 8 (32-bit)", "Windows 8 (32-bit) (experimental)"); - _xenServer610GuestOsMap.put("Windows 8 (64-bit)", "Windows 7 (64-bit) (experimental)"); + _xenServer610GuestOsMap.put("Windows 8 (64-bit)", "Windows 8 (64-bit) (experimental)"); _xenServer610GuestOsMap.put("Windows Server 2003 (32-bit)", "Windows Server 2003 (32-bit)"); _xenServer610GuestOsMap.put("Windows Server 2003 (64-bit)", "Windows Server 2003 (64-bit)"); _xenServer610GuestOsMap.put("Windows Server 2003 PAE (32-bit)", "Windows Server 2003 PAE (32-bit)"); @@ -661,6 +739,7 @@ public class CitrixHelper { _xenServer610GuestOsMap.put("Windows Server 2008 (32-bit)", "Windows Server 2008 (32-bit)"); _xenServer610GuestOsMap.put("Windows Server 2008 (64-bit)", "Windows Server 2008 (64-bit)"); _xenServer610GuestOsMap.put("Windows Server 2008 R2 (64-bit)", "Windows Server 2008 R2 (64-bit)"); + _xenServer610GuestOsMap.put("Windows Server 2012 (64-bit)", "Windows Server 2012 (64-bit) (experimental)"); _xenServer610GuestOsMap.put("Windows Server 8 (64-bit)", "Windows Server 2012 (64-bit) (experimental)"); _xenServer610GuestOsMap.put("Windows Vista (32-bit)", "Windows Vista (32-bit)"); _xenServer610GuestOsMap.put("Windows XP SP3 (32-bit)", "Windows XP SP3 (32-bit)"); @@ -693,6 +772,15 @@ public class CitrixHelper { return guestOS; } + public static String getXcp160GuestOsType(String stdType) { + String guestOS = _xcp160GuestOsMap.get(stdType); + if (guestOS == null) { + s_logger.debug("Can't find the guest os: " + stdType + " mapping into XCP's guestOS type, start it as HVM guest"); + guestOS = "Other install media"; + } + return guestOS; + } + public static String getXenServerGuestOsType(String stdType, boolean bootFromCD) { String guestOS = _xenServerGuestOsMap.get(stdType); diff --git a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java index 46ae35a4a54..bac361d9133 100644 --- a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java +++ b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/CitrixResourceBase.java @@ -2217,11 +2217,14 @@ public abstract class CitrixResourceBase implements ServerResource, HypervisorRe } String args = "vpc_ipassoc.sh " + routerIp; + String snatArgs = "vpc_privateGateway.sh " + routerIp; if (ip.isAdd()) { args += " -A "; + snatArgs += " -A "; } else { args += " -D "; + snatArgs+= " -D "; } args += " -l "; @@ -2244,6 +2247,17 @@ public abstract class CitrixResourceBase implements ServerResource, HypervisorRe if (result == null || result.isEmpty()) { throw new InternalErrorException("Xen plugin \"vpc_ipassoc\" failed."); } + + if (ip.isSourceNat()) { + snatArgs += " -l " + ip.getPublicIp(); + snatArgs += " -c " + "eth" + correctVif.getDevice(conn); + + result = callHostPlugin(conn, "vmops", "routerProxy", "args", snatArgs); + if (result == null || result.isEmpty()) { + throw new InternalErrorException("Xen plugin \"vcp_privateGateway\" failed."); + } + } + } catch (Exception e) { String msg = "Unable to assign public IP address due to " + e.toString(); s_logger.warn(msg, e); diff --git a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpServerResource.java b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpServerResource.java index 7a958708e76..6baf6a09e3f 100644 --- a/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpServerResource.java +++ b/plugins/hypervisors/xen/src/com/cloud/hypervisor/xen/resource/XcpServerResource.java @@ -39,9 +39,10 @@ import com.xensource.xenapi.Types.XenAPIException; @Local(value=ServerResource.class) public class XcpServerResource extends CitrixResourceBase { private final static Logger s_logger = Logger.getLogger(XcpServerResource.class); - - public XcpServerResource() { + private String version; + public XcpServerResource(String version) { super(); + this.version = version; } @Override @@ -55,7 +56,11 @@ public class XcpServerResource extends CitrixResourceBase { @Override protected String getGuestOsType(String stdType, boolean bootFromCD) { - return CitrixHelper.getXcpGuestOsType(stdType); + if (version.equalsIgnoreCase("1.6")) { + return CitrixHelper.getXcp160GuestOsType(stdType); + } else { + return CitrixHelper.getXcpGuestOsType(stdType); + } } @Override diff --git a/plugins/network-elements/bigswitch-vns/src/com/cloud/network/element/BigSwitchVnsElement.java b/plugins/network-elements/bigswitch-vns/src/com/cloud/network/element/BigSwitchVnsElement.java index 4ee9c93ffcc..411feab7339 100644 --- a/plugins/network-elements/bigswitch-vns/src/com/cloud/network/element/BigSwitchVnsElement.java +++ b/plugins/network-elements/bigswitch-vns/src/com/cloud/network/element/BigSwitchVnsElement.java @@ -138,7 +138,7 @@ public class BigSwitchVnsElement extends AdapterBase implements if (network.getBroadcastDomainType() != BroadcastDomainType.Lswitch) { return false; } -/* + if (!_networkModel.isProviderForNetwork(getProvider(), network.getId())) { s_logger.debug("BigSwitchVnsElement is not a provider for network " @@ -153,7 +153,7 @@ public class BigSwitchVnsElement extends AdapterBase implements + network.getDisplayText()); return false; } -*/ + return true; } diff --git a/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-egress-acl-rule.xml b/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-egress-acl-rule.xml index 930272ed8ee..05c066d6d53 100755 --- a/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-egress-acl-rule.xml +++ b/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-egress-acl-rule.xml @@ -118,70 +118,38 @@ under the License. - - - - - - - - - - - - - - + + value="%deststartport%"/> - + + value="%destendport%"/> @@ -195,7 +163,6 @@ under the License. protocolvalue = "TCP" or "UDP" deststartip="destination start ip" destendip="destination end ip" - sourcestartport="start port at source" - sourceendport="end port at source" - sourceip="source ip" + deststartport="start port at destination" + destendport="end port at destination" --!> diff --git a/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-generic-egress-acl-no-protocol-rule.xml b/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-generic-egress-acl-no-protocol-rule.xml new file mode 100755 index 00000000000..17cfa54a34e --- /dev/null +++ b/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-generic-egress-acl-no-protocol-rule.xml @@ -0,0 +1,94 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-generic-egress-acl-rule.xml b/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-generic-egress-acl-rule.xml index 92c25043dad..436e3eae790 100755 --- a/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-generic-egress-acl-rule.xml +++ b/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-generic-egress-acl-rule.xml @@ -118,5 +118,4 @@ under the License. protocolvalue = "TCP" or "UDP" or "ICMP" deststartip="destination start ip" destendip="destination end ip" - sourceip="source ip" --!> diff --git a/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-ingress-acl-rule.xml b/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-ingress-acl-rule.xml index 1af30b44416..f283ffeb333 100755 --- a/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-ingress-acl-rule.xml +++ b/plugins/network-elements/cisco-vnmc/scripts/network/cisco/create-ingress-acl-rule.xml @@ -118,7 +118,7 @@ under the License. @@ -127,56 +127,24 @@ under the License. dn="%aclruledn%/rule-cond-4/nw-expr2/nw-attr-qual" status="created"/> - - - - - - - - - - - - - - + - + diff --git a/plugins/network-elements/cisco-vnmc/src/com/cloud/api/commands/ListCiscoAsa1000vResourcesCmd.java b/plugins/network-elements/cisco-vnmc/src/com/cloud/api/commands/ListCiscoAsa1000vResourcesCmd.java index 509d39fb5f9..88ea2709325 100755 --- a/plugins/network-elements/cisco-vnmc/src/com/cloud/api/commands/ListCiscoAsa1000vResourcesCmd.java +++ b/plugins/network-elements/cisco-vnmc/src/com/cloud/api/commands/ListCiscoAsa1000vResourcesCmd.java @@ -89,6 +89,7 @@ public class ListCiscoAsa1000vResourcesCmd extends BaseListCmd { if (ciscoAsa1000vDevices != null && !ciscoAsa1000vDevices.isEmpty()) { for (CiscoAsa1000vDevice ciscoAsa1000vDeviceVO : ciscoAsa1000vDevices) { CiscoAsa1000vResourceResponse ciscoAsa1000vResourceResponse = _ciscoAsa1000vService.createCiscoAsa1000vResourceResponse(ciscoAsa1000vDeviceVO); + ciscoAsa1000vResourceResponse.setObjectName("CiscoAsa1000vResource"); ciscoAsa1000vResourcesResponse.add(ciscoAsa1000vResourceResponse); } } diff --git a/plugins/network-elements/cisco-vnmc/src/com/cloud/api/commands/ListCiscoVnmcResourcesCmd.java b/plugins/network-elements/cisco-vnmc/src/com/cloud/api/commands/ListCiscoVnmcResourcesCmd.java index ab553ee94ac..73128ecec2b 100644 --- a/plugins/network-elements/cisco-vnmc/src/com/cloud/api/commands/ListCiscoVnmcResourcesCmd.java +++ b/plugins/network-elements/cisco-vnmc/src/com/cloud/api/commands/ListCiscoVnmcResourcesCmd.java @@ -77,18 +77,19 @@ public class ListCiscoVnmcResourcesCmd extends BaseListCmd { @Override public void execute() throws ResourceUnavailableException, InsufficientCapacityException, ServerApiException, ConcurrentOperationException, ResourceAllocationException { try { - List CiscoVnmcResources = _ciscoVnmcElementService.listCiscoVnmcResources(this); + List ciscoVnmcResources = _ciscoVnmcElementService.listCiscoVnmcResources(this); ListResponse response = new ListResponse(); - List CiscoVnmcResourcesResponse = new ArrayList(); + List ciscoVnmcResourcesResponse = new ArrayList(); - if (CiscoVnmcResources != null && !CiscoVnmcResources.isEmpty()) { - for (CiscoVnmcController CiscoVnmcResourceVO : CiscoVnmcResources) { - CiscoVnmcResourceResponse CiscoVnmcResourceResponse = _ciscoVnmcElementService.createCiscoVnmcResourceResponse(CiscoVnmcResourceVO); - CiscoVnmcResourcesResponse.add(CiscoVnmcResourceResponse); + if (ciscoVnmcResources != null && !ciscoVnmcResources.isEmpty()) { + for (CiscoVnmcController ciscoVnmcResourceVO : ciscoVnmcResources) { + CiscoVnmcResourceResponse ciscoVnmcResourceResponse = _ciscoVnmcElementService.createCiscoVnmcResourceResponse(ciscoVnmcResourceVO); + ciscoVnmcResourceResponse.setObjectName("CiscoVnmcResource"); + ciscoVnmcResourcesResponse.add(ciscoVnmcResourceResponse); } } - response.setResponses(CiscoVnmcResourcesResponse); + response.setResponses(ciscoVnmcResourcesResponse); response.setResponseName(getCommandName()); this.setResponseObject(response); } catch (InvalidParameterValueException invalidParamExcp) { diff --git a/plugins/network-elements/cisco-vnmc/src/com/cloud/api/response/CiscoAsa1000vResourceResponse.java b/plugins/network-elements/cisco-vnmc/src/com/cloud/api/response/CiscoAsa1000vResourceResponse.java index 9cd87da66a1..f857b352b4a 100755 --- a/plugins/network-elements/cisco-vnmc/src/com/cloud/api/response/CiscoAsa1000vResourceResponse.java +++ b/plugins/network-elements/cisco-vnmc/src/com/cloud/api/response/CiscoAsa1000vResourceResponse.java @@ -29,60 +29,69 @@ import com.google.gson.annotations.SerializedName; @EntityReference(value = CiscoAsa1000vDevice.class) public class CiscoAsa1000vResourceResponse extends BaseResponse { - public static final String RESOURCE_NAME = "resourcename"; - @SerializedName(ApiConstants.RESOURCE_ID) @Parameter(description="resource id of the Cisco ASA 1000v appliance") + @SerializedName(ApiConstants.RESOURCE_ID) + @Parameter(description="resource id of the Cisco ASA 1000v appliance") private String id; @SerializedName(ApiConstants.PHYSICAL_NETWORK_ID) @Parameter(description="the physical network to which this ASA 1000v belongs to", entityType = PhysicalNetworkResponse.class) - private Long physicalNetworkId ; - - public Long getPhysicalNetworkId() { - return physicalNetworkId; - } + private Long physicalNetworkId; @SerializedName(ApiConstants.HOST_NAME) @Parameter(description="management ip address of ASA 1000v") private String managementIp; - public String getManagementIp() { - return managementIp; - } - @SerializedName(ApiConstants.ASA_INSIDE_PORT_PROFILE) - @Parameter(description="management ip address of ASA 1000v") + @Parameter(description="port profile associated with inside interface of ASA 1000v") private String inPortProfile; - public String getInPortProfile() { - return inPortProfile; - } - @SerializedName(ApiConstants.NETWORK_ID) @Parameter(description="the guest network to which ASA 1000v is associated", entityType = NetworkResponse.class) private Long guestNetworkId; - public Long getGuestNetworkId() { - return guestNetworkId; + public String getId() { + return id; } public void setId(String ciscoAsa1000vResourceId) { this.id = ciscoAsa1000vResourceId; } + public Long getPhysicalNetworkId() { + return physicalNetworkId; + } + public void setPhysicalNetworkId(Long physicalNetworkId) { this.physicalNetworkId = physicalNetworkId; } + public String getManagementIp() { + return managementIp; + } + public void setManagementIp(String managementIp) { this.managementIp = managementIp; } + public String getInPortProfile() { + return inPortProfile; + } + public void setInPortProfile(String inPortProfile) { this.inPortProfile = inPortProfile; } + public Long getGuestNetworkId() { + return guestNetworkId; + } + public void setGuestNetworkId(Long guestNetworkId) { this.guestNetworkId = guestNetworkId; } + + @Override + public String getObjectId() { + return this.getId(); + } } diff --git a/plugins/network-elements/cisco-vnmc/src/com/cloud/api/response/CiscoVnmcResourceResponse.java b/plugins/network-elements/cisco-vnmc/src/com/cloud/api/response/CiscoVnmcResourceResponse.java index f5c9b727f8f..92a766d1bbf 100644 --- a/plugins/network-elements/cisco-vnmc/src/com/cloud/api/response/CiscoVnmcResourceResponse.java +++ b/plugins/network-elements/cisco-vnmc/src/com/cloud/api/response/CiscoVnmcResourceResponse.java @@ -25,6 +25,7 @@ import org.apache.cloudstack.api.response.PhysicalNetworkResponse; import com.cloud.network.cisco.CiscoVnmcController; import com.google.gson.annotations.SerializedName; + @EntityReference(value = CiscoVnmcController.class) public class CiscoVnmcResourceResponse extends BaseResponse { public static final String RESOURCE_NAME = "resourcename"; @@ -33,43 +34,52 @@ public class CiscoVnmcResourceResponse extends BaseResponse { @Parameter(description="resource id of the Cisco VNMC controller") private String id; - @SerializedName(ApiConstants.PHYSICAL_NETWORK_ID) + @SerializedName(ApiConstants.PHYSICAL_NETWORK_ID) @Parameter(description="the physical network to which this VNMC belongs to", entityType = PhysicalNetworkResponse.class) private Long physicalNetworkId; - public Long getPhysicalNetworkId() { - return physicalNetworkId; - } - - public String getProviderName() { - return providerName; - } - - public String getResourceName() { - return resourceName; - } - - @SerializedName(ApiConstants.PROVIDER) @Parameter(description="name of the provider") + @SerializedName(ApiConstants.PROVIDER) + @Parameter(description="name of the provider") private String providerName; - @SerializedName(RESOURCE_NAME) + @SerializedName(RESOURCE_NAME) @Parameter(description="Cisco VNMC resource name") private String resourceName; + public String getId() { + return id; + } + public void setId(String ciscoVnmcResourceId) { this.id = ciscoVnmcResourceId; } + public Long getPhysicalNetworkId() { + return physicalNetworkId; + } + public void setPhysicalNetworkId(Long physicalNetworkId) { this.physicalNetworkId = physicalNetworkId; } + public String getProviderName() { + return providerName; + } + public void setProviderName(String providerName) { this.providerName = providerName; } + public String getResourceName() { + return resourceName; + } + public void setResourceName(String resourceName) { this.resourceName = resourceName; - } + } + @Override + public String getObjectId() { + return this.getId(); + } } diff --git a/plugins/network-elements/cisco-vnmc/src/com/cloud/network/cisco/CiscoVnmcConnection.java b/plugins/network-elements/cisco-vnmc/src/com/cloud/network/cisco/CiscoVnmcConnection.java index f137148ab48..fed6724418d 100644 --- a/plugins/network-elements/cisco-vnmc/src/com/cloud/network/cisco/CiscoVnmcConnection.java +++ b/plugins/network-elements/cisco-vnmc/src/com/cloud/network/cisco/CiscoVnmcConnection.java @@ -140,23 +140,23 @@ public interface CiscoVnmcConnection { public boolean createTenantVDCIngressAclRule(String tenantName, String identifier, String policyIdentifier, String protocol, String sourceStartIp, String sourceEndIp, - String destStartPort, String destEndPort, String destIp) + String destStartPort, String destEndPort) throws ExecutionException; public boolean createTenantVDCIngressAclRule(String tenantName, String identifier, String policyIdentifier, - String protocol, String sourceStartIp, String sourceEndIp, String destIp) + String protocol, String sourceStartIp, String sourceEndIp) throws ExecutionException; public boolean createTenantVDCEgressAclRule(String tenantName, String identifier, String policyIdentifier, - String protocol, String sourceStartPort, String sourceEndPort, String sourceIp, - String destStartIp, String destEndIp) + String protocol, String destStartIp, String destEndIp, + String destStartPort, String destEndPort) throws ExecutionException; public boolean createTenantVDCEgressAclRule(String tenantName, String identifier, String policyIdentifier, - String protocol, String sourceIp, String destStartIp, String destEndIp) + String protocol, String destStartIp, String destEndIp) throws ExecutionException; public boolean deleteTenantVDCAclRule(String tenantName, diff --git a/plugins/network-elements/cisco-vnmc/src/com/cloud/network/cisco/CiscoVnmcConnectionImpl.java b/plugins/network-elements/cisco-vnmc/src/com/cloud/network/cisco/CiscoVnmcConnectionImpl.java index 527fb04698e..c7380ab11d8 100644 --- a/plugins/network-elements/cisco-vnmc/src/com/cloud/network/cisco/CiscoVnmcConnectionImpl.java +++ b/plugins/network-elements/cisco-vnmc/src/com/cloud/network/cisco/CiscoVnmcConnectionImpl.java @@ -95,6 +95,7 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { CREATE_EGRESS_ACL_RULE("create-egress-acl-rule.xml", "policy-mgr"), CREATE_GENERIC_INGRESS_ACL_RULE("create-generic-ingress-acl-rule.xml", "policy-mgr"), CREATE_GENERIC_EGRESS_ACL_RULE("create-generic-egress-acl-rule.xml", "policy-mgr"), + CREATE_GENERIC_EGRESS_ACL_NO_PROTOCOL_RULE("create-generic-egress-acl-no-protocol-rule.xml", "policy-mgr"), DELETE_RULE("delete-rule.xml", "policy-mgr"), @@ -279,7 +280,7 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { String xml = VnmcXml.CREATE_VDC.getXml(); String service = VnmcXml.CREATE_VDC.getService(); xml = replaceXmlValue(xml, "cookie", _cookie); - xml = replaceXmlValue(xml, "descr", "VDC for Tenant" + tenantName); + xml = replaceXmlValue(xml, "descr", "VDC for Tenant " + tenantName); xml = replaceXmlValue(xml, "name", getNameForTenantVDC(tenantName)); xml = replaceXmlValue(xml, "dn", getDnForTenantVDC(tenantName)); @@ -304,7 +305,7 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { String xml = VnmcXml.CREATE_EDGE_DEVICE_PROFILE.getXml(); String service = VnmcXml.CREATE_EDGE_DEVICE_PROFILE.getService(); xml = replaceXmlValue(xml, "cookie", _cookie); - xml = replaceXmlValue(xml, "descr", "Edge Device Profile for Tenant VDC" + tenantName); + xml = replaceXmlValue(xml, "descr", "Edge Device Profile for Tenant VDC " + tenantName); xml = replaceXmlValue(xml, "name", getNameForEdgeDeviceServiceProfile(tenantName)); xml = replaceXmlValue(xml, "dn", getDnForTenantVDCEdgeDeviceProfile(tenantName)); @@ -407,7 +408,7 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { String xml = VnmcXml.CREATE_EDGE_SECURITY_PROFILE.getXml(); String service = VnmcXml.CREATE_EDGE_SECURITY_PROFILE.getService(); xml = replaceXmlValue(xml, "cookie", _cookie); - xml = replaceXmlValue(xml, "descr", "Edge Security Profile for Tenant VDC" + tenantName); + xml = replaceXmlValue(xml, "descr", "Edge Security Profile for Tenant VDC " + tenantName); xml = replaceXmlValue(xml, "name", getNameForEdgeDeviceSecurityProfile(tenantName)); xml = replaceXmlValue(xml, "espdn", getDnForTenantVDCEdgeSecurityProfile(tenantName)); xml = replaceXmlValue(xml, "egressref", "default-egress"); @@ -505,7 +506,8 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { return createTenantVDCNatPolicyRef( getDnForSourceNatPolicyRef(tenantName), getNameForSourceNatPolicy(tenantName), - tenantName); + tenantName, + true); } @Override @@ -545,7 +547,7 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { String xml = VnmcXml.RESOLVE_NAT_POLICY_SET.getXml(); String service = VnmcXml.RESOLVE_NAT_POLICY_SET.getService(); xml = replaceXmlValue(xml, "cookie", _cookie); - xml = replaceXmlValue(xml, "descr", "Edge Security Profile for Tenant VDC" + tenantName); + xml = replaceXmlValue(xml, "descr", "Edge Security Profile for Tenant VDC " + tenantName); xml = replaceXmlValue(xml, "name", getNameForEdgeDeviceSecurityProfile(tenantName)); xml = replaceXmlValue(xml, "espdn", getDnForTenantVDCEdgeSecurityProfile(tenantName)); xml = replaceXmlValue(xml, "natpolicysetname", getNameForNatPolicySet(tenantName)); @@ -656,11 +658,10 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { String xml = VnmcXml.RESOLVE_ACL_POLICY_SET.getXml(); String service = VnmcXml.RESOLVE_ACL_POLICY_SET.getService(); xml = replaceXmlValue(xml, "cookie", _cookie); - xml = replaceXmlValue(xml, "descr", "Edge Security Profile for Tenant VDC" + tenantName); + xml = replaceXmlValue(xml, "descr", "Edge Security Profile for Tenant VDC " + tenantName); xml = replaceXmlValue(xml, "name", getNameForEdgeDeviceSecurityProfile(tenantName)); xml = replaceXmlValue(xml, "espdn", getDnForTenantVDCEdgeSecurityProfile(tenantName)); - //xml = replaceXmlValue(xml, "egresspolicysetname", getNameForAclPolicySet(tenantName, false)); - xml = replaceXmlValue(xml, "egresspolicysetname", "default-egress"); + xml = replaceXmlValue(xml, "egresspolicysetname", getNameForAclPolicySet(tenantName, false)); xml = replaceXmlValue(xml, "ingresspolicysetname", getNameForAclPolicySet(tenantName, true)); xml = replaceXmlValue(xml, "natpolicysetname", getNameForNatPolicySet(tenantName)); @@ -672,7 +673,7 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { public boolean createTenantVDCIngressAclRule(String tenantName, String identifier, String policyIdentifier, String protocol, String sourceStartIp, String sourceEndIp, - String destStartPort, String destEndPort, String destIp) throws ExecutionException { + String destStartPort, String destEndPort) throws ExecutionException { String xml = VnmcXml.CREATE_INGRESS_ACL_RULE.getXml(); String service = VnmcXml.CREATE_INGRESS_ACL_RULE.getService(); @@ -686,7 +687,6 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { xml = replaceXmlValue(xml, "sourceendip", sourceEndIp); xml = replaceXmlValue(xml, "deststartport", destStartPort); xml = replaceXmlValue(xml, "destendport", destEndPort); - xml = replaceXmlValue(xml, "destip", destIp); List rules = listChildren(getDnForAclPolicy(tenantName, policyIdentifier)); int order = 100; @@ -702,8 +702,7 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { @Override public boolean createTenantVDCIngressAclRule(String tenantName, String identifier, String policyIdentifier, - String protocol, String sourceStartIp, String sourceEndIp, - String destIp) throws ExecutionException { + String protocol, String sourceStartIp, String sourceEndIp) throws ExecutionException { String xml = VnmcXml.CREATE_GENERIC_INGRESS_ACL_RULE.getXml(); String service = VnmcXml.CREATE_GENERIC_INGRESS_ACL_RULE.getService(); @@ -730,8 +729,8 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { @Override public boolean createTenantVDCEgressAclRule(String tenantName, String identifier, String policyIdentifier, - String protocol, String sourceStartPort, String sourceEndPort, String sourceIp, - String destStartIp, String destEndIp) throws ExecutionException { + String protocol, String destStartIp, String destEndIp, + String destStartPort, String destEndPort) throws ExecutionException { String xml = VnmcXml.CREATE_EGRESS_ACL_RULE.getXml(); String service = VnmcXml.CREATE_EGRESS_ACL_RULE.getService(); @@ -743,9 +742,8 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { xml = replaceXmlValue(xml, "protocolvalue", protocol); xml = replaceXmlValue(xml, "deststartip", destStartIp); xml = replaceXmlValue(xml, "destendip", destEndIp); - xml = replaceXmlValue(xml, "sourcestartport", sourceStartPort); - xml = replaceXmlValue(xml, "sourceendport", sourceEndPort); - xml = replaceXmlValue(xml, "sourceip", sourceIp); + xml = replaceXmlValue(xml, "deststartport", destStartPort); + xml = replaceXmlValue(xml, "destendport", destEndPort); List rules = listChildren(getDnForAclPolicy(tenantName, policyIdentifier)); int order = 100; @@ -761,17 +759,20 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { @Override public boolean createTenantVDCEgressAclRule(String tenantName, String identifier, String policyIdentifier, - String protocol, String sourceIp, - String destStartIp, String destEndIp) throws ExecutionException { + String protocol, String destStartIp, String destEndIp) throws ExecutionException { String xml = VnmcXml.CREATE_GENERIC_EGRESS_ACL_RULE.getXml(); String service = VnmcXml.CREATE_GENERIC_EGRESS_ACL_RULE.getService(); - + if (protocol.equalsIgnoreCase("all")) { // any protocol + xml = VnmcXml.CREATE_GENERIC_EGRESS_ACL_NO_PROTOCOL_RULE.getXml(); + service = VnmcXml.CREATE_GENERIC_EGRESS_ACL_NO_PROTOCOL_RULE.getService(); + } else { // specific protocol + xml = replaceXmlValue(xml, "protocolvalue", protocol); + } xml = replaceXmlValue(xml, "cookie", _cookie); xml = replaceXmlValue(xml, "aclruledn", getDnForAclRule(tenantName, identifier, policyIdentifier)); xml = replaceXmlValue(xml, "aclrulename", getNameForAclRule(tenantName, identifier)); xml = replaceXmlValue(xml, "descr", "Egress ACL rule for Tenant VDC " + tenantName); xml = replaceXmlValue(xml, "actiontype", "permit"); - xml = replaceXmlValue(xml, "protocolvalue", protocol); xml = replaceXmlValue(xml, "deststartip", destStartIp); xml = replaceXmlValue(xml, "destendip", destEndIp); @@ -838,17 +839,23 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { return verifySuccess(response); } - private boolean createTenantVDCNatPolicyRef(String policyRefDn, String name, String tenantName) throws ExecutionException { + private boolean createTenantVDCNatPolicyRef(String policyRefDn, String name, String tenantName, boolean isSourceNat) throws ExecutionException { String xml = VnmcXml.CREATE_NAT_POLICY_REF.getXml(); String service = VnmcXml.CREATE_NAT_POLICY_REF.getService(); xml = replaceXmlValue(xml, "cookie", _cookie); xml = replaceXmlValue(xml, "natpolicyrefdn", policyRefDn); xml = replaceXmlValue(xml, "natpolicyname", name); - List policies = listNatPolicies(tenantName); - int order = 100; - if (policies != null) { - order += policies.size(); + // PF and static NAT policies need to come before source NAT, so leaving buffer + // and creating source NAT with a high order value. + // Initially tried setting MAX_INT as the order but VNMC complains about it + int order = 10000; // TODO: For now value should be sufficient, if required may need to increase + if (!isSourceNat) { + List policies = listNatPolicies(tenantName); + order = 100; // order starts at 100 + if (policies != null) { + order += policies.size(); + } } xml = replaceXmlValue(xml, "order", Integer.toString(order)); @@ -1062,7 +1069,8 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { return createTenantVDCNatPolicyRef( getDnForPFPolicyRef(tenantName, identifier), getNameForPFPolicy(tenantName, identifier), - tenantName); + tenantName, + false); } @Override @@ -1180,7 +1188,8 @@ public class CiscoVnmcConnectionImpl implements CiscoVnmcConnection { return createTenantVDCNatPolicyRef( getDnForDNatPolicyRef(tenantName, identifier), getNameForDNatPolicy(tenantName, identifier), - tenantName); + tenantName, + false); } @Override diff --git a/plugins/network-elements/cisco-vnmc/src/com/cloud/network/element/CiscoVnmcElement.java b/plugins/network-elements/cisco-vnmc/src/com/cloud/network/element/CiscoVnmcElement.java index 443bb40f57f..b335edb9f63 100644 --- a/plugins/network-elements/cisco-vnmc/src/com/cloud/network/element/CiscoVnmcElement.java +++ b/plugins/network-elements/cisco-vnmc/src/com/cloud/network/element/CiscoVnmcElement.java @@ -70,6 +70,7 @@ import com.cloud.deploy.DeployDestination; import com.cloud.exception.ConcurrentOperationException; import com.cloud.exception.InsufficientCapacityException; import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.ResourceAllocationException; import com.cloud.exception.ResourceUnavailableException; import com.cloud.host.DetailVO; import com.cloud.host.Host; @@ -104,6 +105,7 @@ import com.cloud.network.dao.PhysicalNetworkServiceProviderDao; import com.cloud.network.dao.PhysicalNetworkServiceProviderVO; import com.cloud.network.resource.CiscoVnmcResource; import com.cloud.network.rules.FirewallRule; +import com.cloud.network.rules.FirewallRule.TrafficType; import com.cloud.network.rules.PortForwardingRule; import com.cloud.network.rules.StaticNat; import com.cloud.offering.NetworkOffering; @@ -113,6 +115,7 @@ import com.cloud.resource.ResourceStateAdapter; import com.cloud.resource.ServerResource; import com.cloud.resource.UnableDeleteHostException; import com.cloud.user.Account; +import com.cloud.user.UserContext; import com.cloud.utils.component.AdapterBase; import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; @@ -338,10 +341,31 @@ public class CiscoVnmcElement extends AdapterBase implements SourceNatServicePro publicGateways.add(vlanVO.getVlanGateway()); } + // due to VNMC limitation of not allowing source NAT ip as the outside ip of firewall, + // an additional public ip needs to acquired for assigning as firewall outside ip + IpAddress outsideIp = null; + try { + Account caller = UserContext.current().getCaller(); + long callerUserId = UserContext.current().getCallerUserId(); + outsideIp = _networkMgr.allocateIp(owner, false, caller, callerUserId, zone); + } catch (ResourceAllocationException e) { + s_logger.error("Unable to allocate additional public Ip address. Exception details " + e); + return false; + } + + try { + outsideIp = _networkMgr.associateIPToGuestNetwork(outsideIp.getId(), network.getId(), true); + } catch (ResourceAllocationException e) { + s_logger.error("Unable to assign allocated additional public Ip " + outsideIp.getAddress().addr() + " to network with vlan " + vlanId + ". Exception details " + e); + return false; + } + // create logical edge firewall in VNMC String gatewayNetmask = NetUtils.getCidrNetmask(network.getCidr()); + // due to ASA limitation of allowing single subnet to be assigned to firewall interfaces, + // all public ip addresses must be from same subnet, this essentially means single public subnet in zone if (!createLogicalEdgeFirewall(vlanId, network.getGateway(), gatewayNetmask, - sourceNatIp.getAddress().addr(), sourceNatIp.getNetmask(), publicGateways, ciscoVnmcHost.getId())) { + outsideIp.getAddress().addr(), sourceNatIp.getNetmask(), publicGateways, ciscoVnmcHost.getId())) { s_logger.error("Failed to create logical edge firewall in Cisco VNMC device for network " + network.getName()); return false; } @@ -356,10 +380,10 @@ public class CiscoVnmcElement extends AdapterBase implements SourceNatServicePro } // configure source NAT - //if (!configureSourceNat(vlanId, network.getCidr(), sourceNatIp, ciscoVnmcHost.getId())) { - // s_logger.error("Failed to configure source NAT in Cisco VNMC device for network " + network.getName()); - // return false; - //} + if (!configureSourceNat(vlanId, network.getCidr(), sourceNatIp, ciscoVnmcHost.getId())) { + s_logger.error("Failed to configure source NAT in Cisco VNMC device for network " + network.getName()); + return false; + } // associate Asa 1000v instance with logical edge firewall if (!associateAsaWithLogicalEdgeFirewall(vlanId, assignedAsa.getManagementIp(), ciscoVnmcHost.getId())) { @@ -434,16 +458,14 @@ public class CiscoVnmcElement extends AdapterBase implements SourceNatServicePro @Override public boolean isReady(PhysicalNetworkServiceProvider provider) { - // TODO Auto-generated method stub - return false; + return true; } @Override public boolean shutdownProviderInstances( PhysicalNetworkServiceProvider provider, ReservationContext context) throws ConcurrentOperationException, ResourceUnavailableException { - // TODO Auto-generated method stub - return false; + return true; } @Override @@ -656,8 +678,12 @@ public class CiscoVnmcElement extends AdapterBase implements SourceNatServicePro List rulesTO = new ArrayList(); for (FirewallRule rule : rules) { - IpAddress sourceIp = _networkModel.getIp(rule.getSourceIpAddressId()); - FirewallRuleTO ruleTO = new FirewallRuleTO(rule, null, sourceIp.getAddress().addr(), rule.getPurpose(), rule.getTrafficType()); + String address = "0.0.0.0"; + if (rule.getTrafficType() == TrafficType.Ingress) { + IpAddress sourceIp = _networkModel.getIp(rule.getSourceIpAddressId()); + address = sourceIp.getAddress().addr(); + } + FirewallRuleTO ruleTO = new FirewallRuleTO(rule, null, address, rule.getPurpose(), rule.getTrafficType()); rulesTO.add(ruleTO); } diff --git a/plugins/network-elements/cisco-vnmc/src/com/cloud/network/resource/CiscoVnmcResource.java b/plugins/network-elements/cisco-vnmc/src/com/cloud/network/resource/CiscoVnmcResource.java index 91559782304..906e0ae6e85 100644 --- a/plugins/network-elements/cisco-vnmc/src/com/cloud/network/resource/CiscoVnmcResource.java +++ b/plugins/network-elements/cisco-vnmc/src/com/cloud/network/resource/CiscoVnmcResource.java @@ -368,29 +368,29 @@ public class CiscoVnmcResource implements ServerResource { if (!_connection.createTenantVDCIngressAclRule(tenant, Long.toString(rule.getId()), policyIdentifier, rule.getProtocol().toUpperCase(), externalIpRange[0], externalIpRange[1], - Integer.toString(rule.getSrcPortRange()[0]), Integer.toString(rule.getSrcPortRange()[1]), publicIp)) { + Integer.toString(rule.getSrcPortRange()[0]), Integer.toString(rule.getSrcPortRange()[1]))) { throw new Exception("Failed to create ACL ingress rule in VNMC for guest network with vlan " + vlanId); } } else { if (!_connection.createTenantVDCIngressAclRule(tenant, Long.toString(rule.getId()), policyIdentifier, - rule.getProtocol().toUpperCase(), externalIpRange[0], externalIpRange[1], publicIp)) { + rule.getProtocol().toUpperCase(), externalIpRange[0], externalIpRange[1])) { throw new Exception("Failed to create ACL ingress rule in VNMC for guest network with vlan " + vlanId); } } } else { - if (!rule.getProtocol().equalsIgnoreCase("icmp")) { + if (rule.getProtocol().equalsIgnoreCase("tcp") || rule.getProtocol().equalsIgnoreCase("udp")) { if (!_connection.createTenantVDCEgressAclRule(tenant, Long.toString(rule.getId()), policyIdentifier, rule.getProtocol().toUpperCase(), - Integer.toString(rule.getSrcPortRange()[0]), Integer.toString(rule.getSrcPortRange()[1]), publicIp, - externalIpRange[0], externalIpRange[1])) { + externalIpRange[0], externalIpRange[1], + Integer.toString(rule.getSrcPortRange()[0]), Integer.toString(rule.getSrcPortRange()[1]))) { throw new Exception("Failed to create ACL egress rule in VNMC for guest network with vlan " + vlanId); } } else { if (!_connection.createTenantVDCEgressAclRule(tenant, Long.toString(rule.getId()), policyIdentifier, - rule.getProtocol().toUpperCase(), publicIp, externalIpRange[0], externalIpRange[1])) { + rule.getProtocol().toUpperCase(), externalIpRange[0], externalIpRange[1])) { throw new Exception("Failed to create ACL egress rule in VNMC for guest network with vlan " + vlanId); } } diff --git a/plugins/network-elements/cisco-vnmc/test/com/cloud/network/resource/CiscoVnmcResourceTest.java b/plugins/network-elements/cisco-vnmc/test/com/cloud/network/resource/CiscoVnmcResourceTest.java index e814fdcd4d5..acfc5ebaaa7 100755 --- a/plugins/network-elements/cisco-vnmc/test/com/cloud/network/resource/CiscoVnmcResourceTest.java +++ b/plugins/network-elements/cisco-vnmc/test/com/cloud/network/resource/CiscoVnmcResourceTest.java @@ -171,11 +171,11 @@ public class CiscoVnmcResourceTest { when(_connection.createTenantVDCIngressAclRule( anyString(), anyString(), anyString(), anyString(), anyString(), anyString(), - anyString(), anyString(), anyString())).thenReturn(true); + anyString(), anyString())).thenReturn(true); when(_connection.createTenantVDCEgressAclRule( anyString(), anyString(), anyString(), anyString(), anyString(), anyString(), - anyString(), anyString(), anyString())).thenReturn(true); + anyString(), anyString())).thenReturn(true); when(_connection.associateAclPolicySet(anyString())).thenReturn(true); Answer answer = _resource.executeRequest(cmd); diff --git a/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/element/ElasticLoadBalancerElement.java b/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/element/ElasticLoadBalancerElement.java index bebba3cb09d..8b1b4140a8d 100644 --- a/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/element/ElasticLoadBalancerElement.java +++ b/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/element/ElasticLoadBalancerElement.java @@ -35,6 +35,7 @@ import com.cloud.deploy.DeployDestination; import com.cloud.exception.ConcurrentOperationException; import com.cloud.exception.InsufficientCapacityException; import com.cloud.exception.ResourceUnavailableException; +import com.cloud.exception.UnsupportedServiceException; import com.cloud.network.Network; import com.cloud.network.Network.Capability; import com.cloud.network.Network.Provider; @@ -46,6 +47,7 @@ import com.cloud.network.PublicIpAddress; import com.cloud.network.dao.NetworkDao; import com.cloud.network.lb.ElasticLoadBalancerManager; import com.cloud.network.lb.LoadBalancingRule; +import com.cloud.network.rules.LoadBalancerContainer; import com.cloud.offering.NetworkOffering; import com.cloud.offerings.dao.NetworkOfferingDao; import com.cloud.utils.component.AdapterBase; @@ -68,12 +70,25 @@ public class ElasticLoadBalancerElement extends AdapterBase implements LoadBalan boolean _enabled; TrafficType _frontEndTrafficType = TrafficType.Guest; - private boolean canHandle(Network network) { + private boolean canHandle(Network network, List rules) { if (network.getGuestType() != Network.GuestType.Shared|| network.getTrafficType() != TrafficType.Guest) { s_logger.debug("Not handling network with type " + network.getGuestType() + " and traffic type " + network.getTrafficType()); return false; } + Map lbCaps = this.getCapabilities().get(Service.Lb); + if (!lbCaps.isEmpty()) { + String schemeCaps = lbCaps.get(Capability.LbSchemes); + if (schemeCaps != null) { + for (LoadBalancingRule rule : rules) { + if (!schemeCaps.contains(rule.getScheme().toString())) { + s_logger.debug("Scheme " + rules.get(0).getScheme() + " is not supported by the provider " + this.getName()); + return false; + } + } + } + } + return true; } @@ -94,6 +109,7 @@ public class ElasticLoadBalancerElement extends AdapterBase implements LoadBalan lbCapabilities.put(Capability.SupportedLBAlgorithms, "roundrobin,leastconn,source"); lbCapabilities.put(Capability.SupportedLBIsolation, "shared"); lbCapabilities.put(Capability.SupportedProtocols, "tcp, udp"); + lbCapabilities.put(Capability.LbSchemes, LoadBalancerContainer.Scheme.Public.toString()); capabilities.put(Service.Lb, lbCapabilities); return capabilities; @@ -139,10 +155,10 @@ public class ElasticLoadBalancerElement extends AdapterBase implements LoadBalan @Override public boolean applyLBRules(Network network, List rules) throws ResourceUnavailableException { - if (!canHandle(network)) { + if (!canHandle(network, rules)) { return false; } - + return _lbMgr.applyLoadBalancerRules(network, rules); } diff --git a/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/lb/ElasticLoadBalancerManager.java b/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/lb/ElasticLoadBalancerManager.java index aea795d436f..cce2b2c23c1 100644 --- a/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/lb/ElasticLoadBalancerManager.java +++ b/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/lb/ElasticLoadBalancerManager.java @@ -19,11 +19,11 @@ package com.cloud.network.lb; import java.util.List; import org.apache.cloudstack.api.command.user.loadbalancer.CreateLoadBalancerRuleCmd; + import com.cloud.exception.InsufficientAddressCapacityException; import com.cloud.exception.NetworkRuleConflictException; import com.cloud.exception.ResourceUnavailableException; import com.cloud.network.Network; -import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.LoadBalancer; import com.cloud.user.Account; @@ -32,7 +32,7 @@ public interface ElasticLoadBalancerManager { public static final int DEFAULT_ELB_VM_CPU_MHZ = 256; // 500 MHz public boolean applyLoadBalancerRules(Network network, - List rules) + List rules) throws ResourceUnavailableException; public LoadBalancer handleCreateLoadBalancerRule(CreateLoadBalancerRuleCmd lb, Account caller, long networkId) throws InsufficientAddressCapacityException, NetworkRuleConflictException; diff --git a/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/lb/ElasticLoadBalancerManagerImpl.java b/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/lb/ElasticLoadBalancerManagerImpl.java index 283b517dce9..b21e8f9dba3 100644 --- a/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/lb/ElasticLoadBalancerManagerImpl.java +++ b/plugins/network-elements/elastic-loadbalancer/src/com/cloud/network/lb/ElasticLoadBalancerManagerImpl.java @@ -102,7 +102,6 @@ import com.cloud.network.router.VirtualRouter.RedundantState; import com.cloud.network.router.VirtualRouter.Role; import com.cloud.network.router.VpcVirtualNetworkApplianceManager; import com.cloud.network.rules.FirewallRule; -import com.cloud.network.rules.FirewallRule.Purpose; import com.cloud.network.rules.LoadBalancer; import com.cloud.offering.NetworkOffering; import com.cloud.offering.ServiceOffering; @@ -118,7 +117,6 @@ import com.cloud.user.UserContext; import com.cloud.user.dao.AccountDao; import com.cloud.utils.NumbersUtil; import com.cloud.utils.Pair; -import com.cloud.utils.component.Manager; import com.cloud.utils.component.ManagerBase; import com.cloud.utils.concurrency.NamedThreadFactory; import com.cloud.utils.db.DB; @@ -126,6 +124,7 @@ import com.cloud.utils.db.SearchBuilder; import com.cloud.utils.db.SearchCriteria; import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; +import com.cloud.utils.net.Ip; import com.cloud.vm.DomainRouterVO; import com.cloud.vm.NicProfile; import com.cloud.vm.ReservationContext; @@ -297,8 +296,7 @@ ElasticLoadBalancerManager, VirtualMachineGuru { String protocol = rule.getProtocol(); String algorithm = rule.getAlgorithm(); - String elbIp = _networkModel.getIp(rule.getSourceIpAddressId()).getAddress() - .addr(); + String elbIp = rule.getSourceIp().addr(); int srcPort = rule.getSourcePortStart(); String uuid = rule.getUuid(); List destinations = rule.getDestinations(); @@ -331,8 +329,10 @@ ElasticLoadBalancerManager, VirtualMachineGuru { return sendCommandsToRouter(elbVm, cmds); } - protected DomainRouterVO findElbVmForLb(FirewallRule lb) {//TODO: use a table to lookup - ElasticLbVmMapVO map = _elbVmMapDao.findOneByIp(lb.getSourceIpAddressId()); + protected DomainRouterVO findElbVmForLb(LoadBalancingRule lb) {//TODO: use a table to lookup + Network ntwk = _networkModel.getNetwork(lb.getNetworkId()); + long sourceIpId = _networkModel.getPublicIpAddress(lb.getSourceIp().addr(), ntwk.getDataCenterId()).getId(); + ElasticLbVmMapVO map = _elbVmMapDao.findOneByIp(sourceIpId); if (map == null) { return null; } @@ -342,15 +342,11 @@ ElasticLoadBalancerManager, VirtualMachineGuru { @Override public boolean applyLoadBalancerRules(Network network, - List rules) + List rules) throws ResourceUnavailableException { if (rules == null || rules.isEmpty()) { return true; } - if (rules.get(0).getPurpose() != Purpose.LoadBalancing) { - s_logger.warn("ELB: Not handling non-LB firewall rules"); - return false; - } DomainRouterVO elbVm = findElbVmForLb(rules.get(0)); @@ -363,14 +359,16 @@ ElasticLoadBalancerManager, VirtualMachineGuru { if (elbVm.getState() == State.Running) { //resend all rules for the public ip - List lbs = _lbDao.listByIpAddress(rules.get(0).getSourceIpAddressId()); + long sourceIpId = _networkModel.getPublicIpAddress(rules.get(0).getSourceIp().addr(), network.getDataCenterId()).getId(); + List lbs = _lbDao.listByIpAddress(sourceIpId); List lbRules = new ArrayList(); for (LoadBalancerVO lb : lbs) { List dstList = _lbMgr.getExistingDestinations(lb.getId()); List policyList = _lbMgr.getStickinessPolicies(lb.getId()); List hcPolicyList = _lbMgr.getHealthCheckPolicies(lb.getId()); + Ip sourceIp = _networkModel.getPublicIpAddress(lb.getSourceIpAddressId()).getAddress(); LoadBalancingRule loadBalancing = new LoadBalancingRule( - lb, dstList, policyList, hcPolicyList); + lb, dstList, policyList, hcPolicyList, sourceIp); lbRules.add(loadBalancing); } return applyLBRules(elbVm, lbRules, network.getId()); @@ -656,7 +654,10 @@ ElasticLoadBalancerManager, VirtualMachineGuru { LoadBalancer result = null; try { lb.setSourceIpAddressId(ipId); - result = _lbMgr.createLoadBalancer(lb, false); + + result = _lbMgr.createPublicLoadBalancer(lb.getXid(), lb.getName(), lb.getDescription(), + lb.getSourcePortStart(), lb.getDefaultPortStart(), ipId.longValue(), lb.getProtocol(), + lb.getAlgorithm(), false, UserContext.current()); } catch (NetworkRuleConflictException e) { s_logger.warn("Failed to create LB rule, not continuing with ELB deployment"); if (newIp) { @@ -943,7 +944,8 @@ ElasticLoadBalancerManager, VirtualMachineGuru { List dstList = _lbMgr.getExistingDestinations(lb.getId()); List policyList = _lbMgr.getStickinessPolicies(lb.getId()); List hcPolicyList = _lbMgr.getHealthCheckPolicies(lb.getId()); - LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, dstList, policyList, hcPolicyList); + Ip sourceIp = _networkModel.getPublicIpAddress(lb.getSourceIpAddressId()).getAddress(); + LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, dstList, policyList, hcPolicyList, sourceIp); lbRules.add(loadBalancing); } diff --git a/plugins/network-elements/f5/src/com/cloud/network/element/F5ExternalLoadBalancerElement.java b/plugins/network-elements/f5/src/com/cloud/network/element/F5ExternalLoadBalancerElement.java index e384e3cfd0d..80b42e030d8 100644 --- a/plugins/network-elements/f5/src/com/cloud/network/element/F5ExternalLoadBalancerElement.java +++ b/plugins/network-elements/f5/src/com/cloud/network/element/F5ExternalLoadBalancerElement.java @@ -16,9 +16,30 @@ // under the License. package com.cloud.network.element; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import javax.ejb.Local; +import javax.inject.Inject; + +import org.apache.cloudstack.api.response.ExternalLoadBalancerResponse; +import org.apache.cloudstack.network.ExternalNetworkDeviceManager.NetworkDevice; +import org.apache.log4j.Logger; + import com.cloud.agent.api.to.LoadBalancerTO; import com.cloud.api.ApiDBUtils; -import com.cloud.api.commands.*; +import com.cloud.api.commands.AddExternalLoadBalancerCmd; +import com.cloud.api.commands.AddF5LoadBalancerCmd; +import com.cloud.api.commands.ConfigureF5LoadBalancerCmd; +import com.cloud.api.commands.DeleteExternalLoadBalancerCmd; +import com.cloud.api.commands.DeleteF5LoadBalancerCmd; +import com.cloud.api.commands.ListExternalLoadBalancersCmd; +import com.cloud.api.commands.ListF5LoadBalancerNetworksCmd; +import com.cloud.api.commands.ListF5LoadBalancersCmd; import com.cloud.api.response.F5LoadBalancerResponse; import com.cloud.configuration.Config; import com.cloud.configuration.ConfigurationManager; @@ -27,22 +48,41 @@ import com.cloud.dc.DataCenter; import com.cloud.dc.DataCenterVO; import com.cloud.dc.dao.DataCenterDao; import com.cloud.deploy.DeployDestination; -import com.cloud.exception.*; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.InsufficientNetworkCapacityException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.ResourceUnavailableException; import com.cloud.host.Host; import com.cloud.host.HostVO; import com.cloud.host.dao.HostDao; import com.cloud.host.dao.HostDetailsDao; -import com.cloud.network.*; +import com.cloud.network.ExternalLoadBalancerDeviceManager; +import com.cloud.network.ExternalLoadBalancerDeviceManagerImpl; +import com.cloud.network.Network; import com.cloud.network.Network.Capability; import com.cloud.network.Network.Provider; import com.cloud.network.Network.Service; +import com.cloud.network.NetworkModel; import com.cloud.network.Networks.TrafficType; -import com.cloud.network.dao.*; +import com.cloud.network.PhysicalNetwork; +import com.cloud.network.PhysicalNetworkServiceProvider; +import com.cloud.network.PublicIpAddress; +import com.cloud.network.dao.ExternalLoadBalancerDeviceDao; +import com.cloud.network.dao.ExternalLoadBalancerDeviceVO; import com.cloud.network.dao.ExternalLoadBalancerDeviceVO.LBDeviceState; +import com.cloud.network.dao.NetworkDao; +import com.cloud.network.dao.NetworkExternalLoadBalancerDao; +import com.cloud.network.dao.NetworkExternalLoadBalancerVO; +import com.cloud.network.dao.NetworkServiceMapDao; +import com.cloud.network.dao.NetworkVO; +import com.cloud.network.dao.PhysicalNetworkDao; +import com.cloud.network.dao.PhysicalNetworkVO; import com.cloud.network.lb.LoadBalancingRule; import com.cloud.network.resource.F5BigIpResource; import com.cloud.network.rules.LbStickinessMethod; import com.cloud.network.rules.LbStickinessMethod.StickinessMethodType; +import com.cloud.network.rules.LoadBalancerContainer; import com.cloud.offering.NetworkOffering; import com.cloud.utils.NumbersUtil; import com.cloud.utils.exception.CloudRuntimeException; @@ -51,13 +91,6 @@ import com.cloud.vm.ReservationContext; import com.cloud.vm.VirtualMachine; import com.cloud.vm.VirtualMachineProfile; import com.google.gson.Gson; -import org.apache.cloudstack.api.response.ExternalLoadBalancerResponse; -import org.apache.cloudstack.network.ExternalNetworkDeviceManager.NetworkDevice; -import org.apache.log4j.Logger; - -import javax.ejb.Local; -import javax.inject.Inject; -import java.util.*; @Local(value = {NetworkElement.class, LoadBalancingServiceProvider.class, IpDeployer.class}) public class F5ExternalLoadBalancerElement extends ExternalLoadBalancerDeviceManagerImpl implements LoadBalancingServiceProvider, IpDeployer, F5ExternalLoadBalancerElementService, ExternalLoadBalancerDeviceManager { @@ -87,11 +120,25 @@ public class F5ExternalLoadBalancerElement extends ExternalLoadBalancerDeviceMan @Inject ConfigurationDao _configDao; - private boolean canHandle(Network config) { + private boolean canHandle(Network config, List rules) { if ((config.getGuestType() != Network.GuestType.Isolated && config.getGuestType() != Network.GuestType.Shared) || config.getTrafficType() != TrafficType.Guest) { + s_logger.trace("Not handling network with Type " + config.getGuestType() + " and traffic type " + config.getTrafficType()); return false; } + + Map lbCaps = this.getCapabilities().get(Service.Lb); + if (!lbCaps.isEmpty()) { + String schemeCaps = lbCaps.get(Capability.LbSchemes); + if (schemeCaps != null && rules != null && !rules.isEmpty()) { + for (LoadBalancingRule rule : rules) { + if (!schemeCaps.contains(rule.getScheme().toString())) { + s_logger.debug("Scheme " + rules.get(0).getScheme() + " is not supported by the provider " + this.getName()); + return false; + } + } + } + } return (_networkManager.isProviderForNetwork(getProvider(), config.getId()) && _ntwkSrvcDao.canProviderSupportServiceInNetwork(config.getId(), Service.Lb, Network.Provider.F5BigIp)); } @@ -100,7 +147,7 @@ public class F5ExternalLoadBalancerElement extends ExternalLoadBalancerDeviceMan public boolean implement(Network guestConfig, NetworkOffering offering, DeployDestination dest, ReservationContext context) throws ResourceUnavailableException, ConcurrentOperationException, InsufficientNetworkCapacityException { - if (!canHandle(guestConfig)) { + if (!canHandle(guestConfig, null)) { return false; } @@ -124,7 +171,7 @@ public class F5ExternalLoadBalancerElement extends ExternalLoadBalancerDeviceMan @Override public boolean shutdown(Network guestConfig, ReservationContext context, boolean cleanup) throws ResourceUnavailableException, ConcurrentOperationException { - if (!canHandle(guestConfig)) { + if (!canHandle(guestConfig, null)) { return false; } @@ -143,13 +190,16 @@ public class F5ExternalLoadBalancerElement extends ExternalLoadBalancerDeviceMan @Override public boolean validateLBRule(Network network, LoadBalancingRule rule) { - String algo = rule.getAlgorithm(); - return (algo.equals("roundrobin") || algo.equals("leastconn")); + if (canHandle(network, new ArrayList(Arrays.asList(rule)))) { + String algo = rule.getAlgorithm(); + return (algo.equals("roundrobin") || algo.equals("leastconn")); + } + return true; } @Override public boolean applyLBRules(Network config, List rules) throws ResourceUnavailableException { - if (!canHandle(config)) { + if (!canHandle(config, rules)) { return false; } @@ -180,6 +230,9 @@ public class F5ExternalLoadBalancerElement extends ExternalLoadBalancerDeviceMan // Support inline mode with firewall lbCapabilities.put(Capability.InlineMode, "true"); + + //support only for public lb + lbCapabilities.put(Capability.LbSchemes, LoadBalancerContainer.Scheme.Public.toString()); LbStickinessMethod method; List methodList = new ArrayList(); diff --git a/plugins/network-elements/internal-loadbalancer/pom.xml b/plugins/network-elements/internal-loadbalancer/pom.xml new file mode 100644 index 00000000000..48e664ee0e5 --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/pom.xml @@ -0,0 +1,50 @@ + + + 4.0.0 + cloud-plugin-network-internallb + Apache CloudStack Plugin - Network Internal Load Balancer + + org.apache.cloudstack + cloudstack-plugins + 4.2.0-SNAPSHOT + ../../pom.xml + + + install + src + test + + + resources + + **/*.xml + + + + + + test/resources + + %regex[.*[0-9]*To[0-9]*.*Test.*] + + + + + diff --git a/plugins/network-elements/internal-loadbalancer/src/org/apache/cloudstack/network/element/InternalLoadBalancerElement.java b/plugins/network-elements/internal-loadbalancer/src/org/apache/cloudstack/network/element/InternalLoadBalancerElement.java new file mode 100644 index 00000000000..4b9308b6606 --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/src/org/apache/cloudstack/network/element/InternalLoadBalancerElement.java @@ -0,0 +1,548 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.cloudstack.network.element; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import javax.ejb.Local; +import javax.inject.Inject; + +import org.apache.cloudstack.api.command.admin.internallb.ConfigureInternalLoadBalancerElementCmd; +import org.apache.cloudstack.api.command.admin.internallb.CreateInternalLoadBalancerElementCmd; +import org.apache.cloudstack.api.command.admin.internallb.ListInternalLoadBalancerElementsCmd; +import org.apache.cloudstack.lb.dao.ApplicationLoadBalancerRuleDao; +import org.apache.cloudstack.network.lb.InternalLoadBalancerVMManager; +import org.apache.log4j.Logger; + +import com.cloud.agent.api.to.LoadBalancerTO; +import com.cloud.configuration.ConfigurationManager; +import com.cloud.dc.DataCenter; +import com.cloud.dc.DataCenter.NetworkType; +import com.cloud.deploy.DeployDestination; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.Network; +import com.cloud.network.Network.Capability; +import com.cloud.network.Network.Provider; +import com.cloud.network.Network.Service; +import com.cloud.network.NetworkModel; +import com.cloud.network.Networks.TrafficType; +import com.cloud.network.PhysicalNetworkServiceProvider; +import com.cloud.network.PublicIpAddress; +import com.cloud.network.VirtualRouterProvider; +import com.cloud.network.VirtualRouterProvider.VirtualRouterProviderType; +import com.cloud.network.dao.NetworkServiceMapDao; +import com.cloud.network.dao.PhysicalNetworkServiceProviderDao; +import com.cloud.network.dao.VirtualRouterProviderDao; +import com.cloud.network.element.IpDeployer; +import com.cloud.network.element.LoadBalancingServiceProvider; +import com.cloud.network.element.NetworkElement; +import com.cloud.network.element.VirtualRouterElement; +import com.cloud.network.element.VirtualRouterProviderVO; +import com.cloud.network.lb.LoadBalancingRule; +import com.cloud.network.router.VirtualRouter; +import com.cloud.network.router.VirtualRouter.Role; +import com.cloud.network.rules.FirewallRule; +import com.cloud.network.rules.LoadBalancerContainer; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.offering.NetworkOffering; +import com.cloud.user.Account; +import com.cloud.user.AccountManager; +import com.cloud.user.User; +import com.cloud.utils.component.AdapterBase; +import com.cloud.utils.db.SearchCriteria.Op; +import com.cloud.utils.db.SearchCriteria2; +import com.cloud.utils.db.SearchCriteriaService; +import com.cloud.utils.exception.CloudRuntimeException; +import com.cloud.utils.net.Ip; +import com.cloud.vm.DomainRouterVO; +import com.cloud.vm.NicProfile; +import com.cloud.vm.ReservationContext; +import com.cloud.vm.VirtualMachine; +import com.cloud.vm.VirtualMachineProfile; +import com.cloud.vm.dao.DomainRouterDao; + +@Local(value = {NetworkElement.class}) +public class InternalLoadBalancerElement extends AdapterBase implements LoadBalancingServiceProvider, InternalLoadBalancerElementService, IpDeployer{ + private static final Logger s_logger = Logger.getLogger(InternalLoadBalancerElement.class); + protected static final Map> capabilities = setCapabilities(); + private static InternalLoadBalancerElement internalLbElement = null; + + @Inject NetworkModel _ntwkModel; + @Inject NetworkServiceMapDao _ntwkSrvcDao; + @Inject DomainRouterDao _routerDao; + @Inject VirtualRouterProviderDao _vrProviderDao; + @Inject PhysicalNetworkServiceProviderDao _pNtwkSvcProviderDao; + @Inject InternalLoadBalancerVMManager _internalLbMgr; + @Inject ConfigurationManager _configMgr; + @Inject AccountManager _accountMgr; + @Inject ApplicationLoadBalancerRuleDao _appLbDao; + + protected InternalLoadBalancerElement() { + } + + + public static InternalLoadBalancerElement getInstance() { + if ( internalLbElement == null) { + internalLbElement = new InternalLoadBalancerElement(); + } + return internalLbElement; + } + + + private boolean canHandle(Network config, Scheme lbScheme) { + //works in Advance zone only + DataCenter dc = _configMgr.getZone(config.getDataCenterId()); + if (dc.getNetworkType() != NetworkType.Advanced) { + s_logger.trace("Not hanling zone of network type " + dc.getNetworkType()); + return false; + } + if (config.getGuestType() != Network.GuestType.Isolated || config.getTrafficType() != TrafficType.Guest) { + s_logger.trace("Not handling network with Type " + config.getGuestType() + " and traffic type " + config.getTrafficType()); + return false; + } + + Map lbCaps = this.getCapabilities().get(Service.Lb); + if (!lbCaps.isEmpty()) { + String schemeCaps = lbCaps.get(Capability.LbSchemes); + if (schemeCaps != null && lbScheme != null) { + if (!schemeCaps.contains(lbScheme.toString())) { + s_logger.debug("Scheme " + lbScheme.toString() + " is not supported by the provider " + this.getName()); + return false; + } + } + } + + if (!_ntwkModel.isProviderSupportServiceInNetwork(config.getId(), Service.Lb, getProvider())) { + s_logger.trace("Element " + getProvider().getName() + " doesn't support service " + Service.Lb + + " in the network " + config); + return false; + } + return true; + } + + + @Override + public Map> getCapabilities() { + return capabilities; + } + + + @Override + public Provider getProvider() { + return Provider.InternalLbVm; + } + + + @Override + public boolean implement(Network network, NetworkOffering offering, DeployDestination dest, ReservationContext context) + throws ConcurrentOperationException, ResourceUnavailableException, + InsufficientCapacityException { + + if (!canHandle(network, null)) { + s_logger.trace("No need to implement " + this.getName()); + return true; + } + + //1) Get all the Ips from the network having LB rules assigned + List ips = _appLbDao.listLbIpsBySourceIpNetworkIdAndScheme(network.getId(), Scheme.Internal); + + //2) Start those vms + for (String ip : ips) { + Ip sourceIp = new Ip(ip); + List internalLbVms; + try { + internalLbVms = _internalLbMgr.deployInternalLbVm(network, sourceIp, dest, _accountMgr.getAccount(network.getAccountId()), null); + } catch (InsufficientCapacityException e) { + s_logger.warn("Failed to deploy element " + this.getName() + " for ip " + sourceIp + " due to:", e); + return false; + } catch (ConcurrentOperationException e) { + s_logger.warn("Failed to deploy element " + this.getName() + " for ip " + sourceIp + " due to:", e); + return false; + } + + if (internalLbVms == null || internalLbVms.isEmpty()) { + throw new ResourceUnavailableException("Can't deploy " + this.getName() + " to handle LB rules", + DataCenter.class, network.getDataCenterId()); + } + } + + return true; + } + + + @Override + public boolean prepare(Network network, NicProfile nic, VirtualMachineProfile vm, DeployDestination dest, ReservationContext context) throws ConcurrentOperationException, + ResourceUnavailableException, InsufficientCapacityException { + + if (!canHandle(network, null)) { + s_logger.trace("No need to prepare " + this.getName()); + return true; + } + + if (vm.getType() == VirtualMachine.Type.User) { + //1) Get all the Ips from the network having LB rules assigned + List ips = _appLbDao.listLbIpsBySourceIpNetworkIdAndScheme(network.getId(), Scheme.Internal); + + //2) Start those vms + for (String ip : ips) { + Ip sourceIp = new Ip(ip); + List internalLbVms; + try { + internalLbVms = _internalLbMgr.deployInternalLbVm(network, sourceIp, dest, _accountMgr.getAccount(network.getAccountId()), null); + } catch (InsufficientCapacityException e) { + s_logger.warn("Failed to deploy element " + this.getName() + " for ip " + sourceIp + " due to:", e); + return false; + } catch (ConcurrentOperationException e) { + s_logger.warn("Failed to deploy element " + this.getName() + " for ip " + sourceIp + " due to:", e); + return false; + } + + if (internalLbVms == null || internalLbVms.isEmpty()) { + throw new ResourceUnavailableException("Can't deploy " + this.getName() + " to handle LB rules", + DataCenter.class, network.getDataCenterId()); + } + } + } + + return true; + } + + @Override + public boolean release(Network network, NicProfile nic, VirtualMachineProfile vm, ReservationContext context) throws ConcurrentOperationException, ResourceUnavailableException { + return true; + } + + + @Override + public boolean shutdown(Network network, ReservationContext context, boolean cleanup) throws ConcurrentOperationException, ResourceUnavailableException { + List internalLbVms = _routerDao.listByNetworkAndRole(network.getId(), Role.INTERNAL_LB_VM); + if (internalLbVms == null || internalLbVms.isEmpty()) { + return true; + } + boolean result = true; + for (VirtualRouter internalLbVm : internalLbVms) { + result = result && _internalLbMgr.destroyInternalLbVm(internalLbVm.getId(), + context.getAccount(), context.getCaller().getId()); + if (cleanup) { + if (!result) { + s_logger.warn("Failed to stop internal lb element " + internalLbVm + ", but would try to process clean up anyway."); + } + result = (_internalLbMgr.destroyInternalLbVm(internalLbVm.getId(), + context.getAccount(), context.getCaller().getId())); + if (!result) { + s_logger.warn("Failed to clean up internal lb element " + internalLbVm); + } + } + } + return result; + } + + + @Override + public boolean destroy(Network network, ReservationContext context) throws ConcurrentOperationException, ResourceUnavailableException { + List internalLbVms = _routerDao.listByNetworkAndRole(network.getId(), Role.INTERNAL_LB_VM); + if (internalLbVms == null || internalLbVms.isEmpty()) { + return true; + } + boolean result = true; + for (VirtualRouter internalLbVm : internalLbVms) { + result = result && (_internalLbMgr.destroyInternalLbVm(internalLbVm.getId(), + context.getAccount(), context.getCaller().getId())); + } + return result; + } + + + @Override + public boolean isReady(PhysicalNetworkServiceProvider provider) { + VirtualRouterProviderVO element = _vrProviderDao.findByNspIdAndType(provider.getId(), + VirtualRouterProviderType.InternalLbVm); + if (element == null) { + return false; + } + return element.isEnabled(); + } + + + @Override + public boolean shutdownProviderInstances(PhysicalNetworkServiceProvider provider, ReservationContext context) + throws ConcurrentOperationException, ResourceUnavailableException { + VirtualRouterProviderVO element = _vrProviderDao.findByNspIdAndType(provider.getId(), + VirtualRouterProviderType.InternalLbVm); + if (element == null) { + return true; + } + long elementId = element.getId(); + List internalLbVms = _routerDao.listByElementId(elementId); + boolean result = true; + for (DomainRouterVO internalLbVm : internalLbVms) { + result = result && (_internalLbMgr.destroyInternalLbVm(internalLbVm.getId(), + context.getAccount(), context.getCaller().getId())); + } + _vrProviderDao.remove(elementId); + + return result; + } + + + @Override + public boolean canEnableIndividualServices() { + return true; + } + + + @Override + public boolean verifyServicesCombination(Set services) { + return true; + } + + + @Override + public IpDeployer getIpDeployer(Network network) { + return this; + } + + + @Override + public boolean applyLBRules(Network network, List rules) throws ResourceUnavailableException { + //1) Get Internal LB VMs to destroy + Set vmsToDestroy = getVmsToDestroy(rules); + + //2) Get rules to apply + Map> rulesToApply = getLbRulesToApply(rules); + s_logger.debug("Applying " + rulesToApply.size() + " on element " + this.getName()); + + + for (Ip sourceIp : rulesToApply.keySet()) { + if (vmsToDestroy.contains(sourceIp)) { + //2.1 Destroy internal lb vm + List vms = _internalLbMgr.findInternalLbVms(network.getId(), sourceIp); + if (vms.size() > 0) { + //only one internal lb per IP exists + try { + s_logger.debug("Destroying internal lb vm for ip " + sourceIp.addr() + " as all the rules for this vm are in Revoke state"); + return _internalLbMgr.destroyInternalLbVm(vms.get(0).getId(), _accountMgr.getAccount(Account.ACCOUNT_ID_SYSTEM), + _accountMgr.getUserIncludingRemoved(User.UID_SYSTEM).getId()); + } catch (ConcurrentOperationException e) { + s_logger.warn("Failed to apply lb rule(s) for ip " + sourceIp.addr() + " on the element " + this.getName() + " due to:", e); + return false; + } + } + } else { + //2.2 Start Internal LB vm per IP address + List internalLbVms; + try { + DeployDestination dest = new DeployDestination(_configMgr.getZone(network.getDataCenterId()), null, null, null); + internalLbVms = _internalLbMgr.deployInternalLbVm(network, sourceIp, dest, _accountMgr.getAccount(network.getAccountId()), null); + } catch (InsufficientCapacityException e) { + s_logger.warn("Failed to apply lb rule(s) for ip " + sourceIp.addr() + "on the element " + this.getName() + " due to:", e); + return false; + } catch (ConcurrentOperationException e) { + s_logger.warn("Failed to apply lb rule(s) for ip " + sourceIp.addr() + "on the element " + this.getName() + " due to:", e); + return false; + } + + if (internalLbVms == null || internalLbVms.isEmpty()) { + throw new ResourceUnavailableException("Can't find/deploy internal lb vm to handle LB rules", + DataCenter.class, network.getDataCenterId()); + } + + //2.3 Apply Internal LB rules on the VM + if (!_internalLbMgr.applyLoadBalancingRules(network, rulesToApply.get(sourceIp), internalLbVms)) { + throw new CloudRuntimeException("Failed to apply load balancing rules for ip " + sourceIp.addr() + + " in network " + network.getId() + " on element " + this.getName()); + } + } + } + + return true; + } + + + protected Map> getLbRulesToApply(List rules) { + //Group rules by the source ip address as NetworkManager always passes the entire network lb config to the element + Map> rulesToApply = groupBySourceIp(rules); + + return rulesToApply; + } + + + protected Set getVmsToDestroy(List rules) { + //1) Group rules by the source ip address as NetworkManager always passes the entire network lb config to the element + Map> groupedRules = groupBySourceIp(rules); + + //2) Count rules in revoke state + Set vmsToDestroy = new HashSet(); + + for (Ip sourceIp : groupedRules.keySet()) { + List rulesToCheck = groupedRules.get(sourceIp); + int revoke = 0; + for (LoadBalancingRule ruleToCheck : rulesToCheck) { + if (ruleToCheck.getState() == FirewallRule.State.Revoke){ + revoke++; + } + } + + if (revoke == rulesToCheck.size()) { + s_logger.debug("Have to destroy internal lb vm for source ip " + sourceIp); + vmsToDestroy.add(sourceIp); + } + } + return vmsToDestroy; + } + + + protected Map> groupBySourceIp(List rules) { + Map> groupedRules = new HashMap>(); + for (LoadBalancingRule rule : rules) { + Ip sourceIp = rule.getSourceIp(); + if (!groupedRules.containsKey(sourceIp)) { + groupedRules.put(sourceIp, null); + } + + List rulesToApply = groupedRules.get(sourceIp); + if (rulesToApply == null) { + rulesToApply = new ArrayList(); + } + rulesToApply.add(rule); + groupedRules.put(sourceIp, rulesToApply); + } + return groupedRules; + } + + @Override + public boolean validateLBRule(Network network, LoadBalancingRule rule) { + List rules = new ArrayList(); + rules.add(rule); + if (canHandle(network, rule.getScheme())) { + List routers = _routerDao.listByNetworkAndRole(network.getId(), Role.INTERNAL_LB_VM); + if (routers == null || routers.isEmpty()) { + return true; + } + return VirtualRouterElement.validateHAProxyLBRule(rule); + } + return true; + } + + @Override + public List updateHealthChecks(Network network, List lbrules) { + return null; + } + + private static Map> setCapabilities() { + Map> capabilities = new HashMap>(); + + // Set capabilities for LB service + Map lbCapabilities = new HashMap(); + lbCapabilities.put(Capability.SupportedLBAlgorithms, "roundrobin,leastconn,source"); + lbCapabilities.put(Capability.SupportedLBIsolation, "dedicated"); + lbCapabilities.put(Capability.SupportedProtocols, "tcp, udp"); + lbCapabilities.put(Capability.SupportedStickinessMethods, VirtualRouterElement.getHAProxyStickinessCapability()); + lbCapabilities.put(Capability.LbSchemes, LoadBalancerContainer.Scheme.Internal.toString()); + + capabilities.put(Service.Lb, lbCapabilities); + return capabilities; + } + + @Override + public List> getCommands() { + List> cmdList = new ArrayList>(); + cmdList.add(CreateInternalLoadBalancerElementCmd.class); + cmdList.add(ConfigureInternalLoadBalancerElementCmd.class); + cmdList.add(ListInternalLoadBalancerElementsCmd.class); + return cmdList; + } + + @Override + public VirtualRouterProvider configureInternalLoadBalancerElement(long id, boolean enable) { + VirtualRouterProviderVO element = _vrProviderDao.findById(id); + if (element == null || element.getType() != VirtualRouterProviderType.InternalLbVm) { + throw new InvalidParameterValueException("Can't find " + this.getName() + " element with network service provider id " + id + + " to be used as a provider for " + this.getName()); + } + + element.setEnabled(enable); + element = _vrProviderDao.persist(element); + + return element; + } + + @Override + public VirtualRouterProvider addInternalLoadBalancerElement(long ntwkSvcProviderId) { + VirtualRouterProviderVO element = _vrProviderDao.findByNspIdAndType(ntwkSvcProviderId, VirtualRouterProviderType.InternalLbVm); + if (element != null) { + s_logger.debug("There is already an " + this.getName() + " with service provider id " + ntwkSvcProviderId); + return null; + } + + PhysicalNetworkServiceProvider provider = _pNtwkSvcProviderDao.findById(ntwkSvcProviderId); + if (provider == null || !provider.getProviderName().equalsIgnoreCase(this.getName())) { + throw new InvalidParameterValueException("Invalid network service provider is specified"); + } + + element = new VirtualRouterProviderVO(ntwkSvcProviderId, VirtualRouterProviderType.InternalLbVm); + element = _vrProviderDao.persist(element); + return element; + } + + + @Override + public VirtualRouterProvider getInternalLoadBalancerElement(long id) { + VirtualRouterProvider provider = _vrProviderDao.findById(id); + if (provider == null || provider.getType() != VirtualRouterProviderType.InternalLbVm) { + throw new InvalidParameterValueException("Unable to find " + this.getName() + " by id"); + } + return provider; + } + + @Override + public List searchForInternalLoadBalancerElements(Long id, Long ntwkSvsProviderId, Boolean enabled) { + + SearchCriteriaService sc = SearchCriteria2.create(VirtualRouterProviderVO.class); + if (id != null) { + sc.addAnd(sc.getEntity().getId(), Op.EQ, id); + } + if (ntwkSvsProviderId != null) { + sc.addAnd(sc.getEntity().getNspId(), Op.EQ, ntwkSvsProviderId); + } + if (enabled != null) { + sc.addAnd(sc.getEntity().isEnabled(), Op.EQ, enabled); + } + + //return only Internal LB elements + sc.addAnd(sc.getEntity().getType(), Op.EQ, VirtualRouterProvider.VirtualRouterProviderType.InternalLbVm); + + return sc.list(); + } + + @Override + public boolean applyIps(Network network, List ipAddress, Set services) throws ResourceUnavailableException { + //do nothing here; this element just has to extend the ip deployer + //as the LB service implements IPDeployerRequester + return true; + } + +} diff --git a/plugins/network-elements/internal-loadbalancer/src/org/apache/cloudstack/network/lb/InternalLoadBalancerVMManager.java b/plugins/network-elements/internal-loadbalancer/src/org/apache/cloudstack/network/lb/InternalLoadBalancerVMManager.java new file mode 100644 index 00000000000..9faca562bfb --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/src/org/apache/cloudstack/network/lb/InternalLoadBalancerVMManager.java @@ -0,0 +1,90 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.network.lb; + +import java.util.List; +import java.util.Map; + +import com.cloud.deploy.DeployDestination; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.Network; +import com.cloud.network.lb.LoadBalancingRule; +import com.cloud.network.router.VirtualRouter; +import com.cloud.user.Account; +import com.cloud.utils.component.Manager; +import com.cloud.utils.net.Ip; +import com.cloud.vm.VirtualMachineProfile.Param; + +public interface InternalLoadBalancerVMManager extends Manager, InternalLoadBalancerVMService{ + //RAM/CPU for the system offering used by Internal LB VMs + public static final int DEFAULT_INTERNALLB_VM_RAMSIZE = 128; // 128 MB + public static final int DEFAULT_INTERNALLB_VM_CPU_MHZ = 256; // 256 MHz + + /** + * Destroys Internal LB vm instance + * @param vmId + * @param caller + * @param callerUserId + * @return + * @throws ResourceUnavailableException + * @throws ConcurrentOperationException + */ + boolean destroyInternalLbVm(long vmId, Account caller, Long callerUserId) + throws ResourceUnavailableException, ConcurrentOperationException; + + + /** + * Deploys internal lb vm + * @param guestNetwork + * @param requestedGuestIp + * @param dest + * @param owner + * @param params + * @return + * @throws InsufficientCapacityException + * @throws ConcurrentOperationException + * @throws ResourceUnavailableException + */ + List deployInternalLbVm(Network guestNetwork, Ip requestedGuestIp, DeployDestination dest, Account owner, + Map params) throws InsufficientCapacityException, + ConcurrentOperationException, ResourceUnavailableException; + + + + /** + * + * @param network + * @param rules + * @param internalLbVms + * @return + * @throws ResourceUnavailableException + */ + boolean applyLoadBalancingRules(Network network, List rules, List internalLbVms) + throws ResourceUnavailableException; + + + /** + * Returns existing Internal Load Balancer elements based on guestNetworkId (required) and requestedIp (optional) + * @param guestNetworkId + * @param requestedGuestIp + * @return + */ + List findInternalLbVms(long guestNetworkId, Ip requestedGuestIp); + +} diff --git a/plugins/network-elements/internal-loadbalancer/src/org/apache/cloudstack/network/lb/InternalLoadBalancerVMManagerImpl.java b/plugins/network-elements/internal-loadbalancer/src/org/apache/cloudstack/network/lb/InternalLoadBalancerVMManagerImpl.java new file mode 100644 index 00000000000..fe32a7ba26f --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/src/org/apache/cloudstack/network/lb/InternalLoadBalancerVMManagerImpl.java @@ -0,0 +1,951 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.network.lb; + +import java.util.ArrayList; +import java.util.Iterator; +import java.util.List; +import java.util.Map; + +import javax.ejb.Local; +import javax.inject.Inject; +import javax.naming.ConfigurationException; + +import org.apache.cloudstack.lb.ApplicationLoadBalancerRuleVO; +import org.apache.cloudstack.lb.dao.ApplicationLoadBalancerRuleDao; +import org.apache.log4j.Logger; +import org.springframework.stereotype.Component; + +import com.cloud.agent.AgentManager; +import com.cloud.agent.AgentManager.OnError; +import com.cloud.agent.api.Answer; +import com.cloud.agent.api.GetDomRVersionAnswer; +import com.cloud.agent.api.GetDomRVersionCmd; +import com.cloud.agent.api.StopAnswer; +import com.cloud.agent.api.check.CheckSshAnswer; +import com.cloud.agent.api.check.CheckSshCommand; +import com.cloud.agent.api.routing.LoadBalancerConfigCommand; +import com.cloud.agent.api.routing.NetworkElementCommand; +import com.cloud.agent.api.to.LoadBalancerTO; +import com.cloud.agent.api.to.NicTO; +import com.cloud.agent.api.to.VirtualMachineTO; +import com.cloud.agent.manager.Commands; +import com.cloud.configuration.Config; +import com.cloud.configuration.dao.ConfigurationDao; +import com.cloud.dc.DataCenter; +import com.cloud.dc.DataCenterVO; +import com.cloud.dc.dao.DataCenterDao; +import com.cloud.deploy.DataCenterDeployment; +import com.cloud.deploy.DeployDestination; +import com.cloud.deploy.DeploymentPlan; +import com.cloud.exception.AgentUnavailableException; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientAddressCapacityException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.InsufficientServerCapacityException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.OperationTimedoutException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.exception.StorageUnavailableException; +import com.cloud.hypervisor.Hypervisor.HypervisorType; +import com.cloud.network.Network; +import com.cloud.network.Network.Provider; +import com.cloud.network.Network.Service; +import com.cloud.network.NetworkManager; +import com.cloud.network.NetworkModel; +import com.cloud.network.Networks.TrafficType; +import com.cloud.network.PhysicalNetworkServiceProvider; +import com.cloud.network.VirtualRouterProvider; +import com.cloud.network.VirtualRouterProvider.VirtualRouterProviderType; +import com.cloud.network.dao.NetworkDao; +import com.cloud.network.dao.NetworkVO; +import com.cloud.network.dao.PhysicalNetworkServiceProviderDao; +import com.cloud.network.dao.VirtualRouterProviderDao; +import com.cloud.network.lb.LoadBalancingRule; +import com.cloud.network.lb.LoadBalancingRule.LbDestination; +import com.cloud.network.lb.LoadBalancingRule.LbHealthCheckPolicy; +import com.cloud.network.lb.LoadBalancingRule.LbStickinessPolicy; +import com.cloud.network.lb.LoadBalancingRulesManager; +import com.cloud.network.router.VirtualRouter; +import com.cloud.network.router.VirtualRouter.RedundantState; +import com.cloud.network.router.VirtualRouter.Role; +import com.cloud.network.rules.FirewallRule; +import com.cloud.offering.NetworkOffering; +import com.cloud.offering.ServiceOffering; +import com.cloud.offerings.dao.NetworkOfferingDao; +import com.cloud.resource.ResourceManager; +import com.cloud.server.ConfigurationServer; +import com.cloud.service.ServiceOfferingVO; +import com.cloud.service.dao.ServiceOfferingDao; +import com.cloud.storage.VMTemplateVO; +import com.cloud.storage.dao.VMTemplateDao; +import com.cloud.user.Account; +import com.cloud.user.AccountManager; +import com.cloud.user.User; +import com.cloud.utils.Pair; +import com.cloud.utils.component.ManagerBase; +import com.cloud.utils.db.DB; +import com.cloud.utils.exception.CloudRuntimeException; +import com.cloud.utils.net.Ip; +import com.cloud.utils.net.NetUtils; +import com.cloud.vm.DomainRouterVO; +import com.cloud.vm.Nic; +import com.cloud.vm.NicProfile; +import com.cloud.vm.NicVO; +import com.cloud.vm.ReservationContext; +import com.cloud.vm.VirtualMachine; +import com.cloud.vm.VirtualMachine.State; +import com.cloud.vm.VirtualMachineGuru; +import com.cloud.vm.VirtualMachineManager; +import com.cloud.vm.VirtualMachineName; +import com.cloud.vm.VirtualMachineProfile; +import com.cloud.vm.VirtualMachineProfile.Param; +import com.cloud.vm.dao.DomainRouterDao; +import com.cloud.vm.dao.NicDao; + +@Component +@Local(value = { InternalLoadBalancerVMManager.class, InternalLoadBalancerVMService.class}) +public class InternalLoadBalancerVMManagerImpl extends ManagerBase implements + InternalLoadBalancerVMManager, VirtualMachineGuru { + private static final Logger s_logger = Logger + .getLogger(InternalLoadBalancerVMManagerImpl.class); + static final private String _internalLbVmNamePrefix = "b"; + + private String _instance; + private String _mgmtHost; + private String _mgmtCidr; + private long _internalLbVmOfferingId; + + @Inject VirtualMachineManager _itMgr; + @Inject DomainRouterDao _internalLbVmDao; + @Inject ConfigurationDao _configDao; + @Inject AgentManager _agentMgr; + @Inject DataCenterDao _dcDao; + @Inject VirtualRouterProviderDao _vrProviderDao; + @Inject ApplicationLoadBalancerRuleDao _lbDao; + @Inject NetworkModel _ntwkModel; + @Inject LoadBalancingRulesManager _lbMgr; + @Inject NicDao _nicDao; + @Inject AccountManager _accountMgr; + @Inject NetworkDao _networkDao; + @Inject NetworkManager _ntwkMgr; + @Inject ServiceOfferingDao _serviceOfferingDao; + @Inject PhysicalNetworkServiceProviderDao _physicalProviderDao; + @Inject NetworkOfferingDao _networkOfferingDao; + @Inject VMTemplateDao _templateDao; + @Inject ResourceManager _resourceMgr; + @Inject ConfigurationServer _configServer; + + @Override + public DomainRouterVO findByName(String name) { + if (!VirtualMachineName.isValidSystemVmName(name, _instance, _internalLbVmNamePrefix)) { + return null; + } + + return _internalLbVmDao.findById(VirtualMachineName.getRouterId(name)); + } + + @Override + public DomainRouterVO findById(long id) { + return _internalLbVmDao.findById(id); + } + + @Override + public DomainRouterVO persist(DomainRouterVO vm) { + DomainRouterVO virtualRouter = _internalLbVmDao.persist(vm); + return virtualRouter; + } + + @Override + public boolean finalizeVirtualMachineProfile(VirtualMachineProfile profile, + DeployDestination dest, ReservationContext context) { + + //Internal LB vm starts up with 2 Nics + //Nic #1 - Guest Nic with IP address that would act as the LB entry point + //Nic #2 - Control/Management Nic + + StringBuilder buf = profile.getBootArgsBuilder(); + buf.append(" template=domP"); + buf.append(" name=").append(profile.getHostName()); + + if (Boolean.valueOf(_configDao.getValue("system.vm.random.password"))) { + buf.append(" vmpassword=").append(_configDao.getValue("system.vm.password")); + } + + NicProfile controlNic = null; + Network guestNetwork = null; + + for (NicProfile nic : profile.getNics()) { + int deviceId = nic.getDeviceId(); + buf.append(" eth").append(deviceId).append("ip=").append(nic.getIp4Address()); + buf.append(" eth").append(deviceId).append("mask=").append(nic.getNetmask()); + + if (nic.isDefaultNic()) { + buf.append(" gateway=").append(nic.getGateway()); + buf.append(" dns1=").append(nic.getGateway()); + } + + if (nic.getTrafficType() == TrafficType.Guest) { + guestNetwork = _ntwkModel.getNetwork(nic.getNetworkId()); + } else if (nic.getTrafficType() == TrafficType.Management) { + buf.append(" localgw=").append(dest.getPod().getGateway()); + } else if (nic.getTrafficType() == TrafficType.Control) { + controlNic = nic; + // Internal LB control command is sent over management server in VMware + if (dest.getHost().getHypervisorType() == HypervisorType.VMware) { + if (s_logger.isInfoEnabled()) { + s_logger.info("Check if we need to add management server explicit route to Internal LB. pod cidr: " + + dest.getPod().getCidrAddress() + "/" + dest.getPod().getCidrSize() + + ", pod gateway: " + dest.getPod().getGateway() + ", management host: " + _mgmtHost); + } + + if (s_logger.isInfoEnabled()) { + s_logger.info("Add management server explicit route to Internal LB."); + } + + + buf.append(" mgmtcidr=").append(_mgmtCidr); + buf.append(" localgw=").append(dest.getPod().getGateway()); + } + } + } + + if (controlNic == null) { + throw new CloudRuntimeException("Didn't start a control port"); + } + + if (guestNetwork != null) { + String domain = guestNetwork.getNetworkDomain(); + if (domain != null) { + buf.append(" domain=" + domain); + } + } + + String type = "ilbvm"; + buf.append(" type=" + type); + + if (s_logger.isDebugEnabled()) { + s_logger.debug("Boot Args for " + profile + ": " + buf.toString()); + } + + return true; + } + + @Override + public boolean finalizeDeployment(Commands cmds, VirtualMachineProfile profile, DeployDestination dest, ReservationContext context) throws ResourceUnavailableException { + DomainRouterVO internalLbVm = profile.getVirtualMachine(); + + List nics = profile.getNics(); + for (NicProfile nic : nics) { + if (nic.getTrafficType() == TrafficType.Control) { + internalLbVm.setPrivateIpAddress(nic.getIp4Address()); + internalLbVm.setPrivateMacAddress(nic.getMacAddress()); + } + } + _internalLbVmDao.update(internalLbVm.getId(), internalLbVm); + + finalizeCommandsOnStart(cmds, profile); + return true; + } + + @Override + public boolean finalizeStart(VirtualMachineProfile profile, long hostId, Commands cmds, ReservationContext context) { + DomainRouterVO internalLbVm = profile.getVirtualMachine(); + + boolean result = true; + + Answer answer = cmds.getAnswer("checkSsh"); + if (answer != null && answer instanceof CheckSshAnswer) { + CheckSshAnswer sshAnswer = (CheckSshAnswer) answer; + if (sshAnswer == null || !sshAnswer.getResult()) { + s_logger.warn("Unable to ssh to the internal LB VM: " + sshAnswer.getDetails()); + result = false; + } + } else { + result = false; + } + if (result == false) { + return result; + } + + //Get guest network info + List guestNetworks = new ArrayList(); + List internalLbVmNics = _nicDao.listByVmId(profile.getId()); + for (Nic internalLbVmNic : internalLbVmNics) { + Network network = _ntwkModel.getNetwork(internalLbVmNic.getNetworkId()); + if (network.getTrafficType() == TrafficType.Guest) { + guestNetworks.add(network); + } + } + + answer = cmds.getAnswer("getDomRVersion"); + if (answer != null && answer instanceof GetDomRVersionAnswer) { + GetDomRVersionAnswer versionAnswer = (GetDomRVersionAnswer)answer; + if (answer == null || !answer.getResult()) { + s_logger.warn("Unable to get the template/scripts version of internal LB VM " + internalLbVm.getInstanceName() + + " due to: " + versionAnswer.getDetails()); + result = false; + } else { + internalLbVm.setTemplateVersion(versionAnswer.getTemplateVersion()); + internalLbVm.setScriptsVersion(versionAnswer.getScriptsVersion()); + internalLbVm = _internalLbVmDao.persist(internalLbVm, guestNetworks); + } + } else { + result = false; + } + + return result; + } + + @Override + public boolean finalizeCommandsOnStart(Commands cmds, VirtualMachineProfile profile) { + DomainRouterVO internalLbVm = profile.getVirtualMachine(); + NicProfile controlNic = getNicProfileByTrafficType(profile, TrafficType.Control); + + if (controlNic == null) { + s_logger.error("Control network doesn't exist for the internal LB vm " + internalLbVm); + return false; + } + + finalizeSshAndVersionOnStart(cmds, profile, internalLbVm, controlNic); + + // restart network if restartNetwork = false is not specified in profile parameters + boolean reprogramGuestNtwk = true; + if (profile.getParameter(Param.ReProgramGuestNetworks) != null + && (Boolean) profile.getParameter(Param.ReProgramGuestNetworks) == false) { + reprogramGuestNtwk = false; + } + + VirtualRouterProvider lbProvider = _vrProviderDao.findById(internalLbVm.getElementId()); + if (lbProvider == null) { + throw new CloudRuntimeException("Cannot find related element " + VirtualRouterProviderType.InternalLbVm + " of vm: " + internalLbVm.getHostName()); + } + + Provider provider = Network.Provider.getProvider(lbProvider.getType().toString()); + if (provider == null) { + throw new CloudRuntimeException("Cannot find related provider of provider: " + lbProvider.getType().toString()); + } + + if (reprogramGuestNtwk) { + NicProfile guestNic = getNicProfileByTrafficType(profile, TrafficType.Guest); + finalizeLbRulesForIp(cmds, internalLbVm, provider, new Ip(guestNic.getIp4Address()), guestNic.getNetworkId()); + } + + return true; + } + + @Override + public void finalizeStop(VirtualMachineProfile profile, StopAnswer answer) { + } + + @Override + public void finalizeExpunge(DomainRouterVO vm) { + } + + @Override + public Long convertToId(String vmName) { + if (!VirtualMachineName.isValidSystemVmName(vmName, _instance, _internalLbVmNamePrefix)) { + return null; + } + + return VirtualMachineName.getRouterId(vmName); + } + + @Override + public boolean plugNic(Network network, NicTO nic, VirtualMachineTO vm, ReservationContext context, DeployDestination dest) throws ConcurrentOperationException, ResourceUnavailableException, + InsufficientCapacityException { + //not supported + throw new UnsupportedOperationException("Plug nic is not supported for vm of type " + vm.getType()); + } + + @Override + public boolean unplugNic(Network network, NicTO nic, VirtualMachineTO vm, ReservationContext context, DeployDestination dest) throws ConcurrentOperationException, ResourceUnavailableException { + //not supported + throw new UnsupportedOperationException("Unplug nic is not supported for vm of type " + vm.getType()); + } + + @Override + public void prepareStop(VirtualMachineProfile profile) { + } + + @Override + public boolean configure(String name, Map params) throws ConfigurationException { + final Map configs = _configDao.getConfiguration("AgentManager", params); + _instance = configs.get("instance.name"); + if (_instance == null) { + _instance = "DEFAULT"; + } + + _mgmtHost = configs.get("host"); + _mgmtCidr = _configDao.getValue(Config.ManagementNetwork.key()); + + String offIdStr = configs.get(Config.InternalLbVmServiceOfferingId.key()); + if (offIdStr != null && !offIdStr.isEmpty()) { + _internalLbVmOfferingId = Long.parseLong(offIdStr); + } else { + boolean useLocalStorage = Boolean.parseBoolean(configs.get(Config.SystemVMUseLocalStorage.key())); + ServiceOfferingVO newOff = new ServiceOfferingVO("System Offering For Internal LB VM", 1, InternalLoadBalancerVMManager.DEFAULT_INTERNALLB_VM_RAMSIZE, InternalLoadBalancerVMManager.DEFAULT_INTERNALLB_VM_CPU_MHZ, null, + null, true, null, useLocalStorage, true, null, true, VirtualMachine.Type.InternalLoadBalancerVm, true); + newOff.setUniqueName(ServiceOffering.internalLbVmDefaultOffUniqueName); + newOff = _serviceOfferingDao.persistSystemServiceOffering(newOff); + _internalLbVmOfferingId = newOff.getId(); + } + + _itMgr.registerGuru(VirtualMachine.Type.InternalLoadBalancerVm, this); + + if (s_logger.isInfoEnabled()) { + s_logger.info(getName() + " has been configured"); + } + + return true; + } + + @Override + public String getName() { + return _name; + } + + protected NicProfile getNicProfileByTrafficType(VirtualMachineProfile profile, TrafficType trafficType) { + for (NicProfile nic : profile.getNics()) { + if (nic.getTrafficType() == trafficType && nic.getIp4Address() != null) { + return nic; + } + } + return null; + } + + protected void finalizeSshAndVersionOnStart(Commands cmds, VirtualMachineProfile profile, DomainRouterVO router, NicProfile controlNic) { + cmds.addCommand("checkSsh", new CheckSshCommand(profile.getInstanceName(), controlNic.getIp4Address(), 3922)); + + // Update internal lb vm template/scripts version + final GetDomRVersionCmd command = new GetDomRVersionCmd(); + command.setAccessDetail(NetworkElementCommand.ROUTER_IP, controlNic.getIp4Address()); + command.setAccessDetail(NetworkElementCommand.ROUTER_NAME, router.getInstanceName()); + cmds.addCommand("getDomRVersion", command); + } + + + protected void finalizeLbRulesForIp(Commands cmds, DomainRouterVO internalLbVm, Provider provider, Ip sourceIp, long guestNtwkId) { + s_logger.debug("Resending load balancing rules as a part of start for " + internalLbVm); + List lbs = _lbDao.listBySrcIpSrcNtwkId(sourceIp, guestNtwkId); + List lbRules = new ArrayList(); + if (_ntwkModel.isProviderSupportServiceInNetwork(guestNtwkId, Service.Lb, provider)) { + // Re-apply load balancing rules + for (ApplicationLoadBalancerRuleVO lb : lbs) { + List dstList = _lbMgr.getExistingDestinations(lb.getId()); + List policyList = _lbMgr.getStickinessPolicies(lb.getId()); + List hcPolicyList = _lbMgr.getHealthCheckPolicies(lb.getId()); + LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, dstList, policyList, hcPolicyList, sourceIp); + lbRules.add(loadBalancing); + } + } + + s_logger.debug("Found " + lbRules.size() + " load balancing rule(s) to apply as a part of Intenrnal LB vm" + internalLbVm + " start."); + if (!lbRules.isEmpty()) { + createApplyLoadBalancingRulesCommands(lbRules, internalLbVm, cmds, guestNtwkId); + } + } + + private void createApplyLoadBalancingRulesCommands(List rules, VirtualRouter internalLbVm, Commands cmds, long guestNetworkId) { + + LoadBalancerTO[] lbs = new LoadBalancerTO[rules.size()]; + int i = 0; + boolean inline = false; + for (LoadBalancingRule rule : rules) { + boolean revoked = (rule.getState().equals(FirewallRule.State.Revoke)); + String protocol = rule.getProtocol(); + String algorithm = rule.getAlgorithm(); + String uuid = rule.getUuid(); + + String srcIp = rule.getSourceIp().addr(); + int srcPort = rule.getSourcePortStart(); + List destinations = rule.getDestinations(); + List stickinessPolicies = rule.getStickinessPolicies(); + LoadBalancerTO lb = new LoadBalancerTO(uuid, srcIp, srcPort, protocol, algorithm, revoked, false, inline, destinations, stickinessPolicies); + lbs[i++] = lb; + } + + Network guestNetwork = _ntwkModel.getNetwork(guestNetworkId); + Nic guestNic = _nicDao.findByNtwkIdAndInstanceId(guestNetwork.getId(), internalLbVm.getId()); + NicProfile guestNicProfile = new NicProfile(guestNic, guestNetwork, guestNic.getBroadcastUri(), guestNic.getIsolationUri(), + _ntwkModel.getNetworkRate(guestNetwork.getId(), internalLbVm.getId()), + _ntwkModel.isSecurityGroupSupportedInNetwork(guestNetwork), + _ntwkModel.getNetworkTag(internalLbVm.getHypervisorType(), guestNetwork)); + + LoadBalancerConfigCommand cmd = new LoadBalancerConfigCommand(lbs, guestNic.getIp4Address(), + guestNic.getIp4Address(), internalLbVm.getPrivateIpAddress(), + _itMgr.toNicTO(guestNicProfile, internalLbVm.getHypervisorType()), internalLbVm.getVpcId()); + + cmd.lbStatsVisibility = _configDao.getValue(Config.NetworkLBHaproxyStatsVisbility.key()); + cmd.lbStatsUri = _configDao.getValue(Config.NetworkLBHaproxyStatsUri.key()); + cmd.lbStatsAuth = _configDao.getValue(Config.NetworkLBHaproxyStatsAuth.key()); + cmd.lbStatsPort = _configDao.getValue(Config.NetworkLBHaproxyStatsPort.key()); + + cmd.setAccessDetail(NetworkElementCommand.ROUTER_IP, getInternalLbControlIp(internalLbVm.getId())); + cmd.setAccessDetail(NetworkElementCommand.ROUTER_GUEST_IP, guestNic.getIp4Address()); + cmd.setAccessDetail(NetworkElementCommand.ROUTER_NAME, internalLbVm.getInstanceName()); + DataCenterVO dcVo = _dcDao.findById(internalLbVm.getDataCenterId()); + cmd.setAccessDetail(NetworkElementCommand.ZONE_NETWORK_TYPE, dcVo.getNetworkType().toString()); + cmds.addCommand(cmd); + } + + + protected String getInternalLbControlIp(long internalLbVmId) { + String controlIpAddress = null; + List nics = _nicDao.listByVmId(internalLbVmId); + for (NicVO nic : nics) { + Network ntwk = _ntwkModel.getNetwork(nic.getNetworkId()); + if (ntwk.getTrafficType() == TrafficType.Control) { + controlIpAddress = nic.getIp4Address(); + } + } + + if(controlIpAddress == null) { + s_logger.warn("Unable to find Internal LB control ip in its attached NICs!. Internal LB vm: " + internalLbVmId); + DomainRouterVO internalLbVm = _internalLbVmDao.findById(internalLbVmId); + return internalLbVm.getPrivateIpAddress(); + } + + return controlIpAddress; + } + + @Override + public boolean destroyInternalLbVm(long vmId, Account caller, Long callerUserId) + throws ResourceUnavailableException, ConcurrentOperationException { + if (s_logger.isDebugEnabled()) { + s_logger.debug("Attempting to destroy Internal LB vm " + vmId); + } + + DomainRouterVO internalLbVm = _internalLbVmDao.findById(vmId); + if (internalLbVm == null) { + return true; + } + + _accountMgr.checkAccess(caller, null, true, internalLbVm); + + return _itMgr.expunge(internalLbVm, _accountMgr.getActiveUser(callerUserId), caller); + } + + + @Override + public VirtualRouter stopInternalLbVm(long vmId, boolean forced, Account caller, long callerUserId) throws ConcurrentOperationException, + ResourceUnavailableException { + DomainRouterVO internalLbVm = _internalLbVmDao.findById(vmId); + if (internalLbVm == null || internalLbVm.getRole() != Role.INTERNAL_LB_VM) { + throw new InvalidParameterValueException("Can't find internal lb vm by id specified"); + } + + return stopInternalLbVm(internalLbVm, forced, caller, callerUserId); + } + + protected VirtualRouter stopInternalLbVm(DomainRouterVO internalLbVm, boolean forced, Account caller, long callerUserId) throws ResourceUnavailableException, ConcurrentOperationException { + s_logger.debug("Stopping internal lb vm " + internalLbVm); + try { + if (_itMgr.advanceStop((DomainRouterVO) internalLbVm, forced, _accountMgr.getActiveUser(callerUserId), caller)) { + return _internalLbVmDao.findById(internalLbVm.getId()); + } else { + return null; + } + } catch (OperationTimedoutException e) { + throw new CloudRuntimeException("Unable to stop " + internalLbVm, e); + } + } + + + @Override + public List deployInternalLbVm(Network guestNetwork, Ip requestedGuestIp, DeployDestination dest, + Account owner, Map params) throws InsufficientCapacityException, + ConcurrentOperationException, ResourceUnavailableException { + + List internalLbVms = findOrDeployInternalLbVm(guestNetwork, requestedGuestIp, dest, owner, params); + + return startInternalLbVms(params, internalLbVms); + } + + protected List startInternalLbVms(Map params, List internalLbVms) + throws StorageUnavailableException, InsufficientCapacityException, ConcurrentOperationException, ResourceUnavailableException { + List runningInternalLbVms = null; + + if (internalLbVms != null) { + runningInternalLbVms = new ArrayList(); + } else { + s_logger.debug("Have no internal lb vms to start"); + return null; + } + + for (DomainRouterVO internalLbVm : internalLbVms) { + if (internalLbVm.getState() != VirtualMachine.State.Running) { + internalLbVm = startInternalLbVm(internalLbVm, _accountMgr.getSystemAccount(), User.UID_SYSTEM, params); + } + + if (internalLbVm != null) { + runningInternalLbVms.add(internalLbVm); + } + } + return runningInternalLbVms; + } + + + + @DB + protected List findOrDeployInternalLbVm(Network guestNetwork, Ip requestedGuestIp, DeployDestination dest, + Account owner, Map params) throws ConcurrentOperationException, + InsufficientCapacityException, ResourceUnavailableException { + + List internalLbVms = new ArrayList(); + Network lock = _networkDao.acquireInLockTable(guestNetwork.getId(), _ntwkMgr.getNetworkLockTimeout()); + if (lock == null) { + throw new ConcurrentOperationException("Unable to lock network " + guestNetwork.getId()); + } + + if (s_logger.isDebugEnabled()) { + s_logger.debug("Lock is acquired for network id " + lock.getId() + " as a part of internal lb startup in " + dest); + } + + long internalLbProviderId = getInternalLbProviderId(guestNetwork); + + try { + assert guestNetwork.getState() == Network.State.Implemented || guestNetwork.getState() == Network.State.Setup || + guestNetwork.getState() == Network.State.Implementing : "Network is not yet fully implemented: " + + guestNetwork; + assert guestNetwork.getTrafficType() == TrafficType.Guest; + + //deploy internal lb vm + Pair> planAndInternalLbVms = getDeploymentPlanAndInternalLbVms(dest, guestNetwork.getId(), requestedGuestIp); + internalLbVms = planAndInternalLbVms.second(); + DeploymentPlan plan = planAndInternalLbVms.first(); + + if (internalLbVms.size() > 0) { + s_logger.debug("Found " + internalLbVms.size() + " internal lb vms for the requested IP " + requestedGuestIp.addr()); + return internalLbVms; + } + + List> networks = createInternalLbVmNetworks(guestNetwork, plan, requestedGuestIp); + //Pass startVm=false as we are holding the network lock that needs to be released at the end of vm allocation + DomainRouterVO internalLbVm = deployInternalLbVm(owner, dest, plan, params, internalLbProviderId, _internalLbVmOfferingId, guestNetwork.getVpcId(), + networks, false); + if (internalLbVm != null) { + _internalLbVmDao.addRouterToGuestNetwork(internalLbVm, guestNetwork); + internalLbVms.add(internalLbVm); + } + } finally { + if (lock != null) { + _networkDao.releaseFromLockTable(lock.getId()); + if (s_logger.isDebugEnabled()) { + s_logger.debug("Lock is released for network id " + lock.getId() + " as a part of internal lb vm startup in " + dest); + } + } + } + return internalLbVms; + } + + protected long getInternalLbProviderId(Network guestNetwork) { + VirtualRouterProviderType type = VirtualRouterProviderType.InternalLbVm; + long physicalNetworkId = _ntwkModel.getPhysicalNetworkId(guestNetwork); + + PhysicalNetworkServiceProvider provider = _physicalProviderDao.findByServiceProvider(physicalNetworkId, type.toString()); + if (provider == null) { + throw new CloudRuntimeException("Cannot find service provider " + type.toString() + " in physical network " + physicalNetworkId); + } + + VirtualRouterProvider internalLbProvider = _vrProviderDao.findByNspIdAndType(provider.getId(), type); + if (internalLbProvider == null) { + throw new CloudRuntimeException("Cannot find provider " + type.toString() + " as service provider " + provider.getId()); + } + + return internalLbProvider.getId(); + } + + protected List> createInternalLbVmNetworks(Network guestNetwork, DeploymentPlan plan, Ip guestIp) throws ConcurrentOperationException, + InsufficientAddressCapacityException { + + //Form networks + List> networks = new ArrayList>(3); + + //1) Guest network - default + if (guestNetwork != null) { + s_logger.debug("Adding nic for Internal LB in Guest network " + guestNetwork); + NicProfile guestNic = new NicProfile(); + if (guestIp != null) { + guestNic.setIp4Address(guestIp.addr()); + } else { + guestNic.setIp4Address(_ntwkMgr.acquireGuestIpAddress(guestNetwork, null)); + } + guestNic.setGateway(guestNetwork.getGateway()); + guestNic.setBroadcastUri(guestNetwork.getBroadcastUri()); + guestNic.setBroadcastType(guestNetwork.getBroadcastDomainType()); + guestNic.setIsolationUri(guestNetwork.getBroadcastUri()); + guestNic.setMode(guestNetwork.getMode()); + String gatewayCidr = guestNetwork.getCidr(); + guestNic.setNetmask(NetUtils.getCidrNetmask(gatewayCidr)); + guestNic.setDefaultNic(true); + networks.add(new Pair((NetworkVO) guestNetwork, guestNic)); + } + + //2) Control network + s_logger.debug("Adding nic for Internal LB vm in Control network "); + List offerings = _ntwkModel.getSystemAccountNetworkOfferings(NetworkOffering.SystemControlNetwork); + NetworkOffering controlOffering = offerings.get(0); + NetworkVO controlConfig = _ntwkMgr.setupNetwork(_accountMgr.getSystemAccount(), controlOffering, plan, null, null, false).get(0); + networks.add(new Pair(controlConfig, null)); + + return networks; + } + + + protected Pair> getDeploymentPlanAndInternalLbVms(DeployDestination dest, long guestNetworkId, Ip requestedGuestIp) { + long dcId = dest.getDataCenter().getId(); + DeploymentPlan plan = new DataCenterDeployment(dcId); + List internalLbVms = findInternalLbVms(guestNetworkId, requestedGuestIp); + + return new Pair>(plan, internalLbVms); + + } + + @Override + public List findInternalLbVms(long guestNetworkId, Ip requestedGuestIp) { + List internalLbVms = _internalLbVmDao.listByNetworkAndRole(guestNetworkId, Role.INTERNAL_LB_VM); + if (requestedGuestIp != null && !internalLbVms.isEmpty()) { + Iterator it = internalLbVms.iterator(); + while (it.hasNext()) { + DomainRouterVO vm = it.next(); + Nic nic = _nicDao.findByNtwkIdAndInstanceId(guestNetworkId, vm.getId()); + if (!nic.getIp4Address().equalsIgnoreCase(requestedGuestIp.addr())) { + it.remove(); + } + } + } + return internalLbVms; + } + + + protected DomainRouterVO deployInternalLbVm(Account owner, DeployDestination dest, DeploymentPlan plan, Map params, + long internalLbProviderId, long svcOffId, Long vpcId, + List> networks, boolean startVm) throws ConcurrentOperationException, + InsufficientAddressCapacityException, InsufficientServerCapacityException, InsufficientCapacityException, + StorageUnavailableException, ResourceUnavailableException { + + long id = _internalLbVmDao.getNextInSequence(Long.class, "id"); + if (s_logger.isDebugEnabled()) { + s_logger.debug("Creating the internal lb vm " + id + " in datacenter " + dest.getDataCenter()); + } + + ServiceOfferingVO routerOffering = _serviceOfferingDao.findById(svcOffId); + + // Internal lb is the network element, we don't know the hypervisor type yet. + // Try to allocate the internal lb twice using diff hypervisors, and when failed both times, throw the exception up + List hypervisors = getHypervisors(dest, plan, null); + + int allocateRetry = 0; + int startRetry = 0; + DomainRouterVO internalLbVm = null; + for (Iterator iter = hypervisors.iterator(); iter.hasNext();) { + HypervisorType hType = iter.next(); + try { + s_logger.debug("Allocating the Internal lb with the hypervisor type " + hType); + String templateName = null; + switch (hType) { + case XenServer: + templateName = _configServer.getConfigValue(Config.RouterTemplateXen.key(), Config.ConfigurationParameterScope.zone.toString(), dest.getDataCenter().getId()); + break; + case KVM: + templateName = _configServer.getConfigValue(Config.RouterTemplateKVM.key(), Config.ConfigurationParameterScope.zone.toString(), dest.getDataCenter().getId()); + break; + case VMware: + templateName = _configServer.getConfigValue(Config.RouterTemplateVmware.key(), Config.ConfigurationParameterScope.zone.toString(), dest.getDataCenter().getId()); + break; + case Hyperv: + templateName = _configServer.getConfigValue(Config.RouterTemplateHyperv.key(), Config.ConfigurationParameterScope.zone.toString(), dest.getDataCenter().getId()); + break; + case LXC: + templateName = _configServer.getConfigValue(Config.RouterTemplateLXC.key(), Config.ConfigurationParameterScope.zone.toString(), dest.getDataCenter().getId()); + break; + default: break; + } + VMTemplateVO template = _templateDao.findRoutingTemplate(hType, templateName); + + if (template == null) { + s_logger.debug(hType + " won't support system vm, skip it"); + continue; + } + + internalLbVm = new DomainRouterVO(id, routerOffering.getId(), internalLbProviderId, + VirtualMachineName.getSystemVmName(id, _instance, _internalLbVmNamePrefix), template.getId(), template.getHypervisorType(), + template.getGuestOSId(), owner.getDomainId(), owner.getId(), false, 0, false, + RedundantState.UNKNOWN, false, false, VirtualMachine.Type.InternalLoadBalancerVm, vpcId); + internalLbVm.setRole(Role.INTERNAL_LB_VM); + internalLbVm = _itMgr.allocate(internalLbVm, template, routerOffering, networks, plan, null, owner); + } catch (InsufficientCapacityException ex) { + if (allocateRetry < 2 && iter.hasNext()) { + s_logger.debug("Failed to allocate the Internal lb vm with hypervisor type " + hType + ", retrying one more time"); + continue; + } else { + throw ex; + } + } finally { + allocateRetry++; + } + + if (startVm) { + try { + internalLbVm = startInternalLbVm(internalLbVm, _accountMgr.getSystemAccount(), User.UID_SYSTEM, params); + break; + } catch (InsufficientCapacityException ex) { + if (startRetry < 2 && iter.hasNext()) { + s_logger.debug("Failed to start the Internal lb vm " + internalLbVm + " with hypervisor type " + hType + ", " + + "destroying it and recreating one more time"); + // destroy the internal lb vm + destroyInternalLbVm(internalLbVm.getId(), _accountMgr.getSystemAccount(), User.UID_SYSTEM); + continue; + } else { + throw ex; + } + } finally { + startRetry++; + } + } else { + //return stopped internal lb vm + return internalLbVm; + } + } + return internalLbVm; + } + + + + protected DomainRouterVO startInternalLbVm(DomainRouterVO internalLbVm, Account caller, long callerUserId, Map params) + throws StorageUnavailableException, InsufficientCapacityException, + ConcurrentOperationException, ResourceUnavailableException { + s_logger.debug("Starting Internal LB VM " + internalLbVm); + if (_itMgr.start(internalLbVm, params, _accountMgr.getUserIncludingRemoved(callerUserId), caller, null) != null) { + if (internalLbVm.isStopPending()) { + s_logger.info("Clear the stop pending flag of Internal LB VM " + internalLbVm.getHostName() + " after start router successfully!"); + internalLbVm.setStopPending(false); + internalLbVm = _internalLbVmDao.persist(internalLbVm); + } + return _internalLbVmDao.findById(internalLbVm.getId()); + } else { + return null; + } + } + + + protected List getHypervisors(DeployDestination dest, DeploymentPlan plan, + List supportedHypervisors) throws InsufficientServerCapacityException { + List hypervisors = new ArrayList(); + + HypervisorType defaults = _resourceMgr.getDefaultHypervisor(dest.getDataCenter().getId()); + if (defaults != HypervisorType.None) { + hypervisors.add(defaults); + } else { + //if there is no default hypervisor, get it from the cluster + hypervisors = _resourceMgr.getSupportedHypervisorTypes(dest.getDataCenter().getId(), true, + plan.getPodId()); + } + + //keep only elements defined in supported hypervisors + StringBuilder hTypesStr = new StringBuilder(); + if (supportedHypervisors != null && !supportedHypervisors.isEmpty()) { + hypervisors.retainAll(supportedHypervisors); + for (HypervisorType hType : supportedHypervisors) { + hTypesStr.append(hType).append(" "); + } + } + + if (hypervisors.isEmpty()) { + throw new InsufficientServerCapacityException("Unable to create internal lb vm, " + + "there are no clusters in the zone ", DataCenter.class, dest.getDataCenter().getId()); + } + return hypervisors; + } + + @Override + public boolean applyLoadBalancingRules(Network network, final List rules, List internalLbVms) + throws ResourceUnavailableException { + if (rules == null || rules.isEmpty()) { + s_logger.debug("No lb rules to be applied for network " + network); + return true; + } + + //only one internal lb vm is supported per ip address at this time + if (internalLbVms == null || internalLbVms.isEmpty()) { + throw new CloudRuntimeException("Can't apply the lb rules on network " + network + " as the list of internal lb vms is empty"); + } + + VirtualRouter lbVm = internalLbVms.get(0); + if (lbVm.getState() == State.Running) { + return sendLBRules(lbVm, rules, network.getId()); + } else if (lbVm.getState() == State.Stopped || lbVm.getState() == State.Stopping) { + s_logger.debug("Internal LB VM " + lbVm.getInstanceName() + " is in " + lbVm.getState() + + ", so not sending apply lb rules commands to the backend"); + return true; + } else { + s_logger.warn("Unable to apply lb rules, Internal LB VM is not in the right state " + lbVm.getState()); + throw new ResourceUnavailableException("Unable to apply lb rules; Internal LB VM is not in the right state", DataCenter.class, lbVm.getDataCenterId()); + } + } + + protected boolean sendLBRules(VirtualRouter internalLbVm, List rules, long guestNetworkId) throws ResourceUnavailableException { + Commands cmds = new Commands(OnError.Continue); + createApplyLoadBalancingRulesCommands(rules, internalLbVm, cmds, guestNetworkId); + return sendCommandsToInternalLbVm(internalLbVm, cmds); + } + + + protected boolean sendCommandsToInternalLbVm(final VirtualRouter internalLbVm, Commands cmds) throws AgentUnavailableException { + Answer[] answers = null; + try { + answers = _agentMgr.send(internalLbVm.getHostId(), cmds); + } catch (OperationTimedoutException e) { + s_logger.warn("Timed Out", e); + throw new AgentUnavailableException("Unable to send commands to virtual router ", internalLbVm.getHostId(), e); + } + + if (answers == null) { + return false; + } + + if (answers.length != cmds.size()) { + return false; + } + + boolean result = true; + if (answers.length > 0) { + for (Answer answer : answers) { + if (!answer.getResult()) { + result = false; + break; + } + } + } + return result; + } + + + @Override + public VirtualRouter startInternalLbVm(long internalLbVmId, Account caller, long callerUserId) + throws StorageUnavailableException, InsufficientCapacityException, + ConcurrentOperationException, ResourceUnavailableException { + + DomainRouterVO internalLbVm = _internalLbVmDao.findById(internalLbVmId); + if (internalLbVm == null || internalLbVm.getRole() != Role.INTERNAL_LB_VM) { + throw new InvalidParameterValueException("Can't find internal lb vm by id specified"); + } + + return startInternalLbVm(internalLbVm, caller, callerUserId, null); + } +} diff --git a/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbelement/ElementChildTestConfiguration.java b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbelement/ElementChildTestConfiguration.java new file mode 100644 index 00000000000..8a67e84f951 --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbelement/ElementChildTestConfiguration.java @@ -0,0 +1,125 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.internallbelement; + +import java.io.IOException; + +import org.apache.cloudstack.lb.dao.ApplicationLoadBalancerRuleDao; +import org.apache.cloudstack.network.lb.InternalLoadBalancerVMManager; +import org.apache.cloudstack.test.utils.SpringUtils; +import org.mockito.Mockito; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.ComponentScan; +import org.springframework.context.annotation.ComponentScan.Filter; +import org.springframework.context.annotation.Configuration; +import org.springframework.context.annotation.FilterType; +import org.springframework.core.type.classreading.MetadataReader; +import org.springframework.core.type.classreading.MetadataReaderFactory; +import org.springframework.core.type.filter.TypeFilter; + +import com.cloud.configuration.ConfigurationManager; +import com.cloud.dc.dao.AccountVlanMapDaoImpl; +import com.cloud.dc.dao.DataCenterDao; +import com.cloud.network.NetworkManager; +import com.cloud.network.NetworkModel; +import com.cloud.network.dao.NetworkServiceMapDao; +import com.cloud.network.dao.PhysicalNetworkServiceProviderDao; +import com.cloud.network.dao.VirtualRouterProviderDao; +import com.cloud.user.AccountManager; +import com.cloud.utils.net.NetUtils; +import com.cloud.vm.dao.DomainRouterDao; + +@Configuration +@ComponentScan( + basePackageClasses={ + NetUtils.class, + }, + includeFilters={@Filter(value=ElementChildTestConfiguration.Library.class, type=FilterType.CUSTOM)}, + useDefaultFilters=false + ) + +public class ElementChildTestConfiguration { + public static class Library implements TypeFilter { + @Bean + public AccountManager accountManager() { + return Mockito.mock(AccountManager.class); + } + + + @Bean + public DomainRouterDao domainRouterDao() { + return Mockito.mock(DomainRouterDao.class); + } + + @Bean + public VirtualRouterProviderDao virtualRouterProviderDao() { + return Mockito.mock(VirtualRouterProviderDao.class); + } + + @Bean + public NetworkModel networkModel() { + return Mockito.mock(NetworkModel.class); + } + + + @Bean + public NetworkManager networkManager() { + return Mockito.mock(NetworkManager.class); + } + + + @Bean + public PhysicalNetworkServiceProviderDao physicalNetworkServiceProviderDao() { + return Mockito.mock(PhysicalNetworkServiceProviderDao.class); + } + + @Bean + public NetworkServiceMapDao networkServiceMapDao() { + return Mockito.mock(NetworkServiceMapDao.class); + } + + @Bean + public InternalLoadBalancerVMManager internalLoadBalancerVMManager() { + return Mockito.mock(InternalLoadBalancerVMManager.class); + } + + @Bean + public ConfigurationManager confugurationManager() { + return Mockito.mock(ConfigurationManager.class); + } + + + @Bean + public ApplicationLoadBalancerRuleDao applicationLoadBalancerRuleDao() { + return Mockito.mock(ApplicationLoadBalancerRuleDao.class); + } + + @Bean + public DataCenterDao dataCenterDao() { + return Mockito.mock(DataCenterDao.class); + } + + + + @Override + public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { + mdr.getClassMetadata().getClassName(); + ComponentScan cs = ElementChildTestConfiguration.class.getAnnotation(ComponentScan.class); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + } + } +} diff --git a/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbelement/InternalLbElementServiceTest.java b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbelement/InternalLbElementServiceTest.java new file mode 100644 index 00000000000..bdc50cafb8c --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbelement/InternalLbElementServiceTest.java @@ -0,0 +1,189 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.internallbelement; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertNotNull; +import static org.junit.Assert.assertTrue; + +import javax.inject.Inject; + +import org.apache.cloudstack.network.element.InternalLoadBalancerElementService; +import org.junit.Before; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.mockito.Mockito; +import org.springframework.test.context.ContextConfiguration; +import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; + +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.network.VirtualRouterProvider; +import com.cloud.network.VirtualRouterProvider.VirtualRouterProviderType; +import com.cloud.network.dao.PhysicalNetworkServiceProviderDao; +import com.cloud.network.dao.PhysicalNetworkServiceProviderVO; +import com.cloud.network.dao.VirtualRouterProviderDao; +import com.cloud.network.element.VirtualRouterProviderVO; +import com.cloud.user.AccountManager; +import com.cloud.utils.component.ComponentContext; + +@RunWith(SpringJUnit4ClassRunner.class) +@ContextConfiguration(locations="classpath:/lb_element.xml") +public class InternalLbElementServiceTest { + //The interface to test + @Inject InternalLoadBalancerElementService _lbElSvc; + + //Mocked interfaces + @Inject AccountManager _accountMgr; + @Inject VirtualRouterProviderDao _vrProviderDao; + @Inject PhysicalNetworkServiceProviderDao _pNtwkProviderDao; + + long validElId = 1L; + long nonExistingElId = 2L; + long invalidElId = 3L; //not of VirtualRouterProviderType + + long validProviderId = 1L; + long nonExistingProviderId = 2L; + long invalidProviderId = 3L; + + + @Before + public void setUp() { + + ComponentContext.initComponentsLifeCycle(); + VirtualRouterProviderVO validElement = new VirtualRouterProviderVO(1, VirtualRouterProviderType.InternalLbVm); + VirtualRouterProviderVO invalidElement = new VirtualRouterProviderVO(1, VirtualRouterProviderType.VirtualRouter); + + Mockito.when(_vrProviderDao.findById(validElId)).thenReturn(validElement); + Mockito.when(_vrProviderDao.findById(invalidElId)).thenReturn(invalidElement); + + Mockito.when(_vrProviderDao.persist(validElement)).thenReturn(validElement); + + Mockito.when(_vrProviderDao.findByNspIdAndType(validProviderId, VirtualRouterProviderType.InternalLbVm)).thenReturn(validElement); + + PhysicalNetworkServiceProviderVO validProvider = new PhysicalNetworkServiceProviderVO(1, "InternalLoadBalancerElement"); + PhysicalNetworkServiceProviderVO invalidProvider = new PhysicalNetworkServiceProviderVO(1, "Invalid name!"); + + Mockito.when(_pNtwkProviderDao.findById(validProviderId)).thenReturn(validProvider); + Mockito.when(_pNtwkProviderDao.findById(invalidProviderId)).thenReturn(invalidProvider); + + Mockito.when(_vrProviderDao.persist(Mockito.any(VirtualRouterProviderVO.class))).thenReturn(validElement); + } + + //TESTS FOR getInternalLoadBalancerElement METHOD + + + @Test (expected = InvalidParameterValueException.class) + public void findNonExistingVm() { + String expectedExcText = null; + try { + _lbElSvc.getInternalLoadBalancerElement(nonExistingElId); + } catch (InvalidParameterValueException e) { + expectedExcText = e.getMessage(); + throw e; + } finally { + assertEquals("Test failed. The non-existing intenral lb provider was found" + + expectedExcText, expectedExcText, "Unable to find InternalLoadBalancerElementService by id"); + } + } + + + @Test (expected = InvalidParameterValueException.class) + public void findInvalidVm() { + String expectedExcText = null; + try { + _lbElSvc.getInternalLoadBalancerElement(invalidElId); + } catch (InvalidParameterValueException e) { + expectedExcText = e.getMessage(); + throw e; + } finally { + assertEquals("Test failed. The non-existing intenral lb provider was found" + + expectedExcText, expectedExcText, "Unable to find InternalLoadBalancerElementService by id"); + } + } + + + @Test + public void findValidVm() { + VirtualRouterProvider provider = null; + try { + provider = _lbElSvc.getInternalLoadBalancerElement(validElId); + } finally { + assertNotNull("Test failed. Couldn't find the VR provider by the valid id",provider); + } + } + + + //TESTS FOR configureInternalLoadBalancerElement METHOD + + @Test (expected = InvalidParameterValueException.class) + public void configureNonExistingVm() { + + _lbElSvc.configureInternalLoadBalancerElement(nonExistingElId, true); + + } + + + @Test (expected = InvalidParameterValueException.class) + public void ConfigureInvalidVm() { + _lbElSvc.configureInternalLoadBalancerElement(invalidElId, true); + } + + + @Test + public void enableProvider() { + VirtualRouterProvider provider = null; + try { + provider = _lbElSvc.configureInternalLoadBalancerElement(validElId, true); + } finally { + assertNotNull("Test failed. Couldn't find the VR provider by the valid id ",provider); + assertTrue("Test failed. The provider wasn't eanbled ", provider.isEnabled()); + } + } + + @Test + public void disableProvider() { + VirtualRouterProvider provider = null; + try { + provider = _lbElSvc.configureInternalLoadBalancerElement(validElId, false); + } finally { + assertNotNull("Test failed. Couldn't find the VR provider by the valid id ",provider); + assertFalse("Test failed. The provider wasn't disabled ", provider.isEnabled()); + } + } + + //TESTS FOR addInternalLoadBalancerElement METHOD + + @Test (expected = InvalidParameterValueException.class) + public void addToNonExistingProvider() { + + _lbElSvc.addInternalLoadBalancerElement(nonExistingProviderId); + + } + + public void addToInvalidProvider() { + _lbElSvc.addInternalLoadBalancerElement(invalidProviderId); + } + + @Test + public void addToExistingProvider() { + _lbElSvc.addInternalLoadBalancerElement(validProviderId); + } + +} + + diff --git a/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbelement/InternalLbElementTest.java b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbelement/InternalLbElementTest.java new file mode 100644 index 00000000000..f19612f6b0f --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbelement/InternalLbElementTest.java @@ -0,0 +1,226 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.internallbelement; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertNull; +import static org.junit.Assert.assertTrue; + +import java.lang.reflect.Field; +import java.util.ArrayList; +import java.util.HashSet; +import java.util.List; + +import javax.inject.Inject; + +import org.apache.cloudstack.lb.ApplicationLoadBalancerRuleVO; +import org.apache.cloudstack.network.element.InternalLoadBalancerElement; +import org.apache.cloudstack.network.lb.InternalLoadBalancerVMManager; +import org.junit.Before; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.mockito.Mockito; +import org.springframework.test.context.ContextConfiguration; +import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; + +import com.cloud.agent.api.to.LoadBalancerTO; +import com.cloud.configuration.ConfigurationManager; +import com.cloud.dc.DataCenter.NetworkType; +import com.cloud.dc.DataCenterVO; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.Network.Provider; +import com.cloud.network.Network.Service; +import com.cloud.network.VirtualRouterProvider.VirtualRouterProviderType; +import com.cloud.network.addr.PublicIp; +import com.cloud.network.dao.NetworkVO; +import com.cloud.network.dao.PhysicalNetworkServiceProviderDao; +import com.cloud.network.dao.PhysicalNetworkServiceProviderVO; +import com.cloud.network.dao.VirtualRouterProviderDao; +import com.cloud.network.element.VirtualRouterProviderVO; +import com.cloud.network.lb.LoadBalancingRule; +import com.cloud.network.rules.FirewallRule; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.user.AccountManager; +import com.cloud.utils.component.ComponentContext; +import com.cloud.utils.net.Ip; + +@RunWith(SpringJUnit4ClassRunner.class) +@ContextConfiguration(locations="classpath:/lb_element.xml") +public class InternalLbElementTest { + //The class to test + @Inject InternalLoadBalancerElement _lbEl; + + //Mocked interfaces + @Inject AccountManager _accountMgr; + @Inject VirtualRouterProviderDao _vrProviderDao; + @Inject PhysicalNetworkServiceProviderDao _pNtwkProviderDao; + @Inject InternalLoadBalancerVMManager _internalLbMgr; + @Inject ConfigurationManager _configMgr; + + long validElId = 1L; + long nonExistingElId = 2L; + long invalidElId = 3L; //not of VirtualRouterProviderType + long notEnabledElId = 4L; + + long validProviderId = 1L; + long nonExistingProviderId = 2L; + long invalidProviderId = 3L; + + + @Before + public void setUp() { + + ComponentContext.initComponentsLifeCycle(); + VirtualRouterProviderVO validElement = new VirtualRouterProviderVO(1, VirtualRouterProviderType.InternalLbVm); + validElement.setEnabled(true); + VirtualRouterProviderVO invalidElement = new VirtualRouterProviderVO(1, VirtualRouterProviderType.VirtualRouter); + VirtualRouterProviderVO notEnabledElement = new VirtualRouterProviderVO(1, VirtualRouterProviderType.InternalLbVm); + + Mockito.when(_vrProviderDao.findByNspIdAndType(validElId, VirtualRouterProviderType.InternalLbVm)).thenReturn(validElement); + Mockito.when(_vrProviderDao.findByNspIdAndType(invalidElId, VirtualRouterProviderType.InternalLbVm)).thenReturn(invalidElement); + Mockito.when(_vrProviderDao.findByNspIdAndType(notEnabledElId, VirtualRouterProviderType.InternalLbVm)).thenReturn(notEnabledElement); + + Mockito.when(_vrProviderDao.persist(validElement)).thenReturn(validElement); + + Mockito.when(_vrProviderDao.findByNspIdAndType(validProviderId, VirtualRouterProviderType.InternalLbVm)).thenReturn(validElement); + + PhysicalNetworkServiceProviderVO validProvider = new PhysicalNetworkServiceProviderVO(1, "InternalLoadBalancerElement"); + PhysicalNetworkServiceProviderVO invalidProvider = new PhysicalNetworkServiceProviderVO(1, "Invalid name!"); + + Mockito.when(_pNtwkProviderDao.findById(validProviderId)).thenReturn(validProvider); + Mockito.when(_pNtwkProviderDao.findById(invalidProviderId)).thenReturn(invalidProvider); + + Mockito.when(_vrProviderDao.persist(Mockito.any(VirtualRouterProviderVO.class))).thenReturn(validElement); + + DataCenterVO dc = new DataCenterVO + (1L, null, null, null, null, null, null, null, null, null, NetworkType.Advanced, null, null); + Mockito.when(_configMgr.getZone(Mockito.anyLong())).thenReturn(dc); + } + + //TEST FOR getProvider() method + + @Test + public void verifyProviderName() { + Provider pr = _lbEl.getProvider(); + assertEquals("Wrong provider is returned", pr.getName(), Provider.InternalLbVm.getName()); + } + + //TEST FOR isReady() METHOD + + @Test + public void verifyValidProviderState() { + PhysicalNetworkServiceProviderVO provider = new PhysicalNetworkServiceProviderVO(); + provider = setId(provider, validElId); + boolean isReady = _lbEl.isReady(provider); + assertTrue("Valid provider is returned as not ready", isReady); + } + + + @Test + public void verifyNonExistingProviderState() { + PhysicalNetworkServiceProviderVO provider = new PhysicalNetworkServiceProviderVO(); + provider = setId(provider, nonExistingElId); + boolean isReady = _lbEl.isReady(provider); + assertFalse("Non existing provider is returned as ready", isReady); + } + + + @Test + public void verifyInvalidProviderState() { + PhysicalNetworkServiceProviderVO provider = new PhysicalNetworkServiceProviderVO(); + provider = setId(provider, invalidElId); + boolean isReady = _lbEl.isReady(provider); + assertFalse("Not valid provider is returned as ready", isReady); + } + + @Test + public void verifyNotEnabledProviderState() { + PhysicalNetworkServiceProviderVO provider = new PhysicalNetworkServiceProviderVO(); + provider = setId(provider, notEnabledElId); + boolean isReady = _lbEl.isReady(provider); + assertFalse("Not enabled provider is returned as ready", isReady); + } + + //TEST FOR canEnableIndividualServices METHOD + @Test + public void verifyCanEnableIndividualSvc() { + boolean result = _lbEl.canEnableIndividualServices(); + assertTrue("Wrong value is returned by canEnableIndividualSvc", result); + } + + //TEST FOR verifyServicesCombination METHOD + @Test + public void verifyServicesCombination() { + boolean result = _lbEl.verifyServicesCombination(new HashSet()); + assertTrue("Wrong value is returned by verifyServicesCombination", result); + } + + + //TEST FOR applyIps METHOD + @Test + public void verifyApplyIps() throws ResourceUnavailableException { + List ips = new ArrayList(); + boolean result = _lbEl.applyIps(new NetworkVO(), ips, new HashSet()); + assertTrue("Wrong value is returned by applyIps method", result); + } + + + //TEST FOR updateHealthChecks METHOD + @Test + public void verifyUpdateHealthChecks() throws ResourceUnavailableException { + List check = _lbEl.updateHealthChecks(new NetworkVO(), new ArrayList()); + assertNull("Wrong value is returned by updateHealthChecks method", check); + } + + //TEST FOR validateLBRule METHOD + @Test + public void verifyValidateLBRule() throws ResourceUnavailableException { + ApplicationLoadBalancerRuleVO lb = new ApplicationLoadBalancerRuleVO(null, null, 22, 22, "roundrobin", + 1L, 1L, 1L, new Ip("10.10.10.1"), 1L, Scheme.Internal); + lb.setState(FirewallRule.State.Add); + + LoadBalancingRule rule = new LoadBalancingRule(lb, null, + null, null, new Ip("10.10.10.1")); + + + boolean result = _lbEl.validateLBRule(new NetworkVO(), rule); + assertTrue("Wrong value is returned by validateLBRule method", result); + } + + + private static PhysicalNetworkServiceProviderVO setId(PhysicalNetworkServiceProviderVO vo, long id) { + PhysicalNetworkServiceProviderVO voToReturn = vo; + Class c = voToReturn.getClass(); + try { + Field f = c.getDeclaredField("id"); + f.setAccessible(true); + f.setLong(voToReturn, id); + } catch (NoSuchFieldException ex) { + return null; + } catch (IllegalAccessException ex) { + return null; + } + + return voToReturn; + } + + + +} + + diff --git a/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbvmmgr/InternalLBVMManagerTest.java b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbvmmgr/InternalLBVMManagerTest.java new file mode 100644 index 00000000000..a19a82e30c1 --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbvmmgr/InternalLBVMManagerTest.java @@ -0,0 +1,388 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.internallbvmmgr; + +import java.lang.reflect.Field; +import java.net.URI; +import java.net.URISyntaxException; +import java.util.ArrayList; +import java.util.List; + +import javax.inject.Inject; + +import junit.framework.TestCase; + +import org.apache.cloudstack.lb.ApplicationLoadBalancerRuleVO; +import org.apache.cloudstack.network.lb.InternalLoadBalancerVMManager; +import org.junit.Before; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.mockito.Mockito; +import org.springframework.test.context.ContextConfiguration; +import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; + +import com.cloud.agent.AgentManager; +import com.cloud.agent.api.Answer; +import com.cloud.agent.manager.Commands; +import com.cloud.dc.DataCenter.NetworkType; +import com.cloud.dc.DataCenterVO; +import com.cloud.dc.dao.DataCenterDao; +import com.cloud.exception.AgentUnavailableException; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.OperationTimedoutException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.hypervisor.Hypervisor.HypervisorType; +import com.cloud.network.NetworkModel; +import com.cloud.network.dao.NetworkVO; +import com.cloud.network.lb.LoadBalancingRule; +import com.cloud.network.router.VirtualRouter; +import com.cloud.network.router.VirtualRouter.Role; +import com.cloud.network.rules.FirewallRule; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.service.ServiceOfferingVO; +import com.cloud.service.dao.ServiceOfferingDao; +import com.cloud.user.Account; +import com.cloud.user.AccountManager; +import com.cloud.user.AccountVO; +import com.cloud.user.User; +import com.cloud.utils.component.ComponentContext; +import com.cloud.utils.exception.CloudRuntimeException; +import com.cloud.utils.net.Ip; +import com.cloud.vm.DomainRouterVO; +import com.cloud.vm.NicProfile; +import com.cloud.vm.NicVO; +import com.cloud.vm.VirtualMachine; +import com.cloud.vm.VirtualMachine.State; +import com.cloud.vm.VirtualMachineManager; +import com.cloud.vm.dao.DomainRouterDao; +import com.cloud.vm.dao.NicDao; + +/** + * Set of unittests for InternalLoadBalancerVMManager + * + */ + +@RunWith(SpringJUnit4ClassRunner.class) +@ContextConfiguration(locations="classpath:/lb_mgr.xml") +public class InternalLBVMManagerTest extends TestCase { + //The interface to test + @Inject InternalLoadBalancerVMManager _lbVmMgr; + + //Mocked interfaces + @Inject AccountManager _accountMgr; + @Inject ServiceOfferingDao _svcOffDao; + @Inject DomainRouterDao _domainRouterDao; + @Inject NicDao _nicDao; + @Inject AgentManager _agentMgr; + @Inject NetworkModel _ntwkModel; + @Inject VirtualMachineManager _itMgr; + @Inject DataCenterDao _dcDao; + + long validNtwkId = 1L; + long invalidNtwkId = 2L; + String requestedIp = "10.1.1.1"; + DomainRouterVO vm = null; + NetworkVO ntwk = createNetwork(); + long validVmId = 1L; + long invalidVmId = 2L; + + @Before + public void setUp() { + //mock system offering creation as it's used by configure() method called by initComponentsLifeCycle + Mockito.when(_accountMgr.getAccount(1L)).thenReturn(new AccountVO()); + ServiceOfferingVO off = new ServiceOfferingVO("alena", 1, 1, + 1, 1, 1, false, "alena", false, false, null, false, VirtualMachine.Type.InternalLoadBalancerVm, false); + off = setId(off, 1); + Mockito.when(_svcOffDao.persistSystemServiceOffering(Mockito.any(ServiceOfferingVO.class))).thenReturn(off); + + ComponentContext.initComponentsLifeCycle(); + + vm = new DomainRouterVO(1L,off.getId(),1,"alena",1,HypervisorType.XenServer,1,1,1, + false, 0,false,null,false,false, + VirtualMachine.Type.InternalLoadBalancerVm, null); + vm.setRole(Role.INTERNAL_LB_VM); + vm = setId(vm, 1); + vm.setPrivateIpAddress("10.2.2.2"); + NicVO nic = new NicVO("somereserver", 1L, 1L, VirtualMachine.Type.InternalLoadBalancerVm); + nic.setIp4Address(requestedIp); + + List emptyList = new ArrayList(); + List nonEmptyList = new ArrayList(); + nonEmptyList.add(vm); + + Mockito.when(_domainRouterDao.listByNetworkAndRole(invalidNtwkId, Role.INTERNAL_LB_VM)).thenReturn(emptyList); + Mockito.when(_domainRouterDao.listByNetworkAndRole(validNtwkId, Role.INTERNAL_LB_VM)).thenReturn(nonEmptyList); + + Mockito.when(_nicDao.findByNtwkIdAndInstanceId(validNtwkId, 1)).thenReturn(nic); + Mockito.when(_nicDao.findByNtwkIdAndInstanceId(invalidNtwkId, 1)).thenReturn(nic); + + Answer answer= new Answer(null, true, null); + Answer[] answers = new Answer[1]; + answers[0] = answer; + + try { + Mockito.when(_agentMgr.send(Mockito.anyLong(), Mockito.any(Commands.class))).thenReturn(answers); + } catch (AgentUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (OperationTimedoutException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + + createNetwork(); + Mockito.when(_ntwkModel.getNetwork(Mockito.anyLong())).thenReturn(ntwk); + + + Mockito.when(_itMgr.toNicTO(Mockito.any(NicProfile.class), Mockito.any(HypervisorType.class))).thenReturn(null); + Mockito.when(_domainRouterDao.findById(Mockito.anyLong())).thenReturn(vm); + DataCenterVO dc = new DataCenterVO + (1L, null, null, null, null, null, null, null, null, null, NetworkType.Advanced, null, null); + Mockito.when(_dcDao.findById(Mockito.anyLong())).thenReturn(dc); + + + try { + Mockito.when(_itMgr.expunge(Mockito.any(DomainRouterVO.class), Mockito.any(User.class), Mockito.any(Account.class))).thenReturn(true); + } catch (ResourceUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + + Mockito.when(_domainRouterDao.findById(validVmId)).thenReturn(vm); + Mockito.when(_domainRouterDao.findById(invalidVmId)).thenReturn(null); + + } + + protected NetworkVO createNetwork() { + ntwk = new NetworkVO(); + try { + ntwk.setBroadcastUri(new URI("somevlan")); + } catch (URISyntaxException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + ntwk = setId(ntwk, 1L); + return ntwk; + } + + //TESTS FOR findInternalLbVms METHOD + + @Test + public void findInternalLbVmsForInvalidNetwork() { + List vms = _lbVmMgr.findInternalLbVms(invalidNtwkId, new Ip(requestedIp)); + assertTrue("Non empty vm list was returned for invalid network id", vms.isEmpty()); + } + + @Test + public void findInternalLbVmsForValidNetwork() { + List vms = _lbVmMgr.findInternalLbVms(validNtwkId, new Ip(requestedIp)); + assertTrue("Empty vm list was returned for valid network id", !vms.isEmpty()); + } + + + //TESTS FOR applyLoadBalancingRules METHOD + @Test + public void applyEmptyRulesSet() { + boolean result = false; + List vms = new ArrayList(); + try { + result = _lbVmMgr.applyLoadBalancingRules(new NetworkVO(), new ArrayList(), vms); + } catch (ResourceUnavailableException e) { + + } finally { + assertTrue("Got failure when tried to apply empty list of rules", result); + } + } + + @Test (expected = CloudRuntimeException.class) + public void applyWithEmptyVmsSet() { + boolean result = false; + List vms = new ArrayList(); + List rules = new ArrayList(); + LoadBalancingRule rule = new LoadBalancingRule(null, null, + null, null, null); + + rules.add(rule); + try { + result = _lbVmMgr.applyLoadBalancingRules(new NetworkVO(), rules, vms); + } catch (ResourceUnavailableException e) { + } finally { + assertFalse("Got success when tried to apply with the empty internal lb vm list", result); + } + } + + @Test (expected = ResourceUnavailableException.class) + public void applyToVmInStartingState() throws ResourceUnavailableException { + boolean result = false; + List vms = new ArrayList(); + vm.setState(State.Starting); + vms.add(vm); + + List rules = new ArrayList(); + LoadBalancingRule rule = new LoadBalancingRule(null, null, + null, null, null); + + rules.add(rule); + try { + result = _lbVmMgr.applyLoadBalancingRules(new NetworkVO(), rules, vms); + } finally { + assertFalse("Rules were applied to vm in Starting state", result); + } + } + + + @Test + public void applyToVmInStoppedState() throws ResourceUnavailableException { + boolean result = false; + List vms = new ArrayList(); + vm.setState(State.Stopped); + vms.add(vm); + + List rules = new ArrayList(); + LoadBalancingRule rule = new LoadBalancingRule(null, null, + null, null, null); + + rules.add(rule); + try { + result = _lbVmMgr.applyLoadBalancingRules(new NetworkVO(), rules, vms); + } finally { + assertTrue("Rules failed to apply to vm in Stopped state", result); + } + } + + + @Test + public void applyToVmInStoppingState() throws ResourceUnavailableException { + boolean result = false; + List vms = new ArrayList(); + vm.setState(State.Stopping); + vms.add(vm); + + List rules = new ArrayList(); + LoadBalancingRule rule = new LoadBalancingRule(null, null, + null, null, null); + + rules.add(rule); + try { + result = _lbVmMgr.applyLoadBalancingRules(new NetworkVO(), rules, vms); + } finally { + assertTrue("Rules failed to apply to vm in Stopping state", result); + } + } + + + @Test + public void applyToVmInRunningState() throws ResourceUnavailableException { + boolean result = false; + List vms = new ArrayList(); + vm.setState(State.Running); + vms.add(vm); + + List rules = new ArrayList(); + ApplicationLoadBalancerRuleVO lb = new ApplicationLoadBalancerRuleVO(null, null, 22, 22, "roundrobin", + 1L, 1L, 1L, new Ip(requestedIp), 1L, Scheme.Internal); + lb.setState(FirewallRule.State.Add); + + LoadBalancingRule rule = new LoadBalancingRule(lb, null, + null, null, new Ip(requestedIp)); + + rules.add(rule); + + ntwk.getId(); + + try { + result = _lbVmMgr.applyLoadBalancingRules(ntwk, rules, vms); + } finally { + assertTrue("Rules failed to apply to vm in Running state", result); + } + } + + + //TESTS FOR destroyInternalLbVm METHOD + @Test + public void destroyNonExistingVM() throws ResourceUnavailableException, ConcurrentOperationException { + boolean result = false; + + try { + result = _lbVmMgr.destroyInternalLbVm(invalidVmId, new AccountVO(), 1L); + } finally { + assertTrue("Failed to destroy non-existing vm", result); + } + } + + @Test + public void destroyExistingVM() throws ResourceUnavailableException, ConcurrentOperationException { + boolean result = false; + + try { + result = _lbVmMgr.destroyInternalLbVm(validVmId, new AccountVO(), 1L); + } finally { + assertTrue("Failed to destroy valid vm", result); + } + } + + + private static ServiceOfferingVO setId(ServiceOfferingVO vo, long id) { + ServiceOfferingVO voToReturn = vo; + Class c = voToReturn.getClass(); + try { + Field f = c.getSuperclass().getDeclaredField("id"); + f.setAccessible(true); + f.setLong(voToReturn, id); + } catch (NoSuchFieldException ex) { + return null; + } catch (IllegalAccessException ex) { + return null; + } + + return voToReturn; + } + + + private static NetworkVO setId(NetworkVO vo, long id) { + NetworkVO voToReturn = vo; + Class c = voToReturn.getClass(); + try { + Field f = c.getDeclaredField("id"); + f.setAccessible(true); + f.setLong(voToReturn, id); + } catch (NoSuchFieldException ex) { + return null; + } catch (IllegalAccessException ex) { + return null; + } + + return voToReturn; + } + + private static DomainRouterVO setId(DomainRouterVO vo, long id) { + DomainRouterVO voToReturn = vo; + Class c = voToReturn.getClass(); + try { + Field f = c.getSuperclass().getDeclaredField("id"); + f.setAccessible(true); + f.setLong(voToReturn, id); + } catch (NoSuchFieldException ex) { + return null; + } catch (IllegalAccessException ex) { + return null; + } + + return voToReturn; + } + +} diff --git a/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbvmmgr/InternalLBVMServiceTest.java b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbvmmgr/InternalLBVMServiceTest.java new file mode 100644 index 00000000000..75f54faf8f0 --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbvmmgr/InternalLBVMServiceTest.java @@ -0,0 +1,291 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.internallbvmmgr; + +import java.lang.reflect.Field; +import java.util.Map; + +import javax.inject.Inject; + +import junit.framework.TestCase; + +import org.apache.cloudstack.network.lb.InternalLoadBalancerVMService; +import org.junit.Before; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.mockito.Mockito; +import org.springframework.test.context.ContextConfiguration; +import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; + +import com.cloud.deploy.DeploymentPlan; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.OperationTimedoutException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.exception.StorageUnavailableException; +import com.cloud.hypervisor.Hypervisor.HypervisorType; +import com.cloud.network.router.VirtualRouter; +import com.cloud.network.router.VirtualRouter.Role; +import com.cloud.service.ServiceOfferingVO; +import com.cloud.service.dao.ServiceOfferingDao; +import com.cloud.user.Account; +import com.cloud.user.AccountManager; +import com.cloud.user.AccountVO; +import com.cloud.user.User; +import com.cloud.utils.component.ComponentContext; +import com.cloud.vm.DomainRouterVO; +import com.cloud.vm.VirtualMachine; +import com.cloud.vm.VirtualMachineManager; +import com.cloud.vm.dao.DomainRouterDao; + +/** + * Set of unittests for InternalLoadBalancerVMService + * + */ + +@RunWith(SpringJUnit4ClassRunner.class) +@ContextConfiguration(locations="classpath:/lb_svc.xml") +@SuppressWarnings("unchecked") +public class InternalLBVMServiceTest extends TestCase { + //The interface to test + @Inject InternalLoadBalancerVMService _lbVmSvc; + + //Mocked interfaces + @Inject AccountManager _accountMgr; + @Inject ServiceOfferingDao _svcOffDao; + @Inject DomainRouterDao _domainRouterDao; + @Inject VirtualMachineManager _itMgr; + + long validVmId = 1L; + long nonExistingVmId = 2L; + long nonInternalLbVmId = 3L; + + @Before + public void setUp() { + //mock system offering creation as it's used by configure() method called by initComponentsLifeCycle + Mockito.when(_accountMgr.getAccount(1L)).thenReturn(new AccountVO()); + ServiceOfferingVO off = new ServiceOfferingVO("alena", 1, 1, + 1, 1, 1, false, "alena", false, false, null, false, VirtualMachine.Type.InternalLoadBalancerVm, false); + off = setId(off, 1); + Mockito.when(_svcOffDao.persistSystemServiceOffering(Mockito.any(ServiceOfferingVO.class))).thenReturn(off); + + ComponentContext.initComponentsLifeCycle(); + + DomainRouterVO validVm = new DomainRouterVO(validVmId,off.getId(),1,"alena",1,HypervisorType.XenServer,1,1,1, + false, 0,false,null,false,false, + VirtualMachine.Type.InternalLoadBalancerVm, null); + validVm.setRole(Role.INTERNAL_LB_VM); + DomainRouterVO nonInternalLbVm = new DomainRouterVO(validVmId,off.getId(),1,"alena",1,HypervisorType.XenServer,1,1,1, + false, 0,false,null,false,false, + VirtualMachine.Type.DomainRouter, null); + nonInternalLbVm.setRole(Role.VIRTUAL_ROUTER); + + Mockito.when(_domainRouterDao.findById(validVmId)).thenReturn(validVm); + Mockito.when(_domainRouterDao.findById(nonExistingVmId)).thenReturn(null); + Mockito.when(_domainRouterDao.findById(nonInternalLbVmId)).thenReturn(nonInternalLbVm); + + try { + Mockito.when(_itMgr.start(Mockito.any(DomainRouterVO.class), + Mockito.any(Map.class), Mockito.any(User.class), Mockito.any(Account.class), Mockito.any(DeploymentPlan.class))).thenReturn(validVm); + } catch (InsufficientCapacityException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ResourceUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + + try { + Mockito.when(_itMgr.advanceStop(Mockito.any(DomainRouterVO.class), Mockito.any(Boolean.class), Mockito.any(User.class), Mockito.any(Account.class))).thenReturn(true); + } catch (ResourceUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (OperationTimedoutException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ConcurrentOperationException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + + } + + //TESTS FOR START COMMAND + + + @Test (expected = InvalidParameterValueException.class) + public void startNonExistingVm() { + String expectedExcText = null; + try { + _lbVmSvc.startInternalLbVm(nonExistingVmId, _accountMgr.getAccount(1L), 1L); + } catch (StorageUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (InsufficientCapacityException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ConcurrentOperationException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ResourceUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (InvalidParameterValueException e) { + expectedExcText = e.getMessage(); + throw e; + } finally { + assertEquals("Test failed. The non-existing internal lb vm was attempted to start" + + expectedExcText, expectedExcText, "Can't find internal lb vm by id specified"); + } + } + + @Test (expected = InvalidParameterValueException.class) + public void startNonInternalLbVmVm() { + String expectedExcText = null; + try { + _lbVmSvc.startInternalLbVm(nonInternalLbVmId, _accountMgr.getAccount(1L), 1L); + } catch (StorageUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (InsufficientCapacityException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ConcurrentOperationException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ResourceUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + }catch (InvalidParameterValueException e) { + expectedExcText = e.getMessage(); + throw e; + } finally { + assertEquals("Test failed. The existing vm of not Internal lb vm type was attempted to start" + + expectedExcText, expectedExcText, "Can't find internal lb vm by id specified"); + } + } + + @Test + public void startValidLbVmVm() { + VirtualRouter vr = null; + try { + vr = _lbVmSvc.startInternalLbVm(validVmId, _accountMgr.getAccount(1L), 1L); + } catch (StorageUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (InsufficientCapacityException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ConcurrentOperationException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ResourceUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } finally { + assertNotNull("Internal LB vm is null which means it failed to start " + vr, vr); + } + } + + + //TEST FOR STOP COMMAND + @Test (expected = InvalidParameterValueException.class) + public void stopNonExistingVm() { + String expectedExcText = null; + try { + _lbVmSvc.stopInternalLbVm(nonExistingVmId, false,_accountMgr.getAccount(1L), 1L); + } catch (StorageUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ConcurrentOperationException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ResourceUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (InvalidParameterValueException e) { + expectedExcText = e.getMessage(); + throw e; + } finally { + assertEquals("Test failed. The non-existing internal lb vm was attempted to stop" + + expectedExcText, expectedExcText, "Can't find internal lb vm by id specified"); + } + } + + + @Test (expected = InvalidParameterValueException.class) + public void stopNonInternalLbVmVm() { + String expectedExcText = null; + try { + _lbVmSvc.stopInternalLbVm(nonInternalLbVmId, false, _accountMgr.getAccount(1L), 1L); + } catch (StorageUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ConcurrentOperationException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ResourceUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + }catch (InvalidParameterValueException e) { + expectedExcText = e.getMessage(); + throw e; + } finally { + assertEquals("Test failed. The existing vm of not Internal lb vm type was attempted to stop" + + expectedExcText, expectedExcText, "Can't find internal lb vm by id specified"); + } + } + + + @Test + public void stopValidLbVmVm() { + VirtualRouter vr = null; + try { + vr = _lbVmSvc.stopInternalLbVm(validVmId, false, _accountMgr.getAccount(1L), 1L); + } catch (StorageUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ConcurrentOperationException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } catch (ResourceUnavailableException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } finally { + assertNotNull("Internal LB vm is null which means it failed to stop " + vr, vr); + } + } + + + + private static ServiceOfferingVO setId(ServiceOfferingVO vo, long id) { + ServiceOfferingVO voToReturn = vo; + Class c = voToReturn.getClass(); + try { + Field f = c.getSuperclass().getDeclaredField("id"); + f.setAccessible(true); + f.setLong(voToReturn, id); + } catch (NoSuchFieldException ex) { + return null; + } catch (IllegalAccessException ex) { + return null; + } + + return voToReturn; + } +} diff --git a/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbvmmgr/LbChildTestConfiguration.java b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbvmmgr/LbChildTestConfiguration.java new file mode 100644 index 00000000000..79354ef26e2 --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/test/org/apache/cloudstack/internallbvmmgr/LbChildTestConfiguration.java @@ -0,0 +1,172 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.internallbvmmgr; + +import java.io.IOException; + +import org.apache.cloudstack.lb.dao.ApplicationLoadBalancerRuleDao; +import org.apache.cloudstack.test.utils.SpringUtils; +import org.mockito.Mockito; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.ComponentScan; +import org.springframework.context.annotation.ComponentScan.Filter; +import org.springframework.context.annotation.Configuration; +import org.springframework.context.annotation.FilterType; +import org.springframework.core.type.classreading.MetadataReader; +import org.springframework.core.type.classreading.MetadataReaderFactory; +import org.springframework.core.type.filter.TypeFilter; + +import com.cloud.agent.AgentManager; +import com.cloud.configuration.dao.ConfigurationDao; +import com.cloud.dc.dao.AccountVlanMapDaoImpl; +import com.cloud.dc.dao.DataCenterDao; +import com.cloud.network.NetworkManager; +import com.cloud.network.NetworkModel; +import com.cloud.network.dao.NetworkDao; +import com.cloud.network.dao.PhysicalNetworkServiceProviderDao; +import com.cloud.network.dao.VirtualRouterProviderDao; +import com.cloud.network.lb.LoadBalancingRulesManager; +import com.cloud.offerings.dao.NetworkOfferingDao; +import com.cloud.resource.ResourceManager; +import com.cloud.server.ConfigurationServer; +import com.cloud.service.dao.ServiceOfferingDao; +import com.cloud.storage.dao.VMTemplateDao; +import com.cloud.user.AccountManager; +import com.cloud.utils.net.NetUtils; +import com.cloud.vm.VirtualMachineManager; +import com.cloud.vm.dao.DomainRouterDao; +import com.cloud.vm.dao.NicDao; + + +@Configuration +@ComponentScan( + basePackageClasses={ + NetUtils.class, + }, + includeFilters={@Filter(value=LbChildTestConfiguration.Library.class, type=FilterType.CUSTOM)}, + useDefaultFilters=false + ) + + public class LbChildTestConfiguration { + + public static class Library implements TypeFilter { + + + @Bean + public AccountManager accountManager() { + return Mockito.mock(AccountManager.class); + } + + @Bean + public VirtualMachineManager virtualMachineManager() { + return Mockito.mock(VirtualMachineManager.class); + } + + @Bean + public DomainRouterDao domainRouterDao() { + return Mockito.mock(DomainRouterDao.class); + } + + @Bean + public ConfigurationDao configurationDao() { + return Mockito.mock(ConfigurationDao.class); + } + + @Bean + public VirtualRouterProviderDao virtualRouterProviderDao() { + return Mockito.mock(VirtualRouterProviderDao.class); + } + + @Bean + public ApplicationLoadBalancerRuleDao applicationLoadBalancerRuleDao() { + return Mockito.mock(ApplicationLoadBalancerRuleDao.class); + } + + @Bean + public NetworkModel networkModel() { + return Mockito.mock(NetworkModel.class); + } + + @Bean + public LoadBalancingRulesManager loadBalancingRulesManager() { + return Mockito.mock(LoadBalancingRulesManager.class); + } + + @Bean + public NicDao nicDao() { + return Mockito.mock(NicDao.class); + } + + @Bean + public NetworkDao networkDao() { + return Mockito.mock(NetworkDao.class); + } + + @Bean + public NetworkManager networkManager() { + return Mockito.mock(NetworkManager.class); + } + + @Bean + public ServiceOfferingDao serviceOfferingDao() { + return Mockito.mock(ServiceOfferingDao.class); + } + + @Bean + public PhysicalNetworkServiceProviderDao physicalNetworkServiceProviderDao() { + return Mockito.mock(PhysicalNetworkServiceProviderDao.class); + } + + @Bean + public NetworkOfferingDao networkOfferingDao() { + return Mockito.mock(NetworkOfferingDao.class); + } + + @Bean + public VMTemplateDao vmTemplateDao() { + return Mockito.mock(VMTemplateDao.class); + } + + @Bean + public ResourceManager resourceManager() { + return Mockito.mock(ResourceManager.class); + } + + @Bean + public AgentManager agentManager() { + return Mockito.mock(AgentManager.class); + } + + @Bean + public DataCenterDao dataCenterDao() { + return Mockito.mock(DataCenterDao.class); + } + + @Bean + public ConfigurationServer configurationServer() { + return Mockito.mock(ConfigurationServer.class); + } + + @Override + public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { + mdr.getClassMetadata().getClassName(); + ComponentScan cs = LbChildTestConfiguration.class.getAnnotation(ComponentScan.class); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + } + + } +} diff --git a/plugins/network-elements/internal-loadbalancer/test/resources/lb_element.xml b/plugins/network-elements/internal-loadbalancer/test/resources/lb_element.xml new file mode 100644 index 00000000000..5dec9c314f6 --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/test/resources/lb_element.xml @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/plugins/network-elements/internal-loadbalancer/test/resources/lb_mgr.xml b/plugins/network-elements/internal-loadbalancer/test/resources/lb_mgr.xml new file mode 100644 index 00000000000..1ad6403861c --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/test/resources/lb_mgr.xml @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/plugins/network-elements/internal-loadbalancer/test/resources/lb_svc.xml b/plugins/network-elements/internal-loadbalancer/test/resources/lb_svc.xml new file mode 100644 index 00000000000..fa822f35302 --- /dev/null +++ b/plugins/network-elements/internal-loadbalancer/test/resources/lb_svc.xml @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/plugins/network-elements/netscaler/src/com/cloud/network/element/NetscalerElement.java b/plugins/network-elements/netscaler/src/com/cloud/network/element/NetscalerElement.java index 2bbdb0450be..60d6674fdb4 100644 --- a/plugins/network-elements/netscaler/src/com/cloud/network/element/NetscalerElement.java +++ b/plugins/network-elements/netscaler/src/com/cloud/network/element/NetscalerElement.java @@ -16,16 +16,38 @@ // under the License. package com.cloud.network.element; +import java.net.URI; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import javax.ejb.Local; +import javax.inject.Inject; + +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.network.ExternalNetworkDeviceManager.NetworkDevice; +import org.apache.cloudstack.region.gslb.GslbServiceProvider; +import org.apache.log4j.Logger; + import com.cloud.agent.AgentManager; import com.cloud.agent.api.Answer; import com.cloud.agent.api.routing.GlobalLoadBalancerConfigCommand; +import com.cloud.agent.api.routing.HealthCheckLBConfigAnswer; +import com.cloud.agent.api.routing.HealthCheckLBConfigCommand; import com.cloud.agent.api.routing.LoadBalancerConfigCommand; import com.cloud.agent.api.routing.SetStaticNatRulesAnswer; import com.cloud.agent.api.routing.SetStaticNatRulesCommand; import com.cloud.agent.api.to.LoadBalancerTO; import com.cloud.agent.api.to.StaticNatRuleTO; import com.cloud.api.ApiDBUtils; -import com.cloud.api.commands.*; +import com.cloud.api.commands.AddNetscalerLoadBalancerCmd; +import com.cloud.api.commands.ConfigureNetscalerLoadBalancerCmd; +import com.cloud.api.commands.DeleteNetscalerLoadBalancerCmd; +import com.cloud.api.commands.ListNetscalerLoadBalancerNetworksCmd; +import com.cloud.api.commands.ListNetscalerLoadBalancersCmd; import com.cloud.api.response.NetscalerLoadBalancerResponse; import com.cloud.configuration.Config; import com.cloud.configuration.ConfigurationManager; @@ -37,28 +59,52 @@ import com.cloud.dc.HostPodVO; import com.cloud.dc.dao.DataCenterDao; import com.cloud.dc.dao.DataCenterIpAddressDao; import com.cloud.deploy.DeployDestination; -import com.cloud.exception.*; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.InsufficientNetworkCapacityException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.ResourceUnavailableException; import com.cloud.host.Host; import com.cloud.host.HostVO; import com.cloud.host.dao.HostDao; import com.cloud.host.dao.HostDetailsDao; -import com.cloud.network.*; +import com.cloud.network.ExternalLoadBalancerDeviceManager; +import com.cloud.network.ExternalLoadBalancerDeviceManagerImpl; +import com.cloud.network.IpAddress; +import com.cloud.network.NetScalerPodVO; +import com.cloud.network.Network; import com.cloud.network.Network.Capability; import com.cloud.network.Network.Provider; import com.cloud.network.Network.Service; +import com.cloud.network.NetworkModel; import com.cloud.network.Networks.TrafficType; +import com.cloud.network.PhysicalNetwork; +import com.cloud.network.PhysicalNetworkServiceProvider; +import com.cloud.network.PublicIpAddress; import com.cloud.network.as.AutoScaleCounter; import com.cloud.network.as.AutoScaleCounter.AutoScaleCounterType; -import com.cloud.network.dao.*; +import com.cloud.network.dao.ExternalLoadBalancerDeviceDao; +import com.cloud.network.dao.ExternalLoadBalancerDeviceVO; import com.cloud.network.dao.ExternalLoadBalancerDeviceVO.LBDeviceState; +import com.cloud.network.dao.NetScalerPodDao; +import com.cloud.network.dao.NetworkDao; +import com.cloud.network.dao.NetworkExternalLoadBalancerDao; +import com.cloud.network.dao.NetworkExternalLoadBalancerVO; +import com.cloud.network.dao.NetworkServiceMapDao; +import com.cloud.network.dao.NetworkVO; +import com.cloud.network.dao.PhysicalNetworkDao; +import com.cloud.network.dao.PhysicalNetworkVO; import com.cloud.network.lb.LoadBalancingRule; import com.cloud.network.lb.LoadBalancingRule.LbDestination; import com.cloud.network.resource.NetscalerResource; import com.cloud.network.rules.FirewallRule; -import com.cloud.network.rules.FirewallRule.Purpose; import com.cloud.network.rules.LbStickinessMethod; import com.cloud.network.rules.LbStickinessMethod.StickinessMethodType; +import com.cloud.network.rules.LoadBalancerContainer; import com.cloud.network.rules.StaticNat; +import com.cloud.network.vpc.PrivateGateway; +import com.cloud.network.vpc.StaticRouteProfile; +import com.cloud.network.vpc.Vpc; import com.cloud.offering.NetworkOffering; import com.cloud.utils.NumbersUtil; import com.cloud.utils.db.DB; @@ -70,15 +116,6 @@ import com.cloud.vm.ReservationContext; import com.cloud.vm.VirtualMachine; import com.cloud.vm.VirtualMachineProfile; import com.google.gson.Gson; -import org.apache.cloudstack.api.ApiConstants; -import org.apache.cloudstack.network.ExternalNetworkDeviceManager.NetworkDevice; -import org.apache.cloudstack.region.gslb.GslbServiceProvider; -import org.apache.log4j.Logger; - -import javax.ejb.Local; -import javax.inject.Inject; -import java.net.URI; -import java.util.*; @Local(value = {NetworkElement.class, StaticNatServiceProvider.class, LoadBalancingServiceProvider.class, GslbServiceProvider.class}) public class NetscalerElement extends ExternalLoadBalancerDeviceManagerImpl implements LoadBalancingServiceProvider, @@ -202,6 +239,10 @@ public class NetscalerElement extends ExternalLoadBalancerDeviceManagerImpl impl if (!canHandle(config, Service.Lb)) { return false; } + + if (canHandleLbRules(rules)) { + return false; + } if (isBasicZoneNetwok(config)) { return applyElasticLoadBalancerRules(config, rules); @@ -232,6 +273,9 @@ public class NetscalerElement extends ExternalLoadBalancerDeviceManagerImpl impl // Specifies that load balancing rules can only be made with public IPs that aren't source NAT IPs lbCapabilities.put(Capability.LoadBalancingSupportedIps, "additional"); + // Supports only Public load balancing + lbCapabilities.put(Capability.LbSchemes, LoadBalancerContainer.Scheme.Public.toString()); + // Specifies that load balancing rules can support autoscaling and the list of counters it supports AutoScaleCounter counter; List counterList = new ArrayList(); @@ -639,14 +683,7 @@ public class NetscalerElement extends ExternalLoadBalancerDeviceManagerImpl impl return this; } - public boolean applyElasticLoadBalancerRules(Network network, List rules) throws ResourceUnavailableException { - - List loadBalancingRules = new ArrayList(); - for (FirewallRule rule : rules) { - if (rule.getPurpose().equals(Purpose.LoadBalancing)) { - loadBalancingRules.add((LoadBalancingRule) rule); - } - } + public boolean applyElasticLoadBalancerRules(Network network, List loadBalancingRules) throws ResourceUnavailableException { if (loadBalancingRules == null || loadBalancingRules.isEmpty()) { return true; @@ -677,12 +714,12 @@ public class NetscalerElement extends ExternalLoadBalancerDeviceManagerImpl impl String protocol = rule.getProtocol(); String algorithm = rule.getAlgorithm(); String lbUuid = rule.getUuid(); - String srcIp = _networkMgr.getIp(rule.getSourceIpAddressId()).getAddress().addr(); + String srcIp = rule.getSourceIp().addr(); int srcPort = rule.getSourcePortStart(); List destinations = rule.getDestinations(); if ((destinations != null && !destinations.isEmpty()) || rule.isAutoScaleConfig()) { - LoadBalancerTO loadBalancer = new LoadBalancerTO(lbUuid, srcIp, srcPort, protocol, algorithm, revoked, false, false, destinations, rule.getStickinessPolicies()); + LoadBalancerTO loadBalancer = new LoadBalancerTO(lbUuid, srcIp, srcPort, protocol, algorithm, revoked, false, false, destinations, rule.getStickinessPolicies(), rule.getHealthCheckPolicies()); if (rule.isAutoScaleConfig()) { loadBalancer.setAutoScaleVmGroup(rule.getAutoScaleVmGroup()); } @@ -808,11 +845,69 @@ public class NetscalerElement extends ExternalLoadBalancerDeviceManagerImpl impl return null; } + public List getElasticLBRulesHealthCheck(Network network, List loadBalancingRules) + throws ResourceUnavailableException { + + HealthCheckLBConfigAnswer answer = null; + + if (loadBalancingRules == null || loadBalancingRules.isEmpty()) { + return null; + } + + String errMsg = null; + ExternalLoadBalancerDeviceVO lbDeviceVO = getExternalLoadBalancerForNetwork(network); + + if (lbDeviceVO == null) { + s_logger.warn("There is no external load balancer device assigned to this network either network is not implement are already shutdown so just returning"); + return null; + } + + if (!isNetscalerDevice(lbDeviceVO.getDeviceName())) { + errMsg = "There are no NetScaler load balancer assigned for this network. So NetScaler element can not be handle elastic load balancer rules."; + s_logger.error(errMsg); + throw new ResourceUnavailableException(errMsg, this.getClass(), 0); + } + + List loadBalancersToApply = new ArrayList(); + for (int i = 0; i < loadBalancingRules.size(); i++) { + LoadBalancingRule rule = loadBalancingRules.get(i); + boolean revoked = (rule.getState().equals(FirewallRule.State.Revoke)); + String protocol = rule.getProtocol(); + String algorithm = rule.getAlgorithm(); + String lbUuid = rule.getUuid(); + String srcIp = rule.getSourceIp().addr(); + int srcPort = rule.getSourcePortStart(); + List destinations = rule.getDestinations(); + + if ((destinations != null && !destinations.isEmpty()) || rule.isAutoScaleConfig()) { + LoadBalancerTO loadBalancer = new LoadBalancerTO(lbUuid, srcIp, srcPort, protocol, algorithm, revoked, + false, false, destinations, null, rule.getHealthCheckPolicies()); + loadBalancersToApply.add(loadBalancer); + } + } + + if (loadBalancersToApply.size() > 0) { + int numLoadBalancersForCommand = loadBalancersToApply.size(); + LoadBalancerTO[] loadBalancersForCommand = loadBalancersToApply + .toArray(new LoadBalancerTO[numLoadBalancersForCommand]); + HealthCheckLBConfigCommand cmd = new HealthCheckLBConfigCommand(loadBalancersForCommand); + HostVO externalLoadBalancer = _hostDao.findById(lbDeviceVO.getHostId()); + answer = (HealthCheckLBConfigAnswer) _agentMgr.easySend(externalLoadBalancer.getId(), cmd); + return answer.getLoadBalancers(); + } + return null; + } + public List updateHealthChecks(Network network, List lbrules) { - if (canHandle(network, Service.Lb)) { + if (canHandle(network, Service.Lb) && canHandleLbRules(lbrules)) { try { - return getLBHealthChecks(network, lbrules); + + if (isBasicZoneNetwok(network)) { + return getElasticLBRulesHealthCheck(network, lbrules); + } else { + return getLBHealthChecks(network, lbrules); + } } catch (ResourceUnavailableException e) { s_logger.error("Error in getting the LB Rules from NetScaler " + e); } @@ -822,7 +917,7 @@ public class NetscalerElement extends ExternalLoadBalancerDeviceManagerImpl impl return null; } - public List getLBHealthChecks(Network network, List rules) + public List getLBHealthChecks(Network network, List rules) throws ResourceUnavailableException { return super.getLBHealthChecks(network, rules); } @@ -891,4 +986,21 @@ public class NetscalerElement extends ExternalLoadBalancerDeviceManagerImpl impl } return null; } + + private boolean canHandleLbRules(List rules) { + Map lbCaps = this.getCapabilities().get(Service.Lb); + if (!lbCaps.isEmpty()) { + String schemeCaps = lbCaps.get(Capability.LbSchemes); + if (schemeCaps != null) { + for (LoadBalancingRule rule : rules) { + if (!schemeCaps.contains(rule.getScheme().toString())) { + s_logger.debug("Scheme " + rules.get(0).getScheme() + " is not supported by the provider " + this.getName()); + return false; + } + } + } + } + return true; + } + } diff --git a/plugins/network-elements/netscaler/src/com/cloud/network/resource/NetscalerResource.java b/plugins/network-elements/netscaler/src/com/cloud/network/resource/NetscalerResource.java index b82176b7e37..98e14618248 100644 --- a/plugins/network-elements/netscaler/src/com/cloud/network/resource/NetscalerResource.java +++ b/plugins/network-elements/netscaler/src/com/cloud/network/resource/NetscalerResource.java @@ -1211,6 +1211,18 @@ public class NetscalerResource implements ServerResource { try { gslbservice service; service = getServiceObject(client, serviceName); + String gslbServerName = generateGslbServerName(serviceIp); + + if (!gslbServerExists(client, gslbServerName)) { + base_response apiCallResult; + com.citrix.netscaler.nitro.resource.config.basic.server nsServer = new com.citrix.netscaler.nitro.resource.config.basic.server(); + nsServer.set_name(gslbServerName); + nsServer.set_ipaddress(serviceIp); + apiCallResult = com.citrix.netscaler.nitro.resource.config.basic.server.add(client, nsServer); + if ((apiCallResult.errorcode != 0) && (apiCallResult.errorcode != NitroError.NS_RESOURCE_EXISTS)) { + throw new ExecutionException("Failed to add server " + gslbServerName + " due to" + apiCallResult.message); + } + } boolean isUpdateSite = false; if (service == null) { @@ -1220,7 +1232,7 @@ public class NetscalerResource implements ServerResource { } service.set_sitename(siteName); - service.set_servername(serviceIp); + service.set_servername(gslbServerName); int port = Integer.parseInt(servicePort); service.set_port(port); service.set_servicename(serviceName); @@ -1236,7 +1248,7 @@ public class NetscalerResource implements ServerResource { s_logger.debug("Successfully created service: " + serviceName + " at site: " + siteName); } } catch (Exception e) { - String errMsg = "Failed to created service: " + serviceName + " at site: " + siteName; + String errMsg = "Failed to created service: " + serviceName + " at site: " + siteName + " due to " + e.getMessage(); if (s_logger.isDebugEnabled()) { s_logger.debug(errMsg); } @@ -1284,7 +1296,7 @@ public class NetscalerResource implements ServerResource { } } } catch (Exception e) { - String errMsg = "Failed to update service: " + serviceName + " at site: " + siteName; + String errMsg = "Failed to update service: " + serviceName + " at site: " + siteName + "due to " + e.getMessage(); if (s_logger.isDebugEnabled()) { s_logger.debug(errMsg); } @@ -1294,6 +1306,7 @@ public class NetscalerResource implements ServerResource { private static void createVserverServiceBinding(nitro_service client, String serviceName, String vserverName) throws ExecutionException { + String errMsg; try { gslbvserver_gslbservice_binding binding = new gslbvserver_gslbservice_binding(); binding.set_name(vserverName); @@ -1303,8 +1316,18 @@ public class NetscalerResource implements ServerResource { s_logger.debug("Successfully created service: " + serviceName + " and virtual server: " + vserverName + " binding"); } + } catch (nitro_exception ne) { + if (ne.getErrorCode() == 273) { + return; + } + errMsg = "Failed to create service: " + serviceName + " and virtual server: " + + vserverName + " binding due to " + ne.getMessage(); + if (s_logger.isDebugEnabled()) { + s_logger.debug(errMsg); + } + throw new ExecutionException(errMsg); } catch (Exception e) { - String errMsg = "Failed to create service: " + serviceName + " and virtual server: " + errMsg = "Failed to create service: " + serviceName + " and virtual server: " + vserverName + " binding due to " + e.getMessage(); if (s_logger.isDebugEnabled()) { s_logger.debug(errMsg); @@ -1437,6 +1460,39 @@ public class NetscalerResource implements ServerResource { private static String generateUniqueServiceName(String siteName, String publicIp, String publicPort) { return "cloud-gslb-service-" + siteName + "-" + publicIp + "-" + publicPort; } + + private static boolean gslbServerExists(nitro_service client, String serverName) throws ExecutionException { + try { + if (com.citrix.netscaler.nitro.resource.config.basic.server.get(client, serverName) != null) { + return true; + } else { + return false; + } + } catch (nitro_exception e) { + if (e.getErrorCode() == NitroError.NS_RESOURCE_NOT_EXISTS) { + return false; + } else { + throw new ExecutionException("Failed to verify Server " + serverName + " exists on the NetScaler device due to " + e.getMessage()); + } + } catch (Exception e) { + throw new ExecutionException("Failed to verify Server " + serverName + " exists on the NetScaler device due to " + e.getMessage()); + } + } + + private static String generateGslbServerName(String serverIP) { + return genGslbObjectName("Cloud-Server-", serverIP); + } + + private static String genGslbObjectName(Object... args) { + String objectName = ""; + for (int i = 0; i < args.length; i++) { + objectName += args[i]; + if (i != args.length -1) { + objectName += "-"; + } + } + return objectName; + } } @@ -1562,7 +1618,9 @@ public class NetscalerResource implements ServerResource { String srcIp = rule.getSrcIp(); String dstIP = rule.getDstIp(); String iNatRuleName = generateInatRuleName(srcIp, dstIP); + String rNatRuleName = generateRnatRuleName(srcIp, dstIP); inat iNatRule = null; + rnat rnatRule = null; if (!rule.revoked()) { try { @@ -1589,9 +1647,47 @@ public class NetscalerResource implements ServerResource { } s_logger.debug("Created Inat rule on the Netscaler device " + _ip + " to enable static NAT from " + srcIp + " to " + dstIP); } + try { + rnat[] rnatRules = rnat.get(_netscalerService); + if (rnatRules != null) { + for (rnat rantrule : rnatRules) { + if (rantrule.get_network().equalsIgnoreCase(rNatRuleName)) { + rnatRule = rantrule; + break; + } + } + } + } catch (nitro_exception e) { + throw e; + } + + if (rnatRule == null) { + rnatRule = new rnat(); + rnatRule.set_natip(srcIp); + rnatRule.set_network(dstIP); + rnatRule.set_netmask("255.255.255.255"); + try { + apiCallResult = rnat.update(_netscalerService, rnatRule); + } catch (nitro_exception e) { + if (e.getErrorCode() != NitroError.NS_RESOURCE_EXISTS) { + throw e; + } + } + s_logger.debug("Created Rnat rule on the Netscaler device " + _ip + " to enable revese static NAT from " + dstIP + " to " + srcIp); + } } else { try { inat.delete(_netscalerService, iNatRuleName); + rnat[] rnatRules = rnat.get(_netscalerService); + if (rnatRules != null) { + for (rnat rantrule : rnatRules) { + if (rantrule.get_network().equalsIgnoreCase(dstIP)) { + rnatRule = rantrule; + rnat.clear(_netscalerService, rnatRule); + break; + } + } + } } catch (nitro_exception e) { if (e.getErrorCode() != NitroError.NS_RESOURCE_NOT_EXISTS) { throw e; @@ -2201,6 +2297,7 @@ public class NetscalerResource implements ServerResource { } csMon.set_interval(hcp.getHealthcheckInterval()); + csMon.set_retries(Math.max(hcp.getHealthcheckThresshold(), hcp.getUnhealthThresshold()) + 1); csMon.set_resptimeout(hcp.getResponseTime()); csMon.set_failureretries(hcp.getUnhealthThresshold()); csMon.set_successretries(hcp.getHealthcheckThresshold()); @@ -3034,6 +3131,10 @@ public class NetscalerResource implements ServerResource { return genObjectName("Cloud-Inat", srcIp); } + private String generateRnatRuleName(String srcIp, String dstIP) { + return genObjectName("Cloud-Rnat", srcIp); + } + private String generateNSVirtualServerName(String srcIp, long srcPort) { return genObjectName("Cloud-VirtualServer", srcIp, srcPort); } diff --git a/plugins/network-elements/nicira-nvp/src/com/cloud/api/commands/DeleteNiciraNvpDeviceCmd.java b/plugins/network-elements/nicira-nvp/src/com/cloud/api/commands/DeleteNiciraNvpDeviceCmd.java old mode 100644 new mode 100755 index 8d21a55a65e..9ba1c836a98 --- a/plugins/network-elements/nicira-nvp/src/com/cloud/api/commands/DeleteNiciraNvpDeviceCmd.java +++ b/plugins/network-elements/nicira-nvp/src/com/cloud/api/commands/DeleteNiciraNvpDeviceCmd.java @@ -95,7 +95,7 @@ public class DeleteNiciraNvpDeviceCmd extends BaseAsyncCmd { @Override public String getEventType() { - return EventTypes.EVENT_EXTERNAL_LB_DEVICE_DELETE; + return EventTypes.EVENT_EXTERNAL_NVP_CONTROLLER_DELETE; } @Override diff --git a/plugins/network-elements/nicira-nvp/src/com/cloud/network/nicira/NiciraNvpTag.java b/plugins/network-elements/nicira-nvp/src/com/cloud/network/nicira/NiciraNvpTag.java index f8282b86d9c..157c3b522c7 100644 --- a/plugins/network-elements/nicira-nvp/src/com/cloud/network/nicira/NiciraNvpTag.java +++ b/plugins/network-elements/nicira-nvp/src/com/cloud/network/nicira/NiciraNvpTag.java @@ -16,7 +16,10 @@ // under the License. package com.cloud.network.nicira; +import org.apache.log4j.Logger; + public class NiciraNvpTag { + private static final Logger s_logger = Logger.getLogger(NiciraNvpTag.class); private String scope; private String tag; @@ -24,7 +27,12 @@ public class NiciraNvpTag { public NiciraNvpTag(String scope, String tag) { this.scope = scope; - this.tag = tag; + if (tag.length() > 40) { + s_logger.warn("tag \"" + tag + "\" too long, truncating to 40 characters"); + this.tag = tag.substring(0, 40); + } else { + this.tag = tag; + } } public String getScope() { @@ -40,7 +48,12 @@ public class NiciraNvpTag { } public void setTag(String tag) { - this.tag = tag; + if (tag.length() > 40) { + s_logger.warn("tag \"" + tag + "\" too long, truncating to 40 characters"); + this.tag = tag.substring(0, 40); + } else { + this.tag = tag; + } } } diff --git a/plugins/network-elements/nicira-nvp/test/com/cloud/network/nicira/NiciraTagTest.java b/plugins/network-elements/nicira-nvp/test/com/cloud/network/nicira/NiciraTagTest.java new file mode 100644 index 00000000000..fd13e07ab59 --- /dev/null +++ b/plugins/network-elements/nicira-nvp/test/com/cloud/network/nicira/NiciraTagTest.java @@ -0,0 +1,54 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package com.cloud.network.nicira; + +import org.junit.Test; +import static org.junit.Assert.*; + +public class NiciraTagTest { + @Test + public void testCreateTag() { + NiciraNvpTag tag = new NiciraNvpTag("scope","tag"); + assertEquals("scope part set", "scope", tag.getScope()); + assertEquals("tag part set", "tag", tag.getTag()); + } + + @Test + public void testCreateLongTag() { + NiciraNvpTag tag = new NiciraNvpTag("scope","verylongtagthatshouldattheminimumexceedthefortycharacterlenght"); + assertEquals("scope part set", "scope", tag.getScope()); + assertEquals("tag part set", "verylongtagthatshouldattheminimumexceedt", tag.getTag()); + } + + @Test + public void testSetTag() { + NiciraNvpTag tag = new NiciraNvpTag(); + tag.setScope("scope"); + tag.setTag("tag"); + assertEquals("scope part set", "scope", tag.getScope()); + assertEquals("tag part set", "tag", tag.getTag()); + } + + @Test + public void testSetLongTag() { + NiciraNvpTag tag = new NiciraNvpTag(); + tag.setScope("scope"); + tag.setTag("verylongtagthatshouldattheminimumexceedthefortycharacterlenght"); + assertEquals("scope part set", "scope", tag.getScope()); + assertEquals("tag part set", "verylongtagthatshouldattheminimumexceedt", tag.getTag()); + } +} \ No newline at end of file diff --git a/plugins/pom.xml b/plugins/pom.xml index 471253f0728..e49fac9533a 100755 --- a/plugins/pom.xml +++ b/plugins/pom.xml @@ -16,8 +16,7 @@ KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ---> - +--> 4.0.0 cloudstack-plugins Apache CloudStack Plugin POM @@ -63,6 +62,7 @@ storage/volume/default alert-handlers/snmp-alerts alert-handlers/syslog-alerts + network-elements/internal-loadbalancer diff --git a/plugins/storage/volume/default/src/org/apache/cloudstack/storage/datastore/lifecycle/CloudStackPrimaryDataStoreLifeCycleImpl.java b/plugins/storage/volume/default/src/org/apache/cloudstack/storage/datastore/lifecycle/CloudStackPrimaryDataStoreLifeCycleImpl.java index a0c991b5ad6..7153282a2aa 100644 --- a/plugins/storage/volume/default/src/org/apache/cloudstack/storage/datastore/lifecycle/CloudStackPrimaryDataStoreLifeCycleImpl.java +++ b/plugins/storage/volume/default/src/org/apache/cloudstack/storage/datastore/lifecycle/CloudStackPrimaryDataStoreLifeCycleImpl.java @@ -30,12 +30,10 @@ import javax.inject.Inject; import org.apache.cloudstack.engine.subsystem.api.storage.ClusterScope; import org.apache.cloudstack.engine.subsystem.api.storage.DataStore; import org.apache.cloudstack.engine.subsystem.api.storage.DataStoreManager; -import org.apache.cloudstack.engine.subsystem.api.storage.DataStoreRole; import org.apache.cloudstack.engine.subsystem.api.storage.HostScope; import org.apache.cloudstack.engine.subsystem.api.storage.PrimaryDataStoreInfo; import org.apache.cloudstack.engine.subsystem.api.storage.PrimaryDataStoreLifeCycle; import org.apache.cloudstack.engine.subsystem.api.storage.PrimaryDataStoreParameters; -import org.apache.cloudstack.engine.subsystem.api.storage.ScopeType; import org.apache.cloudstack.engine.subsystem.api.storage.ZoneScope; import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDao; import org.apache.cloudstack.storage.datastore.db.StoragePoolVO; @@ -46,17 +44,12 @@ import com.cloud.agent.AgentManager; import com.cloud.agent.api.Answer; import com.cloud.agent.api.CreateStoragePoolCommand; import com.cloud.agent.api.DeleteStoragePoolCommand; -import com.cloud.agent.api.ModifyStoragePoolCommand; import com.cloud.agent.api.StoragePoolInfo; import com.cloud.alert.AlertManager; -import com.cloud.capacity.Capacity; -import com.cloud.capacity.CapacityVO; -import com.cloud.capacity.dao.CapacityDao; import com.cloud.exception.DiscoveryException; import com.cloud.exception.InvalidParameterValueException; import com.cloud.host.Host; import com.cloud.host.HostVO; -import com.cloud.host.Status; import com.cloud.hypervisor.Hypervisor.HypervisorType; import com.cloud.resource.ResourceManager; import com.cloud.server.ManagementServer; @@ -67,29 +60,14 @@ import com.cloud.storage.StoragePool; import com.cloud.storage.StoragePoolAutomation; import com.cloud.storage.StoragePoolDiscoverer; import com.cloud.storage.StoragePoolHostVO; -import com.cloud.storage.StoragePoolStatus; -import com.cloud.storage.StoragePoolWorkVO; -import com.cloud.storage.VolumeVO; import com.cloud.storage.dao.StoragePoolHostDao; import com.cloud.storage.dao.StoragePoolWorkDao; import com.cloud.storage.dao.VolumeDao; -import com.cloud.user.Account; -import com.cloud.user.User; -import com.cloud.user.UserContext; import com.cloud.user.dao.UserDao; import com.cloud.utils.NumbersUtil; import com.cloud.utils.UriUtils; import com.cloud.utils.db.DB; -import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; -import com.cloud.utils.exception.ExecutionException; -import com.cloud.vm.ConsoleProxyVO; -import com.cloud.vm.DomainRouterVO; -import com.cloud.vm.SecondaryStorageVmVO; -import com.cloud.vm.UserVmVO; -import com.cloud.vm.VMInstanceVO; -import com.cloud.vm.VirtualMachine; -import com.cloud.vm.VirtualMachine.State; import com.cloud.vm.VirtualMachineManager; import com.cloud.vm.dao.ConsoleProxyDao; import com.cloud.vm.dao.DomainRouterDao; @@ -157,7 +135,7 @@ public class CloudStackPrimaryDataStoreLifeCycleImpl implements throw new InvalidParameterValueException( "Cluster id requires pod id"); } - + PrimaryDataStoreParameters parameters = new PrimaryDataStoreParameters(); URI uri = null; @@ -195,7 +173,7 @@ public class CloudStackPrimaryDataStoreLifeCycleImpl implements String tags = (String) dsInfos.get("tags"); Map details = (Map) dsInfos .get("details"); - + parameters.setTags(tags); parameters.setDetails(details); @@ -208,7 +186,7 @@ public class CloudStackPrimaryDataStoreLifeCycleImpl implements } String userInfo = uri.getUserInfo(); int port = uri.getPort(); - StoragePoolVO pool = null; + StoragePool pool = null; if (s_logger.isDebugEnabled()) { s_logger.debug("createPool Params @ scheme - " + scheme + " storageHost - " + storageHost + " hostPath - " @@ -272,7 +250,7 @@ public class CloudStackPrimaryDataStoreLifeCycleImpl implements parameters.setPath(hostPath); } else { for (StoragePoolDiscoverer discoverer : _discoverers) { - Map> pools; + Map> pools; try { pools = discoverer.find(zoneId, podId, uri, details); } catch (DiscoveryException e) { @@ -281,7 +259,7 @@ public class CloudStackPrimaryDataStoreLifeCycleImpl implements e); } if (pools != null) { - Map.Entry> entry = pools + Map.Entry> entry = pools .entrySet().iterator().next(); pool = entry.getKey(); details = entry.getValue(); @@ -310,7 +288,7 @@ public class CloudStackPrimaryDataStoreLifeCycleImpl implements parameters.setPath(hostPath); } else { StoragePoolType type = Enum.valueOf(StoragePoolType.class, scheme); - + if (type != null) { parameters.setType(type); parameters.setHost(storageHost); @@ -332,7 +310,7 @@ public class CloudStackPrimaryDataStoreLifeCycleImpl implements + " already in use by another pod (id=" + oldPodId + ")"); } } - + Object existingUuid = dsInfos.get("uuid"); String uuid = null; @@ -368,7 +346,7 @@ public class CloudStackPrimaryDataStoreLifeCycleImpl implements parameters.setName(poolName); parameters.setClusterId(clusterId); parameters.setProviderName(providerName); - + return dataStoreHelper.createPrimaryDataStore(parameters); } @@ -457,7 +435,7 @@ public class CloudStackPrimaryDataStoreLifeCycleImpl implements primaryDataStoreDao.expunge(primarystore.getId()); return false; } - + this.dataStoreHelper.attachCluster(store); return true; } @@ -527,11 +505,11 @@ public class CloudStackPrimaryDataStoreLifeCycleImpl implements } } } - + if (!deleteFlag) { throw new CloudRuntimeException("Failed to delete storage pool on host"); } - + return this.dataStoreHelper.deletePrimaryDataStore(store); } diff --git a/pom.xml b/pom.xml index 7d5b4c3bdef..e8fdb2f83ea 100644 --- a/pom.xml +++ b/pom.xml @@ -1,23 +1,14 @@ - + + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> 4.0.0 @@ -34,8 +25,8 @@ Apache CloudStack is an IaaS (“Infrastracture as a Service”) cloud orchestration platform. http://www.cloudstack.org - scm:git:https://git-wip-us.apache.org/repos/asf/incubator-cloudstack.git - scm:git:https://git-wip-us.apache.org/repos/asf/incubator-cloudstack.git + scm:git:https://git-wip-us.apache.org/repos/asf/cloudstack.git + scm:git:https://git-wip-us.apache.org/repos/asf/cloudstack.git jira @@ -43,7 +34,7 @@ - + 1.6 UTF-8 @@ -92,6 +83,7 @@ 0.10 build/replace.properties 0.4.9 + target @@ -106,40 +98,49 @@ Apache CloudStack User List - cloudstack-users-subscribe@incubator.apache.org - cloudstack-users-unsubscribe@incubator.apache.org - cloudstack-users@incubator.apache.org - http://mail-archives.apache.org/mod_mbox/incubator-cloudstack-users + users-subscribe@cloudstack.apache.org + users-unsubscribe@cloudstack.apache.org + users@cloudstack.apache.org + http://mail-archives.apache.org/mod_mbox/cloudstack-users + + http://mail-archives.apache.org/mod_mbox/incubator-cloudstack-users + Apache CloudStack Developer List - cloudstack-dev-subscribe@incubator.apache.org - cloudstack-dev-unsubscribe@incubator.apache.org - cloudstack-dev@incubator.apache.org - http://mail-archives.apache.org/mod_mbox/incubator-cloudstack-dev + dev-subscribe@cloudstack.apache.org + dev-unsubscribe@cloudstack.apache.org + dev@cloudstack.apache.org + http://mail-archives.apache.org/mod_mbox/cloudstack-dev + + http://mail-archives.apache.org/mod_mbox/incubator-cloudstack-dev + Apache CloudStack Commits List - cloudstack-commits-subscribe@incubator.apache.org - cloudstack-commits-unsubscribe@incubator.apache.org - cloudstack-commits@incubator.apache.org - http://mail-archives.apache.org/mod_mbox/incubator-cloudstack-commits + commits-subscribe@cloudstack.apache.org + commits-unsubscribe@cloudstack.apache.org + commits@cloudstack.apache.org + http://mail-archives.apache.org/mod_mbox/cloudstack-commits + + http://mail-archives.apache.org/mod_mbox/incubator-cloudstack-commits + The Apache CloudStack Team - cloudstack-dev@incubator.apache.org - http://incubator.apache.org/projects/cloudstack.html + dev@cloudstack.apache.org + http://cloudstack.apache.org/ Apache Software Foundation http://apache.org/ - Jenkin - http://jenkins.cloudstack.org/ + Jenkins + http://builds.apache.org/ @@ -167,9 +168,9 @@ plugins patches framework - services test client + services @@ -204,6 +205,20 @@ spring-web ${org.springframework.version} + org.mockito mockito-all @@ -235,8 +250,31 @@ install + src + test + + + test/resources + + + ${basedir}/${cs.target.dir}/classes + ${basedir}/${cs.target.dir}/test-classes + + maven-clean-plugin + + true + + + target + + **/* + + + + + org.apache.maven.plugins maven-release-plugin @@ -253,8 +291,8 @@ - + org.eclipse.m2e lifecycle-mapping @@ -276,7 +314,7 @@ - + @@ -377,7 +415,7 @@ patches/systemvm/debian/config/etc/apache2/sites-available/default patches/systemvm/debian/config/etc/apache2/sites-available/default-ssl patches/systemvm/debian/config/etc/apache2/vhostexample.conf - patches/systemvm/debian/config/etc/dnsmasq.conf + patches/systemvm/debian/config/etc/dnsmasq.conf.tmpl patches/systemvm/debian/config/etc/vpcdnsmasq.conf patches/systemvm/debian/config/etc/ssh/sshd_config patches/systemvm/debian/config/etc/rsyslog.conf @@ -398,6 +436,8 @@ patches/systemvm/debian/config/var/www/html/userdata/.htaccess patches/systemvm/debian/config/var/www/html/latest/.htaccess patches/systemvm/debian/vpn/etc/ipsec.d/l2tp.conf + tools/transifex/.tx/config + tools/marvin/marvin/sandbox/advanced/sandbox.cfg @@ -469,6 +509,12 @@ awsapi + + eclipse + + target-eclipse + + developer @@ -479,6 +525,16 @@ tools + + impatient + + tools/devcloud/devcloud.cfg + + + developer + + + vmware diff --git a/scripts/network/exdhcp/dnsmasq_edithosts.sh b/scripts/network/exdhcp/dnsmasq_edithosts.sh index 05285d9accf..7990356edc4 100755 --- a/scripts/network/exdhcp/dnsmasq_edithosts.sh +++ b/scripts/network/exdhcp/dnsmasq_edithosts.sh @@ -35,6 +35,9 @@ wait_for_dnsmasq () { return 1 } +command -v dhcp_release > /dev/null 2>&1 +no_dhcp_release=$? + [ ! -f /etc/dhcphosts.txt ] && touch /etc/dhcphosts.txt [ ! -f /var/lib/misc/dnsmasq.leases ] && touch /var/lib/misc/dnsmasq.leases @@ -44,6 +47,12 @@ sed -i /$3,/d /etc/dhcphosts.txt echo "$1,$2,$3,infinite" >>/etc/dhcphosts.txt +#release previous dhcp lease if present +if [ $no_dhcp_release -eq 0 ] +then + dhcp_release lo $2 $(grep $2 $DHCP_LEASES | awk '{print $2}') > /dev/null 2>&1 +fi + #delete leases to supplied mac and ip addresses sed -i /$1/d /var/lib/misc/dnsmasq.leases sed -i /"$2 "/d /var/lib/misc/dnsmasq.leases @@ -61,9 +70,13 @@ echo "$2 $3" >> /etc/hosts pid=$(pidof dnsmasq) if [ "$pid" != "" ] then - # send SIGHUP to dnsmasq to reload /etc/hosts /etc/dhcphosts.txt - # this will not reload /etc/dnsmasq.conf - kill -s 1 $pid + # use SIGHUP to avoid service outage if dhcp_release is available. + if [ $no_dhcp_release -eq 0 ] + then + kill -HUP $pid + else + service dnsmasq restart + fi else service dnsmasq start wait_for_dnsmasq diff --git a/server/pom.xml b/server/pom.xml index 8b64335d50f..004d9c8e068 100644 --- a/server/pom.xml +++ b/server/pom.xml @@ -1,22 +1,14 @@ - - + + 4.0.0 cloud-server Apache CloudStack Server @@ -42,6 +34,11 @@ httpcore ${cs.httpcore.version} + + org.apache.cloudstack + cloud-framework-jobs + ${project.version} + org.apache.httpcomponents httpclient @@ -110,35 +107,35 @@ **/*.xml - + test/resources - - %regex[.*[0-9]*To[0-9]*.*Test.*] - + + %regex[.*[0-9]*To[0-9]*.*Test.*] + - - org.apache.maven.plugins - maven-compiler-plugin - - - default-testCompile - test-compile - - - **/com/cloud/upgrade/*.java - **/com/cloud/async/*.java - - - - testCompile - - - - + + org.apache.maven.plugins + maven-compiler-plugin + + + default-testCompile + test-compile + + + **/com/cloud/upgrade/*.java + **/com/cloud/async/*.java + + + + testCompile + + + + org.apache.maven.plugins maven-surefire-plugin @@ -146,8 +143,8 @@ -Xmx1024m %regex[.*[0-9]*To[0-9]*.*Test.*] - com/cloud/upgrade/AdvanceZone223To224UpgradeTest - com/cloud/upgrade/AdvanceZone217To224UpgradeTest + com/cloud/upgrade/AdvanceZone223To224UpgradeTest + com/cloud/upgrade/AdvanceZone217To224UpgradeTest com/cloud/async/* com/cloud/cluster/* com/cloud/snapshot/* @@ -157,7 +154,9 @@ com/cloud/network/vpn/RemoteAccessVpnTest.java com/cloud/network/security/SecurityGroupManagerImpl2Test.java com/cloud/network/security/SecurityGroupManagerImpl2Test.java - com/cloud/vpc/* + com/cloud/vpc/VpcTestConfiguration.java + com/cloud/vpc/VpcApiUnitTest.java + com/cloud/vpc/VpcManagerTest.java @@ -173,22 +172,18 @@ - + - - + + - + diff --git a/core/src/com/cloud/alert/AlertManager.java b/server/src/com/cloud/alert/AlertManager.java similarity index 100% rename from core/src/com/cloud/alert/AlertManager.java rename to server/src/com/cloud/alert/AlertManager.java diff --git a/server/src/com/cloud/alert/AlertManagerImpl.java b/server/src/com/cloud/alert/AlertManagerImpl.java index 655ed98ea60..9b7cd274a2e 100755 --- a/server/src/com/cloud/alert/AlertManagerImpl.java +++ b/server/src/com/cloud/alert/AlertManagerImpl.java @@ -70,6 +70,7 @@ import com.cloud.host.dao.HostDao; import com.cloud.network.dao.IPAddressDao; import com.cloud.org.Grouping.AllocationState; import com.cloud.resource.ResourceManager; +import com.cloud.server.ConfigurationServer; import com.cloud.storage.StorageManager; import com.cloud.storage.dao.VolumeDao; import com.cloud.utils.NumbersUtil; @@ -106,7 +107,8 @@ public class AlertManagerImpl extends ManagerBase implements AlertManager { @Inject private PrimaryDataStoreDao _storagePoolDao; @Inject private ConfigurationDao _configDao; @Inject private ResourceManager _resourceMgr; - @Inject private ConfigurationManager _configMgr; + @Inject private ConfigurationManager _configMgr; + @Inject ConfigurationServer _configServer; private Timer _timer = null; private float _cpuOverProvisioningFactor = 1; private long _capacityCheckPeriod = 60L * 60L * 1000L; // one hour by default @@ -562,19 +564,33 @@ public class AlertManagerImpl extends ManagerBase implements AlertManager { float overProvFactor = 1f; capacity = _capacityDao.findCapacityBy(capacityType.intValue(), cluster.getDataCenterId(), null, cluster.getId()); - if (capacityType == Capacity.CAPACITY_TYPE_STORAGE){ - capacity.add(getUsedStats(capacityType, cluster.getDataCenterId(), cluster.getPodId(), cluster.getId())); + // cpu and memory allocated capacity notification threshold can be defined at cluster level, so getting the value if they are defined at cluster level + double capacityValue = 0; + switch (capacityType) { + case Capacity.CAPACITY_TYPE_STORAGE: + capacity.add(getUsedStats(capacityType, cluster.getDataCenterId(), cluster.getPodId(), cluster.getId())); + capacityValue = Double.parseDouble(_configServer.getConfigValue(Config.StorageCapacityThreshold.key(), Config.ConfigurationParameterScope.cluster.toString(), cluster.getId())); + break; + case Capacity.CAPACITY_TYPE_STORAGE_ALLOCATED: + capacityValue = Double.parseDouble(_configServer.getConfigValue(Config.StorageAllocatedCapacityThreshold.key(), Config.ConfigurationParameterScope.cluster.toString(), cluster.getId())); + break; + case Capacity.CAPACITY_TYPE_CPU: + overProvFactor = ApiDBUtils.getCpuOverprovisioningFactor(); + capacityValue = Double.parseDouble(_configServer.getConfigValue(Config.CPUCapacityThreshold.key(), Config.ConfigurationParameterScope.cluster.toString(), cluster.getId())); + break; + case Capacity.CAPACITY_TYPE_MEMORY: + capacityValue = Double.parseDouble(_configServer.getConfigValue(Config.MemoryCapacityThreshold.key(), Config.ConfigurationParameterScope.cluster.toString(), cluster.getId())); + break; + default: + capacityValue = _capacityTypeThresholdMap.get(capacityType); } if (capacity == null || capacity.size() == 0){ continue; - } - if (capacityType == Capacity.CAPACITY_TYPE_CPU){ - overProvFactor = ApiDBUtils.getCpuOverprovisioningFactor(); } double totalCapacity = capacity.get(0).getTotalCapacity() * overProvFactor; double usedCapacity = capacity.get(0).getUsedCapacity() + capacity.get(0).getReservedCapacity(); - if (totalCapacity != 0 && usedCapacity/totalCapacity > _capacityTypeThresholdMap.get(capacityType)){ + if (totalCapacity != 0 && usedCapacity/totalCapacity > capacityValue){ generateEmailAlert(ApiDBUtils.findZoneById(cluster.getDataCenterId()), ApiDBUtils.findPodById(cluster.getPodId()), cluster, totalCapacity, usedCapacity, capacityType); } diff --git a/server/src/com/cloud/api/ApiDBUtils.java b/server/src/com/cloud/api/ApiDBUtils.java index 21ce63b8ae8..fce1f719086 100755 --- a/server/src/com/cloud/api/ApiDBUtils.java +++ b/server/src/com/cloud/api/ApiDBUtils.java @@ -25,8 +25,6 @@ import java.util.Set; import javax.annotation.PostConstruct; import javax.inject.Inject; -import com.cloud.network.rules.LoadBalancer; -import com.cloud.region.ha.GlobalLoadBalancingRulesService; import org.apache.cloudstack.affinity.AffinityGroup; import org.apache.cloudstack.affinity.AffinityGroupResponse; import org.apache.cloudstack.affinity.dao.AffinityGroupDao; @@ -37,8 +35,8 @@ import org.apache.cloudstack.api.response.AsyncJobResponse; import org.apache.cloudstack.api.response.DiskOfferingResponse; import org.apache.cloudstack.api.response.DomainRouterResponse; import org.apache.cloudstack.api.response.EventResponse; -import org.apache.cloudstack.api.response.HostResponse; import org.apache.cloudstack.api.response.HostForMigrationResponse; +import org.apache.cloudstack.api.response.HostResponse; import org.apache.cloudstack.api.response.InstanceGroupResponse; import org.apache.cloudstack.api.response.ProjectAccountResponse; import org.apache.cloudstack.api.response.ProjectInvitationResponse; @@ -52,6 +50,7 @@ import org.apache.cloudstack.api.response.UserResponse; import org.apache.cloudstack.api.response.UserVmResponse; import org.apache.cloudstack.api.response.VolumeResponse; import org.apache.cloudstack.api.response.ZoneResponse; +import org.apache.cloudstack.lb.dao.ApplicationLoadBalancerRuleDao; import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDao; import org.apache.cloudstack.storage.datastore.db.StoragePoolVO; import org.springframework.stereotype.Component; @@ -130,6 +129,8 @@ import com.cloud.host.HostVO; import com.cloud.host.dao.HostDao; import com.cloud.host.dao.HostDetailsDao; import com.cloud.hypervisor.Hypervisor.HypervisorType; +import com.cloud.network.dao.AccountGuestVlanMapDao; +import com.cloud.network.dao.AccountGuestVlanMapVO; import com.cloud.network.IpAddress; import com.cloud.network.Network; import com.cloud.network.Network.Capability; @@ -155,6 +156,8 @@ import com.cloud.network.as.dao.AutoScaleVmGroupPolicyMapDao; import com.cloud.network.as.dao.AutoScaleVmProfileDao; import com.cloud.network.as.dao.ConditionDao; import com.cloud.network.as.dao.CounterDao; +import com.cloud.network.dao.AccountGuestVlanMapDao; +import com.cloud.network.dao.AccountGuestVlanMapVO; import com.cloud.network.dao.FirewallRulesCidrsDao; import com.cloud.network.dao.FirewallRulesDao; import com.cloud.network.dao.IPAddressDao; @@ -179,6 +182,7 @@ import com.cloud.network.dao.Site2SiteVpnGatewayDao; import com.cloud.network.dao.Site2SiteVpnGatewayVO; import com.cloud.network.router.VirtualRouter; import com.cloud.network.rules.FirewallRuleVO; +import com.cloud.network.rules.LoadBalancer; import com.cloud.network.security.SecurityGroup; import com.cloud.network.security.SecurityGroupManager; import com.cloud.network.security.SecurityGroupVO; @@ -202,6 +206,7 @@ import com.cloud.projects.Project; import com.cloud.projects.ProjectAccount; import com.cloud.projects.ProjectInvitation; import com.cloud.projects.ProjectService; +import com.cloud.region.ha.GlobalLoadBalancingRulesService; import com.cloud.resource.ResourceManager; import com.cloud.server.Criteria; import com.cloud.server.ManagementServer; @@ -309,6 +314,7 @@ public class ApiDBUtils { static GuestOSDao _guestOSDao; static GuestOSCategoryDao _guestOSCategoryDao; static HostDao _hostDao; + static AccountGuestVlanMapDao _accountGuestVlanMapDao; static IPAddressDao _ipAddressDao; static LoadBalancerDao _loadBalancerDao; static SecurityGroupDao _securityGroupDao; @@ -416,6 +422,7 @@ public class ApiDBUtils { @Inject private GuestOSDao guestOSDao; @Inject private GuestOSCategoryDao guestOSCategoryDao; @Inject private HostDao hostDao; + @Inject private AccountGuestVlanMapDao accountGuestVlanMapDao; @Inject private IPAddressDao ipAddressDao; @Inject private LoadBalancerDao loadBalancerDao; @Inject private SecurityGroupDao securityGroupDao; @@ -495,6 +502,7 @@ public class ApiDBUtils { @Inject private VMSnapshotDao vmSnapshotDao; @Inject private NicSecondaryIpDao nicSecondaryIpDao; @Inject private VpcProvisioningService vpcProvSvc; + @Inject private ApplicationLoadBalancerRuleDao _appLbDao; @Inject private AffinityGroupDao affinityGroupDao; @Inject private AffinityGroupJoinDao affinityGroupJoinDao; @Inject private GlobalLoadBalancingRulesService gslbService; @@ -512,6 +520,7 @@ public class ApiDBUtils { _templateMgr = templateMgr; _accountDao = accountDao; + _accountGuestVlanMapDao = accountGuestVlanMapDao; _accountVlanMapDao = accountVlanMapDao; _clusterDao = clusterDao; _capacityDao = capacityDao; @@ -945,6 +954,15 @@ public class ApiDBUtils { } } + public static Long getAccountIdForGuestVlan(long vlanDbId) { + List accountGuestVlanMaps = _accountGuestVlanMapDao.listAccountGuestVlanMapsByVlan(vlanDbId); + if (accountGuestVlanMaps.isEmpty()) { + return null; + } else { + return accountGuestVlanMaps.get(0).getAccountId(); + } + } + public static HypervisorType getVolumeHyperType(long volumeId) { return _volumeDao.getHypervisorType(volumeId); } @@ -1034,7 +1052,7 @@ public class ApiDBUtils { } public static Integer getNetworkRate(long networkOfferingId) { - return _configMgr.getNetworkOfferingNetworkRate(networkOfferingId); + return _configMgr.getNetworkOfferingNetworkRate(networkOfferingId, null); } public static Account getVlanAccount(long vlanId) { diff --git a/server/src/com/cloud/api/ApiResponseHelper.java b/server/src/com/cloud/api/ApiResponseHelper.java index 2820825aa45..ef067636cb1 100755 --- a/server/src/com/cloud/api/ApiResponseHelper.java +++ b/server/src/com/cloud/api/ApiResponseHelper.java @@ -34,101 +34,19 @@ import java.util.TimeZone; import javax.inject.Inject; -import com.cloud.vm.*; import org.apache.cloudstack.acl.ControlledEntity; import org.apache.cloudstack.acl.ControlledEntity.ACLType; +import org.apache.cloudstack.affinity.AffinityGroup; +import org.apache.cloudstack.affinity.AffinityGroupResponse; import org.apache.cloudstack.api.ApiConstants.HostDetails; import org.apache.cloudstack.api.ApiConstants.VMDetails; import org.apache.cloudstack.api.BaseCmd; import org.apache.cloudstack.api.ResponseGenerator; import org.apache.cloudstack.api.command.user.job.QueryAsyncJobResultCmd; -import org.apache.cloudstack.api.response.AccountResponse; -import org.apache.cloudstack.api.response.AsyncJobResponse; -import org.apache.cloudstack.api.response.AutoScalePolicyResponse; -import org.apache.cloudstack.api.response.AutoScaleVmGroupResponse; -import org.apache.cloudstack.api.response.AutoScaleVmProfileResponse; -import org.apache.cloudstack.api.response.CapabilityResponse; -import org.apache.cloudstack.api.response.CapacityResponse; -import org.apache.cloudstack.api.response.ClusterResponse; -import org.apache.cloudstack.api.response.ConditionResponse; -import org.apache.cloudstack.api.response.ConfigurationResponse; -import org.apache.cloudstack.api.response.ControlledEntityResponse; -import org.apache.cloudstack.api.response.ControlledViewEntityResponse; -import org.apache.cloudstack.api.response.CounterResponse; -import org.apache.cloudstack.api.response.CreateCmdResponse; -import org.apache.cloudstack.api.response.DiskOfferingResponse; -import org.apache.cloudstack.api.response.DomainResponse; -import org.apache.cloudstack.api.response.DomainRouterResponse; -import org.apache.cloudstack.api.response.EventResponse; -import org.apache.cloudstack.api.response.ExtractResponse; -import org.apache.cloudstack.api.response.FirewallResponse; -import org.apache.cloudstack.api.response.FirewallRuleResponse; -import org.apache.cloudstack.api.response.GlobalLoadBalancerResponse; -import org.apache.cloudstack.api.response.GuestOSResponse; -import org.apache.cloudstack.api.response.HostResponse; -import org.apache.cloudstack.api.response.HostForMigrationResponse; -import org.apache.cloudstack.api.response.HypervisorCapabilitiesResponse; -import org.apache.cloudstack.api.response.IPAddressResponse; -import org.apache.cloudstack.api.response.InstanceGroupResponse; -import org.apache.cloudstack.api.response.IpForwardingRuleResponse; -import org.apache.cloudstack.api.response.LBHealthCheckPolicyResponse; -import org.apache.cloudstack.api.response.LBHealthCheckResponse; -import org.apache.cloudstack.api.response.LBStickinessPolicyResponse; -import org.apache.cloudstack.api.response.LBStickinessResponse; -import org.apache.cloudstack.api.response.LDAPConfigResponse; -import org.apache.cloudstack.api.response.LoadBalancerResponse; -import org.apache.cloudstack.api.response.NetworkACLResponse; -import org.apache.cloudstack.api.response.NetworkOfferingResponse; -import org.apache.cloudstack.api.response.NetworkResponse; -import org.apache.cloudstack.api.response.NicResponse; -import org.apache.cloudstack.api.response.NicSecondaryIpResponse; -import org.apache.cloudstack.api.response.PhysicalNetworkResponse; -import org.apache.cloudstack.api.response.PodResponse; -import org.apache.cloudstack.api.response.PrivateGatewayResponse; -import org.apache.cloudstack.api.response.ProjectAccountResponse; -import org.apache.cloudstack.api.response.ProjectInvitationResponse; -import org.apache.cloudstack.api.response.ProjectResponse; -import org.apache.cloudstack.api.response.ProviderResponse; -import org.apache.cloudstack.api.response.RegionResponse; -import org.apache.cloudstack.api.response.RemoteAccessVpnResponse; -import org.apache.cloudstack.api.response.ResourceCountResponse; -import org.apache.cloudstack.api.response.ResourceLimitResponse; -import org.apache.cloudstack.api.response.ResourceTagResponse; -import org.apache.cloudstack.api.response.S3Response; -import org.apache.cloudstack.api.response.SecurityGroupResponse; -import org.apache.cloudstack.api.response.SecurityGroupRuleResponse; -import org.apache.cloudstack.api.response.ServiceOfferingResponse; -import org.apache.cloudstack.api.response.ServiceResponse; -import org.apache.cloudstack.api.response.Site2SiteCustomerGatewayResponse; -import org.apache.cloudstack.api.response.Site2SiteVpnConnectionResponse; -import org.apache.cloudstack.api.response.Site2SiteVpnGatewayResponse; -import org.apache.cloudstack.api.response.SnapshotPolicyResponse; -import org.apache.cloudstack.api.response.SnapshotResponse; -import org.apache.cloudstack.api.response.SnapshotScheduleResponse; -import org.apache.cloudstack.api.response.StaticRouteResponse; -import org.apache.cloudstack.api.response.StorageNetworkIpRangeResponse; -import org.apache.cloudstack.api.response.StoragePoolForMigrationResponse; -import org.apache.cloudstack.api.response.StoragePoolResponse; -import org.apache.cloudstack.api.response.SwiftResponse; -import org.apache.cloudstack.api.response.SystemVmInstanceResponse; -import org.apache.cloudstack.api.response.SystemVmResponse; -import org.apache.cloudstack.api.response.TemplatePermissionsResponse; -import org.apache.cloudstack.api.response.TemplateResponse; -import org.apache.cloudstack.api.response.TrafficMonitorResponse; -import org.apache.cloudstack.api.response.TrafficTypeResponse; -import org.apache.cloudstack.api.response.UsageRecordResponse; -import org.apache.cloudstack.api.response.UserResponse; -import org.apache.cloudstack.api.response.UserVmResponse; -import org.apache.cloudstack.api.response.VMSnapshotResponse; -import org.apache.cloudstack.api.response.VirtualRouterProviderResponse; -import org.apache.cloudstack.api.response.VlanIpRangeResponse; -import org.apache.cloudstack.api.response.VolumeResponse; -import org.apache.cloudstack.api.response.VpcOfferingResponse; -import org.apache.cloudstack.api.response.VpcResponse; -import org.apache.cloudstack.api.response.VpnUsersResponse; -import org.apache.cloudstack.api.response.ZoneResponse; +import org.apache.cloudstack.api.response.*; import org.apache.cloudstack.region.PortableIp; import org.apache.cloudstack.region.PortableIpRange; +import org.apache.cloudstack.network.lb.ApplicationLoadBalancerRule; import org.apache.cloudstack.region.Region; import org.apache.cloudstack.storage.datastore.db.StoragePoolVO; import org.apache.cloudstack.usage.Usage; @@ -182,12 +100,15 @@ import com.cloud.event.Event; import com.cloud.host.Host; import com.cloud.host.HostVO; import com.cloud.hypervisor.HypervisorCapabilities; +import com.cloud.network.GuestVlan; import com.cloud.network.IpAddress; import com.cloud.network.Network; import com.cloud.network.Network.Capability; import com.cloud.network.Network.Provider; import com.cloud.network.Network.Service; +import com.cloud.network.NetworkModel; import com.cloud.network.NetworkProfile; +import com.cloud.network.Networks.IsolationType; import com.cloud.network.Networks.TrafficType; import com.cloud.network.PhysicalNetwork; import com.cloud.network.PhysicalNetworkServiceProvider; @@ -213,6 +134,7 @@ import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.FirewallRuleVO; import com.cloud.network.rules.HealthCheckPolicy; import com.cloud.network.rules.LoadBalancer; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.network.rules.PortForwardingRule; import com.cloud.network.rules.StaticNatRule; import com.cloud.network.rules.StickinessPolicy; @@ -226,6 +148,7 @@ import com.cloud.network.vpc.Vpc; import com.cloud.network.vpc.VpcOffering; import com.cloud.offering.DiskOffering; import com.cloud.offering.NetworkOffering; +import com.cloud.offering.NetworkOffering.Detail; import com.cloud.offering.ServiceOffering; import com.cloud.offerings.NetworkOfferingVO; import com.cloud.org.Cluster; @@ -266,39 +189,19 @@ import com.cloud.user.UserContext; import com.cloud.uservm.UserVm; import com.cloud.utils.Pair; import com.cloud.utils.StringUtils; +import com.cloud.utils.net.Ip; import com.cloud.utils.net.NetUtils; +import com.cloud.vm.ConsoleProxyVO; +import com.cloud.vm.InstanceGroup; +import com.cloud.vm.Nic; +import com.cloud.vm.NicProfile; +import com.cloud.vm.NicSecondaryIp; +import com.cloud.vm.NicVO; +import com.cloud.vm.VMInstanceVO; +import com.cloud.vm.VirtualMachine; import com.cloud.vm.VirtualMachine.Type; import com.cloud.vm.dao.NicSecondaryIpVO; import com.cloud.vm.snapshot.VMSnapshot; -import org.apache.cloudstack.acl.ControlledEntity; -import org.apache.cloudstack.acl.ControlledEntity.ACLType; -import org.apache.cloudstack.affinity.AffinityGroup; -import org.apache.cloudstack.affinity.AffinityGroupResponse; -import org.apache.cloudstack.api.ApiConstants.HostDetails; -import org.apache.cloudstack.api.ApiConstants.VMDetails; -import org.apache.cloudstack.api.BaseCmd; -import org.apache.cloudstack.api.ResponseGenerator; -import org.apache.cloudstack.api.command.user.job.QueryAsyncJobResultCmd; -import org.apache.cloudstack.api.response.*; -import org.apache.cloudstack.region.Region; -import org.apache.cloudstack.usage.Usage; -import org.apache.cloudstack.usage.UsageService; -import org.apache.cloudstack.usage.UsageTypes; -import com.cloud.vm.dao.UserVmData; -import com.cloud.vm.dao.UserVmData.NicData; -import com.cloud.vm.dao.UserVmData.SecurityGroupData; -import com.cloud.vm.snapshot.VMSnapshot; -import org.apache.cloudstack.api.ResponseGenerator; -import org.apache.cloudstack.api.response.VMSnapshotResponse; -import org.apache.log4j.Logger; - -import java.text.DecimalFormat; -import java.util.*; - -import javax.inject.Inject; - -import static java.util.Collections.emptyList; -import static java.util.Collections.singletonList; @Component public class ApiResponseHelper implements ResponseGenerator { @@ -307,6 +210,7 @@ public class ApiResponseHelper implements ResponseGenerator { private static final DecimalFormat s_percentFormat = new DecimalFormat("##.##"); @Inject private EntityManager _entityMgr = null; @Inject private UsageService _usageSvc = null; + @Inject NetworkModel _ntwkModel; @Override public UserResponse createUserResponse(User user) { @@ -770,7 +674,7 @@ public class ApiResponseHelper implements ResponseGenerator { } //set tag information - List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.UserVm, loadBalancer.getId()); + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.LoadBalancer, loadBalancer.getId()); List tagResponses = new ArrayList(); for (ResourceTag tag : tags) { ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); @@ -2283,6 +2187,13 @@ public class ApiResponseHelper implements ResponseGenerator { response.setForVpc(ApiDBUtils.isOfferingForVpc(offering)); response.setServices(serviceResponses); + + //set network offering details + Map details = _ntwkModel.getNtwkOffDetails(offering.getId()); + if (details != null && !details.isEmpty()) { + response.setDetails(details); + } + response.setObjectName("networkoffering"); return response; } @@ -2729,6 +2640,25 @@ public class ApiResponseHelper implements ResponseGenerator { return response; } + @Override + public GuestVlanRangeResponse createDedicatedGuestVlanRangeResponse(GuestVlan vlan) { + GuestVlanRangeResponse guestVlanRangeResponse = new GuestVlanRangeResponse(); + + guestVlanRangeResponse.setId(vlan.getUuid()); + Long accountId= ApiDBUtils.getAccountIdForGuestVlan(vlan.getId()); + Account owner = ApiDBUtils.findAccountById(accountId); + if (owner != null) { + populateAccount(guestVlanRangeResponse, owner.getId()); + populateDomain(guestVlanRangeResponse, owner.getDomainId()); + } + guestVlanRangeResponse.setGuestVlanRange(vlan.getGuestVlanRange()); + guestVlanRangeResponse.setPhysicalNetworkId(vlan.getPhysicalNetworkId()); + PhysicalNetworkVO physicalNetwork = ApiDBUtils.findPhysicalNetworkById(vlan.getPhysicalNetworkId()); + guestVlanRangeResponse.setZoneId(physicalNetwork.getDataCenterId()); + + return guestVlanRangeResponse; + } + @Override public ServiceResponse createNetworkServiceResponse(Service service) { ServiceResponse response = new ServiceResponse(); @@ -2827,6 +2757,11 @@ public class ApiResponseHelper implements ResponseGenerator { @Override public VirtualRouterProviderResponse createVirtualRouterProviderResponse(VirtualRouterProvider result) { + //generate only response of the VR/VPCVR provider type + if (!(result.getType() == VirtualRouterProvider.VirtualRouterProviderType.VirtualRouter + || result.getType() == VirtualRouterProvider.VirtualRouterProviderType.VPCVirtualRouter)) { + return null; + } VirtualRouterProviderResponse response = new VirtualRouterProviderResponse(); response.setId(result.getUuid()); PhysicalNetworkServiceProvider nsp = ApiDBUtils.findPhysicalNetworkServiceProviderById(result.getNspId()); @@ -3124,6 +3059,7 @@ public class ApiResponseHelper implements ResponseGenerator { populateAccount(response, result.getAccountId()); populateDomain(response, result.getDomainId()); response.setState(result.getState().toString()); + response.setSourceNat(result.getSourceNat()); response.setObjectName("privategateway"); @@ -3689,6 +3625,73 @@ public class ApiResponseHelper implements ResponseGenerator { return response; } + + @Override + public ApplicationLoadBalancerResponse createLoadBalancerContainerReponse(ApplicationLoadBalancerRule lb, Map lbInstances) { + + ApplicationLoadBalancerResponse lbResponse = new ApplicationLoadBalancerResponse(); + lbResponse.setId(lb.getUuid()); + lbResponse.setName(lb.getName()); + lbResponse.setDescription(lb.getDescription()); + lbResponse.setAlgorithm(lb.getAlgorithm()); + Network nw = ApiDBUtils.findNetworkById(lb.getNetworkId()); + lbResponse.setNetworkId(nw.getUuid()); + populateOwner(lbResponse, lb); + + if (lb.getScheme() == Scheme.Internal) { + lbResponse.setSourceIp(lb.getSourceIp().addr()); + //TODO - create the view for the load balancer rule to reflect the network uuid + Network network = ApiDBUtils.findNetworkById(lb.getNetworkId()); + lbResponse.setSourceIpNetworkId(network.getUuid()); + } else { + //for public, populate the ip information from the ip address + IpAddress publicIp = ApiDBUtils.findIpAddressById(lb.getSourceIpAddressId()); + lbResponse.setSourceIp(publicIp.getAddress().addr()); + Network ntwk = ApiDBUtils.findNetworkById(publicIp.getNetworkId()); + lbResponse.setSourceIpNetworkId(ntwk.getUuid()); + } + + //set load balancer rules information (only one rule per load balancer in this release) + List ruleResponses = new ArrayList(); + ApplicationLoadBalancerRuleResponse ruleResponse = new ApplicationLoadBalancerRuleResponse(); + ruleResponse.setInstancePort(lb.getDefaultPortStart()); + ruleResponse.setSourcePort(lb.getSourcePortStart()); + String stateToSet = lb.getState().toString(); + if (stateToSet.equals(FirewallRule.State.Revoke)) { + stateToSet = "Deleting"; + } + ruleResponse.setState(stateToSet); + ruleResponse.setObjectName("loadbalancerrule"); + ruleResponses.add(ruleResponse); + lbResponse.setLbRules(ruleResponses); + + //set Lb instances information + List instanceResponses = new ArrayList(); + for (Ip ip : lbInstances.keySet()) { + ApplicationLoadBalancerInstanceResponse instanceResponse = new ApplicationLoadBalancerInstanceResponse(); + instanceResponse.setIpAddress(ip.addr()); + UserVm vm = lbInstances.get(ip); + instanceResponse.setId(vm.getUuid()); + instanceResponse.setName(vm.getInstanceName()); + instanceResponse.setObjectName("loadbalancerinstance"); + instanceResponses.add(instanceResponse); + } + + lbResponse.setLbInstances(instanceResponses); + + //set tag information + List tags = ApiDBUtils.listByResourceTypeAndId(TaggedResourceType.LoadBalancer, lb.getId()); + List tagResponses = new ArrayList(); + for (ResourceTag tag : tags) { + ResourceTagResponse tagResponse = createResourceTagResponse(tag, true); + tagResponses.add(tagResponse); + } + lbResponse.setTags(tagResponses); + + lbResponse.setObjectName("loadbalancer"); + return lbResponse; + } + @Override public AffinityGroupResponse createAffinityGroupResponse(AffinityGroup group) { @@ -3779,6 +3782,32 @@ public class ApiResponseHelper implements ResponseGenerator { } response.setState(portableIp.getState().name()); + + return response; + } + + @Override + public InternalLoadBalancerElementResponse createInternalLbElementResponse(VirtualRouterProvider result) { + if (result.getType() != VirtualRouterProvider.VirtualRouterProviderType.InternalLbVm) { + return null; + } + InternalLoadBalancerElementResponse response = new InternalLoadBalancerElementResponse(); + response.setId(result.getUuid()); + PhysicalNetworkServiceProvider nsp = ApiDBUtils.findPhysicalNetworkServiceProviderById(result.getNspId()); + if (nsp != null) { + response.setNspId(nsp.getUuid()); + } + response.setEnabled(result.isEnabled()); + + response.setObjectName("internalloadbalancerelement"); + return response; + } + + @Override + public IsolationMethodResponse createIsolationMethodResponse(IsolationType method) { + IsolationMethodResponse response = new IsolationMethodResponse(); + response.setIsolationMethodName(method.toString()); + response.setObjectName("isolationmethod"); return response; } } diff --git a/server/src/com/cloud/api/ApiServer.java b/server/src/com/cloud/api/ApiServer.java index dd5fd4d5657..497be50a766 100755 --- a/server/src/com/cloud/api/ApiServer.java +++ b/server/src/com/cloud/api/ApiServer.java @@ -48,7 +48,7 @@ import javax.annotation.PostConstruct; import javax.crypto.Mac; import javax.crypto.spec.SecretKeySpec; import javax.inject.Inject; -import javax.servlet.http.HttpServletRequest; +import javax.naming.ConfigurationException; import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpSession; @@ -65,6 +65,7 @@ import org.apache.cloudstack.api.command.admin.host.ListHostsCmd; import org.apache.cloudstack.api.command.admin.router.ListRoutersCmd; import org.apache.cloudstack.api.command.admin.storage.ListStoragePoolsCmd; import org.apache.cloudstack.api.command.admin.user.ListUsersCmd; +import com.cloud.event.ActionEventUtils; import org.apache.cloudstack.api.command.user.account.ListAccountsCmd; import org.apache.cloudstack.api.command.user.account.ListProjectAccountsCmd; import org.apache.cloudstack.api.command.user.event.ListEventsCmd; @@ -122,7 +123,6 @@ import com.cloud.configuration.ConfigurationVO; import com.cloud.configuration.dao.ConfigurationDao; import com.cloud.domain.Domain; import com.cloud.domain.DomainVO; -import com.cloud.event.ActionEventUtils; import com.cloud.exception.AccountLimitException; import com.cloud.exception.CloudAuthenticationException; import com.cloud.exception.InsufficientCapacityException; @@ -142,6 +142,7 @@ import com.cloud.utils.NumbersUtil; import com.cloud.utils.Pair; import com.cloud.utils.StringUtils; import com.cloud.utils.component.ComponentContext; +import com.cloud.utils.component.ManagerBase; import com.cloud.utils.component.PluggableService; import com.cloud.utils.concurrency.NamedThreadFactory; import com.cloud.utils.db.SearchCriteria; @@ -149,7 +150,7 @@ import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; @Component -public class ApiServer implements HttpRequestHandler, ApiServerService { +public class ApiServer extends ManagerBase implements HttpRequestHandler, ApiServerService { private static final Logger s_logger = Logger.getLogger(ApiServer.class.getName()); private static final Logger s_accessLogger = Logger.getLogger("apiserver." + ApiServer.class.getName()); @@ -180,13 +181,19 @@ public class ApiServer implements HttpRequestHandler, ApiServerService { @PostConstruct void initComponent() { s_instance = this; - init(); } public static ApiServer getInstance() { return s_instance; } - + + @Override + public boolean configure(String name, Map params) + throws ConfigurationException { + init(); + return true; + } + public void init() { Integer apiPort = null; // api port, null by default SearchCriteria sc = _configDao.createSearchCriteria(); diff --git a/server/src/com/cloud/api/query/QueryManagerImpl.java b/server/src/com/cloud/api/query/QueryManagerImpl.java index 50018e53efb..808b1efceb1 100644 --- a/server/src/com/cloud/api/query/QueryManagerImpl.java +++ b/server/src/com/cloud/api/query/QueryManagerImpl.java @@ -29,7 +29,9 @@ import javax.inject.Inject; import org.apache.cloudstack.affinity.AffinityGroupResponse; import org.apache.cloudstack.affinity.AffinityGroupVMMapVO; import org.apache.cloudstack.affinity.dao.AffinityGroupVMMapDao; +import org.apache.cloudstack.api.BaseListProjectAndAccountResourcesCmd; import org.apache.cloudstack.api.command.admin.host.ListHostsCmd; +import org.apache.cloudstack.api.command.admin.internallb.ListInternalLBVMsCmd; import org.apache.cloudstack.api.command.admin.router.ListRoutersCmd; import org.apache.cloudstack.api.command.admin.storage.ListStoragePoolsCmd; import org.apache.cloudstack.api.command.admin.user.ListUsersCmd; @@ -981,7 +983,21 @@ public class QueryManagerImpl extends ManagerBase implements QueryService { @Override public ListResponse searchForRouters(ListRoutersCmd cmd) { - Pair, Integer> result = searchForRoutersInternal(cmd); + Pair, Integer> result = searchForRoutersInternal(cmd, cmd.getId(), cmd.getRouterName(), + cmd.getState(), cmd.getZoneId(), cmd.getPodId(), cmd.getHostId(), cmd.getKeyword(), cmd.getNetworkId(), + cmd.getVpcId(), cmd.getForVpc(), cmd.getRole(), cmd.getZoneType()); + ListResponse response = new ListResponse(); + + List routerResponses = ViewResponseHelper.createDomainRouterResponse(result.first().toArray(new DomainRouterJoinVO[result.first().size()])); + response.setResponses(routerResponses, result.second()); + return response; + } + + @Override + public ListResponse searchForInternalLbVms(ListInternalLBVMsCmd cmd) { + Pair, Integer> result = searchForRoutersInternal(cmd, cmd.getId(), cmd.getRouterName(), + cmd.getState(), cmd.getZoneId(), cmd.getPodId(), cmd.getHostId(), cmd.getKeyword(), cmd.getNetworkId(), + cmd.getVpcId(), cmd.getForVpc(), cmd.getRole(), cmd.getZoneType()); ListResponse response = new ListResponse(); List routerResponses = ViewResponseHelper.createDomainRouterResponse(result.first().toArray(new DomainRouterJoinVO[result.first().size()])); @@ -990,18 +1006,9 @@ public class QueryManagerImpl extends ManagerBase implements QueryService { } - private Pair, Integer> searchForRoutersInternal(ListRoutersCmd cmd) { - Long id = cmd.getId(); - String name = cmd.getRouterName(); - String state = cmd.getState(); - Long zoneId = cmd.getZoneId(); - String zoneType = cmd.getZoneType(); - Long pod = cmd.getPodId(); - Long hostId = cmd.getHostId(); - String keyword = cmd.getKeyword(); - Long networkId = cmd.getNetworkId(); - Long vpcId = cmd.getVpcId(); - Boolean forVpc = cmd.getForVpc(); + private Pair, Integer> searchForRoutersInternal(BaseListProjectAndAccountResourcesCmd cmd, Long id, + String name, String state, Long zoneId, Long podId, Long hostId, String keyword, Long networkId, Long vpcId, Boolean forVpc, String role, String zoneType) { + Account caller = UserContext.current().getCaller(); List permittedAccounts = new ArrayList(); @@ -1032,6 +1039,7 @@ public class QueryManagerImpl extends ManagerBase implements QueryService { sb.and("podId", sb.entity().getPodId(), SearchCriteria.Op.EQ); sb.and("hostId", sb.entity().getHostId(), SearchCriteria.Op.EQ); sb.and("vpcId", sb.entity().getVpcId(), SearchCriteria.Op.EQ); + sb.and("role", sb.entity().getRole(), SearchCriteria.Op.EQ); if (forVpc != null) { if (forVpc) { @@ -1073,13 +1081,14 @@ public class QueryManagerImpl extends ManagerBase implements QueryService { sc.setParameters("dataCenterId", zoneId); } + if (podId != null) { + sc.setParameters("podId", podId); + } + if (zoneType != null) { sc.setParameters("dataCenterType", zoneType); } - if (pod != null) { - sc.setParameters("podId", pod); - } if (hostId != null) { sc.setParameters("hostId", hostId); @@ -1092,6 +1101,10 @@ public class QueryManagerImpl extends ManagerBase implements QueryService { if (vpcId != null) { sc.setParameters("vpcId", vpcId); } + + if (role != null) { + sc.setParameters("role", role); + } // search VR details by ids Pair, Integer> uniqueVrPair = _routerJoinDao.searchAndCount(sc, searchFilter); diff --git a/server/src/com/cloud/api/query/dao/DomainRouterJoinDaoImpl.java b/server/src/com/cloud/api/query/dao/DomainRouterJoinDaoImpl.java index 125db17c760..a7a83de14a1 100644 --- a/server/src/com/cloud/api/query/dao/DomainRouterJoinDaoImpl.java +++ b/server/src/com/cloud/api/query/dao/DomainRouterJoinDaoImpl.java @@ -32,6 +32,7 @@ import com.cloud.api.query.vo.DomainRouterJoinVO; import com.cloud.configuration.dao.ConfigurationDao; import com.cloud.network.Networks.TrafficType; import com.cloud.network.router.VirtualRouter; +import com.cloud.network.router.VirtualRouter.Role; import com.cloud.user.Account; import com.cloud.utils.db.GenericDaoBase; import com.cloud.utils.db.SearchBuilder; @@ -156,6 +157,8 @@ public class DomainRouterJoinDaoImpl extends GenericDaoBase volumes = _volumeDao.findByPoolId(pool.getId()); long totalSize = 0; @@ -486,39 +483,39 @@ public class CapacityManagerImpl extends ManagerBase implements CapacityManager, } return totalSize; } - + @Override public long getAllocatedPoolCapacity(StoragePoolVO pool, VMTemplateVO templateForVmCreation){ - + // Get size for all the volumes Pair sizes = _volumeDao.getCountAndTotalByPool(pool.getId()); long totalAllocatedSize = sizes.second() + sizes.first() * _extraBytesPerVolume; - - // Get size for VM Snapshots + + // Get size for VM Snapshots totalAllocatedSize = totalAllocatedSize + getVMSnapshotAllocatedCapacity(pool); // Iterate through all templates on this storage pool boolean tmpinstalled = false; List templatePoolVOs; templatePoolVOs = _templatePoolDao.listByPoolId(pool.getId()); - - for (VMTemplateStoragePoolVO templatePoolVO : templatePoolVOs) { + + for (VMTemplateStoragePoolVO templatePoolVO : templatePoolVOs) { if ((templateForVmCreation != null) && !tmpinstalled && (templatePoolVO.getTemplateId() == templateForVmCreation.getId())) { tmpinstalled = true; } long templateSize = templatePoolVO.getTemplateSize(); totalAllocatedSize += templateSize + _extraBytesPerVolume; } - + // Add the size for the templateForVmCreation if its not already present /*if ((templateForVmCreation != null) && !tmpinstalled) { - + }*/ - + return totalAllocatedSize; } - - + + @DB @Override public void updateCapacityForHost(HostVO host){ @@ -528,7 +525,7 @@ public class CapacityManagerImpl extends ManagerBase implements CapacityManager, for (ServiceOfferingVO offering : offerings) { offeringsMap.put(offering.getId(), offering); } - + long usedCpu = 0; long usedMemory = 0; long reservedMemory = 0; @@ -574,7 +571,7 @@ public class CapacityManagerImpl extends ManagerBase implements CapacityManager, + usedCpu); cpuCap.setUsedCapacity(usedCpu); } - + if (memCap.getUsedCapacity() == usedMemory && memCap.getReservedCapacity() == reservedMemory) { s_logger.debug("No need to calibrate memory capacity, host:" + host.getId() + " usedMem: " + memCap.getUsedCapacity() + " reservedMem: " + memCap.getReservedCapacity()); @@ -591,7 +588,7 @@ public class CapacityManagerImpl extends ManagerBase implements CapacityManager, + " new usedMem: " + usedMemory); memCap.setUsedCapacity(usedMemory); } - + try { _capacityDao.update(cpuCap.getId(), cpuCap); _capacityDao.update(memCap.getId(), memCap); @@ -610,24 +607,24 @@ public class CapacityManagerImpl extends ManagerBase implements CapacityManager, capacity.setReservedCapacity(reservedMemory); capacity.setCapacityState(capacityState); _capacityDao.persist(capacity); - + capacity = new CapacityVO( host.getId(), host.getDataCenterId(), - host.getPodId(), + host.getPodId(), host.getClusterId(), usedCpu, - (long)(host.getCpus().longValue() * host.getSpeed().longValue()), + host.getCpus().longValue() * host.getSpeed().longValue(), CapacityVO.CAPACITY_TYPE_CPU); capacity.setReservedCapacity(reservedCpu); capacity.setCapacityState(capacityState); _capacityDao.persist(capacity); txn.commit(); - + } - + } - + @Override public boolean preStateTransitionEvent(State oldState, Event event, State newState, VirtualMachine vm, boolean transitionStatus, Object opaque) { return true; @@ -681,7 +678,7 @@ public class CapacityManagerImpl extends ManagerBase implements CapacityManager, releaseVmCapacity(vm, false, false, oldHostId); } } - + if ((newState == State.Starting || newState == State.Migrating || event == Event.AgentReportMigrated) && vm.getHostId() != null) { boolean fromLastHost = false; if (vm.getLastHostId() == vm.getHostId()) { @@ -729,7 +726,7 @@ public class CapacityManagerImpl extends ManagerBase implements CapacityManager, _capacityDao.update(CapacityVOCpu.getId(), CapacityVOCpu); } else { CapacityVO capacity = new CapacityVO(server.getId(), server.getDataCenterId(), server.getPodId(), server.getClusterId(), 0L, - (long) (server.getCpus().longValue() * server.getSpeed().longValue()), + server.getCpus().longValue() * server.getSpeed().longValue(), CapacityVO.CAPACITY_TYPE_CPU); _capacityDao.persist(capacity); } @@ -815,32 +812,32 @@ public class CapacityManagerImpl extends ManagerBase implements CapacityManager, @Override public void processCancelMaintenaceEventAfter(Long hostId) { - updateCapacityForHost(_hostDao.findById(hostId)); + updateCapacityForHost(_hostDao.findById(hostId)); } @Override public void processCancelMaintenaceEventBefore(Long hostId) { // TODO Auto-generated method stub - + } @Override - public void processDeletHostEventAfter(HostVO host) { + public void processDeletHostEventAfter(Host host) { // TODO Auto-generated method stub - + } @Override - public void processDeleteHostEventBefore(HostVO host) { + public void processDeleteHostEventBefore(Host host) { // TODO Auto-generated method stub - + } @Override public void processDiscoverEventAfter( Map> resources) { // TODO Auto-generated method stub - + } @Override @@ -848,11 +845,11 @@ public class CapacityManagerImpl extends ManagerBase implements CapacityManager, Long clusterId, URI uri, String username, String password, List hostTags) { // TODO Auto-generated method stub - + } @Override - public void processPrepareMaintenaceEventAfter(Long hostId) { + public void processPrepareMaintenaceEventAfter(Long hostId) { _capacityDao.removeBy(Capacity.CAPACITY_TYPE_MEMORY, null, null, null, hostId); _capacityDao.removeBy(Capacity.CAPACITY_TYPE_CPU, null, null, null, hostId); } @@ -860,7 +857,7 @@ public class CapacityManagerImpl extends ManagerBase implements CapacityManager, @Override public void processPrepareMaintenaceEventBefore(Long hostId) { // TODO Auto-generated method stub - + } @Override @@ -871,7 +868,7 @@ public class CapacityManagerImpl extends ManagerBase implements CapacityManager, Long maxGuestLimit = _hypervisorCapabilitiesDao.getMaxGuestsLimit(hypervisorType, hypervisorVersion); if(vmCount.longValue() >= maxGuestLimit.longValue()){ if (s_logger.isDebugEnabled()) { - s_logger.debug("Host name: " + host.getName() + ", hostId: "+ host.getId() + + s_logger.debug("Host name: " + host.getName() + ", hostId: "+ host.getId() + " already reached max Running VMs(count includes system VMs), limit is: " + maxGuestLimit + ",Running VM counts is: "+vmCount.longValue()); } return true; diff --git a/server/src/com/cloud/capacity/StorageCapacityListener.java b/server/src/com/cloud/capacity/StorageCapacityListener.java index d5751a34cc9..bc03f725e78 100755 --- a/server/src/com/cloud/capacity/StorageCapacityListener.java +++ b/server/src/com/cloud/capacity/StorageCapacityListener.java @@ -16,8 +16,10 @@ // under the License. package com.cloud.capacity; +import java.math.BigDecimal; import java.util.List; +import com.cloud.storage.StorageManager; import org.apache.log4j.Logger; import com.cloud.agent.Listener; @@ -39,14 +41,11 @@ import com.cloud.utils.db.SearchCriteria; public class StorageCapacityListener implements Listener { CapacityDao _capacityDao; - float _overProvisioningFactor = 1.0f; + StorageManager _storageMgr; - - public StorageCapacityListener(CapacityDao _capacityDao, - float _overProvisioningFactor) { - super(); - this._capacityDao = _capacityDao; - this._overProvisioningFactor = _overProvisioningFactor; + public StorageCapacityListener(CapacityDao capacityDao, StorageManager storageMgr) { + this._capacityDao = capacityDao; + this._storageMgr = storageMgr; } @@ -79,9 +78,10 @@ public class StorageCapacityListener implements Listener { StartupStorageCommand ssCmd = (StartupStorageCommand) startup; if (ssCmd.getResourceType() == Storage.StorageResourceType.STORAGE_HOST) { + BigDecimal overProvFactor = _storageMgr.getStorageOverProvisioningFactor(server.getDataCenterId()); CapacityVO capacity = new CapacityVO(server.getId(), server.getDataCenterId(), server.getPodId(), server.getClusterId(), 0L, - (long) (server.getTotalSize() * _overProvisioningFactor), + (overProvFactor.multiply(new BigDecimal(server.getTotalSize()))).longValue(), CapacityVO.CAPACITY_TYPE_STORAGE_ALLOCATED); _capacityDao.persist(capacity); } diff --git a/server/src/com/cloud/cluster/CheckPointVO.java b/server/src/com/cloud/cluster/CheckPointVO.java deleted file mode 100644 index db4f828721a..00000000000 --- a/server/src/com/cloud/cluster/CheckPointVO.java +++ /dev/null @@ -1,121 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.cluster; - -import java.util.Date; - -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.GeneratedValue; -import javax.persistence.GenerationType; -import javax.persistence.Id; -import javax.persistence.Table; - -import com.cloud.utils.db.GenericDao; -import org.apache.cloudstack.api.InternalIdentity; - -@Entity -@Table(name="stack_maid") -public class CheckPointVO implements InternalIdentity { - - @Id - @GeneratedValue(strategy=GenerationType.IDENTITY) - @Column(name="id") - private long id; - - @Column(name="msid") - private long msid; - - @Column(name="thread_id") - private long threadId; - - @Column(name="seq") - private long seq; - - @Column(name="cleanup_delegate", length=128) - private String delegate; - - @Column(name="cleanup_context", length=65535) - private String context; - - @Column(name=GenericDao.CREATED_COLUMN) - private Date created; - - public CheckPointVO() { - } - - public CheckPointVO(long seq) { - this.seq = seq; - } - - public long getId() { - return id; - } - - public long getMsid() { - return msid; - } - - public void setMsid(long msid) { - this.msid = msid; - } - - public long getThreadId() { - return threadId; - } - - public void setThreadId(long threadId) { - this.threadId = threadId; - } - - public long getSeq() { - return seq; - } - - public void setSeq(long seq) { - this.seq = seq; - } - - public String getDelegate() { - return delegate; - } - - public void setDelegate(String delegate) { - this.delegate = delegate; - } - - public String getContext() { - return context; - } - - public void setContext(String context) { - this.context = context; - } - - public Date getCreated() { - return this.created; - } - - public void setCreated(Date created) { - this.created = created; - } - - @Override - public String toString() { - return new StringBuilder("Task[").append(id).append("-").append(context).append("-").append(delegate).append("]").toString(); - } -} diff --git a/server/src/com/cloud/cluster/dao/StackMaidDao.java b/server/src/com/cloud/cluster/dao/StackMaidDao.java deleted file mode 100644 index eb13b5cb2c2..00000000000 --- a/server/src/com/cloud/cluster/dao/StackMaidDao.java +++ /dev/null @@ -1,44 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.cluster.dao; - -import java.util.Date; -import java.util.List; - -import com.cloud.cluster.CheckPointVO; -import com.cloud.utils.db.GenericDao; - -public interface StackMaidDao extends GenericDao { - public long pushCleanupDelegate(long msid, int seq, String delegateClzName, Object context); - public CheckPointVO popCleanupDelegate(long msid); - public void clearStack(long msid); - - public List listLeftoversByMsid(long msid); - public List listLeftoversByCutTime(Date cutTime); - - /** - * Take over the task items of another management server and clean them up. - * - * @param takeOverMsid management server id to take over. - * @param selfId the management server id of this node. - * @return list of tasks to take over. - */ - boolean takeover(long takeOverMsid, long selfId); - - List listCleanupTasks(long selfId); - List listLeftoversByCutTime(Date cutTime, long msid); -} diff --git a/server/src/com/cloud/cluster/dao/StackMaidDaoImpl.java b/server/src/com/cloud/cluster/dao/StackMaidDaoImpl.java deleted file mode 100644 index 243b00ff4a3..00000000000 --- a/server/src/com/cloud/cluster/dao/StackMaidDaoImpl.java +++ /dev/null @@ -1,208 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.cluster.dao; - -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.SQLException; -import java.util.ArrayList; -import java.util.Date; -import java.util.List; -import java.util.TimeZone; - -import javax.ejb.Local; - -import org.apache.log4j.Logger; -import org.springframework.stereotype.Component; - -import com.cloud.cluster.CheckPointVO; -import com.cloud.serializer.SerializerHelper; -import com.cloud.utils.DateUtil; -import com.cloud.utils.db.DB; -import com.cloud.utils.db.Filter; -import com.cloud.utils.db.GenericDaoBase; -import com.cloud.utils.db.SearchBuilder; -import com.cloud.utils.db.SearchCriteria; -import com.cloud.utils.db.SearchCriteria.Op; -import com.cloud.utils.db.Transaction; - -@Component -@Local(value = { StackMaidDao.class }) @DB(txn=false) -public class StackMaidDaoImpl extends GenericDaoBase implements StackMaidDao { - private static final Logger s_logger = Logger.getLogger(StackMaidDaoImpl.class); - - private SearchBuilder popSearch; - private SearchBuilder clearSearch; - private final SearchBuilder AllFieldsSearch; - - public StackMaidDaoImpl() { - popSearch = createSearchBuilder(); - popSearch.and("msid", popSearch.entity().getMsid(), SearchCriteria.Op.EQ); - popSearch.and("threadId", popSearch.entity().getThreadId(), SearchCriteria.Op.EQ); - - clearSearch = createSearchBuilder(); - clearSearch.and("msid", clearSearch.entity().getMsid(), SearchCriteria.Op.EQ); - - AllFieldsSearch = createSearchBuilder(); - AllFieldsSearch.and("msid", AllFieldsSearch.entity().getMsid(), Op.EQ); - AllFieldsSearch.and("thread", AllFieldsSearch.entity().getThreadId(), Op.EQ); - AllFieldsSearch.done(); - } - - @Override - public boolean takeover(long takeOverMsid, long selfId) { - CheckPointVO task = createForUpdate(); - task.setMsid(selfId); - task.setThreadId(0); - - SearchCriteria sc = AllFieldsSearch.create(); - sc.setParameters("msid", takeOverMsid); - return update(task, sc) > 0; - - } - - @Override - public List listCleanupTasks(long msId) { - SearchCriteria sc = AllFieldsSearch.create(); - sc.setParameters("msid", msId); - sc.setParameters("thread", 0); - - return this.search(sc, null); - } - - @Override - public long pushCleanupDelegate(long msid, int seq, String delegateClzName, Object context) { - CheckPointVO delegateItem = new CheckPointVO(); - delegateItem.setMsid(msid); - delegateItem.setThreadId(Thread.currentThread().getId()); - delegateItem.setSeq(seq); - delegateItem.setDelegate(delegateClzName); - delegateItem.setContext(SerializerHelper.toSerializedStringOld(context)); - delegateItem.setCreated(DateUtil.currentGMTTime()); - - super.persist(delegateItem); - return delegateItem.getId(); - } - - @Override - public CheckPointVO popCleanupDelegate(long msid) { - SearchCriteria sc = popSearch.create(); - sc.setParameters("msid", msid); - sc.setParameters("threadId", Thread.currentThread().getId()); - - Filter filter = new Filter(CheckPointVO.class, "seq", false, 0L, (long)1); - List l = listIncludingRemovedBy(sc, filter); - if(l != null && l.size() > 0) { - expunge(l.get(0).getId()); - return l.get(0); - } - - return null; - } - - @Override - public void clearStack(long msid) { - SearchCriteria sc = clearSearch.create(); - sc.setParameters("msid", msid); - - expunge(sc); - } - - @Override - @DB - public List listLeftoversByMsid(long msid) { - List l = new ArrayList(); - String sql = "select * from stack_maid where msid=? order by msid asc, thread_id asc, seq desc"; - - Transaction txn = Transaction.currentTxn(); - PreparedStatement pstmt = null; - try { - pstmt = txn.prepareAutoCloseStatement(sql); - pstmt.setLong(1, msid); - - ResultSet rs = pstmt.executeQuery(); - while(rs.next()) { - l.add(toEntityBean(rs, false)); - } - } catch (SQLException e) { - s_logger.error("unexcpected exception " + e.getMessage(), e); - } catch (Throwable e) { - s_logger.error("unexcpected exception " + e.getMessage(), e); - } finally { - txn.close(); - } - return l; - } - - @Override - @DB - public List listLeftoversByCutTime(Date cutTime) { - - List l = new ArrayList(); - String sql = "select * from stack_maid where created < ? order by msid asc, thread_id asc, seq desc"; - - Transaction txn = Transaction.open(Transaction.CLOUD_DB); - PreparedStatement pstmt = null; - try { - pstmt = txn.prepareAutoCloseStatement(sql); - String gmtCutTime = DateUtil.getDateDisplayString(TimeZone.getTimeZone("GMT"), cutTime); - pstmt.setString(1, gmtCutTime); - - ResultSet rs = pstmt.executeQuery(); - while(rs.next()) { - l.add(toEntityBean(rs, false)); - } - } catch (SQLException e) { - s_logger.error("unexcpected exception " + e.getMessage(), e); - } catch (Throwable e) { - s_logger.error("unexcpected exception " + e.getMessage(), e); - } finally { - txn.close(); - } - return l; - } - - @Override - @DB - public List listLeftoversByCutTime(Date cutTime, long msid) { - - List l = new ArrayList(); - String sql = "select * from stack_maid where created < ? and msid = ? order by msid asc, thread_id asc, seq desc"; - - Transaction txn = Transaction.open(Transaction.CLOUD_DB); - PreparedStatement pstmt = null; - try { - pstmt = txn.prepareAutoCloseStatement(sql); - String gmtCutTime = DateUtil.getDateDisplayString(TimeZone.getTimeZone("GMT"), cutTime); - pstmt.setString(1, gmtCutTime); - pstmt.setLong(2, msid); - - ResultSet rs = pstmt.executeQuery(); - while(rs.next()) { - l.add(toEntityBean(rs, false)); - } - } catch (SQLException e) { - s_logger.error("unexcpected exception " + e.getMessage(), e); - } catch (Throwable e) { - s_logger.error("unexcpected exception " + e.getMessage(), e); - } finally { - txn.close(); - } - return l; - } -} - diff --git a/server/src/com/cloud/configuration/Config.java b/server/src/com/cloud/configuration/Config.java index dbcbc5332d0..77ca2de1923 100755 --- a/server/src/com/cloud/configuration/Config.java +++ b/server/src/com/cloud/configuration/Config.java @@ -51,25 +51,25 @@ public enum Config { AlertSMTPUsername("Alert", ManagementServer.class, String.class, "alert.smtp.username", null, "Username for SMTP authentication (applies only if alert.smtp.useAuth is true).", null), AlertWait("Alert", AgentManager.class, Integer.class, "alert.wait", null, "Seconds to wait before alerting on a disconnected agent", null), CapacityCheckPeriod("Alert", ManagementServer.class, Integer.class, "capacity.check.period", "300000", "The interval in milliseconds between capacity checks", null), - StorageAllocatedCapacityThreshold("Alert", ManagementServer.class, Float.class, "cluster.storage.allocated.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of allocated storage utilization above which alerts will be sent about low storage available.", null), - StorageCapacityThreshold("Alert", ManagementServer.class, Float.class, "cluster.storage.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of storage utilization above which alerts will be sent about low storage available.", null), - CPUCapacityThreshold("Alert", ManagementServer.class, Float.class, "cluster.cpu.allocated.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of cpu utilization above which alerts will be sent about low cpu available.", null), - MemoryCapacityThreshold("Alert", ManagementServer.class, Float.class, "cluster.memory.allocated.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of memory utilization above which alerts will be sent about low memory available.", null), + StorageAllocatedCapacityThreshold("Alert", ManagementServer.class, Float.class, "cluster.storage.allocated.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of allocated storage utilization above which alerts will be sent about low storage available.", null, ConfigurationParameterScope.cluster.toString()), + StorageCapacityThreshold("Alert", ManagementServer.class, Float.class, "cluster.storage.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of storage utilization above which alerts will be sent about low storage available.", null, ConfigurationParameterScope.cluster.toString()), + CPUCapacityThreshold("Alert", ManagementServer.class, Float.class, "cluster.cpu.allocated.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of cpu utilization above which alerts will be sent about low cpu available.", null, ConfigurationParameterScope.cluster.toString()), + MemoryCapacityThreshold("Alert", ManagementServer.class, Float.class, "cluster.memory.allocated.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of memory utilization above which alerts will be sent about low memory available.", null, ConfigurationParameterScope.cluster.toString()), PublicIpCapacityThreshold("Alert", ManagementServer.class, Float.class, "zone.virtualnetwork.publicip.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of public IP address space utilization above which alerts will be sent.", null), PrivateIpCapacityThreshold("Alert", ManagementServer.class, Float.class, "pod.privateip.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of private IP address space utilization above which alerts will be sent.", null), SecondaryStorageCapacityThreshold("Alert", ManagementServer.class, Float.class, "zone.secstorage.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of secondary storage utilization above which alerts will be sent about low storage available.", null), VlanCapacityThreshold("Alert", ManagementServer.class, Float.class, "zone.vlan.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of Zone Vlan utilization above which alerts will be sent about low number of Zone Vlans.", null), DirectNetworkPublicIpCapacityThreshold("Alert", ManagementServer.class, Float.class, "zone.directnetwork.publicip.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of Direct Network Public Ip Utilization above which alerts will be sent about low number of direct network public ips.", null), LocalStorageCapacityThreshold("Alert", ManagementServer.class, Float.class, "cluster.localStorage.capacity.notificationthreshold", "0.75", "Percentage (as a value between 0 and 1) of local storage utilization above which alerts will be sent about low local storage available.", null), - StorageAllocatedCapacityDisableThreshold("Alert", ManagementServer.class, Float.class, "pool.storage.allocated.capacity.disablethreshold", "0.85", "Percentage (as a value between 0 and 1) of allocated storage utilization above which allocators will disable using the pool for low allocated storage available.", null), - StorageCapacityDisableThreshold("Alert", ManagementServer.class, Float.class, "pool.storage.capacity.disablethreshold", "0.85", "Percentage (as a value between 0 and 1) of storage utilization above which allocators will disable using the pool for low storage available.", null), - CPUCapacityDisableThreshold("Alert", ManagementServer.class, Float.class, "cluster.cpu.allocated.capacity.disablethreshold", "0.85", "Percentage (as a value between 0 and 1) of cpu utilization above which allocators will disable using the cluster for low cpu available. Keep the corresponding notification threshold lower than this to be notified beforehand.", null), - MemoryCapacityDisableThreshold("Alert", ManagementServer.class, Float.class, "cluster.memory.allocated.capacity.disablethreshold", "0.85", "Percentage (as a value between 0 and 1) of memory utilization above which allocators will disable using the cluster for low memory available. Keep the corresponding notification threshold lower than this to be notified beforehand.", null), + StorageAllocatedCapacityDisableThreshold("Alert", ManagementServer.class, Float.class, "pool.storage.allocated.capacity.disablethreshold", "0.85", "Percentage (as a value between 0 and 1) of allocated storage utilization above which allocators will disable using the pool for low allocated storage available.", null, ConfigurationParameterScope.zone.toString()), + StorageCapacityDisableThreshold("Alert", ManagementServer.class, Float.class, "pool.storage.capacity.disablethreshold", "0.85", "Percentage (as a value between 0 and 1) of storage utilization above which allocators will disable using the pool for low storage available.", null, ConfigurationParameterScope.zone.toString()), + CPUCapacityDisableThreshold("Alert", ManagementServer.class, Float.class, "cluster.cpu.allocated.capacity.disablethreshold", "0.85", "Percentage (as a value between 0 and 1) of cpu utilization above which allocators will disable using the cluster for low cpu available. Keep the corresponding notification threshold lower than this to be notified beforehand.", null, ConfigurationParameterScope.cluster.toString()), + MemoryCapacityDisableThreshold("Alert", ManagementServer.class, Float.class, "cluster.memory.allocated.capacity.disablethreshold", "0.85", "Percentage (as a value between 0 and 1) of memory utilization above which allocators will disable using the cluster for low memory available. Keep the corresponding notification threshold lower than this to be notified beforehand.", null, ConfigurationParameterScope.cluster.toString()), // Storage - StorageOverprovisioningFactor("Storage", StoragePoolAllocator.class, String.class, "storage.overprovisioning.factor", "2", "Used for storage overprovisioning calculation; available storage will be (actualStorageSize * storage.overprovisioning.factor)", null), + StorageOverprovisioningFactor("Storage", StoragePoolAllocator.class, String.class, "storage.overprovisioning.factor", "2", "Used for storage overprovisioning calculation; available storage will be (actualStorageSize * storage.overprovisioning.factor)", null, ConfigurationParameterScope.zone.toString()), StorageStatsInterval("Storage", ManagementServer.class, String.class, "storage.stats.interval", "60000", "The interval (in milliseconds) when storage stats (per host) are retrieved from agents.", null), MaxVolumeSize("Storage", ManagementServer.class, Integer.class, "storage.max.volume.size", "2000", "The maximum size for a volume (in GB).", null), MaxUploadVolumeSize("Storage", ManagementServer.class, Integer.class, "storage.max.volume.upload.size", "500", "The maximum size for a uploaded volume(in GB).", null), @@ -93,8 +93,8 @@ public enum Config { GuestVlanBits("Network", ManagementServer.class, Integer.class, "guest.vlan.bits", "12", "The number of bits to reserve for the VLAN identifier in the guest subnet.", null), //MulticastThrottlingRate("Network", ManagementServer.class, Integer.class, "multicast.throttling.rate", "10", "Default multicast rate in megabits per second allowed.", null), - NetworkThrottlingRate("Network", ManagementServer.class, Integer.class, "network.throttling.rate", "200", "Default data transfer rate in megabits per second allowed in network.", null), - GuestDomainSuffix("Network", AgentManager.class, String.class, "guest.domain.suffix", "cloud.internal", "Default domain name for vms inside virtualized networks fronted by router", null), + NetworkThrottlingRate("Network", ManagementServer.class, Integer.class, "network.throttling.rate", "200", "Default data transfer rate in megabits per second allowed in network.", null, ConfigurationParameterScope.zone.toString()), + GuestDomainSuffix("Network", AgentManager.class, String.class, "guest.domain.suffix", "cloud.internal", "Default domain name for vms inside virtualized networks fronted by router", null, ConfigurationParameterScope.zone.toString()), DirectNetworkNoDefaultRoute("Network", ManagementServer.class, Boolean.class, "direct.network.no.default.route", "false", "Direct Network Dhcp Server should not send a default route", "true/false"), OvsTunnelNetwork("Network", ManagementServer.class, Boolean.class, "sdn.ovs.controller", "false", "Enable/Disable Open vSwitch SDN controller for L2-in-L3 overlay networks", null), OvsTunnelNetworkDefaultLabel("Network", ManagementServer.class, String.class, "sdn.ovs.controller.default.label", "cloud-public", "Default network label to be used when fetching interface for GRE endpoints", null), @@ -112,7 +112,7 @@ public enum Config { //VPN RemoteAccessVpnPskLength("Network", AgentManager.class, Integer.class, "remote.access.vpn.psk.length", "24", "The length of the ipsec preshared key (minimum 8, maximum 256)", null), - RemoteAccessVpnClientIpRange("Network", AgentManager.class, String.class, "remote.access.vpn.client.iprange", "10.1.2.1-10.1.2.8", "The range of ips to be allocated to remote access vpn clients. The first ip in the range is used by the VPN server", null), + RemoteAccessVpnClientIpRange("Network", AgentManager.class, String.class, "remote.access.vpn.client.iprange", "10.1.2.1-10.1.2.8", "The range of ips to be allocated to remote access vpn clients. The first ip in the range is used by the VPN server", null, ConfigurationParameterScope.account.toString()), RemoteAccessVpnUserLimit("Network", AgentManager.class, String.class, "remote.access.vpn.user.limit", "8", "The maximum number of VPN users that can be created per account", null), Site2SiteVpnConnectionPerVpnGatewayLimit("Network", ManagementServer.class, Integer.class, "site2site.vpn.vpngateway.connection.limit", "4", "The maximum number of VPN connection per VPN gateway", null), Site2SiteVpnSubnetsPerCustomerGatewayLimit("Network", ManagementServer.class, Integer.class, "site2site.vpn.customergateway.subnets.limit", "10", "The maximum number of subnets per customer gateway", null), @@ -149,7 +149,7 @@ public enum Config { S3Enable("Advanced", ManagementServer.class, Boolean.class, "s3.enable", "false", "enable s3 ", null), EventPurgeInterval("Advanced", ManagementServer.class, Integer.class, "event.purge.interval", "86400", "The interval (in seconds) to wait before running the event purge thread", null), AccountCleanupInterval("Advanced", ManagementServer.class, Integer.class, "account.cleanup.interval", "86400", "The interval (in seconds) between cleanup for removed accounts", null), - AllowPublicUserTemplates("Advanced", ManagementServer.class, Integer.class, "allow.public.user.templates", "true", "If false, users will not be able to create public templates.", null), + AllowPublicUserTemplates("Advanced", ManagementServer.class, Integer.class, "allow.public.user.templates", "true", "If false, users will not be able to create public templates.", null, ConfigurationParameterScope.account.toString()), InstanceName("Advanced", AgentManager.class, String.class, "instance.name", "VM", "Name of the deployment instance.", "instanceName"), ExpungeDelay("Advanced", UserVmManager.class, Integer.class, "expunge.delay", "86400", "Determines how long (in seconds) to wait before actually expunging destroyed vm. The default value = the default value of expunge.interval", null), ExpungeInterval("Advanced", UserVmManager.class, Integer.class, "expunge.interval", "86400", "The interval (in seconds) to wait before running the expunge thread.", null), @@ -173,6 +173,11 @@ public enum Config { RouterCheckInterval("Advanced", NetworkManager.class, Integer.class, "router.check.interval", "30", "Interval (in seconds) to report redundant router status.", null), RouterCheckPoolSize("Advanced", NetworkManager.class, Integer.class, "router.check.poolsize", "10", "Numbers of threads using to check redundant router status.", null), RouterTemplateId("Advanced", NetworkManager.class, Long.class, "router.template.id", "1", "Default ID for template.", null), + RouterTemplateXen("Advanced", NetworkManager.class, String.class, "router.template.xen", "SystemVM Template (XenServer)", "Name of the default router template on Xenserver.", null, ConfigurationParameterScope.zone.toString()), + RouterTemplateKVM("Advanced", NetworkManager.class, String.class, "router.template.kvm", "SystemVM Template (KVM)", "Name of the default router template on KVM.", null, ConfigurationParameterScope.zone.toString()), + RouterTemplateVmware("Advanced", NetworkManager.class, String.class, "router.template.vmware", "SystemVM Template (vSphere)", "Name of the default router template on Vmware.", null, ConfigurationParameterScope.zone.toString()), + RouterTemplateHyperv("Advanced", NetworkManager.class, String.class, "router.template.hyperv", "SystemVM Template (HyperV)", "Name of the default router template on Hyperv.", null, ConfigurationParameterScope.zone.toString()), + RouterTemplateLXC("Advanced", NetworkManager.class, String.class, "router.template.lxc", "SystemVM Template (LXC)", "Name of the default router template on LXC.", null, ConfigurationParameterScope.zone.toString()), RouterExtraPublicNics("Advanced", NetworkManager.class, Integer.class, "router.extra.public.nics", "2", "specify extra public nics used for virtual router(up to 5)", "0-5"), StartRetry("Advanced", AgentManager.class, Integer.class, "start.retry", "10", "Number of times to retry create and start commands", null), ScaleRetry("Advanced", AgentManager.class, Integer.class, "scale.retry", "2", "Number of times to retry scaling up the vm", null), @@ -191,8 +196,8 @@ public enum Config { SystemVMAutoReserveCapacity("Advanced", ManagementServer.class, Boolean.class, "system.vm.auto.reserve.capacity", "true", "Indicates whether or not to automatically reserver system VM standby capacity.", null), SystemVMDefaultHypervisor("Advanced", ManagementServer.class, String.class, "system.vm.default.hypervisor", null, "Hypervisor type used to create system vm", null), SystemVMRandomPassword("Advanced", ManagementServer.class, Boolean.class, "system.vm.random.password", "false", "Randomize system vm password the first time management server starts", null), - CPUOverprovisioningFactor("Advanced", ManagementServer.class, String.class, "cpu.overprovisioning.factor", "1", "Used for CPU overprovisioning calculation; available CPU will be (actualCpuCapacity * cpu.overprovisioning.factor)", null), - MemOverprovisioningFactor("Advanced", ManagementServer.class, String.class, "mem.overprovisioning.factor", "1", "Used for memory overprovisioning calculation", null), + CPUOverprovisioningFactor("Advanced", ManagementServer.class, String.class, "cpu.overprovisioning.factor", "1", "Used for CPU overprovisioning calculation; available CPU will be (actualCpuCapacity * cpu.overprovisioning.factor)", null, ConfigurationParameterScope.cluster.toString()), + MemOverprovisioningFactor("Advanced", ManagementServer.class, String.class, "mem.overprovisioning.factor", "1", "Used for memory overprovisioning calculation", null, ConfigurationParameterScope.cluster.toString()), LinkLocalIpNums("Advanced", ManagementServer.class, Integer.class, "linkLocalIp.nums", "10", "The number of link local ip that needed by domR(in power of 2)", null), HypervisorList("Advanced", ManagementServer.class, String.class, "hypervisor.list", HypervisorType.KVM + "," + HypervisorType.XenServer + "," + HypervisorType.VMware + "," + HypervisorType.BareMetal + "," + HypervisorType.Ovm + "," + HypervisorType.LXC, "The list of hypervisors that this deployment will use.", "hypervisorList"), ManagementHostIPAdr("Advanced", ManagementServer.class, String.class, "host", "localhost", "The ip address of management server", null), @@ -403,7 +408,10 @@ public enum Config { CloudDnsName("Advanced", ManagementServer.class, String.class, "cloud.dns.name", "default", " DNS name of the cloud", null), BlacklistedRoutes("Advanced", VpcManager.class, String.class, "blacklisted.routes", null, "Routes that are blacklisted, can not be used for Static Routes creation for the VPC Private Gateway", - "routes", ConfigurationParameterScope.zone.toString()); + "routes", ConfigurationParameterScope.zone.toString()), + + InternalLbVmServiceOfferingId("Advanced", ManagementServer.class, Long.class, "internallbvm.service.offering", null, "Uuid of the service offering used by internal lb vm; if NULL - default system internal lb offering will be used", null); + private final String _category; @@ -419,7 +427,7 @@ public enum Config { global, zone, cluster, - pool, + storagepool, account } @@ -427,7 +435,7 @@ public enum Config { static { _scopeLevelConfigsMap.put(ConfigurationParameterScope.zone.toString(), new ArrayList()); _scopeLevelConfigsMap.put(ConfigurationParameterScope.cluster.toString(), new ArrayList()); - _scopeLevelConfigsMap.put(ConfigurationParameterScope.pool.toString(), new ArrayList()); + _scopeLevelConfigsMap.put(ConfigurationParameterScope.storagepool.toString(), new ArrayList()); _scopeLevelConfigsMap.put(ConfigurationParameterScope.account.toString(), new ArrayList()); _scopeLevelConfigsMap.put(ConfigurationParameterScope.global.toString(), new ArrayList()); diff --git a/server/src/com/cloud/configuration/ConfigurationManager.java b/server/src/com/cloud/configuration/ConfigurationManager.java index 738c5bab35d..d2f831905ee 100755 --- a/server/src/com/cloud/configuration/ConfigurationManager.java +++ b/server/src/com/cloud/configuration/ConfigurationManager.java @@ -30,13 +30,13 @@ import com.cloud.dc.Vlan; import com.cloud.exception.ConcurrentOperationException; import com.cloud.exception.InsufficientCapacityException; import com.cloud.exception.InvalidParameterValueException; -import com.cloud.exception.ResourceAllocationException; import com.cloud.network.Network; import com.cloud.network.Network.Capability; import com.cloud.network.Network.Provider; import com.cloud.network.Network.Service; import com.cloud.network.Networks.TrafficType; import com.cloud.offering.DiskOffering; +import com.cloud.offering.NetworkOffering; import com.cloud.offering.NetworkOffering.Availability; import com.cloud.offerings.NetworkOfferingVO; import com.cloud.org.Grouping.AllocationState; @@ -60,7 +60,7 @@ public interface ConfigurationManager extends ConfigurationService, Manager { * @param name * @param value */ - void updateConfiguration(long userId, String name, String category, String value, String scope, Long id); + String updateConfiguration(long userId, String name, String category, String value, String scope, Long id); /** * Creates a new service offering @@ -179,8 +179,6 @@ public interface ConfigurationManager extends ConfigurationService, Manager { * @param trafficType * @param tags * @param specifyVlan - * @param isPersistent - * ; * @param networkRate * TODO * @param serviceProviderMap @@ -196,14 +194,16 @@ public interface ConfigurationManager extends ConfigurationService, Manager { * ; * @param specifyIpRanges * TODO + * @param isPersistent + * ; + * @param details TODO * @param id - * * @return network offering object */ NetworkOfferingVO createNetworkOffering(String name, String displayText, TrafficType trafficType, String tags, boolean specifyVlan, Availability availability, Integer networkRate, Map> serviceProviderMap, boolean isDefault, Network.GuestType type, boolean systemOnly, Long serviceOfferingId, boolean conserveMode, Map> serviceCapabilityMap, - boolean specifyIpRanges, boolean isPersistent); + boolean specifyIpRanges, boolean isPersistent, Map details); Vlan createVlanAndPublicIpRange(long zoneId, long networkId, long physicalNetworkId, boolean forVirtualNetwork, Long podId, String startIP, String endIP, String vlanGateway, String vlanNetmask, String vlanId, Account vlanOwner, String startIPv6, String endIPv6, String vlanIp6Gateway, String vlanIp6Cidr) throws InsufficientCapacityException, ConcurrentOperationException, InvalidParameterValueException; diff --git a/server/src/com/cloud/configuration/ConfigurationManagerImpl.java b/server/src/com/cloud/configuration/ConfigurationManagerImpl.java index daaf5963dea..bc7583d00f3 100755 --- a/server/src/com/cloud/configuration/ConfigurationManagerImpl.java +++ b/server/src/com/cloud/configuration/ConfigurationManagerImpl.java @@ -39,7 +39,11 @@ import javax.naming.NamingException; import javax.naming.directory.DirContext; import javax.naming.directory.InitialDirContext; + +import com.cloud.dc.*; import com.cloud.dc.dao.*; +import com.cloud.user.*; +import com.cloud.event.UsageEventUtils; import org.apache.cloudstack.acl.SecurityChecker; import org.apache.cloudstack.api.ApiConstants.LDAPParams; import org.apache.cloudstack.api.command.admin.config.UpdateCfgCmd; @@ -69,6 +73,10 @@ import org.apache.cloudstack.api.command.admin.zone.UpdateZoneCmd; import org.apache.cloudstack.api.command.user.network.ListNetworkOfferingsCmd; import org.apache.cloudstack.region.*; import org.apache.cloudstack.region.dao.RegionDao; +import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDao; +import org.apache.cloudstack.storage.datastore.db.StoragePoolDetailVO; +import org.apache.cloudstack.storage.datastore.db.StoragePoolDetailsDao; +import org.apache.cloudstack.storage.datastore.db.StoragePoolVO; import org.apache.log4j.Logger; import org.springframework.stereotype.Component; @@ -77,20 +85,19 @@ import com.cloud.api.ApiDBUtils; import com.cloud.capacity.dao.CapacityDao; import com.cloud.configuration.Resource.ResourceType; import com.cloud.configuration.dao.ConfigurationDao; -import com.cloud.dc.AccountVlanMapVO; -import com.cloud.dc.ClusterVO; -import com.cloud.dc.DataCenter; import com.cloud.dc.DataCenter.NetworkType; -import com.cloud.dc.DataCenterIpAddressVO; -import com.cloud.dc.DataCenterLinkLocalIpAddressVO; -import com.cloud.dc.DataCenterVO; -import com.cloud.dc.DcDetailVO; -import com.cloud.dc.HostPodVO; -import com.cloud.dc.Pod; -import com.cloud.dc.PodVlanMapVO; -import com.cloud.dc.Vlan; import com.cloud.dc.Vlan.VlanType; import com.cloud.dc.VlanVO; +import com.cloud.dc.dao.AccountVlanMapDao; +import com.cloud.dc.dao.ClusterDao; +import com.cloud.dc.dao.DataCenterDao; +import com.cloud.dc.dao.DataCenterIpAddressDao; +import com.cloud.dc.dao.DataCenterLinkLocalIpAddressDao; +import com.cloud.dc.dao.DcDetailsDao; +import com.cloud.dc.dao.HostPodDao; +import com.cloud.dc.dao.PodVlanMapDao; +import com.cloud.dc.dao.VlanDao; + import com.cloud.deploy.DataCenterDeployment; import com.cloud.domain.Domain; import com.cloud.domain.DomainVO; @@ -125,10 +132,12 @@ import com.cloud.network.dao.PhysicalNetworkDao; import com.cloud.network.dao.PhysicalNetworkTrafficTypeDao; import com.cloud.network.dao.PhysicalNetworkTrafficTypeVO; import com.cloud.network.dao.PhysicalNetworkVO; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.network.vpc.VpcManager; import com.cloud.offering.DiskOffering; import com.cloud.offering.NetworkOffering; import com.cloud.offering.NetworkOffering.Availability; +import com.cloud.offering.NetworkOffering.Detail; import com.cloud.offering.ServiceOffering; import com.cloud.offerings.NetworkOfferingServiceMapVO; import com.cloud.offerings.NetworkOfferingVO; @@ -138,6 +147,7 @@ import com.cloud.org.Grouping; import com.cloud.org.Grouping.AllocationState; import com.cloud.projects.Project; import com.cloud.projects.ProjectManager; +import com.cloud.server.ConfigurationServer; import com.cloud.service.ServiceOfferingVO; import com.cloud.service.dao.ServiceOfferingDao; import com.cloud.storage.DiskOfferingVO; @@ -149,12 +159,6 @@ import com.cloud.storage.s3.S3Manager; import com.cloud.storage.secondary.SecondaryStorageVmManager; import com.cloud.storage.swift.SwiftManager; import com.cloud.test.IPRangeConfig; -import com.cloud.user.Account; -import com.cloud.user.AccountManager; -import com.cloud.user.AccountVO; -import com.cloud.user.ResourceLimitService; -import com.cloud.user.User; -import com.cloud.user.UserContext; import com.cloud.user.dao.AccountDao; import com.cloud.utils.NumbersUtil; import com.cloud.utils.StringUtils; @@ -187,8 +191,6 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati @Inject DataCenterDao _zoneDao; @Inject - DcDetailsDao _zoneDetailsDao; - @Inject DomainDao _domainDao; @Inject SwiftDao _swiftDao; @@ -256,6 +258,18 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati RegionDao _regionDao; @Inject PortableIpDao _portableIpDao; + @Inject + ConfigurationServer _configServer; + @Inject + DcDetailsDao _dcDetailsDao; + @Inject + ClusterDetailsDao _clusterDetailsDao; + @Inject + StoragePoolDetailsDao _storagePoolDetailsDao; + @Inject + AccountDetailsDao _accountDetailsDao; + @Inject + PrimaryDataStoreDao _storagePoolDao; // FIXME - why don't we have interface for DataCenterLinkLocalIpAddressDao? @Inject protected DataCenterLinkLocalIpAddressDao _LinkLocalIpAllocDao; @@ -334,7 +348,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati @Override @DB - public void updateConfiguration(long userId, String name, String category, String value, String scope, Long resourceId) { + public String updateConfiguration(long userId, String name, String category, String value, String scope, Long resourceId) { String validationMsg = validateConfigurationValue(name, value, scope); @@ -346,23 +360,61 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati // If scope of the parameter is given then it needs to be updated in the corresponding details table, // if scope is mentioned as global or not mentioned then it is normal global parameter updation if (scope != null && !scope.isEmpty() && !Config.ConfigurationParameterScope.global.toString().equalsIgnoreCase(scope)) { - if (Config.ConfigurationParameterScope.zone.toString().equalsIgnoreCase(scope)) { - DataCenterVO zone = _zoneDao.findById(resourceId); - if (zone == null) { - throw new InvalidParameterValueException("unable to find zone by id " + resourceId); - } - DcDetailVO dcDetailVO = _zoneDetailsDao.findDetail(resourceId, name.toLowerCase()); - if (dcDetailVO == null) { - dcDetailVO = new DcDetailVO(zone.getId(), name, value); - _zoneDetailsDao.persist(dcDetailVO); - } else { - dcDetailVO.setValue(value); - _zoneDetailsDao.update(resourceId, dcDetailVO); - } - } else { - s_logger.error("TO Do for the remaining levels (cluster/pool/account)"); - throw new InvalidParameterValueException("The scope "+ scope +" yet to be implemented"); + switch (Config.ConfigurationParameterScope.valueOf(scope)) { + case zone: DataCenterVO zone = _zoneDao.findById(resourceId); + if (zone == null) { + throw new InvalidParameterValueException("unable to find zone by id " + resourceId); + } + DcDetailVO dcDetailVO = _dcDetailsDao.findDetail(resourceId, name.toLowerCase()); + if (dcDetailVO == null) { + dcDetailVO = new DcDetailVO(resourceId, name, value); + _dcDetailsDao.persist(dcDetailVO); + } else { + dcDetailVO.setValue(value); + _dcDetailsDao.update(dcDetailVO.getId(), dcDetailVO); + } break; + case cluster: ClusterVO cluster = _clusterDao.findById(resourceId); + if (cluster == null) { + throw new InvalidParameterValueException("unable to find cluster by id " + resourceId); + } + ClusterDetailsVO clusterDetailsVO = _clusterDetailsDao.findDetail(resourceId, name); + if (clusterDetailsVO == null) { + clusterDetailsVO = new ClusterDetailsVO(resourceId, name, value); + _clusterDetailsDao.persist(clusterDetailsVO); + } else { + clusterDetailsVO.setValue(value); + _clusterDetailsDao.update(clusterDetailsVO.getId(), clusterDetailsVO); + } break; + + case storagepool: StoragePoolVO pool = _storagePoolDao.findById(resourceId); + if (pool == null) { + throw new InvalidParameterValueException("unable to find storage pool by id " + resourceId); + } + StoragePoolDetailVO storagePoolDetailVO = _storagePoolDetailsDao.findDetail(resourceId, name); + if (storagePoolDetailVO == null) { + storagePoolDetailVO = new StoragePoolDetailVO(resourceId, name, value); + _storagePoolDetailsDao.persist(storagePoolDetailVO); + + } else { + storagePoolDetailVO.setValue(value); + _storagePoolDetailsDao.update(storagePoolDetailVO.getId(), storagePoolDetailVO); + } break; + + case account: AccountVO account = _accountDao.findById(resourceId); + if (account == null) { + throw new InvalidParameterValueException("unable to find account by id " + resourceId); + } + AccountDetailVO accountDetailVO = _accountDetailsDao.findDetail(resourceId, name); + if (accountDetailVO == null) { + accountDetailVO = new AccountDetailVO(resourceId, name, value); + _accountDetailsDao.persist(accountDetailVO); + } else { + accountDetailVO.setValue(value); + _accountDetailsDao.update(accountDetailVO.getId(), accountDetailVO); + } break; + default: throw new InvalidParameterValueException("Scope provided is invalid"); } + return value; } // Execute all updates in a single transaction @@ -461,16 +513,19 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati } txn.commit(); + return _configDao.getValue(name); } @Override @ActionEvent(eventType = EventTypes.EVENT_CONFIGURATION_VALUE_EDIT, eventDescription = "updating configuration") - public Configuration updateConfiguration(UpdateCfgCmd cmd) { + public Configuration updateConfiguration(UpdateCfgCmd cmd) throws InvalidParameterValueException { Long userId = UserContext.current().getCallerUserId(); String name = cmd.getCfgName(); String value = cmd.getValue(); - String scope = cmd.getScope(); - Long id = cmd.getId(); + Long zoneId = cmd.getZoneId(); + Long clusterId = cmd.getClusterId(); + Long storagepoolId = cmd.getStoragepoolId(); + Long accountId = cmd.getAccountId(); UserContext.current().setEventDetails(" Name: " + name + " New Value: " + (((name.toLowerCase()).contains("password")) ? "*****" : (((value == null) ? "" : value)))); // check if config value exists @@ -487,11 +542,38 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati value = null; } - updateConfiguration(userId, name, config.getCategory(), value, scope, id); - String updatedValue = _configDao.getValue(name); + String scope = null; + Long id = null; + int paramCountCheck = 0; + + if (zoneId != null) { + scope = Config.ConfigurationParameterScope.zone.toString(); + id = zoneId; + paramCountCheck++; + } + if (clusterId != null) { + scope = Config.ConfigurationParameterScope.cluster.toString(); + id = clusterId; + paramCountCheck++; + } + if (accountId != null) { + scope = Config.ConfigurationParameterScope.account.toString(); + id = accountId; + paramCountCheck++; + } + if (storagepoolId != null) { + scope = Config.ConfigurationParameterScope.storagepool.toString(); + id = storagepoolId; + paramCountCheck++; + } + + if (paramCountCheck > 1) { + throw new InvalidParameterValueException("cannot handle multiple IDs, provide only one ID corresponding to the scope"); + } + + String updatedValue = updateConfiguration(userId, name, config.getCategory(), value, scope, id); if ((value == null && updatedValue == null) || updatedValue.equalsIgnoreCase(value)) { return _configDao.findByName(name); - } else { throw new CloudRuntimeException("Unable to update configuration parameter " + name); } @@ -505,10 +587,14 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati return "Invalid configuration variable."; } String configScope = c.getScope(); - if (scope != null && !scope.isEmpty()) { + if (scope != null) { if (!configScope.contains(scope)) { - s_logger.error("Invalid scope " + scope + " for the parameter " + name); - return "Invalid scope for the parameter."; + s_logger.error("Invalid scope id provided for the parameter " + name); + return "Invalid scope id provided for the parameter " + name; + } + if ((name.equalsIgnoreCase("cpu.overprovisioning.factor") || name.equalsIgnoreCase("mem.overprovisioning.factor")) && value == null) { + s_logger.error("value cannot be null for cpu.overprovisioning.factor/mem.overprovisioning.factor"); + return "value cannot be null for cpu.overprovisioning.factor/mem.overprovisioning.factor"; } } @@ -1858,6 +1944,8 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati vmType = VirtualMachine.Type.ConsoleProxy; } else if (VirtualMachine.Type.SecondaryStorageVm.toString().toLowerCase().equals(vmTypeString)) { vmType = VirtualMachine.Type.SecondaryStorageVm; + } else if (VirtualMachine.Type.InternalLoadBalancerVm.toString().toLowerCase().equals(vmTypeString)) { + vmType = VirtualMachine.Type.InternalLoadBalancerVm; } else { throw new InvalidParameterValueException("Invalid systemVmType. Supported types are: " + VirtualMachine.Type.DomainRouter + ", " + VirtualMachine.Type.ConsoleProxy + ", " + VirtualMachine.Type.SecondaryStorageVm); @@ -2646,6 +2734,14 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati // This VLAN is account-specific, so create an AccountVlanMapVO entry AccountVlanMapVO accountVlanMapVO = new AccountVlanMapVO(vlanOwner.getId(), vlan.getId()); _accountVlanMapDao.persist(accountVlanMapVO); + + // generate usage event for dedication of every ip address in the range + List ips = _publicIpAddressDao.listByVlanId(vlan.getId()); + for (IPAddressVO ip : ips) { + UsageEventUtils.publishUsageEvent(EventTypes.EVENT_NET_IP_ASSIGN, vlanOwner.getId(), + ip.getDataCenterId(), ip.getId(), ip.getAddress().toString(), ip.isSourceNat(), vlan.getVlanType().toString(), + ip.getSystem(), ip.getClass().getName(), ip.getUuid()); + } } else if (podId != null) { // This VLAN is pod-wide, so create a PodVlanMapVO entry PodVlanMapVO podVlanMapVO = new PodVlanMapVO(podId, vlan.getId()); @@ -2674,6 +2770,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati // Check if the VLAN has any allocated public IPs long allocIpCount = _publicIpAddressDao.countIPs(vlan.getDataCenterId(), vlanDbId, true); + List ips = _publicIpAddressDao.listByVlanId(vlanDbId); boolean success = true; if (allocIpCount > 0) { if (isAccountSpecific) { @@ -2687,8 +2784,6 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati s_logger.debug("lock vlan " + vlanDbId + " is acquired"); } - List ips = _publicIpAddressDao.listByVlanId(vlanDbId); - for (IPAddressVO ip : ips) { if (ip.isOneToOneNat()) { throw new InvalidParameterValueException("Can't delete account specific vlan " + vlanDbId + @@ -2725,6 +2820,15 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati return false; } + // if ip range is dedicated to an account generate usage events for release of every ip in the range + if(isAccountSpecific) { + for (IPAddressVO ip : ips) { + UsageEventUtils.publishUsageEvent(EventTypes.EVENT_NET_IP_RELEASE, acctVln.get(0).getId(), + ip.getDataCenterId(), ip.getId(), ip.getAddress().toString(), ip.isSourceNat(), vlan.getVlanType().toString(), + ip.getSystem(), ip.getClass().getName(), ip.getUuid()); + } + } + // Delete the VLAN return _vlanDao.expunge(vlanDbId); } else { @@ -2809,6 +2913,12 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati txn.commit(); + // generate usage event for dedication of every ip address in the range + for (IPAddressVO ip : ips) { + UsageEventUtils.publishUsageEvent(EventTypes.EVENT_NET_IP_ASSIGN, vlanOwner.getId(), + ip.getDataCenterId(), ip.getId(), ip.getAddress().toString(), ip.isSourceNat(), vlan.getVlanType().toString(), + ip.getSystem(), ip.getClass().getName(), ip.getUuid()); + } return vlan; } @@ -2838,6 +2948,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati // Check if range has any allocated public IPs long allocIpCount = _publicIpAddressDao.countIPs(vlan.getDataCenterId(), vlanDbId, true); + List ips = _publicIpAddressDao.listByVlanId(vlanDbId); boolean success = true; if (allocIpCount > 0) { try { @@ -2848,7 +2959,6 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati if (s_logger.isDebugEnabled()) { s_logger.debug("lock vlan " + vlanDbId + " is acquired"); } - List ips = _publicIpAddressDao.listByVlanId(vlanDbId); for (IPAddressVO ip : ips) { // Disassociate allocated IP's that are not in use if ( !ip.isOneToOneNat() && !ip.isSourceNat() && !(_firewallDao.countRulesByIpId(ip.getId()) > 0) ) { @@ -2870,6 +2980,12 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati // A Public IP range can only be dedicated to one account at a time if (_accountVlanMapDao.remove(acctVln.get(0).getId())) { + // generate usage events to remove dedication for every ip in the range + for (IPAddressVO ip : ips) { + UsageEventUtils.publishUsageEvent(EventTypes.EVENT_NET_IP_RELEASE, acctVln.get(0).getId(), + ip.getDataCenterId(), ip.getId(), ip.getAddress().toString(), ip.isSourceNat(), vlan.getVlanType().toString(), + ip.getSystem(), ip.getClass().getName(), ip.getUuid()); + } return true; } else { return false; @@ -3251,6 +3367,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati Network.GuestType guestType = null; boolean specifyIpRanges = cmd.getSpecifyIpRanges(); boolean isPersistent = cmd.getIsPersistent(); + Map detailsStr = cmd.getDetails(); // Verify traffic type for (TrafficType tType : TrafficType.values()) { @@ -3343,10 +3460,10 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati Network.Service service = Network.Service.getService(serviceStr); if (serviceProviderMap.containsKey(service)) { Set providers = new HashSet(); - // in Acton, don't allow to specify more than 1 provider per service - if (svcPrv.get(serviceStr) != null && svcPrv.get(serviceStr).size() > 1) { + // Allow to specify more than 1 provider per service only if the service is LB + if (!serviceStr.equalsIgnoreCase(Service.Lb.getName()) && svcPrv.get(serviceStr) != null && svcPrv.get(serviceStr).size() > 1) { throw new InvalidParameterValueException("In the current release only one provider can be " + - "specified for the service"); + "specified for the service if the service is not LB"); } for (String prvNameStr : svcPrv.get(serviceStr)) { // check if provider is supported @@ -3419,9 +3536,26 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati firewallProviderSet.add(firewallProvider); serviceProviderMap.put(Service.Firewall, firewallProviderSet); } + + Map details = new HashMap(); + if (detailsStr != null) { + for (String detailStr : detailsStr.keySet()) { + NetworkOffering.Detail offDetail = null; + for (NetworkOffering.Detail supportedDetail: NetworkOffering.Detail.values()) { + if (detailStr.equalsIgnoreCase(supportedDetail.toString())) { + offDetail = supportedDetail; + break; + } + } + if (offDetail == null) { + throw new InvalidParameterValueException("Unsupported detail " + detailStr); + } + details.put(offDetail, detailsStr.get(detailStr)); + } + } return createNetworkOffering(name, displayText, trafficType, tags, specifyVlan, availability, networkRate, serviceProviderMap, false, guestType, false, - serviceOfferingId, conserveMode, serviceCapabilityMap, specifyIpRanges, isPersistent); + serviceOfferingId, conserveMode, serviceCapabilityMap, specifyIpRanges, isPersistent, details); } void validateLoadBalancerServiceCapabilities(Map lbServiceCapabilityMap) { @@ -3450,8 +3584,16 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati if (!enabled && !disabled) { throw new InvalidParameterValueException("Unknown specified value for " + Capability.InlineMode.getName()); } + } else if (cap == Capability.LbSchemes) { + boolean internalLb = value.contains("internal"); + boolean publicLb = value.contains("public"); + if (!internalLb && !publicLb) { + throw new InvalidParameterValueException("Unknown specified value for " + Capability.LbSchemes.getName()); + } } else { - throw new InvalidParameterValueException("Only " + Capability.SupportedLBIsolation.getName() + ", " + Capability.ElasticLb.getName() + ", " + Capability.InlineMode.getName() + " capabilities can be sepcified for LB service"); + throw new InvalidParameterValueException("Only " + Capability.SupportedLBIsolation.getName() + + ", " + Capability.ElasticLb.getName() + ", " + Capability.InlineMode.getName() + + ", " + Capability.LbSchemes.getName() + " capabilities can be sepcified for LB service"); } } } @@ -3523,7 +3665,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati @DB public NetworkOfferingVO createNetworkOffering(String name, String displayText, TrafficType trafficType, String tags, boolean specifyVlan, Availability availability, Integer networkRate, Map> serviceProviderMap, boolean isDefault, Network.GuestType type, boolean systemOnly, Long serviceOfferingId, - boolean conserveMode, Map> serviceCapabilityMap, boolean specifyIpRanges, boolean isPersistent) { + boolean conserveMode, Map> serviceCapabilityMap, boolean specifyIpRanges, boolean isPersistent, Map details) { String multicastRateStr = _configDao.getValue("multicast.throttling.rate"); int multicastRate = ((multicastRateStr == null) ? 10 : Integer.parseInt(multicastRateStr)); @@ -3577,6 +3719,8 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati boolean elasticIp = false; boolean associatePublicIp = false; boolean inline = false; + boolean publicLb = false; + boolean internalLb = false; if (serviceCapabilityMap != null && !serviceCapabilityMap.isEmpty()) { Map lbServiceCapabilityMap = serviceCapabilityMap.get(Service.Lb); @@ -3601,6 +3745,23 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati } else { inline = false; } + + String publicLbStr = lbServiceCapabilityMap.get(Capability.LbSchemes); + if (serviceProviderMap.containsKey(Service.Lb)) { + if (publicLbStr != null) { + _networkModel.checkCapabilityForProvider(serviceProviderMap.get(Service.Lb), Service.Lb, Capability.LbSchemes, publicLbStr); + internalLb = publicLbStr.contains("internal"); + publicLb = publicLbStr.contains("public"); + } else { + //if not specified, default public lb to true + publicLb = true; + } + } + } + + //in the current version of the code, publicLb and specificLb can't both be set to true for the same network offering + if (publicLb && internalLb) { + throw new InvalidParameterValueException("Public lb and internal lb can't be enabled at the same time on the offering"); } Map sourceNatServiceCapabilityMap = serviceCapabilityMap.get(Service.SourceNat); @@ -3635,18 +3796,23 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati NetworkOfferingVO offering = new NetworkOfferingVO(name, displayText, trafficType, systemOnly, specifyVlan, networkRate, multicastRate, isDefault, availability, tags, type, conserveMode, dedicatedLb, - sharedSourceNat, redundantRouter, elasticIp, elasticLb, specifyIpRanges, inline, isPersistent, associatePublicIp); + sharedSourceNat, redundantRouter, elasticIp, elasticLb, specifyIpRanges, inline, isPersistent, associatePublicIp, publicLb, internalLb); if (serviceOfferingId != null) { offering.setServiceOfferingId(serviceOfferingId); } + + //validate the details + if (details != null) { + validateNtwkOffDetails(details, serviceProviderMap); + } Transaction txn = Transaction.currentTxn(); txn.start(); - // create network offering object + //1) create network offering object s_logger.debug("Adding network offering " + offering); - offering = _networkOfferingDao.persist(offering); - // populate services and providers + offering = _networkOfferingDao.persist(offering, details); + //2) populate services and providers if (serviceProviderMap != null) { for (Network.Service service : serviceProviderMap.keySet()) { Set providers = serviceProviderMap.get(service); @@ -3680,6 +3846,42 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati return offering; } + protected void validateNtwkOffDetails(Map details, Map> serviceProviderMap) { + for (Detail detail : details.keySet()) { + + Provider lbProvider = null; + if (detail == NetworkOffering.Detail.InternalLbProvider || detail == NetworkOffering.Detail.PublicLbProvider) { + //1) Vaidate the detail values - have to match the lb provider name + String providerStr = details.get(detail); + if (Network.Provider.getProvider(providerStr) == null) { + throw new InvalidParameterValueException("Invalid value " + providerStr + " for the detail " + detail); + } + if (serviceProviderMap.get(Service.Lb) != null) { + for (Provider provider : serviceProviderMap.get(Service.Lb)) { + if (provider.getName().equalsIgnoreCase(providerStr)) { + lbProvider = provider; + break; + } + } + } + + if (lbProvider == null) { + throw new InvalidParameterValueException("Invalid value " + details.get(detail) + + " for the detail " + detail + ". The provider is not supported by the network offering"); + } + + //2) validate if the provider supports the scheme + Set lbProviders = new HashSet(); + lbProviders.add(lbProvider); + if (detail == NetworkOffering.Detail.InternalLbProvider) { + _networkModel.checkCapabilityForProvider(lbProviders, Service.Lb, Capability.LbSchemes, Scheme.Internal.toString()); + } else if (detail == NetworkOffering.Detail.PublicLbProvider){ + _networkModel.checkCapabilityForProvider(lbProviders, Service.Lb, Capability.LbSchemes, Scheme.Public.toString()); + } + } + } + } + @Override public List searchForNetworkOfferings(ListNetworkOfferingsCmd cmd) { @@ -3905,6 +4107,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati public boolean isOfferingForVpc(NetworkOffering offering) { boolean vpcProvider = _ntwkOffServiceMapDao.isProviderForNetworkOffering(offering.getId(), Provider.VPCVirtualRouter); + boolean internalLb = offering.getInternalLb(); return vpcProvider; } @@ -4088,7 +4291,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati } @Override - public Integer getNetworkOfferingNetworkRate(long networkOfferingId) { + public Integer getNetworkOfferingNetworkRate(long networkOfferingId, Long dataCenterId) { // validate network offering information NetworkOffering no = getNetworkOffering(networkOfferingId); @@ -4100,7 +4303,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati if (no.getRateMbps() != null) { networkRate = no.getRateMbps(); } else { - networkRate = Integer.parseInt(_configDao.getValue(Config.NetworkThrottlingRate.key())); + networkRate = Integer.parseInt(_configServer.getConfigValue(Config.NetworkThrottlingRate.key(), Config.ConfigurationParameterScope.zone.toString(), dataCenterId)); } // networkRate is unsigned int in netowrkOfferings table, and can't be @@ -4236,7 +4439,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati } @Override - public Integer getServiceOfferingNetworkRate(long serviceOfferingId) { + public Integer getServiceOfferingNetworkRate(long serviceOfferingId, Long dataCenterId) { // validate network offering information ServiceOffering offering = _serviceOfferingDao.findById(serviceOfferingId); @@ -4250,7 +4453,7 @@ public class ConfigurationManagerImpl extends ManagerBase implements Configurati } else { // for domain router service offering, get network rate from if (offering.getSystemVmType() != null && offering.getSystemVmType().equalsIgnoreCase(VirtualMachine.Type.DomainRouter.toString())) { - networkRate = Integer.parseInt(_configDao.getValue(Config.NetworkThrottlingRate.key())); + networkRate = Integer.parseInt(_configServer.getConfigValue(Config.NetworkThrottlingRate.key(), Config.ConfigurationParameterScope.zone.toString(), dataCenterId)); } else { networkRate = Integer.parseInt(_configDao.getValue(Config.VmNetworkThrottlingRate.key())); } diff --git a/server/src/com/cloud/consoleproxy/ConsoleProxyManagerImpl.java b/server/src/com/cloud/consoleproxy/ConsoleProxyManagerImpl.java index c4ad8170d6d..9a7a46faf3d 100755 --- a/server/src/com/cloud/consoleproxy/ConsoleProxyManagerImpl.java +++ b/server/src/com/cloud/consoleproxy/ConsoleProxyManagerImpl.java @@ -5,7 +5,7 @@ // to you under the Apache License, Version 2.0 (the // "License"); you may not use this file except in compliance // with the License. You may obtain a copy of the License at -// +// // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, @@ -23,7 +23,6 @@ import java.util.HashMap; import java.util.Iterator; import java.util.List; import java.util.Map; -import java.util.UUID; import javax.ejb.Local; import javax.inject.Inject; @@ -98,7 +97,6 @@ import com.cloud.resource.UnableDeleteHostException; import com.cloud.server.ManagementServer; import com.cloud.service.ServiceOfferingVO; import com.cloud.service.dao.ServiceOfferingDao; -import com.cloud.servlet.ConsoleProxyPasswordBasedEncryptor; import com.cloud.storage.StorageManager; import com.cloud.storage.StoragePoolStatus; import com.cloud.storage.VMTemplateHostVO; @@ -263,186 +261,6 @@ public class ConsoleProxyManagerImpl extends ManagerBase implements ConsoleProxy private final GlobalLock _allocProxyLock = GlobalLock.getInternLock(getAllocProxyLockName()); - /* - * private final String keyContent = - * "MIICdgIBADANBgkqhkiG9w0BAQEFAASCAmAwggJcAgEAAoGBALV5vGlkiWwoZX4hTRplPXP8qtST\n" - * + "hwZhko8noeY5vf8ECwmd+vrCTw/JvnOtkx/8oYNbg/SeUt1EfOsk6gqJdBblGFBZRMcUJlIpqE9z\n" + - * "uv68U9G8Gfi/qvRSY336hibw0J5bZ4vn1QqmyHDB+Czea9AjFUV7AEVG15+vED7why+/AgMBAAEC\n" - * + "gYBmFBPnNKYYMKDmUdUNA+WNWJK/ADzzWe8WlzR6TACTcbLDthl289WFC/YVG42mcHRpbxDKiEQU\n" + - * "MnIR0rHTO34Qb/2HcuyweStU2gqR6omxBvMnFpJr90nD1HcOMJzeLHsphau0/EmKKey+gk4PyieD\n" - * + "KqTM7LTjjHv8xPM4n+WAAQJBAOMNCeFKlJ4kMokWhU74B5/w/NGyT1BHUN0VmilHSiJC8JqS4BiI\n" + - * "ZpAeET3VmilO6QTGh2XVhEDGteu3uZR6ipUCQQDMnRzMgQ/50LFeIQo4IBtwlEouczMlPQF4c21R\n" - * + "1d720moxILVPT0NJZTQUDDmmgbL+B7CgtcCR2NlP5sKPZVADAkEAh4Xq1cy8dMBKYcVNgNtPQcqI\n" + - * "PWpfKR3ISI5yXB0vRNAL6Vet5zbTcUZhKDVtNSbis3UEsGYH8NorEC2z2cpjGQJANhJi9Ow6c5Mh\n" - * + "/DURBUn+1l5pyCKrZnDbvaALSLATLvjmFTuGjoHszy2OeKnOZmEqExWnKKE/VYuPyhy6V7i3TwJA\n" + - * "f8skDgtPK0OsBCa6IljPaHoWBjPc4kFkSTSS1d56hUcWSikTmiuKdLyBb85AADSZYsvHWrte4opN\n" + "dhNukMJuRA==\n"; - * - * private final String certContent = "-----BEGIN CERTIFICATE-----\n" + - * "MIIE3jCCA8agAwIBAgIFAqv56tIwDQYJKoZIhvcNAQEFBQAwgcoxCzAJBgNVBAYT\n" - * + "AlVTMRAwDgYDVQQIEwdBcml6b25hMRMwEQYDVQQHEwpTY290dHNkYWxlMRowGAYD\n" + - * "VQQKExFHb0RhZGR5LmNvbSwgSW5jLjEzMDEGA1UECxMqaHR0cDovL2NlcnRpZmlj\n" - * + "YXRlcy5nb2RhZGR5LmNvbS9yZXBvc2l0b3J5MTAwLgYDVQQDEydHbyBEYWRkeSBT\n" + - * "ZWN1cmUgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkxETAPBgNVBAUTCDA3OTY5Mjg3\n" - * + "MB4XDTA5MDIxMTA0NTc1NloXDTEyMDIwNzA1MTEyM1owWTEZMBcGA1UECgwQKi5y\n" + - * "ZWFsaG9zdGlwLmNvbTEhMB8GA1UECwwYRG9tYWluIENvbnRyb2wgVmFsaWRhdGVk\n" - * + "MRkwFwYDVQQDDBAqLnJlYWxob3N0aXAuY29tMIGfMA0GCSqGSIb3DQEBAQUAA4GN\n" + - * "ADCBiQKBgQC1ebxpZIlsKGV+IU0aZT1z/KrUk4cGYZKPJ6HmOb3/BAsJnfr6wk8P\n" - * + "yb5zrZMf/KGDW4P0nlLdRHzrJOoKiXQW5RhQWUTHFCZSKahPc7r+vFPRvBn4v6r0\n" + - * "UmN9+oYm8NCeW2eL59UKpshwwfgs3mvQIxVFewBFRtefrxA+8IcvvwIDAQABo4IB\n" - * + "vTCCAbkwDwYDVR0TAQH/BAUwAwEBADAdBgNVHSUEFjAUBggrBgEFBQcDAQYIKwYB\n" + - * "BQUHAwIwDgYDVR0PAQH/BAQDAgWgMDIGA1UdHwQrMCkwJ6AloCOGIWh0dHA6Ly9j\n" - * + "cmwuZ29kYWRkeS5jb20vZ2RzMS0yLmNybDBTBgNVHSAETDBKMEgGC2CGSAGG/W0B\n" + - * "BxcBMDkwNwYIKwYBBQUHAgEWK2h0dHA6Ly9jZXJ0aWZpY2F0ZXMuZ29kYWRkeS5j\n" - * + "b20vcmVwb3NpdG9yeS8wgYAGCCsGAQUFBwEBBHQwcjAkBggrBgEFBQcwAYYYaHR0\n" + - * "cDovL29jc3AuZ29kYWRkeS5jb20vMEoGCCsGAQUFBzAChj5odHRwOi8vY2VydGlm\n" - * + "aWNhdGVzLmdvZGFkZHkuY29tL3JlcG9zaXRvcnkvZ2RfaW50ZXJtZWRpYXRlLmNy\n" + - * "dDAfBgNVHSMEGDAWgBT9rGEyk2xF1uLuhV+auud2mWjM5zArBgNVHREEJDAighAq\n" - * + "LnJlYWxob3N0aXAuY29tgg5yZWFsaG9zdGlwLmNvbTAdBgNVHQ4EFgQUHxwmdK5w\n" + - * "9/YVeZ/3fHyi6nQfzoYwDQYJKoZIhvcNAQEFBQADggEBABv/XinvId6oWXJtmku+\n" - * + "7m90JhSVH0ycoIGjgdaIkcExQGP08MCilbUsPcbhLheSFdgn/cR4e1MP083lacoj\n" + - * "OGauY7b8f/cuquGkT49Ns14awPlEzRjjycQEjjLxFEuL5CFWa2t2gKRE1dSfhDQ+\n" - * + "fJ6GBCs1XgZLuhkKS8fPf+YmG2ZjHzYDjYoSx7paDXgEm+kbYIZdCK51lA0BUAjP\n" + - * "9ZMGhsu/PpAbh5U/DtcIqxY0xeqD4TeGsBzXg6uLhv+jKHDtXg5fYPe+z0n5DCEL\n" - * + "k0fLF4+i/pt9hVCz0QrZ28RUhXf825+EOL0Gw+Uzt+7RV2cCaJrlu4cDrDom2FRy\n" + "E8I=\n" + - * "-----END CERTIFICATE-----\n"; - */ - public static final String keyContent = - "-----BEGIN PRIVATE KEY-----\n" + - "MIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQCDT9AtEfs+s/I8QXp6rrCw0iNJ\n" + - "0+GgsybNHheU+JpL39LMTZykCrZhZnyDvwdxCoOfE38Sa32baHKNds+y2SHnMNsOkw8OcNucHEBX\n" + - "1FIpOBGph9D6xC+umx9od6xMWETUv7j6h2u+WC3OhBM8fHCBqIiAol31/IkcqDxxsHlQ8S/oCfTl\n" + - "XJUY6Yn628OA1XijKdRnadV0hZ829cv/PZKljjwQUTyrd0KHQeksBH+YAYSo2JUl8ekNLsOi8/cP\n" + - "tfojnltzRI1GXi0ZONs8VnDzJ0a2gqZY+uxlz+CGbLnGnlN4j9cBpE+MfUE+35Dq121sTpsSgF85\n" + - "Mz+pVhn2S633AgMBAAECggEAH/Szd9RxbVADenCA6wxKSa3KErRyq1YN8ksJeCKMAj0FIt0caruE\n" + - "qO11DebWW8cwQu1Otl/cYI6pmg24/BBldMrp9IELX/tNJo+lhPpRyGAxxC0eSXinFfoASb8d+jJd\n" + - "Bd1mmemM6fSxqRlxSP4LrzIhjhR1g2CiyYuTsiM9UtoVKGyHwe7KfFwirUOJo3Mr18zUVNm7YqY4\n" + - "IVhOSq59zkH3ULBlYq4bG50jpxa5mNSCZ7IpafPY/kE/CbR+FWNt30+rk69T+qb5abg6+XGm+OAm\n" + - "bnQ18yZEqX6nJLk7Ch0cfA5orGgrTMOrM71wK7tBBDQ308kOxDGebx6j0qD36QKBgQDTRDr8kuhA\n" + - "9sUyKr9vk2DQCMpNvEeiwI3JRMqmmxpNAtg01aJ3Ya57vX5Fc+zcuV87kP6FM1xgpHQvnw5LWo2J\n" + - "s7ANwQcP8ricEW5zkZhSjI4ssMeAubmsHOloGxmLFYZqwx0JI7CWViGTLMcUlqKblmHcjeQDeDfP\n" + - "P1TaCItFmwKBgQCfHZwVvIcaDs5vxVpZ4ftvflIrW8qq0uOVK6QIf9A/YTGhCXl2qxxTg2A6+0rg\n" + - "ZqI7zKzUDxIbVv0KlgCbpHDC9d5+sdtDB3wW2pimuJ3p1z4/RHb4n/lDwXCACZl1S5l24yXX2pFZ\n" + - "wdPCXmy5PYkHMssFLNhI24pprUIQs66M1QKBgQDQwjAjWisD3pRXESSfZRsaFkWJcM28hdbVFhPF\n" + - "c6gWhwQLmTp0CuL2RPXcPUPFi6sN2iWWi3zxxi9Eyz+9uBn6AsOpo56N5MME/LiOnETO9TKb+Ib6\n" + - "rQtKhjshcv3XkIqFPo2XdVvOAgglPO7vajX91iiXXuH7h7RmJud6l0y/lwKBgE+bi90gLuPtpoEr\n" + - "VzIDKz40ED5bNYHT80NNy0rpT7J2GVN9nwStRYXPBBVeZq7xCpgqpgmO5LtDAWULeZBlbHlOdBwl\n" + - "NhNKKl5wzdEUKwW0yBL1WSS5PQgWPwgARYP25/ggW22sj+49WIo1neXsEKPGWObk8e050f1fTt92\n" + - "Vo1lAoGAb1gCoyBCzvi7sqFxm4V5oapnJeiQQJFjhoYWqGa26rQ+AvXXNuBcigIeDXNJPctSF0Uc\n" + - "p11KbbCgiruBbckvM1vGsk6Sx4leRk+IFHRpJktFUek4o0eUg0shOsyyvyet48Dfg0a8FvcxROs0\n" + - "gD+IYds5doiob/hcm1hnNB/3vk4=\n" + - "-----END PRIVATE KEY-----\n"; - - public static final String certContent = - "-----BEGIN CERTIFICATE-----\n" + - "MIIFZTCCBE2gAwIBAgIHKBCduBUoKDANBgkqhkiG9w0BAQUFADCByjELMAkGA1UE\n" + - "BhMCVVMxEDAOBgNVBAgTB0FyaXpvbmExEzARBgNVBAcTClNjb3R0c2RhbGUxGjAY\n" + - "BgNVBAoTEUdvRGFkZHkuY29tLCBJbmMuMTMwMQYDVQQLEypodHRwOi8vY2VydGlm\n" + - "aWNhdGVzLmdvZGFkZHkuY29tL3JlcG9zaXRvcnkxMDAuBgNVBAMTJ0dvIERhZGR5\n" + - "IFNlY3VyZSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTERMA8GA1UEBRMIMDc5Njky\n" + - "ODcwHhcNMTIwMjAzMDMzMDQwWhcNMTcwMjA3MDUxMTIzWjBZMRkwFwYDVQQKDBAq\n" + - "LnJlYWxob3N0aXAuY29tMSEwHwYDVQQLDBhEb21haW4gQ29udHJvbCBWYWxpZGF0\n" + - "ZWQxGTAXBgNVBAMMECoucmVhbGhvc3RpcC5jb20wggEiMA0GCSqGSIb3DQEBAQUA\n" + - "A4IBDwAwggEKAoIBAQCDT9AtEfs+s/I8QXp6rrCw0iNJ0+GgsybNHheU+JpL39LM\n" + - "TZykCrZhZnyDvwdxCoOfE38Sa32baHKNds+y2SHnMNsOkw8OcNucHEBX1FIpOBGp\n" + - "h9D6xC+umx9od6xMWETUv7j6h2u+WC3OhBM8fHCBqIiAol31/IkcqDxxsHlQ8S/o\n" + - "CfTlXJUY6Yn628OA1XijKdRnadV0hZ829cv/PZKljjwQUTyrd0KHQeksBH+YAYSo\n" + - "2JUl8ekNLsOi8/cPtfojnltzRI1GXi0ZONs8VnDzJ0a2gqZY+uxlz+CGbLnGnlN4\n" + - "j9cBpE+MfUE+35Dq121sTpsSgF85Mz+pVhn2S633AgMBAAGjggG+MIIBujAPBgNV\n" + - "HRMBAf8EBTADAQEAMB0GA1UdJQQWMBQGCCsGAQUFBwMBBggrBgEFBQcDAjAOBgNV\n" + - "HQ8BAf8EBAMCBaAwMwYDVR0fBCwwKjAooCagJIYiaHR0cDovL2NybC5nb2RhZGR5\n" + - "LmNvbS9nZHMxLTY0LmNybDBTBgNVHSAETDBKMEgGC2CGSAGG/W0BBxcBMDkwNwYI\n" + - "KwYBBQUHAgEWK2h0dHA6Ly9jZXJ0aWZpY2F0ZXMuZ29kYWRkeS5jb20vcmVwb3Np\n" + - "dG9yeS8wgYAGCCsGAQUFBwEBBHQwcjAkBggrBgEFBQcwAYYYaHR0cDovL29jc3Au\n" + - "Z29kYWRkeS5jb20vMEoGCCsGAQUFBzAChj5odHRwOi8vY2VydGlmaWNhdGVzLmdv\n" + - "ZGFkZHkuY29tL3JlcG9zaXRvcnkvZ2RfaW50ZXJtZWRpYXRlLmNydDAfBgNVHSME\n" + - "GDAWgBT9rGEyk2xF1uLuhV+auud2mWjM5zArBgNVHREEJDAighAqLnJlYWxob3N0\n" + - "aXAuY29tgg5yZWFsaG9zdGlwLmNvbTAdBgNVHQ4EFgQUZyJz9/QLy5TWIIscTXID\n" + - "E8Xk47YwDQYJKoZIhvcNAQEFBQADggEBAKiUV3KK16mP0NpS92fmQkCLqm+qUWyN\n" + - "BfBVgf9/M5pcT8EiTZlS5nAtzAE/eRpBeR3ubLlaAogj4rdH7YYVJcDDLLoB2qM3\n" + - "qeCHu8LFoblkb93UuFDWqRaVPmMlJRnhsRkL1oa2gM2hwQTkBDkP7w5FG1BELCgl\n" + - "gZI2ij2yxjge6pOEwSyZCzzbCcg9pN+dNrYyGEtB4k+BBnPA3N4r14CWbk+uxjrQ\n" + - "6j2Ip+b7wOc5IuMEMl8xwTyjuX3lsLbAZyFI9RCyofwA9NqIZ1GeB6Zd196rubQp\n" + - "93cmBqGGjZUs3wMrGlm7xdjlX6GQ9UvmvkMub9+lL99A5W50QgCmFeI=\n" + - "-----END CERTIFICATE-----\n"; - - public static final String rootCa = - "-----BEGIN CERTIFICATE-----\n" + - "MIIE3jCCA8agAwIBAgICAwEwDQYJKoZIhvcNAQEFBQAwYzELMAkGA1UEBhMCVVMx\n" + - "ITAfBgNVBAoTGFRoZSBHbyBEYWRkeSBHcm91cCwgSW5jLjExMC8GA1UECxMoR28g\n" + - "RGFkZHkgQ2xhc3MgMiBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw0wNjExMTYw\n" + - "MTU0MzdaFw0yNjExMTYwMTU0MzdaMIHKMQswCQYDVQQGEwJVUzEQMA4GA1UECBMH\n" + - "QXJpem9uYTETMBEGA1UEBxMKU2NvdHRzZGFsZTEaMBgGA1UEChMRR29EYWRkeS5j\n" + - "b20sIEluYy4xMzAxBgNVBAsTKmh0dHA6Ly9jZXJ0aWZpY2F0ZXMuZ29kYWRkeS5j\n" + - "b20vcmVwb3NpdG9yeTEwMC4GA1UEAxMnR28gRGFkZHkgU2VjdXJlIENlcnRpZmlj\n" + - "YXRpb24gQXV0aG9yaXR5MREwDwYDVQQFEwgwNzk2OTI4NzCCASIwDQYJKoZIhvcN\n" + - "AQEBBQADggEPADCCAQoCggEBAMQt1RWMnCZM7DI161+4WQFapmGBWTtwY6vj3D3H\n" + - "KrjJM9N55DrtPDAjhI6zMBS2sofDPZVUBJ7fmd0LJR4h3mUpfjWoqVTr9vcyOdQm\n" + - "VZWt7/v+WIbXnvQAjYwqDL1CBM6nPwT27oDyqu9SoWlm2r4arV3aLGbqGmu75RpR\n" + - "SgAvSMeYddi5Kcju+GZtCpyz8/x4fKL4o/K1w/O5epHBp+YlLpyo7RJlbmr2EkRT\n" + - "cDCVw5wrWCs9CHRK8r5RsL+H0EwnWGu1NcWdrxcx+AuP7q2BNgWJCJjPOq8lh8BJ\n" + - "6qf9Z/dFjpfMFDniNoW1fho3/Rb2cRGadDAW/hOUoz+EDU8CAwEAAaOCATIwggEu\n" + - "MB0GA1UdDgQWBBT9rGEyk2xF1uLuhV+auud2mWjM5zAfBgNVHSMEGDAWgBTSxLDS\n" + - "kdRMEXGzYcs9of7dqGrU4zASBgNVHRMBAf8ECDAGAQH/AgEAMDMGCCsGAQUFBwEB\n" + - "BCcwJTAjBggrBgEFBQcwAYYXaHR0cDovL29jc3AuZ29kYWRkeS5jb20wRgYDVR0f\n" + - "BD8wPTA7oDmgN4Y1aHR0cDovL2NlcnRpZmljYXRlcy5nb2RhZGR5LmNvbS9yZXBv\n" + - "c2l0b3J5L2dkcm9vdC5jcmwwSwYDVR0gBEQwQjBABgRVHSAAMDgwNgYIKwYBBQUH\n" + - "AgEWKmh0dHA6Ly9jZXJ0aWZpY2F0ZXMuZ29kYWRkeS5jb20vcmVwb3NpdG9yeTAO\n" + - "BgNVHQ8BAf8EBAMCAQYwDQYJKoZIhvcNAQEFBQADggEBANKGwOy9+aG2Z+5mC6IG\n" + - "OgRQjhVyrEp0lVPLN8tESe8HkGsz2ZbwlFalEzAFPIUyIXvJxwqoJKSQ3kbTJSMU\n" + - "A2fCENZvD117esyfxVgqwcSeIaha86ykRvOe5GPLL5CkKSkB2XIsKd83ASe8T+5o\n" + - "0yGPwLPk9Qnt0hCqU7S+8MxZC9Y7lhyVJEnfzuz9p0iRFEUOOjZv2kWzRaJBydTX\n" + - "RE4+uXR21aITVSzGh6O1mawGhId/dQb8vxRMDsxuxN89txJx9OjxUUAiKEngHUuH\n" + - "qDTMBqLdElrRhjZkAzVvb3du6/KFUJheqwNTrZEjYx8WnM25sgVjOuH0aBsXBTWV\n" + - "U+4=\n" + - "-----END CERTIFICATE-----\n" + - "-----BEGIN CERTIFICATE-----\n" + - "MIIE+zCCBGSgAwIBAgICAQ0wDQYJKoZIhvcNAQEFBQAwgbsxJDAiBgNVBAcTG1Zh\n" + - "bGlDZXJ0IFZhbGlkYXRpb24gTmV0d29yazEXMBUGA1UEChMOVmFsaUNlcnQsIElu\n" + - "Yy4xNTAzBgNVBAsTLFZhbGlDZXJ0IENsYXNzIDIgUG9saWN5IFZhbGlkYXRpb24g\n" + - "QXV0aG9yaXR5MSEwHwYDVQQDExhodHRwOi8vd3d3LnZhbGljZXJ0LmNvbS8xIDAe\n" + - "BgkqhkiG9w0BCQEWEWluZm9AdmFsaWNlcnQuY29tMB4XDTA0MDYyOTE3MDYyMFoX\n" + - "DTI0MDYyOTE3MDYyMFowYzELMAkGA1UEBhMCVVMxITAfBgNVBAoTGFRoZSBHbyBE\n" + - "YWRkeSBHcm91cCwgSW5jLjExMC8GA1UECxMoR28gRGFkZHkgQ2xhc3MgMiBDZXJ0\n" + - "aWZpY2F0aW9uIEF1dGhvcml0eTCCASAwDQYJKoZIhvcNAQEBBQADggENADCCAQgC\n" + - "ggEBAN6d1+pXGEmhW+vXX0iG6r7d/+TvZxz0ZWizV3GgXne77ZtJ6XCAPVYYYwhv\n" + - "2vLM0D9/AlQiVBDYsoHUwHU9S3/Hd8M+eKsaA7Ugay9qK7HFiH7Eux6wwdhFJ2+q\n" + - "N1j3hybX2C32qRe3H3I2TqYXP2WYktsqbl2i/ojgC95/5Y0V4evLOtXiEqITLdiO\n" + - "r18SPaAIBQi2XKVlOARFmR6jYGB0xUGlcmIbYsUfb18aQr4CUWWoriMYavx4A6lN\n" + - "f4DD+qta/KFApMoZFv6yyO9ecw3ud72a9nmYvLEHZ6IVDd2gWMZEewo+YihfukEH\n" + - "U1jPEX44dMX4/7VpkI+EdOqXG68CAQOjggHhMIIB3TAdBgNVHQ4EFgQU0sSw0pHU\n" + - "TBFxs2HLPaH+3ahq1OMwgdIGA1UdIwSByjCBx6GBwaSBvjCBuzEkMCIGA1UEBxMb\n" + - "VmFsaUNlcnQgVmFsaWRhdGlvbiBOZXR3b3JrMRcwFQYDVQQKEw5WYWxpQ2VydCwg\n" + - "SW5jLjE1MDMGA1UECxMsVmFsaUNlcnQgQ2xhc3MgMiBQb2xpY3kgVmFsaWRhdGlv\n" + - "biBBdXRob3JpdHkxITAfBgNVBAMTGGh0dHA6Ly93d3cudmFsaWNlcnQuY29tLzEg\n" + - "MB4GCSqGSIb3DQEJARYRaW5mb0B2YWxpY2VydC5jb22CAQEwDwYDVR0TAQH/BAUw\n" + - "AwEB/zAzBggrBgEFBQcBAQQnMCUwIwYIKwYBBQUHMAGGF2h0dHA6Ly9vY3NwLmdv\n" + - "ZGFkZHkuY29tMEQGA1UdHwQ9MDswOaA3oDWGM2h0dHA6Ly9jZXJ0aWZpY2F0ZXMu\n" + - "Z29kYWRkeS5jb20vcmVwb3NpdG9yeS9yb290LmNybDBLBgNVHSAERDBCMEAGBFUd\n" + - "IAAwODA2BggrBgEFBQcCARYqaHR0cDovL2NlcnRpZmljYXRlcy5nb2RhZGR5LmNv\n" + - "bS9yZXBvc2l0b3J5MA4GA1UdDwEB/wQEAwIBBjANBgkqhkiG9w0BAQUFAAOBgQC1\n" + - "QPmnHfbq/qQaQlpE9xXUhUaJwL6e4+PrxeNYiY+Sn1eocSxI0YGyeR+sBjUZsE4O\n" + - "WBsUs5iB0QQeyAfJg594RAoYC5jcdnplDQ1tgMQLARzLrUc+cb53S8wGd9D0Vmsf\n" + - "SxOaFIqII6hR8INMqzW/Rn453HWkrugp++85j09VZw==\n" + - "-----END CERTIFICATE-----\n" + - "-----BEGIN CERTIFICATE-----\n" + - "MIIC5zCCAlACAQEwDQYJKoZIhvcNAQEFBQAwgbsxJDAiBgNVBAcTG1ZhbGlDZXJ0\n" + - "IFZhbGlkYXRpb24gTmV0d29yazEXMBUGA1UEChMOVmFsaUNlcnQsIEluYy4xNTAz\n" + - "BgNVBAsTLFZhbGlDZXJ0IENsYXNzIDIgUG9saWN5IFZhbGlkYXRpb24gQXV0aG9y\n" + - "aXR5MSEwHwYDVQQDExhodHRwOi8vd3d3LnZhbGljZXJ0LmNvbS8xIDAeBgkqhkiG\n" + - "9w0BCQEWEWluZm9AdmFsaWNlcnQuY29tMB4XDTk5MDYyNjAwMTk1NFoXDTE5MDYy\n" + - "NjAwMTk1NFowgbsxJDAiBgNVBAcTG1ZhbGlDZXJ0IFZhbGlkYXRpb24gTmV0d29y\n" + - "azEXMBUGA1UEChMOVmFsaUNlcnQsIEluYy4xNTAzBgNVBAsTLFZhbGlDZXJ0IENs\n" + - "YXNzIDIgUG9saWN5IFZhbGlkYXRpb24gQXV0aG9yaXR5MSEwHwYDVQQDExhodHRw\n" + - "Oi8vd3d3LnZhbGljZXJ0LmNvbS8xIDAeBgkqhkiG9w0BCQEWEWluZm9AdmFsaWNl\n" + - "cnQuY29tMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDOOnHK5avIWZJV16vY\n" + - "dA757tn2VUdZZUcOBVXc65g2PFxTXdMwzzjsvUGJ7SVCCSRrCl6zfN1SLUzm1NZ9\n" + - "WlmpZdRJEy0kTRxQb7XBhVQ7/nHk01xC+YDgkRoKWzk2Z/M/VXwbP7RfZHM047QS\n" + - "v4dk+NoS/zcnwbNDu+97bi5p9wIDAQABMA0GCSqGSIb3DQEBBQUAA4GBADt/UG9v\n" + - "UJSZSWI4OB9L+KXIPqeCgfYrx+jFzug6EILLGACOTb2oWH+heQC1u+mNr0HZDzTu\n" + - "IYEZoDJJKPTEjlbVUjP9UNV+mWwD5MlM/Mtsq2azSiGM5bUMMj4QssxsodyamEwC\n" + - "W/POuZ6lcg5Ktz885hZo+L7tdEy8W9ViH0Pd\n" + - "-----END CERTIFICATE-----\n"; - @Inject private KeystoreDao _ksDao; @Inject @@ -781,7 +599,7 @@ public class ConsoleProxyManagerImpl extends ManagerBase implements ConsoleProxy if(proxy.getActiveSession() >= _capacityPerProxy){ it.remove(); } - } + } if (s_logger.isTraceEnabled()) { s_logger.trace("Running proxy pool size : " + runningList.size()); for (ConsoleProxyVO proxy : runningList) { @@ -1338,7 +1156,7 @@ public class ConsoleProxyManagerImpl extends ManagerBase implements ConsoleProxy //expunge the vm boolean result = _itMgr.expunge(proxy, _accountMgr.getSystemUser(), _accountMgr.getSystemAccount()); if (result) { - HostVO host = _hostDao.findByTypeNameAndZoneId(proxy.getDataCenterId(), proxy.getHostName(), + HostVO host = _hostDao.findByTypeNameAndZoneId(proxy.getDataCenterId(), proxy.getHostName(), Host.Type.ConsoleProxy); if (host != null) { s_logger.debug("Removing host entry for proxy id=" + vmId); @@ -1363,9 +1181,9 @@ public class ConsoleProxyManagerImpl extends ManagerBase implements ConsoleProxy if (lock.lock(ACQUIRE_GLOBAL_LOCK_TIMEOUT_FOR_SYNC)) { KeystoreVO ksVo = _ksDao.findByName(CERTIFICATE_NAME); if (ksVo == null) { - _ksDao.save(CERTIFICATE_NAME, certContent, keyContent, "realhostip.com"); + _ksDao.save(CERTIFICATE_NAME, ConsoleProxyVO.certContent, ConsoleProxyVO.keyContent, "realhostip.com"); KeystoreVO caRoot = new KeystoreVO(); - caRoot.setCertificate(rootCa); + caRoot.setCertificate(ConsoleProxyVO.rootCa); caRoot.setDomainSuffix("realhostip.com"); caRoot.setName("root"); caRoot.setIndex(0); @@ -1906,5 +1724,5 @@ public class ConsoleProxyManagerImpl extends ManagerBase implements ConsoleProxy @Override public void prepareStop(VirtualMachineProfile profile) { } - + } diff --git a/server/src/com/cloud/deploy/FirstFitPlanner.java b/server/src/com/cloud/deploy/FirstFitPlanner.java index 1647cf7dba9..e8504a991c1 100755 --- a/server/src/com/cloud/deploy/FirstFitPlanner.java +++ b/server/src/com/cloud/deploy/FirstFitPlanner.java @@ -452,21 +452,6 @@ public class FirstFitPlanner extends PlannerBase implements DeploymentPlanner { return disabledPods; } - private Map getCapacityThresholdMap(){ - // Lets build this real time so that the admin wont have to restart MS if he changes these values - Map disableThresholdMap = new HashMap(); - - String cpuDisableThresholdString = _configDao.getValue(Config.CPUCapacityDisableThreshold.key()); - float cpuDisableThreshold = NumbersUtil.parseFloat(cpuDisableThresholdString, 0.85F); - disableThresholdMap.put(Capacity.CAPACITY_TYPE_CPU, cpuDisableThreshold); - - String memoryDisableThresholdString = _configDao.getValue(Config.MemoryCapacityDisableThreshold.key()); - float memoryDisableThreshold = NumbersUtil.parseFloat(memoryDisableThresholdString, 0.85F); - disableThresholdMap.put(Capacity.CAPACITY_TYPE_MEMORY, memoryDisableThreshold); - - return disableThresholdMap; - } - private List getCapacitiesForCheckingThreshold(){ List capacityList = new ArrayList(); capacityList.add(Capacity.CAPACITY_TYPE_CPU); @@ -476,7 +461,6 @@ public class FirstFitPlanner extends PlannerBase implements DeploymentPlanner { private void removeClustersCrossingThreshold(List clusterListForVmAllocation, ExcludeList avoid, VirtualMachineProfile vmProfile, DeploymentPlan plan){ - Map capacityThresholdMap = getCapacityThresholdMap(); List capacityList = getCapacitiesForCheckingThreshold(); List clustersCrossingThreshold = new ArrayList(); @@ -491,12 +475,11 @@ public class FirstFitPlanner extends PlannerBase implements DeploymentPlanner { return; } if (capacity == Capacity.CAPACITY_TYPE_CPU) { - clustersCrossingThreshold = _capacityDao.listClustersCrossingThreshold(capacity, plan.getDataCenterId(), - capacityThresholdMap.get(capacity), cpu_requested); + clustersCrossingThreshold = _capacityDao.listClustersCrossingThreshold(capacity, plan.getDataCenterId(), Config.CPUCapacityDisableThreshold.key(), cpu_requested); } else if (capacity == Capacity.CAPACITY_TYPE_MEMORY ) { clustersCrossingThreshold = _capacityDao.listClustersCrossingThreshold(capacity, plan.getDataCenterId(), - capacityThresholdMap.get(capacity), ram_requested ); + Config.MemoryCapacityDisableThreshold.key(), ram_requested ); } @@ -506,8 +489,8 @@ public class FirstFitPlanner extends PlannerBase implements DeploymentPlanner { // Remove clusters crossing disabled threshold clusterListForVmAllocation.removeAll(clustersCrossingThreshold); - s_logger.debug("Cannot allocate cluster list " + clustersCrossingThreshold.toString() + " for vm creation since their allocated percentage" + - " crosses the disable capacity threshold: " + capacityThresholdMap.get(capacity) + " for capacity Type : " + capacity + ", skipping these clusters"); + s_logger.debug("Cannot allocate cluster list " + clustersCrossingThreshold.toString() + " for vm creation since their allocated percentage" + + " crosses the disable capacity threshold defined at each cluster/ at global value for capacity Type : " + capacity + ", skipping these clusters"); } } @@ -748,37 +731,43 @@ public class FirstFitPlanner extends PlannerBase implements DeploymentPlanner { //If the plan specifies a poolId, it means that this VM's ROOT volume is ready and the pool should be reused. //In this case, also check if rest of the volumes are ready and can be reused. if(plan.getPoolId() != null){ - s_logger.debug("Volume has pool already allocated, checking if pool can be reused, poolId: "+toBeCreated.getPoolId()); + s_logger.debug("Volume has pool(" + plan.getPoolId() + ") already allocated, checking if pool can be reused, poolId: "+toBeCreated.getPoolId()); List suitablePools = new ArrayList(); StoragePool pool = null; if(toBeCreated.getPoolId() != null){ + s_logger.debug("finding pool by id '" + toBeCreated.getPoolId() + "'"); pool = (StoragePool)this.dataStoreMgr.getPrimaryDataStore(toBeCreated.getPoolId()); }else{ + s_logger.debug("finding pool by id '" + plan.getPoolId() + "'"); pool = (StoragePool)this.dataStoreMgr.getPrimaryDataStore(plan.getPoolId()); } - if(!pool.isInMaintenance()){ - if(!avoid.shouldAvoid(pool)){ - long exstPoolDcId = pool.getDataCenterId(); + if(pool != null){ + if(!pool.isInMaintenance()){ + if(!avoid.shouldAvoid(pool)){ + long exstPoolDcId = pool.getDataCenterId(); - long exstPoolPodId = pool.getPodId() != null ? pool.getPodId() : -1; - long exstPoolClusterId = pool.getClusterId() != null ? pool.getClusterId() : -1; - if(plan.getDataCenterId() == exstPoolDcId && plan.getPodId() == exstPoolPodId && plan.getClusterId() == exstPoolClusterId){ - s_logger.debug("Planner need not allocate a pool for this volume since its READY"); - suitablePools.add(pool); - suitableVolumeStoragePools.put(toBeCreated, suitablePools); - if (!(toBeCreated.getState() == Volume.State.Allocated || toBeCreated.getState() == Volume.State.Creating)) { - readyAndReusedVolumes.add(toBeCreated); + long exstPoolPodId = pool.getPodId() != null ? pool.getPodId() : -1; + long exstPoolClusterId = pool.getClusterId() != null ? pool.getClusterId() : -1; + if(plan.getDataCenterId() == exstPoolDcId && plan.getPodId() == exstPoolPodId && plan.getClusterId() == exstPoolClusterId){ + s_logger.debug("Planner need not allocate a pool for this volume since its READY"); + suitablePools.add(pool); + suitableVolumeStoragePools.put(toBeCreated, suitablePools); + if (!(toBeCreated.getState() == Volume.State.Allocated || toBeCreated.getState() == Volume.State.Creating)) { + readyAndReusedVolumes.add(toBeCreated); + } + continue; + }else{ + s_logger.debug("Pool of the volume does not fit the specified plan, need to reallocate a pool for this volume"); } - continue; }else{ - s_logger.debug("Pool of the volume does not fit the specified plan, need to reallocate a pool for this volume"); + s_logger.debug("Pool of the volume is in avoid set, need to reallocate a pool for this volume"); } }else{ - s_logger.debug("Pool of the volume is in avoid set, need to reallocate a pool for this volume"); + s_logger.debug("Pool of the volume is in maintenance, need to reallocate a pool for this volume"); } }else{ - s_logger.debug("Pool of the volume is in maintenance, need to reallocate a pool for this volume"); + s_logger.debug("Unable to find pool by provided id"); } } diff --git a/server/src/com/cloud/maint/AgentUpgradeVO.java b/server/src/com/cloud/maint/AgentUpgradeVO.java deleted file mode 100644 index b36f5b7dd6c..00000000000 --- a/server/src/com/cloud/maint/AgentUpgradeVO.java +++ /dev/null @@ -1,63 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.maint; - -import org.apache.cloudstack.api.InternalIdentity; - -import javax.persistence.Column; -import javax.persistence.Entity; -import javax.persistence.EnumType; -import javax.persistence.Enumerated; -import javax.persistence.Id; -import javax.persistence.Table; - - -@Entity -@Table(name="op_host_upgrade") -public class AgentUpgradeVO implements InternalIdentity { - @Id - @Column(name="host_id") - private long id; - - @Column(name="version") - private String version; - - @Column(name="state") - @Enumerated(value=EnumType.STRING) - private UpgradeManager.State state; - - protected AgentUpgradeVO() { - } - - public AgentUpgradeVO(long id, String version, UpgradeManager.State state) { - this.id = id; - this.version = version; - this.state = state; - } - - public long getId() { - return id; - } - - public String getVersion() { - return version; - } - - public UpgradeManager.State getState() { - return state; - } -} diff --git a/server/src/com/cloud/maint/UpgradeManager.java b/server/src/com/cloud/maint/UpgradeManager.java deleted file mode 100644 index 71bca225b32..00000000000 --- a/server/src/com/cloud/maint/UpgradeManager.java +++ /dev/null @@ -1,47 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.maint; - -import com.cloud.utils.component.Manager; - -/** - * Upgrade Manager manages the upgrade of agents. - * - */ -public interface UpgradeManager extends Manager { - enum State { - RequiresUpdate, - WaitingForUpdate, - UpToDate; - }; - - /** - * Checks if the agent requires an upgrade before it can process - * any commands. - * - * @param hostId host id. - * @return state of the agent. - */ - State registerForUpgrade(long hostId, String version); - - /** - * @return the URL to download the new agent. - */ -// String getAgentUrl(); - - -} diff --git a/server/src/com/cloud/maint/UpgradeManagerImpl.java b/server/src/com/cloud/maint/UpgradeManagerImpl.java deleted file mode 100644 index 54e1ff4401e..00000000000 --- a/server/src/com/cloud/maint/UpgradeManagerImpl.java +++ /dev/null @@ -1,189 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.maint; - -import java.io.File; -import java.io.FileInputStream; -import java.io.FileOutputStream; -import java.io.IOException; -import java.io.InputStream; -import java.net.HttpURLConnection; -import java.nio.ByteBuffer; -import java.nio.channels.Channels; -import java.nio.channels.ReadableByteChannel; -import java.nio.channels.WritableByteChannel; -import java.util.Date; -import java.util.Map; -import java.util.Properties; - -import javax.ejb.Local; -import javax.inject.Inject; -import javax.naming.ConfigurationException; - -import org.apache.commons.httpclient.HttpClient; -import org.apache.commons.httpclient.HttpException; -import org.apache.commons.httpclient.MultiThreadedHttpConnectionManager; -import org.apache.commons.httpclient.methods.GetMethod; -import org.apache.log4j.Logger; -import org.springframework.stereotype.Component; - -import com.cloud.configuration.dao.ConfigurationDao; -import com.cloud.maint.dao.AgentUpgradeDao; -import com.cloud.utils.PropertiesUtil; -import com.cloud.utils.component.ManagerBase; - -/** - * - * UpgradeManagerImpl implements the upgrade process. It's functionalities - * include - * 1. Identifying agents that require an upgrade before it can connect. - * 2. Spread out a release update to agents so that the entire system - * does not come down at the same time. - */ -@Component -@Local(UpgradeManager.class) -public class UpgradeManagerImpl extends ManagerBase implements UpgradeManager { - private final static Logger s_logger = Logger.getLogger(UpgradeManagerImpl.class); - private static final MultiThreadedHttpConnectionManager s_httpClientManager = new MultiThreadedHttpConnectionManager(); - - String _minimalVersion; - String _recommendedVersion; -// String _upgradeUrl; - String _agentPath; - long _checkInterval; - - @Inject AgentUpgradeDao _upgradeDao; - @Inject ConfigurationDao _configDao; - - @Override - public State registerForUpgrade(long hostId, String version) { - State state = State.UpToDate; - s_logger.debug("Minimal version is " + _minimalVersion + "; version is " + version + "; recommended version is " + _recommendedVersion); - if (Version.compare(version, _minimalVersion) < 0) { - state = State.RequiresUpdate; - } else if (Version.compare(version, _recommendedVersion) < 0) { - state = State.WaitingForUpdate; - } else { - state = State.UpToDate; - } - - /* - if (state != State.UpToDate) { - AgentUpgradeVO vo = _upgradeDao.findById(hostId); - if (vo == null) { - vo = new AgentUpgradeVO(hostId, version, state); - _upgradeDao.persist(vo); - } - } - */ - - return state; - } - - public String deployNewAgent(String url) { - s_logger.info("Updating agent with binary from " + url); - - final HttpClient client = new HttpClient(s_httpClientManager); - final GetMethod method = new GetMethod(url); - int response; - File file = null; - try { - response = client.executeMethod(method); - if (response != HttpURLConnection.HTTP_OK) { - s_logger.warn("Retrieving the agent gives response code: " + response); - return "Retrieving the file from " + url + " got response code: " + response; - } - - final InputStream is = method.getResponseBodyAsStream(); - file = File.createTempFile("agent-", "-" + Long.toString(new Date().getTime())); - file.deleteOnExit(); - - s_logger.debug("Retrieving new agent into " + file.getAbsolutePath()); - - final FileOutputStream fos = new FileOutputStream(file); - - final ByteBuffer buffer = ByteBuffer.allocate(2048); - final ReadableByteChannel in = Channels.newChannel(is); - final WritableByteChannel out = fos.getChannel(); - - while (in.read(buffer) != -1) { - buffer.flip(); - out.write(buffer); - buffer.clear(); - } - - in.close(); - out.close(); - - s_logger.debug("New Agent zip file is now retrieved"); - } catch (final HttpException e) { - return "Unable to retrieve the file from " + url; - } catch (final IOException e) { - return "Unable to retrieve the file from " + url; - } finally { - method.releaseConnection(); - } - - file.delete(); - - return "File will be deployed."; - } - -// @Override -// public String getAgentUrl() { -// return _upgradeUrl; -// } - - @Override - public boolean configure(String name, Map params) throws ConfigurationException { - - final Map configs = _configDao.getConfiguration("UpgradeManager", params); - - File agentUpgradeFile = PropertiesUtil.findConfigFile("agent-update.properties"); - Properties agentUpgradeProps = new Properties(); - try { - if (agentUpgradeFile != null) { - agentUpgradeProps.load(new FileInputStream(agentUpgradeFile)); - } - - _minimalVersion = agentUpgradeProps.getProperty("agent.minimal.version"); - _recommendedVersion = agentUpgradeProps.getProperty("agent.recommended.version"); - - if (_minimalVersion == null) { - _minimalVersion = "0.0.0.0"; - } - - if (_recommendedVersion == null) { - _recommendedVersion = _minimalVersion; - } - - //_upgradeUrl = configs.get("upgrade.url"); - -// if (_upgradeUrl == null) { -// s_logger.debug("There is no upgrade url found in configuration table"); -// // _upgradeUrl = "http://updates.vmops.com/releases/rss.xml"; -// } - - return true; - } catch (IOException ex) { - if (s_logger.isDebugEnabled()) { - s_logger.debug("Error reading agent-update.properties: " + ex); - } - } - return false; - } -} diff --git a/server/src/com/cloud/migration/Db21to22MigrationUtil.java b/server/src/com/cloud/migration/Db21to22MigrationUtil.java deleted file mode 100755 index 66a7d59f53a..00000000000 --- a/server/src/com/cloud/migration/Db21to22MigrationUtil.java +++ /dev/null @@ -1,228 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.migration; - -import java.io.File; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.util.List; - -import javax.inject.Inject; - -import org.apache.log4j.xml.DOMConfigurator; - -import com.cloud.configuration.Resource; -import com.cloud.configuration.Resource.ResourceType; -import com.cloud.configuration.ResourceCountVO; -import com.cloud.configuration.dao.ConfigurationDao; -import com.cloud.configuration.dao.ResourceCountDao; -import com.cloud.dc.DataCenter.NetworkType; -import com.cloud.dc.DataCenterVO; -import com.cloud.dc.dao.ClusterDao; -import com.cloud.dc.dao.DataCenterDao; -import com.cloud.domain.DomainVO; -import com.cloud.domain.dao.DomainDao; -import com.cloud.host.dao.HostDao; -import com.cloud.resource.ResourceManager; -import com.cloud.user.Account; -import com.cloud.user.dao.AccountDao; -import com.cloud.utils.PropertiesUtil; -import com.cloud.utils.db.SearchBuilder; -import com.cloud.utils.db.SearchCriteria; -import com.cloud.utils.db.Transaction; -import com.cloud.vm.InstanceGroupVMMapVO; -import com.cloud.vm.InstanceGroupVO; -import com.cloud.vm.dao.InstanceGroupDao; -import com.cloud.vm.dao.InstanceGroupVMMapDao; - -public class Db21to22MigrationUtil { - - @Inject private ClusterDao _clusterDao; - @Inject private HostDao _hostDao; - @Inject private AccountDao _accountDao; - @Inject private DomainDao _domainDao; - @Inject private ResourceCountDao _resourceCountDao; - @Inject private InstanceGroupDao _vmGroupDao; - @Inject private InstanceGroupVMMapDao _groupVMMapDao; - @Inject private ConfigurationDao _configurationDao; - @Inject private DataCenterDao _zoneDao; - @Inject private ResourceManager _resourceMgr; - - private void doMigration() { - setupComponents(); - - migrateResourceCounts(); - - setupInstanceGroups(); - - migrateZones(); - - setupClusterGuid(); - - System.out.println("Migration done"); - } - - /* add guid in cluster table */ - private void setupClusterGuid() { - - //FIXME moving out XenServer code out of server. This upgrade step need to be taken care of - /* - XenServerConnectionPool _connPool = XenServerConnectionPool.getInstance(); - List clusters = _clusterDao.listByHyTypeWithoutGuid(HypervisorType.XenServer.toString()); - for (ClusterVO cluster : clusters) { - List hosts = _resourceMgr.listAllHostsInCluster(cluster.getId()); - for (HostVO host : hosts) { - String ip = host.getPrivateIpAddress(); - String username = host.getDetail("username"); - String password = host.getDetail("password"); - if (ip == null || ip.isEmpty() || username == null || username.isEmpty() || password == null - || password.isEmpty()) { - continue; - } - Queue pass=new LinkedList(); - pass.add(password); - Connection conn = _connPool.slaveConnect(ip, username, pass); - if (conn == null) - continue; - Pool.Record pr = null; - try { - pr = XenServerConnectionPool.getPoolRecord(conn); - } catch (Exception e) { - continue; - } finally { - try { - Session.localLogout(conn); - } catch (Exception e) { - } - } - cluster.setGuid(pr.uuid); - _clusterDao.update(cluster.getId(), cluster); - break; - } - } - */ - } - - - /** - * This method migrates the zones based on bug: 7204 - * based on the param direct.attach.untagged.vlan.enabled, we update zone to basic or advanced for 2.2 - */ - private void migrateZones(){ - try { - System.out.println("Migrating zones"); - String val = _configurationDao.getValue("direct.attach.untagged.vlan.enabled"); - NetworkType networkType; - if(val == null || val.equalsIgnoreCase("true")){ - networkType = NetworkType.Basic; - }else{ - networkType = NetworkType.Advanced; - } - List existingZones = _zoneDao.listAll(); - for(DataCenterVO zone : existingZones){ - zone.setNetworkType(networkType); - _zoneDao.update(zone.getId(), zone); - } - } catch (Exception e) { - System.out.println("Unhandled exception in migrateZones()" + e); - } - } - - private void migrateResourceCounts() { - System.out.println("migrating resource counts"); - SearchBuilder sb = _resourceCountDao.createSearchBuilder(); - sb.and("type", sb.entity().getType(), SearchCriteria.Op.EQ); - - for (ResourceType type : Resource.ResourceType.values()) { - SearchCriteria sc = sb.create(); - sc.setParameters("type", type); - - List resourceCounts = _resourceCountDao.search(sc, null); - for (ResourceCountVO resourceCount : resourceCounts) { - if (resourceCount.getAccountId() != null) { - Account acct = _accountDao.findById(resourceCount.getAccountId()); - Long domainId = acct.getDomainId(); - while (domainId != null) { - _resourceCountDao.updateDomainCount(domainId, type, true, resourceCount.getCount()); - DomainVO domain = _domainDao.findById(domainId); - domainId = domain.getParent(); - } - } - } - } - System.out.println("done migrating resource counts"); - } - - private void setupComponents() { - } - - private void setupInstanceGroups() { - System.out.println("setting up vm instance groups"); - - //Search for all the vms that have not null groups - Long vmId = 0L; - Long accountId = 0L; - String groupName; - Transaction txn = Transaction.open(Transaction.CLOUD_DB); - txn.start(); - try { - String request = "SELECT vm.id, uservm.account_id, vm.group from vm_instance vm, user_vm uservm where vm.group is not null and vm.removed is null and vm.id=uservm.id order by id"; - System.out.println(request); - PreparedStatement statement = txn.prepareStatement(request); - ResultSet result = statement.executeQuery(); - while (result.next()) { - vmId = result.getLong(1); - accountId = result.getLong(2); - groupName = result.getString(3); - InstanceGroupVO group = _vmGroupDao.findByAccountAndName(accountId, groupName); - //Create vm group if the group doesn't exist for this account - if (group == null) { - group = new InstanceGroupVO(groupName, accountId); - group = _vmGroupDao.persist(group); - System.out.println("Created new isntance group with name " + groupName + " for account id=" + accountId); - } - - if (group != null) { - InstanceGroupVMMapVO groupVmMapVO = new InstanceGroupVMMapVO(group.getId(), vmId); - _groupVMMapDao.persist(groupVmMapVO); - System.out.println("Assigned vm id=" + vmId + " to group with name " + groupName + " for account id=" + accountId); - } - } - txn.commit(); - statement.close(); - } catch (Exception e) { - System.out.println("Unhandled exception: " + e); - } finally { - txn.close(); - } - } - - - public static void main(String[] args) { - File file = PropertiesUtil.findConfigFile("log4j-cloud.xml"); - - if (file != null) { - System.out.println("Log4j configuration from : " + file.getAbsolutePath()); - DOMConfigurator.configureAndWatch(file.getAbsolutePath(), 10000); - } else { - System.out.println("Configure log4j with default properties"); - } - - new Db21to22MigrationUtil().doMigration(); - System.exit(0); - } -} diff --git a/server/src/com/cloud/migration/Db22beta4to22GAMigrationUtil.java b/server/src/com/cloud/migration/Db22beta4to22GAMigrationUtil.java deleted file mode 100644 index 4487d654571..00000000000 --- a/server/src/com/cloud/migration/Db22beta4to22GAMigrationUtil.java +++ /dev/null @@ -1,128 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.migration; - -import java.io.File; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.SQLException; -import java.util.HashMap; -import java.util.Map; -import java.util.Set; - -import org.apache.log4j.xml.DOMConfigurator; - -import com.cloud.utils.PropertiesUtil; -import com.cloud.utils.db.DB; -import com.cloud.utils.db.Transaction; -import com.cloud.utils.exception.CloudRuntimeException; - -@DB(txn=false) -public class Db22beta4to22GAMigrationUtil { - - private Map pfRuleIdToIpAddressIdMap = new HashMap(); - private final String FindPfIdToPublicIpId = "SELECT id,ip_address_id from firewall_rules where is_static_nat=1"; - private final String FindVmIdPerPfRule = "SELECT instance_id from port_forwarding_rules where id = ?"; - private final String WriteVmIdToIpAddrTable = "UPDATE user_ip_address set vm_id = ? where id = ?"; - protected Db22beta4to22GAMigrationUtil() { - } - - @DB - //This method gets us a map of pf/firewall id <-> ip address id - //Using the keyset, we will iterate over the pf table to find corresponding vm id - //When we get the vm id, we will use the val for each key to update the corresponding ip addr row with the vm id - public void populateMap(){ - Long key = null; - Long val = null; - - Transaction txn = Transaction.open(Transaction.CLOUD_DB); - - StringBuilder sql = new StringBuilder(FindPfIdToPublicIpId); - - PreparedStatement pstmt = null; - try { - pstmt = txn.prepareAutoCloseStatement(sql.toString()); - - ResultSet rs = pstmt.executeQuery(); - while (rs.next()) { - key = rs.getLong("id"); - val = rs.getLong("ip_address_id"); - pfRuleIdToIpAddressIdMap.put(key, val); - } - - } catch (SQLException e) { - throw new CloudRuntimeException("Unable to execute " + pstmt.toString(), e); - } - - } - - @DB - public void updateVmIdForIpAddresses(){ - Transaction txn = Transaction.open(Transaction.CLOUD_DB); - Set pfIds = pfRuleIdToIpAddressIdMap.keySet(); - StringBuilder sql = new StringBuilder(FindVmIdPerPfRule); - Long vmId = null; - Long ipAddressId = null; - PreparedStatement pstmt = null; - for(Long pfId : pfIds){ - try { - pstmt = txn.prepareAutoCloseStatement(sql.toString()); - pstmt.setLong(1, pfId); - ResultSet rs = pstmt.executeQuery(); - while(rs.next()) { - vmId = rs.getLong("instance_id"); - } - ipAddressId = pfRuleIdToIpAddressIdMap.get(pfId); - finallyUpdate(ipAddressId, vmId, txn); - } catch (SQLException e) { - throw new CloudRuntimeException("Unable to execute " + pstmt.toString(), e); - } - } - } - - @DB - public void finallyUpdate(Long ipAddressId, Long vmId, Transaction txn){ - - StringBuilder sql = new StringBuilder(WriteVmIdToIpAddrTable); - - PreparedStatement pstmt = null; - try { - pstmt = txn.prepareAutoCloseStatement(sql.toString()); - pstmt.setLong(1, vmId); - pstmt.setLong(2, ipAddressId); - int rs = pstmt.executeUpdate(); - } catch (SQLException e) { - throw new CloudRuntimeException("Unable to execute " + pstmt.toString(), e); - } - } - - public static void main(String[] args) { - - File file = PropertiesUtil.findConfigFile("log4j-cloud.xml"); - - if(file != null) { - System.out.println("Log4j configuration from : " + file.getAbsolutePath()); - DOMConfigurator.configureAndWatch(file.getAbsolutePath(), 10000); - } else { - System.out.println("Configure log4j with default properties"); - } - - Db22beta4to22GAMigrationUtil util = new Db22beta4to22GAMigrationUtil(); - util.populateMap(); - util.updateVmIdForIpAddresses(); - } -} diff --git a/server/src/com/cloud/network/ExternalLoadBalancerDeviceManager.java b/server/src/com/cloud/network/ExternalLoadBalancerDeviceManager.java index 9f11b850180..cb00614b086 100644 --- a/server/src/com/cloud/network/ExternalLoadBalancerDeviceManager.java +++ b/server/src/com/cloud/network/ExternalLoadBalancerDeviceManager.java @@ -23,7 +23,7 @@ import com.cloud.exception.InsufficientCapacityException; import com.cloud.exception.ResourceUnavailableException; import com.cloud.host.Host; import com.cloud.network.dao.ExternalLoadBalancerDeviceVO; -import com.cloud.network.rules.FirewallRule; +import com.cloud.network.lb.LoadBalancingRule; import com.cloud.resource.ServerResource; import com.cloud.utils.component.Manager; @@ -89,7 +89,7 @@ public interface ExternalLoadBalancerDeviceManager extends Manager{ * @return true if successfully applied rules * @throws ResourceUnavailableException */ - public boolean applyLoadBalancerRules(Network network, List rules) throws ResourceUnavailableException; + public boolean applyLoadBalancerRules(Network network, List rules) throws ResourceUnavailableException; /** * implements or shutdowns guest network on the load balancer device assigned to the guest network @@ -102,6 +102,6 @@ public interface ExternalLoadBalancerDeviceManager extends Manager{ public boolean manageGuestNetworkWithExternalLoadBalancer(boolean add, Network guestConfig) throws ResourceUnavailableException, InsufficientCapacityException; - public List getLBHealthChecks(Network network, List rules) + public List getLBHealthChecks(Network network, List rules) throws ResourceUnavailableException; } diff --git a/server/src/com/cloud/network/ExternalLoadBalancerDeviceManagerImpl.java b/server/src/com/cloud/network/ExternalLoadBalancerDeviceManagerImpl.java index b4662d13df3..f93bf7ae9b5 100644 --- a/server/src/com/cloud/network/ExternalLoadBalancerDeviceManagerImpl.java +++ b/server/src/com/cloud/network/ExternalLoadBalancerDeviceManagerImpl.java @@ -270,7 +270,7 @@ public abstract class ExternalLoadBalancerDeviceManagerImpl extends AdapterBase lbDeviceVO = new ExternalLoadBalancerDeviceVO(host.getId(), pNetwork.getId(), ntwkDevice.getNetworkServiceProvder(), deviceName, capacity, dedicatedUse, gslbProvider); if (gslbProvider) { - lbDeviceVO.setGslbSitePrivateIP(gslbSitePublicIp); + lbDeviceVO.setGslbSitePublicIP(gslbSitePublicIp); lbDeviceVO.setGslbSitePrivateIP(gslbSitePrivateIp); } _externalLoadBalancerDeviceDao.persist(lbDeviceVO); @@ -829,19 +829,11 @@ public abstract class ExternalLoadBalancerDeviceManagerImpl extends AdapterBase } @Override - public boolean applyLoadBalancerRules(Network network, List rules) throws ResourceUnavailableException { + public boolean applyLoadBalancerRules(Network network, List loadBalancingRules) throws ResourceUnavailableException { // Find the external load balancer in this zone long zoneId = network.getDataCenterId(); DataCenterVO zone = _dcDao.findById(zoneId); - List loadBalancingRules = new ArrayList(); - - for (FirewallRule rule : rules) { - if (rule.getPurpose().equals(Purpose.LoadBalancing)) { - loadBalancingRules.add((LoadBalancingRule) rule); - } - } - if (loadBalancingRules == null || loadBalancingRules.isEmpty()) { return true; } @@ -870,12 +862,13 @@ public abstract class ExternalLoadBalancerDeviceManagerImpl extends AdapterBase String protocol = rule.getProtocol(); String algorithm = rule.getAlgorithm(); String uuid = rule.getUuid(); - String srcIp = _networkModel.getIp(rule.getSourceIpAddressId()).getAddress().addr(); + String srcIp = rule.getSourceIp().addr(); int srcPort = rule.getSourcePortStart(); List destinations = rule.getDestinations(); if (externalLoadBalancerIsInline) { - MappingNic nic = getLoadBalancingIpNic(zone, network, rule.getSourceIpAddressId(), revoked, null); + long ipId = _networkModel.getPublicIpAddress(rule.getSourceIp().addr(), network.getDataCenterId()).getId(); + MappingNic nic = getLoadBalancingIpNic(zone, network, ipId, revoked, null); mappingStates.add(nic.getState()); NicVO loadBalancingIpNic = nic.getNic(); if (loadBalancingIpNic == null) { @@ -927,7 +920,8 @@ public abstract class ExternalLoadBalancerDeviceManagerImpl extends AdapterBase } else { continue; } - getLoadBalancingIpNic(zone, network, rule.getSourceIpAddressId(), revoke, existedGuestIp); + long sourceIpId = _networkModel.getPublicIpAddress(rule.getSourceIp().addr(), network.getDataCenterId()).getId(); + getLoadBalancingIpNic(zone, network, sourceIpId, revoke, existedGuestIp); } } throw new ResourceUnavailableException(ex.getMessage(), DataCenter.class, network.getDataCenterId()); @@ -1113,7 +1107,7 @@ public abstract class ExternalLoadBalancerDeviceManagerImpl extends AdapterBase } @Override - public List getLBHealthChecks(Network network, List rules) + public List getLBHealthChecks(Network network, List loadBalancingRules) throws ResourceUnavailableException { // Find the external load balancer in this zone @@ -1121,14 +1115,6 @@ public abstract class ExternalLoadBalancerDeviceManagerImpl extends AdapterBase DataCenterVO zone = _dcDao.findById(zoneId); HealthCheckLBConfigAnswer answer = null; - List loadBalancingRules = new ArrayList(); - - for (FirewallRule rule : rules) { - if (rule.getPurpose().equals(Purpose.LoadBalancing)) { - loadBalancingRules.add((LoadBalancingRule) rule); - } - } - if (loadBalancingRules == null || loadBalancingRules.isEmpty()) { return null; } @@ -1158,12 +1144,13 @@ public abstract class ExternalLoadBalancerDeviceManagerImpl extends AdapterBase String protocol = rule.getProtocol(); String algorithm = rule.getAlgorithm(); String uuid = rule.getUuid(); - String srcIp = _networkModel.getIp(rule.getSourceIpAddressId()).getAddress().addr(); + String srcIp = rule.getSourceIp().addr(); int srcPort = rule.getSourcePortStart(); List destinations = rule.getDestinations(); if (externalLoadBalancerIsInline) { - MappingNic nic = getLoadBalancingIpNic(zone, network, rule.getSourceIpAddressId(), revoked, null); + long sourceIpId = _networkModel.getPublicIpAddress(rule.getSourceIp().addr(), network.getDataCenterId()).getId(); + MappingNic nic = getLoadBalancingIpNic(zone, network, sourceIpId, revoked, null); mappingStates.add(nic.getState()); NicVO loadBalancingIpNic = nic.getNic(); if (loadBalancingIpNic == null) { diff --git a/server/src/com/cloud/network/ExternalLoadBalancerUsageManagerImpl.java b/server/src/com/cloud/network/ExternalLoadBalancerUsageManagerImpl.java index d405382f89c..2c8031c64f0 100644 --- a/server/src/com/cloud/network/ExternalLoadBalancerUsageManagerImpl.java +++ b/server/src/com/cloud/network/ExternalLoadBalancerUsageManagerImpl.java @@ -16,6 +16,22 @@ // under the License. package com.cloud.network; +import java.net.URI; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.concurrent.Executors; +import java.util.concurrent.ScheduledExecutorService; +import java.util.concurrent.TimeUnit; + +import javax.ejb.Local; +import javax.inject.Inject; +import javax.naming.ConfigurationException; + +import org.apache.log4j.Logger; +import org.springframework.stereotype.Component; + import com.cloud.agent.AgentManager; import com.cloud.agent.api.ExternalNetworkResourceUsageAnswer; import com.cloud.agent.api.ExternalNetworkResourceUsageCommand; @@ -48,6 +64,7 @@ import com.cloud.network.dao.NetworkServiceMapDao; import com.cloud.network.dao.NetworkVO; import com.cloud.network.dao.PhysicalNetworkDao; import com.cloud.network.dao.PhysicalNetworkServiceProviderDao; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.network.rules.PortForwardingRuleVO; import com.cloud.network.rules.dao.PortForwardingRulesDao; import com.cloud.offerings.dao.NetworkOfferingDao; @@ -68,20 +85,6 @@ import com.cloud.vm.DomainRouterVO; import com.cloud.vm.NicVO; import com.cloud.vm.dao.DomainRouterDao; import com.cloud.vm.dao.NicDao; -import org.apache.log4j.Logger; -import org.springframework.stereotype.Component; - -import javax.ejb.Local; -import javax.inject.Inject; -import javax.naming.ConfigurationException; -import java.net.URI; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.concurrent.Executors; -import java.util.concurrent.ScheduledExecutorService; -import java.util.concurrent.TimeUnit; @Component @Local(value = { ExternalLoadBalancerUsageManager.class }) @@ -647,9 +650,10 @@ public class ExternalLoadBalancerUsageManagerImpl extends ManagerBase implements // If an external load balancer is added, manage one entry for each load balancing rule in this network if (externalLoadBalancer != null && lbAnswer != null) { boolean inline = _networkMgr.isNetworkInlineMode(network); - List loadBalancers = _loadBalancerDao.listByNetworkId(network.getId()); + List loadBalancers = _loadBalancerDao.listByNetworkIdAndScheme(network.getId(), Scheme.Public); for (LoadBalancerVO loadBalancer : loadBalancers) { String publicIp = _networkMgr.getIp(loadBalancer.getSourceIpAddressId()).getAddress().addr(); + if (!createOrUpdateStatsEntry(create, accountId, zoneId, network.getId(), publicIp, externalLoadBalancer.getId(), lbAnswer, inline)) { throw new ExecutionException(networkErrorMsg + ", load balancing rule public IP = " + publicIp); } diff --git a/server/src/com/cloud/network/NetworkManager.java b/server/src/com/cloud/network/NetworkManager.java index 4af716ca12a..34a092a465a 100755 --- a/server/src/com/cloud/network/NetworkManager.java +++ b/server/src/com/cloud/network/NetworkManager.java @@ -43,6 +43,7 @@ import com.cloud.network.element.StaticNatServiceProvider; import com.cloud.network.element.UserDataServiceProvider; import com.cloud.network.guru.NetworkGuru; import com.cloud.network.rules.FirewallRule; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.network.rules.StaticNat; import com.cloud.offering.NetworkOffering; import com.cloud.offerings.NetworkOfferingVO; @@ -333,7 +334,7 @@ public interface NetworkManager { int getRuleCountForIp(Long addressId, FirewallRule.Purpose purpose, FirewallRule.State state); - LoadBalancingServiceProvider getLoadBalancingProviderForNetwork(Network network); + LoadBalancingServiceProvider getLoadBalancingProviderForNetwork(Network network, Scheme lbScheme); boolean isSecondaryIpSetForNic(long nicId); diff --git a/server/src/com/cloud/network/NetworkManagerImpl.java b/server/src/com/cloud/network/NetworkManagerImpl.java index 72ccac0ec7d..c91243095da 100755 --- a/server/src/com/cloud/network/NetworkManagerImpl.java +++ b/server/src/com/cloud/network/NetworkManagerImpl.java @@ -31,6 +31,7 @@ import com.cloud.dc.DataCenter.NetworkType; import com.cloud.dc.Vlan.VlanType; import com.cloud.dc.dao.AccountVlanMapDao; import com.cloud.dc.dao.DataCenterDao; +import com.cloud.dc.dao.DataCenterVnetDao; import com.cloud.dc.dao.PodVlanMapDao; import com.cloud.dc.dao.VlanDao; import com.cloud.deploy.DataCenterDeployment; @@ -46,6 +47,7 @@ import com.cloud.host.Host; import com.cloud.host.HostVO; import com.cloud.host.Status; import com.cloud.host.dao.HostDao; +import com.cloud.server.ConfigurationServer; import com.cloud.hypervisor.Hypervisor.HypervisorType; import com.cloud.network.IpAddress.State; import com.cloud.network.Network.*; @@ -60,6 +62,13 @@ import com.cloud.network.guru.NetworkGuru; import com.cloud.network.lb.LoadBalancingRulesManager; import com.cloud.network.rules.*; import com.cloud.network.rules.FirewallRule.Purpose; +import com.cloud.network.rules.FirewallRuleVO; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.network.rules.PortForwardingRuleVO; +import com.cloud.network.rules.RulesManager; +import com.cloud.network.rules.StaticNat; +import com.cloud.network.rules.StaticNatRule; +import com.cloud.network.rules.StaticNatRuleImpl; import com.cloud.network.rules.dao.PortForwardingRulesDao; import com.cloud.network.vpc.NetworkACLManager; import com.cloud.network.vpc.VpcManager; @@ -70,6 +79,7 @@ import com.cloud.offering.NetworkOffering.Availability; import com.cloud.offerings.NetworkOfferingServiceMapVO; import com.cloud.offerings.NetworkOfferingVO; import com.cloud.offerings.dao.NetworkOfferingDao; +import com.cloud.offerings.dao.NetworkOfferingDetailsDao; import com.cloud.offerings.dao.NetworkOfferingServiceMapDao; import com.cloud.org.Grouping; import com.cloud.user.*; @@ -153,6 +163,14 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L RemoteAccessVpnService _vpnMgr; @Inject PodVlanMapDao _podVlanMapDao; + @Inject + NetworkOfferingDetailsDao _ntwkOffDetailsDao; + @Inject + ConfigurationServer _configServer; + @Inject + AccountGuestVlanMapDao _accountGuestVlanMapDao; + @Inject + DataCenterVnetDao _datacenterVnetDao; List _networkGurus; public List getNetworkGurus() { @@ -245,7 +263,6 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L int _networkGcWait; int _networkGcInterval; - String _networkDomain; int _networkLockTimeout; private Map _configs; @@ -367,9 +384,12 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L VlanVO vlan = _vlanDao.findById(addr.getVlanId()); String guestType = vlan.getVlanType().toString(); - UsageEventUtils.publishUsageEvent(EventTypes.EVENT_NET_IP_ASSIGN, owner.getId(), - addr.getDataCenterId(), addr.getId(), addr.getAddress().toString(), addr.isSourceNat(), guestType, - addr.getSystem(), addr.getClass().getName(), addr.getUuid()); + + if (!isIpDedicated(addr)) { + UsageEventUtils.publishUsageEvent(EventTypes.EVENT_NET_IP_ASSIGN, owner.getId(), + addr.getDataCenterId(), addr.getId(), addr.getAddress().toString(), addr.isSourceNat(), guestType, + addr.getSystem(), addr.getClass().getName(), addr.getUuid()); + } // don't increment resource count for direct ip addresses if (addr.getAssociatedWithNetworkId() != null) { _resourceLimitMgr.incrementResourceCount(owner.getId(), ResourceType.public_ip); @@ -379,6 +399,12 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L txn.commit(); } + private boolean isIpDedicated(IPAddressVO addr) { + List maps = _accountVlanMapDao.listAccountVlanMapsByVlan(addr.getVlanId()); + if (maps != null && !maps.isEmpty()) + return true; + return false; + } @Override public PublicIp assignSourceNatIpAddressToGuestNetwork(Account owner, Network guestNetwork) @@ -866,7 +892,6 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L _networkGcInterval = NumbersUtil.parseInt(_configs.get(Config.NetworkGcInterval.key()), 600); _configs = _configDao.getConfiguration("Network", params); - _networkDomain = _configs.get(Config.GuestDomainSuffix.key()); _networkLockTimeout = NumbersUtil.parseInt(_configs.get(Config.NetworkLockTimeout.key()), 600); @@ -933,7 +958,7 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L _configMgr.createNetworkOffering(NetworkOffering.QuickCloudNoServices, "Offering for QuickCloud with no services", TrafficType.Guest, null, true, Availability.Optional, null, new HashMap>(), true, - Network.GuestType.Shared, false, null, true, null, true, false); + Network.GuestType.Shared, false, null, true, null, true, false, null); offering.setState(NetworkOffering.State.Enabled); _networkOfferingDao.update(offering.getId(), offering); } @@ -942,14 +967,14 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L _configMgr.createNetworkOffering(NetworkOffering.DefaultSharedNetworkOfferingWithSGService, "Offering for Shared Security group enabled networks", TrafficType.Guest, null, true, Availability.Optional, null, defaultSharedNetworkOfferingProviders, true, - Network.GuestType.Shared, false, null, true, null, true, false); + Network.GuestType.Shared, false, null, true, null, true, false, null); offering.setState(NetworkOffering.State.Enabled); _networkOfferingDao.update(offering.getId(), offering); } if (_networkOfferingDao.findByUniqueName(NetworkOffering.DefaultSharedNetworkOffering) == null) { offering = _configMgr.createNetworkOffering(NetworkOffering.DefaultSharedNetworkOffering, "Offering for Shared networks", TrafficType.Guest, null, true, Availability.Optional, null, - defaultSharedNetworkOfferingProviders, true, Network.GuestType.Shared, false, null, true, null, true, false); + defaultSharedNetworkOfferingProviders, true, Network.GuestType.Shared, false, null, true, null, true, false, null); offering.setState(NetworkOffering.State.Enabled); _networkOfferingDao.update(offering.getId(), offering); } @@ -972,7 +997,7 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L offering = _configMgr.createNetworkOffering(NetworkOffering.DefaultIsolatedNetworkOfferingWithSourceNatService, "Offering for Isolated networks with Source Nat service enabled", TrafficType.Guest, null, false, Availability.Required, null, defaultINetworkOfferingProvidersForVpcNetwork, - true, Network.GuestType.Isolated, false, null, true, null, false, false); + true, Network.GuestType.Isolated, false, null, true, null, false, false, null); offering.setState(NetworkOffering.State.Enabled); _networkOfferingDao.update(offering.getId(), offering); } @@ -981,7 +1006,7 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L offering = _configMgr.createNetworkOffering(NetworkOffering.DefaultIsolatedNetworkOfferingForVpcNetworks, "Offering for Isolated VPC networks with Source Nat service enabled", TrafficType.Guest, null, false, Availability.Optional, null, defaultVPCOffProviders, - true, Network.GuestType.Isolated, false, null, false, null, false, false); + true, Network.GuestType.Isolated, false, null, false, null, false, false, null); offering.setState(NetworkOffering.State.Enabled); _networkOfferingDao.update(offering.getId(), offering); } @@ -992,7 +1017,7 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L offering = _configMgr.createNetworkOffering(NetworkOffering.DefaultIsolatedNetworkOfferingForVpcNetworksNoLB, "Offering for Isolated VPC networks with Source Nat service enabled and LB service disabled", TrafficType.Guest, null, false, Availability.Optional, null, defaultVPCOffProviders, - true, Network.GuestType.Isolated, false, null, false, null, false, false); + true, Network.GuestType.Isolated, false, null, false, null, false, false, null); offering.setState(NetworkOffering.State.Enabled); _networkOfferingDao.update(offering.getId(), offering); } @@ -1001,7 +1026,7 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L offering = _configMgr.createNetworkOffering(NetworkOffering.DefaultIsolatedNetworkOffering, "Offering for Isolated networks with no Source Nat service", TrafficType.Guest, null, true, Availability.Optional, null, defaultIsolatedNetworkOfferingProviders, true, Network.GuestType.Isolated, - false, null, true, null, true, false); + false, null, true, null, true, false, null); offering.setState(NetworkOffering.State.Enabled); _networkOfferingDao.update(offering.getId(), offering); } @@ -1030,7 +1055,7 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L if (_networkOfferingDao.findByUniqueName(NetworkOffering.DefaultSharedEIPandELBNetworkOffering) == null) { offering = _configMgr.createNetworkOffering(NetworkOffering.DefaultSharedEIPandELBNetworkOffering, "Offering for Shared networks with Elastic IP and Elastic LB capabilities", TrafficType.Guest, null, true, - Availability.Optional, null, netscalerServiceProviders, true, Network.GuestType.Shared, false, null, true, serviceCapabilityMap, true, false); + Availability.Optional, null, netscalerServiceProviders, true, Network.GuestType.Shared, false, null, true, serviceCapabilityMap, true, false, null); offering.setState(NetworkOffering.State.Enabled); offering.setDedicatedLB(false); _networkOfferingDao.update(offering.getId(), offering); @@ -1988,8 +2013,34 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L // For Isolated networks, don't allow to create network with vlan that already exists in the zone if (ntwkOff.getGuestType() == GuestType.Isolated) { if (_networksDao.countByZoneAndUri(zoneId, uri) > 0) { - throw new InvalidParameterValueException("Network with vlan " + vlanId + " already exists in zone " + zoneId); - } + throw new InvalidParameterValueException("Network with vlan " + vlanId + " already exists in zone " + zoneId); + } else { + List dcVnets = _datacenterVnetDao.findVnet(zoneId, vlanId.toString()); + //for the network that is created as part of private gateway, + //the vnet is not coming from the data center vnet table, so the list can be empty + if (!dcVnets.isEmpty()) { + DataCenterVnetVO dcVnet = dcVnets.get(0); + // Fail network creation if specified vlan is dedicated to a different account + if (dcVnet.getAccountGuestVlanMapId() != null) { + Long accountGuestVlanMapId = dcVnet.getAccountGuestVlanMapId(); + AccountGuestVlanMapVO map = _accountGuestVlanMapDao.findById(accountGuestVlanMapId); + if (map.getAccountId() != owner.getAccountId()) { + throw new InvalidParameterValueException("Vlan " + vlanId + " is dedicated to a different account"); + } + // Fail network creation if owner has a dedicated range of vlans but the specified vlan belongs to the system pool + } else { + List maps = _accountGuestVlanMapDao.listAccountGuestVlanMapsByAccount(owner.getAccountId()); + if (maps != null && !maps.isEmpty()) { + int vnetsAllocatedToAccount = _datacenterVnetDao.countVnetsAllocatedToAccount(zoneId, owner.getAccountId()); + int vnetsDedicatedToAccount = _datacenterVnetDao.countVnetsDedicatedToAccount(zoneId, owner.getAccountId()); + if (vnetsAllocatedToAccount < vnetsDedicatedToAccount) { + throw new InvalidParameterValueException("Specified vlan " + vlanId + " doesn't belong" + + " to the vlan range dedicated to the owner "+ owner.getAccountName()); + } + } + } + } + } } else { // don't allow to creating shared network with given Vlan ID, if there already exists a isolated network or // shared network with same Vlan ID in the zone @@ -1998,7 +2049,10 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L throw new InvalidParameterValueException("There is a isolated/shared network with vlan id: " + vlanId + " already exists " + "in zone " + zoneId); } - } + } + + + } // If networkDomain is not specified, take it from the global configuration @@ -2023,7 +2077,7 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L // 2) If null, generate networkDomain using domain suffix from the global config variables if (networkDomain == null) { - networkDomain = "cs" + Long.toHexString(owner.getId()) + _networkDomain; + networkDomain = "cs" + Long.toHexString(owner.getId()) + _configServer.getConfigValue(Config.GuestDomainSuffix.key(), Config.ConfigurationParameterScope.zone.toString(), zoneId); } } else { @@ -2607,9 +2661,15 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L success = false; } - // apply load balancer rules - if (!_lbMgr.applyLoadBalancersForNetwork(networkId)) { - s_logger.warn("Failed to reapply load balancer rules as a part of network id=" + networkId + " restart"); + // apply public load balancer rules + if (!_lbMgr.applyLoadBalancersForNetwork(networkId, Scheme.Public)) { + s_logger.warn("Failed to reapply Public load balancer rules as a part of network id=" + networkId + " restart"); + success = false; + } + + // apply internal load balancer rules + if (!_lbMgr.applyLoadBalancersForNetwork(networkId, Scheme.Internal)) { + s_logger.warn("Failed to reapply internal load balancer rules as a part of network id=" + networkId + " restart"); success = false; } @@ -2885,14 +2945,15 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L } // Save usage event - if (ip.getAllocatedToAccountId() != Account.ACCOUNT_ID_SYSTEM) { + if (ip.getAllocatedToAccountId() != null && ip.getAllocatedToAccountId() != Account.ACCOUNT_ID_SYSTEM) { VlanVO vlan = _vlanDao.findById(ip.getVlanId()); String guestType = vlan.getVlanType().toString(); - - UsageEventUtils.publishUsageEvent(EventTypes.EVENT_NET_IP_RELEASE, - ip.getAllocatedToAccountId(), ip.getDataCenterId(), addrId, ip.getAddress().addr(), - ip.isSourceNat(), guestType, ip.getSystem(), ip.getClass().getName(), ip.getUuid()); + if (!isIpDedicated(ip)) { + UsageEventUtils.publishUsageEvent(EventTypes.EVENT_NET_IP_RELEASE, + ip.getAllocatedToAccountId(), ip.getDataCenterId(), addrId, ip.getAddress().addr(), + ip.isSourceNat(), guestType, ip.getSystem(), ip.getClass().getName(), ip.getUuid()); + } } ip = _ipAddressDao.markAsUnavailable(addrId); @@ -3189,12 +3250,22 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L } try { - if (!_lbMgr.revokeLoadBalancersForNetwork(networkId)) { - s_logger.warn("Failed to cleanup lb rules as a part of shutdownNetworkRules"); + if (!_lbMgr.revokeLoadBalancersForNetwork(networkId, Scheme.Public)) { + s_logger.warn("Failed to cleanup public lb rules as a part of shutdownNetworkRules"); success = false; } } catch (ResourceUnavailableException ex) { - s_logger.warn("Failed to cleanup lb rules as a part of shutdownNetworkRules due to ", ex); + s_logger.warn("Failed to cleanup public lb rules as a part of shutdownNetworkRules due to ", ex); + success = false; + } + + try { + if (!_lbMgr.revokeLoadBalancersForNetwork(networkId, Scheme.Internal)) { + s_logger.warn("Failed to cleanup internal lb rules as a part of shutdownNetworkRules"); + success = false; + } + } catch (ResourceUnavailableException ex) { + s_logger.warn("Failed to cleanup public lb rules as a part of shutdownNetworkRules due to ", ex); success = false; } @@ -3600,7 +3671,7 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L } } } else { - NicVO nicVO = _nicDao.findByInstanceIdAndNetworkId(network.getId(), vm.getId()); + NicVO nicVO = _nicDao.findByNtwkIdAndInstanceId(network.getId(), vm.getId()); if (nicVO != null) { nic = _networkModel.getNicProfile(vm, network.getId(), null); } @@ -3702,35 +3773,62 @@ public class NetworkManagerImpl extends ManagerBase implements NetworkManager, L return null; } - protected NetworkElement getElementForServiceInNetwork(Network network, Service service) { + protected List getElementForServiceInNetwork(Network network, Service service) { + List elements = new ArrayList(); List providers = getProvidersForServiceInNetwork(network, service); //Only support one provider now if (providers == null) { s_logger.error("Cannot find " + service.getName() + " provider for network " + network.getId()); return null; } - if (providers.size() != 1) { + if (providers.size() != 1 && service != Service.Lb) { + //support more than one LB providers only s_logger.error("Found " + providers.size() + " " + service.getName() + " providers for network!" + network.getId()); return null; + } + + for (Provider provider : providers) { + NetworkElement element = _networkModel.getElementImplementingProvider(provider.getName()); + s_logger.info("Let " + element.getName() + " handle " + service.getName() + " in network " + network.getId()); + elements.add(element); } - NetworkElement element = _networkModel.getElementImplementingProvider(providers.get(0).getName()); - s_logger.info("Let " + element.getName() + " handle " + service.getName() + " in network " + network.getId()); - return element; + return elements; } @Override public StaticNatServiceProvider getStaticNatProviderForNetwork(Network network) { - NetworkElement element = getElementForServiceInNetwork(network, Service.StaticNat); + //only one provider per Static nat service is supoprted + NetworkElement element = getElementForServiceInNetwork(network, Service.StaticNat).get(0); assert element instanceof StaticNatServiceProvider; return (StaticNatServiceProvider)element; } @Override - public LoadBalancingServiceProvider getLoadBalancingProviderForNetwork(Network network) { - NetworkElement element = getElementForServiceInNetwork(network, Service.Lb); - assert element instanceof LoadBalancingServiceProvider; - return (LoadBalancingServiceProvider)element; + public LoadBalancingServiceProvider getLoadBalancingProviderForNetwork(Network network, Scheme lbScheme) { + List lbElements = getElementForServiceInNetwork(network, Service.Lb); + NetworkElement lbElement = null; + if (lbElements.size() > 1) { + String providerName = null; + //get network offering details + NetworkOffering off = _configMgr.getNetworkOffering(network.getNetworkOfferingId()); + if (lbScheme == Scheme.Public) { + providerName = _ntwkOffDetailsDao.getDetail(off.getId(), NetworkOffering.Detail.PublicLbProvider); + } else { + providerName = _ntwkOffDetailsDao.getDetail(off.getId(), NetworkOffering.Detail.InternalLbProvider); + } + if (providerName == null) { + throw new InvalidParameterValueException("Can't find Lb provider supporting scheme " + lbScheme.toString() + " in network " + network); + } + lbElement = _networkModel.getElementImplementingProvider(providerName); + } else if (lbElements.size() == 1){ + lbElement = lbElements.get(0); + } + + assert lbElement != null; + assert lbElement instanceof LoadBalancingServiceProvider; + return (LoadBalancingServiceProvider)lbElement; } + @Override public boolean isNetworkInlineMode(Network network) { NetworkOfferingVO offering = _networkOfferingDao.findById(network.getNetworkOfferingId()); diff --git a/server/src/com/cloud/network/NetworkModelImpl.java b/server/src/com/cloud/network/NetworkModelImpl.java index c5930d9315c..135fd290535 100755 --- a/server/src/com/cloud/network/NetworkModelImpl.java +++ b/server/src/com/cloud/network/NetworkModelImpl.java @@ -32,6 +32,7 @@ import javax.ejb.Local; import javax.inject.Inject; import javax.naming.ConfigurationException; +import org.apache.cloudstack.lb.dao.ApplicationLoadBalancerRuleDao; import org.apache.log4j.Logger; import org.springframework.stereotype.Component; @@ -84,11 +85,14 @@ import com.cloud.network.rules.FirewallRuleVO; import com.cloud.network.rules.dao.PortForwardingRulesDao; import com.cloud.network.vpc.dao.PrivateIpDao; import com.cloud.offering.NetworkOffering; +import com.cloud.offering.NetworkOffering.Detail; import com.cloud.offerings.NetworkOfferingServiceMapVO; import com.cloud.offerings.NetworkOfferingVO; import com.cloud.offerings.dao.NetworkOfferingDao; +import com.cloud.offerings.dao.NetworkOfferingDetailsDao; import com.cloud.offerings.dao.NetworkOfferingServiceMapDao; import com.cloud.projects.dao.ProjectAccountDao; +import com.cloud.server.ConfigurationServer; import com.cloud.user.Account; import com.cloud.user.AccountVO; import com.cloud.user.DomainManager; @@ -143,6 +147,8 @@ public class NetworkModelImpl extends ManagerBase implements NetworkModel { @Inject PodVlanMapDao _podVlanMapDao; + @Inject + ConfigurationServer _configServer; List _networkElements; public List getNetworkElements() { @@ -179,9 +185,13 @@ public class NetworkModelImpl extends ManagerBase implements NetworkModel { @Inject UserIpv6AddressDao _ipv6Dao; @Inject - NicSecondaryIpDao _nicSecondaryIpDao;; + NicSecondaryIpDao _nicSecondaryIpDao; + @Inject + ApplicationLoadBalancerRuleDao _appLbRuleDao; @Inject private ProjectAccountDao _projectAccountDao; + @Inject + NetworkOfferingDetailsDao _ntwkOffDetailsDao; private final HashMap _systemNetworks = new HashMap(5); static Long _privateOfferingId = null; @@ -600,7 +610,6 @@ public class NetworkModelImpl extends ManagerBase implements NetworkModel { NetworkElement element = getElementImplementingProvider(instance.getProvider()); if (element != null) { Map> elementCapabilities = element.getCapabilities(); - ; if (elementCapabilities != null) { networkCapabilities.put(service, elementCapabilities.get(service)); } @@ -913,7 +922,7 @@ public class NetworkModelImpl extends ManagerBase implements NetworkModel { boolean isUserVmsDefaultNetwork = false; boolean isDomRGuestOrPublicNetwork = false; if (vm != null) { - Nic nic = _nicDao.findByInstanceIdAndNetworkId(networkId, vmId); + Nic nic = _nicDao.findByNtwkIdAndInstanceId(networkId, vmId); if (vm.getType() == Type.User && nic != null && nic.isDefaultNic()) { isUserVmsDefaultNetwork = true; } else if (vm.getType() == Type.DomainRouter && ntwkOff != null && (ntwkOff.getTrafficType() == TrafficType.Public || ntwkOff.getTrafficType() == TrafficType.Guest)) { @@ -921,9 +930,9 @@ public class NetworkModelImpl extends ManagerBase implements NetworkModel { } } if (isUserVmsDefaultNetwork || isDomRGuestOrPublicNetwork) { - return _configMgr.getServiceOfferingNetworkRate(vm.getServiceOfferingId()); + return _configMgr.getServiceOfferingNetworkRate(vm.getServiceOfferingId(), network.getDataCenterId()); } else { - return _configMgr.getNetworkOfferingNetworkRate(ntwkOff.getId()); + return _configMgr.getNetworkOfferingNetworkRate(ntwkOff.getId(), network.getDataCenterId()); } } @@ -1461,10 +1470,8 @@ public class NetworkModelImpl extends ManagerBase implements NetworkModel { throw new UnsupportedServiceException("Service " + service.getName() + " doesn't have capability " + cap.getName() + " for element=" + element.getName() + " implementing Provider=" + provider.getName()); } - - capValue = capValue.toLowerCase(); - - if (!value.contains(capValue)) { + + if (!value.toLowerCase().contains(capValue.toLowerCase())) { throw new UnsupportedServiceException("Service " + service.getName() + " doesn't support value " + capValue + " for capability " + cap.getName() + " for element=" + element.getName() + " implementing Provider=" + provider.getName()); } @@ -1564,8 +1571,8 @@ public class NetworkModelImpl extends ManagerBase implements NetworkModel { } @Override - public String getDefaultNetworkDomain() { - return _networkDomain; + public String getDefaultNetworkDomain(long zoneId) { + return _configServer.getConfigValue(Config.GuestDomainSuffix.key(), Config.ConfigurationParameterScope.zone.toString(), zoneId); } @Override @@ -1660,23 +1667,19 @@ public class NetworkModelImpl extends ManagerBase implements NetworkModel { @Override public Set getAvailableIps(Network network, String requestedIp) { String[] cidr = network.getCidr().split("/"); - List ips = _nicDao.listIpAddressInNetwork(network.getId()); - List secondaryIps = _nicSecondaryIpDao.listSecondaryIpAddressInNetwork(network.getId()); - ips.addAll(secondaryIps); - Set allPossibleIps = NetUtils.getAllIpsFromCidr(cidr[0], Integer.parseInt(cidr[1])); + List ips = getUsedIpsInNetwork(network); Set usedIps = new TreeSet(); - + for (String ip : ips) { if (requestedIp != null && requestedIp.equals(ip)) { s_logger.warn("Requested ip address " + requestedIp + " is already in use in network" + network); return null; } - + usedIps.add(NetUtils.ip2Long(ip)); } - if (usedIps.size() != 0) { - allPossibleIps.removeAll(usedIps); - } + + Set allPossibleIps = NetUtils.getAllIpsFromCidr(cidr[0], Integer.parseInt(cidr[1]), usedIps); String gateway = network.getGateway(); if ((gateway != null) && (allPossibleIps.contains(NetUtils.ip2Long(gateway)))) @@ -1684,6 +1687,19 @@ public class NetworkModelImpl extends ManagerBase implements NetworkModel { return allPossibleIps; } + + @Override + public List getUsedIpsInNetwork(Network network) { + //Get all ips used by vms nics + List ips = _nicDao.listIpAddressInNetwork(network.getId()); + //Get all secondary ips for nics + List secondaryIps = _nicSecondaryIpDao.listSecondaryIpAddressInNetwork(network.getId()); + ips.addAll(secondaryIps); + //Get ips used by load balancers + List lbIps = _appLbRuleDao.listLbIpsBySourceIpNetworkId(network.getId()); + ips.addAll(lbIps); + return ips; + } @Override public String getDomainNetworkDomain(long domainId, long zoneId) { @@ -1791,7 +1807,7 @@ public class NetworkModelImpl extends ManagerBase implements NetworkModel { if (broadcastUri != null) { nic = _nicDao.findByNetworkIdInstanceIdAndBroadcastUri(networkId, vm.getId(), broadcastUri); } else { - nic = _nicDao.findByInstanceIdAndNetworkId(networkId, vm.getId()); + nic = _nicDao.findByNtwkIdAndInstanceId(networkId, vm.getId()); } if (nic == null) { return null; @@ -2049,4 +2065,26 @@ public class NetworkModelImpl extends ManagerBase implements NetworkModel { } return null; } + + + @Override + public IpAddress getPublicIpAddress(String ipAddress, long zoneId) { + List networks = _networksDao.listByZoneAndTrafficType(zoneId, TrafficType.Public); + if (networks.isEmpty() || networks.size() > 1) { + throw new CloudRuntimeException("Can't find public network in the zone specified"); + } + + return _ipAddressDao.findByIpAndSourceNetworkId(networks.get(0).getId(), ipAddress); + } + + @Override + public Map getNtwkOffDetails(long offId) { + return _ntwkOffDetailsDao.getNtwkOffDetails(offId); + } + + + @Override + public Networks.IsolationType[] listNetworkIsolationMethods() { + return Networks.IsolationType.values(); + } } diff --git a/server/src/com/cloud/network/NetworkServiceImpl.java b/server/src/com/cloud/network/NetworkServiceImpl.java index 594ff7ee95c..14b94a4f0eb 100755 --- a/server/src/com/cloud/network/NetworkServiceImpl.java +++ b/server/src/com/cloud/network/NetworkServiceImpl.java @@ -5,7 +5,7 @@ // to you under the Apache License, Version 2.0 (the // "License"); you may not use this file except in compliance // with the License. You may obtain a copy of the License at -// +// // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, @@ -16,13 +16,56 @@ // under the License. package com.cloud.network; +import java.net.Inet6Address; +import java.net.InetAddress; +import java.net.UnknownHostException; +import java.security.InvalidParameterException; +import java.sql.PreparedStatement; +import java.sql.ResultSet; +import java.sql.SQLException; +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.TreeSet; +import java.util.UUID; + +import javax.ejb.Local; +import javax.inject.Inject; +import javax.naming.ConfigurationException; + +import org.apache.cloudstack.acl.ControlledEntity.ACLType; +import org.apache.cloudstack.acl.SecurityChecker; +import org.apache.cloudstack.acl.SecurityChecker.AccessType; +import org.apache.cloudstack.api.command.admin.network.DedicateGuestVlanRangeCmd; +import org.apache.cloudstack.api.command.admin.network.ListDedicatedGuestVlanRangesCmd; +import org.apache.cloudstack.api.command.admin.usage.ListTrafficTypeImplementorsCmd; +import org.apache.cloudstack.api.command.user.network.CreateNetworkCmd; +import org.apache.cloudstack.api.command.user.network.ListNetworksCmd; +import org.apache.cloudstack.api.command.user.network.RestartNetworkCmd; +import org.apache.cloudstack.api.command.user.vm.ListNicsCmd; +import org.apache.cloudstack.network.element.InternalLoadBalancerElementService; +import org.apache.log4j.Logger; +import org.springframework.stereotype.Component; + import com.cloud.configuration.Config; import com.cloud.configuration.ConfigurationManager; import com.cloud.configuration.dao.ConfigurationDao; -import com.cloud.dc.*; +import com.cloud.dc.DataCenter; import com.cloud.dc.DataCenter.NetworkType; +import com.cloud.dc.DataCenterVO; +import com.cloud.dc.DataCenterVnetVO; +import com.cloud.dc.Pod; import com.cloud.dc.Vlan.VlanType; -import com.cloud.dc.dao.*; +import com.cloud.dc.VlanVO; +import com.cloud.dc.dao.AccountVlanMapDao; +import com.cloud.dc.dao.DataCenterDao; +import com.cloud.dc.dao.DataCenterVnetDao; +import com.cloud.dc.dao.HostPodDao; +import com.cloud.dc.dao.VlanDao; import com.cloud.deploy.DeployDestination; import com.cloud.domain.Domain; import com.cloud.domain.DomainVO; @@ -32,7 +75,14 @@ import com.cloud.event.EventTypes; import com.cloud.event.UsageEventUtils; import com.cloud.event.dao.EventDao; import com.cloud.event.dao.UsageEventDao; -import com.cloud.exception.*; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientAddressCapacityException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.PermissionDeniedException; +import com.cloud.exception.ResourceAllocationException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.exception.UnsupportedServiceException; import com.cloud.host.dao.HostDao; import com.cloud.network.IpAddress.State; import com.cloud.network.Network.Capability; @@ -44,7 +94,22 @@ import com.cloud.network.Networks.TrafficType; import com.cloud.network.PhysicalNetwork.BroadcastDomainRange; import com.cloud.network.VirtualRouterProvider.VirtualRouterProviderType; import com.cloud.network.addr.PublicIp; -import com.cloud.network.dao.*; +import com.cloud.network.dao.AccountGuestVlanMapDao; +import com.cloud.network.dao.AccountGuestVlanMapVO; +import com.cloud.network.dao.FirewallRulesDao; +import com.cloud.network.dao.IPAddressDao; +import com.cloud.network.dao.IPAddressVO; +import com.cloud.network.dao.NetworkDao; +import com.cloud.network.dao.NetworkDomainDao; +import com.cloud.network.dao.NetworkDomainVO; +import com.cloud.network.dao.NetworkServiceMapDao; +import com.cloud.network.dao.NetworkVO; +import com.cloud.network.dao.PhysicalNetworkDao; +import com.cloud.network.dao.PhysicalNetworkServiceProviderDao; +import com.cloud.network.dao.PhysicalNetworkServiceProviderVO; +import com.cloud.network.dao.PhysicalNetworkTrafficTypeDao; +import com.cloud.network.dao.PhysicalNetworkTrafficTypeVO; +import com.cloud.network.dao.PhysicalNetworkVO; import com.cloud.network.element.NetworkElement; import com.cloud.network.element.VirtualRouterElement; import com.cloud.network.element.VpcVirtualRouterElement; @@ -68,7 +133,14 @@ import com.cloud.projects.ProjectManager; import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.tags.ResourceTagVO; import com.cloud.tags.dao.ResourceTagDao; -import com.cloud.user.*; +import com.cloud.user.Account; +import com.cloud.user.AccountManager; +import com.cloud.user.AccountVO; +import com.cloud.user.DomainManager; +import com.cloud.user.ResourceLimitService; +import com.cloud.user.User; +import com.cloud.user.UserContext; +import com.cloud.user.UserVO; import com.cloud.user.dao.AccountDao; import com.cloud.user.dao.UserDao; import com.cloud.utils.AnnotationHelper; @@ -76,15 +148,36 @@ import com.cloud.utils.Journal; import com.cloud.utils.NumbersUtil; import com.cloud.utils.Pair; import com.cloud.utils.component.ManagerBase; -import com.cloud.utils.db.*; +import com.cloud.utils.db.DB; +import com.cloud.utils.db.Filter; +import com.cloud.utils.db.JoinBuilder; +import com.cloud.utils.db.SearchBuilder; +import com.cloud.utils.db.SearchCriteria; import com.cloud.utils.db.SearchCriteria.Op; +import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; import com.cloud.utils.net.NetUtils; +import com.cloud.vm.Nic; +import com.cloud.vm.NicSecondaryIp; +import com.cloud.vm.NicVO; +import com.cloud.vm.ReservationContext; +import com.cloud.vm.ReservationContextImpl; +import com.cloud.vm.SecondaryStorageVmVO; +import com.cloud.vm.UserVmVO; +import com.cloud.vm.VMInstanceVO; +import com.cloud.vm.VirtualMachine; +import com.cloud.vm.dao.NicDao; +import com.cloud.vm.dao.NicSecondaryIpDao; +import com.cloud.vm.dao.NicSecondaryIpVO; +import com.cloud.vm.dao.UserVmDao; +import com.cloud.vm.dao.VMInstanceDao; import com.cloud.vm.*; import com.cloud.vm.dao.*; import org.apache.cloudstack.acl.ControlledEntity.ACLType; import org.apache.cloudstack.acl.SecurityChecker; import org.apache.cloudstack.acl.SecurityChecker.AccessType; +import org.apache.cloudstack.api.command.admin.network.DedicateGuestVlanRangeCmd; +import org.apache.cloudstack.api.command.admin.network.ListDedicatedGuestVlanRangesCmd; import org.apache.cloudstack.api.command.admin.usage.ListTrafficTypeImplementorsCmd; import org.apache.cloudstack.api.command.user.network.CreateNetworkCmd; import org.apache.cloudstack.api.command.user.network.ListNetworksCmd; @@ -105,6 +198,7 @@ import java.sql.ResultSet; import java.sql.SQLException; import java.util.*; + /** * NetworkServiceImpl implements NetworkService. */ @@ -149,9 +243,9 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { @Inject UsageEventDao _usageEventDao; - + @Inject List _networkGurus; - + @Inject NetworkDomainDao _networkDomainDao; @Inject @@ -159,10 +253,10 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { @Inject FirewallRulesDao _firewallDao; - + @Inject ResourceLimitService _resourceLimitMgr; - + @Inject DomainManager _domainMgr; @Inject @@ -173,7 +267,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { PhysicalNetworkDao _physicalNetworkDao; @Inject PhysicalNetworkServiceProviderDao _pNSPDao; - + @Inject PhysicalNetworkTrafficTypeDao _pNTrafficTypeDao; @@ -201,8 +295,12 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { HostDao _hostDao; @Inject HostPodDao _hostPodDao; + @Inject + InternalLoadBalancerElementService _internalLbElementSvc; @Inject DataCenterVnetDao _datacneter_vnet; + @Inject + AccountGuestVlanMapDao _accountGuestVlanMapDao; int _cidrLimit; boolean _allowSubdomainNetworkAccess; @@ -251,7 +349,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (purposes == null || purposes.isEmpty()) { // since no active rules are there check if any rules are applied on the public IP but are in // revoking state - + purposes = getPublicIpPurposeInRules(ip, true, includingFirewall); if (ip.isOneToOneNat()) { if (purposes == null) { @@ -368,9 +466,9 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } return true; } - - + + private Set getPublicIpPurposeInRules(PublicIp ip, boolean includeRevoked, boolean includingFirewall) { Set result = new HashSet(); @@ -399,15 +497,15 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { return _networksDao.listByZoneAndGuestType(owner.getId(), zoneId, Network.GuestType.Isolated, false); } - + @Override public List getIsolatedNetworksWithSourceNATOwnedByAccountInZone(long zoneId, Account owner) { return _networksDao.listSourceNATEnabledNetworks(owner.getId(), zoneId, Network.GuestType.Isolated); } - - + + @Override @ActionEvent(eventType = EventTypes.EVENT_NET_IP_ASSIGN, eventDescription = "allocating Ip", create = true) @@ -426,17 +524,19 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } // if shared network in the advanced zone, then check the caller against the network for 'AccessType.UseNetwork' - if (isSharedNetworkOfferingWithServices(network.getNetworkOfferingId()) && zone.getNetworkType() == NetworkType.Advanced) { - Account caller = UserContext.current().getCaller(); - long callerUserId = UserContext.current().getCallerUserId(); - _accountMgr.checkAccess(caller, AccessType.UseNetwork, false, network); - if (s_logger.isDebugEnabled()) { - s_logger.debug("Associate IP address called by the user " + callerUserId + " account " + ipOwner.getId()); + if (zone.getNetworkType() == NetworkType.Advanced) { + if (isSharedNetworkOfferingWithServices(network.getNetworkOfferingId())) { + Account caller = UserContext.current().getCaller(); + long callerUserId = UserContext.current().getCallerUserId(); + _accountMgr.checkAccess(caller, AccessType.UseNetwork, false, network); + if (s_logger.isDebugEnabled()) { + s_logger.debug("Associate IP address called by the user " + callerUserId + " account " + ipOwner.getId()); + } + return _networkMgr.allocateIp(ipOwner, false, caller, callerUserId, zone); + } else { + throw new InvalidParameterValueException("Associate IP address can only be called on the shared networks in the advanced zone" + + " with Firewall/Source Nat/Static Nat/Port Forwarding/Load balancing services enabled"); } - return _networkMgr.allocateIp(ipOwner, false, caller, callerUserId, zone); - } else { - throw new InvalidParameterValueException("Associate IP address can only be called on the shared networks in the advanced zone" + - " with Firewall/Source Nat/Static Nat/Port Forwarding/Load balancing services enabled"); } } } @@ -458,7 +558,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { _accountMgr.checkAccess(caller, null, false, ipOwner); long callerUserId = UserContext.current().getCallerUserId(); DataCenter zone = _configMgr.getZone(zoneId); - + return _networkMgr.allocateIp(ipOwner, isSystem, caller, callerUserId, zone); } @@ -490,6 +590,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } + @Override public NicSecondaryIp allocateSecondaryGuestIP (Account ipOwner, long zoneId, Long nicId, Long networkId, String requestedIp) throws InsufficientAddressCapacityException { Long accountId = null; @@ -597,6 +698,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } } + @Override @DB public boolean releaseSecondaryIpFromNic (long ipAddressId) { Account caller = UserContext.current().getCaller(); @@ -758,7 +860,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { public Network getNetwork(long id) { return _networksDao.findById(id); } - + private void checkSharedNetworkCidrOverlap(Long zoneId, long physicalNetworkId, String cidr) { if (zoneId == null || cidr == null) { @@ -809,7 +911,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } } } - + @Override @DB @ActionEvent(eventType = EventTypes.EVENT_NETWORK_CREATE, eventDescription = "creating network") @@ -841,15 +943,12 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (ntwkOff == null || ntwkOff.isSystemOnly()) { InvalidParameterValueException ex = new InvalidParameterValueException("Unable to find network offering by specified id"); if (ntwkOff != null) { - ex.addProxyObject(ntwkOff, networkOfferingId, "networkOfferingId"); + ex.addProxyObject(ntwkOff, networkOfferingId, "networkOfferingId"); // Get the VO object's table name. String tablename = AnnotationHelper.getTableName(ntwkOff); if (tablename != null) { ex.addProxyObject(tablename, networkOfferingId, "networkOfferingId"); - } else { - s_logger.info("\nCould not retrieve table name (annotation) from " + tablename + " VO proxy object\n"); } - throw ex; } throw ex; } @@ -871,12 +970,12 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (zone == null) { throw new InvalidParameterValueException("Specified zone id was not found"); } - + if (Grouping.AllocationState.Disabled == zone.getAllocationState() && !_accountMgr.isRootAdmin(caller.getType())) { // See DataCenterVO.java PermissionDeniedException ex = new PermissionDeniedException("Cannot perform this operation since specified Zone is currently disabled"); ex.addProxyObject(zone, zoneId, "zoneId"); - throw ex; + throw ex; } // Only domain and account ACL types are supported in Acton. @@ -896,7 +995,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } } else if (ntwkOff.getGuestType() == GuestType.Shared) { if (!(aclType == ACLType.Domain || aclType == ACLType.Account)) { - throw new InvalidParameterValueException("AclType should be " + ACLType.Domain + " or " + + throw new InvalidParameterValueException("AclType should be " + ACLType.Domain + " or " + ACLType.Account + " for network of type " + Network.GuestType.Shared); } } @@ -932,7 +1031,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } DomainVO domain = _domainDao.findById(domainId); - if (domain == null) { + if (domain == null) { throw new InvalidParameterValueException("Unable to find domain by specified id"); } _accountMgr.checkAccess(caller, domain); @@ -958,7 +1057,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (startIPv6 != null) { ipv6 = true; } - + if (gateway != null) { try { // getByName on a literal representation will only check validity of the address @@ -975,8 +1074,8 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { throw new InvalidParameterValueException("Gateway parameter is invalid"); } } - - + + String cidr = null; if (ipv4) { // if end ip is not specified, default it to startIp @@ -1009,18 +1108,18 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } } - + if (ipv6) { if (endIPv6 == null) { endIPv6 = startIPv6; } _networkModel.checkIp6Parameters(startIPv6, endIPv6, ip6Gateway, ip6Cidr); - + if (zone.getNetworkType() != NetworkType.Advanced || ntwkOff.getGuestType() != Network.GuestType.Shared) { throw new InvalidParameterValueException("Can only support create IPv6 network with advance shared network!"); } } - + // Regular user can create Guest Isolated Source Nat enabled network only if (caller.getType() == Account.ACCOUNT_TYPE_NORMAL && (ntwkOff.getTrafficType() != TrafficType.Guest || ntwkOff.getGuestType() != Network.GuestType.Isolated @@ -1034,7 +1133,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (caller.getType() == Account.ACCOUNT_TYPE_NORMAL && (ntwkOff.getSpecifyVlan() || vlanId != null)) { throw new InvalidParameterValueException("Regular user is not allowed to specify vlanId"); } - + if (ipv4) { // For non-root admins check cidr limit - if it's allowed by global config value if (caller.getType() != Account.ACCOUNT_TYPE_ADMIN && cidr != null) { @@ -1052,14 +1151,18 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (ipv6 && providersConfiguredForExternalNetworking(ntwkProviders)) { throw new InvalidParameterValueException("Cannot support IPv6 on network offering with external devices!"); } - + if (cidr != null && providersConfiguredForExternalNetworking(ntwkProviders)) { if (ntwkOff.getGuestType() == GuestType.Shared && (zone.getNetworkType() == NetworkType.Advanced) && isSharedNetworkOfferingWithServices(networkOfferingId)) { // validate if CIDR specified overlaps with any of the CIDR's allocated for isolated networks and shared networks in the zone checkSharedNetworkCidrOverlap(zoneId, pNtwk.getId(), cidr); } else { - throw new InvalidParameterValueException("Cannot specify CIDR when using network offering with external devices!"); + // if the guest network is for the VPC, if any External Provider are supported in VPC + // cidr will not be null as it is generated from the super cidr of vpc. + // if cidr is not null and network is not part of vpc then throw the exception + if (vpcId == null) + throw new InvalidParameterValueException("Cannot specify CIDR when using network offering with external devices!"); } } @@ -1068,9 +1171,9 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { // 2) GuestType is Isolated, but SourceNat service is disabled boolean createVlan = (startIP != null && endIP != null && zone.getNetworkType() == NetworkType.Advanced && ((ntwkOff.getGuestType() == Network.GuestType.Shared) - || (ntwkOff.getGuestType() == GuestType.Isolated && + || (ntwkOff.getGuestType() == GuestType.Isolated && !areServicesSupportedByNetworkOffering(ntwkOff.getId(), Service.SourceNat)))); - + if (!createVlan) { // Only support advance shared network in IPv6, which means createVlan is a must if (ipv6) { @@ -1088,7 +1191,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } else { s_logger.info("\nCould not retrieve table name (annotation) from " + tablename + " VO proxy object\n"); } - throw ex; + throw ex; } Transaction txn = Transaction.currentTxn(); @@ -1115,15 +1218,19 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (!_configMgr.isOfferingForVpc(ntwkOff)){ throw new InvalidParameterValueException("Network offering can't be used for VPC networks"); } - network = _vpcMgr.createVpcGuestNetwork(networkOfferingId, name, displayText, gateway, cidr, vlanId, + network = _vpcMgr.createVpcGuestNetwork(networkOfferingId, name, displayText, gateway, cidr, vlanId, networkDomain, owner, sharedDomainId, pNtwk, zoneId, aclType, subdomainAccess, vpcId, caller); } else { if (_configMgr.isOfferingForVpc(ntwkOff)){ throw new InvalidParameterValueException("Network offering can be used for VPC networks only"); } - network = _networkMgr.createGuestNetwork(networkOfferingId, name, displayText, gateway, cidr, vlanId, + if (ntwkOff.getInternalLb()) { + throw new InvalidParameterValueException("Internal Lb can be enabled on vpc networks only"); + } + + network = _networkMgr.createGuestNetwork(networkOfferingId, name, displayText, gateway, cidr, vlanId, networkDomain, owner, sharedDomainId, pNtwk, zoneId, aclType, subdomainAccess, vpcId, ip6Gateway, ip6Cidr); - } + } if (caller.getType() == Account.ACCOUNT_TYPE_ADMIN && createVlan) { // Create vlan ip range @@ -1233,13 +1340,13 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } else { permittedAccounts.clear(); Project project = _projectMgr.getProject(projectId); - if (project == null) { + if (project == null) { throw new InvalidParameterValueException("Unable to find project by specified id"); } if (!_projectMgr.canAccessProjectAccount(caller, project.getProjectAccountId())) { // getProject() returns type ProjectVO. InvalidParameterValueException ex = new InvalidParameterValueException("Account " + caller + " cannot access specified project id"); - ex.addProxyObject(project, projectId, "projectId"); + ex.addProxyObject(project, projectId, "projectId"); throw ex; } permittedAccounts.add(project.getProjectAccountId()); @@ -1251,15 +1358,15 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { path = _domainDao.findById(domainId).getPath(); } else { path = _domainDao.findById(caller.getDomainId()).getPath(); - } - + } + if (listAll && domainId == null) { isRecursive = true; } Filter searchFilter = new Filter(NetworkVO.class, "id", false, cmd.getStartIndex(), cmd.getPageSizeVal()); SearchBuilder sb = _networksDao.createSearchBuilder(); - + if (forVpc != null) { if (forVpc) { sb.and("vpc", sb.entity().getVpcId(), Op.NNULL); @@ -1303,8 +1410,8 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { SearchBuilder accountSearch = _accountDao.createSearchBuilder(); accountSearch.and("typeNEQ", accountSearch.entity().getType(), SearchCriteria.Op.NEQ); accountSearch.and("typeEQ", accountSearch.entity().getType(), SearchCriteria.Op.EQ); - - + + sb.join("accountSearch", accountSearch, sb.entity().getAccountId(), accountSearch.entity().getId(), JoinBuilder.JoinType.INNER); List networksToReturn = new ArrayList(); @@ -1313,7 +1420,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (!permittedAccounts.isEmpty()) { //get account level networks networksToReturn.addAll(listAccountSpecificNetworks( - buildNetworkSearchCriteria(sb, keyword, id, isSystem, zoneId, guestIpType, trafficType, + buildNetworkSearchCriteria(sb, keyword, id, isSystem, zoneId, guestIpType, trafficType, physicalNetworkId, aclType, skipProjectNetworks, restartRequired, specifyIpRanges, vpcId, tags, zoneType), searchFilter, permittedAccounts)); //get domain level networks @@ -1327,12 +1434,12 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } else { //add account specific networks networksToReturn.addAll(listAccountSpecificNetworksByDomainPath( - buildNetworkSearchCriteria(sb, keyword, id, isSystem, zoneId, guestIpType, trafficType, + buildNetworkSearchCriteria(sb, keyword, id, isSystem, zoneId, guestIpType, trafficType, physicalNetworkId, aclType, skipProjectNetworks, restartRequired, specifyIpRanges, vpcId, tags, zoneType), searchFilter, path, isRecursive)); //add domain specific networks of domain + parent domains networksToReturn.addAll(listDomainSpecificNetworksByDomainPath( - buildNetworkSearchCriteria(sb, keyword, id, isSystem, zoneId, guestIpType, trafficType, + buildNetworkSearchCriteria(sb, keyword, id, isSystem, zoneId, guestIpType, trafficType, physicalNetworkId, aclType, skipProjectNetworks, restartRequired, specifyIpRanges, vpcId, tags, zoneType), searchFilter, path, isRecursive)); //add networks of subdomains @@ -1372,7 +1479,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { networksToReturn=supportedNetworks; } - + if (canUseForDeploy != null) { List networksForDeploy = new ArrayList(); for (NetworkVO network : networksToReturn) { @@ -1380,16 +1487,16 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { networksForDeploy.add(network); } } - + networksToReturn=networksForDeploy; } - + return networksToReturn; } - - private SearchCriteria buildNetworkSearchCriteria(SearchBuilder sb, String keyword, Long id, + + private SearchCriteria buildNetworkSearchCriteria(SearchBuilder sb, String keyword, Long id, Boolean isSystem, Long zoneId, String guestIpType, String trafficType, Long physicalNetworkId, String aclType, boolean skipProjectNetworks, Boolean restartRequired, Boolean specifyIpRanges, Long vpcId, Map tags, String zoneType) { @@ -1414,9 +1521,9 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } if(zoneType != null) { - sc.setJoinParameters("zoneSearch", "networkType", zoneType); + sc.setJoinParameters("zoneSearch", "networkType", zoneType); } - + if (guestIpType != null) { sc.addAnd("guestType", SearchCriteria.Op.EQ, guestIpType); } @@ -1446,11 +1553,11 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (specifyIpRanges != null) { sc.addAnd("specifyIpRanges", SearchCriteria.Op.EQ, specifyIpRanges); } - + if (vpcId != null) { sc.addAnd("vpcId", SearchCriteria.Op.EQ, vpcId); } - + if (tags != null && !tags.isEmpty()) { int count = 0; sc.setJoinParameters("tagSearch", "resourceType", TaggedResourceType.Network.toString()); @@ -1533,7 +1640,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } List networkIds = new ArrayList(); - + List maps = _networkDomainDao.listDomainNetworkMapByDomain(allowedDomains.toArray()); for (NetworkDomainVO map : maps) { @@ -1562,16 +1669,16 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { NetworkVO network = _networksDao.findById(networkId); if (network == null) { // see NetworkVO.java - + InvalidParameterValueException ex = new InvalidParameterValueException("unable to find network with specified id"); - ex.addProxyObject(network, networkId, "networkId"); + ex.addProxyObject(network, networkId, "networkId"); throw ex; } // don't allow to delete system network if (isNetworkSystem(network)) { InvalidParameterValueException ex = new InvalidParameterValueException("Network with specified id is system and can't be removed"); - ex.addProxyObject(network, network.getId(), "networkId"); + ex.addProxyObject(network, network.getId(), "networkId"); throw ex; } @@ -1586,7 +1693,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { return _networkMgr.destroyNetwork(networkId, context); } - + @Override @ActionEvent(eventType = EventTypes.EVENT_NETWORK_RESTART, eventDescription = "restarting network", async = true) public boolean restartNetwork(RestartNetworkCmd cmd, boolean cleanup) throws ConcurrentOperationException, ResourceUnavailableException, InsufficientCapacityException { @@ -1598,7 +1705,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { // Check if network exists NetworkVO network = _networksDao.findById(networkId); - if (network == null) { + if (network == null) { InvalidParameterValueException ex = new InvalidParameterValueException("Network with specified id doesn't exist"); ex.addProxyObject("networks", networkId, "networkId"); throw ex; @@ -1608,9 +1715,9 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (!(network.getState() == Network.State.Implemented || network.getState() == Network.State.Setup)) { throw new InvalidParameterValueException("Network is not in the right state to be restarted. Correct states are: " + Network.State.Implemented + ", " + Network.State.Setup); } - + if (network.getBroadcastDomainType() == BroadcastDomainType.Lswitch ) { - /** + /** * Unable to restart these networks now. * TODO Restarting a SDN based network requires updating the nics and the configuration * in the controller. This requires a non-trivial rewrite of the restart procedure. @@ -1636,15 +1743,15 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { return _networksDao.getActiveNicsIn(networkId); } - - - + + + protected Map getNetworkOfferingServiceCapabilities(NetworkOffering offering, Service service) { if (!areServicesSupportedByNetworkOffering(offering.getId(), service)) { - // TBD: We should be sending networkOfferingId and not the offering object itself. + // TBD: We should be sending networkOfferingId and not the offering object itself. throw new UnsupportedServiceException("Service " + service.getName() + " is not supported by the network offering " + offering); } @@ -1677,14 +1784,14 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { return serviceCapabilities; } - - + + @Override public IpAddress getIp(long ipAddressId) { return _ipAddressDao.findById(ipAddressId); } - + protected boolean providersConfiguredForExternalNetworking(Collection providers) { for(String providerStr : providers){ Provider provider = Network.Provider.getProvider(providerStr); @@ -1708,32 +1815,32 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { return false; } - + protected boolean areServicesSupportedByNetworkOffering(long networkOfferingId, Service... services) { return (_ntwkOfferingSrvcDao.areServicesSupportedByNetworkOffering(networkOfferingId, services)); } - + protected boolean areServicesSupportedInNetwork(long networkId, Service... services) { return (_ntwkSrvcDao.areServicesSupportedInNetwork(networkId, services)); } - - - - + + + + private boolean checkForNonStoppedVmInNetwork(long networkId) { - List vms = _userVmDao.listByNetworkIdAndStates(networkId, VirtualMachine.State.Starting, + List vms = _userVmDao.listByNetworkIdAndStates(networkId, VirtualMachine.State.Starting, VirtualMachine.State.Running, VirtualMachine.State.Migrating, VirtualMachine.State.Stopping); return vms.isEmpty(); } - + @Override @DB @ActionEvent(eventType = EventTypes.EVENT_NETWORK_UPDATE, eventDescription = "updating network", async = true) - public Network updateGuestNetwork(long networkId, String name, String displayText, Account callerAccount, + public Network updateGuestNetwork(long networkId, String name, String displayText, Account callerAccount, User callerUser, String domainSuffix, Long networkOfferingId, Boolean changeCidr, String guestVmCidr) { boolean restartNetwork = false; @@ -1745,7 +1852,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { ex.addProxyObject("networks", networkId, "networkId"); throw ex; } - + //perform below validation if the network is vpc network if (network.getVpcId() != null && networkOfferingId != null) { Vpc vpc = _vpcMgr.getVpc(network.getVpcId()); @@ -1767,7 +1874,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (network.getTrafficType() != Networks.TrafficType.Guest) { throw new InvalidParameterValueException("Can't allow networks which traffic type is not " + TrafficType.Guest); } - + _accountMgr.checkAccess(callerAccount, null, true, network); if (name != null) { @@ -1791,14 +1898,14 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (networkOfferingId != null) { if (networkOffering == null || networkOffering.isSystemOnly()) { InvalidParameterValueException ex = new InvalidParameterValueException("Unable to find network offering with specified id"); - ex.addProxyObject(networkOffering, networkOfferingId, "networkOfferingId"); + ex.addProxyObject(networkOffering, networkOfferingId, "networkOfferingId"); throw ex; } - + // network offering should be in Enabled state if (networkOffering.getState() != NetworkOffering.State.Enabled) { InvalidParameterValueException ex = new InvalidParameterValueException("Network offering with specified id is not in " + NetworkOffering.State.Enabled + " state, can't upgrade to it"); - ex.addProxyObject(networkOffering, networkOfferingId, "networkOfferingId"); + ex.addProxyObject(networkOffering, networkOfferingId, "networkOfferingId"); throw ex; } //can't update from vpc to non-vpc network offering @@ -1812,7 +1919,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (networkOfferingId != oldNetworkOfferingId) { Collection newProviders = _networkMgr.finalizeServicesAndProvidersForNetwork(networkOffering, network.getPhysicalNetworkId()).values(); Collection oldProviders = _networkMgr.finalizeServicesAndProvidersForNetwork(oldNtwkOff, network.getPhysicalNetworkId()).values(); - + if (providersConfiguredForExternalNetworking(newProviders) != providersConfiguredForExternalNetworking(oldProviders) && !changeCidr) { throw new InvalidParameterValueException("Updating network failed since guest CIDR needs to be changed!"); @@ -1820,7 +1927,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (changeCidr) { if (!checkForNonStoppedVmInNetwork(network.getId())) { InvalidParameterValueException ex = new InvalidParameterValueException("All user vm of network of specified id should be stopped before changing CIDR!"); - ex.addProxyObject(network, networkId, "networkId"); + ex.addProxyObject(network, networkId, "networkId"); throw ex; } } @@ -1953,7 +2060,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (!_networkMgr.shutdownNetworkElementsAndResources(context, true, network)) { s_logger.warn("Failed to shutdown the network elements and resources as a part of network restart: " + network); CloudRuntimeException ex = new CloudRuntimeException("Failed to shutdown the network elements and resources as a part of update to network of specified id"); - ex.addProxyObject(network, networkId, "networkId"); + ex.addProxyObject(network, networkId, "networkId"); throw ex; } } else { @@ -1972,13 +2079,13 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (!_networkMgr.shutdownNetwork(network.getId(), context, true)) { s_logger.warn("Failed to shutdown the network as a part of update to network with specified id"); CloudRuntimeException ex = new CloudRuntimeException("Failed to shutdown the network as a part of update of specified network id"); - ex.addProxyObject(network, networkId, "networkId"); + ex.addProxyObject(network, networkId, "networkId"); throw ex; } } } else { CloudRuntimeException ex = new CloudRuntimeException("Failed to shutdown the network elements and resources as a part of update to network with specified id; network is in wrong state: " + network.getState()); - ex.addProxyObject(network, networkId, "networkId"); + ex.addProxyObject(network, networkId, "networkId"); throw ex; } } @@ -2040,7 +2147,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } catch (Exception ex) { s_logger.warn("Failed to implement network " + network + " elements and resources as a part of network update due to ", ex); CloudRuntimeException e = new CloudRuntimeException("Failed to implement network (with specified id) elements and resources as a part of network update"); - e.addProxyObject(network, networkId, "networkId"); + e.addProxyObject(network, networkId, "networkId"); throw e; } } @@ -2068,14 +2175,11 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } - - protected Set getAvailableIps(Network network, String requestedIp) { String[] cidr = network.getCidr().split("/"); List ips = _nicDao.listIpAddressInNetwork(network.getId()); - Set allPossibleIps = NetUtils.getAllIpsFromCidr(cidr[0], Integer.parseInt(cidr[1])); - Set usedIps = new TreeSet(); - + Set usedIps = new TreeSet(); + for (String ip : ips) { if (requestedIp != null && requestedIp.equals(ip)) { s_logger.warn("Requested ip address " + requestedIp + " is already in use in network" + network); @@ -2084,9 +2188,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { usedIps.add(NetUtils.ip2Long(ip)); } - if (usedIps.size() != 0) { - allPossibleIps.removeAll(usedIps); - } + Set allPossibleIps = NetUtils.getAllIpsFromCidr(cidr[0], Integer.parseInt(cidr[1]), usedIps); String gateway = network.getGateway(); if ((gateway != null) && (allPossibleIps.contains(NetUtils.ip2Long(gateway)))) @@ -2096,7 +2198,6 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } - protected boolean canUpgrade(Network network, long oldNetworkOfferingId, long newNetworkOfferingId) { NetworkOffering oldNetworkOffering = _networkOfferingDao.findByIdIncludingRemoved(oldNetworkOfferingId); NetworkOffering newNetworkOffering = _networkOfferingDao.findById(newNetworkOfferingId); @@ -2162,16 +2263,24 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { return false; } } + + //can't update from internal LB to public LB + if (areServicesSupportedByNetworkOffering(oldNetworkOfferingId, Service.Lb) && areServicesSupportedByNetworkOffering(newNetworkOfferingId, Service.Lb)) { + if (oldNetworkOffering.getPublicLb() != newNetworkOffering.getPublicLb() || oldNetworkOffering.getInternalLb() != newNetworkOffering.getInternalLb()) { + throw new InvalidParameterValueException("Original and new offerings support different types of LB - Internal vs Public," + + " can't upgrade"); + } + } return canIpsUseOffering(publicIps, newNetworkOfferingId); } - + @Override @DB @ActionEvent(eventType = EventTypes.EVENT_PHYSICAL_NETWORK_CREATE, eventDescription = "Creating Physical Network", create = true) - public PhysicalNetwork createPhysicalNetwork(Long zoneId, String vnetRange, String networkSpeed, List + public PhysicalNetwork createPhysicalNetwork(Long zoneId, String vnetRange, String networkSpeed, List isolationMethods, String broadcastDomainRangeStr, Long domainId, List tags, String name) { // Check if zone exists @@ -2276,13 +2385,16 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { // add security group provider to the physical network addDefaultSecurityGroupProviderToPhysicalNetwork(pNetwork.getId()); - + // add VPCVirtualRouter as the defualt network service provider addDefaultVpcVirtualRouterToPhysicalNetwork(pNetwork.getId()); // add baremetal as the defualt network service provider /* addDefaultBaremetalProvidersToPhysicalNetwork(pNetwork.getId()); */ + //Add Internal Load Balancer element as a default network service provider + addDefaultInternalLbProviderToPhysicalNetwork(pNetwork.getId()); + txn.commit(); return pNetwork; } catch (Exception ex) { @@ -2321,7 +2433,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { PhysicalNetworkVO network = _physicalNetworkDao.findById(id); if (network == null) { InvalidParameterValueException ex = new InvalidParameterValueException("Physical Network with specified id doesn't exist in the system"); - ex.addProxyObject(network, id, "physicalNetworkId"); + ex.addProxyObject(network, id, "physicalNetworkId"); throw ex; } @@ -2329,7 +2441,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { DataCenter zone = _dcDao.findById(network.getDataCenterId()); if (zone == null) { InvalidParameterValueException ex = new InvalidParameterValueException("Zone with id=" + network.getDataCenterId() + " doesn't exist in the system"); - ex.addProxyObject(zone, network.getDataCenterId(), "dataCenterId"); + ex.addProxyObject(zone, network.getDataCenterId(), "dataCenterId"); throw ex; } if (newVnetRangeString != null) { @@ -2542,6 +2654,19 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { txn.close(); throw new InvalidParameterValueException("Some of the vnets from this range are allocated, can only remove a range which has no allocated vnets"); } + // If the range is partially dedicated to an account fail the request + List maps = _accountGuestVlanMapDao.listAccountGuestVlanMapsByPhysicalNetwork(network.getId()); + for (AccountGuestVlanMapVO map : maps) { + String[] vlans = map.getGuestVlanRange().split("-"); + Integer dedicatedStartVlan = Integer.parseInt(vlans[0]); + Integer dedicatedEndVlan = Integer.parseInt(vlans[1]); + if ((start >= dedicatedStartVlan && start <= dedicatedEndVlan) || (end >= dedicatedStartVlan && end <= dedicatedEndVlan)) { + txn.close(); + throw new InvalidParameterValueException("Vnet range " + map.getGuestVlanRange() + " is dedicated" + + " to an account. The specified range " + start + "-" + end + " overlaps with the dedicated range " + + " Please release the overlapping dedicated range before deleting the range"); + } + } for (i=0; i= end){ temp = existingRanges.get(i).second(); @@ -2572,6 +2697,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { _physicalNetworkDao.update(network.getId(), network); txn.commit(); _physicalNetworkDao.releaseFromLockTable(network.getId()); + return true; } @@ -2588,7 +2714,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { PhysicalNetworkVO pNetwork = _physicalNetworkDao.findById(physicalNetworkId); if (pNetwork == null) { InvalidParameterValueException ex = new InvalidParameterValueException("Physical Network with specified id doesn't exist in the system"); - ex.addProxyObject(pNetwork, physicalNetworkId, "physicalNetworkId"); + ex.addProxyObject(pNetwork, physicalNetworkId, "physicalNetworkId"); throw ex; } @@ -2615,7 +2741,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { // delete service providers List providers = _pNSPDao.listBy(physicalNetworkId); - + for(PhysicalNetworkServiceProviderVO provider : providers){ try { deleteNetworkServiceProvider(provider.getId()); @@ -2632,7 +2758,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { _pNTrafficTypeDao.deleteTrafficTypes(physicalNetworkId); boolean success = _physicalNetworkDao.remove(physicalNetworkId); - + txn.commit(); return success; @@ -2708,6 +2834,260 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } + @Override + @DB + @ActionEvent(eventType = EventTypes.EVENT_GUEST_VLAN_RANGE_DEDICATE, eventDescription = "dedicating guest vlan range", async = false) + public GuestVlan dedicateGuestVlanRange(DedicateGuestVlanRangeCmd cmd) { + String vlan = cmd.getVlan(); + String accountName = cmd.getAccountName(); + Long domainId = cmd.getDomainId(); + Long physicalNetworkId = cmd.getPhysicalNetworkId(); + Long projectId = cmd.getProjectId(); + + int startVlan, endVlan; + String updatedVlanRange = null; + long guestVlanMapId = 0; + long guestVlanMapAccountId = 0; + + // Verify account is valid + Account vlanOwner = null; + if (projectId != null) { + if (accountName != null) { + throw new InvalidParameterValueException("accountName and projectId are mutually exclusive"); + } + Project project = _projectMgr.getProject(projectId); + if (project == null) { + throw new InvalidParameterValueException("Unable to find project by id " + projectId); + } + vlanOwner = _accountMgr.getAccount(project.getProjectAccountId()); + } + + if ((accountName != null) && (domainId != null)) { + vlanOwner = _accountDao.findActiveAccount(accountName, domainId); + if (vlanOwner == null) { + throw new InvalidParameterValueException("Unable to find account by name " + accountName); + } + } + + // Verify physical network isolation type is VLAN + PhysicalNetworkVO physicalNetwork = _physicalNetworkDao.findById(physicalNetworkId); + if (physicalNetwork == null ) { + throw new InvalidParameterValueException("Unable to find physical network by id " + physicalNetworkId); + } else if (physicalNetwork.getIsolationMethods() == null || !physicalNetwork.getIsolationMethods().contains("VLAN")) { + throw new InvalidParameterValueException("Cannot dedicate guest vlan range. " + + "Physical isolation type of network " + physicalNetworkId + " is not VLAN"); + } + + // Get the start and end vlan + String[] vlanRange = vlan.split("-"); + if (vlanRange.length != 2) { + throw new InvalidParameterValueException("Invalid format for parameter value vlan " + vlan + " .Vlan should be specified as 'startvlan-endvlan'"); + } + + try { + startVlan = Integer.parseInt(vlanRange[0]); + endVlan = Integer.parseInt(vlanRange[1]); + } catch (NumberFormatException e) { + s_logger.warn("Unable to parse guest vlan range:", e); + throw new InvalidParameterValueException("Please provide valid guest vlan range"); + } + + // Verify guest vlan range exists in the system + List > existingRanges = physicalNetwork.getVnet(); + Boolean exists = false; + if (!existingRanges.isEmpty()) { + for (int i=0 ; i < existingRanges.size(); i++){ + int existingStartVlan = existingRanges.get(i).first(); + int existingEndVlan = existingRanges.get(i).second(); + if (startVlan >= existingStartVlan && endVlan <= existingEndVlan) { + exists = true; + break; + } + } + if (!exists) { + throw new InvalidParameterValueException("Unable to find guest vlan by range " + vlan); + } + } + + // Verify guest vlans in the range don't belong to a network of a different account + for (int i = startVlan; i <= endVlan; i++) { + List allocatedVlans = _datacneter_vnet.listAllocatedVnetsInRange(physicalNetwork.getDataCenterId(), physicalNetwork.getId(), startVlan, endVlan); + if (allocatedVlans != null && !allocatedVlans.isEmpty()){ + for (DataCenterVnetVO allocatedVlan : allocatedVlans) { + if (allocatedVlan.getAccountId() != vlanOwner.getAccountId()) { + throw new InvalidParameterValueException("Guest vlan from this range " + allocatedVlan.getVnet() + " is allocated to a different account." + + " Can only dedicate a range which has no allocated vlans or has vlans allocated to the same account "); + } + } + } + } + + List guestVlanMaps = _accountGuestVlanMapDao.listAccountGuestVlanMapsByPhysicalNetwork(physicalNetworkId); + for (AccountGuestVlanMapVO guestVlanMap : guestVlanMaps) { + List vlanTokens = getVlanFromRange(guestVlanMap.getGuestVlanRange()); + int dedicatedStartVlan = vlanTokens.get(0).intValue(); + int dedicatedEndVlan = vlanTokens.get(1).intValue(); + guestVlanMapId = guestVlanMap.getId(); + guestVlanMapAccountId = guestVlanMap.getAccountId(); + + // Verify if range is already dedicated + if (startVlan >= dedicatedStartVlan && endVlan <= dedicatedEndVlan) { + if (guestVlanMap.getAccountId() != vlanOwner.getAccountId()) { + throw new InvalidParameterValueException("Vlan range is already dedicated to another account. Cannot dedicate guest vlan range " + vlan); + } else { + s_logger.debug("Vlan range " + vlan +" is already dedicated to the specified account" + accountName); + return guestVlanMap; + } + } + // Verify if range overlaps with an existing range + if (startVlan < dedicatedStartVlan & endVlan+1 >= dedicatedStartVlan & endVlan <= dedicatedEndVlan) { // extend to the left + updatedVlanRange = startVlan + "-" + dedicatedEndVlan; + break; + } else if (startVlan >= dedicatedStartVlan & startVlan-1 <= dedicatedEndVlan & endVlan > dedicatedEndVlan) { // extend to right + updatedVlanRange = dedicatedStartVlan + "-" + endVlan; + break; + } else if (startVlan < dedicatedStartVlan & endVlan > dedicatedEndVlan){ // extend to the left and right + updatedVlanRange = startVlan + "-" + endVlan; + break; + } + } + + AccountGuestVlanMapVO accountGuestVlanMapVO; + if (updatedVlanRange != null) { + if (guestVlanMapAccountId != vlanOwner.getAccountId()) { + throw new InvalidParameterValueException("Vlan range is partially dedicated to another account. Cannot dedicate guest vlan range " + vlan); + } + accountGuestVlanMapVO = _accountGuestVlanMapDao.findById(guestVlanMapId); + accountGuestVlanMapVO.setGuestVlanRange(updatedVlanRange); + _accountGuestVlanMapDao.update(guestVlanMapId, accountGuestVlanMapVO); + } else { + Transaction txn = Transaction.currentTxn(); + accountGuestVlanMapVO = new AccountGuestVlanMapVO(vlanOwner.getAccountId(), physicalNetworkId); + accountGuestVlanMapVO.setGuestVlanRange(startVlan + "-" + endVlan); + _accountGuestVlanMapDao.persist(accountGuestVlanMapVO); + txn.commit(); + } + // For every guest vlan set the corresponding account guest vlan map id + for (int i = startVlan; i <= endVlan; i++) { + List dataCenterVnet = _datacneter_vnet.findVnet(physicalNetwork.getDataCenterId(),((Integer)i).toString()); + dataCenterVnet.get(0).setAccountGuestVlanMapId(accountGuestVlanMapVO.getId()); + _datacneter_vnet.update(dataCenterVnet.get(0).getId(), dataCenterVnet.get(0)); + } + return accountGuestVlanMapVO; + } + + private List getVlanFromRange(String vlanRange) { + // Get the start and end vlan + String[] vlanTokens = vlanRange.split("-"); + List tokens = new ArrayList(); + try { + int startVlan = Integer.parseInt(vlanTokens[0]); + int endVlan = Integer.parseInt(vlanTokens[1]); + tokens.add(startVlan); + tokens.add(endVlan); + } catch (NumberFormatException e) { + s_logger.warn("Unable to parse guest vlan range:", e); + throw new InvalidParameterValueException("Please provide valid guest vlan range"); + } + return tokens; + } + + @Override + public Pair, Integer> listDedicatedGuestVlanRanges(ListDedicatedGuestVlanRangesCmd cmd) { + Long id = cmd.getId(); + String accountName = cmd.getAccountName(); + Long domainId = cmd.getDomainId(); + Long projectId = cmd.getProjectId(); + String guestVlanRange = cmd.getGuestVlanRange(); + Long physicalNetworkId = cmd.getPhysicalNetworkId(); + Long zoneId = cmd.getZoneId(); + + Long accountId = null; + if (accountName != null && domainId != null) { + if (projectId != null) { + throw new InvalidParameterValueException("Account and projectId can't be specified together"); + } + Account account = _accountDao.findActiveAccount(accountName, domainId); + if (account == null) { + InvalidParameterValueException ex = new InvalidParameterValueException("Unable to find account " + accountName); + ex.addProxyObject("domain", domainId, "domainId"); + throw ex; + } else { + accountId = account.getId(); + } + } + + // set project information + if (projectId != null) { + Project project = _projectMgr.getProject(projectId); + if (project == null) { + InvalidParameterValueException ex = new InvalidParameterValueException("Unable to find project by id " + projectId); + ex.addProxyObject(project, projectId, "projectId"); + throw ex; + } + accountId = project.getProjectAccountId(); + } + + + SearchBuilder sb = _accountGuestVlanMapDao.createSearchBuilder(); + sb.and("id", sb.entity().getId(), SearchCriteria.Op.EQ); + sb.and("accountId", sb.entity().getAccountId(), SearchCriteria.Op.EQ); + sb.and("guestVlanRange", sb.entity().getGuestVlanRange(), SearchCriteria.Op.EQ); + sb.and("physicalNetworkId", sb.entity().getPhysicalNetworkId(), SearchCriteria.Op.EQ); + + if (zoneId != null) { + SearchBuilder physicalnetworkSearch = _physicalNetworkDao.createSearchBuilder(); + physicalnetworkSearch.and("zoneId", physicalnetworkSearch.entity().getDataCenterId(), SearchCriteria.Op.EQ); + sb.join("physicalnetworkSearch", physicalnetworkSearch, sb.entity().getPhysicalNetworkId(), physicalnetworkSearch.entity().getId(), JoinBuilder.JoinType.INNER); + } + + SearchCriteria sc = sb.create(); + if (id != null) { + sc.setParameters("id", id); + } + + if (accountId != null) { + sc.setParameters("accountId", accountId); + } + + if (guestVlanRange != null) { + sc.setParameters("guestVlanRange", guestVlanRange); + } + + if (physicalNetworkId != null) { + sc.setParameters("physicalNetworkId", physicalNetworkId); + } + + if (zoneId != null) { + sc.setJoinParameters("physicalnetworkSearch", "zoneId", zoneId); + } + + Filter searchFilter = new Filter(AccountGuestVlanMapVO.class, "id", true, cmd.getStartIndex(), cmd.getPageSizeVal()); + Pair, Integer> result = _accountGuestVlanMapDao.searchAndCount(sc, searchFilter); + return new Pair, Integer>(result.first(), result.second()); + } + + @Override + @ActionEvent(eventType = EventTypes.EVENT_DEDICATED_GUEST_VLAN_RANGE_RELEASE, eventDescription = "releasing" + + " dedicated guest vlan range", async = true) + @DB + public boolean releaseDedicatedGuestVlanRange(Long dedicatedGuestVlanRangeId) { + // Verify dedicated range exists + AccountGuestVlanMapVO dedicatedGuestVlan = _accountGuestVlanMapDao.findById(dedicatedGuestVlanRangeId); + if (dedicatedGuestVlan == null) { + throw new InvalidParameterValueException("Dedicated guest vlan with specified" + + " id doesn't exist in the system"); + } + + // Remove dedication for the guest vlan + _datacneter_vnet.releaseDedicatedGuestVlans(dedicatedGuestVlan.getId()); + if (_accountGuestVlanMapDao.remove(dedicatedGuestVlanRangeId)) { + return true; + } else { + return false; + } + } + @Override public List listNetworkServices(String providerName) { @@ -2730,7 +3110,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } } - + @Override @DB @ActionEvent(eventType = EventTypes.EVENT_SERVICE_PROVIDER_CREATE, eventDescription = "Creating Physical Network ServiceProvider", create = true) @@ -2749,7 +3129,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { PhysicalNetworkVO destNetwork = _physicalNetworkDao.findById(destinationPhysicalNetworkId); if (destNetwork == null) { InvalidParameterValueException ex = new InvalidParameterValueException("Destination Physical Network with specified id doesn't exist in the system"); - ex.addProxyObject(destNetwork, destinationPhysicalNetworkId, "destinationPhysicalNetworkId"); + ex.addProxyObject(destNetwork, destinationPhysicalNetworkId, "destinationPhysicalNetworkId"); throw ex; } } @@ -2991,7 +3371,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } else { pNtwks = _physicalNetworkDao.listByZone(zoneId); } - + if (pNtwks.isEmpty()) { throw new InvalidParameterValueException("Unable to find physical network in zone id=" + zoneId); } @@ -3018,8 +3398,8 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } } - - + + @Override @DB @ActionEvent(eventType = EventTypes.EVENT_TRAFFIC_TYPE_CREATE, eventDescription = "Creating Physical Network TrafficType", create = true) @@ -3184,7 +3564,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { return new Pair, Integer>(result.first(), result.second()); } - + @@ -3211,48 +3591,66 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { if (networkElement == null) { throw new CloudRuntimeException("Unable to find the Network Element implementing the VirtualRouter Provider"); } - + VirtualRouterElement element = (VirtualRouterElement)networkElement; element.addElement(nsp.getId(), VirtualRouterProviderType.VirtualRouter); return nsp; } - + protected PhysicalNetworkServiceProvider addDefaultVpcVirtualRouterToPhysicalNetwork(long physicalNetworkId) { - PhysicalNetworkServiceProvider nsp = addProviderToPhysicalNetwork(physicalNetworkId, + PhysicalNetworkServiceProvider nsp = addProviderToPhysicalNetwork(physicalNetworkId, Network.Provider.VPCVirtualRouter.getName(), null, null); - + NetworkElement networkElement = _networkModel.getElementImplementingProvider(Network.Provider.VPCVirtualRouter.getName()); if (networkElement == null) { throw new CloudRuntimeException("Unable to find the Network Element implementing the VPCVirtualRouter Provider"); } - + VpcVirtualRouterElement element = (VpcVirtualRouterElement)networkElement; element.addElement(nsp.getId(), VirtualRouterProviderType.VPCVirtualRouter); return nsp; } + + + protected PhysicalNetworkServiceProvider addDefaultInternalLbProviderToPhysicalNetwork(long physicalNetworkId) { + + PhysicalNetworkServiceProvider nsp = addProviderToPhysicalNetwork(physicalNetworkId, + Network.Provider.InternalLbVm.getName(), null, null); + + NetworkElement networkElement = _networkModel.getElementImplementingProvider(Network.Provider.InternalLbVm.getName()); + if (networkElement == null) { + throw new CloudRuntimeException("Unable to find the Network Element implementing the " + Network.Provider.InternalLbVm.getName() + " Provider"); + } + + _internalLbElementSvc.addInternalLoadBalancerElement(nsp.getId()); + + return nsp; + } protected PhysicalNetworkServiceProvider addDefaultSecurityGroupProviderToPhysicalNetwork(long physicalNetworkId) { - PhysicalNetworkServiceProvider nsp = addProviderToPhysicalNetwork(physicalNetworkId, + PhysicalNetworkServiceProvider nsp = addProviderToPhysicalNetwork(physicalNetworkId, Network.Provider.SecurityGroupProvider.getName(), null, null); return nsp; } + + private PhysicalNetworkServiceProvider addDefaultBaremetalProvidersToPhysicalNetwork(long physicalNetworkId) { PhysicalNetworkVO pvo = _physicalNetworkDao.findById(physicalNetworkId); DataCenterVO dvo = _dcDao.findById(pvo.getDataCenterId()); if (dvo.getNetworkType() == NetworkType.Basic) { - + // Baremetal is currently disabled /* addProviderToPhysicalNetwork(physicalNetworkId, "BaremetalDhcpProvider", null, null); addProviderToPhysicalNetwork(physicalNetworkId, "BaremetalPxeProvider", null, null); addProviderToPhysicalNetwork(physicalNetworkId, "BaremetaUserdataProvider", null, null); -*/ +*/ } return null; } @@ -3266,13 +3664,13 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } } - - + + private boolean getAllowSubdomainAccessGlobal() { return _allowSubdomainNetworkAccess; } - + @Override public List> listTrafficTypeImplementor(ListTrafficTypeImplementorsCmd cmd) { @@ -3297,7 +3695,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { return results; } - + @Override @ActionEvent(eventType = EventTypes.EVENT_NET_IP_ASSIGN, eventDescription = "associating Ip", async = true) public IpAddress associateIPToNetwork(long ipId, long networkId) throws InsufficientAddressCapacityException, @@ -3313,20 +3711,20 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { " to VPC.Specify vpcId to associate ip address to VPC"); } return _networkMgr.associateIPToGuestNetwork(ipId, networkId, true); - + } - + @Override @DB - public Network createPrivateNetwork(String networkName, String displayText, long physicalNetworkId, - String vlan, String startIp, String endIp, String gateway, String netmask, long networkOwnerId, Long vpcId) + public Network createPrivateNetwork(String networkName, String displayText, long physicalNetworkId, + String vlan, String startIp, String endIp, String gateway, String netmask, long networkOwnerId, Long vpcId, Boolean sourceNat) throws ResourceAllocationException, ConcurrentOperationException, InsufficientCapacityException { - + Account owner = _accountMgr.getAccount(networkOwnerId); - + // Get system network offeirng NetworkOfferingVO ntwkOff = findSystemNetworkOffering(NetworkOffering.SystemPrivateGatewayNetworkOffering); - + // Validate physical network PhysicalNetwork pNtwk = _physicalNetworkDao.findById(physicalNetworkId); if (pNtwk == null) { @@ -3335,7 +3733,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { ex.addProxyObject("physical_network", physicalNetworkId, "physicalNetworkId"); throw ex; } - + // VALIDATE IP INFO // if end ip is not specified, default it to startIp if (!NetUtils.isValidIp(startIp)) { @@ -3356,49 +3754,49 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { } cidr = NetUtils.ipAndNetMaskToCidr(gateway, netmask); - - + + Transaction txn = Transaction.currentTxn(); txn.start(); - + //lock datacenter as we need to get mac address seq from there DataCenterVO dc = _dcDao.lockRow(pNtwk.getDataCenterId(), true); - + //check if we need to create guest network Network privateNetwork = _networksDao.getPrivateNetwork(BroadcastDomainType.Vlan.toUri(vlan).toString(), cidr, networkOwnerId, pNtwk.getDataCenterId()); if (privateNetwork == null) { //create Guest network - privateNetwork = _networkMgr.createGuestNetwork(ntwkOff.getId(), networkName, displayText, gateway, cidr, vlan, + privateNetwork = _networkMgr.createGuestNetwork(ntwkOff.getId(), networkName, displayText, gateway, cidr, vlan, null, owner, null, pNtwk, pNtwk.getDataCenterId(), ACLType.Account, null, null, null, null); s_logger.debug("Created private network " + privateNetwork); } else { s_logger.debug("Private network already exists: " + privateNetwork); } - + //add entry to private_ip_address table PrivateIpVO privateIp = _privateIpDao.findByIpAndSourceNetworkId(privateNetwork.getId(), startIp); if (privateIp != null) { throw new InvalidParameterValueException("Private ip address " + startIp + " already used for private gateway" + " in zone " + _configMgr.getZone(pNtwk.getDataCenterId()).getName()); } - + Long mac = dc.getMacAddress(); Long nextMac = mac + 1; dc.setMacAddress(nextMac); - privateIp = new PrivateIpVO(startIp, privateNetwork.getId(), nextMac, vpcId); + privateIp = new PrivateIpVO(startIp, privateNetwork.getId(), nextMac, vpcId, sourceNat); _privateIpDao.persist(privateIp); - + _dcDao.update(dc.getId(), dc); - + txn.commit(); s_logger.debug("Private network " + privateNetwork + " is created"); return privateNetwork; } - + private NetworkOfferingVO findSystemNetworkOffering(String offeringName) { List allOfferings = _networkOfferingDao.listSystemNetworkOfferings(); for (NetworkOfferingVO offer: allOfferings){ diff --git a/server/src/com/cloud/network/dao/LoadBalancerDaoImpl.java b/server/src/com/cloud/network/dao/LoadBalancerDaoImpl.java deleted file mode 100644 index f211a7f1a79..00000000000 --- a/server/src/com/cloud/network/dao/LoadBalancerDaoImpl.java +++ /dev/null @@ -1,137 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.network.dao; - -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.util.ArrayList; -import java.util.List; - -import javax.ejb.Local; -import javax.inject.Inject; - -import org.apache.log4j.Logger; -import org.springframework.stereotype.Component; - -import com.cloud.network.rules.FirewallRule.State; -import com.cloud.utils.db.GenericDaoBase; -import com.cloud.utils.db.SearchBuilder; -import com.cloud.utils.db.SearchCriteria; -import com.cloud.utils.db.SearchCriteria.Op; -import com.cloud.utils.db.Transaction; - -@Component -@Local(value = { LoadBalancerDao.class }) -public class LoadBalancerDaoImpl extends GenericDaoBase implements LoadBalancerDao { - private static final Logger s_logger = Logger.getLogger(LoadBalancerDaoImpl.class); - private static final String LIST_INSTANCES_BY_LOAD_BALANCER = "SELECT vm.id " + - " FROM vm_instance vm, load_balancer lb, ip_forwarding fwd, user_ip_address ip " + - " WHERE lb.id = ? AND " + - " fwd.group_id = lb.id AND " + - " fwd.forwarding = 0 AND " + - " fwd.private_ip_address = vm.private_ip_address AND " + - " lb.ip_address = ip.public_ip_address AND " + - " ip.data_center_id = vm.data_center_id "; - private final SearchBuilder ListByIp; - private final SearchBuilder IpAndPublicPortSearch; - private final SearchBuilder AccountAndNameSearch; - protected final SearchBuilder TransitionStateSearch; - - @Inject protected FirewallRulesCidrsDao _portForwardingRulesCidrsDao; - - protected LoadBalancerDaoImpl() { - ListByIp = createSearchBuilder(); - ListByIp.and("ipAddressId", ListByIp.entity().getSourceIpAddressId(), SearchCriteria.Op.EQ); - ListByIp.and("networkId", ListByIp.entity().getNetworkId(), SearchCriteria.Op.EQ); - ListByIp.done(); - - IpAndPublicPortSearch = createSearchBuilder(); - IpAndPublicPortSearch.and("ipAddressId", IpAndPublicPortSearch.entity().getSourceIpAddressId(), SearchCriteria.Op.EQ); - IpAndPublicPortSearch.and("publicPort", IpAndPublicPortSearch.entity().getSourcePortStart(), SearchCriteria.Op.EQ); - IpAndPublicPortSearch.done(); - - AccountAndNameSearch = createSearchBuilder(); - AccountAndNameSearch.and("accountId", AccountAndNameSearch.entity().getAccountId(), SearchCriteria.Op.EQ); - AccountAndNameSearch.and("name", AccountAndNameSearch.entity().getName(), SearchCriteria.Op.EQ); - AccountAndNameSearch.done(); - - TransitionStateSearch = createSearchBuilder(); - TransitionStateSearch.and("networkId", TransitionStateSearch.entity().getNetworkId(), Op.EQ); - TransitionStateSearch.and("state", TransitionStateSearch.entity().getState(), Op.IN); - TransitionStateSearch.done(); - } - - @Override - public List listInstancesByLoadBalancer(long loadBalancerId) { - Transaction txn = Transaction.currentTxn(); - String sql = LIST_INSTANCES_BY_LOAD_BALANCER; - PreparedStatement pstmt = null; - List instanceList = new ArrayList(); - try { - pstmt = txn.prepareAutoCloseStatement(sql); - pstmt.setLong(1, loadBalancerId); - - ResultSet rs = pstmt.executeQuery(); - while (rs.next()) { - Long vmId = rs.getLong(1); - instanceList.add(vmId); - } - } catch (Exception ex) { - s_logger.error("error getting recent usage network stats", ex); - } - return instanceList; - } - - @Override - public List listByIpAddress(long ipAddressId) { - SearchCriteria sc = ListByIp.create(); - sc.setParameters("ipAddressId", ipAddressId); - return listBy(sc); - } - - @Override - public List listByNetworkId(long networkId) { - SearchCriteria sc = ListByIp.create(); - sc.setParameters("networkId", networkId); - return listBy(sc); - } - - @Override - public LoadBalancerVO findByIpAddressAndPublicPort(long ipAddressId, String publicPort) { - SearchCriteria sc = IpAndPublicPortSearch.create(); - sc.setParameters("ipAddressId", ipAddressId); - sc.setParameters("publicPort", publicPort); - return findOneBy(sc); - } - - @Override - public LoadBalancerVO findByAccountAndName(Long accountId, String name) { - SearchCriteria sc = AccountAndNameSearch.create(); - sc.setParameters("accountId", accountId); - sc.setParameters("name", name); - return findOneBy(sc); - } - - @Override - public List listInTransitionStateByNetworkId(long networkId) { - SearchCriteria sc = TransitionStateSearch.create(); - sc.setParameters("networkId", networkId); - sc.setParameters("state", State.Add.toString(), State.Revoke.toString()); - return listBy(sc); - } - -} diff --git a/server/src/com/cloud/network/element/VirtualRouterElement.java b/server/src/com/cloud/network/element/VirtualRouterElement.java index f601f4fa2e4..28473cc7bc2 100755 --- a/server/src/com/cloud/network/element/VirtualRouterElement.java +++ b/server/src/com/cloud/network/element/VirtualRouterElement.java @@ -25,7 +25,6 @@ import java.util.Set; import javax.ejb.Local; import javax.inject.Inject; -import com.cloud.utils.PropertiesUtil; import org.apache.cloudstack.api.command.admin.router.ConfigureVirtualRouterElementCmd; import org.apache.cloudstack.api.command.admin.router.CreateVirtualRouterElementCmd; import org.apache.cloudstack.api.command.admin.router.ListVirtualRouterElementsCmd; @@ -66,6 +65,7 @@ import com.cloud.network.router.VpcVirtualNetworkApplianceManager; import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.LbStickinessMethod; import com.cloud.network.rules.LbStickinessMethod.StickinessMethodType; +import com.cloud.network.rules.LoadBalancerContainer; import com.cloud.network.rules.PortForwardingRule; import com.cloud.network.rules.RulesManager; import com.cloud.network.rules.StaticNat; @@ -242,7 +242,7 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl * number like 12 2) time or tablesize like 12h, 34m, 45k, 54m , here * last character is non-digit but from known characters . */ - private boolean containsOnlyNumbers(String str, String endChar) { + private static boolean containsOnlyNumbers(String str, String endChar) { if (str == null) return false; @@ -271,7 +271,7 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl return true; } - private boolean validateHAProxyLBRule(LoadBalancingRule rule) { + public static boolean validateHAProxyLBRule(LoadBalancingRule rule) { String timeEndChar = "dhms"; for (LbStickinessPolicy stickinessPolicy : rule.getStickinessPolicies()) { @@ -338,7 +338,9 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl @Override public boolean validateLBRule(Network network, LoadBalancingRule rule) { - if (canHandle(network, Service.Lb)) { + List rules = new ArrayList(); + rules.add(rule); + if (canHandle(network, Service.Lb) && canHandleLbRules(rules)) { List routers = _routerDao.listByNetworkAndRole(network.getId(), Role.VIRTUAL_ROUTER); if (routers == null || routers.isEmpty()) { return true; @@ -351,6 +353,10 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl @Override public boolean applyLBRules(Network network, List rules) throws ResourceUnavailableException { if (canHandle(network, Service.Lb)) { + if (!canHandleLbRules(rules)) { + return false; + } + List routers = _routerDao.listByNetworkAndRole(network.getId(), Role.VIRTUAL_ROUTER); if (routers == null || routers.isEmpty()) { s_logger.debug("Virtual router elemnt doesn't need to apply firewall rules on the backend; virtual " + @@ -358,8 +364,8 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl return true; } - if (!_routerMgr.applyFirewallRules(network, rules, routers)) { - throw new CloudRuntimeException("Failed to apply firewall rules in network " + network.getId()); + if (!_routerMgr.applyLoadBalancingRules(network, rules, routers)) { + throw new CloudRuntimeException("Failed to apply load balancing rules in network " + network.getId()); } else { return true; } @@ -452,7 +458,7 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl return capabilities; } - private static String getHAProxyStickinessCapability() { + public static String getHAProxyStickinessCapability() { LbStickinessMethod method; List methodList = new ArrayList(1); @@ -557,8 +563,8 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl lbCapabilities.put(Capability.SupportedLBAlgorithms, "roundrobin,leastconn,source"); lbCapabilities.put(Capability.SupportedLBIsolation, "dedicated"); lbCapabilities.put(Capability.SupportedProtocols, "tcp, udp"); - lbCapabilities.put(Capability.SupportedStickinessMethods, getHAProxyStickinessCapability()); + lbCapabilities.put(Capability.LbSchemes, LoadBalancerContainer.Scheme.Public.toString()); capabilities.put(Service.Lb, lbCapabilities); @@ -715,8 +721,8 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl @Override public VirtualRouterProvider configure(ConfigureVirtualRouterElementCmd cmd) { VirtualRouterProviderVO element = _vrProviderDao.findById(cmd.getId()); - if (element == null) { - s_logger.debug("Can't find element with network service provider id " + cmd.getId()); + if (element == null || !(element.getType() == VirtualRouterProviderType.VirtualRouter || element.getType() == VirtualRouterProviderType.VPCVirtualRouter)) { + s_logger.debug("Can't find Virtual Router element with network service provider id " + cmd.getId()); return null; } @@ -728,6 +734,10 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl @Override public VirtualRouterProvider addElement(Long nspId, VirtualRouterProviderType providerType) { + if (!(providerType == VirtualRouterProviderType.VirtualRouter || providerType == VirtualRouterProviderType.VPCVirtualRouter)) { + throw new InvalidParameterValueException("Element " + this.getName() + " supports only providerTypes: " + + VirtualRouterProviderType.VirtualRouter.toString() + " and " + VirtualRouterProviderType.VPCVirtualRouter); + } VirtualRouterProviderVO element = _vrProviderDao.findByNspIdAndType(nspId, providerType); if (element != null) { s_logger.debug("There is already a virtual router element with service provider id " + nspId); @@ -801,7 +811,11 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl @Override public VirtualRouterProvider getCreatedElement(long id) { - return _vrProviderDao.findById(id); + VirtualRouterProvider provider = _vrProviderDao.findById(id); + if (!(provider.getType() == VirtualRouterProviderType.VirtualRouter || provider.getType() == VirtualRouterProviderType.VPCVirtualRouter)) { + throw new InvalidParameterValueException("Unable to find provider by id"); + } + return provider; } @Override @@ -911,6 +925,10 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl if (enabled != null) { sc.addAnd(sc.getEntity().isEnabled(), Op.EQ, enabled); } + + //return only VR and VPC VR + sc.addAnd(sc.getEntity().getType(), Op.IN, VirtualRouterProvider.VirtualRouterProviderType.VPCVirtualRouter, VirtualRouterProvider.VirtualRouterProviderType.VirtualRouter); + return sc.list(); } @@ -946,4 +964,20 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl // TODO Auto-generated method stub return null; } + + private boolean canHandleLbRules(List rules) { + Map lbCaps = this.getCapabilities().get(Service.Lb); + if (!lbCaps.isEmpty()) { + String schemeCaps = lbCaps.get(Capability.LbSchemes); + if (schemeCaps != null) { + for (LoadBalancingRule rule : rules) { + if (!schemeCaps.contains(rule.getScheme().toString())) { + s_logger.debug("Scheme " + rules.get(0).getScheme() + " is not supported by the provider " + this.getName()); + return false; + } + } + } + } + return true; + } } diff --git a/server/src/com/cloud/network/firewall/FirewallManagerImpl.java b/server/src/com/cloud/network/firewall/FirewallManagerImpl.java index 4ad8868b86a..def4c1ed06f 100644 --- a/server/src/com/cloud/network/firewall/FirewallManagerImpl.java +++ b/server/src/com/cloud/network/firewall/FirewallManagerImpl.java @@ -27,17 +27,12 @@ import javax.ejb.Local; import javax.inject.Inject; import javax.naming.ConfigurationException; +import org.apache.cloudstack.api.command.user.firewall.ListEgressFirewallRulesCmd; import com.cloud.network.dao.*; import org.apache.cloudstack.api.command.user.firewall.ListFirewallRulesCmd; import org.apache.log4j.Logger; import org.springframework.stereotype.Component; -import com.mysql.jdbc.ConnectionPropertiesImpl; -import org.apache.log4j.Logger; - -import org.apache.cloudstack.api.BaseListCmd; -import org.apache.cloudstack.api.command.user.firewall.ListEgressFirewallRulesCmd; -import org.apache.cloudstack.api.command.user.firewall.ListFirewallRulesCmd; import com.cloud.configuration.Config; import com.cloud.configuration.dao.ConfigurationDao; import com.cloud.domain.dao.DomainDao; @@ -53,7 +48,6 @@ import com.cloud.network.IpAddress; import com.cloud.network.Network; import com.cloud.network.Network.Capability; import com.cloud.network.Network.Service; -import com.cloud.network.Networks.TrafficType; import com.cloud.network.NetworkManager; import com.cloud.network.NetworkModel; import com.cloud.network.NetworkRuleApplier; @@ -61,10 +55,15 @@ import com.cloud.network.element.FirewallServiceProvider; import com.cloud.network.element.NetworkACLServiceProvider; import com.cloud.network.element.PortForwardingServiceProvider; import com.cloud.network.element.StaticNatServiceProvider; -import com.cloud.network.rules.*; +import com.cloud.network.rules.FirewallManager; +import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.FirewallRule.FirewallRuleType; import com.cloud.network.rules.FirewallRule.Purpose; import com.cloud.network.rules.FirewallRule.State; +import com.cloud.network.rules.FirewallRuleVO; +import com.cloud.network.rules.PortForwardingRule; +import com.cloud.network.rules.PortForwardingRuleVO; +import com.cloud.network.rules.StaticNat; import com.cloud.network.rules.dao.PortForwardingRulesDao; import com.cloud.network.vpc.VpcManager; import com.cloud.projects.Project.ListProjectResourcesCriteria; @@ -83,8 +82,8 @@ import com.cloud.utils.db.Filter; import com.cloud.utils.db.JoinBuilder; import com.cloud.utils.db.SearchBuilder; import com.cloud.utils.db.SearchCriteria; -import com.cloud.utils.db.*; import com.cloud.utils.db.SearchCriteria.Op; +import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; import com.cloud.utils.net.NetUtils; import com.cloud.vm.UserVmVO; @@ -438,22 +437,28 @@ public class FirewallManagerImpl extends ManagerBase implements FirewallService, return; } - if (ipAddress!=null){ - if (ipAddress.getAssociatedWithNetworkId() == null) { - throw new InvalidParameterValueException("Unable to create firewall rule ; ip with specified id is not associated with any network"); - } else { - networkId = ipAddress.getAssociatedWithNetworkId(); - } - + if (ipAddress != null){ + if (ipAddress.getAssociatedWithNetworkId() == null) { + throw new InvalidParameterValueException("Unable to create firewall rule ; ip with specified id is not associated with any network"); + } else { + networkId = ipAddress.getAssociatedWithNetworkId(); + } + // Validate ip address _accountMgr.checkAccess(caller, null, true, ipAddress); - + } + + //network id either has to be passed explicitly, or implicitly as a part of ipAddress object + if (networkId == null) { + throw new InvalidParameterValueException("Unable to retrieve network id to validate the rule"); + } + Network network = _networkModel.getNetwork(networkId); - assert network != null : "Can't create port forwarding rule as network associated with public ip address is null?"; + assert network != null : "Can't create rule as network associated with public ip address is null?"; - if (trafficType == FirewallRule.TrafficType.Egress) { - _accountMgr.checkAccess(caller, null, true, network); - } + if (trafficType == FirewallRule.TrafficType.Egress) { + _accountMgr.checkAccess(caller, null, true, network); + } // Verify that the network guru supports the protocol specified Map caps = null; @@ -464,32 +469,32 @@ public class FirewallManagerImpl extends ManagerBase implements FirewallService, } } else if (purpose == Purpose.PortForwarding) { caps = _networkModel.getNetworkServiceCapabilities(network.getId(), Service.PortForwarding); - }else if (purpose == Purpose.Firewall){ - caps = _networkModel.getNetworkServiceCapabilities(network.getId(),Service.Firewall); + } else if (purpose == Purpose.Firewall){ + caps = _networkModel.getNetworkServiceCapabilities(network.getId(),Service.Firewall); } if (caps != null) { - String supportedProtocols; - String supportedTrafficTypes = null; - if (purpose == FirewallRule.Purpose.Firewall) { - supportedTrafficTypes = caps.get(Capability.SupportedTrafficDirection).toLowerCase(); - } + String supportedProtocols; + String supportedTrafficTypes = null; + if (purpose == FirewallRule.Purpose.Firewall) { + supportedTrafficTypes = caps.get(Capability.SupportedTrafficDirection).toLowerCase(); + } - if (purpose == FirewallRule.Purpose.Firewall && trafficType == FirewallRule.TrafficType.Egress) { - supportedProtocols = caps.get(Capability.SupportedEgressProtocols).toLowerCase(); - } else { - supportedProtocols = caps.get(Capability.SupportedProtocols).toLowerCase(); - } + if (purpose == FirewallRule.Purpose.Firewall && trafficType == FirewallRule.TrafficType.Egress) { + supportedProtocols = caps.get(Capability.SupportedEgressProtocols).toLowerCase(); + } else { + supportedProtocols = caps.get(Capability.SupportedProtocols).toLowerCase(); + } if (!supportedProtocols.contains(proto.toLowerCase())) { throw new InvalidParameterValueException("Protocol " + proto + " is not supported in zone " + network.getDataCenterId()); } else if (proto.equalsIgnoreCase(NetUtils.ICMP_PROTO) && purpose != Purpose.Firewall) { throw new InvalidParameterValueException("Protocol " + proto + " is currently supported only for rules with purpose " + Purpose.Firewall); - } else if (purpose == Purpose.Firewall && !supportedTrafficTypes.contains(trafficType.toString().toLowerCase())) { - throw new InvalidParameterValueException("Traffic Type " + trafficType + " is currently supported by Firewall in network " + networkId); - } + } else if (purpose == Purpose.Firewall && !supportedTrafficTypes.contains(trafficType.toString().toLowerCase())) { + throw new InvalidParameterValueException("Traffic Type " + trafficType + " is currently supported by Firewall in network " + networkId); } } + } @Override diff --git a/server/src/com/cloud/network/guru/ExternalGuestNetworkGuru.java b/server/src/com/cloud/network/guru/ExternalGuestNetworkGuru.java index b1606db71b1..fe9e01f558d 100644 --- a/server/src/com/cloud/network/guru/ExternalGuestNetworkGuru.java +++ b/server/src/com/cloud/network/guru/ExternalGuestNetworkGuru.java @@ -118,7 +118,7 @@ public class ExternalGuestNetworkGuru extends GuestNetworkGuru { if (Boolean.parseBoolean(_configDao.getValue(Config.OvsTunnelNetwork.key()))) { return null; } - + if (!_networkModel.networkIsConfiguredForExternalNetworking(config.getDataCenterId(), config.getId())) { return super.implement(config, offering, dest, context); } @@ -145,25 +145,31 @@ public class ExternalGuestNetworkGuru extends GuestNetworkGuru { implemented.setBroadcastUri(config.getBroadcastUri()); } - // Determine the offset from the lowest vlan tag - int offset = getVlanOffset(config.getPhysicalNetworkId(), vlanTag); - // Determine the new gateway and CIDR String[] oldCidr = config.getCidr().split("/"); String oldCidrAddress = oldCidr[0]; - int cidrSize = getGloballyConfiguredCidrSize(); - - // If the offset has more bits than there is room for, return null - long bitsInOffset = 32 - Integer.numberOfLeadingZeros(offset); - if (bitsInOffset > (cidrSize - 8)) { - throw new CloudRuntimeException("The offset " + offset + " needs " + bitsInOffset + " bits, but only have " + (cidrSize - 8) + " bits to work with."); + int cidrSize = Integer.parseInt(oldCidr[1]); + long newCidrAddress = (NetUtils.ip2Long(oldCidrAddress)); + // if the implementing network is for vpc, no need to generate newcidr, use the cidr that came from super cidr + if (config.getVpcId() != null) { + implemented.setGateway(config.getGateway()); + implemented.setCidr(config.getCidr()); + implemented.setState(State.Implemented); + } else { + // Determine the offset from the lowest vlan tag + int offset = getVlanOffset(config.getPhysicalNetworkId(), vlanTag); + cidrSize = getGloballyConfiguredCidrSize(); + // If the offset has more bits than there is room for, return null + long bitsInOffset = 32 - Integer.numberOfLeadingZeros(offset); + if (bitsInOffset > (cidrSize - 8)) { + throw new CloudRuntimeException("The offset " + offset + " needs " + bitsInOffset + " bits, but only have " + (cidrSize - 8) + " bits to work with."); + } + newCidrAddress = (NetUtils.ip2Long(oldCidrAddress) & 0xff000000) | (offset << (32 - cidrSize)); + implemented.setGateway(NetUtils.long2Ip(newCidrAddress + 1)); + implemented.setCidr(NetUtils.long2Ip(newCidrAddress) + "/" + cidrSize); + implemented.setState(State.Implemented); } - long newCidrAddress = (NetUtils.ip2Long(oldCidrAddress) & 0xff000000) | (offset << (32 - cidrSize)); - implemented.setGateway(NetUtils.long2Ip(newCidrAddress + 1)); - implemented.setCidr(NetUtils.long2Ip(newCidrAddress) + "/" + cidrSize); - implemented.setState(State.Implemented); - // Mask the Ipv4 address of all nics that use this network with the new guest VLAN offset List nicsInNetwork = _nicDao.listByNetworkId(config.getId()); for (NicVO nic : nicsInNetwork) { @@ -172,8 +178,8 @@ public class ExternalGuestNetworkGuru extends GuestNetworkGuru { nic.setIp4Address(NetUtils.long2Ip(newCidrAddress | ipMask)); _nicDao.persist(nic); } - } - + } + // Mask the destination address of all port forwarding rules in this network with the new guest VLAN offset List pfRulesInNetwork = _pfRulesDao.listByNetwork(config.getId()); for (PortForwardingRuleVO pfRule : pfRulesInNetwork) { diff --git a/server/src/com/cloud/network/guru/GuestNetworkGuru.java b/server/src/com/cloud/network/guru/GuestNetworkGuru.java index 291e3ccbc77..32ce744979b 100755 --- a/server/src/com/cloud/network/guru/GuestNetworkGuru.java +++ b/server/src/com/cloud/network/guru/GuestNetworkGuru.java @@ -223,48 +223,7 @@ public abstract class GuestNetworkGuru extends AdapterBase implements NetworkGur nic.deallocate(); } } - - public Ip4Address acquireIp4Address(Network network, Ip4Address requestedIp, String reservationId) { - List ips = _nicDao.listIpAddressInNetwork(network.getId()); - String[] cidr = network.getCidr().split("/"); - SortedSet usedIps = new TreeSet(); - - if (requestedIp != null && requestedIp.equals(network.getGateway())) { - s_logger.warn("Requested ip address " + requestedIp + " is used as a gateway address in network " + network); - return null; - } - - for (String ip : ips) { - usedIps.add(NetUtils.ip2Long(ip)); - } - - if (network.getGateway() != null) { - usedIps.add(NetUtils.ip2Long(network.getGateway())); - } - - if (requestedIp != null) { - if (usedIps.contains(requestedIp.toLong())) { - s_logger.warn("Requested ip address " + requestedIp + " is already in used in " + network); - return null; - } - //check that requested ip has the same cidr - boolean isSameCidr = NetUtils.sameSubnetCIDR(requestedIp.ip4(), cidr[0], Integer.parseInt(cidr[1])); - if (!isSameCidr) { - s_logger.warn("Requested ip address " + requestedIp + " doesn't belong to the network " + network + " cidr"); - return null; - } - - return requestedIp; - } - - long ip = NetUtils.getRandomIpFromCidr(cidr[0], Integer.parseInt(cidr[1]), usedIps); - if (ip == -1) { - s_logger.warn("Unable to allocate any more ip address in " + network); - return null; - } - - return new Ip4Address(ip); - } + public int getVlanOffset(long physicalNetworkId, int vlanTag) { PhysicalNetworkVO pNetwork = _physicalNetworkDao.findById(physicalNetworkId); diff --git a/server/src/com/cloud/network/lb/LBHealthCheckManager.java b/server/src/com/cloud/network/lb/LBHealthCheckManager.java index 2e24965aa35..a9969eb7ce1 100644 --- a/server/src/com/cloud/network/lb/LBHealthCheckManager.java +++ b/server/src/com/cloud/network/lb/LBHealthCheckManager.java @@ -16,9 +16,11 @@ // under the License. package com.cloud.network.lb; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; + public interface LBHealthCheckManager { - void updateLBHealthCheck(); + void updateLBHealthCheck(Scheme scheme); } diff --git a/server/src/com/cloud/network/lb/LBHealthCheckManagerImpl.java b/server/src/com/cloud/network/lb/LBHealthCheckManagerImpl.java index 90547328714..62b738bb498 100644 --- a/server/src/com/cloud/network/lb/LBHealthCheckManagerImpl.java +++ b/server/src/com/cloud/network/lb/LBHealthCheckManagerImpl.java @@ -19,7 +19,6 @@ package com.cloud.network.lb; import static java.lang.String.format; import java.util.Map; - import java.util.concurrent.Executors; import java.util.concurrent.ScheduledExecutorService; import java.util.concurrent.TimeUnit; @@ -34,6 +33,7 @@ import org.springframework.stereotype.Component; import com.cloud.configuration.Config; import com.cloud.configuration.dao.ConfigurationDao; import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.utils.NumbersUtil; import com.cloud.utils.component.Manager; import com.cloud.utils.component.ManagerBase; @@ -90,7 +90,8 @@ public class LBHealthCheckManagerImpl extends ManagerBase implements LBHealthChe @Override public void run() { try { - updateLBHealthCheck(); + updateLBHealthCheck(Scheme.Public); + updateLBHealthCheck(Scheme.Internal); } catch (Exception e) { s_logger.error("Exception in LB HealthCheck Update Checker", e); } @@ -98,9 +99,9 @@ public class LBHealthCheckManagerImpl extends ManagerBase implements LBHealthChe } @Override - public void updateLBHealthCheck() { + public void updateLBHealthCheck(Scheme scheme) { try { - _lbService.updateLBHealthChecks(); + _lbService.updateLBHealthChecks(scheme); } catch (ResourceUnavailableException e) { s_logger.debug("Error while updating the LB HealtCheck ", e); } diff --git a/server/src/com/cloud/network/lb/LoadBalancingRulesManager.java b/server/src/com/cloud/network/lb/LoadBalancingRulesManager.java index d98872a0906..a23d96f8aea 100644 --- a/server/src/com/cloud/network/lb/LoadBalancingRulesManager.java +++ b/server/src/com/cloud/network/lb/LoadBalancingRulesManager.java @@ -16,23 +16,24 @@ // under the License. package com.cloud.network.lb; +import java.util.List; + import com.cloud.exception.NetworkRuleConflictException; import com.cloud.exception.ResourceUnavailableException; -import com.cloud.network.Network; import com.cloud.network.lb.LoadBalancingRule.LbDestination; import com.cloud.network.lb.LoadBalancingRule.LbHealthCheckPolicy; import com.cloud.network.lb.LoadBalancingRule.LbStickinessPolicy; -import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.LbStickinessMethod; import com.cloud.network.rules.LoadBalancer; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.user.Account; -import org.apache.cloudstack.api.command.user.loadbalancer.CreateLoadBalancerRuleCmd; - -import java.util.List; +import com.cloud.user.UserContext; public interface LoadBalancingRulesManager extends LoadBalancingRulesService { - LoadBalancer createLoadBalancer(CreateLoadBalancerRuleCmd lb, boolean openFirewall) throws NetworkRuleConflictException; + LoadBalancer createPublicLoadBalancer(String xId, String name, String description, + int srcPort, int destPort, long sourceIpId, String protocol, String algorithm, boolean openFirewall, UserContext caller) + throws NetworkRuleConflictException; boolean removeAllLoadBalanacersForIp(long ipId, Account caller, long callerUserId); boolean removeAllLoadBalanacersForNetwork(long networkId, Account caller, long callerUserId); @@ -47,9 +48,14 @@ public interface LoadBalancingRulesManager extends LoadBalancingRulesService { * @return true if removal is successful */ boolean removeVmFromLoadBalancers(long vmId); - boolean applyRules(Network network, FirewallRule.Purpose purpose, List rules) throws ResourceUnavailableException ; - boolean applyLoadBalancersForNetwork(long networkId) throws ResourceUnavailableException; + boolean applyLoadBalancersForNetwork(long networkId, Scheme scheme) throws ResourceUnavailableException; String getLBCapability(long networkid, String capabilityName); boolean configureLbAutoScaleVmGroup(long vmGroupid, String currentState) throws ResourceUnavailableException; - boolean revokeLoadBalancersForNetwork(long networkId) throws ResourceUnavailableException; + boolean revokeLoadBalancersForNetwork(long networkId, Scheme scheme) throws ResourceUnavailableException; + + boolean validateLbRule(LoadBalancingRule lbRule); + + void removeLBRule(LoadBalancer rule); + + void isLbServiceSupportedInNetwork(long networkId, Scheme scheme); } diff --git a/server/src/com/cloud/network/lb/LoadBalancingRulesManagerImpl.java b/server/src/com/cloud/network/lb/LoadBalancingRulesManagerImpl.java index 7ad1070e1c7..520dd763667 100755 --- a/server/src/com/cloud/network/lb/LoadBalancingRulesManagerImpl.java +++ b/server/src/com/cloud/network/lb/LoadBalancingRulesManagerImpl.java @@ -16,6 +16,34 @@ // under the License. package com.cloud.network.lb; +import java.security.InvalidParameterException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Iterator; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import javax.ejb.Local; +import javax.inject.Inject; + +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.command.user.loadbalancer.CreateLBHealthCheckPolicyCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.CreateLBStickinessPolicyCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.ListLBHealthCheckPoliciesCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.ListLBStickinessPoliciesCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.ListLoadBalancerRuleInstancesCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.ListLoadBalancerRulesCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.UpdateLoadBalancerRuleCmd; +import org.apache.cloudstack.api.response.ServiceResponse; +import org.apache.cloudstack.lb.ApplicationLoadBalancerRuleVO; +import org.apache.cloudstack.lb.dao.ApplicationLoadBalancerRuleDao; +import org.apache.log4j.Logger; +import org.springframework.stereotype.Component; + import com.cloud.agent.api.to.LoadBalancerTO; import com.cloud.configuration.Config; import com.cloud.configuration.ConfigurationManager; @@ -30,21 +58,70 @@ import com.cloud.event.EventTypes; import com.cloud.event.UsageEventUtils; import com.cloud.event.dao.EventDao; import com.cloud.event.dao.UsageEventDao; -import com.cloud.exception.*; -import com.cloud.network.*; +import com.cloud.exception.InsufficientAddressCapacityException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.NetworkRuleConflictException; +import com.cloud.exception.PermissionDeniedException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.ExternalLoadBalancerUsageManager; +import com.cloud.network.IpAddress; +import com.cloud.network.LBHealthCheckPolicyVO; +import com.cloud.network.Network; import com.cloud.network.Network.Capability; import com.cloud.network.Network.Provider; import com.cloud.network.Network.Service; -import com.cloud.network.as.*; +import com.cloud.network.NetworkManager; +import com.cloud.network.NetworkModel; +import com.cloud.network.addr.PublicIp; +import com.cloud.network.as.AutoScalePolicy; +import com.cloud.network.as.AutoScalePolicyConditionMapVO; +import com.cloud.network.as.AutoScaleVmGroup; +import com.cloud.network.as.AutoScaleVmGroupPolicyMapVO; +import com.cloud.network.as.AutoScaleVmGroupVO; +import com.cloud.network.as.AutoScaleVmProfile; import com.cloud.network.as.Condition; -import com.cloud.network.as.dao.*; -import com.cloud.network.dao.*; +import com.cloud.network.as.Counter; +import com.cloud.network.as.dao.AutoScalePolicyConditionMapDao; +import com.cloud.network.as.dao.AutoScalePolicyDao; +import com.cloud.network.as.dao.AutoScaleVmGroupDao; +import com.cloud.network.as.dao.AutoScaleVmGroupPolicyMapDao; +import com.cloud.network.as.dao.AutoScaleVmProfileDao; +import com.cloud.network.as.dao.ConditionDao; +import com.cloud.network.as.dao.CounterDao; +import com.cloud.network.dao.FirewallRulesCidrsDao; +import com.cloud.network.dao.FirewallRulesDao; +import com.cloud.network.dao.IPAddressDao; +import com.cloud.network.dao.IPAddressVO; +import com.cloud.network.dao.LBHealthCheckPolicyDao; +import com.cloud.network.dao.LBStickinessPolicyDao; +import com.cloud.network.dao.LBStickinessPolicyVO; +import com.cloud.network.dao.LoadBalancerDao; +import com.cloud.network.dao.LoadBalancerVMMapDao; +import com.cloud.network.dao.LoadBalancerVMMapVO; +import com.cloud.network.dao.LoadBalancerVO; +import com.cloud.network.dao.NetworkDao; +import com.cloud.network.dao.NetworkServiceMapDao; +import com.cloud.network.dao.NetworkVO; import com.cloud.network.element.LoadBalancingServiceProvider; -import com.cloud.network.lb.LoadBalancingRule.*; -import com.cloud.network.rules.*; +import com.cloud.network.lb.LoadBalancingRule.LbAutoScalePolicy; +import com.cloud.network.lb.LoadBalancingRule.LbAutoScaleVmGroup; +import com.cloud.network.lb.LoadBalancingRule.LbAutoScaleVmProfile; +import com.cloud.network.lb.LoadBalancingRule.LbCondition; +import com.cloud.network.lb.LoadBalancingRule.LbDestination; +import com.cloud.network.lb.LoadBalancingRule.LbHealthCheckPolicy; +import com.cloud.network.lb.LoadBalancingRule.LbStickinessPolicy; +import com.cloud.network.rules.FirewallManager; +import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.FirewallRule.FirewallRuleType; import com.cloud.network.rules.FirewallRule.Purpose; +import com.cloud.network.rules.FirewallRuleVO; +import com.cloud.network.rules.HealthCheckPolicy; +import com.cloud.network.rules.LbStickinessMethod; import com.cloud.network.rules.LbStickinessMethod.LbStickinessMethodParam; +import com.cloud.network.rules.LoadBalancer; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.network.rules.RulesManager; +import com.cloud.network.rules.StickinessPolicy; import com.cloud.network.vpc.VpcManager; import com.cloud.offering.NetworkOffering; import com.cloud.projects.Project.ListProjectResourcesCriteria; @@ -53,15 +130,25 @@ import com.cloud.service.dao.ServiceOfferingDao; import com.cloud.storage.dao.VMTemplateDao; import com.cloud.tags.ResourceTagVO; import com.cloud.tags.dao.ResourceTagDao; -import com.cloud.user.*; +import com.cloud.user.Account; +import com.cloud.user.AccountManager; +import com.cloud.user.DomainService; +import com.cloud.user.User; +import com.cloud.user.UserContext; import com.cloud.user.dao.AccountDao; import com.cloud.user.dao.UserDao; import com.cloud.uservm.UserVm; import com.cloud.utils.Pair; import com.cloud.utils.Ternary; import com.cloud.utils.component.ManagerBase; -import com.cloud.utils.db.*; +import com.cloud.utils.db.DB; +import com.cloud.utils.db.Filter; +import com.cloud.utils.db.JoinBuilder; +import com.cloud.utils.db.SearchBuilder; +import com.cloud.utils.db.SearchCriteria; +import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; +import com.cloud.utils.net.Ip; import com.cloud.utils.net.NetUtils; import com.cloud.vm.Nic; import com.cloud.vm.UserVmVO; @@ -70,21 +157,11 @@ import com.cloud.vm.dao.NicDao; import com.cloud.vm.dao.UserVmDao; import com.google.gson.Gson; import com.google.gson.reflect.TypeToken; -import org.apache.cloudstack.api.ApiConstants; -import org.apache.cloudstack.api.command.user.loadbalancer.*; -import org.apache.cloudstack.api.response.ServiceResponse; -import org.apache.log4j.Logger; -import org.springframework.stereotype.Component; - -import javax.ejb.Local; -import javax.inject.Inject; -import java.security.InvalidParameterException; -import java.util.*; @Component @Local(value = { LoadBalancingRulesManager.class, LoadBalancingRulesService.class }) public class LoadBalancingRulesManagerImpl extends ManagerBase implements LoadBalancingRulesManager, - LoadBalancingRulesService, NetworkRuleApplier { + LoadBalancingRulesService { private static final Logger s_logger = Logger.getLogger(LoadBalancingRulesManagerImpl.class); @Inject @@ -166,6 +243,7 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements UserDao _userDao; @Inject List _lbProviders; + @Inject ApplicationLoadBalancerRuleDao _appLbRuleDao; // Will return a string. For LB Stickiness this will be a json, for // autoscale this will be "," separated values @@ -261,8 +339,9 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements * Regular config like destinations need not be packed for applying * autoscale config as of today. */ - List policyList = getStickinessPolicies(lb.getId()); - LoadBalancingRule rule = new LoadBalancingRule(lb, null, policyList, null); + List policyList = getStickinessPolicies(lb.getId()); + Ip sourceIp = getSourceIp(lb); + LoadBalancingRule rule = new LoadBalancingRule(lb, null, policyList, null, sourceIp); rule.setAutoScaleVmGroup(lbAutoScaleVmGroup); if (!isRollBackAllowedForProvider(lb)) { @@ -273,7 +352,7 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements List rules = Arrays.asList(rule); - if (!_networkMgr.applyRules(rules, FirewallRule.Purpose.LoadBalancing, this, false)) { + if (!applyLbRules(rules, false)) { s_logger.debug("LB rules' autoscale config are not completely applied"); return false; } @@ -281,6 +360,17 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements return true; } + private Ip getSourceIp(LoadBalancer lb) { + Ip sourceIp = null; + if (lb.getScheme() == Scheme.Public) { + sourceIp = _networkModel.getPublicIpAddress(lb.getSourceIpAddressId()).getAddress(); + } else if (lb.getScheme() == Scheme.Internal) { + ApplicationLoadBalancerRuleVO appLbRule = _appLbRuleDao.findById(lb.getId()); + sourceIp = appLbRule.getSourceIp(); + } + return sourceIp; + } + @Override @DB public boolean configureLbAutoScaleVmGroup(long vmGroupid, String currentState) throws ResourceUnavailableException { @@ -454,9 +544,10 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements cmd.getStickinessMethodName(), cmd.getparamList(), cmd.getDescription()); List policyList = new ArrayList(); policyList.add(new LbStickinessPolicy(cmd.getStickinessMethodName(), lbpolicy.getParams())); + Ip sourceIp = getSourceIp(loadBalancer); LoadBalancingRule lbRule = new LoadBalancingRule(loadBalancer, getExistingDestinations(lbpolicy.getId()), - policyList, null); - if (!validateRule(lbRule)) { + policyList, null, sourceIp); + if (!validateLbRule(lbRule)) { throw new InvalidParameterValueException("Failed to create Stickiness policy: Validation Failed " + cmd.getLbRuleId()); } @@ -539,7 +630,8 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements return policy; } - private boolean validateRule(LoadBalancingRule lbRule) { + @Override + public boolean validateLbRule(LoadBalancingRule lbRule) { Network network = _networkDao.findById(lbRule.getNetworkId()); Purpose purpose = lbRule.getPurpose(); if (purpose != Purpose.LoadBalancing) { @@ -748,7 +840,7 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements // by CloudStack and update them in lbvmmap table @DB @Override - public void updateLBHealthChecks() throws ResourceUnavailableException { + public void updateLBHealthChecks(Scheme scheme) throws ResourceUnavailableException { List rules = _lbDao.listAll(); List networks = _networkDao.listAll(); List stateRules = null; @@ -763,7 +855,7 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements * "HealthCheck Manager :: LB Provider in the Network has the Healthcheck policy capability :: " * + provider.get(0).getName()); */ - rules = _lbDao.listByNetworkId(network.getId()); + rules = _lbDao.listByNetworkIdAndScheme(network.getId(), scheme); if (rules != null && rules.size() > 0) { List lbrules = new ArrayList(); for (LoadBalancerVO lb : rules) { @@ -772,7 +864,8 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements // adding to lbrules list only if the LB rule // hashealtChecks if (hcPolicyList != null && hcPolicyList.size() > 0) { - LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, dstList, null, hcPolicyList); + Ip sourceIp = getSourceIp(lb); + LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, dstList, null, hcPolicyList, sourceIp); lbrules.add(loadBalancing); } } @@ -1168,31 +1261,21 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements @Override @ActionEvent(eventType = EventTypes.EVENT_LOAD_BALANCER_CREATE, eventDescription = "creating load balancer") - public LoadBalancer createLoadBalancerRule(CreateLoadBalancerRuleCmd lb, boolean openFirewall) + public LoadBalancer createPublicLoadBalancerRule(String xId, String name, String description, + int srcPortStart, int srcPortEnd, int defPortStart, int defPortEnd, Long ipAddrId, String protocol, String algorithm, long networkId, long lbOwnerId, boolean openFirewall) throws NetworkRuleConflictException, InsufficientAddressCapacityException { - Account lbOwner = _accountMgr.getAccount(lb.getEntityOwnerId()); - - int defPortStart = lb.getDefaultPortStart(); - int defPortEnd = lb.getDefaultPortEnd(); - - if (!NetUtils.isValidPort(defPortEnd)) { - throw new InvalidParameterValueException("privatePort is an invalid value: " + defPortEnd); - } - if (defPortStart > defPortEnd) { - throw new InvalidParameterValueException("private port range is invalid: " + defPortStart + "-" - + defPortEnd); - } - if ((lb.getAlgorithm() == null) || !NetUtils.isValidAlgorithm(lb.getAlgorithm())) { - throw new InvalidParameterValueException("Invalid algorithm: " + lb.getAlgorithm()); + Account lbOwner = _accountMgr.getAccount(lbOwnerId); + + if (srcPortStart != srcPortEnd) { + throw new InvalidParameterValueException("Port ranges are not supported by the load balancer"); } - Long ipAddrId = lb.getSourceIpAddressId(); IPAddressVO ipVO = null; if (ipAddrId != null) { ipVO = _ipAddressDao.findById(ipAddrId); } - Network network = _networkModel.getNetwork(lb.getNetworkId()); + Network network = _networkModel.getNetwork(networkId); // FIXME: breaking the dependency on ELB manager. This breaks // functionality of ELB using virtual router @@ -1204,8 +1287,7 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements IpAddress systemIp = null; NetworkOffering off = _configMgr.getNetworkOffering(network.getNetworkOfferingId()); if (off.getElasticLb() && ipVO == null && network.getVpcId() == null) { - systemIp = _networkMgr.assignSystemIp(lb.getNetworkId(), lbOwner, true, false); - lb.setSourceIpAddressId(systemIp.getId()); + systemIp = _networkMgr.assignSystemIp(networkId, lbOwner, true, false); ipVO = _ipAddressDao.findById(systemIp.getId()); } @@ -1224,11 +1306,11 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements && ipVO.getVpcId().longValue() == network.getVpcId(); if (assignToVpcNtwk) { // set networkId just for verification purposes - _networkModel.checkIpForService(ipVO, Service.Lb, lb.getNetworkId()); + _networkModel.checkIpForService(ipVO, Service.Lb, networkId); - s_logger.debug("The ip is not associated with the VPC network id=" + lb.getNetworkId() + s_logger.debug("The ip is not associated with the VPC network id=" + networkId + " so assigning"); - ipVO = _networkMgr.associateIPToGuestNetwork(ipAddrId, lb.getNetworkId(), false); + ipVO = _networkMgr.associateIPToGuestNetwork(ipAddrId, networkId, false); performedIpAssoc = true; } } else { @@ -1240,10 +1322,7 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements + network); } - if (lb.getSourceIpAddressId() == null) { - throw new CloudRuntimeException("No ip address is defined to assign the LB to"); - } - result = createLoadBalancer(lb, openFirewall); + result = createPublicLoadBalancer(xId, name, description, srcPortStart, defPortStart, ipVO.getId(), protocol, algorithm, openFirewall, UserContext.current()); } catch (Exception ex) { s_logger.warn("Failed to create load balancer due to ", ex); if (ex instanceof NetworkRuleConflictException) { @@ -1258,27 +1337,31 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements // release ip address if ipassoc was perfored if (performedIpAssoc) { ipVO = _ipAddressDao.findById(ipVO.getId()); - _vpcMgr.unassignIPFromVpcNetwork(ipVO.getId(), lb.getNetworkId()); + _vpcMgr.unassignIPFromVpcNetwork(ipVO.getId(), networkId); } } } if (result == null) { - throw new CloudRuntimeException("Failed to create load balancer rule: " + lb.getName()); + throw new CloudRuntimeException("Failed to create load balancer rule: " + name); } return result; } - @Override @DB - public LoadBalancer createLoadBalancer(CreateLoadBalancerRuleCmd lb, boolean openFirewall) + @Override + public LoadBalancer createPublicLoadBalancer(String xId, String name, String description, + int srcPort, int destPort, long sourceIpId, String protocol, String algorithm, boolean openFirewall, UserContext caller) throws NetworkRuleConflictException { - UserContext caller = UserContext.current(); - int srcPortStart = lb.getSourcePortStart(); - int defPortStart = lb.getDefaultPortStart(); - int srcPortEnd = lb.getSourcePortEnd(); - long sourceIpId = lb.getSourceIpAddressId(); + + if (!NetUtils.isValidPort(destPort)) { + throw new InvalidParameterValueException("privatePort is an invalid value: " + destPort); + } + + if ((algorithm == null) || !NetUtils.isValidAlgorithm(algorithm)) { + throw new InvalidParameterValueException("Invalid algorithm: " + algorithm); + } IPAddressVO ipAddr = _ipAddressDao.findById(sourceIpId); // make sure ip address exists @@ -1293,6 +1376,9 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements ex.addProxyObject(ipAddr, sourceIpId, "sourceIpId"); throw ex; } + + _accountMgr.checkAccess(caller.getCaller(), null, true, ipAddr); + Long networkId = ipAddr.getAssociatedWithNetworkId(); if (networkId == null) { @@ -1301,39 +1387,34 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements ex.addProxyObject(ipAddr, sourceIpId, "sourceIpId"); throw ex; } - - _firewallMgr.validateFirewallRule(caller.getCaller(), ipAddr, srcPortStart, srcPortEnd, lb.getProtocol(), - Purpose.LoadBalancing, FirewallRuleType.User, networkId, null); - NetworkVO network = _networkDao.findById(networkId); - _accountMgr.checkAccess(caller.getCaller(), null, true, ipAddr); - + // verify that lb service is supported by the network - if (!_networkModel.areServicesSupportedInNetwork(network.getId(), Service.Lb)) { - InvalidParameterValueException ex = new InvalidParameterValueException( - "LB service is not supported in specified network id"); - ex.addProxyObject(network, networkId, "networkId"); - throw ex; + isLbServiceSupportedInNetwork(networkId, Scheme.Public); + + _firewallMgr.validateFirewallRule(caller.getCaller(), ipAddr, srcPort, srcPort, protocol, + Purpose.LoadBalancing, FirewallRuleType.User, networkId, null); + + LoadBalancerVO newRule = new LoadBalancerVO(xId, name, description, + sourceIpId, srcPort, srcPort, algorithm, + networkId, ipAddr.getAllocatedToAccountId(), ipAddr.getAllocatedInDomainId()); + + // verify rule is supported by Lb provider of the network + Ip sourceIp = getSourceIp(newRule); + LoadBalancingRule loadBalancing = new LoadBalancingRule(newRule, new ArrayList(), + new ArrayList(), new ArrayList(), sourceIp); + if (!validateLbRule(loadBalancing)) { + throw new InvalidParameterValueException("LB service provider cannot support this rule"); } Transaction txn = Transaction.currentTxn(); txn.start(); - - LoadBalancerVO newRule = new LoadBalancerVO(lb.getXid(), lb.getName(), lb.getDescription(), - lb.getSourceIpAddressId(), lb.getSourcePortEnd(), lb.getDefaultPortStart(), lb.getAlgorithm(), - network.getId(), ipAddr.getAllocatedToAccountId(), ipAddr.getAllocatedInDomainId()); - - // verify rule is supported by Lb provider of the network - LoadBalancingRule loadBalancing = new LoadBalancingRule(newRule, new ArrayList(), - new ArrayList(), new ArrayList()); - if (!validateRule(loadBalancing)) { - throw new InvalidParameterValueException("LB service provider cannot support this rule"); - } - + newRule = _lbDao.persist(newRule); + //create rule for all CIDRs if (openFirewall) { - _firewallMgr.createRuleForAllCidrs(sourceIpId, caller.getCaller(), lb.getSourcePortStart(), - lb.getSourcePortEnd(), lb.getProtocol(), null, null, newRule.getId(), networkId); + _firewallMgr.createRuleForAllCidrs(sourceIpId, caller.getCaller(), srcPort, + srcPort, protocol, null, null, newRule.getId(), networkId); } boolean success = true; @@ -1344,7 +1425,7 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements throw new CloudRuntimeException("Unable to update the state to add for " + newRule); } s_logger.debug("Load balancer " + newRule.getId() + " for Ip address id=" + sourceIpId + ", public port " - + srcPortStart + ", private port " + defPortStart + " is added successfully."); + + srcPort + ", private port " + destPort + " is added successfully."); UserContext.current().setEventDetails("Load balancer Id: " + newRule.getId()); UsageEventUtils.publishUsageEvent(EventTypes.EVENT_LOAD_BALANCER_CREATE, ipAddr.getAllocatedToAccountId(), ipAddr.getDataCenterId(), newRule.getId(), null, LoadBalancingRule.class.getName(), @@ -1380,14 +1461,17 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements lbs = Arrays.asList(lb); } else { // get all rules in transition state - lbs = _lbDao.listInTransitionStateByNetworkId(lb.getNetworkId()); + lbs = _lbDao.listInTransitionStateByNetworkIdAndScheme(lb.getNetworkId(), lb.getScheme()); } return applyLoadBalancerRules(lbs, true); } @Override - public boolean revokeLoadBalancersForNetwork(long networkId) throws ResourceUnavailableException { - List lbs = _lbDao.listByNetworkId(networkId); + public boolean revokeLoadBalancersForNetwork(long networkId, Scheme scheme) throws ResourceUnavailableException { + List lbs = _lbDao.listByNetworkIdAndScheme(networkId, scheme); + if (s_logger.isDebugEnabled()) { + s_logger.debug("Revoking " + lbs.size() + " " + scheme + " load balancing rules for network id=" + networkId); + } if (lbs != null) { for(LoadBalancerVO lb : lbs) { // called during restart, not persisting state in db lb.setState(FirewallRule.State.Revoke); @@ -1400,20 +1484,20 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements } @Override - public boolean applyLoadBalancersForNetwork(long networkId) throws ResourceUnavailableException { - List lbs = _lbDao.listByNetworkId(networkId); + public boolean applyLoadBalancersForNetwork(long networkId, Scheme scheme) throws ResourceUnavailableException { + List lbs = _lbDao.listByNetworkIdAndScheme(networkId, scheme); if (lbs != null) { + s_logger.debug("Applying load balancer rules of scheme " + scheme + " in network id=" + networkId); return applyLoadBalancerRules(lbs, true); } else { - s_logger.info("Network id=" + networkId + " doesn't have load balancer rules, nothing to apply"); + s_logger.info("Network id=" + networkId + " doesn't have load balancer rules of scheme " + scheme + ", nothing to apply"); return true; } } - @Override - public boolean applyRules(Network network, Purpose purpose, List rules) + + protected boolean applyLbRules(Network network, List rules) throws ResourceUnavailableException { - assert (purpose == Purpose.LoadBalancing) : "LB Manager asked to handle non-LB rules"; boolean handled = false; for (LoadBalancingServiceProvider lbElement : _lbProviders) { Provider provider = lbElement.getProvider(); @@ -1422,7 +1506,7 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements if (!isLbProvider) { continue; } - handled = lbElement.applyLBRules(network, (List) rules); + handled = lbElement.applyLBRules(network, rules); if (handled) break; } @@ -1432,7 +1516,8 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements private LoadBalancingRule getLoadBalancerRuleToApply(LoadBalancerVO lb) { List policyList = getStickinessPolicies(lb.getId()); - LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, null, policyList, null); + Ip sourceIp = getSourceIp(lb); + LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, null, policyList, null, sourceIp); if (_autoScaleVmGroupDao.isAutoScaleLoadBalancer(lb.getId())) { // Get the associated VmGroup @@ -1442,7 +1527,7 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements } else { List dstList = getExistingDestinations(lb.getId()); loadBalancing.setDestinations(dstList); - List hcPolicyList = getHealthCheckPolicies(lb.getId()); + List hcPolicyList = getHealthCheckPolicies(lb.getId()); loadBalancing.setHealthCheckPolicies(hcPolicyList); } @@ -1458,7 +1543,7 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements rules.add(getLoadBalancerRuleToApply(lb)); } - if (!_networkMgr.applyRules(rules, FirewallRule.Purpose.LoadBalancing, this, false)) { + if (!applyLbRules(rules, false)) { s_logger.debug("LB rules are not completely applied"); return false; } @@ -1515,7 +1600,7 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements } txn.commit(); - if (checkForReleaseElasticIp) { + if (checkForReleaseElasticIp && lb.getSourceIpAddressId() != null) { boolean success = true; long count = _firewallDao.countRulesByIpId(lb.getSourceIpAddressId()); if (count == 0) { @@ -1534,8 +1619,10 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements } // if the rule is the last one for the ip address assigned to // VPC, unassign it from the network - IpAddress ip = _ipAddressDao.findById(lb.getSourceIpAddressId()); - _vpcMgr.unassignIPFromVpcNetwork(ip.getId(), lb.getNetworkId()); + if (lb.getSourceIpAddressId() != null) { + IpAddress ip = _ipAddressDao.findById(lb.getSourceIpAddressId()); + _vpcMgr.unassignIPFromVpcNetwork(ip.getId(), lb.getNetworkId()); + } } } @@ -1902,32 +1989,115 @@ public class LoadBalancingRulesManagerImpl extends ManagerBase implements count++; } } + + //list only Public load balancers using this command + sc.setParameters("scheme", Scheme.Public); Pair, Integer> result = _lbDao.searchAndCount(sc, searchFilter); return new Pair, Integer>(result.first(), result.second()); } - @Override - public List listByNetworkId(long networkId) { - List lbs = _lbDao.listByNetworkId(networkId); - List lbRules = new ArrayList(); - for (LoadBalancerVO lb : lbs) { - List dstList = getExistingDestinations(lb.getId()); - List policyList = this.getStickinessPolicies(lb.getId()); - List hcPolicyList = this.getHealthCheckPolicies(lb.getId()); - LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, dstList, policyList, hcPolicyList); - lbRules.add(loadBalancing); - } - return lbRules; - } @Override public LoadBalancerVO findById(long lbId) { return _lbDao.findById(lbId); } - protected void removeLBRule(LoadBalancerVO rule) { + @Override + public void removeLBRule(LoadBalancer rule) { // remove the rule _lbDao.remove(rule.getId()); } + + + public boolean applyLbRules(List rules, boolean continueOnError) throws ResourceUnavailableException { + if (rules == null || rules.size() == 0) { + s_logger.debug("There are no Load Balancing Rules to forward to the network elements"); + return true; + } + + boolean success = true; + Network network = _networkModel.getNetwork(rules.get(0).getNetworkId()); + List publicIps = new ArrayList(); + + + // get the list of public ip's owned by the network + List userIps = _ipAddressDao.listByAssociatedNetwork(network.getId(), null); + if (userIps != null && !userIps.isEmpty()) { + for (IPAddressVO userIp : userIps) { + PublicIp publicIp = PublicIp.createFromAddrAndVlan(userIp, _vlanDao.findById(userIp.getVlanId())); + publicIps.add(publicIp); + } + } + + // rules can not programmed unless IP is associated with network + // service provider, so run IP assoication for + // the network so as to ensure IP is associated before applying + // rules (in add state) + _networkMgr.applyIpAssociations(network, false, continueOnError, publicIps); + + + try { + applyLbRules(network, rules); + } catch (ResourceUnavailableException e) { + if (!continueOnError) { + throw e; + } + s_logger.warn("Problems with applying load balancing rules but pushing on", e); + success = false; + } + + // if all the rules configured on public IP are revoked then + // dis-associate IP with network service provider + _networkMgr.applyIpAssociations(network, true, continueOnError, publicIps); + + return success; + } + + @Override + public Map getLbInstances(long lbId) { + Map dstList = new HashMap(); + List lbVmMaps = _lb2VmMapDao.listByLoadBalancerId(lbId); + LoadBalancerVO lb = _lbDao.findById(lbId); + + for (LoadBalancerVMMapVO lbVmMap : lbVmMaps) { + UserVm vm = _vmDao.findById(lbVmMap.getInstanceId()); + Nic nic = _nicDao.findByInstanceIdAndNetworkIdIncludingRemoved(lb.getNetworkId(), vm.getId()); + Ip ip = new Ip(nic.getIp4Address()); + dstList.put(ip, vm); + } + return dstList; + } + + @Override + public void isLbServiceSupportedInNetwork(long networkId, Scheme scheme) { + Network network = _networkDao.findById(networkId); + + //1) Check if the LB service is supported + if (!_networkModel.areServicesSupportedInNetwork(network.getId(), Service.Lb)) { + InvalidParameterValueException ex = new InvalidParameterValueException( + "LB service is not supported in specified network id"); + ex.addProxyObject(network, network.getId(), "networkId"); + throw ex; + } + + //2) Check if the Scheme is supported\ + NetworkOffering off = _configMgr.getNetworkOffering(network.getNetworkOfferingId()); + if (scheme == Scheme.Public) { + if (!off.getPublicLb()) { + throw new InvalidParameterValueException("Scheme " + scheme + " is not supported by the network offering " + off); + } + } else { + if (!off.getInternalLb()) { + throw new InvalidParameterValueException("Scheme " + scheme + " is not supported by the network offering " + off); + } + } + + //3) Check if the provider supports the scheme + LoadBalancingServiceProvider lbProvider = _networkMgr.getLoadBalancingProviderForNetwork(network, scheme); + if (lbProvider == null) { + throw new InvalidParameterValueException("Lb rule with scheme " + scheme.toString() + " is not supported by lb providers in network " + network); + } + } + } diff --git a/server/src/com/cloud/network/router/VirtualNetworkApplianceManager.java b/server/src/com/cloud/network/router/VirtualNetworkApplianceManager.java index f49ab79b500..fcf650f900c 100644 --- a/server/src/com/cloud/network/router/VirtualNetworkApplianceManager.java +++ b/server/src/com/cloud/network/router/VirtualNetworkApplianceManager.java @@ -28,6 +28,7 @@ import com.cloud.network.PublicIpAddress; import com.cloud.network.RemoteAccessVpn; import com.cloud.network.VirtualNetworkApplianceService; import com.cloud.network.VpnUser; +import com.cloud.network.lb.LoadBalancingRule; import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.StaticNat; import com.cloud.user.Account; @@ -103,4 +104,7 @@ public interface VirtualNetworkApplianceManager extends Manager, VirtualNetworkA boolean applyUserData(Network config, NicProfile nic, VirtualMachineProfile vm, DeployDestination dest, List routers) throws ResourceUnavailableException; + + boolean applyLoadBalancingRules(Network network, List rules, List routers) throws ResourceUnavailableException; + } diff --git a/server/src/com/cloud/network/router/VirtualNetworkApplianceManagerImpl.java b/server/src/com/cloud/network/router/VirtualNetworkApplianceManagerImpl.java index 4c7bc75b2d3..e3dd06ba47c 100755 --- a/server/src/com/cloud/network/router/VirtualNetworkApplianceManagerImpl.java +++ b/server/src/com/cloud/network/router/VirtualNetworkApplianceManagerImpl.java @@ -173,6 +173,7 @@ import com.cloud.network.router.VirtualRouter.RedundantState; import com.cloud.network.router.VirtualRouter.Role; import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.FirewallRule.Purpose; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.network.rules.PortForwardingRule; import com.cloud.network.rules.RulesManager; import com.cloud.network.rules.StaticNat; @@ -218,6 +219,7 @@ import com.cloud.utils.db.SearchBuilder; import com.cloud.utils.db.SearchCriteria; import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; +import com.cloud.utils.net.Ip; import com.cloud.utils.net.MacAddress; import com.cloud.utils.net.NetUtils; import com.cloud.vm.DomainRouterVO; @@ -1526,7 +1528,7 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V for (int i = 0; i < count; i++) { List> networks = createRouterNetworks(owner, isRedundant, plan, guestNetwork, new Pair(publicNetwork, sourceNatIp)); - //don't start the router as we are holding the network lock that needs to be released at the end of router allocation + //don't start the router as we are holding the network lock that needs to be released at the end of router allocation DomainRouterVO router = deployRouter(owner, destination, plan, params, isRedundant, vrProvider, offeringId, null, networks, false, null); @@ -1591,7 +1593,26 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V HypervisorType hType = iter.next(); try { s_logger.debug("Allocating the domR with the hypervisor type " + hType); - VMTemplateVO template = _templateDao.findRoutingTemplate(hType); + String templateName = null; + switch (hType) { + case XenServer: + templateName = _configServer.getConfigValue(Config.RouterTemplateXen.key(), Config.ConfigurationParameterScope.zone.toString(), dest.getDataCenter().getId()); + break; + case KVM: + templateName = _configServer.getConfigValue(Config.RouterTemplateKVM.key(), Config.ConfigurationParameterScope.zone.toString(), dest.getDataCenter().getId()); + break; + case VMware: + templateName = _configServer.getConfigValue(Config.RouterTemplateVmware.key(), Config.ConfigurationParameterScope.zone.toString(), dest.getDataCenter().getId()); + break; + case Hyperv: + templateName = _configServer.getConfigValue(Config.RouterTemplateHyperv.key(), Config.ConfigurationParameterScope.zone.toString(), dest.getDataCenter().getId()); + break; + case LXC: + templateName = _configServer.getConfigValue(Config.RouterTemplateLXC.key(), Config.ConfigurationParameterScope.zone.toString(), dest.getDataCenter().getId()); + break; + default: break; + } + VMTemplateVO template = _templateDao.findRoutingTemplate(hType, templateName); if (template == null) { s_logger.debug(hType + " won't support system vm, skip it"); @@ -2391,7 +2412,7 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V } } - List lbs = _loadBalancerDao.listByNetworkId(guestNetworkId); + List lbs = _loadBalancerDao.listByNetworkIdAndScheme(guestNetworkId, Scheme.Public); List lbRules = new ArrayList(); if (_networkModel.isProviderSupportServiceInNetwork(guestNetworkId, Service.Lb, provider)) { // Re-apply load balancing rules @@ -2399,7 +2420,8 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V List dstList = _lbMgr.getExistingDestinations(lb.getId()); List policyList = _lbMgr.getStickinessPolicies(lb.getId()); List hcPolicyList = _lbMgr.getHealthCheckPolicies(lb.getId()); - LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, dstList, policyList, hcPolicyList); + Ip sourceIp = _networkModel.getPublicIpAddress(lb.getSourceIpAddressId()).getAddress(); + LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, dstList, policyList, hcPolicyList, sourceIp); lbRules.add(loadBalancing); } } @@ -2490,7 +2512,7 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V Network network = _networkModel.getNetwork(routerNic.getNetworkId()); if (network.getTrafficType() == TrafficType.Guest) { guestNetworks.add(network); - } + } } answer = cmds.getAnswer("getDomRVersion"); @@ -3017,7 +3039,7 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V String algorithm = rule.getAlgorithm(); String uuid = rule.getUuid(); - String srcIp = _networkModel.getIp(rule.getSourceIpAddressId()).getAddress().addr(); + String srcIp = rule.getSourceIp().addr(); int srcPort = rule.getSourcePortStart(); List destinations = rule.getDestinations(); List stickinessPolicies = rule.getStickinessPolicies(); @@ -3032,7 +3054,7 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V } Network guestNetwork = _networkModel.getNetwork(guestNetworkId); - Nic nic = _nicDao.findByInstanceIdAndNetworkId(guestNetwork.getId(), router.getId()); + Nic nic = _nicDao.findByNtwkIdAndInstanceId(guestNetwork.getId(), router.getId()); NicProfile nicProfile = new NicProfile(nic, guestNetwork, nic.getBroadcastUri(), nic.getIsolationUri(), _networkModel.getNetworkRate(guestNetwork.getId(), router.getId()), _networkModel.isSecurityGroupSupportedInNetwork(guestNetwork), @@ -3125,7 +3147,7 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V } if (createVmData) { - NicVO nic = _nicDao.findByInstanceIdAndNetworkId(guestNetworkId, vm.getId()); + NicVO nic = _nicDao.findByNtwkIdAndInstanceId(guestNetworkId, vm.getId()); if (nic != null) { s_logger.debug("Creating user data entry for vm " + vm + " on domR " + router); createVmDataCommand(router, vm, nic, null, cmds); @@ -3178,7 +3200,7 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V createDhcp = false; } if (createDhcp) { - NicVO nic = _nicDao.findByInstanceIdAndNetworkId(guestNetworkId, vm.getId()); + NicVO nic = _nicDao.findByNtwkIdAndInstanceId(guestNetworkId, vm.getId()); if (nic != null) { s_logger.debug("Creating dhcp entry for vm " + vm + " on domR " + router + "."); createDhcpEntryCommand(router, vm, nic, cmds); @@ -3296,13 +3318,14 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V public boolean execute(Network network, VirtualRouter router) throws ResourceUnavailableException { if (rules.get(0).getPurpose() == Purpose.LoadBalancing) { // for load balancer we have to resend all lb rules for the network - List lbs = _loadBalancerDao.listByNetworkId(network.getId()); + List lbs = _loadBalancerDao.listByNetworkIdAndScheme(network.getId(), Scheme.Public); List lbRules = new ArrayList(); for (LoadBalancerVO lb : lbs) { List dstList = _lbMgr.getExistingDestinations(lb.getId()); List policyList = _lbMgr.getStickinessPolicies(lb.getId()); - List hcPolicyList = _lbMgr.getHealthCheckPolicies(lb.getId() ); - LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, dstList, policyList, hcPolicyList); + List hcPolicyList = _lbMgr.getHealthCheckPolicies(lb.getId()); + Ip sourceIp = _networkModel.getPublicIpAddress(lb.getSourceIpAddressId()).getAddress(); + LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, dstList, policyList, hcPolicyList, sourceIp); lbRules.add(loadBalancing); } return sendLBRules(router, lbRules, network.getId()); @@ -3319,6 +3342,32 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V } }); } + + + @Override + public boolean applyLoadBalancingRules(Network network, final List rules, List routers) throws ResourceUnavailableException { + if (rules == null || rules.isEmpty()) { + s_logger.debug("No lb rules to be applied for network " + network.getId()); + return true; + } + return applyRules(network, routers, "loadbalancing rules", false, null, false, new RuleApplier() { + @Override + public boolean execute(Network network, VirtualRouter router) throws ResourceUnavailableException { + // for load balancer we have to resend all lb rules for the network + List lbs = _loadBalancerDao.listByNetworkIdAndScheme(network.getId(), Scheme.Public); + List lbRules = new ArrayList(); + for (LoadBalancerVO lb : lbs) { + List dstList = _lbMgr.getExistingDestinations(lb.getId()); + List policyList = _lbMgr.getStickinessPolicies(lb.getId()); + List hcPolicyList = _lbMgr.getHealthCheckPolicies(lb.getId()); + Ip sourceIp = _networkModel.getPublicIpAddress(lb.getSourceIpAddressId()).getAddress(); + LoadBalancingRule loadBalancing = new LoadBalancingRule(lb, dstList, policyList, hcPolicyList, sourceIp); + lbRules.add(loadBalancing); + } + return sendLBRules(router, lbRules, network.getId()); + } + }); + } protected boolean sendLBRules(VirtualRouter router, List rules, long guestNetworkId) throws ResourceUnavailableException { Commands cmds = new Commands(OnError.Continue); @@ -3715,4 +3764,11 @@ public class VirtualNetworkApplianceManagerImpl extends ManagerBase implements V } } } + + + + @Override + public VirtualRouter findRouter(long routerId) { + return _routerDao.findById(routerId); + } } diff --git a/server/src/com/cloud/network/router/VpcVirtualNetworkApplianceManagerImpl.java b/server/src/com/cloud/network/router/VpcVirtualNetworkApplianceManagerImpl.java index bdfac060798..611100955e7 100644 --- a/server/src/com/cloud/network/router/VpcVirtualNetworkApplianceManagerImpl.java +++ b/server/src/com/cloud/network/router/VpcVirtualNetworkApplianceManagerImpl.java @@ -440,7 +440,7 @@ public class VpcVirtualNetworkApplianceManagerImpl extends VirtualNetworkApplian defaultDns2 = guestNic.getDns2(); } - Nic nic = _nicDao.findByInstanceIdAndNetworkId(network.getId(), router.getId()); + Nic nic = _nicDao.findByNtwkIdAndInstanceId(network.getId(), router.getId()); String networkDomain = network.getNetworkDomain(); String dhcpRange = getGuestDhcpRange(guestNic, network, _configMgr.getZone(network.getDataCenterId())); @@ -1178,8 +1178,8 @@ public class VpcVirtualNetworkApplianceManagerImpl extends VirtualNetworkApplian for (final PrivateIpAddress ipAddr : ipAddrList) { Network network = _networkModel.getNetwork(ipAddr.getNetworkId()); - IpAddressTO ip = new IpAddressTO(Account.ACCOUNT_ID_SYSTEM, ipAddr.getIpAddress(), add, false, - false, ipAddr.getVlanTag(), ipAddr.getGateway(), ipAddr.getNetmask(), ipAddr.getMacAddress(), + IpAddressTO ip = new IpAddressTO(Account.ACCOUNT_ID_SYSTEM, ipAddr.getIpAddress(), add, false, + ipAddr.getSourceNat(), ipAddr.getVlanTag(), ipAddr.getGateway(), ipAddr.getNetmask(), ipAddr.getMacAddress(), null, false); ip.setTrafficType(network.getTrafficType()); diff --git a/server/src/com/cloud/network/rules/RulesManager.java b/server/src/com/cloud/network/rules/RulesManager.java index 4b83e04eb28..cede987280d 100644 --- a/server/src/com/cloud/network/rules/RulesManager.java +++ b/server/src/com/cloud/network/rules/RulesManager.java @@ -24,6 +24,7 @@ import com.cloud.exception.ResourceUnavailableException; import com.cloud.network.IpAddress; import com.cloud.user.Account; import com.cloud.uservm.UserVm; +import com.cloud.vm.Nic; import com.cloud.vm.VirtualMachine; /** @@ -87,4 +88,6 @@ public interface RulesManager extends RulesService { */ boolean applyStaticNatForNetwork(long networkId, boolean continueOnError, Account caller, boolean forRevoke); + List listAssociatedRulesForGuestNic(Nic nic); + } diff --git a/server/src/com/cloud/network/rules/RulesManagerImpl.java b/server/src/com/cloud/network/rules/RulesManagerImpl.java index 8636d8503a3..c9b47b44bab 100755 --- a/server/src/com/cloud/network/rules/RulesManagerImpl.java +++ b/server/src/com/cloud/network/rules/RulesManagerImpl.java @@ -50,8 +50,11 @@ import com.cloud.network.dao.FirewallRulesCidrsDao; import com.cloud.network.dao.FirewallRulesDao; import com.cloud.network.dao.IPAddressDao; import com.cloud.network.dao.IPAddressVO; +import com.cloud.network.dao.LoadBalancerVMMapDao; +import com.cloud.network.dao.LoadBalancerVMMapVO; import com.cloud.network.rules.FirewallRule.FirewallRuleType; import com.cloud.network.rules.FirewallRule.Purpose; +import com.cloud.network.rules.FirewallRule.TrafficType; import com.cloud.network.rules.dao.PortForwardingRulesDao; import com.cloud.network.vpc.VpcManager; import com.cloud.offering.NetworkOffering; @@ -77,15 +80,18 @@ import com.cloud.utils.db.SearchCriteria.Op; import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; import com.cloud.utils.net.Ip; +import com.cloud.utils.net.NetUtils; import com.cloud.vm.Nic; import com.cloud.vm.NicSecondaryIp; import com.cloud.vm.UserVmVO; +import com.cloud.vm.VMInstanceVO; import com.cloud.vm.VirtualMachine; import com.cloud.vm.VirtualMachine.Type; import com.cloud.vm.dao.NicDao; import com.cloud.vm.dao.NicSecondaryIpDao; import com.cloud.vm.dao.NicSecondaryIpVO; import com.cloud.vm.dao.UserVmDao; +import com.cloud.vm.dao.VMInstanceDao; @Component @Local(value = { RulesManager.class, RulesService.class }) @@ -103,6 +109,8 @@ public class RulesManagerImpl extends ManagerBase implements RulesManager, Rules @Inject UserVmDao _vmDao; @Inject + VMInstanceDao _vmInstanceDao; + @Inject AccountManager _accountMgr; @Inject NetworkManager _networkMgr; @@ -128,6 +136,8 @@ public class RulesManagerImpl extends ManagerBase implements RulesManager, Rules VpcManager _vpcMgr; @Inject NicSecondaryIpDao _nicSecondaryDao; + @Inject + LoadBalancerVMMapDao _loadBalancerVMMapDao; @Override public void checkIpAndUserVm(IpAddress ipAddress, UserVm userVm, Account caller) { @@ -416,7 +426,12 @@ public class RulesManagerImpl extends ManagerBase implements RulesManager, Rules @Override @ActionEvent(eventType = EventTypes.EVENT_ENABLE_STATIC_NAT, eventDescription = "enabling static nat") - public boolean enableStaticNat(long ipId, long vmId, long networkId, boolean isSystemVm, String vmGuestIp) + public boolean enableStaticNat(long ipId, long vmId, long networkId, String vmGuestIp) + throws NetworkRuleConflictException, ResourceUnavailableException { + return enableStaticNat(ipId, vmId, networkId, false, vmGuestIp); + } + + private boolean enableStaticNat(long ipId, long vmId, long networkId, boolean isSystemVm, String vmGuestIp) throws NetworkRuleConflictException, ResourceUnavailableException { UserContext ctx = UserContext.current(); Account caller = ctx.getCaller(); @@ -1370,7 +1385,7 @@ public class RulesManagerImpl extends ManagerBase implements RulesManager, Rules throw new CloudRuntimeException("Ip address is not associated with any network"); } - UserVmVO vm = _vmDao.findById(sourceIp.getAssociatedWithVmId()); + VMInstanceVO vm = _vmInstanceDao.findById(sourceIp.getAssociatedWithVmId()); Network network = _networkModel.getNetwork(networkId); if (network == null) { CloudRuntimeException ex = new CloudRuntimeException("Unable to find an ip address to map to specified vm id"); @@ -1458,4 +1473,36 @@ public class RulesManagerImpl extends ManagerBase implements RulesManager, Rules protected void removePFRule(PortForwardingRuleVO rule) { _portForwardingDao.remove(rule.getId()); } + + @Override + public List listAssociatedRulesForGuestNic(Nic nic){ + List result = new ArrayList(); + // add PF rules + result.addAll(_portForwardingDao.listByDestIpAddr(nic.getIp4Address())); + // add static NAT rules + List staticNatRules = _firewallDao.listStaticNatByVmId(nic.getInstanceId()); + for(FirewallRuleVO rule : staticNatRules){ + if(rule.getNetworkId() == nic.getNetworkId()) + result.add(rule); + } + List staticNatIps = _ipAddressDao.listStaticNatPublicIps(nic.getNetworkId()); + for(IpAddress ip : staticNatIps){ + if(ip.getVmIp() != null && ip.getVmIp().equals(nic.getIp4Address())){ + VMInstanceVO vm = _vmInstanceDao.findById(nic.getInstanceId()); + // generate a static Nat rule on the fly because staticNATrule does not persist into db anymore + // FIX ME + FirewallRuleVO staticNatRule = new FirewallRuleVO(null, ip.getId(), 0, 65535, NetUtils.ALL_PROTO.toString(), + nic.getNetworkId(), vm.getAccountId(), vm.getDomainId(), Purpose.StaticNat, null, null, null, null, null); + result.add(staticNatRule); + } + } + // add LB rules + List lbMapList = _loadBalancerVMMapDao.listByInstanceId(nic.getInstanceId()); + for(LoadBalancerVMMapVO lb : lbMapList){ + FirewallRuleVO lbRule = _firewallDao.findById(lb.getLoadBalancerId()); + if(lbRule.getNetworkId() == nic.getNetworkId()) + result.add(lbRule); + } + return result; + } } diff --git a/server/src/com/cloud/network/vpc/PrivateGatewayProfile.java b/server/src/com/cloud/network/vpc/PrivateGatewayProfile.java index 2595a6a0fa4..20947db0447 100644 --- a/server/src/com/cloud/network/vpc/PrivateGatewayProfile.java +++ b/server/src/com/cloud/network/vpc/PrivateGatewayProfile.java @@ -100,4 +100,9 @@ public class PrivateGatewayProfile implements PrivateGateway { public State getState() { return vpcGateway.getState(); } + + @Override + public boolean getSourceNat() { + return vpcGateway.getSourceNat(); + } } diff --git a/server/src/com/cloud/network/vpc/PrivateIpAddress.java b/server/src/com/cloud/network/vpc/PrivateIpAddress.java index 826bea22e25..2f3cf536e81 100644 --- a/server/src/com/cloud/network/vpc/PrivateIpAddress.java +++ b/server/src/com/cloud/network/vpc/PrivateIpAddress.java @@ -25,6 +25,7 @@ public class PrivateIpAddress implements PrivateIp{ String ipAddress; String macAddress; long networkId; + boolean sourceNat; /** * @param privateIp @@ -42,6 +43,7 @@ public class PrivateIpAddress implements PrivateIp{ this.netmask = netmask; this.macAddress = macAddress; this.networkId = privateIp.getNetworkId(); + this.sourceNat = privateIp.getSourceNat(); } @Override @@ -73,4 +75,9 @@ public class PrivateIpAddress implements PrivateIp{ public long getNetworkId() { return networkId; } + + @Override + public boolean getSourceNat() { + return sourceNat; + } } diff --git a/server/src/com/cloud/network/vpc/VpcManagerImpl.java b/server/src/com/cloud/network/vpc/VpcManagerImpl.java index 224a6800326..e6d71faad35 100644 --- a/server/src/com/cloud/network/vpc/VpcManagerImpl.java +++ b/server/src/com/cloud/network/vpc/VpcManagerImpl.java @@ -184,8 +184,9 @@ public class VpcManagerImpl extends ManagerBase implements VpcManager, VpcProvis private final ScheduledExecutorService _executor = Executors.newScheduledThreadPool(1, new NamedThreadFactory("VpcChecker")); private List vpcElements = null; private final List nonSupportedServices = Arrays.asList(Service.SecurityGroup, Service.Firewall); - private final List supportedProviders = Arrays.asList(Provider.VPCVirtualRouter, Provider.NiciraNvp); - + private final List supportedProviders = Arrays.asList(Provider.VPCVirtualRouter, Provider.NiciraNvp, Provider.InternalLbVm, Provider.Netscaler); + + int _cleanupInterval; int _maxNetworks; SearchBuilder IpAddressSearch; @@ -207,6 +208,7 @@ public class VpcManagerImpl extends ManagerBase implements VpcManager, VpcProvis if (svc == Service.Lb) { Set lbProviders = new HashSet(); lbProviders.add(Provider.VPCVirtualRouter); + lbProviders.add(Provider.InternalLbVm); svcProviderMap.put(svc, lbProviders); } else { svcProviderMap.put(svc, defaultProviders); @@ -215,7 +217,27 @@ public class VpcManagerImpl extends ManagerBase implements VpcManager, VpcProvis createVpcOffering(VpcOffering.defaultVPCOfferingName, VpcOffering.defaultVPCOfferingName, svcProviderMap, true, State.Enabled); } - + + //configure default vpc offering with Netscaler as LB Provider + if (_vpcOffDao.findByUniqueName(VpcOffering.defaultVPCNSOfferingName ) == null) { + s_logger.debug("Creating default VPC offering with Netscaler as LB Provider" + VpcOffering.defaultVPCNSOfferingName); + Map> svcProviderMap = new HashMap>(); + Set defaultProviders = new HashSet(); + defaultProviders.add(Provider.VPCVirtualRouter); + for (Service svc : getSupportedServices()) { + if (svc == Service.Lb) { + Set lbProviders = new HashSet(); + lbProviders.add(Provider.Netscaler); + lbProviders.add(Provider.InternalLbVm); + svcProviderMap.put(svc, lbProviders); + } else { + svcProviderMap.put(svc, defaultProviders); + } + } + createVpcOffering(VpcOffering.defaultVPCNSOfferingName, VpcOffering.defaultVPCNSOfferingName, + svcProviderMap, false, State.Enabled); + } + txn.commit(); Map configs = _configDao.getConfiguration(params); @@ -582,7 +604,7 @@ public class VpcManagerImpl extends ManagerBase implements VpcManager, VpcProvis // 2) If null, generate networkDomain using domain suffix from the global config variables if (networkDomain == null) { - networkDomain = "cs" + Long.toHexString(owner.getId()) + _ntwkModel.getDefaultNetworkDomain(); + networkDomain = "cs" + Long.toHexString(owner.getId()) + _ntwkModel.getDefaultNetworkDomain(zoneId); } } @@ -1038,16 +1060,17 @@ public class VpcManagerImpl extends ManagerBase implements VpcManager, VpcProvis } } - //4) Only one network in the VPC can support LB - if (_ntwkModel.areServicesSupportedByNetworkOffering(guestNtwkOff.getId(), Service.Lb)) { + //4) Only one network in the VPC can support public LB inside the VPC. Internal LB can be supported on multiple VPC tiers + if (_ntwkModel.areServicesSupportedByNetworkOffering(guestNtwkOff.getId(), Service.Lb) && guestNtwkOff.getPublicLb()) { List networks = getVpcNetworks(vpc.getId()); for (Network network : networks) { if (networkId != null && network.getId() == networkId.longValue()) { //skip my own network continue; } else { - if (_ntwkModel.areServicesSupportedInNetwork(network.getId(), Service.Lb)) { - throw new InvalidParameterValueException("LB service is already supported " + + NetworkOffering otherOff = _configMgr.getNetworkOffering(network.getNetworkOfferingId()); + if (_ntwkModel.areServicesSupportedInNetwork(network.getId(), Service.Lb) && otherOff.getPublicLb()) { + throw new InvalidParameterValueException("Public LB service is already supported " + "by network " + network + " in VPC " + vpc); } } @@ -1084,6 +1107,12 @@ public class VpcManagerImpl extends ManagerBase implements VpcManager, VpcProvis if (guestNtwkOff.isConserveMode()) { throw new InvalidParameterValueException("Only networks with conserve mode Off can belong to VPC"); } + + //5) If Netscaler is LB provider make sure it is in dedicated mode + if ( providers.contains(Provider.Netscaler) && !guestNtwkOff.getDedicatedLB() ) { + throw new InvalidParameterValueException("Netscaler only with Dedicated LB can belong to VPC"); + } + return ; } @DB @@ -1285,8 +1314,8 @@ public class VpcManagerImpl extends ManagerBase implements VpcManager, VpcProvis @Override @DB @ActionEvent(eventType = EventTypes.EVENT_PRIVATE_GATEWAY_CREATE, eventDescription = "creating vpc private gateway", create=true) - public PrivateGateway createVpcPrivateGateway(long vpcId, Long physicalNetworkId, String vlan, String ipAddress, - String gateway, String netmask, long gatewayOwnerId) throws ResourceAllocationException, + public PrivateGateway createVpcPrivateGateway(long vpcId, Long physicalNetworkId, String vlan, String ipAddress, + String gateway, String netmask, long gatewayOwnerId, Boolean isSourceNat) throws ResourceAllocationException, ConcurrentOperationException, InsufficientCapacityException { //Validate parameters @@ -1312,11 +1341,11 @@ public class VpcManagerImpl extends ManagerBase implements VpcManager, VpcProvis //1) create private network String networkName = "vpc-" + vpc.getName() + "-privateNetwork"; Network privateNtwk = _ntwkSvc.createPrivateNetwork(networkName, networkName, physicalNetworkId, - vlan, ipAddress, null, gateway, netmask, gatewayOwnerId, vpcId); + vlan, ipAddress, null, gateway, netmask, gatewayOwnerId, vpcId, isSourceNat); //2) create gateway entry VpcGatewayVO gatewayVO = new VpcGatewayVO(ipAddress, VpcGateway.Type.Private, vpcId, privateNtwk.getDataCenterId(), - privateNtwk.getId(), vlan, gateway, netmask, vpc.getAccountId(), vpc.getDomainId()); + privateNtwk.getId(), vlan, gateway, netmask, vpc.getAccountId(), vpc.getDomainId(), isSourceNat); _vpcGatewayDao.persist(gatewayVO); s_logger.debug("Created vpc gateway entry " + gatewayVO); diff --git a/server/src/com/cloud/network/vpn/RemoteAccessVpnManagerImpl.java b/server/src/com/cloud/network/vpn/RemoteAccessVpnManagerImpl.java index 673535aaa42..062743b23af 100755 --- a/server/src/com/cloud/network/vpn/RemoteAccessVpnManagerImpl.java +++ b/server/src/com/cloud/network/vpn/RemoteAccessVpnManagerImpl.java @@ -62,6 +62,7 @@ import com.cloud.network.rules.FirewallRule.Purpose; import com.cloud.network.rules.FirewallRuleVO; import com.cloud.network.rules.RulesManager; import com.cloud.projects.Project.ListProjectResourcesCriteria; +import com.cloud.server.ConfigurationServer; import com.cloud.user.Account; import com.cloud.user.AccountManager; import com.cloud.user.DomainManager; @@ -100,6 +101,7 @@ public class RemoteAccessVpnManagerImpl extends ManagerBase implements RemoteAcc @Inject UsageEventDao _usageEventDao; @Inject ConfigurationDao _configDao; @Inject List _vpnServiceProviders; + @Inject ConfigurationServer _configServer; int _userLimit; @@ -156,7 +158,7 @@ public class RemoteAccessVpnManagerImpl extends ManagerBase implements RemoteAcc } if (ipRange == null) { - ipRange = _clientIpRange; + ipRange = _configServer.getConfigValue(Config.RemoteAccessVpnClientIpRange.key(), Config.ConfigurationParameterScope.account.toString(), ipAddr.getAccountId()); } String[] range = ipRange.split("-"); if (range.length != 2) { @@ -200,7 +202,7 @@ public class RemoteAccessVpnManagerImpl extends ManagerBase implements RemoteAcc private void validateRemoteAccessVpnConfiguration() throws ConfigurationException { String ipRange = _clientIpRange; if (ipRange == null) { - s_logger.warn("Remote Access VPN configuration missing client ip range -- ignoring"); + s_logger.warn("Remote Access VPN global configuration missing client ip range -- ignoring"); return; } Integer pskLength = _pskLength; diff --git a/server/src/com/cloud/resource/ResourceManagerImpl.java b/server/src/com/cloud/resource/ResourceManagerImpl.java index c9c3f9c3722..0ab35dd00a2 100755 --- a/server/src/com/cloud/resource/ResourceManagerImpl.java +++ b/server/src/com/cloud/resource/ResourceManagerImpl.java @@ -30,7 +30,6 @@ import javax.ejb.Local; import javax.inject.Inject; import javax.naming.ConfigurationException; -import com.cloud.dc.*; import org.apache.cloudstack.api.ApiConstants; import org.apache.cloudstack.api.command.admin.cluster.AddClusterCmd; import org.apache.cloudstack.api.command.admin.cluster.DeleteClusterCmd; @@ -74,6 +73,13 @@ import com.cloud.cluster.ManagementServerNode; import com.cloud.configuration.Config; import com.cloud.configuration.ConfigurationManager; import com.cloud.configuration.dao.ConfigurationDao; +import com.cloud.dc.ClusterDetailsDao; +import com.cloud.dc.ClusterDetailsVO; +import com.cloud.dc.ClusterVO; +import com.cloud.dc.DataCenterIpAddressVO; +import com.cloud.dc.DataCenterVO; +import com.cloud.dc.HostPodVO; +import com.cloud.dc.PodCluster; import com.cloud.dc.dao.ClusterDao; import com.cloud.dc.dao.ClusterVSMMapDao; import com.cloud.dc.dao.DataCenterDao; @@ -1638,10 +1644,10 @@ public class ResourceManagerImpl extends ManagerBase implements ResourceManager, private Object dispatchToStateAdapters(ResourceStateAdapter.Event event, boolean singleTaker, Object... args) { synchronized (_resourceStateAdapters) { - Iterator it = _resourceStateAdapters.entrySet().iterator(); + Iterator> it = _resourceStateAdapters.entrySet().iterator(); Object result = null; while (it.hasNext()) { - Map.Entry item = (Map.Entry) it + Map.Entry item = it .next(); ResourceStateAdapter adapter = item.getValue(); diff --git a/server/src/com/cloud/resourcelimit/ResourceLimitManagerImpl.java b/server/src/com/cloud/resourcelimit/ResourceLimitManagerImpl.java index e8805ae8910..5bb770871ca 100755 --- a/server/src/com/cloud/resourcelimit/ResourceLimitManagerImpl.java +++ b/server/src/com/cloud/resourcelimit/ResourceLimitManagerImpl.java @@ -582,7 +582,7 @@ public class ResourceLimitManagerImpl extends ManagerBase implements ResourceLim } //Convert max storage size from GiB to bytes - if (resourceType == ResourceType.primary_storage || resourceType == ResourceType.secondary_storage) { + if ((resourceType == ResourceType.primary_storage || resourceType == ResourceType.secondary_storage) && max >= 0) { max = max * ResourceType.bytesToGiB; } diff --git a/server/src/com/cloud/server/ConfigurationServerImpl.java b/server/src/com/cloud/server/ConfigurationServerImpl.java index cd890ce8582..bc52e9a881c 100755 --- a/server/src/com/cloud/server/ConfigurationServerImpl.java +++ b/server/src/com/cloud/server/ConfigurationServerImpl.java @@ -48,8 +48,10 @@ import com.cloud.dc.*; import com.cloud.dc.dao.DcDetailsDao; import com.cloud.user.*; import com.cloud.utils.db.GenericDao; +import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDao; import org.apache.cloudstack.storage.datastore.db.StoragePoolDetailVO; import org.apache.cloudstack.storage.datastore.db.StoragePoolDetailsDao; +import org.apache.cloudstack.storage.datastore.db.StoragePoolVO; import org.apache.commons.codec.binary.Base64; import org.apache.log4j.Logger; import org.springframework.stereotype.Component; @@ -59,6 +61,7 @@ import com.cloud.configuration.Resource.ResourceType; import com.cloud.configuration.dao.ConfigurationDao; import com.cloud.configuration.dao.ResourceCountDao; import com.cloud.dc.DataCenter.NetworkType; +import com.cloud.dc.dao.ClusterDao; import com.cloud.dc.dao.DataCenterDao; import com.cloud.dc.dao.HostPodDao; import com.cloud.dc.dao.VlanDao; @@ -112,6 +115,8 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio @Inject private ConfigurationDao _configDao; @Inject private DataCenterDao _zoneDao; + @Inject private ClusterDao _clusterDao; + @Inject private PrimaryDataStoreDao _storagePoolDao; @Inject private HostPodDao _podDao; @Inject private DiskOfferingDao _diskOfferingDao; @Inject private ServiceOfferingDao _serviceOfferingDao; @@ -698,7 +703,7 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio return dcDetailVO.getValue(); } break; - case cluster: ClusterDetailsVO cluster = _clusterDetailsDao.findById(resourceId); + case cluster: ClusterVO cluster = _clusterDao.findById(resourceId); if (cluster == null) { throw new InvalidParameterValueException("unable to find cluster by id " + resourceId); } @@ -707,7 +712,7 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio return clusterDetailsVO.getValue(); } break; - case pool: StoragePoolDetailVO pool = _storagePoolDetailsDao.findById(resourceId); + case storagepool: StoragePoolVO pool = _storagePoolDao.findById(resourceId); if (pool == null) { throw new InvalidParameterValueException("unable to find storage pool by id " + resourceId); } @@ -716,7 +721,7 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio return storagePoolDetailVO.getValue(); } break; - case account: AccountDetailVO account = _accountDetailsDao.findById(resourceId); + case account: AccountVO account = _accountDao.findById(resourceId); if (account == null) { throw new InvalidParameterValueException("unable to find account by id " + resourceId); } @@ -1012,7 +1017,7 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio "Offering for Shared Security group enabled networks", TrafficType.Guest, false, true, null, null, true, Availability.Optional, - null, Network.GuestType.Shared, true, true, false); + null, Network.GuestType.Shared, true, true, false, false, false); defaultSharedSGNetworkOffering.setState(NetworkOffering.State.Enabled); defaultSharedSGNetworkOffering = _networkOfferingDao.persistDefaultNetworkOffering(defaultSharedSGNetworkOffering); @@ -1029,7 +1034,7 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio "Offering for Shared networks", TrafficType.Guest, false, true, null, null, true, Availability.Optional, - null, Network.GuestType.Shared, true, true, false); + null, Network.GuestType.Shared, true, true, false, false, false); defaultSharedNetworkOffering.setState(NetworkOffering.State.Enabled); defaultSharedNetworkOffering = _networkOfferingDao.persistDefaultNetworkOffering(defaultSharedNetworkOffering); @@ -1046,7 +1051,7 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio "Offering for Isolated networks with Source Nat service enabled", TrafficType.Guest, false, false, null, null, true, Availability.Required, - null, Network.GuestType.Isolated, true, false, false); + null, Network.GuestType.Isolated, true, false, false, false, true); defaultIsolatedSourceNatEnabledNetworkOffering.setState(NetworkOffering.State.Enabled); defaultIsolatedSourceNatEnabledNetworkOffering = _networkOfferingDao.persistDefaultNetworkOffering(defaultIsolatedSourceNatEnabledNetworkOffering); @@ -1064,7 +1069,7 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio "Offering for Isolated networks with no Source Nat service", TrafficType.Guest, false, true, null, null, true, Availability.Optional, - null, Network.GuestType.Isolated, true, true, false); + null, Network.GuestType.Isolated, true, true, false, false, false); defaultIsolatedEnabledNetworkOffering.setState(NetworkOffering.State.Enabled); defaultIsolatedEnabledNetworkOffering = _networkOfferingDao.persistDefaultNetworkOffering(defaultIsolatedEnabledNetworkOffering); @@ -1081,7 +1086,7 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio "Offering for Shared networks with Elastic IP and Elastic LB capabilities", TrafficType.Guest, false, true, null, null, true, Availability.Optional, - null, Network.GuestType.Shared, true, false, false, false, true, true, true, false, false, true); + null, Network.GuestType.Shared, true, false, false, false, true, true, true, false, false, true, true, false); defaultNetscalerNetworkOffering.setState(NetworkOffering.State.Enabled); defaultNetscalerNetworkOffering = _networkOfferingDao.persistDefaultNetworkOffering(defaultNetscalerNetworkOffering); @@ -1098,7 +1103,7 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio "Offering for Isolated Vpc networks with Source Nat service enabled", TrafficType.Guest, false, false, null, null, true, Availability.Optional, - null, Network.GuestType.Isolated, false, false, false); + null, Network.GuestType.Isolated, false, false, false, false, true); defaultNetworkOfferingForVpcNetworks.setState(NetworkOffering.State.Enabled); defaultNetworkOfferingForVpcNetworks = _networkOfferingDao.persistDefaultNetworkOffering(defaultNetworkOfferingForVpcNetworks); @@ -1128,7 +1133,7 @@ public class ConfigurationServerImpl extends ManagerBase implements Configuratio "Offering for Isolated Vpc networks with Source Nat service enabled and LB service Disabled", TrafficType.Guest, false, false, null, null, true, Availability.Optional, - null, Network.GuestType.Isolated, false, false, false); + null, Network.GuestType.Isolated, false, false, false, false, false); defaultNetworkOfferingForVpcNetworksNoLB.setState(NetworkOffering.State.Enabled); defaultNetworkOfferingForVpcNetworksNoLB = _networkOfferingDao.persistDefaultNetworkOffering(defaultNetworkOfferingForVpcNetworksNoLB); diff --git a/server/src/com/cloud/server/ManagementServerImpl.java b/server/src/com/cloud/server/ManagementServerImpl.java index 9edeb1aad09..5173cd55333 100755 --- a/server/src/com/cloud/server/ManagementServerImpl.java +++ b/server/src/com/cloud/server/ManagementServerImpl.java @@ -43,85 +43,436 @@ import javax.crypto.spec.SecretKeySpec; import javax.inject.Inject; import javax.naming.ConfigurationException; -import com.cloud.configuration.*; -import com.cloud.storage.dao.*; +import org.apache.cloudstack.acl.ControlledEntity; import org.apache.cloudstack.acl.SecurityChecker.AccessType; import org.apache.cloudstack.api.ApiConstants; import com.cloud.event.ActionEventUtils; import org.apache.cloudstack.api.BaseUpdateTemplateOrIsoCmd; -import org.apache.cloudstack.api.command.admin.account.*; -import org.apache.cloudstack.api.command.admin.domain.*; -import org.apache.cloudstack.api.command.admin.host.*; -import org.apache.cloudstack.api.command.admin.network.*; -import org.apache.cloudstack.api.command.admin.offering.*; import org.apache.cloudstack.api.command.admin.region.*; -import org.apache.cloudstack.api.command.admin.resource.*; -import org.apache.cloudstack.api.command.admin.router.*; -import org.apache.cloudstack.api.command.admin.storage.*; -import org.apache.cloudstack.api.command.admin.systemvm.*; -import org.apache.cloudstack.api.command.admin.usage.*; -import org.apache.cloudstack.api.command.admin.user.*; -import org.apache.cloudstack.api.command.admin.vlan.*; -import org.apache.cloudstack.api.command.admin.vpc.*; -import org.apache.cloudstack.api.command.user.autoscale.*; -import org.apache.cloudstack.api.command.user.firewall.*; -import org.apache.cloudstack.api.command.user.iso.*; -import org.apache.cloudstack.api.command.user.loadbalancer.*; -import org.apache.cloudstack.api.command.user.nat.*; -import org.apache.cloudstack.api.command.user.network.*; -import org.apache.cloudstack.api.command.user.project.*; -import org.apache.cloudstack.api.command.user.resource.*; -import org.apache.cloudstack.api.command.user.securitygroup.*; -import org.apache.cloudstack.api.command.user.snapshot.*; -import org.apache.cloudstack.api.command.user.template.*; -import org.apache.cloudstack.api.command.user.vm.*; -import org.apache.cloudstack.api.command.user.volume.*; -import org.apache.cloudstack.api.command.user.vpc.*; -import org.apache.cloudstack.api.command.user.vpn.*; import org.apache.cloudstack.api.response.ExtractResponse; import org.apache.commons.codec.binary.Base64; import org.apache.log4j.Logger; import org.apache.cloudstack.affinity.AffinityGroupProcessor; import org.apache.cloudstack.affinity.dao.AffinityGroupVMMapDao; - +import org.apache.cloudstack.api.ApiConstants; +import org.apache.cloudstack.api.BaseUpdateTemplateOrIsoCmd; +import org.apache.cloudstack.api.command.admin.account.CreateAccountCmd; +import org.apache.cloudstack.api.command.admin.account.DeleteAccountCmd; +import org.apache.cloudstack.api.command.admin.account.DisableAccountCmd; +import org.apache.cloudstack.api.command.admin.account.EnableAccountCmd; +import org.apache.cloudstack.api.command.admin.account.LockAccountCmd; +import org.apache.cloudstack.api.command.admin.account.UpdateAccountCmd; +import org.apache.cloudstack.api.command.admin.autoscale.CreateCounterCmd; +import org.apache.cloudstack.api.command.admin.autoscale.DeleteCounterCmd; +import org.apache.cloudstack.api.command.admin.cluster.AddClusterCmd; +import org.apache.cloudstack.api.command.admin.cluster.DeleteClusterCmd; +import org.apache.cloudstack.api.command.admin.cluster.ListClustersCmd; +import org.apache.cloudstack.api.command.admin.cluster.UpdateClusterCmd; +import org.apache.cloudstack.api.command.admin.config.ListCfgsByCmd; +import org.apache.cloudstack.api.command.admin.config.ListHypervisorCapabilitiesCmd; +import org.apache.cloudstack.api.command.admin.config.UpdateCfgCmd; +import org.apache.cloudstack.api.command.admin.config.UpdateHypervisorCapabilitiesCmd; +import org.apache.cloudstack.api.command.admin.domain.CreateDomainCmd; +import org.apache.cloudstack.api.command.admin.domain.DeleteDomainCmd; +import org.apache.cloudstack.api.command.admin.domain.ListDomainChildrenCmd; +import org.apache.cloudstack.api.command.admin.domain.ListDomainsCmd; +import org.apache.cloudstack.api.command.admin.domain.UpdateDomainCmd; +import org.apache.cloudstack.api.command.admin.host.AddHostCmd; +import org.apache.cloudstack.api.command.admin.host.AddSecondaryStorageCmd; +import org.apache.cloudstack.api.command.admin.host.CancelMaintenanceCmd; +import org.apache.cloudstack.api.command.admin.host.DeleteHostCmd; +import org.apache.cloudstack.api.command.admin.host.FindHostsForMigrationCmd; +import org.apache.cloudstack.api.command.admin.host.ListHostsCmd; +import org.apache.cloudstack.api.command.admin.host.PrepareForMaintenanceCmd; +import org.apache.cloudstack.api.command.admin.host.ReconnectHostCmd; +import org.apache.cloudstack.api.command.admin.host.UpdateHostCmd; +import org.apache.cloudstack.api.command.admin.host.UpdateHostPasswordCmd; +import org.apache.cloudstack.api.command.admin.internallb.ConfigureInternalLoadBalancerElementCmd; +import org.apache.cloudstack.api.command.admin.internallb.CreateInternalLoadBalancerElementCmd; +import org.apache.cloudstack.api.command.admin.internallb.ListInternalLBVMsCmd; +import org.apache.cloudstack.api.command.admin.internallb.ListInternalLoadBalancerElementsCmd; +import org.apache.cloudstack.api.command.admin.internallb.StartInternalLBVMCmd; +import org.apache.cloudstack.api.command.admin.internallb.StopInternalLBVMCmd; +import org.apache.cloudstack.api.command.admin.ldap.LDAPConfigCmd; +import org.apache.cloudstack.api.command.admin.ldap.LDAPRemoveCmd; +import org.apache.cloudstack.api.command.admin.network.AddNetworkDeviceCmd; +import org.apache.cloudstack.api.command.admin.network.AddNetworkServiceProviderCmd; +import org.apache.cloudstack.api.command.admin.network.CreateNetworkOfferingCmd; +import org.apache.cloudstack.api.command.admin.network.CreatePhysicalNetworkCmd; +import org.apache.cloudstack.api.command.admin.network.CreateStorageNetworkIpRangeCmd; +import org.apache.cloudstack.api.command.admin.network.DedicateGuestVlanRangeCmd; +import org.apache.cloudstack.api.command.admin.network.DeleteNetworkDeviceCmd; +import org.apache.cloudstack.api.command.admin.network.DeleteNetworkOfferingCmd; +import org.apache.cloudstack.api.command.admin.network.DeleteNetworkServiceProviderCmd; +import org.apache.cloudstack.api.command.admin.network.DeletePhysicalNetworkCmd; +import org.apache.cloudstack.api.command.admin.network.DeleteStorageNetworkIpRangeCmd; +import org.apache.cloudstack.api.command.admin.network.ListDedicatedGuestVlanRangesCmd; +import org.apache.cloudstack.api.command.admin.network.ListNetworkDeviceCmd; +import org.apache.cloudstack.api.command.admin.network.ListNetworkIsolationMethodsCmd; +import org.apache.cloudstack.api.command.admin.network.ListNetworkServiceProvidersCmd; +import org.apache.cloudstack.api.command.admin.network.ListPhysicalNetworksCmd; +import org.apache.cloudstack.api.command.admin.network.ListStorageNetworkIpRangeCmd; +import org.apache.cloudstack.api.command.admin.network.ListSupportedNetworkServicesCmd; +import org.apache.cloudstack.api.command.admin.network.ReleaseDedicatedGuestVlanRangeCmd; +import org.apache.cloudstack.api.command.admin.network.UpdateNetworkOfferingCmd; +import org.apache.cloudstack.api.command.admin.network.UpdateNetworkServiceProviderCmd; +import org.apache.cloudstack.api.command.admin.network.UpdatePhysicalNetworkCmd; +import org.apache.cloudstack.api.command.admin.network.UpdateStorageNetworkIpRangeCmd; +import org.apache.cloudstack.api.command.admin.offering.CreateDiskOfferingCmd; +import org.apache.cloudstack.api.command.admin.offering.CreateServiceOfferingCmd; +import org.apache.cloudstack.api.command.admin.offering.DeleteDiskOfferingCmd; +import org.apache.cloudstack.api.command.admin.offering.DeleteServiceOfferingCmd; +import org.apache.cloudstack.api.command.admin.offering.UpdateDiskOfferingCmd; +import org.apache.cloudstack.api.command.admin.offering.UpdateServiceOfferingCmd; +import org.apache.cloudstack.api.command.admin.pod.CreatePodCmd; +import org.apache.cloudstack.api.command.admin.pod.DeletePodCmd; +import org.apache.cloudstack.api.command.admin.pod.ListPodsByCmd; +import org.apache.cloudstack.api.command.admin.pod.UpdatePodCmd; +import org.apache.cloudstack.api.command.admin.resource.ArchiveAlertsCmd; +import org.apache.cloudstack.api.command.admin.resource.DeleteAlertsCmd; +import org.apache.cloudstack.api.command.admin.resource.ListAlertsCmd; +import org.apache.cloudstack.api.command.admin.resource.ListCapacityCmd; +import org.apache.cloudstack.api.command.admin.resource.UploadCustomCertificateCmd; +import org.apache.cloudstack.api.command.admin.router.ConfigureVirtualRouterElementCmd; +import org.apache.cloudstack.api.command.admin.router.CreateVirtualRouterElementCmd; +import org.apache.cloudstack.api.command.admin.router.DestroyRouterCmd; +import org.apache.cloudstack.api.command.admin.router.ListRoutersCmd; +import org.apache.cloudstack.api.command.admin.router.ListVirtualRouterElementsCmd; +import org.apache.cloudstack.api.command.admin.router.RebootRouterCmd; +import org.apache.cloudstack.api.command.admin.router.StartRouterCmd; +import org.apache.cloudstack.api.command.admin.router.StopRouterCmd; +import org.apache.cloudstack.api.command.admin.router.UpgradeRouterCmd; +import org.apache.cloudstack.api.command.admin.storage.AddS3Cmd; +import org.apache.cloudstack.api.command.admin.storage.CancelPrimaryStorageMaintenanceCmd; +import org.apache.cloudstack.api.command.admin.storage.CreateStoragePoolCmd; +import org.apache.cloudstack.api.command.admin.storage.DeletePoolCmd; +import org.apache.cloudstack.api.command.admin.storage.FindStoragePoolsForMigrationCmd; +import org.apache.cloudstack.api.command.admin.storage.ListS3sCmd; +import org.apache.cloudstack.api.command.admin.storage.ListStoragePoolsCmd; +import org.apache.cloudstack.api.command.admin.storage.ListStorageProvidersCmd; +import org.apache.cloudstack.api.command.admin.storage.PreparePrimaryStorageForMaintenanceCmd; +import org.apache.cloudstack.api.command.admin.storage.UpdateStoragePoolCmd; +import org.apache.cloudstack.api.command.admin.swift.AddSwiftCmd; +import org.apache.cloudstack.api.command.admin.swift.ListSwiftsCmd; +import org.apache.cloudstack.api.command.admin.systemvm.DestroySystemVmCmd; +import org.apache.cloudstack.api.command.admin.systemvm.ListSystemVMsCmd; +import org.apache.cloudstack.api.command.admin.systemvm.MigrateSystemVMCmd; +import org.apache.cloudstack.api.command.admin.systemvm.RebootSystemVmCmd; +import org.apache.cloudstack.api.command.admin.systemvm.StartSystemVMCmd; +import org.apache.cloudstack.api.command.admin.systemvm.StopSystemVmCmd; +import org.apache.cloudstack.api.command.admin.systemvm.UpgradeSystemVMCmd; +import org.apache.cloudstack.api.command.admin.template.PrepareTemplateCmd; +import org.apache.cloudstack.api.command.admin.usage.AddTrafficMonitorCmd; +import org.apache.cloudstack.api.command.admin.usage.AddTrafficTypeCmd; +import org.apache.cloudstack.api.command.admin.usage.DeleteTrafficMonitorCmd; +import org.apache.cloudstack.api.command.admin.usage.DeleteTrafficTypeCmd; +import org.apache.cloudstack.api.command.admin.usage.GenerateUsageRecordsCmd; +import org.apache.cloudstack.api.command.admin.usage.GetUsageRecordsCmd; +import org.apache.cloudstack.api.command.admin.usage.ListTrafficMonitorsCmd; +import org.apache.cloudstack.api.command.admin.usage.ListTrafficTypeImplementorsCmd; +import org.apache.cloudstack.api.command.admin.usage.ListTrafficTypesCmd; +import org.apache.cloudstack.api.command.admin.usage.ListUsageTypesCmd; +import org.apache.cloudstack.api.command.admin.usage.UpdateTrafficTypeCmd; +import org.apache.cloudstack.api.command.admin.user.CreateUserCmd; +import org.apache.cloudstack.api.command.admin.user.DeleteUserCmd; +import org.apache.cloudstack.api.command.admin.user.DisableUserCmd; +import org.apache.cloudstack.api.command.admin.user.EnableUserCmd; +import org.apache.cloudstack.api.command.admin.user.GetUserCmd; +import org.apache.cloudstack.api.command.admin.user.ListUsersCmd; +import org.apache.cloudstack.api.command.admin.user.LockUserCmd; +import org.apache.cloudstack.api.command.admin.user.RegisterCmd; +import org.apache.cloudstack.api.command.admin.user.UpdateUserCmd; +import org.apache.cloudstack.api.command.admin.vlan.CreateVlanIpRangeCmd; +import org.apache.cloudstack.api.command.admin.vlan.DedicatePublicIpRangeCmd; +import org.apache.cloudstack.api.command.admin.vlan.DeleteVlanIpRangeCmd; +import org.apache.cloudstack.api.command.admin.vlan.ListVlanIpRangesCmd; +import org.apache.cloudstack.api.command.admin.vlan.ReleasePublicIpRangeCmd; +import org.apache.cloudstack.api.command.admin.vm.AssignVMCmd; +import org.apache.cloudstack.api.command.admin.vm.MigrateVMCmd; +import org.apache.cloudstack.api.command.admin.vm.MigrateVirtualMachineWithVolumeCmd; +import org.apache.cloudstack.api.command.admin.vm.RecoverVMCmd; +import org.apache.cloudstack.api.command.admin.vpc.CreatePrivateGatewayCmd; +import org.apache.cloudstack.api.command.admin.vpc.CreateVPCOfferingCmd; +import org.apache.cloudstack.api.command.admin.vpc.DeletePrivateGatewayCmd; +import org.apache.cloudstack.api.command.admin.vpc.DeleteVPCOfferingCmd; +import org.apache.cloudstack.api.command.admin.vpc.UpdateVPCOfferingCmd; +import org.apache.cloudstack.api.command.admin.zone.CreateZoneCmd; +import org.apache.cloudstack.api.command.admin.zone.DeleteZoneCmd; +import org.apache.cloudstack.api.command.admin.zone.MarkDefaultZoneForAccountCmd; +import org.apache.cloudstack.api.command.admin.zone.UpdateZoneCmd; +import org.apache.cloudstack.api.command.user.account.AddAccountToProjectCmd; +import org.apache.cloudstack.api.command.user.account.DeleteAccountFromProjectCmd; +import org.apache.cloudstack.api.command.user.account.ListAccountsCmd; +import org.apache.cloudstack.api.command.user.account.ListProjectAccountsCmd; +import org.apache.cloudstack.api.command.user.address.AssociateIPAddrCmd; +import org.apache.cloudstack.api.command.user.address.DisassociateIPAddrCmd; +import org.apache.cloudstack.api.command.user.address.ListPublicIpAddressesCmd; import org.apache.cloudstack.api.command.user.affinitygroup.CreateAffinityGroupCmd; import org.apache.cloudstack.api.command.user.affinitygroup.DeleteAffinityGroupCmd; import org.apache.cloudstack.api.command.user.affinitygroup.ListAffinityGroupTypesCmd; import org.apache.cloudstack.api.command.user.affinitygroup.ListAffinityGroupsCmd; import org.apache.cloudstack.api.command.user.affinitygroup.UpdateVMAffinityGroupCmd; +import org.apache.cloudstack.api.command.user.autoscale.CreateAutoScalePolicyCmd; +import org.apache.cloudstack.api.command.user.autoscale.CreateAutoScaleVmGroupCmd; +import org.apache.cloudstack.api.command.user.autoscale.CreateAutoScaleVmProfileCmd; +import org.apache.cloudstack.api.command.user.autoscale.CreateConditionCmd; +import org.apache.cloudstack.api.command.user.autoscale.DeleteAutoScalePolicyCmd; +import org.apache.cloudstack.api.command.user.autoscale.DeleteAutoScaleVmGroupCmd; +import org.apache.cloudstack.api.command.user.autoscale.DeleteAutoScaleVmProfileCmd; +import org.apache.cloudstack.api.command.user.autoscale.DeleteConditionCmd; +import org.apache.cloudstack.api.command.user.autoscale.DisableAutoScaleVmGroupCmd; +import org.apache.cloudstack.api.command.user.autoscale.EnableAutoScaleVmGroupCmd; +import org.apache.cloudstack.api.command.user.autoscale.ListAutoScalePoliciesCmd; +import org.apache.cloudstack.api.command.user.autoscale.ListAutoScaleVmGroupsCmd; +import org.apache.cloudstack.api.command.user.autoscale.ListAutoScaleVmProfilesCmd; +import org.apache.cloudstack.api.command.user.autoscale.ListConditionsCmd; +import org.apache.cloudstack.api.command.user.autoscale.ListCountersCmd; +import org.apache.cloudstack.api.command.user.autoscale.UpdateAutoScalePolicyCmd; +import org.apache.cloudstack.api.command.user.autoscale.UpdateAutoScaleVmGroupCmd; +import org.apache.cloudstack.api.command.user.autoscale.UpdateAutoScaleVmProfileCmd; +import org.apache.cloudstack.api.command.user.config.ListCapabilitiesCmd; +import org.apache.cloudstack.api.command.user.event.ArchiveEventsCmd; +import org.apache.cloudstack.api.command.user.event.DeleteEventsCmd; +import org.apache.cloudstack.api.command.user.event.ListEventTypesCmd; +import org.apache.cloudstack.api.command.user.event.ListEventsCmd; +import org.apache.cloudstack.api.command.user.firewall.CreateEgressFirewallRuleCmd; +import org.apache.cloudstack.api.command.user.firewall.CreateFirewallRuleCmd; +import org.apache.cloudstack.api.command.user.firewall.CreatePortForwardingRuleCmd; +import org.apache.cloudstack.api.command.user.firewall.DeleteEgressFirewallRuleCmd; +import org.apache.cloudstack.api.command.user.firewall.DeleteFirewallRuleCmd; +import org.apache.cloudstack.api.command.user.firewall.DeletePortForwardingRuleCmd; +import org.apache.cloudstack.api.command.user.firewall.ListEgressFirewallRulesCmd; +import org.apache.cloudstack.api.command.user.firewall.ListFirewallRulesCmd; +import org.apache.cloudstack.api.command.user.firewall.ListPortForwardingRulesCmd; +import org.apache.cloudstack.api.command.user.firewall.UpdatePortForwardingRuleCmd; +import org.apache.cloudstack.api.command.user.guest.ListGuestOsCategoriesCmd; +import org.apache.cloudstack.api.command.user.guest.ListGuestOsCmd; +import org.apache.cloudstack.api.command.user.iso.AttachIsoCmd; +import org.apache.cloudstack.api.command.user.iso.CopyIsoCmd; +import org.apache.cloudstack.api.command.user.iso.DeleteIsoCmd; +import org.apache.cloudstack.api.command.user.iso.DetachIsoCmd; +import org.apache.cloudstack.api.command.user.iso.ExtractIsoCmd; +import org.apache.cloudstack.api.command.user.iso.ListIsoPermissionsCmd; +import org.apache.cloudstack.api.command.user.iso.ListIsosCmd; +import org.apache.cloudstack.api.command.user.iso.RegisterIsoCmd; +import org.apache.cloudstack.api.command.user.iso.UpdateIsoCmd; +import org.apache.cloudstack.api.command.user.iso.UpdateIsoPermissionsCmd; +import org.apache.cloudstack.api.command.user.job.ListAsyncJobsCmd; +import org.apache.cloudstack.api.command.user.job.QueryAsyncJobResultCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.AssignToLoadBalancerRuleCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.CreateApplicationLoadBalancerCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.CreateLBHealthCheckPolicyCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.CreateLBStickinessPolicyCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.CreateLoadBalancerRuleCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.DeleteApplicationLoadBalancerCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.DeleteLBHealthCheckPolicyCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.DeleteLBStickinessPolicyCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.DeleteLoadBalancerRuleCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.ListApplicationLoadBalancersCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.ListLBHealthCheckPoliciesCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.ListLBStickinessPoliciesCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.ListLoadBalancerRuleInstancesCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.ListLoadBalancerRulesCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.RemoveFromLoadBalancerRuleCmd; +import org.apache.cloudstack.api.command.user.loadbalancer.UpdateLoadBalancerRuleCmd; +import org.apache.cloudstack.api.command.user.nat.CreateIpForwardingRuleCmd; +import org.apache.cloudstack.api.command.user.nat.DeleteIpForwardingRuleCmd; +import org.apache.cloudstack.api.command.user.nat.DisableStaticNatCmd; +import org.apache.cloudstack.api.command.user.nat.EnableStaticNatCmd; +import org.apache.cloudstack.api.command.user.nat.ListIpForwardingRulesCmd; +import org.apache.cloudstack.api.command.user.network.CreateNetworkACLCmd; +import org.apache.cloudstack.api.command.user.network.CreateNetworkCmd; +import org.apache.cloudstack.api.command.user.network.DeleteNetworkACLCmd; +import org.apache.cloudstack.api.command.user.network.DeleteNetworkCmd; +import org.apache.cloudstack.api.command.user.network.ListNetworkACLsCmd; +import org.apache.cloudstack.api.command.user.network.ListNetworkOfferingsCmd; +import org.apache.cloudstack.api.command.user.network.ListNetworksCmd; +import org.apache.cloudstack.api.command.user.network.RestartNetworkCmd; +import org.apache.cloudstack.api.command.user.network.UpdateNetworkCmd; +import org.apache.cloudstack.api.command.user.offering.ListDiskOfferingsCmd; +import org.apache.cloudstack.api.command.user.offering.ListServiceOfferingsCmd; +import org.apache.cloudstack.api.command.user.project.ActivateProjectCmd; +import org.apache.cloudstack.api.command.user.project.CreateProjectCmd; +import org.apache.cloudstack.api.command.user.project.DeleteProjectCmd; +import org.apache.cloudstack.api.command.user.project.DeleteProjectInvitationCmd; +import org.apache.cloudstack.api.command.user.project.ListProjectInvitationsCmd; +import org.apache.cloudstack.api.command.user.project.ListProjectsCmd; +import org.apache.cloudstack.api.command.user.project.SuspendProjectCmd; +import org.apache.cloudstack.api.command.user.project.UpdateProjectCmd; +import org.apache.cloudstack.api.command.user.project.UpdateProjectInvitationCmd; +import org.apache.cloudstack.api.command.user.region.ListRegionsCmd; +import org.apache.cloudstack.api.command.user.region.ha.gslb.AssignToGlobalLoadBalancerRuleCmd; +import org.apache.cloudstack.api.command.user.region.ha.gslb.CreateGlobalLoadBalancerRuleCmd; +import org.apache.cloudstack.api.command.user.region.ha.gslb.DeleteGlobalLoadBalancerRuleCmd; +import org.apache.cloudstack.api.command.user.region.ha.gslb.ListGlobalLoadBalancerRuleCmd; +import org.apache.cloudstack.api.command.user.region.ha.gslb.RemoveFromGlobalLoadBalancerRuleCmd; +import org.apache.cloudstack.api.command.user.resource.GetCloudIdentifierCmd; +import org.apache.cloudstack.api.command.user.resource.ListHypervisorsCmd; +import org.apache.cloudstack.api.command.user.resource.ListResourceLimitsCmd; +import org.apache.cloudstack.api.command.user.resource.UpdateResourceCountCmd; +import org.apache.cloudstack.api.command.user.resource.UpdateResourceLimitCmd; +import org.apache.cloudstack.api.command.user.securitygroup.AuthorizeSecurityGroupEgressCmd; +import org.apache.cloudstack.api.command.user.securitygroup.AuthorizeSecurityGroupIngressCmd; +import org.apache.cloudstack.api.command.user.securitygroup.CreateSecurityGroupCmd; +import org.apache.cloudstack.api.command.user.securitygroup.DeleteSecurityGroupCmd; +import org.apache.cloudstack.api.command.user.securitygroup.ListSecurityGroupsCmd; +import org.apache.cloudstack.api.command.user.securitygroup.RevokeSecurityGroupEgressCmd; +import org.apache.cloudstack.api.command.user.securitygroup.RevokeSecurityGroupIngressCmd; +import org.apache.cloudstack.api.command.user.snapshot.CreateSnapshotCmd; +import org.apache.cloudstack.api.command.user.snapshot.CreateSnapshotPolicyCmd; +import org.apache.cloudstack.api.command.user.snapshot.DeleteSnapshotCmd; +import org.apache.cloudstack.api.command.user.snapshot.DeleteSnapshotPoliciesCmd; +import org.apache.cloudstack.api.command.user.snapshot.ListSnapshotPoliciesCmd; +import org.apache.cloudstack.api.command.user.snapshot.ListSnapshotsCmd; +import org.apache.cloudstack.api.command.user.ssh.CreateSSHKeyPairCmd; +import org.apache.cloudstack.api.command.user.ssh.DeleteSSHKeyPairCmd; +import org.apache.cloudstack.api.command.user.ssh.ListSSHKeyPairsCmd; +import org.apache.cloudstack.api.command.user.ssh.RegisterSSHKeyPairCmd; +import org.apache.cloudstack.api.command.user.tag.CreateTagsCmd; +import org.apache.cloudstack.api.command.user.tag.DeleteTagsCmd; +import org.apache.cloudstack.api.command.user.tag.ListTagsCmd; +import org.apache.cloudstack.api.command.user.template.CopyTemplateCmd; +import org.apache.cloudstack.api.command.user.template.CreateTemplateCmd; +import org.apache.cloudstack.api.command.user.template.DeleteTemplateCmd; +import org.apache.cloudstack.api.command.user.template.ExtractTemplateCmd; +import org.apache.cloudstack.api.command.user.template.ListTemplatePermissionsCmd; +import org.apache.cloudstack.api.command.user.template.ListTemplatesCmd; +import org.apache.cloudstack.api.command.user.template.RegisterTemplateCmd; +import org.apache.cloudstack.api.command.user.template.UpdateTemplateCmd; +import org.apache.cloudstack.api.command.user.template.UpdateTemplatePermissionsCmd; +import org.apache.cloudstack.api.command.user.vm.AddIpToVmNicCmd; +import org.apache.cloudstack.api.command.user.vm.AddNicToVMCmd; +import org.apache.cloudstack.api.command.user.vm.DeployVMCmd; +import org.apache.cloudstack.api.command.user.vm.DestroyVMCmd; +import org.apache.cloudstack.api.command.user.vm.GetVMPasswordCmd; +import org.apache.cloudstack.api.command.user.vm.ListNicsCmd; +import org.apache.cloudstack.api.command.user.vm.ListVMsCmd; +import org.apache.cloudstack.api.command.user.vm.RebootVMCmd; +import org.apache.cloudstack.api.command.user.vm.RemoveIpFromVmNicCmd; +import org.apache.cloudstack.api.command.user.vm.RemoveNicFromVMCmd; +import org.apache.cloudstack.api.command.user.vm.ResetVMPasswordCmd; +import org.apache.cloudstack.api.command.user.vm.ResetVMSSHKeyCmd; +import org.apache.cloudstack.api.command.user.vm.RestoreVMCmd; +import org.apache.cloudstack.api.command.user.vm.ScaleVMCmd; +import org.apache.cloudstack.api.command.user.vm.StartVMCmd; +import org.apache.cloudstack.api.command.user.vm.StopVMCmd; +import org.apache.cloudstack.api.command.user.vm.UpdateDefaultNicForVMCmd; +import org.apache.cloudstack.api.command.user.vm.UpdateVMCmd; +import org.apache.cloudstack.api.command.user.vm.UpgradeVMCmd; +import org.apache.cloudstack.api.command.user.vmgroup.CreateVMGroupCmd; +import org.apache.cloudstack.api.command.user.vmgroup.DeleteVMGroupCmd; +import org.apache.cloudstack.api.command.user.vmgroup.ListVMGroupsCmd; +import org.apache.cloudstack.api.command.user.vmgroup.UpdateVMGroupCmd; +import org.apache.cloudstack.api.command.user.vmsnapshot.CreateVMSnapshotCmd; +import org.apache.cloudstack.api.command.user.vmsnapshot.DeleteVMSnapshotCmd; +import org.apache.cloudstack.api.command.user.vmsnapshot.ListVMSnapshotCmd; +import org.apache.cloudstack.api.command.user.vmsnapshot.RevertToVMSnapshotCmd; +import org.apache.cloudstack.api.command.user.volume.AttachVolumeCmd; +import org.apache.cloudstack.api.command.user.volume.CreateVolumeCmd; +import org.apache.cloudstack.api.command.user.volume.DeleteVolumeCmd; +import org.apache.cloudstack.api.command.user.volume.DetachVolumeCmd; +import org.apache.cloudstack.api.command.user.volume.ExtractVolumeCmd; +import org.apache.cloudstack.api.command.user.volume.ListVolumesCmd; +import org.apache.cloudstack.api.command.user.volume.MigrateVolumeCmd; +import org.apache.cloudstack.api.command.user.volume.ResizeVolumeCmd; +import org.apache.cloudstack.api.command.user.volume.UploadVolumeCmd; +import org.apache.cloudstack.api.command.user.vpc.CreateStaticRouteCmd; +import org.apache.cloudstack.api.command.user.vpc.CreateVPCCmd; +import org.apache.cloudstack.api.command.user.vpc.DeleteStaticRouteCmd; +import org.apache.cloudstack.api.command.user.vpc.DeleteVPCCmd; +import org.apache.cloudstack.api.command.user.vpc.ListPrivateGatewaysCmd; +import org.apache.cloudstack.api.command.user.vpc.ListStaticRoutesCmd; +import org.apache.cloudstack.api.command.user.vpc.ListVPCOfferingsCmd; +import org.apache.cloudstack.api.command.user.vpc.ListVPCsCmd; +import org.apache.cloudstack.api.command.user.vpc.RestartVPCCmd; +import org.apache.cloudstack.api.command.user.vpc.UpdateVPCCmd; +import org.apache.cloudstack.api.command.user.vpn.AddVpnUserCmd; +import org.apache.cloudstack.api.command.user.vpn.CreateRemoteAccessVpnCmd; +import org.apache.cloudstack.api.command.user.vpn.CreateVpnConnectionCmd; +import org.apache.cloudstack.api.command.user.vpn.CreateVpnCustomerGatewayCmd; +import org.apache.cloudstack.api.command.user.vpn.CreateVpnGatewayCmd; +import org.apache.cloudstack.api.command.user.vpn.DeleteRemoteAccessVpnCmd; +import org.apache.cloudstack.api.command.user.vpn.DeleteVpnConnectionCmd; +import org.apache.cloudstack.api.command.user.vpn.DeleteVpnCustomerGatewayCmd; +import org.apache.cloudstack.api.command.user.vpn.DeleteVpnGatewayCmd; +import org.apache.cloudstack.api.command.user.vpn.ListRemoteAccessVpnsCmd; +import org.apache.cloudstack.api.command.user.vpn.ListVpnConnectionsCmd; +import org.apache.cloudstack.api.command.user.vpn.ListVpnCustomerGatewaysCmd; +import org.apache.cloudstack.api.command.user.vpn.ListVpnGatewaysCmd; +import org.apache.cloudstack.api.command.user.vpn.ListVpnUsersCmd; +import org.apache.cloudstack.api.command.user.vpn.RemoveVpnUserCmd; +import org.apache.cloudstack.api.command.user.vpn.ResetVpnConnectionCmd; +import org.apache.cloudstack.api.command.user.vpn.UpdateVpnCustomerGatewayCmd; +import org.apache.cloudstack.api.command.user.zone.ListZonesByCmd; +import org.apache.cloudstack.api.response.ExtractResponse; +import org.apache.cloudstack.engine.subsystem.api.storage.DataStoreManager; +import org.apache.cloudstack.engine.subsystem.api.storage.StoragePoolAllocator; +import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDao; +import org.apache.cloudstack.storage.datastore.db.StoragePoolVO; +import org.apache.commons.codec.binary.Base64; +import org.apache.log4j.Logger; + import com.cloud.agent.AgentManager; import com.cloud.agent.api.GetVncPortAnswer; import com.cloud.agent.api.GetVncPortCommand; import com.cloud.agent.api.storage.CopyVolumeAnswer; import com.cloud.agent.api.storage.CopyVolumeCommand; +import com.cloud.agent.api.storage.CreateVolumeOVAAnswer; +import com.cloud.agent.api.storage.CreateVolumeOVACommand; import com.cloud.agent.manager.allocator.HostAllocator; import com.cloud.alert.Alert; import com.cloud.alert.AlertManager; import com.cloud.alert.AlertVO; import com.cloud.alert.dao.AlertDao; import com.cloud.api.ApiDBUtils; -import com.cloud.async.*; +import com.cloud.async.AsyncJobExecutor; +import com.cloud.async.AsyncJobManager; +import com.cloud.async.AsyncJobResult; +import com.cloud.async.AsyncJobVO; +import com.cloud.async.BaseAsyncJobExecutor; import com.cloud.capacity.Capacity; import com.cloud.capacity.CapacityVO; import com.cloud.capacity.dao.CapacityDao; import com.cloud.capacity.dao.CapacityDaoImpl.SummedCapacity; import com.cloud.cluster.ClusterManager; +import com.cloud.configuration.Config; +import com.cloud.configuration.Configuration; +import com.cloud.configuration.ConfigurationManager; +import com.cloud.configuration.ConfigurationVO; import com.cloud.configuration.dao.ConfigurationDao; import com.cloud.consoleproxy.ConsoleProxyManagementState; import com.cloud.consoleproxy.ConsoleProxyManager; -import com.cloud.dc.*; +import com.cloud.dc.AccountVlanMapVO; +import com.cloud.dc.ClusterVO; +import com.cloud.dc.DataCenterVO; +import com.cloud.dc.HostPodVO; +import com.cloud.dc.Pod; +import com.cloud.dc.PodVlanMapVO; +import com.cloud.dc.Vlan; import com.cloud.dc.Vlan.VlanType; -import com.cloud.dc.dao.*; +import com.cloud.dc.VlanVO; +import com.cloud.dc.dao.AccountVlanMapDao; +import com.cloud.dc.dao.ClusterDao; +import com.cloud.dc.dao.DataCenterDao; +import com.cloud.dc.dao.HostPodDao; +import com.cloud.dc.dao.PodVlanMapDao; +import com.cloud.dc.dao.VlanDao; import com.cloud.deploy.DataCenterDeployment; import com.cloud.deploy.DeploymentPlanner.ExcludeList; import com.cloud.domain.DomainVO; import com.cloud.domain.dao.DomainDao; import com.cloud.event.ActionEvent; +import com.cloud.event.ActionEventUtils; import com.cloud.event.EventTypes; import com.cloud.event.EventVO; import com.cloud.event.dao.EventDao; -import com.cloud.exception.*; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.OperationTimedoutException; +import com.cloud.exception.PermissionDeniedException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.exception.StorageUnavailableException; import com.cloud.ha.HighAvailabilityManager; import com.cloud.host.DetailVO; import com.cloud.host.Host; @@ -138,7 +489,12 @@ import com.cloud.hypervisor.dao.HypervisorCapabilitiesDao; import com.cloud.info.ConsoleProxyInfo; import com.cloud.keystore.KeystoreManager; import com.cloud.network.IpAddress; -import com.cloud.network.dao.*; +import com.cloud.network.dao.IPAddressDao; +import com.cloud.network.dao.IPAddressVO; +import com.cloud.network.dao.LoadBalancerDao; +import com.cloud.network.dao.LoadBalancerVO; +import com.cloud.network.dao.NetworkDao; +import com.cloud.network.dao.NetworkVO; import com.cloud.org.Cluster; import com.cloud.org.Grouping.AllocationState; import com.cloud.projects.Project; @@ -148,9 +504,28 @@ import com.cloud.resource.ResourceManager; import com.cloud.server.ResourceTag.TaggedResourceType; import com.cloud.server.auth.UserAuthenticator; import com.cloud.service.dao.ServiceOfferingDao; -import com.cloud.storage.*; +import com.cloud.storage.DiskOfferingVO; +import com.cloud.storage.GuestOS; +import com.cloud.storage.GuestOSCategoryVO; +import com.cloud.storage.GuestOSVO; +import com.cloud.storage.GuestOsCategory; +import com.cloud.storage.Storage; import com.cloud.storage.Storage.ImageFormat; +import com.cloud.storage.StorageManager; +import com.cloud.storage.StoragePool; +import com.cloud.storage.Upload; import com.cloud.storage.Upload.Mode; +import com.cloud.storage.UploadVO; +import com.cloud.storage.VMTemplateVO; +import com.cloud.storage.Volume; +import com.cloud.storage.VolumeManager; +import com.cloud.storage.VolumeVO; +import com.cloud.storage.dao.DiskOfferingDao; +import com.cloud.storage.dao.GuestOSCategoryDao; +import com.cloud.storage.dao.GuestOSDao; +import com.cloud.storage.dao.UploadDao; +import com.cloud.storage.dao.VMTemplateDao; +import com.cloud.storage.dao.VolumeDao; import com.cloud.storage.s3.S3Manager; import com.cloud.storage.secondary.SecondaryStorageVmManager; import com.cloud.storage.snapshot.SnapshotManager; @@ -160,7 +535,13 @@ import com.cloud.tags.ResourceTagVO; import com.cloud.tags.dao.ResourceTagDao; import com.cloud.template.TemplateManager; import com.cloud.template.VirtualMachineTemplate.TemplateFilter; -import com.cloud.user.*; +import com.cloud.user.Account; +import com.cloud.user.AccountManager; +import com.cloud.user.SSHKeyPair; +import com.cloud.user.SSHKeyPairVO; +import com.cloud.user.User; +import com.cloud.user.UserContext; +import com.cloud.user.UserVO; import com.cloud.user.dao.AccountDao; import com.cloud.user.dao.SSHKeyPairDao; import com.cloud.user.dao.UserDao; @@ -173,15 +554,36 @@ import com.cloud.utils.component.ComponentLifecycle; import com.cloud.utils.component.ManagerBase; import com.cloud.utils.concurrency.NamedThreadFactory; import com.cloud.utils.crypt.DBEncryptionUtil; -import com.cloud.utils.db.*; +import com.cloud.utils.db.DB; +import com.cloud.utils.db.Filter; +import com.cloud.utils.db.GlobalLock; +import com.cloud.utils.db.JoinBuilder; import com.cloud.utils.db.JoinBuilder.JoinType; +import com.cloud.utils.db.SearchBuilder; +import com.cloud.utils.db.SearchCriteria; +import com.cloud.utils.db.Transaction; import com.cloud.utils.exception.CloudRuntimeException; import com.cloud.utils.net.MacAddress; import com.cloud.utils.net.NetUtils; import com.cloud.utils.ssh.SSHKeysHelper; -import com.cloud.vm.*; +import com.cloud.vm.ConsoleProxyVO; +import com.cloud.vm.DiskProfile; +import com.cloud.vm.InstanceGroupVO; +import com.cloud.vm.SecondaryStorageVmVO; +import com.cloud.vm.UserVmVO; +import com.cloud.vm.VMInstanceVO; +import com.cloud.vm.VirtualMachine; import com.cloud.vm.VirtualMachine.State; -import com.cloud.vm.dao.*; +import com.cloud.vm.VirtualMachineManager; +import com.cloud.vm.VirtualMachineProfile; +import com.cloud.vm.VirtualMachineProfileImpl; +import com.cloud.vm.dao.ConsoleProxyDao; +import com.cloud.vm.dao.DomainRouterDao; +import com.cloud.vm.dao.InstanceGroupDao; +import com.cloud.vm.dao.SecondaryStorageVmDao; +import com.cloud.vm.dao.UserVmDao; +import com.cloud.vm.dao.VMInstanceDao; + import edu.emory.mathcs.backport.java.util.Arrays; import edu.emory.mathcs.backport.java.util.Collections; import org.apache.cloudstack.acl.ControlledEntity; @@ -201,7 +603,6 @@ import org.apache.cloudstack.api.command.admin.pod.CreatePodCmd; import org.apache.cloudstack.api.command.admin.pod.DeletePodCmd; import org.apache.cloudstack.api.command.admin.pod.ListPodsByCmd; import org.apache.cloudstack.api.command.admin.pod.UpdatePodCmd; -import org.apache.cloudstack.api.command.admin.region.ListPortableIpRangesCmd; import org.apache.cloudstack.api.command.admin.swift.AddSwiftCmd; import org.apache.cloudstack.api.command.admin.swift.ListSwiftsCmd; import org.apache.cloudstack.api.command.admin.template.PrepareTemplateCmd; @@ -250,7 +651,6 @@ import org.apache.cloudstack.api.command.user.vmgroup.UpdateVMGroupCmd; import org.apache.cloudstack.api.command.user.vmsnapshot.CreateVMSnapshotCmd; import org.apache.cloudstack.api.command.user.vmsnapshot.DeleteVMSnapshotCmd; import org.apache.cloudstack.api.command.user.vmsnapshot.ListVMSnapshotCmd; -import org.apache.cloudstack.api.command.user.vmsnapshot.RevertToSnapshotCmd; import org.apache.cloudstack.api.command.user.zone.ListZonesByCmd; import org.apache.cloudstack.engine.subsystem.api.storage.DataStoreManager; import org.apache.cloudstack.engine.subsystem.api.storage.StoragePoolAllocator; @@ -612,48 +1012,69 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe @Override public Pair, Integer> searchForClusters(ListClustersCmd cmd) { - Filter searchFilter = new Filter(ClusterVO.class, "id", true, cmd.getStartIndex(), cmd.getPageSizeVal()); - SearchCriteria sc = _clusterDao.createSearchCriteria(); - - Object id = cmd.getId(); + Object id = cmd.getId(); Object name = cmd.getClusterName(); Object podId = cmd.getPodId(); Long zoneId = cmd.getZoneId(); Object hypervisorType = cmd.getHypervisorType(); Object clusterType = cmd.getClusterType(); Object allocationState = cmd.getAllocationState(); + String zoneType = cmd.getZoneType(); String keyword = cmd.getKeyword(); - zoneId = _accountMgr.checkAccessAndSpecifyAuthority(UserContext.current().getCaller(), zoneId); - + + + Filter searchFilter = new Filter(ClusterVO.class, "id", true, cmd.getStartIndex(), cmd.getPageSizeVal()); + + SearchBuilder sb = _clusterDao.createSearchBuilder(); + sb.and("id", sb.entity().getId(), SearchCriteria.Op.EQ); + sb.and("name", sb.entity().getName(), SearchCriteria.Op.LIKE); + sb.and("podId", sb.entity().getPodId(), SearchCriteria.Op.EQ); + sb.and("dataCenterId", sb.entity().getDataCenterId(), SearchCriteria.Op.EQ); + sb.and("hypervisorType", sb.entity().getHypervisorType(), SearchCriteria.Op.EQ); + sb.and("clusterType", sb.entity().getClusterType(), SearchCriteria.Op.EQ); + sb.and("allocationState", sb.entity().getAllocationState(), SearchCriteria.Op.EQ); + + if(zoneType != null) { + SearchBuilder zoneSb = _dcDao.createSearchBuilder(); + zoneSb.and("zoneNetworkType", zoneSb.entity().getNetworkType(), SearchCriteria.Op.EQ); + sb.join("zoneSb", zoneSb, sb.entity().getDataCenterId(), zoneSb.entity().getId(), JoinBuilder.JoinType.INNER); + } + + + SearchCriteria sc = sb.create(); if (id != null) { - sc.addAnd("id", SearchCriteria.Op.EQ, id); + sc.setParameters("id", id); } if (name != null) { - sc.addAnd("name", SearchCriteria.Op.LIKE, "%" + name + "%"); + sc.setParameters("name", "%" + name + "%"); } if (podId != null) { - sc.addAnd("podId", SearchCriteria.Op.EQ, podId); + sc.setParameters("podId", podId); } if (zoneId != null) { - sc.addAnd("dataCenterId", SearchCriteria.Op.EQ, zoneId); + sc.setParameters("dataCenterId", zoneId); } if (hypervisorType != null) { - sc.addAnd("hypervisorType", SearchCriteria.Op.EQ, hypervisorType); + sc.setParameters("hypervisorType", hypervisorType); } if (clusterType != null) { - sc.addAnd("clusterType", SearchCriteria.Op.EQ, clusterType); + sc.setParameters("clusterType", clusterType); } if (allocationState != null) { - sc.addAnd("allocationState", SearchCriteria.Op.EQ, allocationState); + sc.setParameters("allocationState", allocationState); } + if(zoneType != null) { + sc.setJoinParameters("zoneSb", "zoneNetworkType", zoneType); + } + if (keyword != null) { SearchCriteria ssc = _clusterDao.createSearchCriteria(); ssc.addOr("name", SearchCriteria.Op.LIKE, "%" + keyword + "%"); @@ -1249,16 +1670,41 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe Object name = cmd.getConfigName(); Object category = cmd.getCategory(); Object keyword = cmd.getKeyword(); - Long id = cmd.getId(); - String scope = cmd.getScope(); + Long zoneId = cmd.getZoneId(); + Long clusterId = cmd.getClusterId(); + Long storagepoolId = cmd.getStoragepoolId(); + Long accountId = cmd.getAccountId(); + String scope = null; + Long id = null; + int paramCountCheck = 0; - if (scope!= null && !scope.isEmpty()) { + if (zoneId != null) { + scope = Config.ConfigurationParameterScope.zone.toString(); + id = zoneId; + paramCountCheck++; + } + if (clusterId != null) { + scope = Config.ConfigurationParameterScope.cluster.toString(); + id = clusterId; + paramCountCheck++; + } + if (accountId != null) { + scope = Config.ConfigurationParameterScope.account.toString(); + id = accountId; + paramCountCheck++; + } + if (storagepoolId != null) { + scope = Config.ConfigurationParameterScope.storagepool.toString(); + id = storagepoolId; + paramCountCheck++; + } + + if (paramCountCheck > 1) { + throw new InvalidParameterValueException("cannot handle multiple IDs, provide only one ID corresponding to the scope"); + } + + if (scope != null && !scope.isEmpty()) { // getting the list of parameters at requested scope - try { - Config.ConfigurationParameterScope.valueOf(scope.toLowerCase()); - } catch (Exception e ) { - throw new InvalidParameterValueException("Invalid scope " + scope + " while listing configuration parameters"); - } if (id == null) { throw new InvalidParameterValueException("Invalid id null, id is needed corresponding to the scope"); } @@ -2206,6 +2652,9 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe cmdList.add(UpdateNetworkServiceProviderCmd.class); cmdList.add(UpdatePhysicalNetworkCmd.class); cmdList.add(UpdateStorageNetworkIpRangeCmd.class); + cmdList.add(DedicateGuestVlanRangeCmd.class); + cmdList.add(ListDedicatedGuestVlanRangesCmd.class); + cmdList.add(ReleaseDedicatedGuestVlanRangeCmd.class); cmdList.add(CreateDiskOfferingCmd.class); cmdList.add(CreateServiceOfferingCmd.class); cmdList.add(DeleteDiskOfferingCmd.class); @@ -2472,7 +2921,7 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe cmdList.add(ListZonesByCmd.class); cmdList.add(ListVMSnapshotCmd.class); cmdList.add(CreateVMSnapshotCmd.class); - cmdList.add(RevertToSnapshotCmd.class); + cmdList.add(RevertToVMSnapshotCmd.class); cmdList.add(DeleteVMSnapshotCmd.class); cmdList.add(AddIpToVmNicCmd.class); cmdList.add(RemoveIpFromVmNicCmd.class); @@ -2487,6 +2936,12 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe cmdList.add(AssignToGlobalLoadBalancerRuleCmd.class); cmdList.add(RemoveFromGlobalLoadBalancerRuleCmd.class); cmdList.add(ListStorageProvidersCmd.class); + cmdList.add(CreateApplicationLoadBalancerCmd.class); + cmdList.add(ListApplicationLoadBalancersCmd.class); + cmdList.add(DeleteApplicationLoadBalancerCmd.class); + cmdList.add(ConfigureInternalLoadBalancerElementCmd.class); + cmdList.add(CreateInternalLoadBalancerElementCmd.class); + cmdList.add(ListInternalLoadBalancerElementsCmd.class); cmdList.add(CreateAffinityGroupCmd.class); cmdList.add(DeleteAffinityGroupCmd.class); cmdList.add(ListAffinityGroupsCmd.class); @@ -2495,6 +2950,11 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe cmdList.add(CreatePortableIpRangeCmd.class); cmdList.add(DeletePortableIpRangeCmd.class); cmdList.add(ListPortableIpRangesCmd.class); + cmdList.add(StopInternalLBVMCmd.class); + cmdList.add(StartInternalLBVMCmd.class); + cmdList.add(ListInternalLBVMsCmd.class); + cmdList.add(ListNetworkIsolationMethodsCmd.class); + cmdList.add(ListNetworkIsolationMethodsCmd.class); return cmdList; } @@ -3034,7 +3494,7 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe List extractURLList = _uploadDao.listByTypeUploadStatus(volumeId, Upload.Type.VOLUME, UploadVO.Status.DOWNLOAD_URL_CREATED); if (extractMode == Upload.Mode.HTTP_DOWNLOAD && extractURLList.size() > 0) { - return extractURLList.get(0).getId(); // If download url already + return extractURLList.get(0).getId(); // If download url already Note: volss // exists then return } else { UploadVO uploadJob = _uploadMonitor.createNewUploadEntry(sserver.getId(), volumeId, UploadVO.Status.COPY_IN_PROGRESS, Upload.Type.VOLUME, @@ -3086,6 +3546,19 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe } String volumeLocalPath = "volumes/" + volume.getId() + "/" + cvAnswer.getVolumePath() + "." + getFormatForPool(srcPool); + //Fang: volss, handle the ova special case; + if (getFormatForPool(srcPool) == "ova") { + CreateVolumeOVACommand cvOVACmd = new CreateVolumeOVACommand(secondaryStorageURL, volumeLocalPath, cvAnswer.getVolumePath(), srcPool, copyvolumewait); + CreateVolumeOVAAnswer OVAanswer = null; + + try { + cvOVACmd.setContextParam("hypervisor", HypervisorType.VMware.toString()); + OVAanswer = (CreateVolumeOVAAnswer) _storageMgr.sendToPool(srcPool, cvOVACmd); //Fang: for extract volume, create the ova file here; + + } catch (StorageUnavailableException e) { + s_logger.debug("Storage unavailable"); + } + } // Update the DB that volume is copied and volumePath uploadJob.setUploadState(UploadVO.Status.COPY_COMPLETE); uploadJob.setLastUpdated(new Date()); diff --git a/server/src/com/cloud/servlet/ConsoleProxyServlet.java b/server/src/com/cloud/servlet/ConsoleProxyServlet.java index ebb91746268..097986bda62 100644 --- a/server/src/com/cloud/servlet/ConsoleProxyServlet.java +++ b/server/src/com/cloud/servlet/ConsoleProxyServlet.java @@ -73,7 +73,7 @@ public class ConsoleProxyServlet extends HttpServlet { @Inject AccountManager _accountMgr; @Inject VirtualMachineManager _vmMgr; @Inject ManagementServer _ms; - @Inject IdentityService _identityService; + @Inject IdentityService _identityService; static ManagementServer s_ms; @@ -81,13 +81,13 @@ public class ConsoleProxyServlet extends HttpServlet { public ConsoleProxyServlet() { } - + @Override public void init(ServletConfig config) throws ServletException { - SpringBeanAutowiringSupport.processInjectionBasedOnServletContext(this, config.getServletContext()); + SpringBeanAutowiringSupport.processInjectionBasedOnServletContext(this, config.getServletContext()); s_ms = _ms; } - + @Override protected void doPost(HttpServletRequest req, HttpServletResponse resp) { doGet(req, resp); @@ -274,7 +274,7 @@ public class ConsoleProxyServlet extends HttpServlet { private void handleAuthRequest(HttpServletRequest req, HttpServletResponse resp, long vmId) { - // TODO authentication channel between console proxy VM and management server needs to be secured, + // TODO authentication channel between console proxy VM and management server needs to be secured, // the data is now being sent through private network, but this is apparently not enough VMInstanceVO vm = _vmMgr.findById(vmId); if(vm == null) { @@ -334,11 +334,11 @@ public class ConsoleProxyServlet extends HttpServlet { private String getEncryptorPassword() { String key = _ms.getEncryptionKey(); String iv = _ms.getEncryptionIV(); - + ConsoleProxyPasswordBasedEncryptor.KeyIVPair keyIvPair = new ConsoleProxyPasswordBasedEncryptor.KeyIVPair(key, iv); return _gson.toJson(keyIvPair); } - + private String composeThumbnailUrl(String rootUrl, VMInstanceVO vm, HostVO hostVo, int w, int h) { StringBuffer sb = new StringBuffer(rootUrl); @@ -385,8 +385,7 @@ public class ConsoleProxyServlet extends HttpServlet { Ternary parsedHostInfo = parseHostInfo(portInfo.first()); String sid = vm.getVncPassword(); - String tag = String.valueOf(vm.getId()); - tag = _identityService.getIdentityUuid("vm_instance", tag); + String tag = vm.getUuid(); String ticket = genAccessTicket(host, String.valueOf(portInfo.second()), sid, tag); ConsoleProxyPasswordBasedEncryptor encryptor = new ConsoleProxyPasswordBasedEncryptor(getEncryptorPassword()); ConsoleProxyClientParam param = new ConsoleProxyClientParam(); @@ -473,12 +472,12 @@ public class ConsoleProxyServlet extends HttpServlet { } catch (PermissionDeniedException ex) { if (accountObj.getType() == Account.ACCOUNT_TYPE_NORMAL) { if (s_logger.isDebugEnabled()) { - s_logger.debug("VM access is denied. VM owner account " + vm.getAccountId() + s_logger.debug("VM access is denied. VM owner account " + vm.getAccountId() + " does not match the account id in session " + accountObj.getId() + " and caller is a normal user"); } } else if(accountObj.getType() == Account.ACCOUNT_TYPE_DOMAIN_ADMIN || accountObj.getType() == Account.ACCOUNT_TYPE_READ_ONLY_ADMIN) { if(s_logger.isDebugEnabled()) { - s_logger.debug("VM access is denied. VM owner account " + vm.getAccountId() + s_logger.debug("VM access is denied. VM owner account " + vm.getAccountId() + " does not match the account id in session " + accountObj.getId() + " and the domain-admin caller does not manage the target domain"); } } @@ -515,7 +514,7 @@ public class ConsoleProxyServlet extends HttpServlet { account = _accountMgr.getAccount(user.getAccountId()); } - if ((user == null) || (user.getRemoved() != null) || !user.getState().equals(Account.State.enabled) + if ((user == null) || (user.getRemoved() != null) || !user.getState().equals(Account.State.enabled) || (account == null) || !account.getState().equals(Account.State.enabled)) { s_logger.warn("Deleted/Disabled/Locked user with id=" + userId + " attempting to access public API"); return false; @@ -586,7 +585,7 @@ public class ConsoleProxyServlet extends HttpServlet { if (!user.getState().equals(Account.State.enabled) || !account.getState().equals(Account.State.enabled)) { s_logger.debug("disabled or locked user accessing the api, userid = " + user.getId() + "; name = " + user.getUsername() + "; state: " + user.getState() + "; accountState: " + account.getState()); return false; - } + } // verify secret key exists secretKey = user.getSecretKey(); @@ -632,10 +631,10 @@ public class ConsoleProxyServlet extends HttpServlet { case '>': sb.append(">"); break; case '&': sb.append("&"); break; case '"': sb.append("""); break; - case ' ': sb.append(" ");break; + case ' ': sb.append(" ");break; default: sb.append(c); break; } } return sb.toString(); - } + } } diff --git a/server/src/com/cloud/storage/OCFS2ManagerImpl.java b/server/src/com/cloud/storage/OCFS2ManagerImpl.java index 476bf04cae9..5eb9a4a5c44 100755 --- a/server/src/com/cloud/storage/OCFS2ManagerImpl.java +++ b/server/src/com/cloud/storage/OCFS2ManagerImpl.java @@ -56,7 +56,7 @@ import com.cloud.utils.exception.CloudRuntimeException; @Local(value ={OCFS2Manager.class}) public class OCFS2ManagerImpl extends ManagerBase implements OCFS2Manager, ResourceListener { private static final Logger s_logger = Logger.getLogger(OCFS2ManagerImpl.class); - + @Inject ClusterDetailsDao _clusterDetailsDao; @Inject AgentManager _agentMgr; @Inject HostDao _hostDao; @@ -64,7 +64,7 @@ public class OCFS2ManagerImpl extends ManagerBase implements OCFS2Manager, Resou @Inject ResourceManager _resourceMgr; @Inject StoragePoolHostDao _poolHostDao; @Inject PrimaryDataStoreDao _poolDao; - + @Override public boolean configure(String name, Map params) throws ConfigurationException { return true; @@ -96,8 +96,8 @@ public class OCFS2ManagerImpl extends ManagerBase implements OCFS2Manager, Resou } return lst; } - - + + private boolean prepareNodes(String clusterName, List hosts) { PrepareOCFS2NodesCommand cmd = new PrepareOCFS2NodesCommand(clusterName, marshalNodes(hosts)); for (HostVO h : hosts) { @@ -111,36 +111,36 @@ public class OCFS2ManagerImpl extends ManagerBase implements OCFS2Manager, Resou return false; } } - + return true; } - + private String getClusterName(Long clusterId) { ClusterVO cluster = _clusterDao.findById(clusterId); if (cluster == null) { throw new CloudRuntimeException("Cannot get cluster for id " + clusterId); } - - String clusterName = "OvmCluster" + cluster.getId(); + + String clusterName = "OvmCluster" + cluster.getId(); return clusterName; } - + @Override public boolean prepareNodes(List hosts, StoragePool pool) { if (pool.getPoolType() != StoragePoolType.OCFS2) { throw new CloudRuntimeException("None OCFS2 storage pool is getting into OCFS2 manager!"); } - + return prepareNodes(getClusterName(pool.getClusterId()), hosts); } @Override - public boolean prepareNodes(Long clusterId) { + public boolean prepareNodes(Long clusterId) { ClusterVO cluster = _clusterDao.findById(clusterId); if (cluster == null) { throw new CloudRuntimeException("Cannot find cluster for ID " + clusterId); } - + SearchCriteriaService sc = SearchCriteria2.create(HostVO.class); sc.addAnd(sc.getEntity().getClusterId(), Op.EQ, clusterId); sc.addAnd(sc.getEntity().getPodId(), Op.EQ, cluster.getPodId()); @@ -151,36 +151,36 @@ public class OCFS2ManagerImpl extends ManagerBase implements OCFS2Manager, Resou s_logger.debug("There is no host in cluster " + clusterId + ", no need to prepare OCFS2 nodes"); return true; } - + return prepareNodes(getClusterName(clusterId), hosts); } @Override public void processDiscoverEventBefore(Long dcid, Long podId, Long clusterId, URI uri, String username, String password, List hostTags) { // TODO Auto-generated method stub - + } @Override public void processDiscoverEventAfter(Map> resources) { // TODO Auto-generated method stub - + } @Override - public void processDeleteHostEventBefore(HostVO host) { + public void processDeleteHostEventBefore(Host host) { // TODO Auto-generated method stub - + } @Override - public void processDeletHostEventAfter(HostVO host) { + public void processDeletHostEventAfter(Host host) { String errMsg = String.format("Prepare OCFS2 nodes failed after delete host %1$s (zone:%2$s, pod:%3$s, cluster:%4$s", host.getId(), host.getDataCenterId(), host.getPodId(), host.getClusterId()); - + if (host.getHypervisorType() != HypervisorType.Ovm) { return; } - + boolean hasOcfs2 = false; List poolRefs = _poolHostDao.listByHostId(host.getId()); for (StoragePoolHostVO poolRef : poolRefs) { @@ -205,24 +205,24 @@ public class OCFS2ManagerImpl extends ManagerBase implements OCFS2Manager, Resou @Override public void processCancelMaintenaceEventBefore(Long hostId) { // TODO Auto-generated method stub - + } @Override public void processCancelMaintenaceEventAfter(Long hostId) { // TODO Auto-generated method stub - + } @Override public void processPrepareMaintenaceEventBefore(Long hostId) { // TODO Auto-generated method stub - + } @Override public void processPrepareMaintenaceEventAfter(Long hostId) { // TODO Auto-generated method stub - + } } diff --git a/server/src/com/cloud/storage/StorageManager.java b/server/src/com/cloud/storage/StorageManager.java index 6026cd9c0fc..d49a7f86e94 100755 --- a/server/src/com/cloud/storage/StorageManager.java +++ b/server/src/com/cloud/storage/StorageManager.java @@ -16,6 +16,7 @@ // under the License. package com.cloud.storage; +import java.math.BigDecimal; import java.util.List; import java.util.Set; @@ -120,4 +121,5 @@ public interface StorageManager extends StorageService { DataStore createLocalStorage(Host host, StoragePoolInfo poolInfo) throws ConnectionException; + BigDecimal getStorageOverProvisioningFactor(Long dcId); } diff --git a/server/src/com/cloud/storage/StorageManagerImpl.java b/server/src/com/cloud/storage/StorageManagerImpl.java index a182e39dd86..1d4dcefad92 100755 --- a/server/src/com/cloud/storage/StorageManagerImpl.java +++ b/server/src/com/cloud/storage/StorageManagerImpl.java @@ -40,6 +40,7 @@ import javax.ejb.Local; import javax.inject.Inject; import javax.naming.ConfigurationException; +import com.cloud.server.ConfigurationServer; import org.apache.cloudstack.api.command.admin.storage.CancelPrimaryStorageMaintenanceCmd; import org.apache.cloudstack.api.command.admin.storage.CreateStoragePoolCmd; import org.apache.cloudstack.api.command.admin.storage.DeletePoolCmd; @@ -292,9 +293,13 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C SnapshotDataFactory snapshotFactory; @Inject protected HypervisorCapabilitiesDao _hypervisorCapabilitiesDao; + @Inject + ConfigurationServer _configServer; @Inject protected ResourceTagDao _resourceTagDao; + + protected List _storagePoolAllocators; public List getStoragePoolAllocators() { return _storagePoolAllocators; @@ -327,15 +332,12 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C protected int _retry = 2; protected int _pingInterval = 60; // seconds protected int _hostRetry; - protected BigDecimal _overProvisioningFactor = new BigDecimal(1); + //protected BigDecimal _overProvisioningFactor = new BigDecimal(1); private long _maxVolumeSizeInGb; private long _serverId; private int _customDiskOfferingMinSize = 1; private int _customDiskOfferingMaxSize = 1024; - private double _storageUsedThreshold = 1.0d; - private double _storageAllocatedThreshold = 1.0d; - protected BigDecimal _storageOverprovisioningFactor = new BigDecimal(1); private Map hostListeners = new HashMap(); private boolean _recreateSystemVmEnabled; @@ -535,12 +537,6 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C Map configs = _configDao.getConfiguration( "management-server", params); - String overProvisioningFactorStr = configs - .get("storage.overprovisioning.factor"); - if (overProvisioningFactorStr != null) { - _overProvisioningFactor = new BigDecimal(overProvisioningFactorStr); - } - _retry = NumbersUtil.parseInt(configs.get(Config.StartRetry.key()), 10); _pingInterval = NumbersUtil.parseInt(configs.get("ping.interval"), 60); _hostRetry = NumbersUtil.parseInt(configs.get("host.retry"), 2); @@ -576,24 +572,6 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C String time = configs.get("storage.cleanup.interval"); _storageCleanupInterval = NumbersUtil.parseInt(time, 86400); - String storageUsedThreshold = _configDao - .getValue(Config.StorageCapacityDisableThreshold.key()); - if (storageUsedThreshold != null) { - _storageUsedThreshold = Double.parseDouble(storageUsedThreshold); - } - - String storageAllocatedThreshold = _configDao - .getValue(Config.StorageAllocatedCapacityDisableThreshold.key()); - if (storageAllocatedThreshold != null) { - _storageAllocatedThreshold = Double - .parseDouble(storageAllocatedThreshold); - } - - String globalStorageOverprovisioningFactor = configs - .get("storage.overprovisioning.factor"); - _storageOverprovisioningFactor = new BigDecimal(NumbersUtil.parseFloat( - globalStorageOverprovisioningFactor, 2.0f)); - s_logger.info("Storage cleanup enabled: " + _storageCleanupEnabled + ", interval: " + _storageCleanupInterval + ", template cleanup enabled: " + _templateCleanupEnabled); @@ -979,6 +957,11 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C listener.hostConnect(hostId, pool.getId()); } + @Override + public BigDecimal getStorageOverProvisioningFactor(Long dcId){ + return new BigDecimal(_configServer.getConfigValue(Config.StorageOverprovisioningFactor.key(), Config.ConfigurationParameterScope.zone.toString(), dcId)); + } + @Override public void createCapacityEntry(StoragePoolVO storagePool, short capacityType, long allocated) { SearchCriteria capacitySC = _capacityDao.createSearchCriteria(); @@ -990,7 +973,8 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C long totalOverProvCapacity; if (storagePool.getPoolType() == StoragePoolType.NetworkFilesystem) { - totalOverProvCapacity = _overProvisioningFactor.multiply(new BigDecimal(storagePool.getCapacityBytes())).longValue();// All this for the inaccuracy of floats for big number multiplication. + BigDecimal overProvFactor = getStorageOverProvisioningFactor(storagePool.getDataCenterId()); + totalOverProvCapacity = overProvFactor.multiply(new BigDecimal(storagePool.getCapacityBytes())).longValue();// All this for the inaccuracy of floats for big number multiplication. } else { totalOverProvCapacity = storagePool.getCapacityBytes(); } @@ -1731,6 +1715,7 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C private boolean checkUsagedSpace(StoragePool pool) { StatsCollector sc = StatsCollector.getInstance(); + double storageUsedThreshold = Double.parseDouble(_configServer.getConfigValue(Config.StorageCapacityDisableThreshold.key(), Config.ConfigurationParameterScope.zone.toString(), pool.getDataCenterId())); if (sc != null) { long totalSize = pool.getCapacityBytes(); StorageStats stats = sc.getStoragePoolStats(pool.getId()); @@ -1745,16 +1730,16 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C + pool.getCapacityBytes() + ", usedBytes: " + stats.getByteUsed() + ", usedPct: " + usedPercentage + ", disable threshold: " - + _storageUsedThreshold); + + storageUsedThreshold); } - if (usedPercentage >= _storageUsedThreshold) { + if (usedPercentage >= storageUsedThreshold) { if (s_logger.isDebugEnabled()) { s_logger.debug("Insufficient space on pool: " + pool.getId() + " since its usage percentage: " + usedPercentage + " has crossed the pool.storage.capacity.disablethreshold: " - + _storageUsedThreshold); + + storageUsedThreshold); } return false; } @@ -1793,12 +1778,13 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C long totalOverProvCapacity; if (pool.getPoolType() == StoragePoolType.NetworkFilesystem) { - totalOverProvCapacity = _storageOverprovisioningFactor.multiply( + totalOverProvCapacity = getStorageOverProvisioningFactor(pool.getDataCenterId()).multiply( new BigDecimal(pool.getCapacityBytes())).longValue(); } else { totalOverProvCapacity = pool.getCapacityBytes(); } + double storageAllocatedThreshold = Double.parseDouble(_configServer.getConfigValue(Config.StorageAllocatedCapacityDisableThreshold.key(), Config.ConfigurationParameterScope.zone.toString(), pool.getDataCenterId())); if (s_logger.isDebugEnabled()) { s_logger.debug("Checking pool: " + pool.getId() + " for volume allocation " + volumes.toString() @@ -1806,12 +1792,12 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C + ", totalAllocatedSize : " + allocatedSizeWithtemplate + ", askingSize : " + totalAskingSize + ", allocated disable threshold: " - + _storageAllocatedThreshold); + + storageAllocatedThreshold); } double usedPercentage = (allocatedSizeWithtemplate + totalAskingSize) / (double) (totalOverProvCapacity); - if (usedPercentage > _storageAllocatedThreshold) { + if (usedPercentage > storageAllocatedThreshold) { if (s_logger.isDebugEnabled()) { s_logger.debug("Insufficient un-allocated capacity on: " + pool.getId() @@ -1820,7 +1806,7 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C + " since its allocated percentage: " + usedPercentage + " has crossed the allocated pool.storage.allocated.capacity.disablethreshold: " - + _storageAllocatedThreshold + ", skipping this pool"); + + storageAllocatedThreshold + ", skipping this pool"); } return false; } diff --git a/server/src/com/cloud/storage/download/DownloadMonitorImpl.java b/server/src/com/cloud/storage/download/DownloadMonitorImpl.java index 5d7a2106e6a..220cbffd5a3 100755 --- a/server/src/com/cloud/storage/download/DownloadMonitorImpl.java +++ b/server/src/com/cloud/storage/download/DownloadMonitorImpl.java @@ -875,7 +875,9 @@ public class DownloadMonitorImpl extends ManagerBase implements DownloadMonitor tmpltHost.setPhysicalSize(tmpltInfo.getPhysicalSize()); tmpltHost.setLastUpdated(new Date()); - if (tmpltInfo.getSize() > 0) { + // Skipping limit checks for SYSTEM Account and for the templates created from volumes or snapshots + // which already got checked and incremented during createTemplate API call. + if (tmpltInfo.getSize() > 0 && tmplt.getAccountId() != Account.ACCOUNT_ID_SYSTEM && tmplt.getUrl() != null) { long accountId = tmplt.getAccountId(); try { _resourceLimitMgr.checkResourceLimit(_accountMgr.getAccount(accountId), diff --git a/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java b/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java index 7dafe4ac865..26aae48ba38 100755 --- a/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java +++ b/server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java @@ -48,7 +48,7 @@ import com.cloud.agent.api.Command; import com.cloud.agent.api.DeleteSnapshotBackupCommand; import com.cloud.agent.api.DeleteSnapshotsDirCommand; import com.cloud.agent.api.DownloadSnapshotFromS3Command; -import com.cloud.agent.api.downloadSnapshotFromSwiftCommand; +import com.cloud.agent.api.DownloadSnapshotFromSwiftCommand; import com.cloud.agent.api.to.S3TO; import com.cloud.agent.api.to.SwiftTO; import com.cloud.alert.AlertManager; @@ -384,7 +384,7 @@ public class SnapshotManagerImpl extends ManagerBase implements SnapshotManager, String parent = null; try { for (String backupUuid : BackupUuids) { - downloadSnapshotFromSwiftCommand cmd = new downloadSnapshotFromSwiftCommand(swift, secondaryStoragePoolUrl, dcId, accountId, volumeId, parent, backupUuid, _backupsnapshotwait); + DownloadSnapshotFromSwiftCommand cmd = new DownloadSnapshotFromSwiftCommand(swift, secondaryStoragePoolUrl, dcId, accountId, volumeId, parent, backupUuid, _backupsnapshotwait); Answer answer = _agentMgr.sendToSSVM(dcId, cmd); if ((answer == null) || !answer.getResult()) { throw new CloudRuntimeException("downloadSnapshotsFromSwift failed "); diff --git a/server/src/com/cloud/template/HypervisorTemplateAdapter.java b/server/src/com/cloud/template/HypervisorTemplateAdapter.java index 491900b44e6..322f32eacdf 100755 --- a/server/src/com/cloud/template/HypervisorTemplateAdapter.java +++ b/server/src/com/cloud/template/HypervisorTemplateAdapter.java @@ -30,6 +30,9 @@ import javax.inject.Inject; import org.apache.cloudstack.api.command.user.iso.DeleteIsoCmd; import org.apache.cloudstack.api.command.user.iso.RegisterIsoCmd; import org.apache.cloudstack.api.command.user.template.DeleteTemplateCmd; +import org.apache.cloudstack.api.command.user.template.ExtractTemplateCmd; +import com.cloud.agent.api.storage.PrepareOVAPackingCommand; +import com.cloud.agent.api.storage.PrepareOVAPackingAnswer; import org.apache.cloudstack.api.command.user.template.RegisterTemplateCmd; import org.apache.cloudstack.engine.subsystem.api.storage.CommandResult; import org.apache.cloudstack.engine.subsystem.api.storage.DataStore; @@ -64,6 +67,10 @@ import com.cloud.utils.UriUtils; import com.cloud.utils.db.DB; import com.cloud.utils.exception.CloudRuntimeException; import com.cloud.vm.UserVmVO; +import com.cloud.hypervisor.Hypervisor.HypervisorType; +import com.cloud.exception.AgentUnavailableException; +import com.cloud.exception.OperationTimedoutException; + @Local(value=TemplateAdapter.class) public class HypervisorTemplateAdapter extends TemplateAdapterBase implements TemplateAdapter { @@ -188,6 +195,77 @@ public class HypervisorTemplateAdapter extends TemplateAdapterBase implements Te return template; } + @Override + public TemplateProfile prepareExtractTemplate(ExtractTemplateCmd extractcmd) { + TemplateProfile profile = super.prepareExtractTemplate(extractcmd); + VMTemplateVO template = (VMTemplateVO)profile.getTemplate(); + Long zoneId = profile.getZoneId(); + Long templateId = template.getId(); + + if (template.getHypervisorType() == HypervisorType.VMware) { + PrepareOVAPackingCommand cmd = null; + String zoneName=""; + List secondaryStorageHosts; + if (!template.isCrossZones() && zoneId != null) { + DataCenterVO zone = _dcDao.findById(zoneId); + zoneName = zone.getName(); + secondaryStorageHosts = _ssvmMgr.listSecondaryStorageHostsInOneZone(zoneId); + + s_logger.debug("Attempting to mark template host refs for template: " + template.getName() + " as destroyed in zone: " + zoneName); + + // Make sure the template is downloaded to all the necessary secondary storage hosts + + for (HostVO secondaryStorageHost : secondaryStorageHosts) { + long hostId = secondaryStorageHost.getId(); + List templateHostVOs = _tmpltHostDao.listByHostTemplate(hostId, templateId); + for (VMTemplateHostVO templateHostVO : templateHostVOs) { + if (templateHostVO.getDownloadState() == Status.DOWNLOAD_IN_PROGRESS) { + String errorMsg = "Please specify a template that is not currently being downloaded."; + s_logger.debug("Template: " + template.getName() + " is currently being downloaded to secondary storage host: " + secondaryStorageHost.getName() + "."); + throw new CloudRuntimeException(errorMsg); + } + String installPath = templateHostVO.getInstallPath(); + if (installPath != null) { + HostVO ssvmhost = _ssvmMgr.pickSsvmHost(secondaryStorageHost); + if( ssvmhost == null ) { + s_logger.warn("prepareOVAPacking (hyervisorTemplateAdapter): There is no secondary storage VM for secondary storage host " + secondaryStorageHost.getName()); + throw new CloudRuntimeException("PrepareExtractTemplate: can't locate ssvm for SecStorage Host."); + } + //Answer answer = _agentMgr.sendToSecStorage(secondaryStorageHost, new PrepareOVAPackingCommand(secondaryStorageHost.getStorageUrl(), installPath)); + cmd = new PrepareOVAPackingCommand(secondaryStorageHost.getStorageUrl(), installPath); + + if (cmd == null) { + s_logger.debug("Fang: PrepareOVAPacking cmd can't created. cmd is null ."); + throw new CloudRuntimeException("PrepareExtractTemplate: can't create a new cmd to packing ova."); + } else { + cmd.setContextParam("hypervisor", HypervisorType.VMware.toString()); + } + Answer answer = null; + s_logger.debug("Fang: PrepareOVAPAcking cmd, before send out. cmd: " + cmd.toString()); + try { + answer = _agentMgr.send(ssvmhost.getId(), cmd); + } catch (AgentUnavailableException e) { + s_logger.warn("Unable to packOVA for template: id: " + templateId + ", name " + ssvmhost.getName(), e); + } catch (OperationTimedoutException e) { + s_logger.warn("Unable to packOVA for template timeout. template id: " + templateId); + e.printStackTrace(); + } + + if (answer == null || !answer.getResult()) { + s_logger.debug("Failed to create OVA for template " + templateHostVO + " due to " + ((answer == null) ? "answer is null" : answer.getDetails())); + throw new CloudRuntimeException("PrepareExtractTemplate: Failed to create OVA for template extraction. "); + } + } + } + } + } else { + s_logger.debug("Failed to create OVA for template " + template + " due to zone non-existing."); + throw new CloudRuntimeException("PrepareExtractTemplate: Failed to create OVA for template extraction. "); + } + } + return profile; + } + @Override @DB public boolean delete(TemplateProfile profile) { boolean success = true; diff --git a/server/src/com/cloud/template/TemplateAdapter.java b/server/src/com/cloud/template/TemplateAdapter.java index 1f8f491cb25..9a2d877926d 100755 --- a/server/src/com/cloud/template/TemplateAdapter.java +++ b/server/src/com/cloud/template/TemplateAdapter.java @@ -22,6 +22,7 @@ import org.apache.cloudstack.api.command.user.iso.DeleteIsoCmd; import org.apache.cloudstack.api.command.user.iso.RegisterIsoCmd; import org.apache.cloudstack.api.command.user.template.DeleteTemplateCmd; import org.apache.cloudstack.api.command.user.template.RegisterTemplateCmd; +import org.apache.cloudstack.api.command.user.template.ExtractTemplateCmd; import com.cloud.exception.ResourceAllocationException; import com.cloud.hypervisor.Hypervisor.HypervisorType; @@ -56,6 +57,8 @@ public interface TemplateAdapter extends Adapter { public TemplateProfile prepareDelete(DeleteIsoCmd cmd); + public TemplateProfile prepareExtractTemplate(ExtractTemplateCmd cmd); + public boolean delete(TemplateProfile profile); public TemplateProfile prepare(boolean isIso, Long userId, String name, String displayText, Integer bits, diff --git a/server/src/com/cloud/template/TemplateAdapterBase.java b/server/src/com/cloud/template/TemplateAdapterBase.java index 1b114250621..0940d3e2af1 100755 --- a/server/src/com/cloud/template/TemplateAdapterBase.java +++ b/server/src/com/cloud/template/TemplateAdapterBase.java @@ -26,12 +26,14 @@ import org.apache.cloudstack.api.command.user.iso.DeleteIsoCmd; import org.apache.cloudstack.api.command.user.iso.RegisterIsoCmd; import org.apache.cloudstack.api.command.user.template.DeleteTemplateCmd; import org.apache.cloudstack.api.command.user.template.RegisterTemplateCmd; +import org.apache.cloudstack.api.command.user.template.ExtractTemplateCmd; import org.apache.cloudstack.engine.subsystem.api.storage.DataStore; import org.apache.cloudstack.engine.subsystem.api.storage.DataStoreManager; import org.apache.cloudstack.engine.subsystem.api.storage.DataStoreRole; import org.apache.log4j.Logger; import com.cloud.api.ApiDBUtils; +import com.cloud.configuration.Config; import com.cloud.configuration.Resource.ResourceType; import com.cloud.configuration.dao.ConfigurationDao; import com.cloud.dc.DataCenterVO; @@ -44,6 +46,7 @@ import com.cloud.exception.ResourceAllocationException; import com.cloud.host.dao.HostDao; import com.cloud.hypervisor.Hypervisor.HypervisorType; import com.cloud.org.Grouping; +import com.cloud.server.ConfigurationServer; import com.cloud.storage.GuestOS; import com.cloud.storage.Storage.ImageFormat; import com.cloud.storage.Storage.TemplateType; @@ -82,6 +85,7 @@ public abstract class TemplateAdapterBase extends AdapterBase implements Templat protected @Inject ResourceLimitService _resourceLimitMgr; protected @Inject DataStoreManager storeMgr; @Inject TemplateManager templateMgr; + @Inject ConfigurationServer _configServer; @Override public boolean stop() { @@ -167,8 +171,8 @@ public abstract class TemplateAdapterBase extends AdapterBase implements Templat if (url.toLowerCase().contains("file://")) { throw new InvalidParameterValueException("File:// type urls are currently unsupported"); } - - boolean allowPublicUserTemplates = Boolean.parseBoolean(_configDao.getValue("allow.public.user.templates")); + // check whether owner can create public templates + boolean allowPublicUserTemplates = Boolean.parseBoolean(_configServer.getConfigValue(Config.AllowPublicUserTemplates.key(), Config.ConfigurationParameterScope.account.toString(), templateOwner.getId())); if (!isAdmin && !allowPublicUserTemplates && isPublic) { throw new InvalidParameterValueException("Only private templates/ISO can be created."); } @@ -337,6 +341,18 @@ public abstract class TemplateAdapterBase extends AdapterBase implements Templat return new TemplateProfile(userId, template, zoneId); } + public TemplateProfile prepareExtractTemplate(ExtractTemplateCmd cmd) { + Long templateId = cmd.getId(); + Long userId = UserContext.current().getCallerUserId(); + Long zoneId = cmd.getZoneId(); + + VMTemplateVO template = _tmpltDao.findById(templateId.longValue()); + if (template == null) { + throw new InvalidParameterValueException("unable to find template with id " + templateId); + } + return new TemplateProfile(userId, template, zoneId); + } + public TemplateProfile prepareDelete(DeleteIsoCmd cmd) { Long templateId = cmd.getId(); Long userId = UserContext.current().getCallerUserId(); diff --git a/server/src/com/cloud/template/TemplateManagerImpl.java b/server/src/com/cloud/template/TemplateManagerImpl.java index c7eaa64335e..a8729e1490a 100755 --- a/server/src/com/cloud/template/TemplateManagerImpl.java +++ b/server/src/com/cloud/template/TemplateManagerImpl.java @@ -75,8 +75,8 @@ import com.cloud.agent.AgentManager; import com.cloud.agent.api.Answer; import com.cloud.agent.api.AttachIsoCommand; import com.cloud.agent.api.ComputeChecksumCommand; -import com.cloud.agent.api.downloadTemplateFromSwiftToSecondaryStorageCommand; -import com.cloud.agent.api.uploadTemplateToSwiftFromSecondaryStorageCommand; +import com.cloud.agent.api.DownloadTemplateFromSwiftToSecondaryStorageCommand; +import com.cloud.agent.api.UploadTemplateToSwiftFromSecondaryStorageCommand; import com.cloud.agent.api.storage.DestroyCommand; import com.cloud.agent.api.storage.PrimaryStorageDownloadAnswer; import com.cloud.agent.api.storage.PrimaryStorageDownloadCommand; @@ -113,6 +113,7 @@ import com.cloud.projects.Project; import com.cloud.projects.ProjectManager; import com.cloud.resource.ResourceManager; +import com.cloud.server.ConfigurationServer; import com.cloud.storage.GuestOSVO; import com.cloud.storage.LaunchPermissionVO; import com.cloud.storage.Snapshot; @@ -253,6 +254,8 @@ public class TemplateManagerImpl extends ManagerBase implements TemplateManager, protected ResourceManager _resourceMgr; @Inject VolumeManager volumeMgr; @Inject VMTemplateHostDao templateHostDao; + @Inject + ConfigurationServer _configServer; int _primaryStorageDownloadWait; @@ -364,6 +367,13 @@ public class TemplateManagerImpl extends ManagerBase implements TemplateManager, String mode = cmd.getMode(); Long eventId = cmd.getStartEventId(); + VirtualMachineTemplate template = getTemplate(templateId); + if (template == null) { + throw new InvalidParameterValueException("unable to find template with id " + templateId); + } + TemplateAdapter adapter = getAdapter(template.getHypervisorType()); + TemplateProfile profile = adapter.prepareExtractTemplate(cmd); + // FIXME: async job needs fixing Long uploadId = extract(caller, templateId, url, zoneId, mode, eventId, false, null, _asyncMgr); if (uploadId != null){ @@ -569,7 +579,7 @@ public class TemplateManagerImpl extends ManagerBase implements TemplateManager, return errMsg; } - downloadTemplateFromSwiftToSecondaryStorageCommand cmd = new downloadTemplateFromSwiftToSecondaryStorageCommand(swift, secHost.getName(), dcId, template.getAccountId(), templateId, + DownloadTemplateFromSwiftToSecondaryStorageCommand cmd = new DownloadTemplateFromSwiftToSecondaryStorageCommand(swift, secHost.getName(), dcId, template.getAccountId(), templateId, tmpltSwift.getPath(), _primaryStorageDownloadWait); try { Answer answer = _agentMgr.sendToSSVM(dcId, cmd); @@ -618,7 +628,7 @@ public class TemplateManagerImpl extends ManagerBase implements TemplateManager, return errMsg; } - uploadTemplateToSwiftFromSecondaryStorageCommand cmd = new uploadTemplateToSwiftFromSecondaryStorageCommand(swift, secHost.getName(), secHost.getDataCenterId(), template.getAccountId(), + UploadTemplateToSwiftFromSecondaryStorageCommand cmd = new UploadTemplateToSwiftFromSecondaryStorageCommand(swift, secHost.getName(), secHost.getDataCenterId(), template.getAccountId(), templateId, _primaryStorageDownloadWait); Answer answer = null; try { @@ -1609,7 +1619,8 @@ public class TemplateManagerImpl extends ManagerBase implements TemplateManager, } boolean isAdmin = _accountMgr.isAdmin(caller.getType()); - boolean allowPublicUserTemplates = Boolean.valueOf(_configDao.getValue("allow.public.user.templates")); + // check configuration parameter(allow.public.user.templates) value for the template owner + boolean allowPublicUserTemplates = Boolean.valueOf(_configServer.getConfigValue(Config.AllowPublicUserTemplates.key(), Config.ConfigurationParameterScope.account.toString(), template.getAccountId())); if (!isAdmin && !allowPublicUserTemplates && isPublic != null && isPublic) { throw new InvalidParameterValueException("Only private " + mediaType + "s can be created."); } @@ -1842,8 +1853,8 @@ public class TemplateManagerImpl extends ManagerBase implements TemplateManager, if (isPublic == null) { isPublic = Boolean.FALSE; } - boolean allowPublicUserTemplates = Boolean.parseBoolean(_configDao - .getValue("allow.public.user.templates")); + // check whether template owner can create public templates + boolean allowPublicUserTemplates = Boolean.parseBoolean(_configServer.getConfigValue(Config.AllowPublicUserTemplates.key(), Config.ConfigurationParameterScope.account.toString(), templateOwner.getId())); if (!isAdmin && !allowPublicUserTemplates && isPublic) { throw new PermissionDeniedException("Failed to create template " + name + ", only private templates can be created."); diff --git a/server/src/com/cloud/user/AccountManagerImpl.java b/server/src/com/cloud/user/AccountManagerImpl.java index 8de73fbd582..4088f64f58b 100755 --- a/server/src/com/cloud/user/AccountManagerImpl.java +++ b/server/src/com/cloud/user/AccountManagerImpl.java @@ -59,6 +59,7 @@ import com.cloud.configuration.dao.ConfigurationDao; import com.cloud.configuration.dao.ResourceCountDao; import com.cloud.dc.DataCenterVO; import com.cloud.dc.dao.DataCenterDao; +import com.cloud.dc.dao.DataCenterVnetDao; import com.cloud.domain.Domain; import com.cloud.domain.DomainVO; import com.cloud.domain.dao.DomainDao; @@ -76,6 +77,8 @@ import com.cloud.network.IpAddress; import com.cloud.network.NetworkManager; import com.cloud.network.VpnUserVO; import com.cloud.network.as.AutoScaleManager; +import com.cloud.network.dao.AccountGuestVlanMapDao; +import com.cloud.network.dao.AccountGuestVlanMapVO; import com.cloud.network.dao.IPAddressDao; import com.cloud.network.dao.IPAddressVO; import com.cloud.network.dao.NetworkDao; @@ -222,6 +225,10 @@ public class AccountManagerImpl extends ManagerBase implements AccountManager, M @Inject VolumeManager volumeMgr; @Inject private AffinityGroupDao _affinityGroupDao; + @Inject + private AccountGuestVlanMapDao _accountGuestVlanMapDao; + @Inject + private DataCenterVnetDao _dataCenterVnetDao; private List _userAuthenticators; List _userPasswordEncoders; @@ -699,6 +706,14 @@ public class AccountManagerImpl extends ManagerBase implements AccountManager, M } } + // release account specific guest vlans + List maps = _accountGuestVlanMapDao.listAccountGuestVlanMapsByAccount(accountId); + for (AccountGuestVlanMapVO map : maps) { + _dataCenterVnetDao.releaseDedicatedGuestVlans(map.getId()); + } + int vlansReleased = _accountGuestVlanMapDao.removeByAccountId(accountId); + s_logger.info("deleteAccount: Released " + vlansReleased + " dedicated guest vlan ranges from account " + accountId); + return true; } catch (Exception ex) { s_logger.warn("Failed to cleanup account " + account + " due to ", ex); diff --git a/server/src/com/cloud/vm/UserVmManagerImpl.java b/server/src/com/cloud/vm/UserVmManagerImpl.java index f58d6be5b2f..f7f5fc7ad74 100755 --- a/server/src/com/cloud/vm/UserVmManagerImpl.java +++ b/server/src/com/cloud/vm/UserVmManagerImpl.java @@ -485,7 +485,7 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use _accountMgr.checkAccess(caller, null, true, userVm); - boolean result = resetVMPasswordInternal(cmd, password); + boolean result = resetVMPasswordInternal(vmId, password); if (result) { userVm.setPassword(password); @@ -512,10 +512,9 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use return userVm; } - private boolean resetVMPasswordInternal(ResetVMPasswordCmd cmd, + private boolean resetVMPasswordInternal(Long vmId, String password) throws ResourceUnavailableException, InsufficientCapacityException { - Long vmId = cmd.getId(); Long userId = UserContext.current().getCallerUserId(); VMInstanceVO vmInstance = _vmDao.findById(vmId); @@ -832,6 +831,12 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use if(network == null) { throw new InvalidParameterValueException("unable to find a network with id " + networkId); } + List allNics = _nicDao.listByVmId(vmInstance.getId()); + for(NicVO nic : allNics){ + if(nic.getNetworkId() == network.getId()) + throw new CloudRuntimeException("A NIC already exists for VM:" + vmInstance.getInstanceName() + " in network: " + network.getUuid()); + } + NicProfile profile = new NicProfile(null, null); if(ipAddress != null) { profile = new NicProfile(ipAddress, null); @@ -1051,7 +1056,7 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use @Override @ActionEvent(eventType = EventTypes.EVENT_VM_SCALE, eventDescription = "scaling Vm") - public UserVm + public boolean upgradeVirtualMachine(ScaleVMCmd cmd) throws InvalidParameterValueException { Long vmId = cmd.getId(); Long newServiceOfferingId = cmd.getServiceOfferingId(); @@ -1059,7 +1064,7 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use // Verify input parameters VMInstanceVO vmInstance = _vmInstanceDao.findById(vmId); - if(vmInstance.getHypervisorType() != HypervisorType.XenServer){ + if(vmInstance.getHypervisorType() != HypervisorType.XenServer && vmInstance.getHypervisorType() != HypervisorType.VMware){ throw new InvalidParameterValueException("This operation not permitted for this hypervisor of the vm"); } @@ -1077,8 +1082,8 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use } // Dynamically upgrade the running vms + boolean success = false; if(vmInstance.getState().equals(State.Running)){ - boolean success = false; int retry = _scaleRetry; while (retry-- != 0) { // It's != so that it can match -1. try{ @@ -1096,7 +1101,7 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use vmInstance = _vmInstanceDao.findById(vmId); vmInstance = _itMgr.reConfigureVm(vmInstance, oldServiceOffering, existingHostHasCapacity); success = true; - return _vmDao.findById(vmInstance.getId()); + return success; }catch(InsufficientCapacityException e ){ s_logger.warn("Received exception while scaling ",e); } catch (ResourceUnavailableException e) { @@ -1113,11 +1118,9 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use } } } - if (!success) - return null; } - return _vmDao.findById(vmInstance.getId()); + return success; } @@ -3722,19 +3725,14 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use + cmd.getAccountName() + " is disabled."); } - // make sure the accounts are under same domain - if (oldAccount.getDomainId() != newAccount.getDomainId()) { - throw new InvalidParameterValueException( - "The account should be under same domain for moving VM between two accounts. Old owner domain =" - + oldAccount.getDomainId() - + " New owner domain=" - + newAccount.getDomainId()); - } + //check caller has access to both the old and new account + _accountMgr.checkAccess(caller, null, true, oldAccount); + _accountMgr.checkAccess(caller, null, true, newAccount); // make sure the accounts are not same if (oldAccount.getAccountId() == newAccount.getAccountId()) { throw new InvalidParameterValueException( - "The account should be same domain for moving VM between two accounts. Account id =" + "The new account is the same as the old account. Account id =" + oldAccount.getAccountId()); } @@ -3826,6 +3824,7 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use _resourceLimitMgr.decrementResourceCount(oldAccount.getAccountId(), ResourceType.primary_storage, new Long(volume.getSize())); volume.setAccountId(newAccount.getAccountId()); + volume.setDomainId(newAccount.getDomainId()); _volsDao.persist(volume); _resourceLimitMgr.incrementResourceCount(newAccount.getAccountId(), ResourceType.volume); _resourceLimitMgr.incrementResourceCount(newAccount.getAccountId(), ResourceType.primary_storage, @@ -4078,7 +4077,7 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use } @Override - public UserVm restoreVM(RestoreVMCmd cmd) { + public UserVm restoreVM(RestoreVMCmd cmd) throws InsufficientCapacityException, ResourceUnavailableException { // Input validation Account caller = UserContext.current().getCaller(); @@ -4096,7 +4095,7 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use return restoreVMInternal(caller, vm, newTemplateId); } - public UserVm restoreVMInternal(Account caller, UserVmVO vm, Long newTemplateId){ + public UserVm restoreVMInternal(Account caller, UserVmVO vm, Long newTemplateId) throws InsufficientCapacityException, ResourceUnavailableException { Long userId = caller.getId(); Account owner = _accountDao.findById(vm.getAccountId()); @@ -4190,6 +4189,29 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use _volsDao.detachVolume(root.getId()); this.volumeMgr.destroyVolume(root); + if (template.getEnablePassword()) { + String password = generateRandomPassword(); + boolean result = resetVMPasswordInternal(vmId, password); + if (result) { + vm.setPassword(password); + _vmDao.loadDetails(vm); + // update the password in vm_details table too + // Check if an SSH key pair was selected for the instance and if so + // use it to encrypt & save the vm password + String sshPublicKey = vm.getDetail("SSH.PublicKey"); + if (sshPublicKey != null && !sshPublicKey.equals("") && password != null && !password.equals("saved_password")) { + String encryptedPasswd = RSAHelper.encryptWithSSHPublicKey(sshPublicKey, password); + if (encryptedPasswd == null) { + throw new CloudRuntimeException("VM reset is completed but error occurred when encrypting newly created password"); + } + vm.setDetail("Encrypted.Password", encryptedPasswd); + _vmDao.saveDetails(vm); + } + } else { + throw new CloudRuntimeException("VM reset is completed but failed to reset password for the virtual machine "); + } + } + if (needRestart) { try { _itMgr.start(vm, null, user, caller); @@ -4222,7 +4244,7 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use _agentMgr.send(dest.getHost().getId(),cmds); PlugNicAnswer plugNicAnswer = cmds.getAnswer(PlugNicAnswer.class); if (!(plugNicAnswer != null && plugNicAnswer.getResult())) { - s_logger.warn("Unable to plug nic for " + vmVO); + s_logger.warn("Unable to plug nic for " + vmVO + " due to: " + " due to: " + plugNicAnswer.getDetails()); return false; } } catch (OperationTimedoutException e) { @@ -4250,7 +4272,7 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Use _agentMgr.send(dest.getHost().getId(),cmds); UnPlugNicAnswer unplugNicAnswer = cmds.getAnswer(UnPlugNicAnswer.class); if (!(unplugNicAnswer != null && unplugNicAnswer.getResult())) { - s_logger.warn("Unable to unplug nic for " + vmVO); + s_logger.warn("Unable to unplug nic for " + vmVO + " due to: " + unplugNicAnswer.getDetails()); return false; } } catch (OperationTimedoutException e) { diff --git a/server/src/com/cloud/vm/VirtualMachineManagerImpl.java b/server/src/com/cloud/vm/VirtualMachineManagerImpl.java index b0d6378e9e5..521b5e0c582 100755 --- a/server/src/com/cloud/vm/VirtualMachineManagerImpl.java +++ b/server/src/com/cloud/vm/VirtualMachineManagerImpl.java @@ -24,7 +24,6 @@ import java.util.Collections; import java.util.Date; import java.util.HashMap; import java.util.HashSet; -import java.util.Iterator; import java.util.List; import java.util.Map; import java.util.Set; @@ -37,39 +36,56 @@ import javax.ejb.Local; import javax.inject.Inject; import javax.naming.ConfigurationException; -import com.cloud.capacity.CapacityManager; import org.apache.cloudstack.engine.subsystem.api.storage.DataStoreManager; -import org.apache.cloudstack.engine.subsystem.api.storage.ObjectInDataStoreStateMachine; import org.apache.cloudstack.engine.subsystem.api.storage.StoragePoolAllocator; import org.apache.cloudstack.engine.subsystem.api.storage.VolumeDataFactory; -import org.apache.cloudstack.engine.subsystem.api.storage.VolumeInfo; import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDao; import org.apache.cloudstack.storage.datastore.db.StoragePoolVO; - -import com.cloud.dc.*; -import com.cloud.agent.api.*; import org.apache.log4j.Logger; import com.cloud.agent.AgentManager; import com.cloud.agent.AgentManager.OnError; import com.cloud.agent.Listener; +import com.cloud.agent.api.AgentControlAnswer; +import com.cloud.agent.api.AgentControlCommand; +import com.cloud.agent.api.Answer; +import com.cloud.agent.api.CheckVirtualMachineAnswer; +import com.cloud.agent.api.CheckVirtualMachineCommand; +import com.cloud.agent.api.ClusterSyncAnswer; +import com.cloud.agent.api.ClusterSyncCommand; +import com.cloud.agent.api.Command; +import com.cloud.agent.api.MigrateAnswer; +import com.cloud.agent.api.MigrateCommand; +import com.cloud.agent.api.PingRoutingCommand; +import com.cloud.agent.api.PrepareForMigrationAnswer; +import com.cloud.agent.api.PrepareForMigrationCommand; +import com.cloud.agent.api.RebootAnswer; +import com.cloud.agent.api.RebootCommand; +import com.cloud.agent.api.ScaleVmCommand; +import com.cloud.agent.api.StartAnswer; +import com.cloud.agent.api.StartCommand; +import com.cloud.agent.api.StartupCommand; +import com.cloud.agent.api.StartupRoutingCommand; import com.cloud.agent.api.StartupRoutingCommand.VmState; +import com.cloud.agent.api.StopAnswer; +import com.cloud.agent.api.StopCommand; import com.cloud.agent.api.to.NicTO; import com.cloud.agent.api.to.VirtualMachineTO; -import com.cloud.agent.api.to.StorageFilerTO; -import com.cloud.agent.api.to.VolumeTO; import com.cloud.agent.manager.Commands; import com.cloud.agent.manager.allocator.HostAllocator; import com.cloud.alert.AlertManager; +import com.cloud.capacity.CapacityManager; import com.cloud.cluster.ClusterManager; import com.cloud.configuration.Config; import com.cloud.configuration.ConfigurationManager; +import com.cloud.configuration.Resource.ResourceType; import com.cloud.configuration.dao.ConfigurationDao; -import com.cloud.dc.dao.ClusterDao; +import com.cloud.dc.ClusterDetailsDao; +import com.cloud.dc.ClusterDetailsVO; import com.cloud.dc.DataCenter; import com.cloud.dc.DataCenterVO; import com.cloud.dc.HostPodVO; -import com.cloud.consoleproxy.ConsoleProxyManager; +import com.cloud.dc.dao.ClusterDao; import com.cloud.dc.dao.DataCenterDao; import com.cloud.dc.dao.HostPodDao; import com.cloud.deploy.DataCenterDeployment; @@ -108,6 +124,7 @@ import com.cloud.network.NetworkManager; import com.cloud.network.NetworkModel; import com.cloud.network.dao.NetworkDao; import com.cloud.network.dao.NetworkVO; +import com.cloud.network.rules.RulesManager; import com.cloud.offering.ServiceOffering; import com.cloud.org.Cluster; import com.cloud.resource.ResourceManager; @@ -125,12 +142,13 @@ import com.cloud.storage.VolumeVO; import com.cloud.storage.dao.DiskOfferingDao; import com.cloud.storage.dao.GuestOSCategoryDao; import com.cloud.storage.dao.GuestOSDao; +import com.cloud.storage.dao.StoragePoolHostDao; import com.cloud.storage.dao.VMTemplateDao; import com.cloud.storage.dao.VolumeDao; -import com.cloud.storage.dao.StoragePoolHostDao; import com.cloud.storage.snapshot.SnapshotManager; import com.cloud.user.Account; import com.cloud.user.AccountManager; +import com.cloud.user.ResourceLimitService; import com.cloud.user.User; import com.cloud.user.dao.AccountDao; import com.cloud.user.dao.UserDao; @@ -152,12 +170,12 @@ import com.cloud.vm.VirtualMachine.Event; import com.cloud.vm.VirtualMachine.State; import com.cloud.vm.dao.NicDao; import com.cloud.vm.dao.UserVmDao; +import com.cloud.vm.dao.UserVmDetailsDao; import com.cloud.vm.dao.VMInstanceDao; import com.cloud.vm.snapshot.VMSnapshot; import com.cloud.vm.snapshot.VMSnapshotManager; import com.cloud.vm.snapshot.VMSnapshotVO; import com.cloud.vm.snapshot.dao.VMSnapshotDao; -import com.cloud.vm.dao.UserVmDetailsDao; @Local(value = VirtualMachineManager.class) public class VirtualMachineManagerImpl extends ManagerBase implements VirtualMachineManager, Listener { @@ -231,6 +249,10 @@ public class VirtualMachineManagerImpl extends ManagerBase implements VirtualMac protected VMSnapshotDao _vmSnapshotDao; @Inject protected VolumeDataFactory volFactory; + @Inject + protected ResourceLimitService _resourceLimitMgr; + @Inject + protected RulesManager rulesMgr; protected List _planners; public List getPlanners() { @@ -428,6 +450,7 @@ public class VirtualMachineManagerImpl extends ManagerBase implements VirtualMac s_logger.debug("Cleaning up NICS"); _networkMgr.cleanupNics(profile); // Clean up volumes based on the vm's instance id + List rootVol = _volsDao.findByInstanceAndType(vm.getId(), Volume.Type.ROOT); this.volumeMgr.cleanupVolumes(vm.getId()); VirtualMachineGuru guru = getVmGuru(vm); @@ -462,6 +485,12 @@ public class VirtualMachineManagerImpl extends ManagerBase implements VirtualMac s_logger.debug("Expunged " + vm); } + // Update Resource count + if (vm.getAccountId() != Account.ACCOUNT_ID_SYSTEM && !rootVol.isEmpty()) { + _resourceLimitMgr.decrementResourceCount(vm.getAccountId(), ResourceType.volume); + _resourceLimitMgr.decrementResourceCount(vm.getAccountId(), ResourceType.primary_storage, + new Long(rootVol.get(0).getSize())); + } return true; } @@ -2834,6 +2863,12 @@ public class VirtualMachineManagerImpl extends ManagerBase implements VirtualMac s_logger.warn("Failed to remove nic from " + vm + " in " + network + ", nic is default."); throw new CloudRuntimeException("Failed to remove nic from " + vm + " in " + network + ", nic is default."); } + + // if specified nic is associated with PF/LB/Static NAT + if(rulesMgr.listAssociatedRulesForGuestNic(nic).size() > 0){ + throw new CloudRuntimeException("Failed to remove nic from " + vm + " in " + network + + ", nic has associated Port forwarding or Load balancer or Static NAT rules."); + } NicProfile nicProfile = new NicProfile(nic, network, nic.getBroadcastUri(), nic.getIsolationUri(), _networkModel.getNetworkRate(network.getId(), vm.getId()), diff --git a/server/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerManagerImpl.java b/server/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerManagerImpl.java new file mode 100644 index 00000000000..ec0be8c9d96 --- /dev/null +++ b/server/src/org/apache/cloudstack/network/lb/ApplicationLoadBalancerManagerImpl.java @@ -0,0 +1,524 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.cloudstack.network.lb; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; + +import javax.ejb.Local; +import javax.inject.Inject; + +import org.apache.cloudstack.acl.SecurityChecker.AccessType; +import org.apache.cloudstack.api.command.user.loadbalancer.ListApplicationLoadBalancersCmd; +import org.apache.cloudstack.lb.ApplicationLoadBalancerRuleVO; +import org.apache.cloudstack.lb.dao.ApplicationLoadBalancerRuleDao; +import org.apache.log4j.Logger; +import org.springframework.stereotype.Component; + +import com.cloud.event.ActionEvent; +import com.cloud.event.EventTypes; +import com.cloud.event.UsageEventUtils; +import com.cloud.exception.InsufficientAddressCapacityException; +import com.cloud.exception.InsufficientVirtualNetworkCapcityException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.NetworkRuleConflictException; +import com.cloud.exception.UnsupportedServiceException; +import com.cloud.network.Network; +import com.cloud.network.Network.Capability; +import com.cloud.network.Network.Service; +import com.cloud.network.NetworkManager; +import com.cloud.network.NetworkModel; +import com.cloud.network.Networks.TrafficType; +import com.cloud.network.dao.FirewallRulesDao; +import com.cloud.network.lb.LoadBalancingRule; +import com.cloud.network.lb.LoadBalancingRule.LbDestination; +import com.cloud.network.lb.LoadBalancingRule.LbHealthCheckPolicy; +import com.cloud.network.lb.LoadBalancingRule.LbStickinessPolicy; +import com.cloud.network.lb.LoadBalancingRulesManager; +import com.cloud.network.rules.FirewallRule.State; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.projects.Project.ListProjectResourcesCriteria; +import com.cloud.server.ResourceTag.TaggedResourceType; +import com.cloud.tags.ResourceTagVO; +import com.cloud.tags.dao.ResourceTagDao; +import com.cloud.user.Account; +import com.cloud.user.AccountManager; +import com.cloud.user.UserContext; +import com.cloud.utils.Pair; +import com.cloud.utils.Ternary; +import com.cloud.utils.component.ManagerBase; +import com.cloud.utils.db.DB; +import com.cloud.utils.db.Filter; +import com.cloud.utils.db.JoinBuilder; +import com.cloud.utils.db.SearchBuilder; +import com.cloud.utils.db.SearchCriteria; +import com.cloud.utils.db.Transaction; +import com.cloud.utils.exception.CloudRuntimeException; +import com.cloud.utils.net.Ip; +import com.cloud.utils.net.NetUtils; + +@Component +@Local(value = { ApplicationLoadBalancerService.class }) +public class ApplicationLoadBalancerManagerImpl extends ManagerBase implements ApplicationLoadBalancerService { + private static final Logger s_logger = Logger.getLogger(ApplicationLoadBalancerManagerImpl.class); + + @Inject NetworkModel _networkModel; + @Inject ApplicationLoadBalancerRuleDao _lbDao; + @Inject AccountManager _accountMgr; + @Inject LoadBalancingRulesManager _lbMgr; + @Inject FirewallRulesDao _firewallDao; + @Inject ResourceTagDao _resourceTagDao; + @Inject NetworkManager _ntwkMgr; + + + @Override + @ActionEvent(eventType = EventTypes.EVENT_LOAD_BALANCER_CREATE, eventDescription = "creating load balancer") + public ApplicationLoadBalancerRule createApplicationLoadBalancer(String name, String description, Scheme scheme, long sourceIpNetworkId, String sourceIp, + int sourcePort, int instancePort, String algorithm, long networkId, long lbOwnerId) throws InsufficientAddressCapacityException, + NetworkRuleConflictException, InsufficientVirtualNetworkCapcityException { + + //Validate LB rule guest network + Network guestNtwk = _networkModel.getNetwork(networkId); + if (guestNtwk == null || guestNtwk.getTrafficType() != TrafficType.Guest) { + throw new InvalidParameterValueException("Can't find guest network by id"); + } + + Account caller = UserContext.current().getCaller(); + _accountMgr.checkAccess(caller, AccessType.UseNetwork, false, guestNtwk); + + Network sourceIpNtwk = _networkModel.getNetwork(sourceIpNetworkId); + if (sourceIpNtwk == null) { + throw new InvalidParameterValueException("Can't find source ip network by id"); + } + + Account lbOwner = _accountMgr.getAccount(lbOwnerId); + if (lbOwner == null) { + throw new InvalidParameterValueException("Can't find the lb owner account"); + } + + return createApplicationLoadBalancer(name, description, scheme, sourceIpNtwk, sourceIp, sourcePort, instancePort, algorithm, lbOwner, guestNtwk); + } + + + protected ApplicationLoadBalancerRule createApplicationLoadBalancer(String name, String description, Scheme scheme, Network sourceIpNtwk, String sourceIp, int sourcePort, int instancePort, String algorithm, + Account lbOwner, Network guestNtwk) throws NetworkRuleConflictException, InsufficientVirtualNetworkCapcityException { + + //Only Internal scheme is supported in this release + if (scheme != Scheme.Internal) { + throw new UnsupportedServiceException("Only scheme of type " + Scheme.Internal + " is supported"); + } + + //1) Validate LB rule's parameters + validateLbRule(sourcePort, instancePort, algorithm, guestNtwk, scheme); + + //2) Validate source network + validateSourceIpNtwkForLbRule(sourceIpNtwk, scheme); + + //3) Get source ip address + Ip sourceIpAddr = getSourceIp(scheme, sourceIpNtwk, sourceIp); + + ApplicationLoadBalancerRuleVO newRule = new ApplicationLoadBalancerRuleVO(name, description, sourcePort, instancePort, algorithm, guestNtwk.getId(), + lbOwner.getId(), lbOwner.getDomainId(), sourceIpAddr, sourceIpNtwk.getId(), scheme); + + //4) Validate Load Balancing rule on the providers + LoadBalancingRule loadBalancing = new LoadBalancingRule(newRule, new ArrayList(), + new ArrayList(), new ArrayList(), sourceIpAddr); + if (!_lbMgr.validateLbRule(loadBalancing)) { + throw new InvalidParameterValueException("LB service provider cannot support this rule"); + } + + //5) Persist Load Balancer rule + return persistLbRule(newRule); + } + + + @DB + protected ApplicationLoadBalancerRule persistLbRule(ApplicationLoadBalancerRuleVO newRule) throws NetworkRuleConflictException { + + Transaction txn = Transaction.currentTxn(); + txn.start(); + + //1) Persist the rule + newRule = _lbDao.persist(newRule); + boolean success = true; + + try { + //2) Detect conflicts + detectLbRulesConflicts(newRule); + if (!_firewallDao.setStateToAdd(newRule)) { + throw new CloudRuntimeException("Unable to update the state to add for " + newRule); + } + s_logger.debug("Load balancer " + newRule.getId() + " for Ip address " + newRule.getSourceIp().addr() + ", source port " + + newRule.getSourcePortStart() + ", instance port " + newRule.getDefaultPortStart() + " is added successfully."); + UserContext.current().setEventDetails("Load balancer Id: " + newRule.getId()); + Network ntwk = _networkModel.getNetwork(newRule.getNetworkId()); + UsageEventUtils.publishUsageEvent(EventTypes.EVENT_LOAD_BALANCER_CREATE, newRule.getAccountId(), + ntwk.getDataCenterId(), newRule.getId(), null, LoadBalancingRule.class.getName(), + newRule.getUuid()); + txn.commit(); + + return newRule; + } catch (Exception e) { + success = false; + if (e instanceof NetworkRuleConflictException) { + throw (NetworkRuleConflictException) e; + } + throw new CloudRuntimeException("Unable to add lb rule for ip address " + newRule.getSourceIpAddressId(), e); + } finally { + if (!success && newRule != null) { + _lbMgr.removeLBRule(newRule); + } + } + } + + /** + * Validates Lb rule parameters + * @param sourcePort + * @param instancePort + * @param algorithm + * @param network + * @param scheme TODO + * @param networkId + */ + protected void validateLbRule(int sourcePort, int instancePort, String algorithm, Network network, Scheme scheme) { + //1) verify that lb service is supported by the network + if (!_networkModel.areServicesSupportedInNetwork(network.getId(), Service.Lb)) { + InvalidParameterValueException ex = new InvalidParameterValueException( + "LB service is not supported in specified network id"); + ex.addProxyObject(network, network.getId(), "networkId"); + throw ex; + } + + //2) verify that lb service is supported by the network + _lbMgr.isLbServiceSupportedInNetwork(network.getId(), scheme); + + Map caps = _networkModel.getNetworkServiceCapabilities(network.getId(), Service.Lb); + String supportedProtocols = caps.get(Capability.SupportedProtocols).toLowerCase(); + if (!supportedProtocols.contains(NetUtils.TCP_PROTO.toLowerCase())) { + throw new InvalidParameterValueException("Protocol " + NetUtils.TCP_PROTO.toLowerCase() + " is not supported in zone " + network.getDataCenterId()); + } + + //3) Validate rule parameters + if (!NetUtils.isValidPort(instancePort)) { + throw new InvalidParameterValueException("Invalid value for instance port: " + instancePort); + } + + if (!NetUtils.isValidPort(sourcePort)) { + throw new InvalidParameterValueException("Invalid value for source port: " + sourcePort); + } + + if ((algorithm == null) || !NetUtils.isValidAlgorithm(algorithm)) { + throw new InvalidParameterValueException("Invalid algorithm: " + algorithm); + } + } + + + /** + * Gets source ip address based on the LB rule scheme/source IP network/requested IP address + * @param scheme + * @param sourceIpNtwk + * @param requestedIp + * @return + * @throws InsufficientVirtualNetworkCapcityException + */ + protected Ip getSourceIp(Scheme scheme, Network sourceIpNtwk, String requestedIp) throws InsufficientVirtualNetworkCapcityException { + + if (requestedIp != null) { + if (_lbDao.countBySourceIp(new Ip(requestedIp), sourceIpNtwk.getId()) > 0) { + s_logger.debug("IP address " + requestedIp + " is already used by existing LB rule, returning it"); + return new Ip(requestedIp); + } + + validateRequestedSourceIpForLbRule(sourceIpNtwk, new Ip(requestedIp), scheme); + } + + requestedIp = allocateSourceIpForLbRule(scheme, sourceIpNtwk, requestedIp); + + if (requestedIp == null) { + throw new InsufficientVirtualNetworkCapcityException("Unable to acquire IP address for network " + sourceIpNtwk, Network.class, sourceIpNtwk.getId()); + } + return new Ip(requestedIp); + } + + + /** + * Allocates new Source IP address for the Load Balancer rule based on LB rule scheme/sourceNetwork + * @param scheme + * @param sourceIpNtwk + * @param requestedIp TODO + * @param sourceIp + * @return + */ + protected String allocateSourceIpForLbRule(Scheme scheme, Network sourceIpNtwk, String requestedIp) { + String sourceIp = null; + if (scheme != Scheme.Internal) { + throw new InvalidParameterValueException("Only scheme " + Scheme.Internal + " is supported"); + } else { + sourceIp = allocateSourceIpForInternalLbRule(sourceIpNtwk, requestedIp); + } + return sourceIp; + } + + + /** + * Allocates sourceIp for the Internal LB rule + * @param sourceIpNtwk + * @param requestedIp TODO + * @return + */ + protected String allocateSourceIpForInternalLbRule(Network sourceIpNtwk, String requestedIp) { + return _ntwkMgr.acquireGuestIpAddress(sourceIpNtwk, requestedIp); + } + + + /** + * Validates requested source ip address of the LB rule based on Lb rule scheme/sourceNetwork + * @param sourceIpNtwk + * @param requestedSourceIp + * @param scheme + */ + void validateRequestedSourceIpForLbRule(Network sourceIpNtwk, Ip requestedSourceIp, Scheme scheme) { + //only Internal scheme is supported in this release + if (scheme != Scheme.Internal) { + throw new UnsupportedServiceException("Only scheme of type " + Scheme.Internal + " is supported"); + } else { + //validate guest source ip + validateRequestedSourceIpForInternalLbRule(sourceIpNtwk, requestedSourceIp); + } + } + + + /** + * Validates requested source IP address of Internal Lb rule against sourceNetworkId + * @param sourceIpNtwk + * @param requestedSourceIp + */ + protected void validateRequestedSourceIpForInternalLbRule(Network sourceIpNtwk, Ip requestedSourceIp) { + //Check if the IP is within the network cidr + Pair cidr = NetUtils.getCidr(sourceIpNtwk.getCidr()); + if (!NetUtils.getCidrSubNet(requestedSourceIp.addr(), cidr.second()).equalsIgnoreCase(NetUtils.getCidrSubNet(cidr.first(), cidr.second()))) { + throw new InvalidParameterValueException("The requested IP is not in the network's CIDR subnet."); + } + } + + + /** + * Validates source IP network for the LB rule + * @param sourceNtwk + * @param scheme + * @return + */ + protected Network validateSourceIpNtwkForLbRule(Network sourceNtwk, Scheme scheme) { + //only Internal scheme is supported in this release + if (scheme != Scheme.Internal) { + throw new UnsupportedServiceException("Only scheme of type " + Scheme.Internal + " is supported"); + } else { + //validate source ip network + return validateSourceIpNtwkForInternalLbRule(sourceNtwk); + } + + } + + /** + * Validates source IP network for the Internal LB rule + * @param sourceIpNtwk + * @return + */ + protected Network validateSourceIpNtwkForInternalLbRule(Network sourceIpNtwk) { + if (sourceIpNtwk.getTrafficType() != TrafficType.Guest) { + throw new InvalidParameterValueException("Only traffic type " + TrafficType.Guest + " is supported"); + } + + //Can't create the LB rule if the network's cidr is NULL + String ntwkCidr = sourceIpNtwk.getCidr(); + if (ntwkCidr == null) { + throw new InvalidParameterValueException("Can't create the application load balancer rule for the network having NULL cidr"); + } + + //check if the requested ip address is within the cidr + return sourceIpNtwk; + } + + + @Override + public boolean deleteApplicationLoadBalancer(long id) { + return _lbMgr.deleteLoadBalancerRule(id, true); + } + + @Override + public Pair, Integer> listApplicationLoadBalancers(ListApplicationLoadBalancersCmd cmd) { + Long id = cmd.getId(); + String name = cmd.getLoadBalancerRuleName(); + String ip = cmd.getSourceIp(); + Long ipNtwkId = cmd.getSourceIpNetworkId(); + String keyword = cmd.getKeyword(); + Scheme scheme = cmd.getScheme(); + Long networkId = cmd.getNetworkId(); + + Map tags = cmd.getTags(); + + Account caller = UserContext.current().getCaller(); + List permittedAccounts = new ArrayList(); + + Ternary domainIdRecursiveListProject = new Ternary( + cmd.getDomainId(), cmd.isRecursive(), null); + _accountMgr.buildACLSearchParameters(caller, id, cmd.getAccountName(), cmd.getProjectId(), permittedAccounts, + domainIdRecursiveListProject, cmd.listAll(), false); + Long domainId = domainIdRecursiveListProject.first(); + Boolean isRecursive = domainIdRecursiveListProject.second(); + ListProjectResourcesCriteria listProjectResourcesCriteria = domainIdRecursiveListProject.third(); + + Filter searchFilter = new Filter(ApplicationLoadBalancerRuleVO.class, "id", true, cmd.getStartIndex(), cmd.getPageSizeVal()); + SearchBuilder sb = _lbDao.createSearchBuilder(); + _accountMgr.buildACLSearchBuilder(sb, domainId, isRecursive, permittedAccounts, listProjectResourcesCriteria); + + sb.and("id", sb.entity().getId(), SearchCriteria.Op.EQ); + sb.and("name", sb.entity().getName(), SearchCriteria.Op.EQ); + sb.and("sourceIpAddress", sb.entity().getSourceIp(), SearchCriteria.Op.EQ); + sb.and("sourceIpAddressNetworkId", sb.entity().getSourceIpNetworkId(), SearchCriteria.Op.EQ); + sb.and("scheme", sb.entity().getScheme(), SearchCriteria.Op.EQ); + sb.and("networkId", sb.entity().getNetworkId(), SearchCriteria.Op.EQ); + + //list only load balancers having not null sourceIp/sourceIpNtwkId + sb.and("sourceIpAddress", sb.entity().getSourceIp(), SearchCriteria.Op.NNULL); + sb.and("sourceIpAddressNetworkId", sb.entity().getSourceIpNetworkId(), SearchCriteria.Op.NNULL); + + if (tags != null && !tags.isEmpty()) { + SearchBuilder tagSearch = _resourceTagDao.createSearchBuilder(); + for (int count = 0; count < tags.size(); count++) { + tagSearch.or().op("key" + String.valueOf(count), tagSearch.entity().getKey(), SearchCriteria.Op.EQ); + tagSearch.and("value" + String.valueOf(count), tagSearch.entity().getValue(), SearchCriteria.Op.EQ); + tagSearch.cp(); + } + tagSearch.and("resourceType", tagSearch.entity().getResourceType(), SearchCriteria.Op.EQ); + sb.groupBy(sb.entity().getId()); + sb.join("tagSearch", tagSearch, sb.entity().getId(), tagSearch.entity().getResourceId(), + JoinBuilder.JoinType.INNER); + } + + SearchCriteria sc = sb.create(); + _accountMgr.buildACLSearchCriteria(sc, domainId, isRecursive, permittedAccounts, listProjectResourcesCriteria); + + if (keyword != null) { + SearchCriteria ssc = _lbDao.createSearchCriteria(); + ssc.addOr("name", SearchCriteria.Op.LIKE, "%" + keyword + "%"); + ssc.addOr("description", SearchCriteria.Op.LIKE, "%" + keyword + "%"); + sc.addAnd("name", SearchCriteria.Op.SC, ssc); + } + + if (name != null) { + sc.setParameters("name", name); + } + + if (id != null) { + sc.setParameters("id", id); + } + + if (ip != null) { + sc.setParameters("sourceIpAddress", ip); + } + + if (ipNtwkId != null) { + sc.setParameters("sourceIpAddressNetworkId", ipNtwkId); + } + + if (scheme != null) { + sc.setParameters("scheme", scheme); + } + + if (networkId != null) { + sc.setParameters("networkId", networkId); + } + + if (tags != null && !tags.isEmpty()) { + int count = 0; + sc.setJoinParameters("tagSearch", "resourceType", TaggedResourceType.LoadBalancer.toString()); + for (String key : tags.keySet()) { + sc.setJoinParameters("tagSearch", "key" + String.valueOf(count), key); + sc.setJoinParameters("tagSearch", "value" + String.valueOf(count), tags.get(key)); + count++; + } + } + + Pair, Integer> result = _lbDao.searchAndCount(sc, searchFilter); + return new Pair, Integer>(result.first(), result.second()); + } + + @Override + public ApplicationLoadBalancerRule getApplicationLoadBalancer(long ruleId) { + ApplicationLoadBalancerRule lbRule = _lbDao.findById(ruleId); + if (lbRule == null) { + throw new InvalidParameterValueException("Can't find the load balancer by id"); + } + return lbRule; + } + + + /** + * Detects lb rule conflicts against other rules + * @param newLbRule + * @throws NetworkRuleConflictException + */ + protected void detectLbRulesConflicts(ApplicationLoadBalancerRule newLbRule) throws NetworkRuleConflictException { + if (newLbRule.getScheme() != Scheme.Internal) { + throw new UnsupportedServiceException("Only scheme of type " + Scheme.Internal + " is supported"); + } else { + detectInternalLbRulesConflict(newLbRule); + } + } + + + /** + * Detects Internal Lb Rules conflicts + * @param newLbRule + * @throws NetworkRuleConflictException + */ + protected void detectInternalLbRulesConflict(ApplicationLoadBalancerRule newLbRule) throws NetworkRuleConflictException { + List lbRules = _lbDao.listBySourceIpAndNotRevoked(newLbRule.getSourceIp(), newLbRule.getSourceIpNetworkId()); + + for (ApplicationLoadBalancerRuleVO lbRule : lbRules) { + if (lbRule.getId() == newLbRule.getId()) { + continue; // Skips my own rule. + } + + if (lbRule.getNetworkId() != newLbRule.getNetworkId() && lbRule.getState() != State.Revoke) { + throw new NetworkRuleConflictException("New rule is for a different network than what's specified in rule " + + lbRule.getXid()); + } + + if ((lbRule.getSourcePortStart().intValue() <= newLbRule.getSourcePortStart().intValue() + && lbRule.getSourcePortEnd().intValue() >= newLbRule.getSourcePortStart().intValue()) + || (lbRule.getSourcePortStart().intValue() <= newLbRule.getSourcePortEnd().intValue() + && lbRule.getSourcePortEnd().intValue() >= newLbRule.getSourcePortEnd().intValue()) + || (newLbRule.getSourcePortStart().intValue() <= lbRule.getSourcePortStart().intValue() + && newLbRule.getSourcePortEnd().intValue() >= lbRule.getSourcePortStart().intValue()) + || (newLbRule.getSourcePortStart().intValue() <= lbRule.getSourcePortEnd().intValue() + && newLbRule.getSourcePortEnd().intValue() >= lbRule.getSourcePortEnd().intValue())) { + + + throw new NetworkRuleConflictException("The range specified, " + newLbRule.getSourcePortStart() + "-" + newLbRule.getSourcePortEnd() + ", conflicts with rule " + lbRule.getId() + + " which has " + lbRule.getSourcePortStart() + "-" + lbRule.getSourcePortEnd()); + } + } + + if (s_logger.isDebugEnabled()) { + s_logger.debug("No network rule conflicts detected for " + newLbRule + " against " + (lbRules.size() - 1) + " existing rules"); + } + } +} diff --git a/server/test/com/cloud/network/DedicateGuestVlanRangesTest.java b/server/test/com/cloud/network/DedicateGuestVlanRangesTest.java new file mode 100644 index 00000000000..e81d7222a60 --- /dev/null +++ b/server/test/com/cloud/network/DedicateGuestVlanRangesTest.java @@ -0,0 +1,378 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package com.cloud.network; + +import java.util.ArrayList; +import java.util.List; +import java.util.UUID; +import java.lang.reflect.Field; + +import org.apache.cloudstack.api.command.admin.network.DedicateGuestVlanRangeCmd; +import org.apache.cloudstack.api.command.admin.network.ListDedicatedGuestVlanRangesCmd; +import org.apache.cloudstack.api.command.admin.network.ReleaseDedicatedGuestVlanRangeCmd; + +import org.apache.log4j.Logger; +import org.junit.Before; +import org.junit.Test; +import org.mockito.Mock; +import org.mockito.MockitoAnnotations; + +import com.cloud.dc.DataCenterVnetVO; +import com.cloud.dc.dao.DataCenterVnetDao; +import com.cloud.network.dao.AccountGuestVlanMapDao; +import com.cloud.network.dao.AccountGuestVlanMapVO; +import com.cloud.network.dao.PhysicalNetworkDao; +import com.cloud.network.dao.PhysicalNetworkVO; +import com.cloud.projects.ProjectManager; +import com.cloud.user.Account; +import com.cloud.user.dao.AccountDao; +import com.cloud.user.AccountManager; +import com.cloud.user.AccountVO; +import com.cloud.user.UserContext; +import com.cloud.utils.db.Transaction; + +import junit.framework.Assert; + +import static org.mockito.Matchers.*; +import static org.mockito.Mockito.when; +import static org.mockito.Mockito.doNothing; + +public class DedicateGuestVlanRangesTest { + + private static final Logger s_logger = Logger.getLogger(DedicateGuestVlanRangesTest.class); + + NetworkServiceImpl networkService = new NetworkServiceImpl(); + + DedicateGuestVlanRangeCmd dedicateGuestVlanRangesCmd = new DedicateGuestVlanRangeCmdExtn(); + Class _dedicateGuestVlanRangeClass = dedicateGuestVlanRangesCmd.getClass().getSuperclass(); + + ReleaseDedicatedGuestVlanRangeCmd releaseDedicatedGuestVlanRangesCmd = new ReleaseDedicatedGuestVlanRangeCmdExtn(); + Class _releaseGuestVlanRangeClass = releaseDedicatedGuestVlanRangesCmd.getClass().getSuperclass(); + + ListDedicatedGuestVlanRangesCmd listDedicatedGuestVlanRangesCmd = new ListDedicatedGuestVlanRangesCmdExtn(); + Class _listDedicatedGuestVlanRangeClass = listDedicatedGuestVlanRangesCmd.getClass().getSuperclass(); + + + @Mock AccountManager _accountMgr; + @Mock AccountDao _accountDao; + @Mock ProjectManager _projectMgr; + @Mock PhysicalNetworkDao _physicalNetworkDao; + @Mock DataCenterVnetDao _dataCenterVnetDao; + @Mock AccountGuestVlanMapDao _accountGuestVlanMapDao; + + @Before + public void setup() throws Exception { + MockitoAnnotations.initMocks(this); + + networkService._accountMgr = _accountMgr; + networkService._accountDao = _accountDao; + networkService._projectMgr = _projectMgr; + networkService._physicalNetworkDao = _physicalNetworkDao; + networkService._datacneter_vnet = _dataCenterVnetDao; + networkService._accountGuestVlanMapDao = _accountGuestVlanMapDao; + + Account account = (Account) new AccountVO("testaccount", 1, "networkdomain", (short) 0, UUID.randomUUID().toString()); + when(networkService._accountMgr.getAccount(anyLong())).thenReturn(account); + when(networkService._accountDao.findActiveAccount(anyString(), anyLong())).thenReturn(account); + + UserContext.registerContext(1, account, null, true); + + Field accountNameField = _dedicateGuestVlanRangeClass.getDeclaredField("accountName"); + accountNameField.setAccessible(true); + accountNameField.set(dedicateGuestVlanRangesCmd, "accountname"); + + Field projectIdField = _dedicateGuestVlanRangeClass.getDeclaredField("projectId"); + projectIdField.setAccessible(true); + projectIdField.set(dedicateGuestVlanRangesCmd, null); + + Field domainIdField = _dedicateGuestVlanRangeClass.getDeclaredField("domainId"); + domainIdField.setAccessible(true); + domainIdField.set(dedicateGuestVlanRangesCmd, 1L); + + Field physicalNetworkIdField = _dedicateGuestVlanRangeClass.getDeclaredField("physicalNetworkId"); + physicalNetworkIdField.setAccessible(true); + physicalNetworkIdField.set(dedicateGuestVlanRangesCmd, 1L); + + Field releaseIdField = _releaseGuestVlanRangeClass.getDeclaredField("id"); + releaseIdField.setAccessible(true); + releaseIdField.set(releaseDedicatedGuestVlanRangesCmd, 1L); + } + + @Test + public void testDedicateGuestVlanRange() throws Exception { + s_logger.info("Running tests for DedicateGuestVlanRange API"); + + /* + * TEST 1: given valid parameters DedicateGuestVlanRange should succeed + */ + runDedicateGuestVlanRangePostiveTest(); + + /* + * TEST 2: given invalid format for vlan range DedicateGuestVlanRange should fail + */ + runDedicateGuestVlanRangeInvalidFormat(); + + /* + * TEST 3: given vlan range that doesn't exist in the system request should fail + */ + runDedicateGuestVlanRangeInvalidRangeValue(); + + /* + * TEST 4: given vlan range has vlans that are allocated to a different account request should fail + */ + runDedicateGuestVlanRangeAllocatedVlans(); + + /* + * TEST 5: given vlan range is already dedicated to another account request should fail + */ + runDedicateGuestVlanRangeDedicatedRange(); + + /* + * TEST 6: given vlan range is partially dedicated to a different account request should fail + */ + runDedicateGuestVlanRangePartiallyDedicated(); + } + + @Test + public void testReleaseDedicatedGuestVlanRange() throws Exception { + + s_logger.info("Running tests for ReleaseDedicatedGuestVlanRange API"); + + /* + * TEST 1: given valid parameters ReleaseDedicatedGuestVlanRange should succeed + */ + runReleaseDedicatedGuestVlanRangePostiveTest(); + + /* + * TEST 2: given range doesn't exist request should fail + */ + runReleaseDedicatedGuestVlanRangeInvalidRange(); + } + + void runDedicateGuestVlanRangePostiveTest() throws Exception { + Transaction txn = Transaction.open("runDedicateGuestVlanRangePostiveTest"); + + Field dedicateVlanField = _dedicateGuestVlanRangeClass.getDeclaredField("vlan"); + dedicateVlanField.setAccessible(true); + dedicateVlanField.set(dedicateGuestVlanRangesCmd, "2-5"); + + PhysicalNetworkVO physicalNetwork = new PhysicalNetworkVO(1L, 1L, "2-5", "200", 1L, null, "testphysicalnetwork"); + physicalNetwork.addIsolationMethod("VLAN"); + AccountGuestVlanMapVO accountGuestVlanMapVO = new AccountGuestVlanMapVO(1L,1L); + + when(networkService._physicalNetworkDao.findById(anyLong())).thenReturn(physicalNetwork); + + when(networkService._datacneter_vnet.listAllocatedVnetsInRange(anyLong(), anyLong(), anyInt(), anyInt())).thenReturn(null); + + when(networkService._accountGuestVlanMapDao.listAccountGuestVlanMapsByPhysicalNetwork(anyLong())).thenReturn(null); + + when(networkService._accountGuestVlanMapDao.persist(any(AccountGuestVlanMapVO.class))).thenReturn(accountGuestVlanMapVO); + + when(networkService._datacneter_vnet.update(anyLong(), any(DataCenterVnetVO.class))).thenReturn(true); + + List dataCenterVnetList = new ArrayList(); + DataCenterVnetVO dataCenterVnetVO = new DataCenterVnetVO("2-5", 1L, 1L); + dataCenterVnetList.add(dataCenterVnetVO); + when(networkService._datacneter_vnet.findVnet(anyLong(), anyString())).thenReturn(dataCenterVnetList); + + try { + GuestVlan result = networkService.dedicateGuestVlanRange(dedicateGuestVlanRangesCmd); + Assert.assertNotNull(result); + } catch (Exception e) { + s_logger.info("exception in testing runDedicateGuestVlanRangePostiveTest message: " + e.toString()); + } finally { + txn.close("runDedicateGuestRangePostiveTest"); + } + } + + void runDedicateGuestVlanRangeInvalidFormat() throws Exception { + Transaction txn = Transaction.open("runDedicateGuestVlanRangeInvalidFormat"); + + Field dedicateVlanField = _dedicateGuestVlanRangeClass.getDeclaredField("vlan"); + dedicateVlanField.setAccessible(true); + dedicateVlanField.set(dedicateGuestVlanRangesCmd, "2"); + + PhysicalNetworkVO physicalNetwork = new PhysicalNetworkVO(1L, 1L, "2-5", "200", 1L, null, "testphysicalnetwork"); + physicalNetwork.addIsolationMethod("VLAN"); + + when(networkService._physicalNetworkDao.findById(anyLong())).thenReturn(physicalNetwork); + + try { + networkService.dedicateGuestVlanRange(dedicateGuestVlanRangesCmd); + } catch (Exception e) { + Assert.assertTrue(e.getMessage().contains("Invalid format for parameter value vlan")); + } finally { + txn.close("runDedicateGuestVlanRangeInvalidFormat"); + } + } + + void runDedicateGuestVlanRangeInvalidRangeValue() throws Exception { + Transaction txn = Transaction.open("runDedicateGuestVlanRangeInvalidRangeValue"); + + Field dedicateVlanField = _dedicateGuestVlanRangeClass.getDeclaredField("vlan"); + dedicateVlanField.setAccessible(true); + dedicateVlanField.set(dedicateGuestVlanRangesCmd, "2-5"); + + PhysicalNetworkVO physicalNetwork = new PhysicalNetworkVO(1L, 1L, "6-10", "200", 1L, null, "testphysicalnetwork"); + physicalNetwork.addIsolationMethod("VLAN"); + + when(networkService._physicalNetworkDao.findById(anyLong())).thenReturn(physicalNetwork); + + try { + networkService.dedicateGuestVlanRange(dedicateGuestVlanRangesCmd); + } catch (Exception e) { + Assert.assertTrue(e.getMessage().contains("Unable to find guest vlan by range")); + } finally { + txn.close("runDedicateGuestVlanRangeInvalidRangeValue"); + } + } + + void runDedicateGuestVlanRangeAllocatedVlans() throws Exception { + Transaction txn = Transaction.open("runDedicateGuestVlanRangeAllocatedVlans"); + + Field dedicateVlanField = _dedicateGuestVlanRangeClass.getDeclaredField("vlan"); + dedicateVlanField.setAccessible(true); + dedicateVlanField.set(dedicateGuestVlanRangesCmd, "2-5"); + + PhysicalNetworkVO physicalNetwork = new PhysicalNetworkVO(1L, 1L, "2-5", "200", 1L, null, "testphysicalnetwork"); + physicalNetwork.addIsolationMethod("VLAN"); + when(networkService._physicalNetworkDao.findById(anyLong())).thenReturn(physicalNetwork); + + List dataCenterList = new ArrayList(); + DataCenterVnetVO dataCenter = new DataCenterVnetVO("2-5", 1L, 1L); + dataCenter.setAccountId(1L); + dataCenterList.add(dataCenter); + when(networkService._datacneter_vnet.listAllocatedVnetsInRange(anyLong(), anyLong(), anyInt(), anyInt())).thenReturn(dataCenterList); + + try { + networkService.dedicateGuestVlanRange(dedicateGuestVlanRangesCmd); + } catch (Exception e) { + Assert.assertTrue(e.getMessage().contains("is allocated to a different account")); + } finally { + txn.close("runDedicateGuestVlanRangeAllocatedVlans"); + } + } + + void runDedicateGuestVlanRangeDedicatedRange() throws Exception { + Transaction txn = Transaction.open("runDedicateGuestVlanRangeDedicatedRange"); + + Field dedicateVlanField = _dedicateGuestVlanRangeClass.getDeclaredField("vlan"); + dedicateVlanField.setAccessible(true); + dedicateVlanField.set(dedicateGuestVlanRangesCmd, "2-5"); + + PhysicalNetworkVO physicalNetwork = new PhysicalNetworkVO(1L, 1L, "2-5", "200", 1L, null, "testphysicalnetwork"); + physicalNetwork.addIsolationMethod("VLAN"); + + when(networkService._physicalNetworkDao.findById(anyLong())).thenReturn(physicalNetwork); + + when(networkService._datacneter_vnet.listAllocatedVnetsInRange(anyLong(), anyLong(), anyInt(), anyInt())).thenReturn(null); + + List guestVlanMaps = new ArrayList(); + AccountGuestVlanMapVO accountGuestVlanMap = new AccountGuestVlanMapVO(1L, 1L); + accountGuestVlanMap.setGuestVlanRange("2-5"); + guestVlanMaps.add(accountGuestVlanMap); + when(networkService._accountGuestVlanMapDao.listAccountGuestVlanMapsByPhysicalNetwork(anyLong())).thenReturn(guestVlanMaps); + + try { + networkService.dedicateGuestVlanRange(dedicateGuestVlanRangesCmd); + } catch (Exception e) { + Assert.assertTrue(e.getMessage().contains("Vlan range is already dedicated to another account")); + } finally { + txn.close("runDedicateGuestVlanRangeDedicatedRange"); + } + } + + void runDedicateGuestVlanRangePartiallyDedicated() throws Exception { + Transaction txn = Transaction.open("runDedicateGuestVlanRangePartiallyDedicated"); + + Field dedicateVlanField = _dedicateGuestVlanRangeClass.getDeclaredField("vlan"); + dedicateVlanField.setAccessible(true); + dedicateVlanField.set(dedicateGuestVlanRangesCmd, "2-5"); + + PhysicalNetworkVO physicalNetwork = new PhysicalNetworkVO(1L, 1L, "2-5", "200", 1L, null, "testphysicalnetwork"); + physicalNetwork.addIsolationMethod("VLAN"); + + when(networkService._physicalNetworkDao.findById(anyLong())).thenReturn(physicalNetwork); + + when(networkService._datacneter_vnet.listAllocatedVnetsInRange(anyLong(), anyLong(), anyInt(), anyInt())).thenReturn(null); + + List guestVlanMaps = new ArrayList(); + AccountGuestVlanMapVO accountGuestVlanMap = new AccountGuestVlanMapVO(2L, 1L); + accountGuestVlanMap.setGuestVlanRange("4-8"); + guestVlanMaps.add(accountGuestVlanMap); + when(networkService._accountGuestVlanMapDao.listAccountGuestVlanMapsByPhysicalNetwork(anyLong())).thenReturn(guestVlanMaps); + + try { + networkService.dedicateGuestVlanRange(dedicateGuestVlanRangesCmd); + } catch (Exception e) { + Assert.assertTrue(e.getMessage().contains("Vlan range is partially dedicated to another account")); + } finally { + txn.close("runDedicateGuestVlanRangePartiallyDedicated"); + } + } + + void runReleaseDedicatedGuestVlanRangePostiveTest() throws Exception { + Transaction txn = Transaction.open("runReleaseDedicatedGuestVlanRangePostiveTest"); + + AccountGuestVlanMapVO accountGuestVlanMap = new AccountGuestVlanMapVO(1L, 1L); + when(networkService._accountGuestVlanMapDao.findById(anyLong())).thenReturn(accountGuestVlanMap); + doNothing().when(networkService._datacneter_vnet).releaseDedicatedGuestVlans(anyLong()); + when(networkService._accountGuestVlanMapDao.remove(anyLong())).thenReturn(true); + + try { + Boolean result = networkService.releaseDedicatedGuestVlanRange(releaseDedicatedGuestVlanRangesCmd.getId()); + Assert.assertTrue(result); + } catch (Exception e) { + s_logger.info("exception in testing runReleaseGuestVlanRangePostiveTest1 message: " + e.toString()); + } finally { + txn.close("runReleaseDedicatedGuestVlanRangePostiveTest"); + } + } + + void runReleaseDedicatedGuestVlanRangeInvalidRange() throws Exception { + Transaction txn = Transaction.open("runReleaseDedicatedGuestVlanRangeInvalidRange"); + + when(networkService._accountGuestVlanMapDao.findById(anyLong())).thenReturn(null); + + try { + networkService.releaseDedicatedGuestVlanRange(releaseDedicatedGuestVlanRangesCmd.getId()); + } catch (Exception e) { + Assert.assertTrue(e.getMessage().contains("Dedicated guest vlan with specified id doesn't exist in the system")); + } finally { + txn.close("runReleaseDedicatedGuestVlanRangeInvalidRange"); + } + } + + public class DedicateGuestVlanRangeCmdExtn extends DedicateGuestVlanRangeCmd { + public long getEntityOwnerId() { + return 1; + } + } + + public class ReleaseDedicatedGuestVlanRangeCmdExtn extends ReleaseDedicatedGuestVlanRangeCmd { + public long getEntityOwnerId() { + return 1; + } + } + + public class ListDedicatedGuestVlanRangesCmdExtn extends ListDedicatedGuestVlanRangesCmd { + public long getEntityOwnerId() { + return 1; + } + } +} diff --git a/server/test/com/cloud/network/MockNetworkManagerImpl.java b/server/test/com/cloud/network/MockNetworkManagerImpl.java index 06be8b53b6e..752dffbbeaa 100755 --- a/server/test/com/cloud/network/MockNetworkManagerImpl.java +++ b/server/test/com/cloud/network/MockNetworkManagerImpl.java @@ -16,19 +16,40 @@ // under the License. package com.cloud.network; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import javax.ejb.Local; +import javax.naming.ConfigurationException; + +import org.apache.cloudstack.acl.ControlledEntity.ACLType; +import org.apache.cloudstack.api.command.admin.usage.ListTrafficTypeImplementorsCmd; +import org.apache.cloudstack.api.command.user.network.CreateNetworkCmd; +import org.apache.cloudstack.api.command.user.network.ListNetworksCmd; +import org.apache.cloudstack.api.command.user.network.RestartNetworkCmd; +import org.apache.cloudstack.api.command.user.vm.ListNicsCmd; +import org.springframework.stereotype.Component; + import com.cloud.dc.DataCenter; import com.cloud.dc.Pod; import com.cloud.dc.Vlan.VlanType; import com.cloud.deploy.DataCenterDeployment; import com.cloud.deploy.DeployDestination; import com.cloud.deploy.DeploymentPlan; -import com.cloud.exception.*; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientAddressCapacityException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.InsufficientVirtualNetworkCapcityException; +import com.cloud.exception.ResourceAllocationException; +import com.cloud.exception.ResourceUnavailableException; import com.cloud.network.Network.Provider; import com.cloud.network.Network.Service; import com.cloud.network.Networks.TrafficType; import com.cloud.network.addr.PublicIp; import com.cloud.network.dao.IPAddressVO; import com.cloud.network.dao.NetworkVO; +import com.cloud.network.GuestVlan; import com.cloud.network.element.LoadBalancingServiceProvider; import com.cloud.network.element.StaticNatServiceProvider; import com.cloud.network.element.UserDataServiceProvider; @@ -36,6 +57,7 @@ import com.cloud.network.guru.NetworkGuru; import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.FirewallRule.Purpose; import com.cloud.network.rules.FirewallRule.State; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.network.rules.StaticNat; import com.cloud.offering.NetworkOffering; import com.cloud.offerings.NetworkOfferingVO; @@ -43,17 +65,12 @@ import com.cloud.user.Account; import com.cloud.user.User; import com.cloud.utils.Pair; import com.cloud.utils.component.ManagerBase; -import com.cloud.vm.Nic; -import com.cloud.vm.NicProfile; -import com.cloud.vm.NicSecondaryIp; -import com.cloud.vm.NicVO; -import com.cloud.vm.ReservationContext; -import com.cloud.vm.VMInstanceVO; -import com.cloud.vm.VirtualMachine; +import com.cloud.vm.*; import com.cloud.vm.VirtualMachine.Type; import com.cloud.vm.VirtualMachineProfile; -import com.cloud.vm.VirtualMachineProfileImpl; import org.apache.cloudstack.acl.ControlledEntity.ACLType; +import org.apache.cloudstack.api.command.admin.network.DedicateGuestVlanRangeCmd; +import org.apache.cloudstack.api.command.admin.network.ListDedicatedGuestVlanRangesCmd; import org.apache.cloudstack.api.command.admin.usage.ListTrafficTypeImplementorsCmd; import org.apache.cloudstack.api.command.user.network.CreateNetworkCmd; import org.apache.cloudstack.api.command.user.network.ListNetworksCmd; @@ -67,6 +84,7 @@ import java.util.List; import java.util.Map; import java.util.Set; + @Component @Local(value = { NetworkManager.class, NetworkService.class }) public class MockNetworkManagerImpl extends ManagerBase implements NetworkManager, NetworkService { @@ -334,6 +352,24 @@ public class MockNetworkManagerImpl extends ManagerBase implements NetworkManage } @Override + public GuestVlan dedicateGuestVlanRange(DedicateGuestVlanRangeCmd cmd) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Pair, Integer> listDedicatedGuestVlanRanges(ListDedicatedGuestVlanRangesCmd cmd) { + // TODO Auto-generated method stub + return null; + } + + @Override + public boolean releaseDedicatedGuestVlanRange(Long dedicatedGuestVlanRangeId) { + // TODO Auto-generated method stub + return true; + } + + @Override public List listNetworkServices(String providerName) { // TODO Auto-generated method stub return null; @@ -604,7 +640,7 @@ public class MockNetworkManagerImpl extends ManagerBase implements NetworkManage */ @Override public Network createPrivateNetwork(String networkName, String displayText, long physicalNetworkId, String vlan, - String startIp, String endIP, String gateway, String netmask, long networkOwnerId, Long vpcId) + String startIp, String endIP, String gateway, String netmask, long networkOwnerId, Long vpcId, Boolean sourceNat) throws ResourceAllocationException, ConcurrentOperationException, InsufficientCapacityException { // TODO Auto-generated method stub return null; @@ -807,7 +843,7 @@ public class MockNetworkManagerImpl extends ManagerBase implements NetworkManage } @Override - public LoadBalancingServiceProvider getLoadBalancingProviderForNetwork(Network network) { + public LoadBalancingServiceProvider getLoadBalancingProviderForNetwork(Network network, Scheme lbScheme) { // TODO Auto-generated method stub return null; } diff --git a/server/test/com/cloud/network/MockNetworkModelImpl.java b/server/test/com/cloud/network/MockNetworkModelImpl.java index 511249fff5a..c3a0d6c5ae9 100644 --- a/server/test/com/cloud/network/MockNetworkModelImpl.java +++ b/server/test/com/cloud/network/MockNetworkModelImpl.java @@ -33,12 +33,14 @@ import com.cloud.network.Network.Capability; import com.cloud.network.Network.GuestType; import com.cloud.network.Network.Provider; import com.cloud.network.Network.Service; +import com.cloud.network.Networks.IsolationType; import com.cloud.network.Networks.TrafficType; import com.cloud.network.dao.IPAddressVO; import com.cloud.network.dao.NetworkVO; import com.cloud.network.element.NetworkElement; import com.cloud.network.element.UserDataServiceProvider; import com.cloud.offering.NetworkOffering; +import com.cloud.offering.NetworkOffering.Detail; import com.cloud.offerings.NetworkOfferingVO; import com.cloud.user.Account; import com.cloud.utils.component.ManagerBase; @@ -566,7 +568,7 @@ public class MockNetworkModelImpl extends ManagerBase implements NetworkModel { * @see com.cloud.network.NetworkModel#getDefaultNetworkDomain() */ @Override - public String getDefaultNetworkDomain() { + public String getDefaultNetworkDomain(long zoneId) { // TODO Auto-generated method stub return null; } @@ -850,4 +852,26 @@ public class MockNetworkModelImpl extends ManagerBase implements NetworkModel { // TODO Auto-generated method stub return null; } + + @Override + public IpAddress getPublicIpAddress(String ipAddress, long zoneId) { + // TODO Auto-generated method stub + return null; + } + + @Override + public List getUsedIpsInNetwork(Network network) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Map getNtwkOffDetails(long offId) { + return null; + } + + public IsolationType[] listNetworkIsolationMethods() { + // TODO Auto-generated method stub + return null; + } } diff --git a/server/test/com/cloud/network/MockRulesManagerImpl.java b/server/test/com/cloud/network/MockRulesManagerImpl.java index e5a6894d76d..82a3e9346e3 100644 --- a/server/test/com/cloud/network/MockRulesManagerImpl.java +++ b/server/test/com/cloud/network/MockRulesManagerImpl.java @@ -28,6 +28,7 @@ import com.cloud.exception.InsufficientAddressCapacityException; import com.cloud.exception.NetworkRuleConflictException; import com.cloud.exception.ResourceUnavailableException; import com.cloud.network.rules.FirewallRule; +import com.cloud.network.rules.FirewallRuleVO; import com.cloud.network.rules.PortForwardingRule; import com.cloud.network.rules.PortForwardingRuleVO; import com.cloud.network.rules.RulesManager; @@ -40,6 +41,7 @@ import com.cloud.utils.Pair; import com.cloud.utils.component.Manager; import com.cloud.utils.component.ManagerBase; import com.cloud.utils.net.Ip; +import com.cloud.vm.Nic; import com.cloud.vm.VirtualMachine; @Local(value = {RulesManager.class, RulesService.class}) @@ -76,8 +78,7 @@ public class MockRulesManagerImpl extends ManagerBase implements RulesManager, R @Override public boolean enableStaticNat(long ipAddressId, long vmId, long networkId, - boolean isSystemVm, String ipAddr) throws NetworkRuleConflictException, - ResourceUnavailableException { + String ipAddr) throws NetworkRuleConflictException, ResourceUnavailableException { // TODO Auto-generated method stub return false; } @@ -311,4 +312,10 @@ public class MockRulesManagerImpl extends ManagerBase implements RulesManager, R return null; } + @Override + public List listAssociatedRulesForGuestNic(Nic nic) { + // TODO Auto-generated method stub + return null; + } + } diff --git a/server/test/com/cloud/network/security/SecurityGroupManagerTestConfiguration.java b/server/test/com/cloud/network/security/SecurityGroupManagerTestConfiguration.java index b3a9ff12dab..e2e9d68c013 100644 --- a/server/test/com/cloud/network/security/SecurityGroupManagerTestConfiguration.java +++ b/server/test/com/cloud/network/security/SecurityGroupManagerTestConfiguration.java @@ -19,6 +19,7 @@ package com.cloud.network.security; import java.io.IOException; +import org.apache.cloudstack.test.utils.SpringUtils; import org.mockito.Mockito; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.ComponentScan; @@ -60,7 +61,6 @@ import com.cloud.tags.dao.ResourceTagsDaoImpl; import com.cloud.user.AccountManager; import com.cloud.user.DomainManager; import com.cloud.user.dao.AccountDaoImpl; -import com.cloud.utils.component.SpringComponentScanUtils; import com.cloud.vm.UserVmManager; import com.cloud.vm.VirtualMachineManager; import com.cloud.vm.dao.NicDaoImpl; @@ -151,7 +151,7 @@ public class SecurityGroupManagerTestConfiguration { public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { mdr.getClassMetadata().getClassName(); ComponentScan cs = SecurityGroupManagerTestConfiguration.class.getAnnotation(ComponentScan.class); - return SpringComponentScanUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); } } diff --git a/server/test/com/cloud/snapshot/SnapshotDaoTestConfiguration.java b/server/test/com/cloud/snapshot/SnapshotDaoTestConfiguration.java index cc410dbc4ca..6695edc0225 100644 --- a/server/test/com/cloud/snapshot/SnapshotDaoTestConfiguration.java +++ b/server/test/com/cloud/snapshot/SnapshotDaoTestConfiguration.java @@ -19,6 +19,7 @@ package com.cloud.snapshot; import java.io.IOException; +import org.apache.cloudstack.test.utils.SpringUtils; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.ComponentScan.Filter; import org.springframework.context.annotation.Configuration; @@ -36,7 +37,6 @@ import com.cloud.host.dao.HostTagsDaoImpl; import com.cloud.storage.dao.SnapshotDaoImpl; import com.cloud.storage.dao.VolumeDaoImpl; import com.cloud.tags.dao.ResourceTagsDaoImpl; -import com.cloud.utils.component.SpringComponentScanUtils; import com.cloud.vm.dao.NicDaoImpl; import com.cloud.vm.dao.VMInstanceDaoImpl; @@ -65,7 +65,7 @@ public class SnapshotDaoTestConfiguration { public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { mdr.getClassMetadata().getClassName(); ComponentScan cs = SnapshotDaoTestConfiguration.class.getAnnotation(ComponentScan.class); - return SpringComponentScanUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); } } diff --git a/server/test/com/cloud/storage/dao/StoragePoolDaoTestConfiguration.java b/server/test/com/cloud/storage/dao/StoragePoolDaoTestConfiguration.java index 58de4d2730b..2f79ff04258 100644 --- a/server/test/com/cloud/storage/dao/StoragePoolDaoTestConfiguration.java +++ b/server/test/com/cloud/storage/dao/StoragePoolDaoTestConfiguration.java @@ -20,6 +20,7 @@ package com.cloud.storage.dao; import java.io.IOException; import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDaoImpl; +import org.apache.cloudstack.test.utils.SpringUtils; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.ComponentScan.Filter; import org.springframework.context.annotation.Configuration; @@ -28,7 +29,6 @@ import org.springframework.core.type.classreading.MetadataReader; import org.springframework.core.type.classreading.MetadataReaderFactory; import org.springframework.core.type.filter.TypeFilter; -import com.cloud.utils.component.SpringComponentScanUtils; @Configuration @ComponentScan(basePackageClasses={ @@ -46,7 +46,7 @@ public class StoragePoolDaoTestConfiguration { public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { mdr.getClassMetadata().getClassName(); ComponentScan cs = StoragePoolDaoTestConfiguration.class.getAnnotation(ComponentScan.class); - return SpringComponentScanUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); } } diff --git a/server/test/com/cloud/vm/MockUserVmManagerImpl.java b/server/test/com/cloud/vm/MockUserVmManagerImpl.java index d886fd8697f..8b0b1c797c0 100644 --- a/server/test/com/cloud/vm/MockUserVmManagerImpl.java +++ b/server/test/com/cloud/vm/MockUserVmManagerImpl.java @@ -401,14 +401,14 @@ public class MockUserVmManagerImpl extends ManagerBase implements UserVmManager, } @Override - public UserVm restoreVM(RestoreVMCmd cmd) { + public UserVm restoreVM(RestoreVMCmd cmd) throws InsufficientCapacityException, ResourceUnavailableException{ // TODO Auto-generated method stub return null; } @Override - public UserVm upgradeVirtualMachine(ScaleVMCmd scaleVMCmd) throws ResourceUnavailableException, ConcurrentOperationException, ManagementServerException, VirtualMachineMigrationException { - return null; //To change body of implemented methods use File | Settings | File Templates. + public boolean upgradeVirtualMachine(ScaleVMCmd scaleVMCmd) throws ResourceUnavailableException, ConcurrentOperationException, ManagementServerException, VirtualMachineMigrationException { + return false; //To change body of implemented methods use File | Settings | File Templates. } diff --git a/server/test/com/cloud/vm/UserVmManagerTest.java b/server/test/com/cloud/vm/UserVmManagerTest.java index e5e2ff2c0a8..dfd7465aba0 100755 --- a/server/test/com/cloud/vm/UserVmManagerTest.java +++ b/server/test/com/cloud/vm/UserVmManagerTest.java @@ -17,19 +17,26 @@ package com.cloud.vm; +import static org.mockito.Matchers.any; import static org.mockito.Matchers.anyBoolean; import static org.mockito.Matchers.anyFloat; import static org.mockito.Matchers.anyInt; import static org.mockito.Matchers.anyLong; +import static org.mockito.Matchers.anyString; import static org.mockito.Matchers.eq; import static org.mockito.Mockito.doNothing; import static org.mockito.Mockito.doReturn; +import static org.mockito.Mockito.doThrow; import static org.mockito.Mockito.when; import java.lang.reflect.Field; import java.util.List; +import java.util.UUID; +import org.apache.cloudstack.acl.ControlledEntity; +import org.apache.cloudstack.acl.SecurityChecker.AccessType; import org.apache.cloudstack.api.ServerApiException; +import org.apache.cloudstack.api.command.admin.vm.AssignVMCmd; import org.apache.cloudstack.api.command.user.vm.RestoreVMCmd; import org.apache.cloudstack.api.command.user.vm.ScaleVMCmd; import org.junit.Before; @@ -44,9 +51,11 @@ import com.cloud.configuration.dao.ConfigurationDao; import com.cloud.exception.ConcurrentOperationException; import com.cloud.exception.InsufficientCapacityException; import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.PermissionDeniedException; import com.cloud.exception.ResourceAllocationException; import com.cloud.exception.ResourceUnavailableException; import com.cloud.hypervisor.Hypervisor; +import com.cloud.hypervisor.Hypervisor.HypervisorType; import com.cloud.offering.ServiceOffering; import com.cloud.service.ServiceOfferingVO; import com.cloud.storage.VMTemplateVO; @@ -57,6 +66,7 @@ import com.cloud.storage.dao.VMTemplateDao; import com.cloud.storage.dao.VolumeDao; import com.cloud.user.Account; import com.cloud.user.AccountManager; +import com.cloud.user.AccountService; import com.cloud.user.AccountVO; import com.cloud.user.UserContext; import com.cloud.user.UserVO; @@ -73,6 +83,7 @@ public class UserVmManagerTest { @Mock VolumeManager _storageMgr; @Mock Account _account; @Mock AccountManager _accountMgr; + @Mock AccountService _accountService; @Mock ConfigurationManager _configMgr; @Mock CapacityManager _capacityMgr; @Mock AccountDao _accountDao; @@ -91,6 +102,7 @@ public class UserVmManagerTest { @Mock VMTemplateVO _templateMock; @Mock VolumeVO _volumeMock; @Mock List _rootVols; + @Mock Account _accountMock2; @Before public void setup(){ MockitoAnnotations.initMocks(this); @@ -102,6 +114,7 @@ public class UserVmManagerTest { _userVmMgr._itMgr = _itMgr; _userVmMgr.volumeMgr = _storageMgr; _userVmMgr._accountDao = _accountDao; + _userVmMgr._accountService = _accountService; _userVmMgr._userDao = _userDao; _userVmMgr._accountMgr = _accountMgr; _userVmMgr._configMgr = _configMgr; @@ -121,7 +134,7 @@ public class UserVmManagerTest { // Test restoreVm when VM state not in running/stopped case @Test(expected=CloudRuntimeException.class) - public void testRestoreVMF1() throws ResourceAllocationException { + public void testRestoreVMF1() throws ResourceAllocationException, InsufficientCapacityException, ResourceUnavailableException { when(_vmDao.findById(anyLong())).thenReturn(_vmMock); when(_templateDao.findById(anyLong())).thenReturn(_templateMock); @@ -370,6 +383,74 @@ public class UserVmManagerTest { return serviceOffering; } - + // Test Move VM b/w accounts where caller is not ROOT/Domain admin + @Test(expected=InvalidParameterValueException.class) + public void testMoveVmToUser1() throws Exception { + AssignVMCmd cmd = new AssignVMCmd(); + Class _class = cmd.getClass(); + + Field virtualmachineIdField = _class.getDeclaredField("virtualMachineId"); + virtualmachineIdField.setAccessible(true); + virtualmachineIdField.set(cmd, 1L); + + Field accountNameField = _class.getDeclaredField("accountName"); + accountNameField.setAccessible(true); + accountNameField.set(cmd, "account"); + + Field domainIdField = _class.getDeclaredField("domainId"); + domainIdField.setAccessible(true); + domainIdField.set(cmd, 1L); + + // caller is of type 0 + Account caller = (Account) new AccountVO("testaccount", 1, "networkdomain", (short) 0, + UUID.randomUUID().toString()); + UserContext.registerContext(1, caller, null, true); + + _userVmMgr.moveVMToUser(cmd); + } + + + // Test Move VM b/w accounts where caller doesn't have access to the old or new account + @Test(expected=PermissionDeniedException.class) + public void testMoveVmToUser2() throws Exception { + AssignVMCmd cmd = new AssignVMCmd(); + Class _class = cmd.getClass(); + + Field virtualmachineIdField = _class.getDeclaredField("virtualMachineId"); + virtualmachineIdField.setAccessible(true); + virtualmachineIdField.set(cmd, 1L); + + Field accountNameField = _class.getDeclaredField("accountName"); + accountNameField.setAccessible(true); + accountNameField.set(cmd, "account"); + + Field domainIdField = _class.getDeclaredField("domainId"); + domainIdField.setAccessible(true); + domainIdField.set(cmd, 1L); + + // caller is of type 0 + Account caller = (Account) new AccountVO("testaccount", 1, "networkdomain", (short) 1, + UUID.randomUUID().toString()); + UserContext.registerContext(1, caller, null, true); + + Account oldAccount = (Account) new AccountVO("testaccount", 1, "networkdomain", (short) 0, + UUID.randomUUID().toString()); + Account newAccount = (Account) new AccountVO("testaccount", 1, "networkdomain", (short) 1, + UUID.randomUUID().toString()); + + UserVmVO vm = new UserVmVO(10L, "test", "test", 1L, HypervisorType.Any, 1L, false, false, 1L, 1L, + 5L, "test", "test", 1L); + vm.setState(VirtualMachine.State.Stopped); + when(_vmDao.findById(anyLong())).thenReturn(vm); + + when(_accountService.getActiveAccountById(anyLong())).thenReturn(oldAccount); + + when(_accountService.getActiveAccountByName(anyString(), anyLong())).thenReturn(newAccount); + + doThrow(new PermissionDeniedException("Access check failed")).when(_accountMgr).checkAccess(any(Account.class), any(AccessType.class), + any(Boolean.class), any(ControlledEntity.class)); + + _userVmMgr.moveVMToUser(cmd); + } } \ No newline at end of file diff --git a/server/test/com/cloud/vm/dao/UserVmCloneSettingDaoTestConfiguration.java b/server/test/com/cloud/vm/dao/UserVmCloneSettingDaoTestConfiguration.java index 6e22e174f58..3bd4df8543f 100644 --- a/server/test/com/cloud/vm/dao/UserVmCloneSettingDaoTestConfiguration.java +++ b/server/test/com/cloud/vm/dao/UserVmCloneSettingDaoTestConfiguration.java @@ -19,6 +19,7 @@ package com.cloud.vm.dao; import java.io.IOException; +import org.apache.cloudstack.test.utils.SpringUtils; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.ComponentScan.Filter; import org.springframework.context.annotation.Configuration; @@ -27,7 +28,6 @@ import org.springframework.core.type.classreading.MetadataReader; import org.springframework.core.type.classreading.MetadataReaderFactory; import org.springframework.core.type.filter.TypeFilter; -import com.cloud.utils.component.SpringComponentScanUtils; import com.cloud.vm.dao.UserVmCloneSettingDaoImpl; @Configuration @@ -45,7 +45,7 @@ public class UserVmCloneSettingDaoTestConfiguration { public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { mdr.getClassMetadata().getClassName(); ComponentScan cs = UserVmCloneSettingDaoTestConfiguration.class.getAnnotation(ComponentScan.class); - return SpringComponentScanUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); } } diff --git a/server/test/com/cloud/vm/dao/UserVmDaoTestConfiguration.java b/server/test/com/cloud/vm/dao/UserVmDaoTestConfiguration.java index 6a63fabd44b..7af772c1b17 100644 --- a/server/test/com/cloud/vm/dao/UserVmDaoTestConfiguration.java +++ b/server/test/com/cloud/vm/dao/UserVmDaoTestConfiguration.java @@ -19,6 +19,7 @@ package com.cloud.vm.dao; import java.io.IOException; +import org.apache.cloudstack.test.utils.SpringUtils; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.ComponentScan.Filter; import org.springframework.context.annotation.Configuration; @@ -27,7 +28,6 @@ import org.springframework.core.type.classreading.MetadataReader; import org.springframework.core.type.classreading.MetadataReaderFactory; import org.springframework.core.type.filter.TypeFilter; -import com.cloud.utils.component.SpringComponentScanUtils; @Configuration @ComponentScan(basePackageClasses={ @@ -43,7 +43,7 @@ public class UserVmDaoTestConfiguration { public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { mdr.getClassMetadata().getClassName(); ComponentScan cs = UserVmDaoTestConfiguration.class.getAnnotation(ComponentScan.class); - return SpringComponentScanUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); } } diff --git a/server/test/com/cloud/vpc/MockConfigurationManagerImpl.java b/server/test/com/cloud/vpc/MockConfigurationManagerImpl.java index d00062c8c70..838be00a8cf 100755 --- a/server/test/com/cloud/vpc/MockConfigurationManagerImpl.java +++ b/server/test/com/cloud/vpc/MockConfigurationManagerImpl.java @@ -285,7 +285,7 @@ public class MockConfigurationManagerImpl extends ManagerBase implements Configu * @see com.cloud.configuration.ConfigurationService#getNetworkOfferingNetworkRate(long) */ @Override - public Integer getNetworkOfferingNetworkRate(long networkOfferingId) { + public Integer getNetworkOfferingNetworkRate(long networkOfferingId, Long dataCenterId) { // TODO Auto-generated method stub return null; } @@ -338,7 +338,7 @@ public class MockConfigurationManagerImpl extends ManagerBase implements Configu * @see com.cloud.configuration.ConfigurationService#getServiceOfferingNetworkRate(long) */ @Override - public Integer getServiceOfferingNetworkRate(long serviceOfferingId) { + public Integer getServiceOfferingNetworkRate(long serviceOfferingId, Long dataCenterId) { // TODO Auto-generated method stub return null; } @@ -448,9 +448,9 @@ public class MockConfigurationManagerImpl extends ManagerBase implements Configu * @see com.cloud.configuration.ConfigurationManager#updateConfiguration(long, java.lang.String, java.lang.String, java.lang.String) */ @Override - public void updateConfiguration(long userId, String name, String category, String value, String scope, Long resourceId) { + public String updateConfiguration(long userId, String name, String category, String value, String scope, Long resourceId) { // TODO Auto-generated method stub - + return null; } /* (non-Javadoc) @@ -523,7 +523,7 @@ public class MockConfigurationManagerImpl extends ManagerBase implements Configu @Override public NetworkOfferingVO createNetworkOffering(String name, String displayText, TrafficType trafficType, String tags, boolean specifyVlan, Availability availability, Integer networkRate, Map> serviceProviderMap, boolean isDefault, GuestType type, boolean systemOnly, Long serviceOfferingId, boolean conserveMode, - Map> serviceCapabilityMap, boolean specifyIpRanges, boolean isPersistent) { + Map> serviceCapabilityMap, boolean specifyIpRanges, boolean isPersistent, Map details) { // TODO Auto-generated method stub return null; } diff --git a/server/test/com/cloud/vpc/MockNetworkManagerImpl.java b/server/test/com/cloud/vpc/MockNetworkManagerImpl.java index 82a80c1486a..88769632a2d 100644 --- a/server/test/com/cloud/vpc/MockNetworkManagerImpl.java +++ b/server/test/com/cloud/vpc/MockNetworkManagerImpl.java @@ -16,18 +16,53 @@ // under the License. package com.cloud.vpc; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import javax.ejb.Local; +import javax.inject.Inject; +import javax.naming.ConfigurationException; + +import org.apache.cloudstack.acl.ControlledEntity.ACLType; +import org.apache.cloudstack.api.command.admin.network.DedicateGuestVlanRangeCmd; +import org.apache.cloudstack.api.command.admin.network.ListDedicatedGuestVlanRangesCmd; +import org.apache.cloudstack.api.command.admin.usage.ListTrafficTypeImplementorsCmd; +import org.apache.cloudstack.api.command.user.network.CreateNetworkCmd; +import org.apache.cloudstack.api.command.user.network.ListNetworksCmd; +import org.apache.cloudstack.api.command.user.network.RestartNetworkCmd; +import org.apache.cloudstack.api.command.user.vm.ListNicsCmd; +import org.apache.log4j.Logger; +import org.springframework.stereotype.Component; + import com.cloud.dc.DataCenter; import com.cloud.dc.Pod; import com.cloud.dc.Vlan.VlanType; import com.cloud.deploy.DataCenterDeployment; import com.cloud.deploy.DeployDestination; import com.cloud.deploy.DeploymentPlan; -import com.cloud.exception.*; -import com.cloud.network.*; +import com.cloud.exception.ConcurrentOperationException; +import com.cloud.exception.InsufficientAddressCapacityException; +import com.cloud.exception.InsufficientCapacityException; +import com.cloud.exception.InsufficientVirtualNetworkCapcityException; +import com.cloud.exception.ResourceAllocationException; +import com.cloud.exception.ResourceUnavailableException; +import com.cloud.network.GuestVlan; +import com.cloud.network.IpAddress; +import com.cloud.network.Network; import com.cloud.network.Network.Provider; import com.cloud.network.Network.Service; +import com.cloud.network.NetworkManager; +import com.cloud.network.NetworkProfile; +import com.cloud.network.NetworkRuleApplier; +import com.cloud.network.NetworkService; import com.cloud.network.Networks.TrafficType; +import com.cloud.network.PhysicalNetwork; +import com.cloud.network.PhysicalNetworkServiceProvider; +import com.cloud.network.PhysicalNetworkTrafficType; +import com.cloud.network.PublicIpAddress; import com.cloud.network.addr.PublicIp; +import com.cloud.network.dao.AccountGuestVlanMapVO; import com.cloud.network.dao.IPAddressVO; import com.cloud.network.dao.NetworkServiceMapDao; import com.cloud.network.dao.NetworkVO; @@ -39,6 +74,7 @@ import com.cloud.network.guru.NetworkGuru; import com.cloud.network.rules.FirewallRule; import com.cloud.network.rules.FirewallRule.Purpose; import com.cloud.network.rules.FirewallRule.State; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; import com.cloud.network.rules.StaticNat; import com.cloud.offering.NetworkOffering; import com.cloud.offerings.NetworkOfferingVO; @@ -56,8 +92,9 @@ import com.cloud.vm.VMInstanceVO; import com.cloud.vm.VirtualMachine; import com.cloud.vm.VirtualMachine.Type; import com.cloud.vm.VirtualMachineProfile; -import com.cloud.vm.VirtualMachineProfileImpl; import org.apache.cloudstack.acl.ControlledEntity.ACLType; +import org.apache.cloudstack.api.command.admin.network.DedicateGuestVlanRangeCmd; +import org.apache.cloudstack.api.command.admin.network.ListDedicatedGuestVlanRangesCmd; import org.apache.cloudstack.api.command.admin.usage.ListTrafficTypeImplementorsCmd; import org.apache.cloudstack.api.command.user.network.CreateNetworkCmd; import org.apache.cloudstack.api.command.user.network.ListNetworksCmd; @@ -66,12 +103,6 @@ import org.apache.cloudstack.api.command.user.vm.ListNicsCmd; import org.apache.log4j.Logger; import org.springframework.stereotype.Component; -import javax.ejb.Local; -import javax.inject.Inject; -import javax.naming.ConfigurationException; -import java.util.HashMap; -import java.util.List; -import java.util.Map; @Component @Local(value = { NetworkManager.class, NetworkService.class }) @@ -348,9 +379,24 @@ public class MockNetworkManagerImpl extends ManagerBase implements NetworkManage return false; } + @Override + public GuestVlan dedicateGuestVlanRange(DedicateGuestVlanRangeCmd cmd) { + // TODO Auto-generated method stub + return null; + } + @Override + public Pair, Integer> listDedicatedGuestVlanRanges(ListDedicatedGuestVlanRangesCmd cmd) { + // TODO Auto-generated method stub + return null; + } + @Override + public boolean releaseDedicatedGuestVlanRange(Long dedicatedGuestVlanRangeId) { + // TODO Auto-generated method stub + return true; + } /* (non-Javadoc) * @see com.cloud.network.NetworkService#listNetworkServices(java.lang.String) @@ -611,7 +657,7 @@ public class MockNetworkManagerImpl extends ManagerBase implements NetworkManage */ @Override public Network createPrivateNetwork(String networkName, String displayText, long physicalNetworkId, String vlan, - String startIp, String endIP, String gateway, String netmask, long networkOwnerId, Long vpcId) + String startIp, String endIP, String gateway, String netmask, long networkOwnerId, Long vpcId, Boolean sourceNat) throws ResourceAllocationException, ConcurrentOperationException, InsufficientCapacityException { // TODO Auto-generated method stub return null; @@ -1293,7 +1339,7 @@ public class MockNetworkManagerImpl extends ManagerBase implements NetworkManage } @Override - public LoadBalancingServiceProvider getLoadBalancingProviderForNetwork(Network network) { + public LoadBalancingServiceProvider getLoadBalancingProviderForNetwork(Network network, Scheme lbScheme) { // TODO Auto-generated method stub return null; } diff --git a/server/test/com/cloud/vpc/MockNetworkModelImpl.java b/server/test/com/cloud/vpc/MockNetworkModelImpl.java index 9857964d911..d9e33b75616 100644 --- a/server/test/com/cloud/vpc/MockNetworkModelImpl.java +++ b/server/test/com/cloud/vpc/MockNetworkModelImpl.java @@ -37,6 +37,7 @@ import com.cloud.network.Network.GuestType; import com.cloud.network.Network.Provider; import com.cloud.network.Network.Service; import com.cloud.network.NetworkModel; +import com.cloud.network.Networks.IsolationType; import com.cloud.network.Networks.TrafficType; import com.cloud.network.PhysicalNetwork; import com.cloud.network.PhysicalNetworkSetupInfo; @@ -46,6 +47,7 @@ import com.cloud.network.dao.NetworkVO; import com.cloud.network.element.NetworkElement; import com.cloud.network.element.UserDataServiceProvider; import com.cloud.offering.NetworkOffering; +import com.cloud.offering.NetworkOffering.Detail; import com.cloud.offerings.NetworkOfferingVO; import com.cloud.offerings.dao.NetworkOfferingServiceMapDao; import com.cloud.user.Account; @@ -581,7 +583,7 @@ public class MockNetworkModelImpl extends ManagerBase implements NetworkModel { * @see com.cloud.network.NetworkModel#getDefaultNetworkDomain() */ @Override - public String getDefaultNetworkDomain() { + public String getDefaultNetworkDomain(long zoneId) { // TODO Auto-generated method stub return null; } @@ -863,4 +865,26 @@ public class MockNetworkModelImpl extends ManagerBase implements NetworkModel { return null; } + @Override + public IpAddress getPublicIpAddress(String ipAddress, long zoneId) { + // TODO Auto-generated method stub + return null; + } + + @Override + public List getUsedIpsInNetwork(Network network) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Map getNtwkOffDetails(long offId) { + return null; + } + + public IsolationType[] listNetworkIsolationMethods() { + // TODO Auto-generated method stub + return null; + } + } diff --git a/server/test/com/cloud/vpc/MockVpcManagerImpl.java b/server/test/com/cloud/vpc/MockVpcManagerImpl.java index 0f269284127..baccbd045d2 100644 --- a/server/test/com/cloud/vpc/MockVpcManagerImpl.java +++ b/server/test/com/cloud/vpc/MockVpcManagerImpl.java @@ -164,7 +164,7 @@ public class MockVpcManagerImpl extends ManagerBase implements VpcManager { * @see com.cloud.network.vpc.VpcService#createVpcPrivateGateway(long, java.lang.Long, java.lang.String, java.lang.String, java.lang.String, java.lang.String, long) */ @Override - public PrivateGateway createVpcPrivateGateway(long vpcId, Long physicalNetworkId, String vlan, String ipAddress, String gateway, String netmask, long gatewayOwnerId) throws ResourceAllocationException, + public PrivateGateway createVpcPrivateGateway(long vpcId, Long physicalNetworkId, String vlan, String ipAddress, String gateway, String netmask, long gatewayOwnerId, Boolean isSourceNat) throws ResourceAllocationException, ConcurrentOperationException, InsufficientCapacityException { // TODO Auto-generated method stub return null; diff --git a/server/test/com/cloud/vpc/MockVpcVirtualNetworkApplianceManager.java b/server/test/com/cloud/vpc/MockVpcVirtualNetworkApplianceManager.java index ef5478bb1f8..9010f1f5acb 100644 --- a/server/test/com/cloud/vpc/MockVpcVirtualNetworkApplianceManager.java +++ b/server/test/com/cloud/vpc/MockVpcVirtualNetworkApplianceManager.java @@ -36,6 +36,7 @@ import com.cloud.network.RemoteAccessVpn; import com.cloud.network.Site2SiteVpnConnection; import com.cloud.network.VpcVirtualNetworkApplianceService; import com.cloud.network.VpnUser; +import com.cloud.network.lb.LoadBalancingRule; import com.cloud.network.router.VirtualRouter; import com.cloud.network.router.VpcVirtualNetworkApplianceManager; import com.cloud.network.rules.FirewallRule; @@ -46,7 +47,6 @@ import com.cloud.network.vpc.Vpc; import com.cloud.user.Account; import com.cloud.user.User; import com.cloud.uservm.UserVm; -import com.cloud.utils.component.Manager; import com.cloud.utils.component.ManagerBase; import com.cloud.vm.DomainRouterVO; import com.cloud.vm.NicProfile; @@ -402,4 +402,16 @@ VpcVirtualNetworkApplianceService { return null; } + @Override + public boolean applyLoadBalancingRules(Network network, List rules, List routers) throws ResourceUnavailableException { + // TODO Auto-generated method stub + return false; + } + + @Override + public VirtualRouter findRouter(long routerId) { + // TODO Auto-generated method stub + return null; + } + } diff --git a/server/test/com/cloud/vpc/VpcTest.java b/server/test/com/cloud/vpc/VpcTest.java new file mode 100644 index 00000000000..52e837ec5ca --- /dev/null +++ b/server/test/com/cloud/vpc/VpcTest.java @@ -0,0 +1,269 @@ +// Licensed to the Apache Software Foundation (ASF) under one or more +// contributor license agreements. See the NOTICE file distributed with +// this work for additional information regarding copyright ownership. +// The ASF licenses this file to You under the Apache License, Version 2.0 +// (the "License"); you may not use this file except in compliance with +// the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package com.cloud.vpc; + +import com.cloud.configuration.ConfigurationManager; +import com.cloud.configuration.dao.ConfigurationDao; +import com.cloud.dc.dao.DataCenterDao; +import com.cloud.dc.dao.VlanDao; +import com.cloud.network.NetworkManager; +import com.cloud.network.NetworkModel; +import com.cloud.network.NetworkService; +import com.cloud.network.dao.FirewallRulesDao; +import com.cloud.network.dao.IPAddressDao; +import com.cloud.network.dao.NetworkDao; +import com.cloud.network.dao.PhysicalNetworkDao; +import com.cloud.network.dao.Site2SiteVpnGatewayDao; +import com.cloud.network.vpc.*; +import com.cloud.network.vpc.dao.PrivateIpDao; +import com.cloud.network.vpc.dao.StaticRouteDao; +import com.cloud.network.vpc.dao.VpcDao; +import com.cloud.network.vpc.dao.VpcGatewayDao; +import com.cloud.network.vpc.dao.VpcOfferingDao; +import com.cloud.network.vpc.dao.VpcOfferingServiceMapDao; +import com.cloud.network.vpc.dao.VpcServiceMapDao; +import com.cloud.network.vpn.Site2SiteVpnManager; +import com.cloud.offerings.dao.NetworkOfferingServiceMapDao; +import com.cloud.server.ConfigurationServer; +import com.cloud.tags.dao.ResourceTagDao; +import com.cloud.user.Account; +import com.cloud.user.AccountManager; +import com.cloud.user.AccountVO; +import com.cloud.user.ResourceLimitService; +import com.cloud.user.UserContext; +import com.cloud.utils.component.ComponentContext; +import com.cloud.vm.dao.DomainRouterDao; + +import junit.framework.TestCase; +import org.apache.cloudstack.api.command.user.network.CreateNetworkACLCmd; +import org.apache.cloudstack.api.command.user.vpc.CreateVPCCmd; +import org.apache.cloudstack.test.utils.SpringUtils; +import org.apache.log4j.Logger; +import org.junit.Before; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.mockito.Mockito; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.ComponentScan; +import org.springframework.context.annotation.Configuration; +import org.springframework.context.annotation.FilterType; +import org.springframework.core.type.classreading.MetadataReader; +import org.springframework.core.type.classreading.MetadataReaderFactory; +import org.springframework.core.type.filter.TypeFilter; +import org.springframework.test.context.ContextConfiguration; +import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; +import org.springframework.test.context.support.AnnotationConfigContextLoader; + +import javax.inject.Inject; +import java.io.IOException; +import java.util.UUID; + +@RunWith(SpringJUnit4ClassRunner.class) +@ContextConfiguration(loader = AnnotationConfigContextLoader.class) +public class VpcTest extends TestCase { + + @Inject + VpcService _vpcService; + + @Inject + AccountManager _accountMgr; + + @Inject + VpcManager _vpcMgr; + + @Inject + VpcDao _vpcDao; + + @Inject + VpcOfferingDao _vpcOfferinDao; + + private VpcVO vpc; + private static final Logger s_logger = Logger.getLogger(VpcTest.class); + + @Before + public void setUp() { + ComponentContext.initComponentsLifeCycle(); + Account account = new AccountVO("testaccount", 1, "testdomain", (short) 0, UUID.randomUUID().toString()); + UserContext.registerContext(1, account, null, true); + vpc = new VpcVO(1, "myvpc", "myvpc", 2, 1, 1, "10.0.1.0/16", "mydomain"); + } + + @Test + public void testCreateVpc() throws Exception { + Mockito.when( + _vpcMgr.createVpc(Mockito.anyLong(), Mockito.anyLong(), Mockito.anyLong(), Mockito.anyString(), + Mockito.anyString(), Mockito.anyString(), Mockito.anyString())).thenReturn(vpc); + Mockito.when(_vpcOfferinDao.persist(Mockito.any(VpcOfferingVO.class))).thenReturn( + new VpcOfferingVO("test", "test", 1L)); + Vpc vpc1 = _vpcMgr.createVpc(1, 1, 1, "myVpc", "my Vpc", "10.0.0.0/16", "test"); + assertNotNull("Vpc is created", vpc1); + } + + @Configuration + @ComponentScan(basePackageClasses = { VpcManager.class }, includeFilters = { @ComponentScan.Filter(value = VpcTestConfiguration.Library.class, type = FilterType.CUSTOM) }, useDefaultFilters = false) + public static class VpcTestConfiguration extends SpringUtils.CloudStackTestConfiguration { + + @Bean + public AccountManager accountManager() { + return Mockito.mock(AccountManager.class); + } + + @Bean + public NetworkManager networkManager() { + return Mockito.mock(NetworkManager.class); + } + + @Bean + public NetworkModel networkModel() { + return Mockito.mock(NetworkModel.class); + } + + @Bean + public VpcManager vpcManager() { + return Mockito.mock(VpcManager.class); + } + + @Bean + public ResourceTagDao resourceTagDao() { + return Mockito.mock(ResourceTagDao.class); + } + + @Bean + public VpcDao VpcDao() { + return Mockito.mock(VpcDao.class); + } + + @Bean + public VpcOfferingDao vpcOfferingDao() { + return Mockito.mock(VpcOfferingDao.class); + } + + @Bean + public VpcOfferingServiceMapDao vpcOfferingServiceMapDao() { + return Mockito.mock(VpcOfferingServiceMapDao.class); + } + + @Bean + public ConfigurationDao configurationDao() { + return Mockito.mock(ConfigurationDao.class); + } + + @Bean + public ConfigurationManager configurationManager() { + return Mockito.mock(ConfigurationManager.class); + } + + @Bean + public NetworkDao networkDao() { + return Mockito.mock(NetworkDao.class); + } + + @Bean + public NetworkACLManager networkACLManager() { + return Mockito.mock(NetworkACLManager.class); + } + + @Bean + public IPAddressDao ipAddressDao() { + return Mockito.mock(IPAddressDao.class); + } + + @Bean + public DomainRouterDao domainRouterDao() { + return Mockito.mock(DomainRouterDao.class); + } + + @Bean + public VpcGatewayDao vpcGatewayDao() { + return Mockito.mock(VpcGatewayDao.class); + } + + @Bean + public PrivateIpDao privateIpDao() { + return Mockito.mock(PrivateIpDao.class); + } + + @Bean + public StaticRouteDao staticRouteDao() { + return Mockito.mock(StaticRouteDao.class); + } + + @Bean + public NetworkOfferingServiceMapDao networkOfferingServiceMapDao() { + return Mockito.mock(NetworkOfferingServiceMapDao.class); + } + + @Bean + public PhysicalNetworkDao physicalNetworkDao() { + return Mockito.mock(PhysicalNetworkDao.class); + } + + @Bean + public FirewallRulesDao firewallRulesDao() { + return Mockito.mock(FirewallRulesDao.class); + } + + @Bean + public Site2SiteVpnGatewayDao site2SiteVpnGatewayDao() { + return Mockito.mock(Site2SiteVpnGatewayDao.class); + } + + @Bean + public Site2SiteVpnManager site2SiteVpnManager() { + return Mockito.mock(Site2SiteVpnManager.class); + } + + @Bean + public VlanDao vlanDao() { + return Mockito.mock(VlanDao.class); + } + + @Bean + public ResourceLimitService resourceLimitService() { + return Mockito.mock(ResourceLimitService.class); + } + + @Bean + public VpcServiceMapDao vpcServiceMapDao() { + return Mockito.mock(VpcServiceMapDao.class); + } + + @Bean + public NetworkService networkService() { + return Mockito.mock(NetworkService.class); + } + + @Bean + public DataCenterDao dataCenterDao() { + return Mockito.mock(DataCenterDao.class); + } + + @Bean + public ConfigurationServer configurationServer() { + return Mockito.mock(ConfigurationServer.class); + } + + public static class Library implements TypeFilter { + @Override + public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { + mdr.getClassMetadata().getClassName(); + ComponentScan cs = VpcTestConfiguration.class.getAnnotation(ComponentScan.class); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + } + } + } + +} diff --git a/server/test/com/cloud/vpc/VpcTestConfiguration.java b/server/test/com/cloud/vpc/VpcTestConfiguration.java index b1f2f80c076..7ae83f3a9c9 100644 --- a/server/test/com/cloud/vpc/VpcTestConfiguration.java +++ b/server/test/com/cloud/vpc/VpcTestConfiguration.java @@ -19,6 +19,7 @@ package com.cloud.vpc; import java.io.IOException; +import org.apache.cloudstack.test.utils.SpringUtils; import org.mockito.Mockito; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.ComponentScan; @@ -91,7 +92,6 @@ import com.cloud.tags.dao.ResourceTagsDaoImpl; import com.cloud.user.AccountManager; import com.cloud.user.dao.AccountDaoImpl; import com.cloud.user.dao.UserStatisticsDaoImpl; -import com.cloud.utils.component.SpringComponentScanUtils; import com.cloud.vm.UserVmManager; import com.cloud.vm.dao.DomainRouterDaoImpl; import com.cloud.vm.dao.NicDaoImpl; @@ -236,7 +236,7 @@ public class VpcTestConfiguration { public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { mdr.getClassMetadata().getClassName(); ComponentScan cs = VpcTestConfiguration.class.getAnnotation(ComponentScan.class); - return SpringComponentScanUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); } } } diff --git a/server/test/com/cloud/vpc/dao/MockNetworkOfferingDaoImpl.java b/server/test/com/cloud/vpc/dao/MockNetworkOfferingDaoImpl.java index dbf14113de4..a8208dd7d9c 100644 --- a/server/test/com/cloud/vpc/dao/MockNetworkOfferingDaoImpl.java +++ b/server/test/com/cloud/vpc/dao/MockNetworkOfferingDaoImpl.java @@ -101,28 +101,28 @@ public class MockNetworkOfferingDaoImpl extends NetworkOfferingDaoImpl implement if (id.longValue() == 1) { //network offering valid for vpc vo = new NetworkOfferingVO("vpc", "vpc", TrafficType.Guest, false, true, null, null, false, - Availability.Optional, null, Network.GuestType.Isolated, false, false, false); + Availability.Optional, null, Network.GuestType.Isolated, false, false, false, false, false); } else if (id.longValue() == 2) { //invalid offering - source nat is not included vo = new NetworkOfferingVO("vpc", "vpc", TrafficType.Guest, false, true, null, null, false, - Availability.Optional, null, Network.GuestType.Isolated, false, false, false); + Availability.Optional, null, Network.GuestType.Isolated, false, false, false, false, false); } else if (id.longValue() == 3) { //network offering invalid for vpc (conserve mode off) vo = new NetworkOfferingVO("non vpc", "non vpc", TrafficType.Guest, false, true, null, null, false, - Availability.Optional, null, Network.GuestType.Isolated, true, false, false); + Availability.Optional, null, Network.GuestType.Isolated, true, false, false, false, false); } else if (id.longValue() == 4) { //network offering invalid for vpc (Shared) vo = new NetworkOfferingVO("non vpc", "non vpc", TrafficType.Guest, false, true, null, null, false, - Availability.Optional, null, Network.GuestType.Shared, false, false, false); + Availability.Optional, null, Network.GuestType.Shared, false, false, false, false, false); } else if (id.longValue() == 5) { //network offering invalid for vpc (has redundant router) vo = new NetworkOfferingVO("vpc", "vpc", TrafficType.Guest, false, true, null, null, false, - Availability.Optional, null, Network.GuestType.Isolated, false, false, false); + Availability.Optional, null, Network.GuestType.Isolated, false, false, false, false, false); vo.setRedundantRouter(true); } else if (id.longValue() == 6) { //network offering invalid for vpc (has lb service) vo = new NetworkOfferingVO("vpc", "vpc", TrafficType.Guest, false, true, null, null, false, - Availability.Optional, null, Network.GuestType.Isolated, false, false, false); + Availability.Optional, null, Network.GuestType.Isolated, false, false, false, false, false); } if (vo != null) { diff --git a/server/test/com/cloud/vpc/dao/MockNetworkServiceMapDaoImpl.java b/server/test/com/cloud/vpc/dao/MockNetworkServiceMapDaoImpl.java index 002b61dcbc4..103f04ea8b9 100644 --- a/server/test/com/cloud/vpc/dao/MockNetworkServiceMapDaoImpl.java +++ b/server/test/com/cloud/vpc/dao/MockNetworkServiceMapDaoImpl.java @@ -95,4 +95,10 @@ public class MockNetworkServiceMapDaoImpl extends GenericDaoBase getProvidersForServiceInNetwork(long networkId, Service service) { + // TODO Auto-generated method stub + return null; + } } diff --git a/server/test/org/apache/cloudstack/affinity/AffinityApiTestConfiguration.java b/server/test/org/apache/cloudstack/affinity/AffinityApiTestConfiguration.java deleted file mode 100644 index e92c1cb0f4a..00000000000 --- a/server/test/org/apache/cloudstack/affinity/AffinityApiTestConfiguration.java +++ /dev/null @@ -1,348 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package org.apache.cloudstack.affinity; - -import java.io.IOException; - -import org.apache.cloudstack.acl.SecurityChecker; -import org.apache.cloudstack.affinity.dao.AffinityGroupDao; -import org.apache.cloudstack.affinity.dao.AffinityGroupVMMapDao; -import org.apache.cloudstack.region.PortableIpDaoImpl; -import org.apache.cloudstack.region.PortableIpRangeDaoImpl; -import org.apache.cloudstack.region.dao.RegionDaoImpl; -import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDaoImpl; -import org.mockito.Mockito; -import org.springframework.context.annotation.Bean; -import org.springframework.context.annotation.ComponentScan; -import org.springframework.context.annotation.Configuration; -import org.springframework.context.annotation.FilterType; -import org.springframework.context.annotation.ComponentScan.Filter; -import org.springframework.core.type.classreading.MetadataReader; -import org.springframework.core.type.classreading.MetadataReaderFactory; -import org.springframework.core.type.filter.TypeFilter; -import com.cloud.utils.component.ComponentContext; -import com.cloud.agent.AgentManager; -import com.cloud.alert.AlertManager; -import com.cloud.api.query.dao.UserAccountJoinDaoImpl; -import com.cloud.capacity.dao.CapacityDaoImpl; -import com.cloud.cluster.agentlb.dao.HostTransferMapDaoImpl; -import com.cloud.configuration.dao.ConfigurationDao; -import com.cloud.dc.dao.AccountVlanMapDaoImpl; -import com.cloud.dc.dao.ClusterDaoImpl; -import com.cloud.dc.dao.DataCenterDaoImpl; -import com.cloud.dc.dao.DataCenterIpAddressDaoImpl; -import com.cloud.dc.dao.DataCenterLinkLocalIpAddressDao; -import com.cloud.dc.dao.DataCenterLinkLocalIpAddressDaoImpl; -import com.cloud.dc.dao.DataCenterVnetDaoImpl; -import com.cloud.dc.dao.DcDetailsDaoImpl; -import com.cloud.dc.dao.HostPodDaoImpl; -import com.cloud.dc.dao.PodVlanDaoImpl; -import com.cloud.dc.dao.PodVlanMapDaoImpl; -import com.cloud.dc.dao.VlanDaoImpl; -import com.cloud.domain.dao.DomainDaoImpl; -import com.cloud.event.EventUtils; -import com.cloud.event.dao.EventDao; -import com.cloud.event.dao.EventDaoImpl; -import com.cloud.event.dao.UsageEventDaoImpl; -import com.cloud.host.dao.HostDaoImpl; -import com.cloud.host.dao.HostDetailsDaoImpl; -import com.cloud.host.dao.HostTagsDaoImpl; -import com.cloud.network.Ipv6AddressManager; -import com.cloud.network.NetworkManager; -import com.cloud.network.NetworkModel; -import com.cloud.network.NetworkService; -import com.cloud.network.StorageNetworkManager; -import com.cloud.network.dao.FirewallRulesCidrsDaoImpl; -import com.cloud.network.dao.FirewallRulesDaoImpl; -import com.cloud.network.dao.IPAddressDaoImpl; -import com.cloud.network.dao.LoadBalancerDaoImpl; -import com.cloud.network.dao.NetworkDao; -import com.cloud.network.dao.NetworkDomainDaoImpl; -import com.cloud.network.dao.NetworkServiceMapDaoImpl; -import com.cloud.network.dao.PhysicalNetworkDaoImpl; -import com.cloud.network.dao.PhysicalNetworkServiceProviderDaoImpl; -import com.cloud.network.dao.PhysicalNetworkTrafficTypeDaoImpl; -import com.cloud.network.dao.UserIpv6AddressDaoImpl; -import com.cloud.network.element.DhcpServiceProvider; -import com.cloud.network.element.IpDeployer; -import com.cloud.network.element.NetworkElement; -import com.cloud.network.guru.NetworkGuru; -import com.cloud.network.lb.LoadBalancingRulesManager; -import com.cloud.network.rules.FirewallManager; -import com.cloud.network.rules.RulesManager; -import com.cloud.network.rules.dao.PortForwardingRulesDaoImpl; -import com.cloud.network.vpc.NetworkACLManager; -import com.cloud.network.vpc.VpcManager; -import com.cloud.network.vpc.dao.PrivateIpDaoImpl; -import com.cloud.network.vpn.RemoteAccessVpnService; -import com.cloud.offerings.dao.NetworkOfferingDao; -import com.cloud.offerings.dao.NetworkOfferingServiceMapDao; -import com.cloud.projects.ProjectManager; -import com.cloud.service.dao.ServiceOfferingDaoImpl; -import com.cloud.storage.dao.DiskOfferingDaoImpl; -import com.cloud.storage.dao.S3DaoImpl; -import com.cloud.storage.dao.SnapshotDaoImpl; -import com.cloud.storage.dao.StoragePoolDetailsDaoImpl; -import com.cloud.storage.dao.SwiftDaoImpl; -import com.cloud.storage.dao.VolumeDaoImpl; -import com.cloud.storage.s3.S3Manager; -import com.cloud.storage.secondary.SecondaryStorageVmManager; -import com.cloud.storage.swift.SwiftManager; -import com.cloud.tags.dao.ResourceTagsDaoImpl; -import com.cloud.user.AccountManager; -import com.cloud.user.ResourceLimitService; -import com.cloud.user.UserContext; -import com.cloud.user.UserContextInitializer; -import com.cloud.user.dao.AccountDao; -import com.cloud.user.dao.AccountDaoImpl; -import com.cloud.user.dao.UserDaoImpl; -import com.cloud.utils.component.SpringComponentScanUtils; -import com.cloud.utils.db.GenericDao; -import com.cloud.utils.db.GenericDaoBase; -import com.cloud.vm.UserVmVO; -import com.cloud.vm.dao.InstanceGroupDaoImpl; -import com.cloud.vm.dao.NicDaoImpl; -import com.cloud.vm.dao.NicSecondaryIpDaoImpl; -import com.cloud.vm.dao.UserVmDao; -import com.cloud.vm.dao.VMInstanceDaoImpl; - -@Configuration -@ComponentScan(basePackageClasses = { AccountVlanMapDaoImpl.class, VolumeDaoImpl.class, HostPodDaoImpl.class, - DomainDaoImpl.class, SwiftDaoImpl.class, ServiceOfferingDaoImpl.class, VlanDaoImpl.class, - IPAddressDaoImpl.class, ResourceTagsDaoImpl.class, InstanceGroupDaoImpl.class, - UserAccountJoinDaoImpl.class, CapacityDaoImpl.class, SnapshotDaoImpl.class, HostDaoImpl.class, - VMInstanceDaoImpl.class, HostTransferMapDaoImpl.class, PortForwardingRulesDaoImpl.class, - PrivateIpDaoImpl.class, UsageEventDaoImpl.class, PodVlanMapDaoImpl.class, DiskOfferingDaoImpl.class, - DataCenterDaoImpl.class, DataCenterIpAddressDaoImpl.class, - DataCenterVnetDaoImpl.class, PodVlanDaoImpl.class, DcDetailsDaoImpl.class, NicSecondaryIpDaoImpl.class, - UserIpv6AddressDaoImpl.class, S3DaoImpl.class, UserDaoImpl.class, NicDaoImpl.class, NetworkDomainDaoImpl.class, - HostDetailsDaoImpl.class, HostTagsDaoImpl.class, ClusterDaoImpl.class, FirewallRulesDaoImpl.class, - FirewallRulesCidrsDaoImpl.class, PhysicalNetworkDaoImpl.class, PhysicalNetworkTrafficTypeDaoImpl.class, - PhysicalNetworkServiceProviderDaoImpl.class, LoadBalancerDaoImpl.class, NetworkServiceMapDaoImpl.class, - PrimaryDataStoreDaoImpl.class, StoragePoolDetailsDaoImpl.class, AffinityGroupServiceImpl.class, - ComponentContext.class, AffinityGroupProcessor.class, UserVmVO.class, EventUtils.class, UserVmVO.class, - PortableIpRangeDaoImpl.class, RegionDaoImpl.class, PortableIpDaoImpl.class - }, includeFilters = { @Filter(value = AffinityApiTestConfiguration.Library.class, type = FilterType.CUSTOM) }, useDefaultFilters = false) -public class AffinityApiTestConfiguration { - - @Bean - public AccountDao accountDao() { - return Mockito.mock(AccountDao.class); - } - - @Bean - public EventUtils eventUtils() { - return Mockito.mock(EventUtils.class); - } - - @Bean - public AffinityGroupProcessor affinityGroupProcessor() { - return Mockito.mock(AffinityGroupProcessor.class); - } - - @Bean - public ComponentContext componentContext() { - return Mockito.mock(ComponentContext.class); - } - - - @Bean - public UserContextInitializer userContextInitializer() { - return Mockito.mock(UserContextInitializer.class); - } - - @Bean - public UserVmVO userVmVO() { - return Mockito.mock(UserVmVO.class); - } - - @Bean - public AffinityGroupDao affinityGroupDao() { - return Mockito.mock(AffinityGroupDao.class); - } - - @Bean - public AffinityGroupVMMapDao affinityGroupVMMapDao() { - return Mockito.mock(AffinityGroupVMMapDao.class); - } - - @Bean - public AccountManager acctMgr() { - return Mockito.mock(AccountManager.class); - } - - @Bean - public NetworkService ntwkSvc() { - return Mockito.mock(NetworkService.class); - } - - @Bean - public NetworkModel ntwkMdl() { - return Mockito.mock(NetworkModel.class); - } - - @Bean - public AlertManager alertMgr() { - return Mockito.mock(AlertManager.class); - } - - @Bean - public SecurityChecker securityChkr() { - return Mockito.mock(SecurityChecker.class); - } - - @Bean - public ResourceLimitService resourceSvc() { - return Mockito.mock(ResourceLimitService.class); - } - - @Bean - public ProjectManager projectMgr() { - return Mockito.mock(ProjectManager.class); - } - - @Bean - public SecondaryStorageVmManager ssvmMgr() { - return Mockito.mock(SecondaryStorageVmManager.class); - } - - @Bean - public SwiftManager swiftMgr() { - return Mockito.mock(SwiftManager.class); - } - - @Bean - public S3Manager s3Mgr() { - return Mockito.mock(S3Manager.class); - } - - @Bean - public VpcManager vpcMgr() { - return Mockito.mock(VpcManager.class); - } - - @Bean - public UserVmDao userVMDao() { - return Mockito.mock(UserVmDao.class); - } - - @Bean - public RulesManager rulesMgr() { - return Mockito.mock(RulesManager.class); - } - - @Bean - public LoadBalancingRulesManager lbRulesMgr() { - return Mockito.mock(LoadBalancingRulesManager.class); - } - - @Bean - public RemoteAccessVpnService vpnMgr() { - return Mockito.mock(RemoteAccessVpnService.class); - } - - @Bean - public NetworkGuru ntwkGuru() { - return Mockito.mock(NetworkGuru.class); - } - - @Bean - public NetworkElement ntwkElement() { - return Mockito.mock(NetworkElement.class); - } - - @Bean - public IpDeployer ipDeployer() { - return Mockito.mock(IpDeployer.class); - } - - @Bean - public DhcpServiceProvider dhcpProvider() { - return Mockito.mock(DhcpServiceProvider.class); - } - - @Bean - public FirewallManager firewallMgr() { - return Mockito.mock(FirewallManager.class); - } - - @Bean - public AgentManager agentMgr() { - return Mockito.mock(AgentManager.class); - } - - @Bean - public StorageNetworkManager storageNtwkMgr() { - return Mockito.mock(StorageNetworkManager.class); - } - - @Bean - public NetworkACLManager ntwkAclMgr() { - return Mockito.mock(NetworkACLManager.class); - } - - @Bean - public Ipv6AddressManager ipv6Mgr() { - return Mockito.mock(Ipv6AddressManager.class); - } - - @Bean - public ConfigurationDao configDao() { - return Mockito.mock(ConfigurationDao.class); - } - - @Bean - public NetworkManager networkManager() { - return Mockito.mock(NetworkManager.class); - } - - @Bean - public NetworkOfferingDao networkOfferingDao() { - return Mockito.mock(NetworkOfferingDao.class); - } - - @Bean - public EventDao eventDao() { - return Mockito.mock(EventDao.class); - } - - @Bean - public NetworkDao networkDao() { - return Mockito.mock(NetworkDao.class); - } - - @Bean - public NetworkOfferingServiceMapDao networkOfferingServiceMapDao() { - return Mockito.mock(NetworkOfferingServiceMapDao.class); - } - - @Bean - public DataCenterLinkLocalIpAddressDao datacenterLinkLocalIpAddressDao() { - return Mockito.mock(DataCenterLinkLocalIpAddressDao.class); - } - - public static class Library implements TypeFilter { - - @Override - public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { - mdr.getClassMetadata().getClassName(); - ComponentScan cs = AffinityApiTestConfiguration.class.getAnnotation(ComponentScan.class); - return SpringComponentScanUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); - } - - } -} diff --git a/server/test/org/apache/cloudstack/affinity/AffinityApiUnitTest.java b/server/test/org/apache/cloudstack/affinity/AffinityApiUnitTest.java index a5e6d15bf0b..484b044e28e 100644 --- a/server/test/org/apache/cloudstack/affinity/AffinityApiUnitTest.java +++ b/server/test/org/apache/cloudstack/affinity/AffinityApiUnitTest.java @@ -16,22 +16,40 @@ // under the License. package org.apache.cloudstack.affinity; -import static org.junit.Assert.*; +import static org.junit.Assert.assertNotNull; +import static org.mockito.Matchers.anyBoolean; import static org.mockito.Matchers.anyLong; -import static org.mockito.Mockito.*; +import static org.mockito.Matchers.anyObject; +import static org.mockito.Matchers.anyString; +import static org.mockito.Matchers.eq; +import static org.mockito.Mockito.when; +import java.io.IOException; import java.util.ArrayList; import java.util.List; +import javax.inject.Inject; +import javax.naming.ConfigurationException; + import org.apache.cloudstack.affinity.dao.AffinityGroupDao; import org.apache.cloudstack.affinity.dao.AffinityGroupVMMapDao; +import org.apache.cloudstack.test.utils.SpringUtils; import org.junit.Before; import org.junit.BeforeClass; import org.junit.Test; import org.junit.runner.RunWith; import org.mockito.Mockito; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.ComponentScan; +import org.springframework.context.annotation.ComponentScan.Filter; +import org.springframework.context.annotation.Configuration; +import org.springframework.context.annotation.FilterType; +import org.springframework.core.type.classreading.MetadataReader; +import org.springframework.core.type.classreading.MetadataReaderFactory; +import org.springframework.core.type.filter.TypeFilter; import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; +import org.springframework.test.context.support.AnnotationConfigContextLoader; import com.cloud.event.EventUtils; import com.cloud.event.EventVO; @@ -41,6 +59,7 @@ import com.cloud.exception.ResourceInUseException; import com.cloud.hypervisor.Hypervisor.HypervisorType; import com.cloud.user.Account; import com.cloud.user.AccountManager; +import com.cloud.user.AccountService; import com.cloud.user.AccountVO; import com.cloud.user.UserContext; import com.cloud.user.dao.AccountDao; @@ -49,15 +68,12 @@ import com.cloud.vm.UserVmVO; import com.cloud.vm.VirtualMachine; import com.cloud.vm.dao.UserVmDao; -import javax.inject.Inject; -import javax.naming.ConfigurationException; - @RunWith(SpringJUnit4ClassRunner.class) -@ContextConfiguration(locations = "classpath:/affinityContext.xml") +@ContextConfiguration(loader = AnnotationConfigContextLoader.class) public class AffinityApiUnitTest { @Inject - AffinityGroupServiceImpl _affinityService; + AffinityGroupService _affinityService; @Inject AccountManager _acctMgr; @@ -82,7 +98,7 @@ public class AffinityApiUnitTest { @Inject AccountDao _accountDao; - + @Inject EventDao _eventDao; @@ -91,7 +107,6 @@ public class AffinityApiUnitTest { @BeforeClass public static void setUp() throws ConfigurationException { - } @Before @@ -119,6 +134,7 @@ public class AffinityApiUnitTest { @Test public void createAffinityGroupTest() { + when(_groupDao.isNameInUse(anyLong(), anyLong(), eq("group1"))).thenReturn(false); AffinityGroup group = _affinityService.createAffinityGroup("user", domainId, "group1", "mock", "affinity group one"); assertNotNull("Affinity group 'group1' of type 'mock' failed to create ", group); @@ -184,4 +200,57 @@ public class AffinityApiUnitTest { _affinityService.updateVMAffinityGroups(10L, affinityGroupIds); } + @Configuration + @ComponentScan(basePackageClasses = {AffinityGroupServiceImpl.class, EventUtils.class}, includeFilters = {@Filter(value = TestConfiguration.Library.class, type = FilterType.CUSTOM)}, useDefaultFilters = false) + public static class TestConfiguration extends SpringUtils.CloudStackTestConfiguration { + + @Bean + public AccountDao accountDao() { + return Mockito.mock(AccountDao.class); + } + + @Bean + public AccountService accountService() { + return Mockito.mock(AccountService.class); + } + + @Bean + public AffinityGroupProcessor affinityGroupProcessor() { + return Mockito.mock(AffinityGroupProcessor.class); + } + + @Bean + public AffinityGroupDao affinityGroupDao() { + return Mockito.mock(AffinityGroupDao.class); + } + + @Bean + public AffinityGroupVMMapDao affinityGroupVMMapDao() { + return Mockito.mock(AffinityGroupVMMapDao.class); + } + + @Bean + public AccountManager accountManager() { + return Mockito.mock(AccountManager.class); + } + + @Bean + public EventDao eventDao() { + return Mockito.mock(EventDao.class); + } + + @Bean + public UserVmDao userVMDao() { + return Mockito.mock(UserVmDao.class); + } + + public static class Library implements TypeFilter { + + @Override + public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { + ComponentScan cs = TestConfiguration.class.getAnnotation(ComponentScan.class); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + } + } + } } diff --git a/server/test/org/apache/cloudstack/lb/ApplicationLoadBalancerTest.java b/server/test/org/apache/cloudstack/lb/ApplicationLoadBalancerTest.java new file mode 100644 index 00000000000..461cbbdf012 --- /dev/null +++ b/server/test/org/apache/cloudstack/lb/ApplicationLoadBalancerTest.java @@ -0,0 +1,292 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.lb; + +import java.lang.reflect.Field; +import java.util.HashMap; +import java.util.Map; + +import javax.inject.Inject; + +import junit.framework.TestCase; + +import org.apache.cloudstack.lb.dao.ApplicationLoadBalancerRuleDao; +import org.apache.cloudstack.network.lb.ApplicationLoadBalancerManagerImpl; +import org.apache.cloudstack.network.lb.ApplicationLoadBalancerRule; +import org.junit.Before; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.mockito.Mockito; +import org.springframework.test.context.ContextConfiguration; +import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; + +import com.cloud.event.dao.UsageEventDao; +import com.cloud.exception.InsufficientAddressCapacityException; +import com.cloud.exception.InsufficientVirtualNetworkCapcityException; +import com.cloud.exception.InvalidParameterValueException; +import com.cloud.exception.NetworkRuleConflictException; +import com.cloud.exception.UnsupportedServiceException; +import com.cloud.network.Network; +import com.cloud.network.Network.Capability; +import com.cloud.network.Network.Service; +import com.cloud.network.NetworkModel; +import com.cloud.network.Networks.TrafficType; +import com.cloud.network.dao.FirewallRulesDao; +import com.cloud.network.dao.NetworkVO; +import com.cloud.network.lb.LoadBalancingRule; +import com.cloud.network.lb.LoadBalancingRulesManager; +import com.cloud.network.rules.FirewallRuleVO; +import com.cloud.network.rules.LoadBalancerContainer.Scheme; +import com.cloud.user.AccountManager; +import com.cloud.user.AccountVO; +import com.cloud.user.UserContext; +import com.cloud.user.UserVO; +import com.cloud.utils.component.ComponentContext; +import com.cloud.utils.exception.CloudRuntimeException; +import com.cloud.utils.net.Ip; +import com.cloud.utils.net.NetUtils; + +/** + * This class is responsible for unittesting the methods defined in ApplicationLoadBalancerService + * + */ + +@RunWith(SpringJUnit4ClassRunner.class) +@ContextConfiguration(locations="classpath:/appLoadBalancer.xml") +public class ApplicationLoadBalancerTest extends TestCase{ + //The interface to test + @Inject ApplicationLoadBalancerManagerImpl _appLbSvc; + + //The interfaces below are mocked + @Inject ApplicationLoadBalancerRuleDao _lbDao; + @Inject LoadBalancingRulesManager _lbMgr; + @Inject NetworkModel _ntwkModel; + @Inject AccountManager _accountMgr; + @Inject FirewallRulesDao _firewallDao; + @Inject UsageEventDao _usageEventDao; + + + public static long existingLbId = 1L; + public static long nonExistingLbId = 2L; + + public static long validGuestNetworkId = 1L; + public static long invalidGuestNetworkId = 2L; + public static long validPublicNetworkId = 3L; + + public static long validAccountId = 1L; + public static long invalidAccountId = 2L; + + public String validRequestedIp = "10.1.1.1"; + + + + @Before + public void setUp() { + ComponentContext.initComponentsLifeCycle(); + //mockito for .getApplicationLoadBalancer tests + Mockito.when(_lbDao.findById(1L)).thenReturn(new ApplicationLoadBalancerRuleVO()); + Mockito.when(_lbDao.findById(2L)).thenReturn(null); + + //mockito for .deleteApplicationLoadBalancer tests + Mockito.when(_lbMgr.deleteLoadBalancerRule(existingLbId, true)).thenReturn(true); + Mockito.when(_lbMgr.deleteLoadBalancerRule(nonExistingLbId, true)).thenReturn(false); + + //mockito for .createApplicationLoadBalancer tests + NetworkVO guestNetwork = new NetworkVO(TrafficType.Guest, null, null, 1, + null, 1, 1L); + setId(guestNetwork, validGuestNetworkId); + guestNetwork.setCidr("10.1.1.1/24"); + + NetworkVO publicNetwork = new NetworkVO(TrafficType.Public, null, null, 1, + null, 1, 1L); + + Mockito.when(_ntwkModel.getNetwork(validGuestNetworkId)).thenReturn(guestNetwork); + Mockito.when(_ntwkModel.getNetwork(invalidGuestNetworkId)).thenReturn(null); + Mockito.when(_ntwkModel.getNetwork(validPublicNetworkId)).thenReturn(publicNetwork); + + Mockito.when(_accountMgr.getAccount(validAccountId)).thenReturn(new AccountVO()); + Mockito.when(_accountMgr.getAccount(invalidAccountId)).thenReturn(null); + Mockito.when(_ntwkModel.areServicesSupportedInNetwork(validGuestNetworkId, Service.Lb)).thenReturn(true); + Mockito.when(_ntwkModel.areServicesSupportedInNetwork(invalidGuestNetworkId, Service.Lb)).thenReturn(false); + + ApplicationLoadBalancerRuleVO lbRule = new ApplicationLoadBalancerRuleVO("new", "new", 22, 22, "roundrobin", + validGuestNetworkId, validAccountId, 1L, new Ip(validRequestedIp), validGuestNetworkId, Scheme.Internal); + Mockito.when(_lbDao.persist(Mockito.any(ApplicationLoadBalancerRuleVO.class))).thenReturn(lbRule); + + Mockito.when(_lbMgr.validateLbRule(Mockito.any(LoadBalancingRule.class))).thenReturn(true); + + Mockito.when(_firewallDao.setStateToAdd(Mockito.any(FirewallRuleVO.class))).thenReturn(true); + + Mockito.when(_accountMgr.getSystemUser()).thenReturn(new UserVO(1)); + Mockito.when(_accountMgr.getSystemAccount()).thenReturn(new AccountVO(2)); + UserContext.registerContext(_accountMgr.getSystemUser().getId(), _accountMgr.getSystemAccount(), null, false); + + Mockito.when(_ntwkModel.areServicesSupportedInNetwork(Mockito.anyLong(), Mockito.any(Network.Service.class))).thenReturn(true); + + Map caps = new HashMap(); + caps.put(Capability.SupportedProtocols, NetUtils.TCP_PROTO); + Mockito.when(_ntwkModel.getNetworkServiceCapabilities(Mockito.anyLong(), Mockito.any(Network.Service.class))).thenReturn(caps); + + + Mockito.when(_lbDao.countBySourceIp(new Ip(validRequestedIp), validGuestNetworkId)).thenReturn(1L); + + } + + /** + * TESTS FOR .getApplicationLoadBalancer + */ + + @Test + //Positive test - retrieve existing lb + public void searchForExistingLoadBalancer() { + ApplicationLoadBalancerRule rule = _appLbSvc.getApplicationLoadBalancer(existingLbId); + assertNotNull("Couldn't find existing application load balancer", rule); + } + + @Test + //Negative test - try to retrieve non-existing lb + public void searchForNonExistingLoadBalancer() { + boolean notFound = false; + ApplicationLoadBalancerRule rule = null; + try { + rule = _appLbSvc.getApplicationLoadBalancer(nonExistingLbId); + if (rule != null) { + notFound = false; + } + } catch (InvalidParameterValueException ex) { + notFound = true; + } + + assertTrue("Found non-existing load balancer; no invalid parameter value exception was thrown", notFound); + } + + /** + * TESTS FOR .deleteApplicationLoadBalancer + */ + + + @Test + //Positive test - delete existing lb + public void deleteExistingLoadBalancer() { + boolean result = false; + try { + result = _appLbSvc.deleteApplicationLoadBalancer(existingLbId); + } finally { + assertTrue("Couldn't delete existing application load balancer", result); + } + } + + + @Test + //Negative test - try to delete non-existing lb + public void deleteNonExistingLoadBalancer() { + boolean result = true; + try { + result = _appLbSvc.deleteApplicationLoadBalancer(nonExistingLbId); + } finally { + assertFalse("Didn't fail when try to delete non-existing load balancer", result); + } + } + + /** + * TESTS FOR .createApplicationLoadBalancer + * @throws NetworkRuleConflictException + * @throws InsufficientVirtualNetworkCapcityException + * @throws InsufficientAddressCapacityException + */ + + @Test (expected = CloudRuntimeException.class) + //Positive test + public void createValidLoadBalancer() throws InsufficientAddressCapacityException, + InsufficientVirtualNetworkCapcityException, NetworkRuleConflictException { + _appLbSvc.createApplicationLoadBalancer("alena", "alena", Scheme.Internal, validGuestNetworkId, validRequestedIp, + 22, 22, "roundrobin", validGuestNetworkId, validAccountId); + } + + + @Test(expected = UnsupportedServiceException.class) + //Negative test - only internal scheme value is supported in the current release + public void createPublicLoadBalancer() throws InsufficientAddressCapacityException, + InsufficientVirtualNetworkCapcityException, NetworkRuleConflictException { + _appLbSvc.createApplicationLoadBalancer("alena", "alena", Scheme.Public, validGuestNetworkId, validRequestedIp, + 22, 22, "roundrobin", validGuestNetworkId, validAccountId); + } + + + @Test(expected = InvalidParameterValueException.class) + //Negative test - invalid SourcePort + public void createWithInvalidSourcePort() throws InsufficientAddressCapacityException, + InsufficientVirtualNetworkCapcityException, NetworkRuleConflictException { + _appLbSvc.createApplicationLoadBalancer("alena", "alena", Scheme.Internal, validGuestNetworkId, validRequestedIp, + 65536, 22, "roundrobin", validGuestNetworkId, validAccountId); + } + + @Test(expected = InvalidParameterValueException.class) + //Negative test - invalid instancePort + public void createWithInvalidInstandePort() throws InsufficientAddressCapacityException, + InsufficientVirtualNetworkCapcityException, NetworkRuleConflictException { + _appLbSvc.createApplicationLoadBalancer("alena", "alena", Scheme.Internal, validGuestNetworkId, validRequestedIp, + 22, 65536, "roundrobin", validGuestNetworkId, validAccountId); + + } + + + @Test(expected = InvalidParameterValueException.class) + //Negative test - invalid algorithm + public void createWithInvalidAlgorithm() throws InsufficientAddressCapacityException, InsufficientVirtualNetworkCapcityException, NetworkRuleConflictException { + String expectedExcText = null; + _appLbSvc.createApplicationLoadBalancer("alena", "alena", Scheme.Internal, validGuestNetworkId, validRequestedIp, + 22, 22, "invalidalgorithm", validGuestNetworkId, validAccountId); + + } + + @Test(expected = InvalidParameterValueException.class) + //Negative test - invalid sourceNetworkId (of Public type, which is not supported) + public void createWithInvalidSourceIpNtwk() throws InsufficientAddressCapacityException, + InsufficientVirtualNetworkCapcityException, NetworkRuleConflictException { + _appLbSvc.createApplicationLoadBalancer("alena", "alena", Scheme.Internal, validPublicNetworkId, validRequestedIp, + 22, 22, "roundrobin", validGuestNetworkId, validAccountId); + + } + + + @Test(expected = InvalidParameterValueException.class) + //Negative test - invalid requested IP (outside of guest network cidr range) + public void createWithInvalidRequestedIp() throws InsufficientAddressCapacityException, + InsufficientVirtualNetworkCapcityException, NetworkRuleConflictException { + + _appLbSvc.createApplicationLoadBalancer("alena", "alena", Scheme.Internal, validGuestNetworkId, "10.2.1.1", + 22, 22, "roundrobin", validGuestNetworkId, validAccountId); + } + + + private static NetworkVO setId(NetworkVO vo, long id) { + NetworkVO voToReturn = vo; + Class c = voToReturn.getClass(); + try { + Field f = c.getDeclaredField("id"); + f.setAccessible(true); + f.setLong(voToReturn, id); + } catch (NoSuchFieldException ex) { + return null; + } catch (IllegalAccessException ex) { + return null; + } + + return voToReturn; + } +} diff --git a/server/test/org/apache/cloudstack/lb/ChildTestConfiguration.java b/server/test/org/apache/cloudstack/lb/ChildTestConfiguration.java new file mode 100644 index 00000000000..a5b84ed6206 --- /dev/null +++ b/server/test/org/apache/cloudstack/lb/ChildTestConfiguration.java @@ -0,0 +1,105 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. +package org.apache.cloudstack.lb; + +import java.io.IOException; + +import org.apache.cloudstack.lb.dao.ApplicationLoadBalancerRuleDao; +import org.apache.cloudstack.test.utils.SpringUtils; +import org.mockito.Mockito; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.ComponentScan; +import org.springframework.context.annotation.ComponentScan.Filter; +import org.springframework.context.annotation.Configuration; +import org.springframework.context.annotation.FilterType; +import org.springframework.core.type.classreading.MetadataReader; +import org.springframework.core.type.classreading.MetadataReaderFactory; +import org.springframework.core.type.filter.TypeFilter; + +import com.cloud.dc.dao.AccountVlanMapDaoImpl; +import com.cloud.event.dao.UsageEventDao; +import com.cloud.network.NetworkManager; +import com.cloud.network.NetworkModel; +import com.cloud.network.dao.FirewallRulesDao; +import com.cloud.network.lb.LoadBalancingRulesManager; +import com.cloud.tags.dao.ResourceTagDao; +import com.cloud.user.AccountManager; +import com.cloud.utils.net.NetUtils; + + +@Configuration +@ComponentScan( + basePackageClasses={ + NetUtils.class + }, + includeFilters={@Filter(value=ChildTestConfiguration.Library.class, type=FilterType.CUSTOM)}, + useDefaultFilters=false + ) + + public class ChildTestConfiguration { + + public static class Library implements TypeFilter { + + @Bean + public ApplicationLoadBalancerRuleDao applicationLoadBalancerDao() { + return Mockito.mock(ApplicationLoadBalancerRuleDao.class); + } + + @Bean + public NetworkModel networkModel() { + return Mockito.mock(NetworkModel.class); + } + + @Bean + public AccountManager accountManager() { + return Mockito.mock(AccountManager.class); + } + + @Bean + public LoadBalancingRulesManager loadBalancingRulesManager() { + return Mockito.mock(LoadBalancingRulesManager.class); + } + + @Bean + public FirewallRulesDao firewallRulesDao() { + return Mockito.mock(FirewallRulesDao.class); + } + + @Bean + public ResourceTagDao resourceTagDao() { + return Mockito.mock(ResourceTagDao.class); + } + + @Bean + public NetworkManager networkManager() { + return Mockito.mock(NetworkManager.class); + } + + @Bean + public UsageEventDao UsageEventDao() { + return Mockito.mock(UsageEventDao.class); + } + + @Override + public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { + mdr.getClassMetadata().getClassName(); + ComponentScan cs = ChildTestConfiguration.class.getAnnotation(ComponentScan.class); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + } + + } +} diff --git a/server/test/org/apache/cloudstack/networkoffering/ChildTestConfiguration.java b/server/test/org/apache/cloudstack/networkoffering/ChildTestConfiguration.java index 55ddcde5112..63f3cbfb639 100644 --- a/server/test/org/apache/cloudstack/networkoffering/ChildTestConfiguration.java +++ b/server/test/org/apache/cloudstack/networkoffering/ChildTestConfiguration.java @@ -19,10 +19,17 @@ package org.apache.cloudstack.networkoffering; import java.io.IOException; +import com.cloud.dc.ClusterDetailsDao; +import com.cloud.dc.dao.*; +import com.cloud.server.ConfigurationServer; +import com.cloud.user.*; import org.apache.cloudstack.acl.SecurityChecker; import org.apache.cloudstack.region.PortableIpDaoImpl; import org.apache.cloudstack.region.dao.RegionDaoImpl; +import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDao; import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDaoImpl; +import org.apache.cloudstack.storage.datastore.db.StoragePoolDetailsDao; +import org.apache.cloudstack.test.utils.SpringUtils; import org.mockito.Mockito; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.ComponentScan; @@ -39,18 +46,6 @@ import com.cloud.api.query.dao.UserAccountJoinDaoImpl; import com.cloud.capacity.dao.CapacityDaoImpl; import com.cloud.cluster.agentlb.dao.HostTransferMapDaoImpl; import com.cloud.configuration.dao.ConfigurationDao; -import com.cloud.dc.dao.AccountVlanMapDaoImpl; -import com.cloud.dc.dao.ClusterDaoImpl; -import com.cloud.dc.dao.DataCenterDaoImpl; -import com.cloud.dc.dao.DataCenterIpAddressDaoImpl; -import com.cloud.dc.dao.DataCenterLinkLocalIpAddressDao; -import com.cloud.dc.dao.DataCenterLinkLocalIpAddressDaoImpl; -import com.cloud.dc.dao.DataCenterVnetDaoImpl; -import com.cloud.dc.dao.DcDetailsDaoImpl; -import com.cloud.dc.dao.HostPodDaoImpl; -import com.cloud.dc.dao.PodVlanDaoImpl; -import com.cloud.dc.dao.PodVlanMapDaoImpl; -import com.cloud.dc.dao.VlanDaoImpl; import com.cloud.domain.dao.DomainDaoImpl; import com.cloud.event.dao.UsageEventDaoImpl; import com.cloud.host.dao.HostDaoImpl; @@ -61,6 +56,7 @@ import com.cloud.network.NetworkManager; import com.cloud.network.NetworkModel; import com.cloud.network.NetworkService; import com.cloud.network.StorageNetworkManager; +import com.cloud.network.dao.AccountGuestVlanMapDaoImpl; import com.cloud.network.dao.FirewallRulesCidrsDaoImpl; import com.cloud.network.dao.FirewallRulesDaoImpl; import com.cloud.network.dao.IPAddressDaoImpl; @@ -99,13 +95,8 @@ import com.cloud.storage.s3.S3Manager; import com.cloud.storage.secondary.SecondaryStorageVmManager; import com.cloud.storage.swift.SwiftManager; import com.cloud.tags.dao.ResourceTagsDaoImpl; -import com.cloud.user.AccountManager; -import com.cloud.user.ResourceLimitService; -import com.cloud.user.UserContext; -import com.cloud.user.UserContextInitializer; import com.cloud.user.dao.AccountDaoImpl; import com.cloud.user.dao.UserDaoImpl; -import com.cloud.utils.component.SpringComponentScanUtils; import com.cloud.vm.dao.InstanceGroupDaoImpl; import com.cloud.vm.dao.NicDaoImpl; import com.cloud.vm.dao.NicSecondaryIpDaoImpl; @@ -162,7 +153,8 @@ import org.apache.cloudstack.region.PortableIpRangeDaoImpl; StoragePoolDetailsDaoImpl.class, PortableIpRangeDaoImpl.class, RegionDaoImpl.class, - PortableIpDaoImpl.class + PortableIpDaoImpl.class, + AccountGuestVlanMapDaoImpl.class }, includeFilters={@Filter(value=ChildTestConfiguration.Library.class, type=FilterType.CUSTOM)}, useDefaultFilters=false @@ -329,6 +321,22 @@ public class ChildTestConfiguration { public DataCenterLinkLocalIpAddressDao datacenterLinkLocalIpAddressDao() { return Mockito.mock(DataCenterLinkLocalIpAddressDao.class); } + + @Bean + public ConfigurationServer configurationServer() { + return Mockito.mock(ConfigurationServer.class); + } + + @Bean + public ClusterDetailsDao clusterDetailsDao() { + return Mockito.mock(ClusterDetailsDao.class); + } + + @Bean + public AccountDetailsDao accountDetailsDao() { + return Mockito.mock(AccountDetailsDao.class); + } + public static class Library implements TypeFilter { @@ -336,7 +344,7 @@ public class ChildTestConfiguration { public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { mdr.getClassMetadata().getClassName(); ComponentScan cs = ChildTestConfiguration.class.getAnnotation(ComponentScan.class); - return SpringComponentScanUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); } } diff --git a/server/test/org/apache/cloudstack/networkoffering/CreateNetworkOfferingTest.java b/server/test/org/apache/cloudstack/networkoffering/CreateNetworkOfferingTest.java index cbb6c00e397..92aa2a2c8ff 100644 --- a/server/test/org/apache/cloudstack/networkoffering/CreateNetworkOfferingTest.java +++ b/server/test/org/apache/cloudstack/networkoffering/CreateNetworkOfferingTest.java @@ -41,6 +41,7 @@ import com.cloud.network.Network; import com.cloud.network.Network.Provider; import com.cloud.network.Network.Service; import com.cloud.network.Networks.TrafficType; +import com.cloud.network.vpc.VpcManager; import com.cloud.offering.NetworkOffering.Availability; import com.cloud.offerings.NetworkOfferingServiceMapVO; import com.cloud.offerings.NetworkOfferingVO; @@ -72,6 +73,9 @@ public class CreateNetworkOfferingTest extends TestCase{ @Inject AccountManager accountMgr; + @Inject + VpcManager vpcMgr; + @Before public void setUp() { ComponentContext.initComponentsLifeCycle(); @@ -80,6 +84,7 @@ public class CreateNetworkOfferingTest extends TestCase{ Mockito.when(configDao.findByName(Mockito.anyString())).thenReturn(configVO); Mockito.when(offDao.persist(Mockito.any(NetworkOfferingVO.class))).thenReturn(new NetworkOfferingVO()); + Mockito.when(offDao.persist(Mockito.any(NetworkOfferingVO.class), Mockito.anyMap())).thenReturn(new NetworkOfferingVO()); Mockito.when(mapDao.persist(Mockito.any(NetworkOfferingServiceMapVO.class))).thenReturn(new NetworkOfferingServiceMapVO()); Mockito.when(accountMgr.getSystemUser()).thenReturn(new UserVO(1)); Mockito.when(accountMgr.getSystemAccount()).thenReturn(new AccountVO(2)); @@ -92,7 +97,7 @@ public class CreateNetworkOfferingTest extends TestCase{ public void createSharedNtwkOffWithVlan() { NetworkOfferingVO off = configMgr.createNetworkOffering("shared", "shared", TrafficType.Guest, null, true, Availability.Optional, 200, null, false, Network.GuestType.Shared, false, - null, false, null, true, false); + null, false, null, true, false, null); assertNotNull("Shared network offering with specifyVlan=true failed to create ", off); } @@ -101,7 +106,7 @@ public class CreateNetworkOfferingTest extends TestCase{ try { NetworkOfferingVO off = configMgr.createNetworkOffering("shared", "shared", TrafficType.Guest, null, false, Availability.Optional, 200, null, false, Network.GuestType.Shared, false, - null, false, null, true, false); + null, false, null, true, false, null); assertNull("Shared network offering with specifyVlan=false was created", off); } catch (InvalidParameterValueException ex) { } @@ -111,7 +116,7 @@ public class CreateNetworkOfferingTest extends TestCase{ public void createSharedNtwkOffWithSpecifyIpRanges() { NetworkOfferingVO off = configMgr.createNetworkOffering("shared", "shared", TrafficType.Guest, null, true, Availability.Optional, 200, null, false, Network.GuestType.Shared, false, - null, false, null, true, false); + null, false, null, true, false, null); assertNotNull("Shared network offering with specifyIpRanges=true failed to create ", off); } @@ -121,7 +126,7 @@ public class CreateNetworkOfferingTest extends TestCase{ try { NetworkOfferingVO off = configMgr.createNetworkOffering("shared", "shared", TrafficType.Guest, null, true, Availability.Optional, 200, null, false, Network.GuestType.Shared, false, - null, false, null, false, false); + null, false, null, false, false, null); assertNull("Shared network offering with specifyIpRanges=false was created", off); } catch (InvalidParameterValueException ex) { } @@ -136,7 +141,7 @@ public class CreateNetworkOfferingTest extends TestCase{ serviceProviderMap.put(Network.Service.SourceNat, vrProvider); NetworkOfferingVO off = configMgr.createNetworkOffering("isolated", "isolated", TrafficType.Guest, null, false, Availability.Optional, 200, serviceProviderMap, false, Network.GuestType.Isolated, false, - null, false, null, false, false); + null, false, null, false, false, null); assertNotNull("Isolated network offering with specifyIpRanges=false failed to create ", off); } @@ -149,7 +154,7 @@ public class CreateNetworkOfferingTest extends TestCase{ serviceProviderMap.put(Network.Service.SourceNat, vrProvider); NetworkOfferingVO off = configMgr.createNetworkOffering("isolated", "isolated", TrafficType.Guest, null, true, Availability.Optional, 200, serviceProviderMap, false, Network.GuestType.Isolated, false, - null, false, null, false, false); + null, false, null, false, false, null); assertNotNull("Isolated network offering with specifyVlan=true wasn't created", off); } @@ -163,7 +168,7 @@ public class CreateNetworkOfferingTest extends TestCase{ serviceProviderMap.put(Network.Service.SourceNat, vrProvider); NetworkOfferingVO off = configMgr.createNetworkOffering("isolated", "isolated", TrafficType.Guest, null, false, Availability.Optional, 200, serviceProviderMap, false, Network.GuestType.Isolated, false, - null, false, null, true, false); + null, false, null, true, false, null); assertNull("Isolated network offering with specifyIpRanges=true and source nat service enabled, was created", off); } catch (InvalidParameterValueException ex) { } @@ -176,8 +181,47 @@ public class CreateNetworkOfferingTest extends TestCase{ Set vrProvider = new HashSet(); NetworkOfferingVO off = configMgr.createNetworkOffering("isolated", "isolated", TrafficType.Guest, null, false, Availability.Optional, 200, serviceProviderMap, false, Network.GuestType.Isolated, false, - null, false, null, true, false); + null, false, null, true, false, null); assertNotNull("Isolated network offering with specifyIpRanges=true and with no sourceNatService, failed to create", off); } + + @Test + public void createVpcNtwkOff() { + Map> serviceProviderMap = new HashMap>(); + Set vrProvider = new HashSet(); + vrProvider.add(Provider.VPCVirtualRouter); + serviceProviderMap.put(Network.Service.Dhcp , vrProvider); + serviceProviderMap.put(Network.Service.Dns , vrProvider); + serviceProviderMap.put(Network.Service.Lb , vrProvider); + serviceProviderMap.put(Network.Service.SourceNat , vrProvider); + serviceProviderMap.put(Network.Service.Gateway , vrProvider); + serviceProviderMap.put(Network.Service.Lb , vrProvider); + NetworkOfferingVO off = configMgr.createNetworkOffering("isolated", "isolated", TrafficType.Guest, null, true, + Availability.Optional, 200, serviceProviderMap, false, Network.GuestType.Isolated, false, + null, false, null, false, false, null); + // System.out.println("Creating Vpc Network Offering"); + assertNotNull("Vpc Isolated network offering with Vpc provider ", off); + } + + @Test + public void createVpcNtwkOffWithNetscaler() { + Map> serviceProviderMap = new HashMap>(); + Set vrProvider = new HashSet(); + Set lbProvider = new HashSet(); + vrProvider.add(Provider.VPCVirtualRouter); + lbProvider.add(Provider.Netscaler); + serviceProviderMap.put(Network.Service.Dhcp, vrProvider); + serviceProviderMap.put(Network.Service.Dns, vrProvider); + serviceProviderMap.put(Network.Service.Lb, vrProvider); + serviceProviderMap.put(Network.Service.SourceNat, vrProvider); + serviceProviderMap.put(Network.Service.Gateway, vrProvider); + serviceProviderMap.put(Network.Service.Lb, lbProvider); + NetworkOfferingVO off = configMgr.createNetworkOffering("isolated", "isolated", TrafficType.Guest, null, true, + Availability.Optional, 200, serviceProviderMap, false, Network.GuestType.Isolated, false, null, false, + null, false, false, null); + // System.out.println("Creating Vpc Network Offering"); + assertNotNull("Vpc Isolated network offering with Vpc and Netscaler provider ", off); + } + } diff --git a/server/test/resources/affinityContext.xml b/server/test/resources/appLoadBalancer.xml similarity index 67% rename from server/test/resources/affinityContext.xml rename to server/test/resources/appLoadBalancer.xml index 15476c1a1b3..d7c1502a715 100644 --- a/server/test/resources/affinityContext.xml +++ b/server/test/resources/appLoadBalancer.xml @@ -23,25 +23,21 @@ - - - - - - - - - - - - - + + - - + + + + + + + + + + - + - - \ No newline at end of file + diff --git a/services/console-proxy/plugin/pom.xml b/services/console-proxy/plugin/pom.xml index 4cbe6d1c8f4..55db33bd951 100644 --- a/services/console-proxy/plugin/pom.xml +++ b/services/console-proxy/plugin/pom.xml @@ -20,16 +20,10 @@ 4.0.0 cloud-plugin-console-proxy Apache CloudStack Console Proxy Plugin - pom org.apache.cloudstack - cloud-service-console-proxy + cloudstack-service-console-proxy 4.2.0-SNAPSHOT ../pom.xml - - install - src - test - diff --git a/services/console-proxy/pom.xml b/services/console-proxy/pom.xml index 1453e8cc264..3aac7b25a80 100644 --- a/services/console-proxy/pom.xml +++ b/services/console-proxy/pom.xml @@ -18,12 +18,12 @@ --> 4.0.0 - cloud-service-console-proxy + cloudstack-service-console-proxy Apache CloudStack Console Proxy Service pom org.apache.cloudstack - cloud-services + cloudstack-services 4.2.0-SNAPSHOT ../pom.xml diff --git a/services/console-proxy/server/css/ajaxviewer.css b/services/console-proxy/server/css/ajaxviewer.css index 5ea552b176f..fd2fb3c44e9 100644 --- a/services/console-proxy/server/css/ajaxviewer.css +++ b/services/console-proxy/server/css/ajaxviewer.css @@ -91,12 +91,12 @@ body { position: absolute; top:32; width: 260; - height: 65; + height: 95; display: block; display: none; border-top: 1px solid black; - background-image:url(/resource/images/back.gif); - background-repeat:repeat-x repeat-y; + background-image:url(/resource/images/back.gif); + background-repeat:repeat-x repeat-y; } #toolbar ul li ul li { diff --git a/services/console-proxy/server/js/ajaxkeys.js b/services/console-proxy/server/js/ajaxkeys.js index 2ecf5b561e0..5f497bbb785 100644 --- a/services/console-proxy/server/js/ajaxkeys.js +++ b/services/console-proxy/server/js/ajaxkeys.js @@ -23,55 +23,306 @@ under the License. * They are used by the ajaxviewer.js */ -//client event type. corresponds to events in ajaxviewer. -X11_KEY_CIRCUMFLEX_ACCENT = 0x5e; // ^ -X11_KEY_YEN_MARK = 0xa5; +//client event type. corresponds to events in ajaxviewer. + + +//use java AWT key modifier masks +JS_KEY_BACKSPACE = 8; +JS_KEY_TAB = 9; +JS_KEY_ENTER = 13; +JS_KEY_SHIFT = 16; +JS_KEY_CTRL = 17; +JS_KEY_ALT = 18; +JS_KEY_CAPSLOCK = 20; +JS_KEY_ESCAPE = 27; +JS_KEY_PAGEUP = 33; +JS_KEY_PAGEDOWN = 34; +JS_KEY_END = 35; +JS_KEY_HOME = 36; +JS_KEY_LEFT = 37; +JS_KEY_UP = 38; +JS_KEY_RIGHT = 39; +JS_KEY_DOWN = 40; +JS_KEY_INSERT = 45; +JS_KEY_DELETE = 46; +JS_KEY_SELECT_KEY = 93; +JS_KEY_NUMPAD0 = 96; +JS_KEY_NUMPAD1 = 97; +JS_KEY_NUMPAD2 = 98; +JS_KEY_NUMPAD3 = 99; +JS_KEY_NUMPAD4 = 100; +JS_KEY_NUMPAD5 = 101; +JS_KEY_NUMPAD6 = 102; +JS_KEY_NUMPAD7 = 103; +JS_KEY_NUMPAD8 = 104; +JS_KEY_NUMPAD9 = 105; +JS_KEY_MULTIPLY = 106; +JS_KEY_ADD = 107; +JS_KEY_SUBSTRACT = 109; +JS_KEY_DECIMAL_POINT = 110; +JS_KEY_DIVIDE = 111; +JS_KEY_F1 = 112; +JS_KEY_F2 = 113; +JS_KEY_F3 = 114; +JS_KEY_F4 = 115; +JS_KEY_F5 = 116; +JS_KEY_F6 = 117; +JS_KEY_F7 = 118; +JS_KEY_F8 = 119; +JS_KEY_F9 = 120; +JS_KEY_F10 = 121; +JS_KEY_F11 = 122; +JS_KEY_F12 = 123; +JS_KEY_SEMI_COLON = 186; // ; +JS_KEY_COMMA = 188; // , +JS_KEY_DASH = 189; // - +JS_KEY_PERIOD = 190; // . +JS_KEY_FORWARD_SLASH = 191; // / +JS_KEY_GRAVE_ACCENT = 192; // ` +JS_KEY_OPEN_BRACKET = 219; // [ +JS_KEY_BACK_SLASH = 220; // \ +JS_KEY_CLOSE_BRACKET = 221; // ] +JS_KEY_SINGLE_QUOTE = 222; // ' + + +//X11 keysym definitions +X11_KEY_CAPSLOCK = 0xffe5; +X11_KEY_BACKSPACE = 0xff08; +X11_KEY_TAB = 0xff09; +X11_KEY_ENTER = 0xff0d; +X11_KEY_ESCAPE = 0xff1b; +X11_KEY_INSERT = 0xff63; +X11_KEY_DELETE = 0xffff; +X11_KEY_HOME = 0xff50; +X11_KEY_END = 0xff57; +X11_KEY_PAGEUP = 0xff55; +X11_KEY_PAGEDOWN = 0xff56; +X11_KEY_LEFT = 0xff51; +X11_KEY_UP = 0xff52; +X11_KEY_RIGHT = 0xff53; +X11_KEY_DOWN = 0xff54; +X11_KEY_F1 = 0xffbe; +X11_KEY_F2 = 0xffbf; +X11_KEY_F3 = 0xffc0; +X11_KEY_F4 = 0xffc1; +X11_KEY_F5 = 0xffc2; +X11_KEY_F6 = 0xffc3; +X11_KEY_F7 = 0xffc4; +X11_KEY_F8 = 0xffc5; +X11_KEY_F9 = 0xffc6; +X11_KEY_F10 = 0xffc7; +X11_KEY_F11 = 0xffc8; +X11_KEY_F12 = 0xffc9; +X11_KEY_SHIFT = 0xffe1; +X11_KEY_CTRL = 0xffe3; +X11_KEY_ALT = 0xffe9; +X11_KEY_GRAVE_ACCENT = 0x60; +X11_KEY_SUBSTRACT = 0x2d; +X11_KEY_ADD = 0x2b; X11_KEY_OPEN_BRACKET = 0x5b; X11_KEY_CLOSE_BRACKET = 0x5d; +X11_KEY_BACK_SLASH = 0x7c; +X11_KEY_REVERSE_SOLIUS = 0x5c; // another back slash (back slash on JP keyboard) +X11_KEY_SINGLE_QUOTE = 0x22; +X11_KEY_COMMA = 0x3c; +X11_KEY_PERIOD = 0x3e; +X11_KEY_FORWARD_SLASH = 0x3f; +X11_KEY_DASH = 0x2d; X11_KEY_COLON = 0x3a; -X11_KEY_REVERSE_SOLIUS = 0x5c; // another back slash (back slash on JP keyboard) -X11_KEY_CAPSLOCK = 0xffe5; X11_KEY_SEMI_COLON = 0x3b; -X11_KEY_SHIFT = 0xffe1; -X11_KEY_ADD = 0x2b; +X11_KEY_NUMPAD0 = 0x30; +X11_KEY_NUMPAD1 = 0x31; +X11_KEY_NUMPAD2 = 0x32; +X11_KEY_NUMPAD3 = 0x33; +X11_KEY_NUMPAD4 = 0x34; +X11_KEY_NUMPAD5 = 0x35; +X11_KEY_NUMPAD6 = 0x36; +X11_KEY_NUMPAD7 = 0x37; +X11_KEY_NUMPAD8 = 0x38; +X11_KEY_NUMPAD9 = 0x39; +X11_KEY_DECIMAL_POINT = 0x2e; +X11_KEY_DIVIDE = 0x3f; +X11_KEY_TILDE = 0x7e; // ~ +X11_KEY_CIRCUMFLEX_ACCENT = 0x5e; // ^ +X11_KEY_YEN_MARK = 0xa5; // Japanese YEN mark +X11_KEY_ASTERISK = 0x2a; KEY_DOWN = 5; KEY_UP = 6; +KEYBOARD_TYPE_COOKED = "us"; +KEYBOARD_TYPE_JP = "jp"; +KEYBOARD_TYPE_UK = "uk"; + //JP keyboard type -// + var keyboardTables = [ - {tindex: 0, keyboardType: "EN-Cooked", mappingTable: - {X11: [ {keycode: 222, entry: X11_KEY_CIRCUMFLEX_ACCENT}, + {tindex: 0, keyboardType: KEYBOARD_TYPE_COOKED, mappingTable: + {X11: [ {keycode: 222, entry: X11_KEY_CIRCUMFLEX_ACCENT}, {keycode: 220, entry: X11_KEY_YEN_MARK}, - {keycode: 219, entry: X11_KEY_OPEN_BRACKET}, - {keycode: 221, entry: X11_KEY_CLOSE_BRACKET}, - {keycode: 59, entry: X11_KEY_COLON, browser: "Firefox"}, {keycode: 186, entry: X11_KEY_COLON, browser: "Chrome"}, {keycode: 9, entry: 9, guestos: "XenServer"}, {keycode: 226, entry: X11_KEY_REVERSE_SOLIUS}, + {keycode: 240, entry: [ {type: KEY_DOWN, code: X11_KEY_CAPSLOCK, modifiers: 0 }, {type: KEY_UP, code: X11_KEY_CAPSLOCK, modifiers: 0 }, ] + } + ], + keyPress: [ + {keycode: 59, entry: [ + {type: KEY_DOWN, code: X11_KEY_SEMI_COLON, modifiers: 0 }, + {type: KEY_UP, code: X11_KEY_SEMI_COLON, modifiers: 0 }, + ] }, - ], - keyPress: [ - {keycode: 59, entry: [ - {type: KEY_DOWN, code: X11_KEY_SEMI_COLON, modifiers: 0 }, - {type: KEY_UP, code: X11_KEY_SEMI_COLON, modifiers: 0 }, - ] - }, - {keycode: 43, entry: [ - {type: KEY_DOWN, code: X11_KEY_SHIFT, modifiers: 0, shift: false }, - {type: KEY_DOWN, code: X11_KEY_ADD, modifiers: 0, shift: false }, - {type: KEY_UP, code: X11_KEY_ADD, modifiers: 0, shift: false }, - {type: KEY_UP, code: X11_KEY_SHIFT, modifiers: 0, shift: false }, - {type: KEY_DOWN, code: X11_KEY_ADD, modifiers: 0, shift: true }, - {type: KEY_UP, code: X11_KEY_ADD, modifiers: 0, shift: true }, - ] - }, - ] - } - } ] - + {keycode: 43, entry: [ + {type: KEY_DOWN, code: X11_KEY_SHIFT, modifiers: 0, shift: false }, + {type: KEY_DOWN, code: X11_KEY_ADD, modifiers: 0, shift: false }, + {type: KEY_UP, code: X11_KEY_ADD, modifiers: 0, shift: false }, + {type: KEY_UP, code: X11_KEY_SHIFT, modifiers: 0, shift: false }, + {type: KEY_DOWN, code: X11_KEY_ADD, modifiers: 0, shift: true }, + {type: KEY_UP, code: X11_KEY_ADD, modifiers: 0, shift: true }, + ] + } + ] + } + }, {tindex: 1, keyboardType: KEYBOARD_TYPE_JP, mappingTable: + // intialize keyboard mapping for RAW keyboard + {X11: [ + {keycode: JS_KEY_CAPSLOCK, entry : X11_KEY_CAPSLOCK}, + {keycode: JS_KEY_BACKSPACE, entry : X11_KEY_BACKSPACE}, + {keycode: JS_KEY_TAB, entry : X11_KEY_TAB}, + {keycode: JS_KEY_ENTER, entry : X11_KEY_ENTER}, + {keycode: JS_KEY_ESCAPE, entry : X11_KEY_ESCAPE}, + {keycode: JS_KEY_INSERT, entry : X11_KEY_INSERT}, + {keycode: JS_KEY_DELETE, entry : X11_KEY_DELETE}, + {keycode: JS_KEY_HOME, entry : X11_KEY_HOME}, + {keycode: JS_KEY_END, entry : X11_KEY_END}, + {keycode: JS_KEY_PAGEUP, entry : X11_KEY_PAGEUP}, + {keycode: JS_KEY_PAGEDOWN, entry : X11_KEY_PAGEDOWN}, + {keycode: JS_KEY_LEFT, entry : X11_KEY_LEFT}, + {keycode: JS_KEY_UP, entry : X11_KEY_UP}, + {keycode: JS_KEY_RIGHT, entry : X11_KEY_RIGHT}, + {keycode: JS_KEY_DOWN, entry : X11_KEY_DOWN}, + {keycode: JS_KEY_F1, entry : X11_KEY_F1}, + {keycode: JS_KEY_F2, entry : X11_KEY_F2}, + {keycode: JS_KEY_F3, entry : X11_KEY_F3}, + {keycode: JS_KEY_F4, entry : X11_KEY_F4}, + {keycode: JS_KEY_F5, entry : X11_KEY_F5}, + {keycode: JS_KEY_F6, entry : X11_KEY_F6}, + {keycode: JS_KEY_F7, entry : X11_KEY_F7}, + {keycode: JS_KEY_F8, entry : X11_KEY_F8}, + {keycode: JS_KEY_F9, entry : X11_KEY_F9}, + {keycode: JS_KEY_F10, entry : X11_KEY_F10}, + {keycode: JS_KEY_F11, entry : X11_KEY_F11}, + {keycode: JS_KEY_F12, entry : X11_KEY_F12}, + {keycode: JS_KEY_SHIFT, entry : X11_KEY_SHIFT}, + {keycode: JS_KEY_CTRL, entry : X11_KEY_CTRL}, + {keycode: JS_KEY_ALT, entry : X11_KEY_ALT}, + //{keycode: JS_KEY_GRAVE_ACCENT, entry : X11_KEY_GRAVE_ACCENT}, + //[192 / 64 = "' @"] + {keycode: 192, entry : 0x5b, browser: "IE"}, + {keycode: 64, entry : 0x5b, browser: "Firefox"}, + //{keycode: JS_KEY_ADD, entry : X11_KEY_ADD}, + //[187 / 59 = "; +"] + {keycode: 187, entry : 0x3a, browser: "IE"}, + {keycode: 59, entry : 0x3b, browser: "Firefox"}, + //{keycode: JS_KEY_OPEN_BRACKET, entry : X11_KEY_OPEN_BRACKET}, + //[219 = "[{"] + {keycode: 219, entry : 0x5d, browser: "IE"}, + {keycode: 219, entry : 0x5d, browser: "Firefox"}, + //{keycode: JS_KEY_CLOSE_BRACKET, entry : X11_KEY_CLOSE_BRACKET}, + //[221 = "]}"] + {keycode: 221, entry : 0x5c, browser: "IE"}, + {keycode: 221, entry : 0x5c, browser: "Firefox"}, + {keycode: JS_KEY_BACK_SLASH, entry : X11_KEY_BACK_SLASH}, + //{keycode: JS_KEY_SINGLE_QUOTE, entry : X11_KEY_SINGLE_QUOTE}, + //[222 / 160 = "~^"] + {keycode: 222, entry : 0x3d, browser: "IE"}, + {keycode: 160, entry : 0x3d, browser: "Firefox"}, + //[173 = "-=" ] specific to Firefox browser + {keycode: 173, entry : 0x2d, browser: "Firefox"}, + {keycode: JS_KEY_COMMA, entry : X11_KEY_COMMA}, + {keycode: JS_KEY_PERIOD, entry : X11_KEY_PERIOD}, + {keycode: JS_KEY_FORWARD_SLASH, entry : X11_KEY_FORWARD_SLASH}, + {keycode: JS_KEY_DASH, entry : X11_KEY_DASH}, + {keycode: JS_KEY_SEMI_COLON, entry : X11_KEY_SEMI_COLON}, + {keycode: JS_KEY_NUMPAD0, entry : X11_KEY_NUMPAD0}, + {keycode: JS_KEY_NUMPAD1, entry : X11_KEY_NUMPAD1}, + {keycode: JS_KEY_NUMPAD2, entry : X11_KEY_NUMPAD2}, + {keycode: JS_KEY_NUMPAD3, entry : X11_KEY_NUMPAD3}, + {keycode: JS_KEY_NUMPAD4, entry : X11_KEY_NUMPAD4}, + {keycode: JS_KEY_NUMPAD5, entry : X11_KEY_NUMPAD5}, + {keycode: JS_KEY_NUMPAD6, entry : X11_KEY_NUMPAD6}, + {keycode: JS_KEY_NUMPAD7, entry : X11_KEY_NUMPAD7}, + {keycode: JS_KEY_NUMPAD8, entry : X11_KEY_NUMPAD8}, + {keycode: JS_KEY_NUMPAD9, entry : X11_KEY_NUMPAD9}, + {keycode: JS_KEY_DECIMAL_POINT, entry : X11_KEY_DECIMAL_POINT}, + {keycode: JS_KEY_DIVIDE, entry : 0xffaf}, + {keycode: JS_KEY_MULTIPLY, entry : 0xffaa}, + {keycode: JS_KEY_ADD, entry : 0xffab}, + {keycode: JS_KEY_SUBSTRACT, entry : 0xffad}, + //Kanji Key = 243 / 244 + {keycode: 243, entry : 0x7e, browser: "IE"}, + {keycode: 244, entry : 0x7e, browser: "IE"}, + //Caps Lock = 240 + {keycode: 240, entry : 0xffe5}, + /* + {keycode: JS_KEY_MULTIPLY, entry : [ + {type: KEY_DOWN, code: X11_KEY_SHIFT, modifiers: 0 }, + {type: KEY_DOWN, code: X11_KEY_ASTERISK, modifiers: 0 }, + {type: KEY_UP, code: X11_KEY_ASTERISK, modifiers: 0 }, + {type: KEY_UP, code: X11_KEY_SHIFT, modifiers: 0 } + ]}, + {keycode: JS_KEY_ADD, entry : false} + */ + //[186 / 58 = "~^"] + {keycode: 186, entry : 0x22, browser: "IE"}, + {keycode: 58, entry : 0x22, browser: "Firefox"}, + ], + keyPress: [ + {keycode: 61, entry: [ + {type: KEY_DOWN, code: X11_KEY_ADD, modifiers: 0, shift: false }, + {type: KEY_UP, code: X11_KEY_ADD, modifiers: 0, shift: false } + ]}, + ] + } + }, {tindex: 2, keyboardType: KEYBOARD_TYPE_UK, mappingTable: + {X11: [], + keyPress: [ + //[34 = "] + {keycode: 34, entry: + [{type : KEY_DOWN, code : 0x40, modifiers : 64, shift : true}] + }, + //[35 = #] + {keycode: 35, entry: + [{type : KEY_DOWN, code : 0x5c, modifiers : 0, shift : false}] + }, + // [64 = @] + {keycode: 64, entry: + [{type : KEY_DOWN, code : 0x22, modifiers : 64, shift : true}] + }, + // [92 = \] + {keycode: 92, entry: + [{type : KEY_DOWN, code : 0xa6, modifiers : 0, shift : false}] + }, + // [126 = ~] + {keycode: 126, entry: + [{type : KEY_DOWN, code : 0x7c, modifiers : 64, shift : true}] + }, + // [163 = £] + {keycode: 163, entry: + [{type : KEY_DOWN, code : 0x23, modifiers : 64, shift : true}] + }, + // [172 = ¬] + {keycode: 172, entry: + [{type : KEY_DOWN, code : 0x7e, modifiers : 64, shift : true}] + }, + // [166 = ¦] + {keycode: 166, entry: + [{type : KEY_DOWN, code : 0x60, modifiers : 896, shift : false}] + } + ] + } + }] diff --git a/services/console-proxy/server/js/ajaxviewer.js b/services/console-proxy/server/js/ajaxviewer.js index e95615d8946..a6e1edafaea 100644 --- a/services/console-proxy/server/js/ajaxviewer.js +++ b/services/console-proxy/server/js/ajaxviewer.js @@ -99,92 +99,13 @@ function KeyboardMapper() { // KeyboardMapper.KEYBOARD_TYPE_RAW = 0; KeyboardMapper.KEYBOARD_TYPE_COOKED = 1; +KeyboardMapper.KEYBOARD_TYPE_UK = 2; KeyboardMapper.prototype = { - + setKeyboardType : function(keyboardType) { this.keyboardType = keyboardType; - - if(keyboardType == KeyboardMapper.KEYBOARD_TYPE_RAW) { - // intialize keyboard mapping for RAW keyboard - this.jsX11KeysymMap[AjaxViewer.JS_KEY_CAPSLOCK] = AjaxViewer.X11_KEY_CAPSLOCK; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_BACKSPACE] = AjaxViewer.X11_KEY_BACKSPACE; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_TAB] = AjaxViewer.X11_KEY_TAB; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_ENTER] = AjaxViewer.X11_KEY_ENTER; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_ESCAPE] = AjaxViewer.X11_KEY_ESCAPE; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_INSERT] = AjaxViewer.X11_KEY_INSERT; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_DELETE] = AjaxViewer.X11_KEY_DELETE; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_HOME] = AjaxViewer.X11_KEY_HOME; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_END] = AjaxViewer.X11_KEY_END; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_PAGEUP] = AjaxViewer.X11_KEY_PAGEUP; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_PAGEDOWN] = AjaxViewer.X11_KEY_PAGEDOWN; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_LEFT] = AjaxViewer.X11_KEY_LEFT; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_UP] = AjaxViewer.X11_KEY_UP; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_RIGHT] = AjaxViewer.X11_KEY_RIGHT; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_DOWN] = AjaxViewer.X11_KEY_DOWN; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F1] = AjaxViewer.X11_KEY_F1; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F2] = AjaxViewer.X11_KEY_F2; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F3] = AjaxViewer.X11_KEY_F3; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F4] = AjaxViewer.X11_KEY_F4; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F5] = AjaxViewer.X11_KEY_F5; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F6] = AjaxViewer.X11_KEY_F6; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F7] = AjaxViewer.X11_KEY_F7; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F8] = AjaxViewer.X11_KEY_F8; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F9] = AjaxViewer.X11_KEY_F9; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F10] = AjaxViewer.X11_KEY_F10; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F11] = AjaxViewer.X11_KEY_F11; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_F12] = AjaxViewer.X11_KEY_F12; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_SHIFT] = AjaxViewer.X11_KEY_SHIFT; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_CTRL] = AjaxViewer.X11_KEY_CTRL; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_ALT] = AjaxViewer.X11_KEY_ALT; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_GRAVE_ACCENT] = AjaxViewer.X11_KEY_GRAVE_ACCENT; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_SUBSTRACT] = AjaxViewer.X11_KEY_SUBSTRACT; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_ADD] = AjaxViewer.X11_KEY_ADD; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_OPEN_BRACKET] = AjaxViewer.X11_KEY_OPEN_BRACKET; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_CLOSE_BRACKET] = AjaxViewer.X11_KEY_CLOSE_BRACKET; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_BACK_SLASH] = AjaxViewer.X11_KEY_BACK_SLASH; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_SINGLE_QUOTE] = AjaxViewer.X11_KEY_SINGLE_QUOTE; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_COMMA] = AjaxViewer.X11_KEY_COMMA; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_PERIOD] = AjaxViewer.X11_KEY_PERIOD; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_FORWARD_SLASH] = AjaxViewer.X11_KEY_FORWARD_SLASH; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_DASH] = AjaxViewer.X11_KEY_DASH; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_SEMI_COLON] = AjaxViewer.X11_KEY_SEMI_COLON; - - this.jsX11KeysymMap[AjaxViewer.JS_KEY_NUMPAD0] = AjaxViewer.X11_KEY_NUMPAD0; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_NUMPAD1] = AjaxViewer.X11_KEY_NUMPAD1; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_NUMPAD2] = AjaxViewer.X11_KEY_NUMPAD2; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_NUMPAD3] = AjaxViewer.X11_KEY_NUMPAD3; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_NUMPAD4] = AjaxViewer.X11_KEY_NUMPAD4; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_NUMPAD5] = AjaxViewer.X11_KEY_NUMPAD5; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_NUMPAD6] = AjaxViewer.X11_KEY_NUMPAD6; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_NUMPAD7] = AjaxViewer.X11_KEY_NUMPAD7; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_NUMPAD8] = AjaxViewer.X11_KEY_NUMPAD8; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_NUMPAD9] = AjaxViewer.X11_KEY_NUMPAD9; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_DECIMAL_POINT] = AjaxViewer.X11_KEY_DECIMAL_POINT; - this.jsX11KeysymMap[AjaxViewer.JS_KEY_DIVIDE] = AjaxViewer.X11_KEY_DIVIDE; - - this.jsX11KeysymMap[AjaxViewer.JS_KEY_MULTIPLY] = [ - {type: AjaxViewer.KEY_DOWN, code: AjaxViewer.X11_KEY_SHIFT, modifiers: 0 }, - {type: AjaxViewer.KEY_DOWN, code: AjaxViewer.X11_KEY_ASTERISK, modifiers: 0 }, - {type: AjaxViewer.KEY_UP, code: AjaxViewer.X11_KEY_ASTERISK, modifiers: 0 }, - {type: AjaxViewer.KEY_UP, code: AjaxViewer.X11_KEY_SHIFT, modifiers: 0 } - ]; - - this.jsX11KeysymMap[AjaxViewer.JS_KEY_ADD] = false; - this.jsKeyPressX11KeysymMap = []; - this.jsKeyPressX11KeysymMap[61] = [ - {type: AjaxViewer.KEY_DOWN, code: AjaxViewer.X11_KEY_ADD, modifiers: 0, shift: false }, - {type: AjaxViewer.KEY_UP, code: AjaxViewer.X11_KEY_ADD, modifiers: 0, shift: false } - ]; - this.jsKeyPressX11KeysymMap[43] = [ - {type: AjaxViewer.KEY_DOWN, code: AjaxViewer.X11_KEY_SHIFT, modifiers: 0, shift: false }, - {type: AjaxViewer.KEY_DOWN, code: AjaxViewer.X11_KEY_ADD, modifiers: 0, shift: false }, - {type: AjaxViewer.KEY_UP, code: AjaxViewer.X11_KEY_ADD, modifiers: 0, shift: false }, - {type: AjaxViewer.KEY_UP, code: AjaxViewer.X11_KEY_SHIFT, modifiers: 0, shift: false }, - {type: AjaxViewer.KEY_DOWN, code: AjaxViewer.X11_KEY_ADD, modifiers: 0, shift: true }, - {type: AjaxViewer.KEY_UP, code: AjaxViewer.X11_KEY_ADD, modifiers: 0, shift: true } - ]; - } else { + if(keyboardType == KeyboardMapper.KEYBOARD_TYPE_COOKED || keyboardType == KeyboardMapper.KEYBOARD_TYPE_UK) { // initialize mapping for COOKED keyboard this.jsX11KeysymMap[AjaxViewer.JS_KEY_CAPSLOCK] = AjaxViewer.X11_KEY_CAPSLOCK; this.jsX11KeysymMap[AjaxViewer.JS_KEY_BACKSPACE] = AjaxViewer.X11_KEY_BACKSPACE; @@ -325,7 +246,6 @@ KeyboardMapper.prototype = { // ENTER/BACKSPACE key should already have been sent through KEY DOWN/KEY UP event if(code == AjaxViewer.JS_KEY_ENTER || code == AjaxViewer.JS_KEY_BACKSPACE) return; - if(code > 0) { var X11Keysym = code; X11Keysym = this.jsKeyPressX11KeysymMap[code]; @@ -475,6 +395,7 @@ AjaxViewer.STATUS_SENDING = 3; AjaxViewer.STATUS_SENT = 4; AjaxViewer.KEYBOARD_TYPE_ENGLISH = "us"; +AjaxViewer.KEYBOARD_TYPE_UK_ENGLISH = "uk"; AjaxViewer.KEYBOARD_TYPE_JAPANESE = "jp"; AjaxViewer.JS_KEY_BACKSPACE = 8; @@ -736,6 +657,10 @@ AjaxViewer.prototype = { this.keyboardMappers[AjaxViewer.KEYBOARD_TYPE_ENGLISH] = mapper; mapper.setKeyboardType(KeyboardMapper.KEYBOARD_TYPE_COOKED); + var mapper = new KeyboardMapper(); + this.keyboardMappers[AjaxViewer.KEYBOARD_TYPE_UK_ENGLISH] = mapper; + mapper.setKeyboardType(KeyboardMapper.KEYBOARD_TYPE_UK); + mapper = new KeyboardMapper(); this.keyboardMappers[AjaxViewer.KEYBOARD_TYPE_JAPANESE] = mapper; mapper.setKeyboardType(KeyboardMapper.KEYBOARD_TYPE_RAW); @@ -795,25 +720,25 @@ AjaxViewer.prototype = { */ // create the mapping table based on the tables input - if (keyboardTables != undefined ) { + if (keyboardTables != undefined ) { - for(var i = 0; i < keyboardTables.length; i++) { - var mappingTbl = keyboardTables[i]; - var mappings = mappingTbl.mappingTable; - var x11Maps = mappings.X11; - for (var j = 0; j < x11Maps.length; j++) { - var code = x11Maps[j].keycode; - var mappedEntry = x11Maps[j].entry; - mapper.jsX11KeysymMap[code] = mappedEntry; + for(var i = 0; i < keyboardTables.length; i++) { + var mappingTbl = keyboardTables[i]; + var keyboardType = mappingTbl.keyboardType; + var mappings = mappingTbl.mappingTable; + var x11Maps = mappings.X11; + for (var j = 0; j < x11Maps.length; j++) { + var code = x11Maps[j].keycode; + var mappedEntry = x11Maps[j].entry; + this.keyboardMappers[keyboardType].jsX11KeysymMap[code] = mappedEntry; + } + var keyPressMaps = mappings.keyPress; + for (var j = 0; j < keyPressMaps.length; j++) { + var code = keyPressMaps[j].keycode; + var mappedEntry = keyPressMaps[j].entry; + this.keyboardMappers[keyboardType].jsKeyPressX11KeysymMap[code] = mappedEntry; + } } - var keyPressMaps = mappings.keyPress; - for (var j = 0; j < keyPressMaps.length; j++) { - var code = keyPressMaps[j].keycode; - var mappedEntry = keyPressMaps[j].entry; - mapper.jsKeyPressX11KeysymMap[code] = mappedEntry; - } - - } } }, // end of the setupKeyboardTranslationTable function @@ -867,6 +792,9 @@ AjaxViewer.prototype = { } else if(cmd == "keyboard_us") { $("#toolbar").find(".pulldown").find("ul").hide(); this.currentKeyboard = AjaxViewer.KEYBOARD_TYPE_ENGLISH; + } else if(cmd == "keyboard_uk") { + $("#toolbar").find(".pulldown").find("ul").hide(); + this.currentKeyboard = AjaxViewer.KEYBOARD_TYPE_UK_ENGLISH; } else if(cmd == "sendCtrlAltDel") { this.sendKeyboardEvent(AjaxViewer.KEY_DOWN, 0xffe9, 0); // X11 Alt this.sendKeyboardEvent(AjaxViewer.KEY_DOWN, 0xffe3, 0); // X11 Ctrl diff --git a/services/console-proxy/server/pom.xml b/services/console-proxy/server/pom.xml index 3ac5d5957f7..c3e360b079f 100644 --- a/services/console-proxy/server/pom.xml +++ b/services/console-proxy/server/pom.xml @@ -22,7 +22,7 @@ Apache CloudStack Console Proxy org.apache.cloudstack - cloud-service-console-proxy + cloudstack-service-console-proxy 4.2.0-SNAPSHOT ../pom.xml diff --git a/services/console-proxy/server/src/com/cloud/consoleproxy/ConsoleProxyClientBase.java b/services/console-proxy/server/src/com/cloud/consoleproxy/ConsoleProxyClientBase.java index 289bdab2f8a..f4c912a9e53 100644 --- a/services/console-proxy/server/src/com/cloud/consoleproxy/ConsoleProxyClientBase.java +++ b/services/console-proxy/server/src/com/cloud/consoleproxy/ConsoleProxyClientBase.java @@ -329,6 +329,7 @@ public abstract class ConsoleProxyClientBase implements ConsoleProxyClient, Cons "", "", "", diff --git a/services/pom.xml b/services/pom.xml index 54b22bbbf62..805bcdb5e6d 100644 --- a/services/pom.xml +++ b/services/pom.xml @@ -18,7 +18,7 @@ --> 4.0.0 - cloud-services + cloudstack-services Apache CloudStack Cloud Services pom diff --git a/services/secondary-storage/pom.xml b/services/secondary-storage/pom.xml index 2c8a1d0b9b8..eb6c0ee9b50 100644 --- a/services/secondary-storage/pom.xml +++ b/services/secondary-storage/pom.xml @@ -22,7 +22,7 @@ Apache CloudStack Secondary Storage Service org.apache.cloudstack - cloud-services + cloudstack-services 4.2.0-SNAPSHOT ../pom.xml diff --git a/services/secondary-storage/src/org/apache/cloudstack/storage/resource/NfsSecondaryStorageResource.java b/services/secondary-storage/src/org/apache/cloudstack/storage/resource/NfsSecondaryStorageResource.java index 638d5cad99d..e7fa5b2f1bc 100755 --- a/services/secondary-storage/src/org/apache/cloudstack/storage/resource/NfsSecondaryStorageResource.java +++ b/services/secondary-storage/src/org/apache/cloudstack/storage/resource/NfsSecondaryStorageResource.java @@ -80,9 +80,9 @@ import com.cloud.agent.api.SecStorageVMSetupCommand; import com.cloud.agent.api.StartupCommand; import com.cloud.agent.api.StartupSecondaryStorageCommand; import com.cloud.agent.api.UploadTemplateToS3FromSecondaryStorageCommand; -import com.cloud.agent.api.downloadSnapshotFromSwiftCommand; -import com.cloud.agent.api.downloadTemplateFromSwiftToSecondaryStorageCommand; -import com.cloud.agent.api.uploadTemplateToSwiftFromSecondaryStorageCommand; +import com.cloud.agent.api.DownloadSnapshotFromSwiftCommand; +import com.cloud.agent.api.DownloadTemplateFromSwiftToSecondaryStorageCommand; +import com.cloud.agent.api.UploadTemplateToSwiftFromSecondaryStorageCommand; import com.cloud.agent.api.storage.CreateEntityDownloadURLCommand; import com.cloud.agent.api.storage.DeleteEntityDownloadURLCommand; import com.cloud.agent.api.storage.DeleteTemplateCommand; @@ -190,20 +190,20 @@ SecondaryStorageResource { return execute((ListTemplateCommand)cmd); } else if (cmd instanceof ListVolumeCommand){ return execute((ListVolumeCommand)cmd); - }else if (cmd instanceof downloadSnapshotFromSwiftCommand){ - return execute((downloadSnapshotFromSwiftCommand)cmd); + }else if (cmd instanceof DownloadSnapshotFromSwiftCommand){ + return execute((DownloadSnapshotFromSwiftCommand)cmd); } else if (cmd instanceof DownloadSnapshotFromS3Command) { return execute((DownloadSnapshotFromS3Command) cmd); } else if (cmd instanceof DeleteSnapshotBackupCommand){ return execute((DeleteSnapshotBackupCommand)cmd); } else if (cmd instanceof DeleteSnapshotsDirCommand){ return execute((DeleteSnapshotsDirCommand)cmd); - } else if (cmd instanceof downloadTemplateFromSwiftToSecondaryStorageCommand) { - return execute((downloadTemplateFromSwiftToSecondaryStorageCommand) cmd); + } else if (cmd instanceof DownloadTemplateFromSwiftToSecondaryStorageCommand) { + return execute((DownloadTemplateFromSwiftToSecondaryStorageCommand) cmd); } else if (cmd instanceof DownloadTemplateFromS3ToSecondaryStorageCommand) { return execute((DownloadTemplateFromS3ToSecondaryStorageCommand) cmd); - } else if (cmd instanceof uploadTemplateToSwiftFromSecondaryStorageCommand) { - return execute((uploadTemplateToSwiftFromSecondaryStorageCommand) cmd); + } else if (cmd instanceof UploadTemplateToSwiftFromSecondaryStorageCommand) { + return execute((UploadTemplateToSwiftFromSecondaryStorageCommand) cmd); } else if (cmd instanceof UploadTemplateToS3FromSecondaryStorageCommand) { return execute((UploadTemplateToS3FromSecondaryStorageCommand) cmd); } else if (cmd instanceof DeleteObjectFromSwiftCommand) { @@ -281,7 +281,7 @@ SecondaryStorageResource { } - private Answer execute(downloadTemplateFromSwiftToSecondaryStorageCommand cmd) { + private Answer execute(DownloadTemplateFromSwiftToSecondaryStorageCommand cmd) { SwiftTO swift = cmd.getSwift(); String secondaryStorageUrl = cmd.getSecondaryStorageUrl(); Long accountId = cmd.getAccountId(); @@ -324,7 +324,7 @@ SecondaryStorageResource { } } - private Answer execute(uploadTemplateToSwiftFromSecondaryStorageCommand cmd) { + private Answer execute(UploadTemplateToSwiftFromSecondaryStorageCommand cmd) { SwiftTO swift = cmd.getSwift(); String secondaryStorageUrl = cmd.getSecondaryStorageUrl(); Long accountId = cmd.getAccountId(); @@ -769,7 +769,7 @@ SecondaryStorageResource { SNAPSHOT_ROOT_DIR, accountId, volumeId); } - public Answer execute(downloadSnapshotFromSwiftCommand cmd){ + public Answer execute(DownloadSnapshotFromSwiftCommand cmd){ SwiftTO swift = cmd.getSwift(); String secondaryStorageUrl = cmd.getSecondaryStorageUrl(); Long accountId = cmd.getAccountId(); diff --git a/setup/db/db/schema-2214to30.sql b/setup/db/db/schema-2214to30.sql index 60eceea447d..e288b0fd4f9 100755 --- a/setup/db/db/schema-2214to30.sql +++ b/setup/db/db/schema-2214to30.sql @@ -664,6 +664,7 @@ ALTER TABLE `cloud`.`dc_storage_network_ip_range` ADD COLUMN `gateway` varchar(1 ALTER TABLE `cloud`.`volumes` ADD COLUMN `last_pool_id` bigint unsigned; UPDATE `cloud`.`volumes` SET `last_pool_id` = `pool_id`; +UPDATE `cloud`.`volumes` SET `path` = SUBSTRING_INDEX(`path`, '/', -1); ALTER TABLE `cloud`.`user_ip_address` ADD COLUMN `is_system` int(1) unsigned NOT NULL default '0'; ALTER TABLE `cloud`.`volumes` ADD COLUMN `update_count` bigint unsigned NOT NULL DEFAULT 0; diff --git a/setup/db/db/schema-40to410.sql b/setup/db/db/schema-40to410.sql index ff1d9085329..b7b1c7a91dd 100644 --- a/setup/db/db/schema-40to410.sql +++ b/setup/db/db/schema-40to410.sql @@ -443,6 +443,10 @@ ALTER TABLE `cloud`.`vlan` ADD COLUMN `ip6_range` varchar(255); ALTER TABLE `cloud`.`data_center` ADD COLUMN `ip6_dns1` varchar(255); ALTER TABLE `cloud`.`data_center` ADD COLUMN `ip6_dns2` varchar(255); +UPDATE `cloud`.`networks` INNER JOIN `cloud`.`vlan` ON networks.id = vlan.network_id +SET networks.gateway = vlan.vlan_gateway, networks.ip6_gateway = vlan.ip6_gateway, networks.ip6_cidr = vlan.ip6_cidr +WHERE networks.data_center_id = vlan.data_center_id AND networks.physical_network_id = vlan.physical_network_id; + -- DB views for list api DROP VIEW IF EXISTS `cloud`.`user_vm_view`; @@ -640,6 +644,7 @@ CREATE VIEW `cloud`.`domain_router_view` AS data_center.id data_center_id, data_center.uuid data_center_uuid, data_center.name data_center_name, + data_center.networktype data_center_type, data_center.dns1 dns1, data_center.dns2 dns2, data_center.ip6_dns1 ip6_dns1, @@ -680,7 +685,8 @@ CREATE VIEW `cloud`.`domain_router_view` AS domain_router.scripts_version scripts_version, domain_router.is_redundant_router is_redundant_router, domain_router.redundant_state redundant_state, - domain_router.stop_pending stop_pending + domain_router.stop_pending stop_pending, + domain_router.role role from `cloud`.`domain_router` inner join diff --git a/setup/db/db/schema-410to420.sql b/setup/db/db/schema-410to420.sql index e89cf23bcf6..0e4015cd5b3 100644 --- a/setup/db/db/schema-410to420.sql +++ b/setup/db/db/schema-410to420.sql @@ -119,21 +119,27 @@ CREATE TABLE `cloud`.`load_balancer_healthcheck_policies` ( INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'management-server', 'vm.instancename.flag', 'false', 'Append guest VM display Name (if set) to the internal name of the VM'); -INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (208, UUID(), 6, 'Windows 8'); -INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (209, UUID(), 6, 'Windows 8 (64 bit)'); -INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (210, UUID(), 6, 'Windows 8 Server (64 bit)'); -INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Windows 8', 208); -INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Windows 8 (64 bit)', 209); -INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Windows 8 Server (64 bit)', 210); +INSERT IGNORE INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (165, UUID(), 6, 'Windows 8 (32-bit)'); +INSERT IGNORE INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (166, UUID(), 6, 'Windows 8 (64-bit)'); +INSERT IGNORE INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (167, UUID(), 6, 'Windows Server 2012 (64-bit)'); +INSERT IGNORE INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (168, UUID(), 6, 'Windows Server 8 (64-bit)'); +INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Windows 8 (32-bit)', 165); +INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Windows 8 (64-bit)', 166); +INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Windows Server 2012 (64-bit)', 167); +INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Windows Server 8 (64-bit)', 168); +INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("XenServer", 'Windows 8 (32-bit)', 165); +INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("XenServer", 'Windows 8 (64-bit)', 166); +INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("XenServer", 'Windows Server 2012 (64-bit)', 167); +INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("XenServer", 'Windows Server 8 (64-bit)', 168); -INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (211, UUID(), 7, 'Apple Mac OS X 10.6 (32 bits)'); -INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (212, UUID(), 7, 'Apple Mac OS X 10.6 (64 bits)'); -INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (213, UUID(), 7, 'Apple Mac OS X 10.7 (32 bits)'); -INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (214, UUID(), 7, 'Apple Mac OS X 10.7 (64 bits)'); -INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Apple Mac OS X 10.6 (32 bits)', 211); -INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Apple Mac OS X 10.6 (64 bits)', 212); -INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Apple Mac OS X 10.7 (32 bits)', 213); -INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Apple Mac OS X 10.7 (64 bits)', 214); +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (211, UUID(), 7, 'Apple Mac OS X 10.6 (32-bit)'); +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (212, UUID(), 7, 'Apple Mac OS X 10.6 (64-bit)'); +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (213, UUID(), 7, 'Apple Mac OS X 10.7 (32-bit)'); +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (214, UUID(), 7, 'Apple Mac OS X 10.7 (64-bit)'); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Apple Mac OS X 10.6 (32-bit)', 211); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Apple Mac OS X 10.6 (64-bit)', 212); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Apple Mac OS X 10.7 (32-bit)', 213); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Apple Mac OS X 10.7 (64-bit)', 214); CREATE TABLE `cloud`.`user_vm_clone_setting` ( `vm_id` bigint unsigned NOT NULL COMMENT 'guest VM id', @@ -333,7 +339,7 @@ CREATE TABLE `cloud`.`vm_snapshots` ( ALTER TABLE `cloud`.`hypervisor_capabilities` ADD COLUMN `vm_snapshot_enabled` tinyint(1) DEFAULT 0 NOT NULL COMMENT 'Whether VM snapshot is supported by hypervisor'; UPDATE `cloud`.`hypervisor_capabilities` SET `vm_snapshot_enabled`=1 WHERE `hypervisor_type` in ('VMware', 'XenServer'); - + DROP VIEW IF EXISTS `cloud`.`user_vm_view`; CREATE VIEW `cloud`.`user_vm_view` AS select @@ -444,7 +450,7 @@ CREATE VIEW `cloud`.`user_vm_view` AS async_job.uuid job_uuid, async_job.job_status job_status, async_job.account_id job_account_id, - affinity_group.id affinity_group_id, + affinity_group.id affinity_group_id, affinity_group.uuid affinity_group_uuid, affinity_group.name affinity_group_name, affinity_group.description affinity_group_description @@ -509,7 +515,7 @@ CREATE VIEW `cloud`.`user_vm_view` AS and async_job.job_status = 0 left join `cloud`.`affinity_group_vm_map` ON vm_instance.id = affinity_group_vm_map.instance_id - left join + left join `cloud`.`affinity_group` ON affinity_group_vm_map.affinity_group_id = affinity_group.id; DROP VIEW IF EXISTS `cloud`.`affinity_group_view`; @@ -838,7 +844,8 @@ CREATE VIEW `cloud`.`domain_router_view` AS domain_router.scripts_version scripts_version, domain_router.is_redundant_router is_redundant_router, domain_router.redundant_state redundant_state, - domain_router.stop_pending stop_pending + domain_router.stop_pending stop_pending, + domain_router.role role from `cloud`.`domain_router` inner join @@ -913,7 +920,7 @@ CREATE TABLE `cloud`.`network_asa1000v_map` ( ALTER TABLE `cloud`.`network_offerings` ADD COLUMN `eip_associate_public_ip` int(1) unsigned NOT NULL DEFAULT 0 COMMENT 'true if public IP is associated with user VM creation by default when EIP service is enabled.' AFTER `elastic_ip_service`; -- Re-enable foreign key checking, at the end of the upgrade path -SET foreign_key_checks = 1; +SET foreign_key_checks = 1; -- Add "default" field to account/user tables @@ -1109,8 +1116,44 @@ CREATE VIEW `cloud`.`account_view` AS and async_job.instance_type = 'Account' and async_job.job_status = 0; + + +ALTER TABLE `cloud`.`load_balancing_rules` ADD COLUMN `source_ip_address` varchar(40) COMMENT 'source ip address for the load balancer rule'; +ALTER TABLE `cloud`.`load_balancing_rules` ADD COLUMN `source_ip_address_network_id` bigint unsigned COMMENT 'the id of the network where source ip belongs to'; +ALTER TABLE `cloud`.`load_balancing_rules` ADD COLUMN `scheme` varchar(40) NOT NULL COMMENT 'load balancer scheme; can be Internal or Public'; +UPDATE `cloud`.`load_balancing_rules` SET `scheme`='Public'; + + + +-- Add details talbe for the network offering +CREATE TABLE `cloud`.`network_offering_details` ( + `id` bigint unsigned NOT NULL auto_increment, + `network_offering_id` bigint unsigned NOT NULL COMMENT 'network offering id', + `name` varchar(255) NOT NULL, + `value` varchar(1024) NOT NULL, + PRIMARY KEY (`id`), + CONSTRAINT `fk_network_offering_details__network_offering_id` FOREIGN KEY `fk_network_offering_details__network_offering_id`(`network_offering_id`) REFERENCES `network_offerings`(`id`) ON DELETE CASCADE +) ENGINE=InnoDB DEFAULT CHARSET=utf8; + +-- Change the constraint for the network service map table. Now we support multiple provider for the same service +ALTER TABLE `cloud`.`ntwk_service_map` DROP FOREIGN KEY `fk_ntwk_service_map__network_id`; +ALTER TABLE `cloud`.`ntwk_service_map` DROP INDEX `network_id`; + +ALTER TABLE `cloud`.`ntwk_service_map` ADD UNIQUE `network_id` (`network_id`,`service`,`provider`); +ALTER TABLE `cloud`.`ntwk_service_map` ADD CONSTRAINT `fk_ntwk_service_map__network_id` FOREIGN KEY (`network_id`) REFERENCES `networks` (`id`) ON DELETE CASCADE; + + +ALTER TABLE `cloud`.`network_offerings` ADD COLUMN `internal_lb` int(1) unsigned NOT NULL DEFAULT '0' COMMENT 'true if the network offering supports Internal lb service'; +ALTER TABLE `cloud`.`network_offerings` ADD COLUMN `public_lb` int(1) unsigned NOT NULL DEFAULT '0' COMMENT 'true if the network offering supports Public lb service'; +UPDATE `cloud`.`network_offerings` SET public_lb=1 where id IN (SELECT DISTINCT network_offering_id FROM `cloud`.`ntwk_offering_service_map` WHERE service='Lb'); + + +INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'NetworkManager', 'internallbvm.service.offering', null, 'Uuid of the service offering used by internal lb vm; if NULL - default system internal lb offering will be used'); + + alter table `cloud_usage`.`usage_network_offering` add column nic_id bigint(20) unsigned NOT NULL; + CREATE TABLE `cloud`.`portable_ip_range` ( `id` bigint unsigned NOT NULL UNIQUE AUTO_INCREMENT, `uuid` varchar(40), @@ -1146,3 +1189,30 @@ CREATE TABLE `cloud`.`portable_ip_address` ( ) ENGINE=InnoDB DEFAULT CHARSET=utf8; ALTER TABLE `cloud`.`user_ip_address` ADD COLUMN is_portable int(1) unsigned NOT NULL default '0'; + +ALTER TABLE `cloud`.`data_center_details` MODIFY value varchar(1024); +ALTER TABLE `cloud`.`cluster_details` MODIFY value varchar(255); +ALTER TABLE `cloud`.`storage_pool_details` MODIFY value varchar(255); +ALTER TABLE `cloud`.`account_details` MODIFY value varchar(255); + +INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Network', 'DEFAULT', 'management-server', 'midonet.apiserver.address', 'http://localhost:8081', 'Specify the address at which the Midonet API server can be contacted (if using Midonet)'); +INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Network', 'DEFAULT', 'management-server', 'midonet.providerrouter.id', 'd7c5e6a3-e2f4-426b-b728-b7ce6a0448e5', 'Specifies the UUID of the Midonet provider router (if using Midonet)'); + +alter table cloud.vpc_gateways add column source_nat boolean default false; +alter table cloud.private_ip_address add column source_nat boolean default false; + +CREATE TABLE `cloud`.`account_vnet_map` ( + `id` bigint unsigned NOT NULL UNIQUE AUTO_INCREMENT, + `uuid` varchar(255) UNIQUE, + `vnet_range` varchar(255) NOT NULL COMMENT 'dedicated guest vlan range', + `account_id` bigint unsigned NOT NULL COMMENT 'account id. foreign key to account table', + `physical_network_id` bigint unsigned NOT NULL COMMENT 'physical network id. foreign key to the the physical network table', + PRIMARY KEY (`id`), + CONSTRAINT `fk_account_vnet_map__physical_network_id` FOREIGN KEY (`physical_network_id`) REFERENCES `physical_network` (`id`) ON DELETE CASCADE, + INDEX `i_account_vnet_map__physical_network_id`(`physical_network_id`), + CONSTRAINT `fk_account_vnet_map__account_id` FOREIGN KEY (`account_id`) REFERENCES `account` (`id`) ON DELETE CASCADE, + INDEX `i_account_vnet_map__account_id`(`account_id`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8; + +ALTER TABLE `cloud`.`op_dc_vnet_alloc` ADD COLUMN account_vnet_map_id bigint unsigned; +ALTER TABLE `cloud`.`op_dc_vnet_alloc` ADD CONSTRAINT `fk_op_dc_vnet_alloc__account_vnet_map_id` FOREIGN KEY `fk_op_dc_vnet_alloc__account_vnet_map_id` (`account_vnet_map_id`) REFERENCES `account_vnet_map` (`id`); diff --git a/setup/db/templates.sql b/setup/db/templates.sql index 2f95f1e00f8..1685dce385c 100755 --- a/setup/db/templates.sql +++ b/setup/db/templates.sql @@ -214,6 +214,10 @@ INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (161 INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (162, UUID(), 1, 'CentOS 5.7 (64-bit)'); INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (163, UUID(), 10, 'Ubuntu 12.04 (32-bit)'); INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (164, UUID(), 10, 'Ubuntu 12.04 (64-bit)'); +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (165, UUID(), 6, 'Windows 8 (32-bit)'); +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (166, UUID(), 6, 'Windows 8 (64-bit)'); +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (167, UUID(), 6, 'Windows Server 2012 (64-bit)'); +INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (168, UUID(), 6, 'Windows Server 8 (64-bit)'); INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (200, UUID(), 1, 'Other CentOS (32-bit)'); INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name) VALUES (201, UUID(), 1, 'Other CentOS (64-bit)'); @@ -294,6 +298,10 @@ INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ('XenServer', 'Other install media', 130); INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ('XenServer', 'Other PV (32-bit)', 139); INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ('XenServer', 'Other PV (64-bit)', 140); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("XenServer", 'Windows 8 (32-bit)', 165); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("XenServer", 'Windows 8 (64-bit)', 166); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("XenServer", 'Windows Server 2012 (64-bit)', 167); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("XenServer", 'Windows Server 8 (64-bit)', 168); INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Microsoft Windows 7(32-bit)', 48); @@ -323,6 +331,10 @@ INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Microsoft Windows 95', 63); INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Microsoft Windows NT 4', 64); INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Microsoft Windows 3.1', 65); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Windows 8 (32-bit)', 165); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Windows 8 (64-bit)', 166); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Windows Server 2012 (64-bit)', 167); +INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Windows Server 8 (64-bit)', 168); INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Red Hat Enterprise Linux 5.0(32-bit)', 30); INSERT INTO `cloud`.`guest_os_hypervisor` (hypervisor_type, guest_os_name, guest_os_id) VALUES ("VmWare", 'Red Hat Enterprise Linux 5.1(32-bit)', 32); diff --git a/setup/dev/advanced.cfg b/setup/dev/advanced.cfg index c031c2a4f84..83357866ca7 100644 --- a/setup/dev/advanced.cfg +++ b/setup/dev/advanced.cfg @@ -45,7 +45,14 @@ { "broadcastdomainrange": "ZONE", "name": "VpcVirtualRouter" + }, + { + "broadcastdomainrange": "ZONE", + "name": "InternalLbVm" } + ], + "isolationmethods": [ + "VLAN" ] } ], @@ -84,8 +91,12 @@ "clustertype": "CloudManaged", "primaryStorages": [ { - "url": "nfs://10.147.28.6:/export/home/sandbox/primary", + "url": "nfs://10.147.28.6:/export/home/sandbox/primary0", "name": "PS0" + }, + { + "url": "nfs://10.147.28.6:/export/home/sandbox/primary1", + "name": "PS1" } ] } diff --git a/setup/dev/basic.cfg b/setup/dev/basic.cfg index 3f56a3ce980..326874d1f19 100644 --- a/setup/dev/basic.cfg +++ b/setup/dev/basic.cfg @@ -42,6 +42,9 @@ "broadcastdomainrange": "Pod", "name": "SecurityGroupProvider" } + ], + "isolationmethods": [ + "L3" ] } ], diff --git a/test/integration/component/test_accounts.py b/test/integration/component/test_accounts.py index 459cfb3a251..9cbefe55fdb 100644 --- a/test/integration/component/test_accounts.py +++ b/test/integration/component/test_accounts.py @@ -60,7 +60,7 @@ class Services: "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, + "memory": 128, # In MBs }, "virtual_machine": { @@ -162,11 +162,11 @@ class TestAccounts(cloudstackTestCase): self.apiclient, self.services["account"] ) - self.debug("Created account: %s" % account.account.name) + self.debug("Created account: %s" % account.name) self.cleanup.append(account) list_accounts_response = list_accounts( self.apiclient, - id=account.account.id + id=account.id ) self.assertEqual( isinstance(list_accounts_response, list), @@ -181,12 +181,12 @@ class TestAccounts(cloudstackTestCase): account_response = list_accounts_response[0] self.assertEqual( - account.account.accounttype, + account.accounttype, account_response.accounttype, "Check Account Type of Created account" ) self.assertEqual( - account.account.name, + account.name, account_response.name, "Check Account Name of Created account" ) @@ -194,8 +194,8 @@ class TestAccounts(cloudstackTestCase): user = User.create( self.apiclient, self.services["user"], - account=account.account.name, - domainid=account.account.domainid + account=account.name, + domainid=account.domainid ) self.debug("Created user: %s" % user.id) list_users_response = list_users( @@ -301,15 +301,15 @@ class TestRemoveUserFromAccount(cloudstackTestCase): user_1 = User.create( self.apiclient, self.services["user"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created user: %s" % user_1.id) user_2 = User.create( self.apiclient, self.services["user"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created user: %s" % user_2.id) self.cleanup.append(user_2) @@ -317,12 +317,12 @@ class TestRemoveUserFromAccount(cloudstackTestCase): vm_1 = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.debug("Deployed VM in account: %s, ID: %s" % ( - self.account.account.name, + self.account.name, vm_1.id )) self.cleanup.append(vm_1) @@ -330,12 +330,12 @@ class TestRemoveUserFromAccount(cloudstackTestCase): vm_2 = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.debug("Deployed VM in account: %s, ID: %s" % ( - self.account.account.name, + self.account.name, vm_2.id )) self.cleanup.append(vm_2) @@ -347,7 +347,7 @@ class TestRemoveUserFromAccount(cloudstackTestCase): # Account should exist after deleting user accounts_response = list_accounts( self.apiclient, - id=self.account.account.id + id=self.account.id ) self.assertEqual( isinstance(accounts_response, list), @@ -362,8 +362,8 @@ class TestRemoveUserFromAccount(cloudstackTestCase): ) vm_response = list_virtual_machines( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(vm_response, list), @@ -401,43 +401,43 @@ class TestRemoveUserFromAccount(cloudstackTestCase): user_1 = User.create( self.apiclient, self.services["user"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created user: %s" % user_1.id) user_2 = User.create( self.apiclient, self.services["user"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created user: %s" % user_2.id) vm_1 = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, + accountid=self.account.name, serviceofferingid=self.service_offering.id ) self.debug("Deployed VM in account: %s, ID: %s" % ( - self.account.account.name, + self.account.name, vm_1.id )) vm_2 = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, + accountid=self.account.name, serviceofferingid=self.service_offering.id ) self.debug("Deployed VM in account: %s, ID: %s" % ( - self.account.account.name, + self.account.name, vm_2.id )) # Get users associated with an account # (Total 3: 2 - Created & 1 default generated while account creation) users = list_users( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(users, list), @@ -468,7 +468,7 @@ class TestRemoveUserFromAccount(cloudstackTestCase): # Account is removed after last user is deleted account_response = list_accounts( self.apiclient, - id=self.account.account.id + id=self.account.id ) self.assertEqual( account_response, @@ -478,8 +478,8 @@ class TestRemoveUserFromAccount(cloudstackTestCase): # All VMs associated with account are removed. vm_response = list_virtual_machines( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( vm_response, @@ -490,8 +490,8 @@ class TestRemoveUserFromAccount(cloudstackTestCase): with self.assertRaises(Exception): list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) return @@ -1217,11 +1217,11 @@ class TestUserDetails(cloudstackTestCase): # Fetching the user details of account self.debug( "Fetching user details for account: %s" % - self.account.account.name) + self.account.name) users = User.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(users, list), @@ -1304,11 +1304,11 @@ class TestUserDetails(cloudstackTestCase): # Fetching the user details of account self.debug( "Fetching user details for account: %s" % - self.account.account.name) + self.account.name) users = User.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(users, list), @@ -1391,11 +1391,11 @@ class TestUserDetails(cloudstackTestCase): # Fetching the user details of account self.debug( "Fetching user details for account: %s" % - self.account.account.name) + self.account.name) users = User.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(users, list), @@ -1515,7 +1515,7 @@ class TestUserLogin(cloudstackTestCase): self.debug("Logging into the cloudstack with login API") respose = User.login( self.apiclient, - username=self.account.account.name, + username=self.account.name, password=self.services["account"]["password"] ) self.assertEqual(respose, None, "Login response should not be none") @@ -1572,8 +1572,8 @@ class TestUserLogin(cloudstackTestCase): accounts = Account.list( self.apiclient, - name=self.account.account.name, - domainid=self.account.account.domainid, + name=self.account.name, + domainid=self.account.domainid, listall=True ) @@ -1586,7 +1586,7 @@ class TestUserLogin(cloudstackTestCase): self.debug("Logging into the cloudstack with login API") respose = User.login( self.apiclient, - username=self.account.account.name, + username=self.account.name, password=self.services["account"]["password"] ) self.assertEqual(respose, None, "Login response should not be none") diff --git a/test/integration/component/test_allocation_states.py b/test/integration/component/test_allocation_states.py index fe4c35f3b9f..5ce0b21124b 100644 --- a/test/integration/component/test_allocation_states.py +++ b/test/integration/component/test_allocation_states.py @@ -49,7 +49,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "disk_offering": { "displaytext": "Small", diff --git a/test/integration/component/test_blocker_bugs.py b/test/integration/component/test_blocker_bugs.py index bfd1c13cb19..d099bf1a448 100644 --- a/test/integration/component/test_blocker_bugs.py +++ b/test/integration/component/test_blocker_bugs.py @@ -51,7 +51,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "disk_offering": { "displaytext": "Small", @@ -136,7 +136,7 @@ class TestSnapshots(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -146,8 +146,8 @@ class TestSnapshots(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=cls.template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, mode=cls.services["mode"] ) @@ -204,8 +204,8 @@ class TestSnapshots(cloudstackTestCase): self.apiclient, self.services["volume"], zoneid=self.zone.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, diskofferingid=self.disk_offering.id ) self.debug("Created volume with ID: %s" % volume.id) @@ -283,8 +283,8 @@ class TestSnapshots(cloudstackTestCase): snapshot = Snapshot.create( self.apiclient, volume_response.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created snapshot: %s" % snapshot.id) #Create volume from snapshot @@ -292,8 +292,8 @@ class TestSnapshots(cloudstackTestCase): self.apiclient, snapshot.id, self.services["volume"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created Volume: %s from Snapshot: %s" % ( volume_from_snapshot.id, @@ -323,12 +323,12 @@ class TestSnapshots(cloudstackTestCase): self.apiclient, self.services["virtual_machine"], templateid=self.template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, mode=self.services["mode"] ) - self.debug("Deployed new VM for account: %s" % self.account.account.name) + self.debug("Deployed new VM for account: %s" % self.account.name) self.cleanup.append(new_virtual_machine) self.debug("Attaching volume: %s to VM: %s" % ( @@ -434,7 +434,7 @@ class TestTemplate(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, @@ -471,8 +471,8 @@ class TestTemplate(cloudstackTestCase): self.apiclient, self.services["templates"], zoneid=self.zone.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Registering template with ID: %s" % template.id) try: @@ -519,8 +519,8 @@ class TestTemplate(cloudstackTestCase): self.apiclient, self.services["virtual_machine"], templateid=template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, ) self.debug("Deployed VM with ID: %s " % virtual_machine.id) @@ -565,15 +565,15 @@ class TestNATRules(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.public_ip = PublicIPAddress.create( cls.api_client, - accountid=cls.account.account.name, + accountid=cls.account.name, zoneid=cls.zone.id, - domainid=cls.account.account.domainid, + domainid=cls.account.domainid, services=cls.services["virtual_machine"] ) cls._cleanup = [ @@ -817,23 +817,23 @@ class TestRouters(cloudstackTestCase): vm_1 = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.admin_account.account.name, - domainid=self.admin_account.account.domainid, + accountid=self.admin_account.name, + domainid=self.admin_account.domainid, serviceofferingid=self.service_offering.id ) self.debug("Deployed VM with ID: %s" % vm_1.id) vm_2 = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.user_account.account.name, - domainid=self.user_account.account.domainid, + accountid=self.user_account.name, + domainid=self.user_account.domainid, serviceofferingid=self.service_offering.id ) self.debug("Deployed VM with ID: %s" % vm_2.id) routers = list_routers( self.apiclient, - account=self.admin_account.account.name, - domainid=self.admin_account.account.domainid, + account=self.admin_account.name, + domainid=self.admin_account.domainid, ) self.assertEqual( isinstance(routers, list), @@ -887,8 +887,8 @@ class TestRouterRestart(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.cleanup = [ @@ -927,8 +927,8 @@ class TestRouterRestart(cloudstackTestCase): # Find router associated with user account list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -945,8 +945,8 @@ class TestRouterRestart(cloudstackTestCase): while True: networks = Network.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) network = networks[0] if network.state in ["Implemented", "Setup"]: @@ -966,8 +966,8 @@ class TestRouterRestart(cloudstackTestCase): # Get router details after restart list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -1009,7 +1009,7 @@ class TestTemplates(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, cls.services["service_offering"] @@ -1020,8 +1020,8 @@ class TestTemplates(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, ) #Stop virtual machine @@ -1091,8 +1091,8 @@ class TestTemplates(cloudstackTestCase): self.apiclient, self.services["templates"], self.volume.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Creating template with ID: %s" % template.id) # Volume and Template Size should be same @@ -1121,8 +1121,8 @@ class TestTemplates(cloudstackTestCase): snapshot = Snapshot.create( self.apiclient, self.volume.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created snapshot with ID: %s" % snapshot.id) snapshots = Snapshot.list( @@ -1203,8 +1203,8 @@ class TestTemplates(cloudstackTestCase): snapshot = Snapshot.create( self.apiclient, self.volume.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created snapshot with ID: %s" % snapshot.id) snapshots = Snapshot.list( diff --git a/test/integration/component/test_egress_rules.py b/test/integration/component/test_egress_rules.py index 7972aa50639..872ca2c7b5d 100644 --- a/test/integration/component/test_egress_rules.py +++ b/test/integration/component/test_egress_rules.py @@ -69,7 +69,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "security_group": { "name": 'SSH', @@ -175,7 +175,7 @@ class TestDefaultSecurityGroupEgress(cloudstackTestCase): admin=True, domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, @@ -208,12 +208,12 @@ class TestDefaultSecurityGroupEgress(cloudstackTestCase): # 4. listVirtualMachines should show that the VM belongs to default # security group - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.debug("Deployed VM with ID: %s" % self.virtual_machine.id) @@ -260,8 +260,8 @@ class TestDefaultSecurityGroupEgress(cloudstackTestCase): # Verify listSecurity groups response security_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(security_groups, list), @@ -333,7 +333,7 @@ class TestAuthorizeIngressRule(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, cls.service_offering @@ -371,15 +371,15 @@ class TestAuthorizeIngressRule(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -396,8 +396,8 @@ class TestAuthorizeIngressRule(cloudstackTestCase): ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(ingress_rule, dict), @@ -410,12 +410,12 @@ class TestAuthorizeIngressRule(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Should be able to SSH VM try: self.debug("SSH into VM: %s" % self.virtual_machine.ssh_ip) @@ -491,7 +491,7 @@ class TestDefaultGroupEgress(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, cls.service_offering @@ -529,16 +529,16 @@ class TestDefaultGroupEgress(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -557,8 +557,8 @@ class TestDefaultGroupEgress(cloudstackTestCase): ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -575,8 +575,8 @@ class TestDefaultGroupEgress(cloudstackTestCase): egress_rule = security_group.authorizeEgress( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -589,12 +589,12 @@ class TestDefaultGroupEgress(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Should be able to SSH VM try: @@ -692,7 +692,7 @@ class TestDefaultGroupEgressAfterDeploy(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, cls.service_offering @@ -730,16 +730,16 @@ class TestDefaultGroupEgressAfterDeploy(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -758,8 +758,8 @@ class TestDefaultGroupEgressAfterDeploy(cloudstackTestCase): ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -773,12 +773,12 @@ class TestDefaultGroupEgressAfterDeploy(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Authorize Security group to SSH to VM self.debug( @@ -787,8 +787,8 @@ class TestDefaultGroupEgressAfterDeploy(cloudstackTestCase): egress_rule = security_group.authorizeEgress( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -875,7 +875,7 @@ class TestRevokeEgressRule(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, cls.service_offering @@ -915,16 +915,16 @@ class TestRevokeEgressRule(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -944,8 +944,8 @@ class TestRevokeEgressRule(cloudstackTestCase): ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -963,8 +963,8 @@ class TestRevokeEgressRule(cloudstackTestCase): egress_rule = security_group.authorizeEgress( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -977,12 +977,12 @@ class TestRevokeEgressRule(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Should be able to SSH VM try: @@ -1033,7 +1033,7 @@ class TestRevokeEgressRule(cloudstackTestCase): "Revoke Egress Rule for Security Group %s for account: %s" \ % ( security_group.id, - self.account.account.name + self.account.name )) result = security_group.revokeEgress( @@ -1137,7 +1137,7 @@ class TestInvalidAccountAuthroize(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, cls.service_offering @@ -1173,16 +1173,16 @@ class TestInvalidAccountAuthroize(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -1205,7 +1205,7 @@ class TestInvalidAccountAuthroize(cloudstackTestCase): self.apiclient, self.services["security_group"], account=random_gen(), - domainid=self.account.account.domainid + domainid=self.account.domainid ) return @@ -1804,7 +1804,7 @@ class TestStartStopVMWithEgressRule(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, cls.service_offering @@ -1842,16 +1842,16 @@ class TestStartStopVMWithEgressRule(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -1871,8 +1871,8 @@ class TestStartStopVMWithEgressRule(cloudstackTestCase): ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -1886,12 +1886,12 @@ class TestStartStopVMWithEgressRule(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Authorize Security group to SSH to VM self.debug( @@ -1900,8 +1900,8 @@ class TestStartStopVMWithEgressRule(cloudstackTestCase): egress_rule = security_group.authorizeEgress( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -2016,7 +2016,7 @@ class TestInvalidParametersForEgress(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, cls.service_offering @@ -2054,16 +2054,16 @@ class TestInvalidParametersForEgress(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -2085,8 +2085,8 @@ class TestInvalidParametersForEgress(cloudstackTestCase): egress_rule = security_group.authorizeEgress( self.apiclient, self.services["sg_invalid_port"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug( "Authorizing egress rule for sec group ID: %s with invalid cidr" @@ -2095,8 +2095,8 @@ class TestInvalidParametersForEgress(cloudstackTestCase): egress_rule = security_group.authorizeEgress( self.apiclient, self.services["sg_invalid_cidr"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug( "Authorizing egress rule for sec group ID: %s with invalid account" @@ -2106,7 +2106,7 @@ class TestInvalidParametersForEgress(cloudstackTestCase): self.apiclient, self.services["security_group"], account=random_gen(), - domainid=self.account.account.domainid + domainid=self.account.domainid ) self.debug( "Authorizing egress rule for sec group ID: %s with cidr: anywhere and port: 22" @@ -2114,8 +2114,8 @@ class TestInvalidParametersForEgress(cloudstackTestCase): egress_rule_A = security_group.authorizeEgress( self.apiclient, self.services["sg_cidr_anywhere"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -2127,8 +2127,8 @@ class TestInvalidParametersForEgress(cloudstackTestCase): egress_rule_R = security_group.authorizeEgress( self.apiclient, self.services["sg_cidr_restricted"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -2144,8 +2144,8 @@ class TestInvalidParametersForEgress(cloudstackTestCase): security_group.authorizeEgress( self.apiclient, self.services["sg_cidr_restricted"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) return @@ -2203,7 +2203,7 @@ class TestEgressAfterHostMaintainance(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, cls.service_offering @@ -2241,16 +2241,16 @@ class TestEgressAfterHostMaintainance(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -2270,8 +2270,8 @@ class TestEgressAfterHostMaintainance(cloudstackTestCase): ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -2289,8 +2289,8 @@ class TestEgressAfterHostMaintainance(cloudstackTestCase): egress_rule = security_group.authorizeEgress( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -2303,12 +2303,12 @@ class TestEgressAfterHostMaintainance(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Should be able to SSH VM try: diff --git a/test/integration/component/test_eip_elb.py b/test/integration/component/test_eip_elb.py index c1ad50530b5..b01371b7643 100644 --- a/test/integration/component/test_eip_elb.py +++ b/test/integration/component/test_eip_elb.py @@ -49,7 +49,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "lbrule": { "name": "SSH", @@ -119,8 +119,8 @@ class TestEIP(cloudstackTestCase): cls.virtual_machine = VirtualMachine.create( cls.api_client, cls.services["virtual_machine"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) networks = Network.list( @@ -140,8 +140,8 @@ class TestEIP(cloudstackTestCase): cls.api_client, associatednetworkid=cls.guest_network.id, isstaticnat=True, - account=cls.account.account.name, - domainid=cls.account.account.domainid, + account=cls.account.name, + domainid=cls.account.domainid, listall=True ) if isinstance(ip_addrs, list): @@ -240,8 +240,8 @@ class TestEIP(cloudstackTestCase): # Verify listSecurity groups response security_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(security_groups, list), @@ -262,8 +262,8 @@ class TestEIP(cloudstackTestCase): "Creating Ingress rule to allow SSH on default security group") cmd = authorizeSecurityGroupIngress.authorizeSecurityGroupIngressCmd() - cmd.domainid = self.account.account.domainid - cmd.account = self.account.account.name + cmd.domainid = self.account.domainid + cmd.account = self.account.name cmd.securitygroupid = security_group.id cmd.protocol = 'TCP' cmd.startport = 22 @@ -370,16 +370,16 @@ class TestEIP(cloudstackTestCase): public_ip = PublicIPAddress.create( self.apiclient, - accountid=self.account.account.name, + accountid=self.account.name, zoneid=self.zone.id, - domainid=self.account.account.domainid, + domainid=self.account.domainid, services=self.services["virtual_machine"] ) self.debug("IP address: %s is acquired by network: %s" % ( - public_ip.ipaddress.ipaddress, + public_ip.ipaddress, self.guest_network.id)) self.debug("Enabling static NAT for IP Address: %s" % - public_ip.ipaddress.ipaddress) + public_ip.ipaddress) StaticNATRule.enable( self.apiclient, @@ -390,11 +390,11 @@ class TestEIP(cloudstackTestCase): # Fetch details from user_ip_address table in database self.debug( "select is_system, one_to_one_nat from user_ip_address where public_ip_address='%s';" \ - % public_ip.ipaddress.ipaddress) + % public_ip.ipaddress) qresultset = self.dbclient.execute( "select is_system, one_to_one_nat from user_ip_address where public_ip_address='%s';" \ - % public_ip.ipaddress.ipaddress + % public_ip.ipaddress ) self.assertEqual( isinstance(qresultset, list), @@ -449,12 +449,12 @@ class TestEIP(cloudstackTestCase): ) # try: -# self.debug("SSH into VM: %s" % public_ip.ipaddress.ipaddress) +# self.debug("SSH into VM: %s" % public_ip.ipaddress) # ssh = self.virtual_machine.get_ssh_client( -# ipaddress=public_ip.ipaddress.ipaddress) +# ipaddress=public_ip.ipaddress) # except Exception as e: # self.fail("SSH Access failed for %s: %s" % \ -# (public_ip.ipaddress.ipaddress, e) +# (public_ip.ipaddress, e) # ) self.debug("SSH into netscaler: %s" % @@ -472,7 +472,7 @@ class TestEIP(cloudstackTestCase): self.debug("Output: %s" % result) self.assertEqual( - result.count(public_ip.ipaddress.ipaddress), + result.count(public_ip.ipaddress), 1, "One IP from EIP pool should be taken and configured on NS" ) @@ -484,7 +484,7 @@ class TestEIP(cloudstackTestCase): self.debug("Output: %s" % result) self.assertEqual( - result.count("NAME: Cloud-Inat-%s" % public_ip.ipaddress.ipaddress), + result.count("NAME: Cloud-Inat-%s" % public_ip.ipaddress), 1, "User source IP should be enabled for INAT service" ) @@ -517,8 +517,8 @@ class TestEIP(cloudstackTestCase): self.api_client, associatednetworkid=self.guest_network.id, isstaticnat=True, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, listall=True ) self.assertEqual( @@ -602,8 +602,8 @@ class TestEIP(cloudstackTestCase): self.api_client, associatednetworkid=self.guest_network.id, isstaticnat=True, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, listall=True ) self.assertEqual( @@ -711,8 +711,8 @@ class TestEIP(cloudstackTestCase): self.api_client, associatednetworkid=self.guest_network.id, isstaticnat=True, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, listall=True ) self.assertEqual( @@ -784,8 +784,8 @@ class TestEIP(cloudstackTestCase): self.api_client, associatednetworkid=self.guest_network.id, isstaticnat=True, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, listall=True ) self.assertEqual( @@ -942,15 +942,15 @@ class TestELB(cloudstackTestCase): cls.vm_1 = VirtualMachine.create( cls.api_client, cls.services["virtual_machine"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.vm_2 = VirtualMachine.create( cls.api_client, cls.services["virtual_machine"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) networks = Network.list( @@ -968,9 +968,9 @@ class TestELB(cloudstackTestCase): cls.lb_rule = LoadBalancerRule.create( cls.api_client, cls.services["lbrule"], - accountid=cls.account.account.name, + accountid=cls.account.name, networkid=cls.guest_network.id, - domainid=cls.account.account.domainid + domainid=cls.account.domainid ) cls.lb_rule.assign(cls.api_client, [cls.vm_1, cls.vm_2]) @@ -1024,8 +1024,8 @@ class TestELB(cloudstackTestCase): # Verify listSecurity groups response security_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(security_groups, list), @@ -1046,8 +1046,8 @@ class TestELB(cloudstackTestCase): "Creating Ingress rule to allow SSH on default security group") cmd = authorizeSecurityGroupIngress.authorizeSecurityGroupIngressCmd() - cmd.domainid = self.account.account.domainid - cmd.account = self.account.account.name + cmd.domainid = self.account.domainid + cmd.account = self.account.name cmd.securitygroupid = security_group.id cmd.protocol = 'TCP' cmd.startport = 22 @@ -1056,12 +1056,12 @@ class TestELB(cloudstackTestCase): self.apiclient.authorizeSecurityGroupIngress(cmd) self.debug( - "Fetching LB IP for account: %s" % self.account.account.name) + "Fetching LB IP for account: %s" % self.account.name) ip_addrs = PublicIPAddress.list( self.api_client, associatednetworkid=self.guest_network.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, forloadbalancing=True, listall=True ) @@ -1073,7 +1073,7 @@ class TestELB(cloudstackTestCase): lb_ip = ip_addrs[0] self.debug("LB IP generated for account: %s is: %s" % ( - self.account.account.name, + self.account.name, lb_ip.ipaddress )) #TODO: uncomment this after ssh issue is resolved @@ -1199,24 +1199,24 @@ class TestELB(cloudstackTestCase): public_ip = PublicIPAddress.create( self.apiclient, - accountid=self.account.account.name, + accountid=self.account.name, zoneid=self.zone.id, - domainid=self.account.account.domainid, + domainid=self.account.domainid, services=self.services["virtual_machine"] ) self.debug("IP address: %s is acquired by network: %s" % ( - public_ip.ipaddress.ipaddress, + public_ip.ipaddress, self.guest_network.id)) self.debug("Creating LB rule for public IP: %s" % - public_ip.ipaddress.ipaddress) + public_ip.ipaddress) lb_rule = LoadBalancerRule.create( self.apiclient, self.services["lbrule"], - accountid=self.account.account.name, + accountid=self.account.name, ipaddressid=public_ip.ipaddress.id, networkid=self.guest_network.id, - domainid=self.account.account.domaind + domainid=self.account.domaind ) self.debug("Assigning VMs (%s, %s) to LB rule: %s" % (self.vm_1.name, self.vm_2.name, @@ -1225,10 +1225,10 @@ class TestELB(cloudstackTestCase): #TODO: workaround : add route in the guest VM for SNIP # # self.debug("SSHing into VMs using ELB IP: %s" % -# public_ip.ipaddress.ipaddress) +# public_ip.ipaddress) # try: # ssh_1 = self.vm_1.get_ssh_client( -# ipaddress=public_ip.ipaddress.ipaddress) +# ipaddress=public_ip.ipaddress) # self.debug("Command: hostname") # result = ssh_1.execute("hostname") # self.debug("Result: %s" % result) @@ -1244,7 +1244,7 @@ class TestELB(cloudstackTestCase): # ) # # ssh_2 = self.vm_2.get_ssh_client( -# ipaddress=public_ip.ipaddress.ipaddress) +# ipaddress=public_ip.ipaddress) # self.debug("Command: hostname") # result = ssh_2.execute("hostname") # self.debug("Result: %s" % result) @@ -1265,11 +1265,11 @@ class TestELB(cloudstackTestCase): ## Fetch details from user_ip_address table in database self.debug( "select is_system from user_ip_address where public_ip_address='%s';" \ - % public_ip.ipaddress.ipaddress) + % public_ip.ipaddress) qresultset = self.dbclient.execute( "select is_system from user_ip_address where public_ip_address='%s';" \ - % public_ip.ipaddress.ipaddress) + % public_ip.ipaddress) self.assertEqual( isinstance(qresultset, list), @@ -1304,7 +1304,7 @@ class TestELB(cloudstackTestCase): self.debug("Output: %s" % result) self.assertEqual( - result.count(public_ip.ipaddress.ipaddress), + result.count(public_ip.ipaddress), 1, "One IP from EIP pool should be taken and configured on NS" ) @@ -1316,7 +1316,7 @@ class TestELB(cloudstackTestCase): self.debug("Output: %s" % result) self.assertEqual( - result.count("Cloud-VirtualServer-%s-22 (%s:22) - TCP" % (public_ip.ipaddress.ipaddress, public_ip.ipaddress.ipaddress)), + result.count("Cloud-VirtualServer-%s-22 (%s:22) - TCP" % (public_ip.ipaddress, public_ip.ipaddress)), 1, "User subnet IP should be enabled for LB service" ) @@ -1342,12 +1342,12 @@ class TestELB(cloudstackTestCase): # running and USNIP : ON self.debug( - "Fetching LB IP for account: %s" % self.account.account.name) + "Fetching LB IP for account: %s" % self.account.name) ip_addrs = PublicIPAddress.list( self.api_client, associatednetworkid=self.guest_network.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, forloadbalancing=True, listall=True ) @@ -1359,7 +1359,7 @@ class TestELB(cloudstackTestCase): lb_ip = ip_addrs[0] self.debug("LB IP generated for account: %s is: %s" % ( - self.account.account.name, + self.account.name, lb_ip.ipaddress )) @@ -1424,11 +1424,11 @@ class TestELB(cloudstackTestCase): # Fetch details from account_id table in database self.debug( "select id from account where account_name='%s';" \ - % self.account.account.name) + % self.account.name) qresultset = self.dbclient.execute( "select id from account where account_name='%s';" \ - % self.account.account.name) + % self.account.name) self.assertEqual( isinstance(qresultset, list), @@ -1467,7 +1467,7 @@ class TestELB(cloudstackTestCase): public_ip = qresult[0] self.debug( - "Fetching public IP for account: %s" % self.account.account.name) + "Fetching public IP for account: %s" % self.account.name) ip_addrs = PublicIPAddress.list( self.api_client, ipaddress=public_ip, diff --git a/test/integration/component/test_multiple_ip_ranges.py b/test/integration/component/test_multiple_ip_ranges.py new file mode 100644 index 00000000000..7e9e712aef0 --- /dev/null +++ b/test/integration/component/test_multiple_ip_ranges.py @@ -0,0 +1,429 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +""" Tests for Multiple IP Ranges feature +""" +from marvin.cloudstackTestCase import * +from marvin.cloudstackAPI import * +from marvin.cloudstackException import cloudstackAPIException +from marvin.integration.lib.utils import * +from marvin.integration.lib.base import * +from marvin.integration.lib.common import * +from netaddr import * + +from nose.plugins.attrib import attr + +class Services: + """Test Multiple IP Ranges + """ + def __init__(self): + self.services = { + "account": { + "email": "test@test.com", + "firstname": "Test", + "lastname": "User", + "username": "test", + # Random characters are appended for unique + # username + "password": "password", + }, + "service_offering": { + "name": "Tiny Instance", + "displaytext": "Tiny Instance", + "cpunumber": 1, + "cpuspeed": 200, # in MHz + "memory": 256, # In MBs + }, + "disk_offering": { + "displaytext": "Small Disk", + "name": "Small Disk", + "disksize": 1 + }, + "templates": { + "displaytext": 'Template', + "name": 'Template', + "ostype": "CentOS 5.3 (64-bit)", + "templatefilter": 'self', + }, + "vlan_ip_range": { + "startip": "", + "endip": "", + "netmask": "", + "gateway": "", + "forvirtualnetwork": "false", + "vlan": "untagged", + } + } + +class TestMultipleIpRanges(cloudstackTestCase): + """Test Multiple IP Ranges for guest network + """ + + + @classmethod + def setUpClass(cls): + cls.api_client = super(TestMultipleIpRanges, cls).getClsTestClient().getApiClient() + cls.services = Services().services + # Get Zone, Domain and templates + cls.domain = get_domain(cls.api_client, cls.services) + cls.zone = get_zone(cls.api_client, cls.services) + cls.pod = get_pod(cls.api_client, cls.zone.id, cls.services) + cls.services['mode'] = cls.zone.networktype + cls.services["domainid"] = cls.domain.id + cls.services["zoneid"] = cls.zone.id + cls.account = Account.create( + cls.api_client, + cls.services["account"], + domainid=cls.domain.id + ) + cls.services["account"] = cls.account.name + cls._cleanup = [ + cls.account, + ] + return + + @classmethod + def tearDownClass(cls): + try: + #Cleanup resources used + cleanup_resources(cls.api_client, cls._cleanup) + except Exception as e: + raise Exception("Warning: Exception during cleanup : %s" % e) + return + + def setUp(self): + self.apiclient = self.testClient.getApiClient() + self.dbclient = self.testClient.getDbConnection() + self.cleanup = [ ] + return + + def tearDown(self): + try: + #Clean up, terminate the resources created + cleanup_resources(self.apiclient, self.cleanup) + except Exception as e: + raise Exception("Warning: Exception during cleanup : %s" % e) + return + + def increment_cidr(self): + """Takes CIDR as input and will increment by one and returns the new CIDR + """ + publicIpRange = PublicIpRange.list(self.apiclient) + self.startIp = publicIpRange[0].startip + self.endIp = publicIpRange[0].endip + self.gateway = publicIpRange[0].gateway + self.netmask = publicIpRange[0].netmask + #Pass ip address and mask length to IPNetwork to findout the CIDR + ip = IPNetwork(self.startIp+"/"+self.netmask) + new_cidr = ip.__iadd__(1) + ip2 = IPNetwork(new_cidr) + return ip2 + + def verify_vlan_range(self,vlan,services): + #compare vlan_list response with configured values + self.assertEqual( + isinstance(vlan, list), + True, + "Check list response returned a valid list" + ) + self.assertNotEqual( + len(vlan), + 0, + "check list vlan response" + ) + self.assertEqual( + str(vlan[0].startip), + str(services["startip"]), + "Start IP in vlan ip range is not matched with the configured start ip" + ) + self.assertEqual( + str(vlan[0].endip), + str(services["endip"]), + "End IP in vlan ip range is not matched with the configured end ip" + ) + self.assertEqual( + str(vlan[0].gateway), + str(services["gateway"]), + "gateway in vlan ip range is not matched with the configured gateway" + ) + self.assertEqual( + str(vlan[0].netmask), + str(services["netmask"]), + "netmask in vlan ip range is not matched with the configured netmask" + ) + return + + @attr(tags=["advanced_sg", "sg"]) + def test_01_add_ip_same_cidr(self): + """Test add guest ip range in the existing cidr + """ + #call increment_cidr function to get exiting cidr from the setup and increment it + ip2 = self.increment_cidr() + test_nw = ip2.network + ip = IPAddress(test_nw) + #Add IP range(5 IPs) in the new CIDR + test_gateway = ip.__add__(1) + test_startIp = ip.__add__(3) + test_endIp = ip.__add__(10) + test_startIp2= ip.__add__(11) + test_endIp2 = ip.__add__(15) + #Populating services with new IP range + self.services["vlan_ip_range"]["startip"] = test_startIp + self.services["vlan_ip_range"]["endip"] = test_endIp + self.services["vlan_ip_range"]["gateway"] = test_gateway + self.services["vlan_ip_range"]["netmask"] = self.netmask + self.services["vlan_ip_range"]["zoneid"] = self.zone.id + self.services["vlan_ip_range"]["podid"] = self.pod.id + #create new vlan ip range + new_vlan = PublicIpRange.create(self.apiclient, self.services["vlan_ip_range"]) + self.debug("Created new vlan range with startip:%s and endip:%s" %(test_startIp,test_endIp)) + self.cleanup.append(new_vlan) + new_vlan_res = new_vlan.list(self.apiclient,id=new_vlan.vlan.id) + #Compare list output with configured values + self.verify_vlan_range(new_vlan_res,self.services["vlan_ip_range"]) + #Add few more ips in the same CIDR + self.services["vlan_ip_range"]["startip"] = test_startIp2 + self.services["vlan_ip_range"]["endip"] = test_endIp2 + new_vlan2 = PublicIpRange.create(self.apiclient, self.services["vlan_ip_range"]) + self.debug("Created new vlan range with startip:%s and endip:%s" %(test_startIp2,test_endIp2)) + self.cleanup.append(new_vlan2) + #list new vlan ip range + new_vlan2_res = new_vlan2.list(self.apiclient,id=new_vlan2.vlan.id) + #Compare list output with configured values + self.verify_vlan_range(new_vlan2_res,self.services["vlan_ip_range"]) + return + + @attr(tags=["advanced_sg", "sg"]) + def test_02_add_ip_diff_cidr(self): + """Test add ip range in a new cidr + + Steps: + 1.Get public vlan range (guest cidr) from the setup + 2.Add IP range to a new cidr + """ + #call increment_cidr function to get exiting cidr from the setup and increment it + ip2 = self.increment_cidr() + test_nw = ip2.network + ip = IPAddress(test_nw) + #Add IP range(5 IPs) in the new CIDR + test_gateway = ip.__add__(1) + test_startIp = ip.__add__(3) + test_endIp = ip.__add__(10) + #Populating services with new IP range + self.services["vlan_ip_range"]["startip"] = test_startIp + self.services["vlan_ip_range"]["endip"] = test_endIp + self.services["vlan_ip_range"]["gateway"] = test_gateway + self.services["vlan_ip_range"]["netmask"] = self.netmask + self.services["vlan_ip_range"]["zoneid"] = self.zone.id + self.services["vlan_ip_range"]["podid"] = self.pod.id + #create new vlan ip range + new_vlan = PublicIpRange.create(self.apiclient, self.services["vlan_ip_range"]) + self.debug("Created new vlan range with startip:%s and endip:%s" %(test_startIp,test_endIp)) + self.cleanup.append(new_vlan) + new_vlan_res = new_vlan.list(self.apiclient,id=new_vlan.vlan.id) + #Compare list output with configured values + self.verify_vlan_range(new_vlan_res,self.services["vlan_ip_range"]) + return + + @attr(tags=["advanced-sg", "sg"]) + def test_03_del_ip_range(self): + """Test delete ip range + + Steps: + 1.Add ip range in same/new cidr + 2.delete the ip range added at step1 + 3.Verify the ip range deletion using list APIs + """ + #call increment_cidr function to get exiting cidr from the setup and increment it + ip2 = self.increment_cidr() + test_nw = ip2.network + ip = IPAddress(test_nw) + #Add IP range(5 IPs) in the new CIDR + test_gateway = ip.__add__(1) + test_startIp = ip.__add__(3) + test_endIp = ip.__add__(10) + #Populating services with new IP range + self.services["vlan_ip_range"]["startip"] = test_startIp + self.services["vlan_ip_range"]["endip"] = test_endIp + self.services["vlan_ip_range"]["gateway"] = test_gateway + self.services["vlan_ip_range"]["netmask"] = self.netmask + self.services["vlan_ip_range"]["zoneid"] = self.zone.id + self.services["vlan_ip_range"]["podid"] = self.pod.id + #create new vlan ip range + new_vlan = PublicIpRange.create(self.apiclient, self.services["vlan_ip_range"]) + self.debug("Created new vlan range with startip:%s and endip:%s" %(test_startIp,test_endIp)) + new_vlan_res = new_vlan.list(self.apiclient,id=new_vlan.vlan.id) + #Compare list output with configured values + self.verify_vlan_range(new_vlan_res,self.services["vlan_ip_range"]) + #Delete the above IP range + new_vlan.delete(self.apiclient) + #listing vlan ip ranges with the id should through exception , if not mark the test case as failed + try: + new_vlan.list(self.apiclient, id=new_vlan.vlan.id) + except cloudstackAPIException as cs: + self.debug(cs.errorMsg) + self.assertTrue(cs.errorMsg.find("entity does not exist")>0, msg="Failed to delete IP range") + return + + @attr(tags=["advanced-sg", "sg"]) + def test_04_add_noncontiguous_ip_range(self): + """Test adding non-contiguous ip range in existing cidr + + 1.Add ip range in new cidr + 1.Add non-contigous ip range in cidr added at step1 + 2.Verify the ip range using list APIs + """ + #call increment_cidr function to get exiting cidr from the setup and increment it + ip2 = self.increment_cidr() + test_nw = ip2.network + ip = IPAddress(test_nw) + #Add IP range(5 IPs) in the new CIDR + test_gateway = ip.__add__(1) + test_startIp = ip.__add__(50) + test_endIp = ip.__add__(60) + #Populating services with new IP range + self.services["vlan_ip_range"]["startip"] = test_startIp + self.services["vlan_ip_range"]["endip"] = test_endIp + self.services["vlan_ip_range"]["gateway"] = test_gateway + self.services["vlan_ip_range"]["netmask"] = self.netmask + self.services["vlan_ip_range"]["zoneid"] = self.zone.id + self.services["vlan_ip_range"]["podid"] = self.pod.id + #create new vlan ip range + new_vlan = PublicIpRange.create(self.apiclient, self.services["vlan_ip_range"]) + self.debug("Created new vlan range with startip:%s and endip:%s" %(test_startIp,test_endIp)) + self.cleanup.append(new_vlan) + new_vlan_res = new_vlan.list(self.apiclient,id=new_vlan.vlan.id) + #Compare list output with configured values + self.verify_vlan_range(new_vlan_res,self.services["vlan_ip_range"]) + #Add non-contiguous ip range in exiting cidr + test_startIp2 = ip.__add__(10) + test_endIp2 = ip.__add__(20) + #Populating services with new IP range + self.services["vlan_ip_range"]["startip"] = test_startIp2 + self.services["vlan_ip_range"]["endip"] = test_endIp2 + #create new vlan ip range + new_vlan = PublicIpRange.create(self.apiclient, self.services["vlan_ip_range"]) + self.debug("Created new vlan range with startip:%s and endip:%s" %(test_startIp,test_endIp)) + self.cleanup.append(new_vlan) + new_vlan_res = new_vlan.list(self.apiclient,id=new_vlan.vlan.id) + #Compare list output with configured values + self.verify_vlan_range(new_vlan_res,self.services["vlan_ip_range"]) + return + + @attr(tags=["advanced-sg", "sg"]) + def test_05_add_overlapped_ip_range(self): + """Test adding overlapped ip range in existing cidr + + 1.Add ip range in new cidr e.g:10.147.40.10-10.147.40.100 + 2.Add ip range overlapped with the ip range in step1 e.g.10.147.40.90-150 + """ + #call increment_cidr function to get exiting cidr from the setup and increment it + ip2 = self.increment_cidr() + test_nw = ip2.network + ip = IPAddress(test_nw) + #Add IP range in the new CIDR + test_gateway = ip.__add__(1) + test_startIp = ip.__add__(10) + test_endIp = ip.__add__(100) + test_startIp2 = ip.__add__(90) + test_endIp2 = ip.__add__(150) + #Populating services with new IP range + self.services["vlan_ip_range"]["startip"] = test_startIp + self.services["vlan_ip_range"]["endip"] = test_endIp + self.services["vlan_ip_range"]["gateway"] = test_gateway + self.services["vlan_ip_range"]["netmask"] = self.netmask + self.services["vlan_ip_range"]["zoneid"] = self.zone.id + self.services["vlan_ip_range"]["podid"] = self.pod.id + #create new vlan ip range + new_vlan = PublicIpRange.create(self.apiclient, self.services["vlan_ip_range"]) + self.debug("Created new vlan range with startip:%s and endip:%s" %(test_startIp,test_endIp)) + self.cleanup.append(new_vlan) + new_vlan_res = new_vlan.list(self.apiclient,id=new_vlan.vlan.id) + #Compare list output with configured values + self.verify_vlan_range(new_vlan_res,self.services["vlan_ip_range"]) + #Add overlapped ip range + #Populating services with new IP range + self.services["vlan_ip_range"]["startip"] = test_startIp2 + self.services["vlan_ip_range"]["endip"] = test_endIp2 + #Try to create ip range overlapped with exiting ip range + try: + PublicIpRange.create(self.apiclient, self.services["vlan_ip_range"]) + except cloudstackAPIException as cs: + self.debug(cs.errorMsg) + self.assertTrue(cs.errorMsg.find("already has IPs that overlap with the new range")>0, msg="Fail:CS allowed adding overlapped ip ranges in guest cidr") + return + #Test will reach here there is a bug in overlap ip range checking + self.fail("CS should not accept overlapped ip ranges in guest traffic, but it allowed") + return + + + @attr(tags=["advanced_sg", "sg"]) + def test_06_add_ip_range_overlapped_with_two_ranges(self): + """Test adding overlapped ip range in existing cidr + + 1.Add ip range in new cidr e.g:10.147.40.2-10.147.40.10 + 2.Add another ip range in the same cidr e.g:10.147.40.20-10.147.40.30 + 2.Add ip range overlapped with both the ip ranges e.g.10.147.40.10-20 + """ + #call increment_cidr function to get exiting cidr from the setup and increment it + ip2 = self.increment_cidr() + test_nw = ip2.network + ip = IPAddress(test_nw) + #Add IP range in the new CIDR + test_gateway = ip.__add__(1) + test_startIp = ip.__add__(2) + test_endIp = ip.__add__(10) + test_startIp2 = ip.__add__(20) + test_endIp2 = ip.__add__(30) + test_startIp3 = ip.__add__(10) + test_endIp3 = ip.__add__(20) + #Populating services with new IP range + self.services["vlan_ip_range"]["startip"] = test_startIp + self.services["vlan_ip_range"]["endip"] = test_endIp + self.services["vlan_ip_range"]["gateway"] = test_gateway + self.services["vlan_ip_range"]["netmask"] = self.netmask + self.services["vlan_ip_range"]["zoneid"] = self.zone.id + self.services["vlan_ip_range"]["podid"] = self.pod.id + #create new vlan ip range + new_vlan = PublicIpRange.create(self.apiclient, self.services["vlan_ip_range"]) + self.debug("Created new vlan range with startip:%s and endip:%s" %(test_startIp,test_endIp)) + self.cleanup.append(new_vlan) + new_vlan_res = new_vlan.list(self.apiclient,id=new_vlan.vlan.id) + #Compare list output with configured values + self.verify_vlan_range(new_vlan_res,self.services["vlan_ip_range"]) + #Add 2nd IP range in the same CIDR + self.services["vlan_ip_range"]["startip"] = test_startIp2 + self.services["vlan_ip_range"]["endip"] = test_endIp2 + new_vlan = PublicIpRange.create(self.apiclient, self.services["vlan_ip_range"]) + self.debug("Created new vlan range with startip:%s and endip:%s" %(test_startIp2,test_endIp2)) + self.cleanup.append(new_vlan) + new_vlan_res = new_vlan.list(self.apiclient,id=new_vlan.vlan.id) + #Compare list output with configured values + self.verify_vlan_range(new_vlan_res,self.services["vlan_ip_range"]) + #Add ip range which will overlap with two existing ip ranges in the same CIDR + #Populating services with new IP range + self.services["vlan_ip_range"]["startip"] = test_startIp3 + self.services["vlan_ip_range"]["endip"] = test_endIp3 + #Try to create ip range overlapped with exiting ip range + try: + PublicIpRange.create(self.apiclient, self.services["vlan_ip_range"]) + except cloudstackAPIException as cs: + self.debug(cs.errorMsg) + self.assertTrue(cs.errorMsg.find("already has IPs that overlap with the new range")>0, msg="Fail:CS allowed adding overlapped ip ranges in guest cidr") + return + #Test will reach here there is a bug in overlap ip range checking + self.fail("CS should not accept overlapped ip ranges in guest traffic, but it allowed") + return diff --git a/test/integration/component/test_network_offering.py b/test/integration/component/test_network_offering.py index 8b12525103a..e33c3765642 100644 --- a/test/integration/component/test_network_offering.py +++ b/test/integration/component/test_network_offering.py @@ -49,7 +49,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "network_offering": { "name": 'Network offering-VR services', @@ -256,21 +256,21 @@ class TestNOVirtualRouter(cloudstackTestCase): self.network = Network.create( self.apiclient, self.services["network"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, networkofferingid=self.network_offering.id, zoneid=self.zone.id ) self.debug("Created network with ID: %s" % self.network.id) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Spawn an instance in that network virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, networkids=[str(self.network.id)] ) @@ -279,8 +279,8 @@ class TestNOVirtualRouter(cloudstackTestCase): src_nat_list = PublicIPAddress.list( self.apiclient, associatednetworkid=self.network.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, listall=True, issourcenat=True, ) @@ -305,7 +305,7 @@ class TestNOVirtualRouter(cloudstackTestCase): self.apiclient, self.services["lbrule"], ipaddressid=src_nat.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug( "Trying to create a port forwarding rule in source NAT: %s" % @@ -322,18 +322,18 @@ class TestNOVirtualRouter(cloudstackTestCase): self.debug("Associating public IP for network: %s" % self.network.id) ip_with_nat_rule = PublicIPAddress.create( self.apiclient, - accountid=self.account.account.name, + accountid=self.account.name, zoneid=self.zone.id, - domainid=self.account.account.domainid, + domainid=self.account.domainid, networkid=self.network.id ) self.debug("Associated %s with network %s" % ( - ip_with_nat_rule.ipaddress.ipaddress, + ip_with_nat_rule.ipaddress, self.network.id )) self.debug("Creating PF rule for IP address: %s" % - ip_with_nat_rule.ipaddress.ipaddress) + ip_with_nat_rule.ipaddress) NATRule.create( self.apiclient, virtual_machine, @@ -342,7 +342,7 @@ class TestNOVirtualRouter(cloudstackTestCase): ) self.debug("Trying to create LB rule on IP with NAT: %s" % - ip_with_nat_rule.ipaddress.ipaddress) + ip_with_nat_rule.ipaddress) # Create Load Balancer rule on IP already having NAT rule with self.assertRaises(Exception): @@ -350,7 +350,7 @@ class TestNOVirtualRouter(cloudstackTestCase): self.apiclient, self.services["lbrule"], ipaddressid=ip_with_nat_rule.ipaddress.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug("Creating PF rule with public port: 66") @@ -376,27 +376,27 @@ class TestNOVirtualRouter(cloudstackTestCase): self.debug("Associating public IP for network: %s" % self.network.id) ip_with_lb_rule = PublicIPAddress.create( self.apiclient, - accountid=self.account.account.name, + accountid=self.account.name, zoneid=self.zone.id, - domainid=self.account.account.domainid, + domainid=self.account.domainid, networkid=self.network.id ) self.debug("Associated %s with network %s" % ( - ip_with_lb_rule.ipaddress.ipaddress, + ip_with_lb_rule.ipaddress, self.network.id )) self.debug("Creating LB rule for IP address: %s" % - ip_with_lb_rule.ipaddress.ipaddress) + ip_with_lb_rule.ipaddress) LoadBalancerRule.create( self.apiclient, self.services["lbrule"], ipaddressid=ip_with_lb_rule.ipaddress.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug("Trying to create PF rule on IP with LB rule: %s" % - ip_with_nat_rule.ipaddress.ipaddress) + ip_with_nat_rule.ipaddress) with self.assertRaises(Exception): NATRule.create( @@ -411,7 +411,7 @@ class TestNOVirtualRouter(cloudstackTestCase): self.apiclient, self.services["lbrule_port_2221"], ipaddressid=ip_with_lb_rule.ipaddress.id, - accountid=self.account.account.name + accountid=self.account.name ) # Check if NAT rule created successfully @@ -499,21 +499,21 @@ class TestNOVirtualRouter(cloudstackTestCase): self.network = Network.create( self.apiclient, self.services["network"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, networkofferingid=self.network_offering.id, zoneid=self.zone.id ) self.debug("Created network with ID: %s" % self.network.id) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Spawn an instance in that network virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, networkids=[str(self.network.id)] ) @@ -522,8 +522,8 @@ class TestNOVirtualRouter(cloudstackTestCase): src_nat_list = PublicIPAddress.list( self.apiclient, associatednetworkid=self.network.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, listall=True, issourcenat=True, ) @@ -547,7 +547,7 @@ class TestNOVirtualRouter(cloudstackTestCase): self.apiclient, self.services["lbrule"], ipaddressid=src_nat.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug("Created LB rule on source NAT: %s" % src_nat.ipaddress) @@ -624,18 +624,18 @@ class TestNOVirtualRouter(cloudstackTestCase): self.debug("Associating public IP for network: %s" % self.network.id) public_ip = PublicIPAddress.create( self.apiclient, - accountid=self.account.account.name, + accountid=self.account.name, zoneid=self.zone.id, - domainid=self.account.account.domainid, + domainid=self.account.domainid, networkid=self.network.id ) self.debug("Associated %s with network %s" % ( - public_ip.ipaddress.ipaddress, + public_ip.ipaddress, self.network.id )) self.debug("Creating PF rule for IP address: %s" % - public_ip.ipaddress.ipaddress) + public_ip.ipaddress) NATRule.create( self.apiclient, virtual_machine, @@ -644,14 +644,14 @@ class TestNOVirtualRouter(cloudstackTestCase): ) self.debug("Trying to create LB rule on IP with NAT: %s" % - public_ip.ipaddress.ipaddress) + public_ip.ipaddress) # Create Load Balancer rule on IP already having NAT rule lb_rule = LoadBalancerRule.create( self.apiclient, self.services["lbrule"], ipaddressid=public_ip.ipaddress.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug("Creating PF rule with public port: 66") @@ -679,7 +679,7 @@ class TestNOVirtualRouter(cloudstackTestCase): self.apiclient, self.services["lbrule_port_2221"], ipaddressid=public_ip.ipaddress.id, - accountid=self.account.account.name + accountid=self.account.name ) # Check if NAT rule created successfully @@ -700,8 +700,8 @@ class TestNOVirtualRouter(cloudstackTestCase): vpn = Vpn.create( self.apiclient, src_nat.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) vpns = Vpn.list( @@ -834,21 +834,21 @@ class TestNOWithNetscaler(cloudstackTestCase): self.network = Network.create( self.apiclient, self.services["network"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, networkofferingid=self.network_offering.id, zoneid=self.zone.id ) self.debug("Created network with ID: %s" % self.network.id) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Spawn an instance in that network virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, networkids=[str(self.network.id)] ) @@ -857,8 +857,8 @@ class TestNOWithNetscaler(cloudstackTestCase): src_nat_list = PublicIPAddress.list( self.apiclient, associatednetworkid=self.network.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, listall=True, issourcenat=True, ) @@ -883,7 +883,7 @@ class TestNOWithNetscaler(cloudstackTestCase): self.apiclient, self.services["lbrule"], ipaddressid=src_nat.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug( @@ -930,18 +930,18 @@ class TestNOWithNetscaler(cloudstackTestCase): self.debug("Associating public IP for network: %s" % self.network.id) ip_with_nat_rule = PublicIPAddress.create( self.apiclient, - accountid=self.account.account.name, + accountid=self.account.name, zoneid=self.zone.id, - domainid=self.account.account.domainid, + domainid=self.account.domainid, networkid=self.network.id ) self.debug("Associated %s with network %s" % ( - ip_with_nat_rule.ipaddress.ipaddress, + ip_with_nat_rule.ipaddress, self.network.id )) self.debug("Creating PF rule for IP address: %s" % - ip_with_nat_rule.ipaddress.ipaddress) + ip_with_nat_rule.ipaddress) NATRule.create( self.apiclient, virtual_machine, @@ -950,7 +950,7 @@ class TestNOWithNetscaler(cloudstackTestCase): ) self.debug("Trying to create LB rule on IP with NAT: %s" % - ip_with_nat_rule.ipaddress.ipaddress) + ip_with_nat_rule.ipaddress) # Create Load Balancer rule on IP already having NAT rule with self.assertRaises(Exception): @@ -958,7 +958,7 @@ class TestNOWithNetscaler(cloudstackTestCase): self.apiclient, self.services["lbrule"], ipaddressid=ip_with_nat_rule.ipaddress.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug("Creating PF rule with public port: 66") @@ -984,28 +984,28 @@ class TestNOWithNetscaler(cloudstackTestCase): self.debug("Associating public IP for network: %s" % self.network.id) ip_with_lb_rule = PublicIPAddress.create( self.apiclient, - accountid=self.account.account.name, + accountid=self.account.name, zoneid=self.zone.id, - domainid=self.account.account.domainid, + domainid=self.account.domainid, networkid=self.network.id ) self.debug("Associated %s with network %s" % ( - ip_with_lb_rule.ipaddress.ipaddress, + ip_with_lb_rule.ipaddress, self.network.id )) self.debug("Creating LB rule for IP address: %s" % - ip_with_lb_rule.ipaddress.ipaddress) + ip_with_lb_rule.ipaddress) LoadBalancerRule.create( self.apiclient, self.services["lbrule"], ipaddressid=ip_with_lb_rule.ipaddress.id, - accountid=self.account.account.name, + accountid=self.account.name, networkid=self.network.id ) self.debug("Trying to create PF rule on IP with LB rule: %s" % - ip_with_nat_rule.ipaddress.ipaddress) + ip_with_nat_rule.ipaddress) with self.assertRaises(Exception): NATRule.create( @@ -1031,7 +1031,7 @@ class TestNOWithNetscaler(cloudstackTestCase): self.apiclient, self.services["lbrule_port_2221"], ipaddressid=ip_with_lb_rule.ipaddress.id, - accountid=self.account.account.name, + accountid=self.account.name, networkid=self.network.id ) @@ -1054,8 +1054,8 @@ class TestNOWithNetscaler(cloudstackTestCase): Vpn.create( self.apiclient, src_nat.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) return @@ -1104,21 +1104,21 @@ class TestNOWithNetscaler(cloudstackTestCase): self.network = Network.create( self.apiclient, self.services["network"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, networkofferingid=self.network_offering.id, zoneid=self.zone.id ) self.debug("Created network with ID: %s" % self.network.id) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Spawn an instance in that network virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, networkids=[str(self.network.id)] ) @@ -1127,8 +1127,8 @@ class TestNOWithNetscaler(cloudstackTestCase): src_nat_list = PublicIPAddress.list( self.apiclient, associatednetworkid=self.network.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, listall=True, issourcenat=True, ) @@ -1153,7 +1153,7 @@ class TestNOWithNetscaler(cloudstackTestCase): self.apiclient, self.services["lbrule"], ipaddressid=src_nat.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug( @@ -1213,18 +1213,18 @@ class TestNOWithNetscaler(cloudstackTestCase): self.debug("Associating public IP for network: %s" % self.network.id) ip_with_nat_rule = PublicIPAddress.create( self.apiclient, - accountid=self.account.account.name, + accountid=self.account.name, zoneid=self.zone.id, - domainid=self.account.account.domainid, + domainid=self.account.domainid, networkid=self.network.id ) self.debug("Associated %s with network %s" % ( - ip_with_nat_rule.ipaddress.ipaddress, + ip_with_nat_rule.ipaddress, self.network.id )) self.debug("Creating PF rule for IP address: %s" % - ip_with_nat_rule.ipaddress.ipaddress) + ip_with_nat_rule.ipaddress) NATRule.create( self.apiclient, virtual_machine, @@ -1233,7 +1233,7 @@ class TestNOWithNetscaler(cloudstackTestCase): ) self.debug("Trying to create LB rule on IP with NAT: %s" % - ip_with_nat_rule.ipaddress.ipaddress) + ip_with_nat_rule.ipaddress) # Create Load Balancer rule on IP already having NAT rule with self.assertRaises(Exception): @@ -1241,7 +1241,7 @@ class TestNOWithNetscaler(cloudstackTestCase): self.apiclient, self.services["lbrule"], ipaddressid=ip_with_nat_rule.ipaddress.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug("Creating PF rule with public port: 66") @@ -1267,28 +1267,28 @@ class TestNOWithNetscaler(cloudstackTestCase): self.debug("Associating public IP for network: %s" % self.network.id) ip_with_lb_rule = PublicIPAddress.create( self.apiclient, - accountid=self.account.account.name, + accountid=self.account.name, zoneid=self.zone.id, - domainid=self.account.account.domainid, + domainid=self.account.domainid, networkid=self.network.id ) self.debug("Associated %s with network %s" % ( - ip_with_lb_rule.ipaddress.ipaddress, + ip_with_lb_rule.ipaddress, self.network.id )) self.debug("Creating LB rule for IP address: %s" % - ip_with_lb_rule.ipaddress.ipaddress) + ip_with_lb_rule.ipaddress) LoadBalancerRule.create( self.apiclient, self.services["lbrule"], ipaddressid=ip_with_lb_rule.ipaddress.id, - accountid=self.account.account.name, + accountid=self.account.name, networkid=self.network.id ) self.debug("Trying to create PF rule on IP with LB rule: %s" % - ip_with_nat_rule.ipaddress.ipaddress) + ip_with_nat_rule.ipaddress) with self.assertRaises(Exception): NATRule.create( @@ -1314,7 +1314,7 @@ class TestNOWithNetscaler(cloudstackTestCase): self.apiclient, self.services["lbrule_port_2221"], ipaddressid=ip_with_lb_rule.ipaddress.id, - accountid=self.account.account.name, + accountid=self.account.name, networkid=self.network.id ) @@ -1336,8 +1336,8 @@ class TestNOWithNetscaler(cloudstackTestCase): vpn = Vpn.create( self.apiclient, src_nat.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) vpns = Vpn.list( @@ -1457,21 +1457,21 @@ class TestNetworkUpgrade(cloudstackTestCase): self.network = Network.create( self.apiclient, self.services["network"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, networkofferingid=self.network_offering.id, zoneid=self.zone.id ) self.debug("Created network with ID: %s" % self.network.id) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Spawn an instance in that network virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, networkids=[str(self.network.id)] ) @@ -1480,8 +1480,8 @@ class TestNetworkUpgrade(cloudstackTestCase): src_nat_list = PublicIPAddress.list( self.apiclient, associatednetworkid=self.network.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, listall=True, issourcenat=True, ) @@ -1504,7 +1504,7 @@ class TestNetworkUpgrade(cloudstackTestCase): self.apiclient, self.services["lbrule"], ipaddressid=src_nat.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug("Created LB rule on source NAT: %s" % src_nat.ipaddress) @@ -1585,8 +1585,8 @@ class TestNetworkUpgrade(cloudstackTestCase): vpn = Vpn.create( self.apiclient, src_nat.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) vpns = Vpn.list( @@ -1657,21 +1657,21 @@ class TestNetworkUpgrade(cloudstackTestCase): self.network = Network.create( self.apiclient, self.services["network"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, networkofferingid=self.network_offering.id, zoneid=self.zone.id ) self.debug("Created network with ID: %s" % self.network.id) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Spawn an instance in that network virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, networkids=[str(self.network.id)] ) @@ -1680,8 +1680,8 @@ class TestNetworkUpgrade(cloudstackTestCase): src_nat_list = PublicIPAddress.list( self.apiclient, associatednetworkid=self.network.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, listall=True, issourcenat=True, ) @@ -1704,7 +1704,7 @@ class TestNetworkUpgrade(cloudstackTestCase): self.apiclient, self.services["lbrule"], ipaddressid=src_nat.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug("Created LB rule on source NAT: %s" % src_nat.ipaddress) @@ -1785,8 +1785,8 @@ class TestNetworkUpgrade(cloudstackTestCase): vpn = Vpn.create( self.apiclient, src_nat.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) vpns = Vpn.list( @@ -1921,21 +1921,21 @@ class TestSharedNetworkWithoutIp(cloudstackTestCase): self.network = Network.create( self.apiclient, self.services["network"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, networkofferingid=shared_nw_off.id, zoneid=self.zone.id ) self.debug("Created network with ID: %s" % self.network.id) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) try: # Spawn an instance in that network VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, networkids=[str(self.network.id)] ) diff --git a/test/integration/component/test_project_configs.py b/test/integration/component/test_project_configs.py index f1469f22e52..1eef123b2ee 100644 --- a/test/integration/component/test_project_configs.py +++ b/test/integration/component/test_project_configs.py @@ -70,7 +70,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "virtual_machine": { "displayname": "Test VM", @@ -206,8 +206,8 @@ class TestUserProjectCreation(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -242,8 +242,8 @@ class TestUserProjectCreation(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.user.account.name, - domainid=self.user.account.domainid + account=self.user.name, + domainid=self.user.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -373,8 +373,8 @@ class TestProjectCreationNegative(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -409,11 +409,11 @@ class TestProjectCreationNegative(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.user.account.name, - domainid=self.user.account.domainid + account=self.user.name, + domainid=self.user.domainid ) self.debug("Project creation with domain user: %s failed" % - self.user.account.name) + self.user.name) return @@ -498,8 +498,8 @@ class TestProjectInviteRequired(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -531,21 +531,21 @@ class TestProjectInviteRequired(cloudstackTestCase): "Check project name from list response" ) self.debug("Adding %s user to project: %s" % ( - self.user.account.name, + self.user.name, project.name )) # Add user to the project project.addAccount( self.apiclient, - self.user.account.name, - self.user.account.email + self.user.name, + self.user.email ) # listProjectAccount to verify the user is added to project or not accounts_reponse = Project.listAccounts( self.apiclient, projectid=project.id, - account=self.user.account.name, + account=self.user.name, ) self.debug(accounts_reponse) self.assertEqual( @@ -650,8 +650,8 @@ class TestProjectInviteRequiredTrue(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -684,22 +684,22 @@ class TestProjectInviteRequiredTrue(cloudstackTestCase): "Check project name from list response" ) self.debug("Adding %s user to project: %s" % ( - self.user.account.name, + self.user.name, project.name )) # Add user to the project project.addAccount( self.apiclient, - self.user.account.name, - self.user.account.email + self.user.name, + self.user.email ) # listProjectAccount to verify the user is added to project or not accounts_reponse = ProjectInvitation.list( self.apiclient, state='Pending', - account=self.user.account.name, - domainid=self.user.account.domainid + account=self.user.name, + domainid=self.user.domainid ) self.assertEqual( isinstance(accounts_reponse, list), @@ -819,8 +819,8 @@ class TestProjectInviteTimeout(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -853,22 +853,22 @@ class TestProjectInviteTimeout(cloudstackTestCase): "Check project name from list response" ) self.debug("Adding %s user to project: %s" % ( - self.user.account.name, + self.user.name, project.name )) # Add user to the project project.addAccount( self.apiclient, - self.user.account.name, - self.user.account.email + self.user.name, + self.user.email ) # listProjectAccount to verify the user is added to project or not accounts_reponse = ProjectInvitation.list( self.apiclient, state='Pending', - account=self.user.account.name, - domainid=self.user.account.domainid + account=self.user.name, + domainid=self.user.domainid ) self.assertEqual( isinstance(accounts_reponse, list), @@ -894,18 +894,18 @@ class TestProjectInviteTimeout(cloudstackTestCase): self.apiclient, projectid=project.id, accept=True, - account=self.user.account.name + account=self.user.name ) self.debug( "Accepting project invitation for project: %s user: %s" % ( project.name, - self.user.account.name + self.user.name )) # listProjectAccount to verify the user is added to project or not accounts_reponse = Project.listAccounts( self.apiclient, projectid=project.id, - account=self.user.account.name, + account=self.user.name, ) self.assertEqual( @@ -945,8 +945,8 @@ class TestProjectInviteTimeout(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -979,22 +979,22 @@ class TestProjectInviteTimeout(cloudstackTestCase): "Check project name from list response" ) self.debug("Adding %s user to project: %s" % ( - self.user.account.name, + self.user.name, project.name )) # Add user to the project project.addAccount( self.apiclient, - self.user.account.name, - self.user.account.email + self.user.name, + self.user.email ) # listProjectAccount to verify the user is added to project or not accounts_reponse = ProjectInvitation.list( self.apiclient, state='Pending', - account=self.user.account.name, - domainid=self.user.account.domainid + account=self.user.name, + domainid=self.user.domainid ) self.assertEqual( isinstance(accounts_reponse, list), @@ -1025,18 +1025,18 @@ class TestProjectInviteTimeout(cloudstackTestCase): self.apiclient, projectid=project.id, accept=True, - account=self.user.account.name + account=self.user.name ) self.debug( "Accepting invitation after expiry project: %s user: %s" % ( project.name, - self.user.account.name + self.user.name )) # listProjectAccount to verify the user is added to project or not accounts_reponse = ProjectInvitation.list( self.apiclient, - account=self.user.account.name, - domainid=self.user.account.domainid + account=self.user.name, + domainid=self.user.domainid ) self.assertEqual( @@ -1076,8 +1076,8 @@ class TestProjectInviteTimeout(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -1110,22 +1110,22 @@ class TestProjectInviteTimeout(cloudstackTestCase): "Check project name from list response" ) self.debug("Adding %s user to project: %s" % ( - self.user.account.name, + self.user.name, project.name )) # Add user to the project project.addAccount( self.apiclient, - self.user.account.name, - self.user.account.email + self.user.name, + self.user.email ) # listProjectAccount to verify the user is added to project or not accounts_reponse = ProjectInvitation.list( self.apiclient, state='Pending', - account=self.user.account.name, - domainid=self.user.account.domainid + account=self.user.name, + domainid=self.user.domainid ) self.assertEqual( isinstance(accounts_reponse, list), @@ -1151,22 +1151,22 @@ class TestProjectInviteTimeout(cloudstackTestCase): time.sleep(int(self.config.value) * 2) self.debug("Adding %s user again to project: %s" % ( - self.user.account.name, + self.user.name, project.name )) # Add user to the project project.addAccount( self.apiclient, - self.user.account.name, - self.user.account.email + self.user.name, + self.user.email ) # listProjectAccount to verify the user is added to project or not accounts_reponse = ProjectInvitation.list( self.apiclient, state='Pending', - account=self.user.account.name, - domainid=self.user.account.domainid + account=self.user.name, + domainid=self.user.domainid ) self.assertEqual( isinstance(accounts_reponse, list), @@ -1205,8 +1205,8 @@ class TestProjectInviteTimeout(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -1239,22 +1239,22 @@ class TestProjectInviteTimeout(cloudstackTestCase): "Check project name from list response" ) self.debug("Adding %s user to project: %s" % ( - self.user.account.name, + self.user.name, project.name )) # Add user to the project project.addAccount( self.apiclient, - self.user.account.name, - self.user.account.email + self.user.name, + self.user.email ) # listProjectAccount to verify the user is added to project or not accounts_reponse = ProjectInvitation.list( self.apiclient, state='Pending', - account=self.user.account.name, - domainid=self.user.account.domainid + account=self.user.name, + domainid=self.user.domainid ) self.assertEqual( isinstance(accounts_reponse, list), @@ -1279,18 +1279,18 @@ class TestProjectInviteTimeout(cloudstackTestCase): self.apiclient, projectid=project.id, accept=False, - account=self.user.account.name + account=self.user.name ) self.debug( "Declining invitation for project: %s user: %s" % ( project.name, - self.user.account.name + self.user.name )) # listProjectAccount to verify the user is added to project or not accounts_reponse = Project.listAccounts( self.apiclient, projectid=project.id, - account=self.user.account.name, + account=self.user.name, ) self.assertEqual( accounts_reponse, @@ -1333,8 +1333,8 @@ class TestProjectInviteTimeout(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -1367,19 +1367,19 @@ class TestProjectInviteTimeout(cloudstackTestCase): "Check project name from list response" ) self.debug("Adding user with email: %s to project: %s" % ( - self.user.account.email, + self.user.email, project.name )) # Add user to the project project.addAccount( self.apiclient, - email=self.user.account.user[0].email + email=self.user.user[0].email ) # Fetch the latest mail sent to user mail_content = fetch_latest_mail( self.services["mail_account"], - from_mail=self.user.account.user[0].email + from_mail=self.user.user[0].email ) return diff --git a/test/integration/component/test_project_limits.py b/test/integration/component/test_project_limits.py index ab13238e187..17ddfc67da5 100644 --- a/test/integration/component/test_project_limits.py +++ b/test/integration/component/test_project_limits.py @@ -63,7 +63,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "disk_offering": { "displaytext": "Tiny Disk Offering", @@ -429,14 +429,14 @@ class TestProjectLimits(cloudstackTestCase): ) self.debug("Adding %s user to project: %s" % ( - self.user.account.name, + self.user.name, project.name )) # Add user to the project project.addAccount( self.apiclient, - self.user.account.name, + self.user.name, ) # Get the resource limits for domain @@ -459,14 +459,14 @@ class TestProjectLimits(cloudstackTestCase): #with self.assertRaises(Exception): self.debug( "Attempting to update resource limit by user: %s" % ( - self.user.account.name + self.user.name )) # Update project resource limits to 3 update_resource_limit( self.apiclient, resource.resourcetype, - account=self.user.account.name, - domainid=self.user.account.domainid, + account=self.user.name, + domainid=self.user.domainid, max=3, projectid=project.id ) @@ -505,10 +505,10 @@ class TestResourceLimitsProject(cloudstackTestCase): cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name # Create Service offering and disk offerings etc cls.service_offering = ServiceOffering.create( @@ -720,7 +720,7 @@ class TestResourceLimitsProject(cloudstackTestCase): projectid=self.project.id ) - self.debug("Deploying VM for account: %s" % self.account.account.name) + self.debug("Deploying VM for account: %s" % self.account.name) virtual_machine_1 = VirtualMachine.create( self.apiclient, self.services["server"], @@ -843,7 +843,7 @@ class TestResourceLimitsProject(cloudstackTestCase): ) self.debug( "Updating template resource limits for domain: %s" % - self.account.account.domainid) + self.account.domainid) # Set usage_vm=1 for Account 1 update_resource_limit( self.apiclient, @@ -852,7 +852,7 @@ class TestResourceLimitsProject(cloudstackTestCase): projectid=self.project.id ) - self.debug("Deploying VM for account: %s" % self.account.account.name) + self.debug("Deploying VM for account: %s" % self.account.name) virtual_machine_1 = VirtualMachine.create( self.apiclient, self.services["server"], @@ -994,13 +994,13 @@ class TestMaxProjectNetworks(cloudstackTestCase): # 3. Create network should fail self.debug("Creating project with '%s' as admin" % - self.account.account.name) + self.account.name) # Create project as a domain admin project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) diff --git a/test/integration/component/test_project_resources.py b/test/integration/component/test_project_resources.py index 191ceb54cb6..84141889f3f 100644 --- a/test/integration/component/test_project_resources.py +++ b/test/integration/component/test_project_resources.py @@ -64,7 +64,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "disk_offering": { "displaytext": "Tiny Disk Offering", @@ -220,8 +220,8 @@ class TestOfferings(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -263,8 +263,8 @@ class TestOfferings(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -400,8 +400,8 @@ class TestNetwork(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -546,10 +546,10 @@ class TestTemplates(cloudstackTestCase): cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name # Create Service offering and disk offerings etc cls.service_offering = ServiceOffering.create( @@ -771,10 +771,10 @@ class TestSnapshots(cloudstackTestCase): cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name # Create Service offering and disk offerings etc cls.service_offering = ServiceOffering.create( @@ -872,8 +872,8 @@ class TestSnapshots(cloudstackTestCase): snapshots = Snapshot.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( snapshots, @@ -918,10 +918,10 @@ class TestPublicIpAddress(cloudstackTestCase): cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name # Create Service offering and disk offerings etc cls.service_offering = ServiceOffering.create( @@ -1037,7 +1037,7 @@ class TestPublicIpAddress(cloudstackTestCase): #Create Load Balancer rule and assign VMs to rule self.debug("Created LB rule for public IP: %s" % - public_ip.ipaddress.ipaddress) + public_ip.ipaddress) lb_rule = LoadBalancerRule.create( self.apiclient, self.services["lbrule"], @@ -1112,13 +1112,13 @@ class TestPublicIpAddress(cloudstackTestCase): "Check end port of firewall rule" ) - self.debug("Deploying VM for account: %s" % self.account.account.name) + self.debug("Deploying VM for account: %s" % self.account.name) virtual_machine_1 = VirtualMachine.create( self.apiclient, self.services["server"], templateid=self.template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, ) self.cleanup.append(virtual_machine_1) @@ -1142,17 +1142,17 @@ class TestPublicIpAddress(cloudstackTestCase): ) self.debug("Creating LB rule for public IP: %s outside project" % - public_ip.ipaddress.ipaddress) + public_ip.ipaddress) with self.assertRaises(Exception): LoadBalancerRule.create( self.apiclient, self.services["lbrule"], public_ip.ipaddress.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug( "Creating firewall rule for public IP: %s outside project" % - public_ip.ipaddress.ipaddress) + public_ip.ipaddress) with self.assertRaises(Exception): FireWallRule.create( self.apiclient, @@ -1219,10 +1219,10 @@ class TestSecurityGroup(cloudstackTestCase): cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.project, @@ -1317,8 +1317,8 @@ class TestSecurityGroup(cloudstackTestCase): self.apiclient, self.services["server"], serviceofferingid=self.service_offering.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, securitygroupids=[security_group.id], ) return diff --git a/test/integration/component/test_project_usage.py b/test/integration/component/test_project_usage.py index 03c42fd196f..ab789e1c13d 100644 --- a/test/integration/component/test_project_usage.py +++ b/test/integration/component/test_project_usage.py @@ -52,7 +52,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "disk_offering": { "displaytext": "Small", @@ -142,13 +142,13 @@ class TestVmUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls.service_offering = ServiceOffering.create( @@ -337,13 +337,13 @@ class TestPublicIPUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls.service_offering = ServiceOffering.create( @@ -416,7 +416,7 @@ class TestPublicIPUsage(cloudstackTestCase): # 3. Delete the newly created account self.debug("Deleting public IP: %s" % - self.public_ip.ipaddress.ipaddress) + self.public_ip.ipaddress) # Release one of the IP self.public_ip.delete(self.apiclient) @@ -512,13 +512,13 @@ class TestVolumeUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls.service_offering = ServiceOffering.create( @@ -689,13 +689,13 @@ class TestTemplateUsage(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls.service_offering = ServiceOffering.create( @@ -858,12 +858,12 @@ class TestISOUsage(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls.iso = Iso.create( @@ -1014,13 +1014,13 @@ class TestLBRuleUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls.service_offering = ServiceOffering.create( @@ -1198,13 +1198,13 @@ class TestSnapshotUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls.service_offering = ServiceOffering.create( @@ -1375,13 +1375,13 @@ class TestNatRuleUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls.service_offering = ServiceOffering.create( @@ -1559,13 +1559,13 @@ class TestVpnUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls.service_offering = ServiceOffering.create( @@ -1648,7 +1648,7 @@ class TestVpnUsage(cloudstackTestCase): ) self.debug("Created VPN user for account: %s" % - self.account.account.name) + self.account.name) vpnuser = VpnUser.create( self.apiclient, diff --git a/test/integration/component/test_projects.py b/test/integration/component/test_projects.py index 95df5bf8c30..f013e99a0dd 100644 --- a/test/integration/component/test_projects.py +++ b/test/integration/component/test_projects.py @@ -78,7 +78,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "virtual_machine": { "displayname": "Test VM", @@ -183,8 +183,8 @@ class TestMultipleProjectCreation(cloudstackTestCase): project_1 = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project_1) @@ -218,8 +218,8 @@ class TestMultipleProjectCreation(cloudstackTestCase): project_2 = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project_2) @@ -248,15 +248,15 @@ class TestMultipleProjectCreation(cloudstackTestCase): # Add user to the project project_1.addAccount( self.apiclient, - self.user.account.name, - self.user.account.email + self.user.name, + self.user.email ) # listProjectAccount to verify the user is added to project or not accounts_reponse = Project.listAccounts( self.apiclient, projectid=project_1.id, - account=self.user.account.name, + account=self.user.name, ) self.debug(accounts_reponse) self.assertEqual( @@ -280,15 +280,15 @@ class TestMultipleProjectCreation(cloudstackTestCase): # Add user to the project project_2.addAccount( self.apiclient, - self.user.account.name, - self.user.account.email + self.user.name, + self.user.email ) # listProjectAccount to verify the user is added to project or not accounts_reponse = Project.listAccounts( self.apiclient, projectid=project_2.id, - account=self.user.account.name, + account=self.user.name, ) self.debug(accounts_reponse) self.assertEqual( @@ -398,8 +398,8 @@ class TestCrossDomainAccountAdd(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -432,15 +432,15 @@ class TestCrossDomainAccountAdd(cloudstackTestCase): ) self.debug("Adding user: %s from domain: %s to project: %s" % ( - self.user.account.name, - self.user.account.domainid, + self.user.name, + self.user.domainid, project.id )) with self.assertRaises(Exception): # Add user to the project from different domain project.addAccount( self.apiclient, - self.user.account.name + self.user.name ) self.debug("User add to project failed!") return @@ -519,8 +519,8 @@ class TestDeleteAccountWithProject(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -555,7 +555,7 @@ class TestDeleteAccountWithProject(cloudstackTestCase): with self.assertRaises(Exception): self.account.delete(self.apiclient) self.debug("Deleting account %s failed!" % - self.account.account.name) + self.account.name) return @@ -635,8 +635,8 @@ class TestDeleteDomainWithProject(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.debug("Created project with domain admin with ID: %s" % @@ -938,7 +938,7 @@ class TestProjectOwners(cloudstackTestCase): ) self.cleanup.append(self.user) self.debug("Created account with ID: %s" % - self.user.account.name) + self.user.name) list_projects_reponse = Project.list( self.apiclient, @@ -1033,20 +1033,20 @@ class TestProjectOwners(cloudstackTestCase): ) self.debug("Adding %s user to project: %s" % ( - self.user.account.name, + self.user.name, project.name )) # Add user to the project project.addAccount( self.apiclient, - self.user.account.name, + self.user.name, ) # listProjectAccount to verify the user is added to project or not accounts_reponse = Project.listAccounts( self.apiclient, projectid=project.id, - account=self.user.account.name, + account=self.user.name, ) self.assertEqual( isinstance(accounts_reponse, list), @@ -1068,19 +1068,19 @@ class TestProjectOwners(cloudstackTestCase): ) self.debug("Updating project with new Admin: %s" % - self.user.account.name) + self.user.name) # Update the project with new admin project.update( self.apiclient, - account=self.user.account.name + account=self.user.name ) # listProjectAccount to verify the user is new admin of the project accounts_reponse = Project.listAccounts( self.apiclient, projectid=project.id, - account=self.user.account.name, + account=self.user.name, ) self.debug(accounts_reponse) self.assertEqual( @@ -1215,8 +1215,8 @@ class TestProjectResources(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.cleanup.append(project) @@ -1248,20 +1248,20 @@ class TestProjectResources(cloudstackTestCase): "Check project name from list response" ) self.debug("Adding %s user to project: %s" % ( - self.user.account.name, + self.user.name, project.name )) # Add user to the project project.addAccount( self.apiclient, - self.user.account.name, + self.user.name, ) # listProjectAccount to verify the user is added to project or not accounts_reponse = Project.listAccounts( self.apiclient, projectid=project.id, - account=self.user.account.name, + account=self.user.name, ) self.assertEqual( isinstance(accounts_reponse, list), @@ -1331,8 +1331,8 @@ class TestProjectResources(cloudstackTestCase): project = Project.create( self.apiclient, self.services["project"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Cleanup created project at end of test self.debug("Created project with domain admin with ID: %s" % @@ -1370,20 +1370,20 @@ class TestProjectResources(cloudstackTestCase): ) self.cleanup.append(self.user) self.debug("Adding %s user to project: %s" % ( - self.user.account.name, + self.user.name, project.name )) # Add user to the project project.addAccount( self.apiclient, - self.user.account.name + self.user.name ) # listProjectAccount to verify the user is added to project or not accounts_reponse = Project.listAccounts( self.apiclient, projectid=project.id, - account=self.user.account.name, + account=self.user.name, ) self.assertEqual( isinstance(accounts_reponse, list), @@ -1496,8 +1496,8 @@ class TestProjectSuspendActivate(cloudstackTestCase): cls.project = Project.create( cls.api_client, cls.services["project"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls.services["virtual_machine"]["zoneid"] = cls.zone.id cls._cleanup = [ @@ -1543,20 +1543,20 @@ class TestProjectSuspendActivate(cloudstackTestCase): # account deletion. self.debug("Adding %s user to project: %s" % ( - self.user.account.name, + self.user.name, self.project.name )) # Add user to the project self.project.addAccount( self.apiclient, - self.user.account.name, + self.user.name, ) # listProjectAccount to verify the user is added to project or not accounts_reponse = Project.listAccounts( self.apiclient, projectid=self.project.id, - account=self.user.account.name, + account=self.user.name, ) self.assertEqual( isinstance(accounts_reponse, list), diff --git a/test/integration/component/test_regions.py b/test/integration/component/test_regions.py new file mode 100644 index 00000000000..daf16cd1f44 --- /dev/null +++ b/test/integration/component/test_regions.py @@ -0,0 +1,140 @@ +#!/usr/bin/env python +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +from marvin.cloudstackTestCase import * +from marvin.cloudstackAPI import * +from marvin.integration.lib.utils import * +from marvin.integration.lib.base import * +from marvin.integration.lib.common import * +from nose.plugins.attrib import attr +from random import choice + +class Services: + def __init__(self): + self.services = { + "region": { + "regionid": "2", + "regionname": "Region2", + "regionendpoint": "http://region2:8080/client" + } + } + +class TestRegions(cloudstackTestCase): + """Test Regions - CRUD tests for regions + """ + + @classmethod + def setUpClass(cls): + cls.api_client = super(TestRegions, cls).getClsTestClient().getApiClient() + cls.services = Services().services + cls.domain = get_domain(cls.api_client, cls.services) + cls.cleanup = [] + return + + def setUp(self): + pseudo_random_int = choice(xrange(1, 200)) + self.services["region"]["regionid"] = pseudo_random_int + self.services["region"]["regionname"] = "region" + str(pseudo_random_int) + self.services["region"]["regionendpoint"] = "http://region" + str(pseudo_random_int) + ":8080/client" + + self.region = Region.create(self.api_client, + self.services["region"] + ) + self.cleanup = [] + self.cleanup.append(self.region) + + list_region = Region.list(self.api_client, + id=self.services["region"]["regionid"] + ) + + self.assertEqual( + isinstance(list_region, list), + True, + msg="Region creation failed" + ) + + @attr(tags=["simulator", "basic", "advanced"]) + def test_createRegionWithExistingRegionId(self): + """Test for duplicate checks on region id + """ + self.services["region"]["regionname"] = random_gen() #alter region name but not id + self.assertRaises(Exception, Region.create, self.api_client, self.services["region"]) + + @attr(tags=["simulator", "basic", "advanced"]) + def test_createRegionWithExistingRegionName(self): + """Test for duplicate checks on region name + """ + random_int = choice(xrange(1, 200)) + self.services["region"]["regionid"] = random_int #alter id but not name + self.services["region"]["regionendpoint"] = "http://region" + str(random_int) + ":8080/client" + self.assertRaises(Exception, Region.create, self.api_client, self.services["region"]) + + @attr(tags=["simulator", "basic", "advanced"]) + def test_updateRegion(self): + """ Test for update Region + """ + self.services["region"]["regionname"] = "Region3" + random_gen() + self.services["region"]["regionendpoint"] = "http://region3updated:8080/client" + + updated_region = self.region.update(self.api_client, + self.services["region"] + ) + + list_region = Region.list(self.api_client, + id=self.services["region"]["regionid"] + ) + + self.assertEqual( + isinstance(list_region, list), + True, + "Check for list Region response" + ) + region_response = list_region[0] + + self.assertEqual( + region_response.id, + updated_region.id, + "listRegion response does not match with region Id created" + ) + + self.assertEqual( + region_response.name, + updated_region.name, + "listRegion response does not match with region name created" + ) + self.assertEqual( + region_response.endpoint, + updated_region.endpoint, + "listRegion response does not match with region endpoint created" + ) + + def tearDown(self): + """ Test for delete region as cleanup + """ + try: + #Clean up + cleanup_resources(self.api_client, self.cleanup) + except Exception as e: + raise Exception("Warning: Exception during cleanup : %s" % e) + + @classmethod + def tearDownClass(cls): + """ + Nothing to do + """ + pass diff --git a/test/integration/component/test_regions_accounts.py b/test/integration/component/test_regions_accounts.py new file mode 100644 index 00000000000..113f725f598 --- /dev/null +++ b/test/integration/component/test_regions_accounts.py @@ -0,0 +1,206 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +from marvin.cloudstackTestCase import * +from marvin.cloudstackAPI import * +from marvin.integration.lib.utils import * +from marvin.integration.lib.base import * +from marvin.integration.lib.common import * +from nose.plugins.attrib import attr + +class Services: + def __init__(self): + self.services = { + "domain": { + "name": "testuuid", + "domainUUID": "domain1" + }, + "account": { + "email": "test@test.com", + "firstname": "Testuuid", + "lastname": "Useruuid", + "username": "test", + "password": "password", + "accountUUID": "account1", + "userUUID": "user1" + }, + "user": { + "email": "test@test.com", + "firstname": "Testuuid", + "lastname": "Useruuid", + "username": "test", + "password": "password", + "userUUID": "user2" + }, + } + + +class TestRegionsAccounts(cloudstackTestCase): + """Test Accounts in Regions - CRUD tests for accounts in regions + """ + + @classmethod + def setUpClass(cls): + cls.api_client = super(TestRegionsAccounts, cls).getClsTestClient().getApiClient() + cls.services = Services().services + cls.domain = get_domain(cls.api_client, cls.services) + cls.cleanup = [] + return + + @attr(tags=["simulator", "basic", "advanced"]) + def test_createAccountWithUUID(self): + """Test for creating account by passing id parameter + + # Validate the following + # 1.Create an Account by passing id parameter.Verify the account is created. + # 2.List this account by passing id parameter.Verify that list account is able to lis this account. + # 3.Delete account should succeed. + """ + account = Account.create( + self.api_client, + self.services["account"], + domainid=self.domain.id + ) + self.assertIn(self.services["account"]["accountUUID"], account.id, + "Account is not created with the accountId passed") + + list_account = Account.list(self.api_client, + id=account.id) + + self.assertEqual( + isinstance(list_account, list), + True, + "Check for list account response by uuid failed" + ) + + account_response = list_account[0] + self.assertEqual(account_response.id, + account.id, + "listAccount response does not match with account Id " + ) + self.assertEqual( + account_response.user[0].firstname, + self.services["account"]["firstname"], + "listAccount response does not match with account firstname" + ) + + self.cleanup.append(account) + return + + @attr(tags=["simulator", "basic", "advanced"]) + def test_createUserWithUUID(self): + """Test for creating User by passing id parameter + + # Validate the following + # 1.Create a User by passing id parameter.Verify the user is created. + # 2.List this user by passing id parameter.Verify that list user is able to list this user. + # 3.Delete User should succeed. + """ + + user = User.create( + self.api_client, + self.services["user"], + account="admin", + domainid=self.domain.id + ) + self.assertIn(self.services["user"]["userUUID"], user.id, + "User is not created successfully with the userId passed") + + list_user = User.list(self.api_client, id=user.id) + + self.assertEqual( + isinstance(list_user, list), + True, + "Check for list user response by uuid failed" + ) + + user_response = list_user[0] + + self.assertEqual(user_response.id, + user.id, + "list User response does not match with user Id " + ) + self.assertEqual( + user_response.firstname, + self.services["user"]["firstname"], + "listUser response does not match with user firstname" + ) + + user.delete(self.api_client) + + list_user = User.list(self.api_client, + id=user.id + ) + + self.assertIsNone( + list_user, + "Deletion of user failed" + ) + return + + @attr(tags=["simulator", "basic", "advanced"]) + def test_createdomainWithUUID(self): + """Test for creating Domain by passing id parameter + + # Validate the following + # 1.Create a domain by passing id parameter.Verify the domain is created. + # 2.List this domain by passing id parameter.Verify that list domain is able to list this domain. + # 3.Delete domain should succeed. + """ + + domain = Domain.create( + self.api_client, + self.services["domain"] + ) + + self.assertIn(self.services["domain"]["domainUUID"], domain.id, + "Domain is not created with the doaminId passed") + + list_domain = Domain.list(self.api_client, + id=domain.id + ) + + self.assertEqual( + isinstance(list_domain, list), + True, + "Check for list domain response by uuid failed" + ) + + domain_response = list_domain[0] + + self.assertEqual(domain_response.id, + domain.id, + "list domain response does not match with domain Id " + ) + self.assertIn( + self.services["domain"]["name"], + domain_response.name, + "list domaiin response does not match with user firstname" + ) + try: + domain.delete(self.api_client) + except Exception as e: + self.fail("Failed to delete domain: %s" % e) + return + + @classmethod + def tearDownClass(cls): + try: + #Clean up + cleanup_resources(cls.api_client, cls.cleanup) + except Exception as e: + raise Exception("Warning: Exception during cleanup : %s" % e) \ No newline at end of file diff --git a/test/integration/component/test_resource_limits.py b/test/integration/component/test_resource_limits.py index 641825b4a0c..1d876b6195f 100644 --- a/test/integration/component/test_resource_limits.py +++ b/test/integration/component/test_resource_limits.py @@ -51,7 +51,7 @@ class Services: "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, + "memory": 128, # In MBs }, "disk_offering": { @@ -902,7 +902,7 @@ class TestResourceLimitsDomain(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name # Create Service offering and disk offerings etc cls.service_offering = ServiceOffering.create( @@ -957,22 +957,22 @@ class TestResourceLimitsDomain(cloudstackTestCase): self.debug( "Updating instance resource limits for domain: %s" % - self.account.account.domainid) + self.account.domainid) # Set usage_vm=1 for Account 1 update_resource_limit( self.apiclient, 0, # Instance - domainid=self.account.account.domainid, + domainid=self.account.domainid, max=2 ) - self.debug("Deploying VM for account: %s" % self.account.account.name) + self.debug("Deploying VM for account: %s" % self.account.name) virtual_machine_1 = VirtualMachine.create( self.apiclient, self.services["server"], templateid=self.template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.cleanup.append(virtual_machine_1) @@ -982,13 +982,13 @@ class TestResourceLimitsDomain(cloudstackTestCase): 'Running', "Check VM state is Running or not" ) - self.debug("Deploying VM for account: %s" % self.account.account.name) + self.debug("Deploying VM for account: %s" % self.account.name) virtual_machine_2 = VirtualMachine.create( self.apiclient, self.services["server"], templateid=self.template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.cleanup.append(virtual_machine_2) @@ -1005,7 +1005,7 @@ class TestResourceLimitsDomain(cloudstackTestCase): self.services["server"], templateid=self.template.id, accountid=self.account_1.account.name, - domainid=self.account.account.domainid, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) return @@ -1025,22 +1025,22 @@ class TestResourceLimitsDomain(cloudstackTestCase): self.debug( "Updating public IP resource limits for domain: %s" % - self.account.account.domainid) + self.account.domainid) # Set usage_vm=1 for Account 1 update_resource_limit( self.apiclient, 1, # Public Ip - domainid=self.account.account.domainid, + domainid=self.account.domainid, max=2 ) - self.debug("Deploying VM for account: %s" % self.account.account.name) + self.debug("Deploying VM for account: %s" % self.account.name) virtual_machine_1 = VirtualMachine.create( self.apiclient, self.services["server"], templateid=self.template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.cleanup.append(virtual_machine_1) @@ -1050,7 +1050,7 @@ class TestResourceLimitsDomain(cloudstackTestCase): 'Running', "Check VM state is Running or not" ) - self.debug("Associating public IP for account: %s" % self.account.account.name) + self.debug("Associating public IP for account: %s" % self.account.name) public_ip_1 = PublicIPAddress.create( self.apiclient, virtual_machine_1.account, @@ -1097,22 +1097,22 @@ class TestResourceLimitsDomain(cloudstackTestCase): self.debug( "Updating snapshot resource limits for domain: %s" % - self.account.account.domainid) + self.account.domainid) # Set usage_vm=1 for Account 1 update_resource_limit( self.apiclient, 3, # Snapshot - domainid=self.account.account.domainid, + domainid=self.account.domainid, max=1 ) - self.debug("Deploying VM for account: %s" % self.account.account.name) + self.debug("Deploying VM for account: %s" % self.account.name) virtual_machine_1 = VirtualMachine.create( self.apiclient, self.services["server"], templateid=self.template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.cleanup.append(virtual_machine_1) @@ -1141,8 +1141,8 @@ class TestResourceLimitsDomain(cloudstackTestCase): # Create a snapshot from the ROOTDISK snapshot_1 = Snapshot.create(self.apiclient, volumes[0].id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.cleanup.append(snapshot_1) # Verify Snapshot state @@ -1159,8 +1159,8 @@ class TestResourceLimitsDomain(cloudstackTestCase): with self.assertRaises(Exception): Snapshot.create(self.apiclient, volumes[0].id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) return @@ -1179,22 +1179,22 @@ class TestResourceLimitsDomain(cloudstackTestCase): self.debug( "Updating volume resource limits for domain: %s" % - self.account.account.domainid) + self.account.domainid) # Set usage_vm=1 for Account 1 update_resource_limit( self.apiclient, 2, # Volume - domainid=self.account.account.domainid, + domainid=self.account.domainid, max=2 ) - self.debug("Deploying VM for account: %s" % self.account.account.name) + self.debug("Deploying VM for account: %s" % self.account.name) virtual_machine_1 = VirtualMachine.create( self.apiclient, self.services["server"], templateid=self.template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.cleanup.append(virtual_machine_1) @@ -1211,8 +1211,8 @@ class TestResourceLimitsDomain(cloudstackTestCase): self.apiclient, self.services["volume"], zoneid=self.zone.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, diskofferingid=self.disk_offering.id ) return @@ -1234,28 +1234,28 @@ class TestResourceLimitsDomain(cloudstackTestCase): update_resource_limit( self.apiclient, 2, # Volume - domainid=self.account.account.domainid, + domainid=self.account.domainid, max=5 ) self.debug( "Updating template resource limits for domain: %s" % - self.account.account.domainid) + self.account.domainid) # Set usage_vm=1 for Account 1 update_resource_limit( self.apiclient, 4, # Template - domainid=self.account.account.domainid, + domainid=self.account.domainid, max=2 ) - self.debug("Deploying VM for account: %s" % self.account.account.name) + self.debug("Deploying VM for account: %s" % self.account.name) virtual_machine_1 = VirtualMachine.create( self.apiclient, self.services["server"], templateid=self.template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.cleanup.append(virtual_machine_1) @@ -1286,8 +1286,8 @@ class TestResourceLimitsDomain(cloudstackTestCase): self.apiclient, self.services["template"], volumeid=volume.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.cleanup.append(template_1) @@ -1303,8 +1303,8 @@ class TestResourceLimitsDomain(cloudstackTestCase): self.apiclient, self.services["template"], volumeid=volume.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.cleanup.append(template_2) @@ -1321,8 +1321,8 @@ class TestResourceLimitsDomain(cloudstackTestCase): self.apiclient, self.services["template"], volumeid=volume.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) return @@ -1432,8 +1432,8 @@ class TestMaxAccountNetworks(cloudstackTestCase): network = Network.create( self.apiclient, self.services["network"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, networkofferingid=self.network_offering.id, zoneid=self.zone.id ) @@ -1446,8 +1446,8 @@ class TestMaxAccountNetworks(cloudstackTestCase): Network.create( self.apiclient, self.services["network"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, networkofferingid=self.network_offering.id, zoneid=self.zone.id ) diff --git a/test/integration/component/test_routers.py b/test/integration/component/test_routers.py index 452c034d5eb..bc33d754260 100644 --- a/test/integration/component/test_routers.py +++ b/test/integration/component/test_routers.py @@ -41,7 +41,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "virtual_machine": { @@ -127,16 +127,16 @@ class TestRouterServices(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=cls.template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.vm_2 = VirtualMachine.create( cls.api_client, cls.services["virtual_machine"], templateid=cls.template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.cleanup = [ @@ -189,8 +189,8 @@ class TestRouterServices(cloudstackTestCase): routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( @@ -216,8 +216,8 @@ class TestRouterServices(cloudstackTestCase): # Network state associated with account should be 'Implemented' networks = list_networks( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( isinstance(networks, list), @@ -243,8 +243,8 @@ class TestRouterServices(cloudstackTestCase): # VM state associated with account should be 'Running' virtual_machines = list_virtual_machines( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -271,8 +271,8 @@ class TestRouterServices(cloudstackTestCase): # Check status of DNS, DHCP, FIrewall, LB VPN processes networks = list_networks( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( isinstance(networks, list), @@ -332,8 +332,8 @@ class TestRouterServices(cloudstackTestCase): routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( @@ -360,8 +360,8 @@ class TestRouterServices(cloudstackTestCase): # Network state associated with account should be 'Implemented' networks = list_networks( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( isinstance(networks, list), @@ -387,8 +387,8 @@ class TestRouterServices(cloudstackTestCase): # VM state associated with account should be 'Running' virtual_machines = list_virtual_machines( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( @@ -445,8 +445,8 @@ class TestRouterServices(cloudstackTestCase): routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( @@ -488,8 +488,8 @@ class TestRouterServices(cloudstackTestCase): self.apiclient, self.services["virtual_machine"], templateid=self.template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.debug("Deployed a VM with ID: %s" % vm.id) @@ -497,8 +497,8 @@ class TestRouterServices(cloudstackTestCase): virtual_machines = list_virtual_machines( self.apiclient, id=vm.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( @@ -522,8 +522,8 @@ class TestRouterServices(cloudstackTestCase): routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( @@ -554,8 +554,8 @@ class TestRouterServices(cloudstackTestCase): virtual_machines = list_virtual_machines( self.apiclient, id=self.vm_1.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( @@ -615,8 +615,8 @@ class TestRouterStopCreatePF(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.cleanup = [ @@ -668,8 +668,8 @@ class TestRouterStopCreatePF(cloudstackTestCase): # Get router details associated for that account routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( @@ -693,8 +693,8 @@ class TestRouterStopCreatePF(cloudstackTestCase): routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( isinstance(routers, list), @@ -711,8 +711,8 @@ class TestRouterStopCreatePF(cloudstackTestCase): public_ips = list_publicIP( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, zoneid=self.zone.id ) self.assertEqual( @@ -749,8 +749,8 @@ class TestRouterStopCreatePF(cloudstackTestCase): routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, zoneid=self.zone.id ) self.assertEqual( @@ -827,8 +827,8 @@ class TestRouterStopCreateLB(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.cleanup = [ @@ -874,8 +874,8 @@ class TestRouterStopCreateLB(cloudstackTestCase): # Get router details associated for that account routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( @@ -900,8 +900,8 @@ class TestRouterStopCreateLB(cloudstackTestCase): routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( isinstance(routers, list), @@ -918,8 +918,8 @@ class TestRouterStopCreateLB(cloudstackTestCase): public_ips = list_publicIP( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(public_ips, list), @@ -943,7 +943,7 @@ class TestRouterStopCreateLB(cloudstackTestCase): self.apiclient, self.services["lbrule"], public_ip.id, - accountid=self.account.account.name + accountid=self.account.name ) self.debug("Assigning VM %s to LB rule: %s" % ( self.vm_1.id, @@ -958,8 +958,8 @@ class TestRouterStopCreateLB(cloudstackTestCase): routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( isinstance(routers, list), @@ -1038,8 +1038,8 @@ class TestRouterStopCreateFW(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.cleanup = [ @@ -1084,8 +1084,8 @@ class TestRouterStopCreateFW(cloudstackTestCase): # Get the router details associated with account routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( @@ -1110,8 +1110,8 @@ class TestRouterStopCreateFW(cloudstackTestCase): routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( isinstance(routers, list), @@ -1128,8 +1128,8 @@ class TestRouterStopCreateFW(cloudstackTestCase): public_ips = list_publicIP( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(public_ips, list), @@ -1157,8 +1157,8 @@ class TestRouterStopCreateFW(cloudstackTestCase): routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.assertEqual( isinstance(routers, list), diff --git a/test/integration/component/test_security_groups.py b/test/integration/component/test_security_groups.py index 7459d2a2913..54b5c67fa4d 100644 --- a/test/integration/component/test_security_groups.py +++ b/test/integration/component/test_security_groups.py @@ -74,7 +74,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "security_group": { "name": 'SSH', @@ -144,7 +144,7 @@ class TestDefaultSecurityGroup(cloudstackTestCase): admin=True, domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, @@ -178,8 +178,8 @@ class TestDefaultSecurityGroup(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.debug("Deployed VM with ID: %s" % self.virtual_machine.id) @@ -222,7 +222,7 @@ class TestDefaultSecurityGroup(cloudstackTestCase): # Verify List Routers response for account self.debug( "Verify list routers response for account: %s" \ - % self.account.account.name + % self.account.name ) routers = list_routers( self.apiclient, @@ -256,8 +256,8 @@ class TestDefaultSecurityGroup(cloudstackTestCase): sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -292,8 +292,8 @@ class TestDefaultSecurityGroup(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.debug("Deployed VM with ID: %s" % self.virtual_machine.id) @@ -336,8 +336,8 @@ class TestDefaultSecurityGroup(cloudstackTestCase): # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -416,7 +416,7 @@ class TestAuthorizeIngressRule(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, cls.service_offering @@ -450,15 +450,15 @@ class TestAuthorizeIngressRule(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -475,8 +475,8 @@ class TestAuthorizeIngressRule(cloudstackTestCase): ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(ingress_rule, dict), @@ -489,12 +489,12 @@ class TestAuthorizeIngressRule(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Should be able to SSH VM try: self.debug("SSH into VM: %s" % self.virtual_machine.id) @@ -552,7 +552,7 @@ class TestRevokeIngressRule(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, cls.service_offering @@ -587,16 +587,16 @@ class TestRevokeIngressRule(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -615,8 +615,8 @@ class TestRevokeIngressRule(cloudstackTestCase): ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -629,12 +629,12 @@ class TestRevokeIngressRule(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Should be able to SSH VM try: @@ -712,12 +712,12 @@ class TestDhcpOnlyRouter(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.virtual_machine = VirtualMachine.create( cls.api_client, cls.services["virtual_machine"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls._cleanup = [ @@ -849,7 +849,7 @@ class TestdeployVMWithUserData(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, cls.service_offering @@ -897,15 +897,15 @@ class TestdeployVMWithUserData(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -922,15 +922,15 @@ class TestdeployVMWithUserData(cloudstackTestCase): "Authorize Ingress Rule for Security Group %s for account: %s" \ % ( security_group.id, - self.account.account.name + self.account.name )) # Authorize Security group to SSH to VM ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(ingress_rule, dict), @@ -940,12 +940,12 @@ class TestdeployVMWithUserData(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Should be able to SSH VM try: self.debug( @@ -1009,7 +1009,7 @@ class TestDeleteSecurityGroup(cloudstackTestCase): self.services["account"], domainid=self.domain.id ) - self.services["account"] = self.account.account.name + self.services["account"] = self.account.name self.cleanup = [ self.account, self.service_offering @@ -1059,15 +1059,15 @@ class TestDeleteSecurityGroup(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -1084,15 +1084,15 @@ class TestDeleteSecurityGroup(cloudstackTestCase): "Authorize Ingress Rule for Security Group %s for account: %s" \ % ( security_group.id, - self.account.account.name + self.account.name )) # Authorize Security group to SSH to VM ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(ingress_rule, dict), @@ -1103,12 +1103,12 @@ class TestDeleteSecurityGroup(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Deleting Security group should raise exception security_group.delete(self.apiclient) @@ -1143,15 +1143,15 @@ class TestDeleteSecurityGroup(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -1168,14 +1168,14 @@ class TestDeleteSecurityGroup(cloudstackTestCase): "Authorize Ingress Rule for Security Group %s for account: %s" \ % ( security_group.id, - self.account.account.name + self.account.name )) # Authorize Security group to SSH to VM ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(ingress_rule, dict), @@ -1186,12 +1186,12 @@ class TestDeleteSecurityGroup(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # Destroy the VM self.virtual_machine.delete(self.apiclient) @@ -1255,7 +1255,7 @@ class TestIngressRule(cloudstackTestCase): self.services["account"], domainid=self.domain.id ) - self.services["account"] = self.account.account.name + self.services["account"] = self.account.name self.cleanup = [ self.account, self.service_offering @@ -1305,15 +1305,15 @@ class TestIngressRule(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -1329,15 +1329,15 @@ class TestIngressRule(cloudstackTestCase): "Authorize Ingress Rule for Security Group %s for account: %s" \ % ( security_group.id, - self.account.account.name + self.account.name )) # Authorize Security group to SSH to VM ingress_rule_1 = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(ingress_rule_1, dict), @@ -1347,25 +1347,25 @@ class TestIngressRule(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) self.debug( "Authorize Ingress Rule for Security Group %s for account: %s" \ % ( security_group.id, - self.account.account.name + self.account.name )) # Authorize Security group to SSH to VM ingress_rule_2 = security_group.authorize( self.apiclient, self.services["security_group_2"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(ingress_rule_2, dict), @@ -1421,16 +1421,16 @@ class TestIngressRule(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -1447,15 +1447,15 @@ class TestIngressRule(cloudstackTestCase): "Authorize Ingress Rule for Security Group %s for account: %s" \ % ( security_group.id, - self.account.account.name + self.account.name )) # Authorize Security group to SSH to VM ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(ingress_rule, dict), @@ -1465,26 +1465,26 @@ class TestIngressRule(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) self.debug( "Authorize Ingress Rule for Security Group %s for account: %s" \ % ( security_group.id, - self.account.account.name + self.account.name )) # Authorize Security group to SSH to VM ingress_rule_2 = security_group.authorize( self.apiclient, self.services["security_group_2"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(ingress_rule_2, dict), @@ -1528,7 +1528,7 @@ class TestIngressRule(cloudstackTestCase): "Revoke Ingress Rule for Security Group %s for account: %s" \ % ( security_group.id, - self.account.account.name + self.account.name )) result = security_group.revoke( @@ -1573,15 +1573,15 @@ class TestIngressRule(cloudstackTestCase): security_group = SecurityGroup.create( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created security group with ID: %s" % security_group.id) # Default Security group should not have any ingress rule sercurity_groups = SecurityGroup.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(sercurity_groups, list), @@ -1599,15 +1599,15 @@ class TestIngressRule(cloudstackTestCase): "Authorize Ingress Rule for Security Group %s for account: %s" \ % ( security_group.id, - self.account.account.name + self.account.name )) # Authorize Security group to SSH to VM ingress_rule = security_group.authorize( self.apiclient, self.services["security_group"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(ingress_rule, dict), @@ -1618,12 +1618,12 @@ class TestIngressRule(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["virtual_machine"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, securitygroupids=[security_group.id] ) - self.debug("Deploying VM in account: %s" % self.account.account.name) + self.debug("Deploying VM in account: %s" % self.account.name) # SSH should be allowed on 22 port try: diff --git a/test/integration/component/test_snapshots.py b/test/integration/component/test_snapshots.py index 5567917371e..014b55afcc1 100644 --- a/test/integration/component/test_snapshots.py +++ b/test/integration/component/test_snapshots.py @@ -152,7 +152,7 @@ class TestSnapshotRootDisk(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -163,8 +163,8 @@ class TestSnapshotRootDisk(cloudstackTestCase): cls.api_client, cls.services["server_without_disk"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, mode=cls.services["mode"] ) @@ -220,8 +220,8 @@ class TestSnapshotRootDisk(cloudstackTestCase): snapshot = Snapshot.create( self.apiclient, volumes[0].id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Snapshot created: ID - %s" % snapshot.id) @@ -384,7 +384,7 @@ class TestSnapshots(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -395,8 +395,8 @@ class TestSnapshots(cloudstackTestCase): cls.api_client, cls.services["server_with_disk"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, mode=cls.services["mode"] ) @@ -405,8 +405,8 @@ class TestSnapshots(cloudstackTestCase): cls.api_client, cls.services["server_without_disk"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, mode=cls.services["mode"] ) @@ -462,8 +462,8 @@ class TestSnapshots(cloudstackTestCase): snapshot = Snapshot.create( self.apiclient, volume[0].id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) snapshots = list_snapshots( self.apiclient, @@ -663,8 +663,8 @@ class TestSnapshots(cloudstackTestCase): snapshot = Snapshot.create( self.apiclient, volume_response.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created Snapshot from volume: %s" % volume_response.id) @@ -674,8 +674,8 @@ class TestSnapshots(cloudstackTestCase): self.apiclient, snapshot.id, self.services, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) volumes = list_volumes( @@ -789,8 +789,8 @@ class TestSnapshots(cloudstackTestCase): snapshot = Snapshot.create( self.apiclient, volumes[0].id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) snapshot.delete(self.apiclient) @@ -1079,8 +1079,8 @@ class TestSnapshots(cloudstackTestCase): snapshot = Snapshot.create( self.apiclient, volume.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Snapshot created from volume ID: %s" % volume.id) @@ -1118,8 +1118,8 @@ class TestSnapshots(cloudstackTestCase): self.apiclient, self.services["server_without_disk"], templateid=template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, mode=self.services["mode"] ) @@ -1209,7 +1209,7 @@ class TestCreateVMsnapshotTemplate(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -1269,8 +1269,8 @@ class TestCreateVMsnapshotTemplate(cloudstackTestCase): self.apiclient, self.services["server"], templateid=self.template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.debug("Created VM with ID: %s" % self.virtual_machine.id) @@ -1359,8 +1359,8 @@ class TestCreateVMsnapshotTemplate(cloudstackTestCase): self.apiclient, self.services["server"], templateid=template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.debug("Created VM with ID: %s from template: %s" % ( @@ -1373,8 +1373,8 @@ class TestCreateVMsnapshotTemplate(cloudstackTestCase): virtual_machines = list_virtual_machines( self.apiclient, id=new_virtual_machine.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(virtual_machines, list), @@ -1505,7 +1505,7 @@ class TestAccountSnapshotClean(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -1515,8 +1515,8 @@ class TestAccountSnapshotClean(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) # Get the Root disk of VM @@ -1577,7 +1577,7 @@ class TestAccountSnapshotClean(cloudstackTestCase): accounts = list_accounts( self.apiclient, - id=self.account.account.id + id=self.account.id ) self.assertEqual( isinstance(accounts, list), @@ -1737,7 +1737,7 @@ class TestAccountSnapshotClean(cloudstackTestCase): "Check snapshot UUID in secondary storage and database" ) - self.debug("Deleting account: %s" % self.account.account.name) + self.debug("Deleting account: %s" % self.account.name) # Delete account self.account.delete(self.apiclient) @@ -1757,7 +1757,7 @@ class TestAccountSnapshotClean(cloudstackTestCase): accounts = list_accounts( self.apiclient, - id=self.account.account.id + id=self.account.id ) self.assertEqual( @@ -1859,7 +1859,7 @@ class TestSnapshotDetachedDisk(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -1869,8 +1869,8 @@ class TestSnapshotDetachedDisk(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, mode=cls.services["mode"] ) @@ -2142,7 +2142,7 @@ class TestSnapshotLimit(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -2152,8 +2152,8 @@ class TestSnapshotLimit(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls._cleanup = [ @@ -2401,7 +2401,7 @@ class TestSnapshotEvents(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -2411,8 +2411,8 @@ class TestSnapshotEvents(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) @@ -2498,8 +2498,8 @@ class TestSnapshotEvents(cloudstackTestCase): time.sleep(self.services["sleep"]) events = list_events( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, type='SNAPSHOT.DELETE' ) self.assertEqual( diff --git a/test/integration/component/test_storage_motion.py b/test/integration/component/test_storage_motion.py index b893b8b7df4..c05d79e6861 100644 --- a/test/integration/component/test_storage_motion.py +++ b/test/integration/component/test_storage_motion.py @@ -98,16 +98,16 @@ class TestStorageMotion(cloudstackTestCase): # Get Zone, Domain and templates domain = get_domain(cls.api_client, cls.services) - zone = get_zone(cls.api_client, cls.services) + cls.zone = get_zone(cls.api_client, cls.services) cls.services['mode'] = cls.zone.networktype template = get_template( cls.api_client, - zone.id, + cls.zone.id, cls.services["ostype"] ) # Set Zones and disk offerings - cls.services["small"]["zoneid"] = zone.id + cls.services["small"]["zoneid"] = cls.zone.id cls.services["small"]["template"] = template.id # Create VMs, NAT Rules etc @@ -126,8 +126,8 @@ class TestStorageMotion(cloudstackTestCase): cls.virtual_machine = VirtualMachine.create( cls.api_client, cls.services["small"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.small_offering.id, mode=cls.services["mode"] ) @@ -258,6 +258,17 @@ class TestStorageMotion(cloudstackTestCase): self.apiclient, id=volume.id ) + self.assertEqual( + isinstance(pools, list), + True, + "Check list storage pools response for valid list" + ) + self.assertNotEqual( + pools, + None, + "Check if pools exists in ListStoragePools" + ) + pool = pools[0] self.debug("Migrating Volume-ID: %s to Pool: %s" % ( volume.id, diff --git a/test/integration/component/test_templates.py b/test/integration/component/test_templates.py index a743bf7e690..1a60123b820 100644 --- a/test/integration/component/test_templates.py +++ b/test/integration/component/test_templates.py @@ -51,7 +51,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "disk_offering": { "displaytext": "Small", @@ -139,7 +139,7 @@ class TestCreateTemplate(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls._cleanup = [ cls.account, @@ -183,8 +183,8 @@ class TestCreateTemplate(cloudstackTestCase): self.apiclient, v, zoneid=self.zone.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug( "Registered a template of format: %s with ID: %s" % ( @@ -205,8 +205,8 @@ class TestCreateTemplate(cloudstackTestCase): self.services["templatefilter"], id=template.id, zoneid=self.zone.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) if isinstance(list_template_response, list): break @@ -240,8 +240,8 @@ class TestCreateTemplate(cloudstackTestCase): self.apiclient, self.services["virtual_machine"], templateid=template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, mode=self.services["mode"] ) @@ -249,8 +249,8 @@ class TestCreateTemplate(cloudstackTestCase): vm_response = list_virtual_machines( self.apiclient, id=virtual_machine.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(vm_response, list), @@ -304,7 +304,7 @@ class TestTemplates(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, cls.services["service_offering"] @@ -315,8 +315,8 @@ class TestTemplates(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, ) #Stop virtual machine @@ -396,8 +396,8 @@ class TestTemplates(cloudstackTestCase): self.apiclient, self.services["virtual_machine"], templateid=self.template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, ) @@ -406,8 +406,8 @@ class TestTemplates(cloudstackTestCase): vm_response = list_virtual_machines( self.apiclient, id=virtual_machine.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) #Verify VM response to check whether VM deployment was successful self.assertNotEqual( @@ -591,8 +591,8 @@ class TestTemplates(cloudstackTestCase): snapshot = Snapshot.create( self.apiclient, volume.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Creating a template from snapshot: %s" % snapshot.id) # Generate template from the snapshot @@ -626,8 +626,8 @@ class TestTemplates(cloudstackTestCase): self.apiclient, self.services["virtual_machine"], templateid=template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, ) self.cleanup.append(virtual_machine) @@ -635,8 +635,8 @@ class TestTemplates(cloudstackTestCase): vm_response = list_virtual_machines( self.apiclient, id=virtual_machine.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(vm_response, list), diff --git a/test/integration/component/test_usage.py b/test/integration/component/test_usage.py index 39228ba3b7a..a3779e4dc2f 100644 --- a/test/integration/component/test_usage.py +++ b/test/integration/component/test_usage.py @@ -48,7 +48,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "disk_offering": { "displaytext": "Small", @@ -135,7 +135,7 @@ class TestVmUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -145,8 +145,8 @@ class TestVmUsage(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls._cleanup = [ @@ -202,11 +202,11 @@ class TestVmUsage(cloudstackTestCase): # Fetch account ID from account_uuid self.debug("select id from account where uuid = '%s';" \ - % self.account.account.id) + % self.account.id) qresultset = self.dbclient.execute( "select id from account where uuid = '%s';" \ - % self.account.account.id + % self.account.id ) self.assertEqual( isinstance(qresultset, list), @@ -319,7 +319,7 @@ class TestPublicIPUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -329,8 +329,8 @@ class TestPublicIPUsage(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) @@ -382,18 +382,18 @@ class TestPublicIPUsage(cloudstackTestCase): # 3. Delete the newly created account self.debug("Deleting public IP: %s" % - self.public_ip.ipaddress.ipaddress) + self.public_ip.ipaddress) # Release one of the IP self.public_ip.delete(self.apiclient) # Fetch account ID from account_uuid self.debug("select id from account where uuid = '%s';" \ - % self.account.account.id) + % self.account.id) qresultset = self.dbclient.execute( "select id from account where uuid = '%s';" \ - % self.account.account.id + % self.account.id ) self.assertEqual( isinstance(qresultset, list), @@ -474,7 +474,7 @@ class TestVolumeUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -484,8 +484,8 @@ class TestVolumeUsage(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls._cleanup = [ @@ -562,11 +562,11 @@ class TestVolumeUsage(cloudstackTestCase): # Fetch account ID from account_uuid self.debug("select id from account where uuid = '%s';" \ - % self.account.account.id) + % self.account.id) qresultset = self.dbclient.execute( "select id from account where uuid = '%s';" \ - % self.account.account.id + % self.account.id ) self.assertEqual( isinstance(qresultset, list), @@ -640,7 +640,7 @@ class TestTemplateUsage(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -651,8 +651,8 @@ class TestTemplateUsage(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, mode=cls.services["mode"] ) @@ -726,11 +726,11 @@ class TestTemplateUsage(cloudstackTestCase): # Fetch account ID from account_uuid self.debug("select id from account where uuid = '%s';" \ - % self.account.account.id) + % self.account.id) qresultset = self.dbclient.execute( "select id from account where uuid = '%s';" \ - % self.account.account.id + % self.account.id ) self.assertEqual( isinstance(qresultset, list), @@ -801,12 +801,12 @@ class TestISOUsage(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.iso = Iso.create( cls.api_client, cls.services["iso"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) try: # Wait till ISO gets downloaded @@ -862,11 +862,11 @@ class TestISOUsage(cloudstackTestCase): # Fetch account ID from account_uuid self.debug("select id from account where uuid = '%s';" \ - % self.account.account.id) + % self.account.id) qresultset = self.dbclient.execute( "select id from account where uuid = '%s';" \ - % self.account.account.id + % self.account.id ) self.assertEqual( isinstance(qresultset, list), @@ -946,7 +946,7 @@ class TestLBRuleUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -956,8 +956,8 @@ class TestLBRuleUsage(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.public_ip_1 = PublicIPAddress.create( @@ -1016,7 +1016,7 @@ class TestLBRuleUsage(cloudstackTestCase): self.apiclient, self.services["lbrule"], self.public_ip_1.ipaddress.id, - accountid=self.account.account.name + accountid=self.account.name ) # Delete LB Rule self.debug("Deleting LB rule with ID: %s" % lb_rule.id) @@ -1024,11 +1024,11 @@ class TestLBRuleUsage(cloudstackTestCase): # Fetch account ID from account_uuid self.debug("select id from account where uuid = '%s';" \ - % self.account.account.id) + % self.account.id) qresultset = self.dbclient.execute( "select id from account where uuid = '%s';" \ - % self.account.account.id + % self.account.id ) self.assertEqual( isinstance(qresultset, list), @@ -1109,7 +1109,7 @@ class TestSnapshotUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -1119,8 +1119,8 @@ class TestSnapshotUsage(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls._cleanup = [ @@ -1190,11 +1190,11 @@ class TestSnapshotUsage(cloudstackTestCase): # Fetch account ID from account_uuid self.debug("select id from account where uuid = '%s';" \ - % self.account.account.id) + % self.account.id) qresultset = self.dbclient.execute( "select id from account where uuid = '%s';" \ - % self.account.account.id + % self.account.id ) self.assertEqual( isinstance(qresultset, list), @@ -1275,7 +1275,7 @@ class TestNatRuleUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -1285,8 +1285,8 @@ class TestNatRuleUsage(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.public_ip_1 = PublicIPAddress.create( @@ -1354,11 +1354,11 @@ class TestNatRuleUsage(cloudstackTestCase): # Fetch account ID from account_uuid self.debug("select id from account where uuid = '%s';" \ - % self.account.account.id) + % self.account.id) qresultset = self.dbclient.execute( "select id from account where uuid = '%s';" \ - % self.account.account.id + % self.account.id ) self.assertEqual( isinstance(qresultset, list), @@ -1438,7 +1438,7 @@ class TestVpnUsage(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -1448,8 +1448,8 @@ class TestVpnUsage(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.public_ip = PublicIPAddress.create( @@ -1506,19 +1506,19 @@ class TestVpnUsage(cloudstackTestCase): vpn = Vpn.create( self.apiclient, self.public_ip.ipaddress.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("Created VPN user for account: %s" % - self.account.account.name) + self.account.name) vpnuser = VpnUser.create( self.apiclient, self.services["vpn_user"]["username"], self.services["vpn_user"]["password"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Remove VPN user @@ -1531,11 +1531,11 @@ class TestVpnUsage(cloudstackTestCase): # Fetch account ID from account_uuid self.debug("select id from account where uuid = '%s';" \ - % self.account.account.id) + % self.account.id) qresultset = self.dbclient.execute( "select id from account where uuid = '%s';" \ - % self.account.account.id + % self.account.id ) self.assertEqual( isinstance(qresultset, list), diff --git a/test/integration/component/test_vm_passwdenabled.py b/test/integration/component/test_vm_passwdenabled.py index e3bcf678948..65b068dc2d2 100644 --- a/test/integration/component/test_vm_passwdenabled.py +++ b/test/integration/component/test_vm_passwdenabled.py @@ -108,8 +108,8 @@ class TestVMPasswordEnabled(cloudstackTestCase): cls.virtual_machine = VirtualMachine.create( cls.api_client, cls.services["small"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.small_offering.id, mode=cls.services["mode"] ) @@ -159,8 +159,8 @@ class TestVMPasswordEnabled(cloudstackTestCase): cls.api_client, cls.services["template"], cls.volume.id, - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) # Delete the VM - No longer needed cls.virtual_machine.delete(cls.api_client) @@ -169,8 +169,8 @@ class TestVMPasswordEnabled(cloudstackTestCase): cls.vm = VirtualMachine.create( cls.api_client, cls.services["small"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.small_offering.id, mode=cls.services["mode"] ) diff --git a/test/integration/component/test_volumes.py b/test/integration/component/test_volumes.py index f50113b1532..34a067930de 100644 --- a/test/integration/component/test_volumes.py +++ b/test/integration/component/test_volumes.py @@ -52,7 +52,7 @@ class Services: "displaytext": "Tiny Instance", "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, # In MBs + "memory": 128, # In MBs }, "disk_offering": { "displaytext": "Small", @@ -121,7 +121,7 @@ class TestAttachVolume(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, cls.services["service_offering"] @@ -129,8 +129,8 @@ class TestAttachVolume(cloudstackTestCase): cls.virtual_machine = VirtualMachine.create( cls.api_client, cls.services["virtual_machine"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, ) cls._cleanup = [ @@ -162,13 +162,13 @@ class TestAttachVolume(cloudstackTestCase): self.apiclient, self.services["volume"], zoneid=self.zone.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, diskofferingid=self.disk_offering.id ) self.debug("Created volume: %s for account: %s" % ( volume.id, - self.account.account.name + self.account.name )) # Check List Volume response for newly created volume list_volume_response = list_volumes( @@ -311,13 +311,13 @@ class TestAttachVolume(cloudstackTestCase): self.apiclient, self.services["volume"], zoneid=self.zone.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, diskofferingid=self.disk_offering.id ) self.debug("Created volume: %s for account: %s" % ( volume.id, - self.account.account.name + self.account.name )) # Check List Volume response for newly created volume list_volume_response = list_volumes( @@ -392,7 +392,7 @@ class TestAttachDetachVolume(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, cls.services["service_offering"] @@ -400,8 +400,8 @@ class TestAttachDetachVolume(cloudstackTestCase): cls.virtual_machine = VirtualMachine.create( cls.api_client, cls.services["virtual_machine"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, ) cls._cleanup = [ @@ -449,13 +449,13 @@ class TestAttachDetachVolume(cloudstackTestCase): self.apiclient, self.services["volume"], zoneid=self.zone.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, diskofferingid=self.disk_offering.id ) self.debug("Created volume: %s for account: %s" % ( volume.id, - self.account.account.name + self.account.name )) self.cleanup.append(volume) volumes.append(volume) @@ -639,7 +639,7 @@ class TestAttachVolumeISO(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, cls.services["service_offering"] @@ -647,8 +647,8 @@ class TestAttachVolumeISO(cloudstackTestCase): cls.virtual_machine = VirtualMachine.create( cls.api_client, cls.services["virtual_machine"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, ) cls._cleanup = [ @@ -694,13 +694,13 @@ class TestAttachVolumeISO(cloudstackTestCase): self.apiclient, self.services["volume"], zoneid=self.zone.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, diskofferingid=self.disk_offering.id ) self.debug("Created volume: %s for account: %s" % ( volume.id, - self.account.account.name + self.account.name )) # Check List Volume response for newly created volume list_volume_response = list_volumes( @@ -749,12 +749,12 @@ class TestAttachVolumeISO(cloudstackTestCase): iso = Iso.create( self.apiclient, self.services["iso"], - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.debug("Created ISO with ID: %s for account: %s" % ( iso.id, - self.account.account.name + self.account.name )) try: @@ -831,7 +831,7 @@ class TestVolumes(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, cls.services["service_offering"] @@ -839,8 +839,8 @@ class TestVolumes(cloudstackTestCase): cls.virtual_machine = VirtualMachine.create( cls.api_client, cls.services["virtual_machine"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, ) @@ -848,8 +848,8 @@ class TestVolumes(cloudstackTestCase): cls.api_client, cls.services["volume"], zoneid=cls.zone.id, - account=cls.account.account.name, - domainid=cls.account.account.domainid, + account=cls.account.name, + domainid=cls.account.domainid, diskofferingid=cls.disk_offering.id ) cls._cleanup = [ @@ -1071,7 +1071,7 @@ class TestDeployVmWithCustomDisk(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, cls.services["service_offering"] @@ -1137,8 +1137,8 @@ class TestDeployVmWithCustomDisk(cloudstackTestCase): Volume.create_custom_disk( self.apiclient, self.services["custom_volume"], - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, diskofferingid=self.disk_offering.id ) self.debug("Create volume failed!") @@ -1149,8 +1149,8 @@ class TestDeployVmWithCustomDisk(cloudstackTestCase): Volume.create_custom_disk( self.apiclient, self.services["custom_volume"], - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, diskofferingid=self.disk_offering.id ) self.debug("Create volume failed!") @@ -1163,8 +1163,8 @@ class TestDeployVmWithCustomDisk(cloudstackTestCase): Volume.create_custom_disk( self.apiclient, self.services["custom_volume"], - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, diskofferingid=self.disk_offering.id ) self.debug("Create volume of cust disk size succeeded") diff --git a/test/integration/component/test_vpn_users.py b/test/integration/component/test_vpn_users.py new file mode 100644 index 00000000000..93186546d94 --- /dev/null +++ b/test/integration/component/test_vpn_users.py @@ -0,0 +1,447 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +""" P1 tests for VPN users +""" +# Import Local Modules +from nose.plugins.attrib import attr +from marvin.cloudstackTestCase import cloudstackTestCase +from marvin.integration.lib.base import ( + Account, + ServiceOffering, + VirtualMachine, + PublicIPAddress, + Vpn, + VpnUser, + Configurations, + NATRule + ) +from marvin.integration.lib.common import (get_domain, + get_zone, + get_template, + cleanup_resources, + ) + + +class Services: + """Test VPN users Services + """ + + def __init__(self): + self.services = { + "account": { + "email": "test@test.com", + "firstname": "Test", + "lastname": "User", + "username": "test", + # Random characters are appended for unique + # username + "password": "password", + }, + "service_offering": { + "name": "Tiny Instance", + "displaytext": "Tiny Instance", + "cpunumber": 1, + "cpuspeed": 100, # in MHz + "memory": 128, # In MBs + }, + "disk_offering": { + "displaytext": "Small Disk Offering", + "name": "Small Disk Offering", + "disksize": 1 + }, + "virtual_machine": { + "displayname": "TestVM", + "username": "root", + "password": "password", + "ssh_port": 22, + "hypervisor": 'KVM', + "privateport": 22, + "publicport": 22, + "protocol": 'TCP', + }, + "vpn_user": { + "username": "test", + "password": "test", + }, + "natrule": { + "privateport": 1701, + "publicport": 1701, + "protocol": "UDP" + }, + "ostype": 'CentOS 5.5 (64-bit)', + "sleep": 60, + "timeout": 10, + # Networking mode: Advanced, Basic + } + + +class TestVPNUsers(cloudstackTestCase): + + @classmethod + def setUpClass(cls): + cls.api_client = super(TestVPNUsers, + cls).getClsTestClient().getApiClient() + cls.services = Services().services + # Get Zone, Domain and templates + cls.domain = get_domain(cls.api_client, cls.services) + cls.zone = get_zone(cls.api_client, cls.services) + cls.services["mode"] = cls.zone.networktype + + cls.template = get_template( + cls.api_client, + cls.zone.id, + cls.services["ostype"] + ) + + cls.services["virtual_machine"]["zoneid"] = cls.zone.id + cls.service_offering = ServiceOffering.create( + cls.api_client, + cls.services["service_offering"] + ) + + cls._cleanup = [cls.service_offering, ] + return + + @classmethod + def tearDownClass(cls): + try: + # Cleanup resources used + cleanup_resources(cls.api_client, cls._cleanup) + except Exception as e: + raise Exception("Warning: Exception during cleanup : %s" % e) + return + + def setUp(self): + self.apiclient = self.testClient.getApiClient() + self.dbclient = self.testClient.getDbConnection() + self.account = Account.create( + self.apiclient, + self.services["account"], + domainid=self.domain.id + ) + self.virtual_machine = VirtualMachine.create( + self.apiclient, + self.services["virtual_machine"], + templateid=self.template.id, + accountid=self.account.name, + domainid=self.account.domainid, + serviceofferingid=self.service_offering.id + ) + self.public_ip = PublicIPAddress.create( + self.apiclient, + self.virtual_machine.account, + self.virtual_machine.zoneid, + self.virtual_machine.domainid, + self.services["virtual_machine"] + ) + self.cleanup = [ + self.account, + ] + return + + def tearDown(self): + try: + # Clean up, terminate the created instance, volumes and snapshots + cleanup_resources(self.apiclient, self.cleanup) + except Exception as e: + raise Exception("Warning: Exception during cleanup : %s" % e) + return + + def create_VPN(self, public_ip): + """Creates VPN for the network""" + + self.debug("Creating VPN with public IP: %s" % public_ip.ipaddress.id) + try: + # Assign VPN to Public IP + vpn = Vpn.create(self.apiclient, + self.public_ip.ipaddress.id, + account=self.account.name, + domainid=self.account.domainid) + + self.debug("Verifying the remote VPN access") + vpns = Vpn.list(self.apiclient, + publicipid=public_ip.ipaddress.id, + listall=True) + self.assertEqual( + isinstance(vpns, list), + True, + "List VPNs shall return a valid response" + ) + return vpn + except Exception as e: + self.fail("Failed to create remote VPN access: %s" % e) + + def create_VPN_Users(self, rand_name=True, api_client=None): + """Creates VPN users for the network""" + + self.debug("Creating VPN users for account: %s" % + self.account.name) + if api_client is None: + api_client = self.apiclient + try: + vpnuser = VpnUser.create( + api_client, + self.services["vpn_user"]["username"], + self.services["vpn_user"]["password"], + account=self.account.name, + domainid=self.account.domainid, + rand_name=rand_name + ) + + self.debug("Verifying the remote VPN access") + vpn_users = VpnUser.list(self.apiclient, + id=vpnuser.id, + listall=True) + self.assertEqual( + isinstance(vpn_users, list), + True, + "List VPNs shall return a valid response" + ) + return vpnuser + except Exception as e: + self.fail("Failed to create remote VPN users: %s" % e) + + @attr(tags=["advanced", "advancedns"]) + @attr(configuration='remote.access.vpn.user.limit') + def test_01_VPN_user_limit(self): + """VPN remote access user limit tests""" + + # Validate the following + # prerequisite: change management configuration setting of + # remote.access.vpn.user.limit + # 1. provision more users than is set in the limit + # Provisioning of users after the limit should failProvisioning of + # users after the limit should fail + + self.debug("Fetching the limit for remote access VPN users") + configs = Configurations.list( + self.apiclient, + name='remote.access.vpn.user.limit', + listall=True) + self.assertEqual(isinstance(configs, list), + True, + "List configs should return a valid response") + + limit = int(configs[0].value) + + self.debug("Enabling the VPN access for IP: %s" % + self.public_ip.ipaddress) + + self.create_VPN(self.public_ip) + self.debug("Creating %s VPN users" % limit) + for x in range(limit): + self.create_VPN_Users() + + self.debug("Adding another user exceeding limit for remote VPN users") + with self.assertRaises(Exception): + self.create_VPN_Users() + self.debug("Limit exceeded exception raised!") + return + + @attr(tags=["advanced", "advancedns"]) + def test_02_use_vpn_port(self): + """Test create VPN when L2TP port in use""" + + # Validate the following + # 1. set a port forward for UDP: 1701 and enable VPN + # 2. set port forward rule for the udp port 1701 over which L2TP works + # 3. port forward should prevent VPN from being enabled + + self.debug("Creating a port forwarding rule on port 1701") + # Create NAT rule + nat_rule = NATRule.create( + self.apiclient, + self.virtual_machine, + self.services["natrule"], + self.public_ip.ipaddress.id) + + self.debug("Verifying the NAT rule created") + nat_rules = NATRule.list(self.apiclient, id=nat_rule.id, listall=True) + + self.assertEqual(isinstance(nat_rules, list), + True, + "List NAT rules should return a valid response") + + self.debug("Enabling the VPN connection for IP: %s" % + self.public_ip.ipaddress) + with self.assertRaises(Exception): + self.create_VPN(self.public_ip) + self.debug("Create VPN connection failed! Test successful!") + return + + @attr(tags=["advanced", "advancedns"]) + def test_03_enable_vpn_use_port(self): + """Test create NAT rule when VPN when L2TP enabled""" + + # Validate the following + # 1. Enable a VPN connection on source NAT + # 2. Add a VPN user + # 3. add a port forward rule for UDP port 1701. Should result in error + # saying that VPN is enabled over port 1701 + + self.debug("Enabling the VPN connection for IP: %s" % + self.public_ip.ipaddress) + self.create_VPN(self.public_ip) + + self.debug("Creating a port forwarding rule on port 1701") + # Create NAT rule + with self.assertRaises(Exception): + NATRule.create( + self.apiclient, + self.virtual_machine, + self.services["natrule"], + self.public_ip.ipaddress.id) + + self.debug("Create NAT rule failed! Test successful!") + return + + @attr(tags=["advanced", "advancedns"]) + def test_04_add_new_users(self): + """Test add new users to existing VPN""" + + # Validate the following + # 1. Enable a VPN connection on source NAT + # 2. Add new user to VPN when there are already existing users. + # 3. We should be able to successfully establish a VPN connection using + # the newly added user credential. + + self.debug("Enabling the VPN connection for IP: %s" % + self.public_ip.ipaddress) + self.create_VPN(self.public_ip) + + try: + self.debug("Adding new VPN user to account: %s" % + self.account.name) + self.create_VPN_Users() + + # TODO: Verify the VPN connection + self.debug("Adding another user to account") + self.create_VPN_Users() + + # TODO: Verify the VPN connection with new user + except Exception as e: + self.fail("Failed to create new VPN user: %s" % e) + return + + @attr(tags=["advanced", "advancedns"]) + def test_05_add_duplicate_user(self): + """Test add duplicate user to existing VPN""" + + # Validate the following + # 1. Enable a VPN connection on source NAT + # 2. Add a VPN user say "abc" that already an added user to the VPN. + # 3. Adding this VPN user should fail. + + self.debug("Enabling the VPN connection for IP: %s" % + self.public_ip.ipaddress) + self.create_VPN(self.public_ip) + + self.debug("Adding new VPN user to account: %s" % + self.account.name) + self.create_VPN_Users(rand_name=False) + + # TODO: Verify the VPN connection + self.debug("Adding another user to account with same username") + with self.assertRaises(Exception): + self.create_VPN_Users(rand_name=False) + return + + @attr(tags=["advanced", "advancedns"]) + def test_06_add_VPN_user_global_admin(self): + """Test as global admin, add a new VPN user to an existing VPN entry + that was created by another account.""" + + # Steps for verification + # 1. Create a new user and deploy few Vms. + # 2. Enable VPN access. Add few VPN users. + # 3. Make sure that VPN access works as expected. + # 4. As global Admin , add VPN user to this user's existing VPN entry. + # Validate the following + # 1. The newly added VPN user should get configured to the router of + # user account. + # 2. We should be able to use this newly created user credential to + # establish VPN connection that will give access all VMs of this user + + self.debug("Enabling VPN connection to account: %s" % + self.account.name) + self.create_VPN(self.public_ip) + self.debug("Creating VPN user for the account: %s" % + self.account.name) + self.create_VPN_Users() + + self.debug("Creating a global admin account") + admin = Account.create(self.apiclient, + self.services["account"], + admin=True, + domainid=self.account.domainid) + self.cleanup.append(admin) + self.debug("Creating API client for newly created user") + api_client = self.testClient.createUserApiClient( + UserName=self.account.name, + DomainName=self.account.domain) + + self.debug("Adding new user to VPN as a global admin: %s" % + admin.account.name) + try: + self.create_VPN_Users(api_client=api_client) + except Exception as e: + self.fail("Global admin should be allowed to create VPN user: %s" % + e) + return + + @attr(tags=["advanced", "advancedns"]) + def test_07_add_VPN_user_domain_admin(self): + """Test as domain admin, add a new VPN user to an existing VPN entry + that was created by another account.""" + + # Steps for verification + # 1. Create a new user and deploy few Vms. + # 2. Enable VPN access. Add few VPN users. + # 3. Make sure that VPN access works as expected. + # 4. As domain Admin , add VPN user to this user's existing VPN entry. + # Validate the following + # 1. The newly added VPN user should get configured to the router of + # user account. + # 2. We should be able to use this newly created user credential to + # establish VPN connection that will give access all VMs of this user + + self.debug("Enabling VPN connection to account: %s" % + self.account.name) + self.create_VPN(self.public_ip) + self.debug("Creating VPN user for the account: %s" % + self.account.name) + self.create_VPN_Users() + + self.debug("Creating a domain admin account") + admin = Account.create(self.apiclient, + self.services["account"], + domainid=self.account.domainid) + self.cleanup.append(admin) + self.debug("Creating API client for newly created user") + api_client = self.testClient.createUserApiClient( + UserName=self.account.name, + DomainName=self.account.domain) + + self.debug("Adding new user to VPN as a domain admin: %s" % + admin.account.name) + try: + self.create_VPN_Users(api_client=api_client) + except Exception as e: + self.fail("Domain admin should be allowed to create VPN user: %s" % + e) + return diff --git a/test/integration/smoke/test_affinity_groups.py b/test/integration/smoke/test_affinity_groups.py index 3ed31152643..e0e1a17273b 100644 --- a/test/integration/smoke/test_affinity_groups.py +++ b/test/integration/smoke/test_affinity_groups.py @@ -48,7 +48,7 @@ class Services: "cpunumber": 1, "cpuspeed": 100, # in MHz - "memory": 64, + "memory": 128, # In MBs }, "ostype": 'CentOS 5.3 (64-bit)', @@ -187,7 +187,7 @@ class TestDeployVmWithAffinityGroup(cloudstackTestCase): @classmethod def tearDown(cls): try: - cls.api_client = super(TestDeployVmWithAffinityGroup, cls).getClsTestClient().getApiClient() + #cls.api_client = super(TestDeployVmWithAffinityGroup, cls).getClsTestClient().getApiClient() #Clean up, terminate the created templates cleanup_resources(cls.api_client, cls.cleanup) except Exception as e: diff --git a/test/integration/smoke/test_deploy_vm_with_userdata.py b/test/integration/smoke/test_deploy_vm_with_userdata.py index fd9e320addc..8ca9bd05a2d 100644 --- a/test/integration/smoke/test_deploy_vm_with_userdata.py +++ b/test/integration/smoke/test_deploy_vm_with_userdata.py @@ -111,6 +111,7 @@ class TestDeployVmWithUserData(cloudstackTestCase): vm = vms[0] self.assert_(vm.id == str(deployVmResponse.id), "Vm deployed is different from the test") self.assert_(vm.state == "Running", "VM is not in Running state") + self.cleanup.append(deployVmResponse) @attr(tags=["simulator", "devcloud", "basic", "advanced"]) def test_deployvm_userdata(self): @@ -134,6 +135,7 @@ class TestDeployVmWithUserData(cloudstackTestCase): vm = vms[0] self.assert_(vm.id == str(deployVmResponse.id), "Vm deployed is different from the test") self.assert_(vm.state == "Running", "VM is not in Running state") + self.cleanup.append(deployVmResponse) @classmethod def tearDownClass(cls): diff --git a/test/integration/smoke/test_global_settings.py b/test/integration/smoke/test_global_settings.py index 12b35d774b7..a7cdb3e1574 100644 --- a/test/integration/smoke/test_global_settings.py +++ b/test/integration/smoke/test_global_settings.py @@ -39,22 +39,22 @@ class TestUpdateConfigWithScope(cloudstackTestCase): updateConfigurationCmd = updateConfiguration.updateConfigurationCmd() updateConfigurationCmd.name = "use.external.dns" updateConfigurationCmd.value = "true" - updateConfigurationCmd.scope = "zone" - updateConfigurationCmd.id = 1 + updateConfigurationCmd.scopename = "zone" + updateConfigurationCmd.scopeid = 1 updateConfigurationResponse = self.apiClient.updateConfiguration(updateConfigurationCmd) self.debug("updated the parameter %s with value %s"%(updateConfigurationResponse.name, updateConfigurationResponse.value)) listConfigurationsCmd = listConfigurations.listConfigurationsCmd() listConfigurationsCmd.cfgName = updateConfigurationResponse.name - listConfigurationsCmd.scope = "zone" - listConfigurationsCmd.id = 1 + listConfigurationsCmd.scopename = "zone" + listConfigurationsCmd.scopeid = 1 listConfigurationsResponse = self.apiClient.listConfigurations(listConfigurationsCmd) self.assertNotEqual(len(listConfigurationsResponse), 0, "Check if the list API \ returns a non-empty response") - configParam = listConfigurationsResponse[0] + configParam = listConfigurationsResponse[7] self.assertEqual(configParam.value, updateConfigurationResponse.value, "Check if the update API returned \ is the same as the one we got in the list API") @@ -67,6 +67,6 @@ class TestUpdateConfigWithScope(cloudstackTestCase): updateConfigurationCmd = updateConfiguration.updateConfigurationCmd() updateConfigurationCmd.name = "use.external.dns" updateConfigurationCmd.value = "false" - updateConfigurationCmd.scope = "zone" - updateConfigurationCmd.id = 1 + updateConfigurationCmd.scopename = "zone" + updateConfigurationCmd.scopeid = 1 self.apiClient.updateConfiguration(updateConfigurationCmd) diff --git a/test/integration/smoke/test_guest_vlan_range.py b/test/integration/smoke/test_guest_vlan_range.py new file mode 100644 index 00000000000..704fe59bfff --- /dev/null +++ b/test/integration/smoke/test_guest_vlan_range.py @@ -0,0 +1,175 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +""" P1 tests for Dedicating Guest Vlan Ranges +""" +#Import Local Modules +import marvin +from nose.plugins.attrib import attr +from marvin.cloudstackTestCase import * +from marvin.cloudstackAPI import * +from marvin.integration.lib.utils import * +from marvin.integration.lib.base import * +from marvin.integration.lib.common import * +import datetime + + +class Services: + """Test Dedicating Guest Vlan Ranges + """ + + def __init__(self): + self.services = { + "domain": { + "name": "Domain", + }, + "account": { + "email": "test@test.com", + "firstname": "Test", + "lastname": "User", + "username": "test", + "password": "password", + }, + "name": "testphysicalnetwork", + + "vlan": "2118-2120", + } + + +class TestDedicateGuestVlanRange(cloudstackTestCase): + + @classmethod + def setUpClass(cls): + cls.api_client = super(TestDedicateGuestVlanRange, cls).getClsTestClient().getApiClient() + cls.services = Services().services + # Get Zone, Domain + cls.domain = get_domain(cls.api_client, cls.services) + cls.zone = get_zone(cls.api_client, cls.services) + + # Create Account + cls.account = Account.create( + cls.api_client, + cls.services["account"], + domainid=cls.domain.id + ) + cls._cleanup = [ + cls.account, + ] + return + + @classmethod + def tearDownClass(cls): + try: + # Cleanup resources used + list_physical_network_response = PhysicalNetwork.list(cls.api_client) + if list_physical_network_response is not None and len(list_physical_network_response) > 0: + physical_network = list_physical_network_response[0] + removeGuestVlanRangeResponse = \ + physical_network.update(cls.api_client, + id=physical_network.id, + removevlan=cls.services["vlan"]) + cleanup_resources(cls.api_client, cls._cleanup) + except Exception as e: + raise Exception("Warning: Exception during cleanup : %s" % e) + return + + def setUp(self): + self.apiclient = self.testClient.getApiClient() + self.dbclient = self.testClient.getDbConnection() + self.cleanup = [] + return + + def tearDown(self): + try: + # Clean up + cleanup_resources(self.apiclient, self.cleanup) + except Exception as e: + raise Exception("Warning: Exception during cleanup : %s" % e) + return + + @attr(tags=["simulator", "advanced", "guestvlanrange", "dedicate", "release"]) + def test_dedicateGuestVlanRange(self): + """Test guest vlan range dedication + """ + + """Assume a physical network is available + """ + # Validate the following: + # 1. List the available physical network using ListPhysicalNetwork + # 2. Add a Guest Vlan range to the available physical network using UpdatePhysicalNetwork + # 3. Dedicate the created guest vlan range to user account using DedicateGuestVlanRange + # 4. Verify vlan range is dedicated with listDedicatedGuestVlanRanges + # 5. Release the dedicated guest vlan range back to the system + # 6. Verify guest vlan range has been released, verify with listDedicatedGuestVlanRanges + # 7. Remove the added guest vlan range using UpdatePhysicalNetwork + + self.debug("Listing available physical network") + list_physical_network_response = PhysicalNetwork.list( + self.apiclient + ) + self.assertEqual( + isinstance(list_physical_network_response, list), + True, + "Check for list guest vlan range response" + ) + physical_network_response = list_physical_network_response[0] + + self.debug("Adding guest vlan range") + addGuestVlanRangeResponse = physical_network_response.update(self.apiclient, id=physical_network_response.id, vlan=self.services["vlan"]) + + self.debug("Dedicating guest vlan range"); + dedicate_guest_vlan_range_response = PhysicalNetwork.dedicate( + self.apiclient, + self.services["vlan"], + physicalnetworkid=physical_network_response.id, + account=self.account.name, + domainid=self.account.domainid + ) + list_dedicated_guest_vlan_range_response = PhysicalNetwork.listDedicated( + self.apiclient, + id=dedicate_guest_vlan_range_response.id + ) + dedicated_guest_vlan_response = list_dedicated_guest_vlan_range_response[0] + self.assertEqual( + dedicated_guest_vlan_response.account, + self.account.name, + "Check account name is in listDedicatedGuestVlanRanges as the account the range is dedicated to" + ) + + self.debug("Releasing guest vlan range"); +<<<<<<< HEAD + dedicated_guest_vlan_response.release(self.apiclient) + list_dedicated_guest_vlan_range_response = PhysicalNetwork.listDedicated( + self.apiclient, + id=dedicate_guest_vlan_range_response.id + ) + dedicated_guest_vlan_response = list_dedicated_guest_vlan_range_response[0] + self.assertEqual( + dedicated_guest_vlan_response.account, + "system", + "Check account name is system account in listDedicatedGuestVlanRanges" + ) +======= + dedicate_guest_vlan_range_response.release(self.apiclient) + list_dedicated_guest_vlan_range_response = PhysicalNetwork.listDedicated(self.apiclient) + self.assertEqual( + list_dedicated_guest_vlan_range_response, + None, + "Check vlan range is not available in listDedicatedGuestVlanRanges" + + ) +>>>>>>> master + diff --git a/test/integration/smoke/test_internal_lb.py b/test/integration/smoke/test_internal_lb.py new file mode 100644 index 00000000000..ae64297bf1c --- /dev/null +++ b/test/integration/smoke/test_internal_lb.py @@ -0,0 +1,250 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +""" Tests for configuring Internal Load Balancing Rules. +""" +#Import Local Modules +from marvin.cloudstackTestCase import * +from marvin.cloudstackAPI import * +from marvin.integration.lib.utils import * +from marvin.integration.lib.base import * +from marvin.integration.lib.common import * + + +class TestInternalLb(cloudstackTestCase): + networkOfferingId = None + networkId = None + vmId = None + lbId = None + + zoneId = 1 + serviceOfferingId = 1 + templateId = 5 + + + serviceProviderList = [ + { + "provider": "VpcVirtualRouter", + "service": "Vpn" + }, + { + "provider": "VpcVirtualRouter", + "service": "UserData" + }, + { + "provider": "VpcVirtualRouter", + "service": "Dhcp" + }, + { + "provider": "VpcVirtualRouter", + "service": "Dns" + }, + { + "provider": "InternalLbVM", + "service": "Lb" + }, + { + "provider": "VpcVirtualRouter", + "service": "SourceNat" + }, + { + "provider": "VpcVirtualRouter", + "service": "StaticNat" + }, + { + "provider": "VpcVirtualRouter", + "service": "PortForwarding" + }, + { + "provider": "VpcVirtualRouter", + "service": "NetworkACL" + } + ] + + serviceCapsList = [ + { + "service": "SourceNat", + "capabilitytype": "SupportedSourceNatTypes", + "capabilityvalue": "peraccount" + }, + { + "service": "Lb", + "capabilitytype": "SupportedLbIsolation", + "capabilityvalue": "dedicated" + }, + { + "service": "Lb", + "capabilitytype": "lbSchemes", + "capabilityvalue": "internal" + } + ] + + def setUp(self): + self.apiClient = self.testClient.getApiClient() + + + + def test_internallb(self): + + #1) Create and enable network offering with Internal Lb vm service + self.createNetworkOffering() + + #2) Create VPC and network in it + self.createNetwork() + + #3) Deploy a vm + self.deployVm() + + #4) Create an Internal Load Balancer + self.createInternalLoadBalancer() + + #5) Assign the VM to the Internal Load Balancer + self.assignToLoadBalancerRule() + + #6) Remove the vm from the Interanl Load Balancer + self.removeFromLoadBalancerRule() + + #7) Delete the Load Balancer + self.deleteLoadBalancer() + + + def deployVm(self): + deployVirtualMachineCmd = deployVirtualMachine.deployVirtualMachineCmd() + deployVirtualMachineCmd.networkids = TestInternalLb.networkId + deployVirtualMachineCmd.serviceofferingid = TestInternalLb.serviceOfferingId + deployVirtualMachineCmd.zoneid = TestInternalLb.zoneId + deployVirtualMachineCmd.templateid = TestInternalLb.templateId + deployVirtualMachineCmd.hypervisor = "XenServer" + deployVMResponse = self.apiClient.deployVirtualMachine(deployVirtualMachineCmd) + TestInternalLb.vmId = deployVMResponse.id + + + def createInternalLoadBalancer(self): + createLoadBalancerCmd = createLoadBalancer.createLoadBalancerCmd() + createLoadBalancerCmd.name = "lb rule" + createLoadBalancerCmd.sourceport = 22 + createLoadBalancerCmd.instanceport = 22 + createLoadBalancerCmd.algorithm = "roundrobin" + createLoadBalancerCmd.scheme = "internal" + createLoadBalancerCmd.sourceipaddressnetworkid = TestInternalLb.networkId + createLoadBalancerCmd.networkid = TestInternalLb.networkId + createLoadBalancerResponse = self.apiClient.createLoadBalancer(createLoadBalancerCmd) + TestInternalLb.lbId = createLoadBalancerResponse.id + self.assertIsNotNone(createLoadBalancerResponse.id, "Failed to create a load balancer") + + + def assignToLoadBalancerRule(self): + assignToLoadBalancerRuleCmd = assignToLoadBalancerRule.assignToLoadBalancerRuleCmd() + assignToLoadBalancerRuleCmd.id = TestInternalLb.lbId + assignToLoadBalancerRuleCmd.virtualMachineIds = TestInternalLb.vmId + assignToLoadBalancerRuleResponse = self.apiClient.assignToLoadBalancerRule(assignToLoadBalancerRuleCmd) + self.assertTrue(assignToLoadBalancerRuleResponse.success, "Failed to assign the vm to the load balancer") + + + + def removeFromLoadBalancerRule(self): + removeFromLoadBalancerRuleCmd = removeFromLoadBalancerRule.removeFromLoadBalancerRuleCmd() + removeFromLoadBalancerRuleCmd.id = TestInternalLb.lbId + removeFromLoadBalancerRuleCmd.virtualMachineIds = TestInternalLb.vmId + removeFromLoadBalancerRuleResponse = self.apiClient.removeFromLoadBalancerRule(removeFromLoadBalancerRuleCmd) + self.assertTrue(removeFromLoadBalancerRuleResponse.success, "Failed to remove the vm from the load balancer") + + + + #def removeInternalLoadBalancer(self): + def deleteLoadBalancer(self): + deleteLoadBalancerCmd = deleteLoadBalancer.deleteLoadBalancerCmd() + deleteLoadBalancerCmd.id = TestInternalLb.lbId + deleteLoadBalancerResponse = self.apiClient.deleteLoadBalancer(deleteLoadBalancerCmd) + self.assertTrue(deleteLoadBalancerResponse.success, "Failed to remove the load balancer") + + + + def createNetwork(self): + createVPCCmd = createVPC.createVPCCmd() + createVPCCmd.name = "new vpc" + createVPCCmd.cidr = "10.1.1.0/24" + createVPCCmd.displaytext = "new vpc" + createVPCCmd.vpcofferingid = 1 + createVPCCmd.zoneid = self.zoneId + createVPCResponse = self.apiClient.createVPC(createVPCCmd) + + + createNetworkCmd = createNetwork.createNetworkCmd() + createNetworkCmd.name = "vpc network" + createNetworkCmd.displaytext = "vpc network" + createNetworkCmd.netmask = "255.255.255.0" + createNetworkCmd.gateway = "10.1.1.1" + createNetworkCmd.zoneid = self.zoneId + createNetworkCmd.vpcid = createVPCResponse.id + createNetworkCmd.networkofferingid = TestInternalLb.networkOfferingId + createNetworkResponse = self.apiClient.createNetwork(createNetworkCmd) + TestInternalLb.networkId = createNetworkResponse.id + + self.assertIsNotNone(createNetworkResponse.id, "Network failed to create") + + + def createNetworkOffering(self): + createNetworkOfferingCmd = createNetworkOffering.createNetworkOfferingCmd() + createNetworkOfferingCmd.name = "Network offering for internal lb service - " + str(random.randrange(1,100+1)) + createNetworkOfferingCmd.displaytext = "Network offering for internal lb service" + createNetworkOfferingCmd.guestiptype = "isolated" + createNetworkOfferingCmd.traffictype = "Guest" + createNetworkOfferingCmd.conservemode = "false" + createNetworkOfferingCmd.supportedservices = "Vpn,Dhcp,Dns,Lb,UserData,SourceNat,StaticNat,PortForwarding,NetworkACL" + + + createNetworkOfferingCmd.serviceproviderlist = [] + for item in self.serviceProviderList: + createNetworkOfferingCmd.serviceproviderlist.append({ + 'service': item['service'], + 'provider': item['provider'] + }) + + createNetworkOfferingCmd.servicecapabilitylist = [] + for item in self.serviceCapsList: + createNetworkOfferingCmd.servicecapabilitylist.append({ + 'service': item['service'], + 'capabilitytype': item['capabilitytype'], + 'capabilityvalue': item['capabilityvalue'] + }) + + + createNetworkOfferingResponse = self.apiClient.createNetworkOffering(createNetworkOfferingCmd) + TestInternalLb.networkOfferingId = createNetworkOfferingResponse.id + + #enable network offering + updateNetworkOfferingCmd = updateNetworkOffering.updateNetworkOfferingCmd() + updateNetworkOfferingCmd.id = TestInternalLb.networkOfferingId + updateNetworkOfferingCmd.state = "Enabled" + updateNetworkOfferingResponse = self.apiClient.updateNetworkOffering(updateNetworkOfferingCmd) + + + #list network offering to see if its enabled + listNetworkOfferingsCmd = listNetworkOfferings.listNetworkOfferingsCmd() + listNetworkOfferingsCmd.id = TestInternalLb.networkOfferingId + listOffResponse = self.apiClient.listNetworkOfferings(listNetworkOfferingsCmd) + + self.assertNotEqual(len(listOffResponse), 0, "Check if the list network offerings API \ + returns a non-empty response") + + + def tearDown(self): + #destroy the vm + if TestInternalLb.vmId is not None: + destroyVirtualMachineCmd = destroyVirtualMachine.destroyVirtualMachineCmd() + destroyVirtualMachineCmd.id = TestInternalLb.vmId + destroyVirtualMachineResponse = self.apiClient.destroyVirtualMachine(destroyVirtualMachineCmd) diff --git a/test/integration/smoke/test_iso.py b/test/integration/smoke/test_iso.py index 0b7d2765775..ad4a8f280d1 100644 --- a/test/integration/smoke/test_iso.py +++ b/test/integration/smoke/test_iso.py @@ -139,8 +139,8 @@ class TestCreateIso(cloudstackTestCase): iso = Iso.create( self.apiclient, self.services["iso_2"], - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.debug("ISO created with ID: %s" % iso.id) @@ -214,7 +214,7 @@ class TestISO(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name # Finding the OsTypeId from Ostype ostypes = list_os_types( cls.api_client, @@ -230,8 +230,8 @@ class TestISO(cloudstackTestCase): cls.iso_1 = Iso.create( cls.api_client, cls.services["iso_1"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) try: cls.iso_1.download(cls.api_client) @@ -242,8 +242,8 @@ class TestISO(cloudstackTestCase): cls.iso_2 = Iso.create( cls.api_client, cls.services["iso_2"], - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) try: cls.iso_2.download(cls.api_client) @@ -448,8 +448,8 @@ class TestISO(cloudstackTestCase): list_iso_response = list_isos( self.apiclient, id=self.iso_2.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_iso_response, list), diff --git a/test/integration/smoke/test_network.py b/test/integration/smoke/test_network.py index df89eaaa695..4a7bb44da2c 100644 --- a/test/integration/smoke/test_network.py +++ b/test/integration/smoke/test_network.py @@ -145,28 +145,28 @@ class TestPublicIP(cloudstackTestCase): cls.account_network = Network.create( cls.api_client, cls.services["network"], - cls.account.account.name, - cls.account.account.domainid + cls.account.name, + cls.account.domainid ) cls.user_network = Network.create( cls.api_client, cls.services["network"], - cls.user.account.name, - cls.user.account.domainid + cls.user.name, + cls.user.domainid ) # Create Source NAT IP addresses account_src_nat_ip = PublicIPAddress.create( cls.api_client, - cls.account.account.name, + cls.account.name, cls.zone.id, - cls.account.account.domainid + cls.account.domainid ) user_src_nat_ip = PublicIPAddress.create( cls.api_client, - cls.user.account.name, + cls.user.name, cls.zone.id, - cls.user.account.domainid + cls.user.domainid ) cls._cleanup = [ cls.account_network, @@ -197,9 +197,9 @@ class TestPublicIP(cloudstackTestCase): ip_address = PublicIPAddress.create( self.apiclient, - self.account.account.name, + self.account.name, self.zone.id, - self.account.account.domainid + self.account.domainid ) list_pub_ip_addr_resp = list_publicIP( self.apiclient, @@ -248,9 +248,9 @@ class TestPublicIP(cloudstackTestCase): ip_address = PublicIPAddress.create( self.apiclient, - self.user.account.name, + self.user.name, self.zone.id, - self.user.account.domainid + self.user.domainid ) #listPublicIpAddresses should return newly created public IP @@ -321,8 +321,8 @@ class TestPortForwarding(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls._cleanup = [ @@ -358,8 +358,8 @@ class TestPortForwarding(cloudstackTestCase): src_nat_ip_addrs = list_publicIP( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -481,9 +481,9 @@ class TestPortForwarding(cloudstackTestCase): ip_address = PublicIPAddress.create( self.apiclient, - self.account.account.name, + self.account.name, self.zone.id, - self.account.account.domainid, + self.account.domainid, self.services["server"] ) self.cleanup.append(ip_address) @@ -554,9 +554,9 @@ class TestPortForwarding(cloudstackTestCase): self.debug("SSHing into VM with IP address %s with NAT IP %s" % ( self.virtual_machine.ipaddress, - ip_address.ipaddress.ipaddress + ip_address.ipaddress )) - self.virtual_machine.get_ssh_client(ip_address.ipaddress.ipaddress) + self.virtual_machine.get_ssh_client(ip_address.ipaddress) except Exception as e: self.fail( "SSH Access failed for %s: %s" % \ @@ -581,7 +581,7 @@ class TestPortForwarding(cloudstackTestCase): self.virtual_machine.ipaddress) remoteSSHClient( - ip_address.ipaddress.ipaddress, + ip_address.ipaddress, self.virtual_machine.ssh_port, self.virtual_machine.username, self.virtual_machine.password @@ -621,23 +621,23 @@ class TestLoadBalancingRule(cloudstackTestCase): cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.vm_2 = VirtualMachine.create( cls.api_client, cls.services["server"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.non_src_nat_ip = PublicIPAddress.create( cls.api_client, - cls.account.account.name, + cls.account.name, cls.zone.id, - cls.account.account.domainid, + cls.account.domainid, cls.services["server"] ) # Open up firewall port for SSH @@ -680,8 +680,8 @@ class TestLoadBalancingRule(cloudstackTestCase): src_nat_ip_addrs = list_publicIP( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(src_nat_ip_addrs, list), @@ -693,8 +693,8 @@ class TestLoadBalancingRule(cloudstackTestCase): # Check if VM is in Running state before creating LB rule vm_response = VirtualMachine.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -720,7 +720,7 @@ class TestLoadBalancingRule(cloudstackTestCase): self.apiclient, self.services["lbrule"], src_nat_ip_addr.id, - accountid=self.account.account.name + accountid=self.account.name ) self.cleanup.append(lb_rule) @@ -889,8 +889,8 @@ class TestLoadBalancingRule(cloudstackTestCase): # Check if VM is in Running state before creating LB rule vm_response = VirtualMachine.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -916,7 +916,7 @@ class TestLoadBalancingRule(cloudstackTestCase): self.apiclient, self.services["lbrule"], self.non_src_nat_ip.ipaddress.id, - accountid=self.account.account.name + accountid=self.account.name ) self.cleanup.append(lb_rule) @@ -974,12 +974,12 @@ class TestLoadBalancingRule(cloudstackTestCase): try: self.debug("SSHing into IP address: %s after adding VMs (ID: %s , %s)" % ( - self.non_src_nat_ip.ipaddress.ipaddress, + self.non_src_nat_ip.ipaddress, self.vm_1.id, self.vm_2.id )) ssh_1 = remoteSSHClient( - self.non_src_nat_ip.ipaddress.ipaddress, + self.non_src_nat_ip.ipaddress, self.services['lbrule']["publicport"], self.vm_1.username, self.vm_1.password @@ -993,12 +993,12 @@ class TestLoadBalancingRule(cloudstackTestCase): self.debug("SSHing again into IP address: %s with VMs (ID: %s , %s) added to LB rule" % ( - self.non_src_nat_ip.ipaddress.ipaddress, + self.non_src_nat_ip.ipaddress, self.vm_1.id, self.vm_2.id )) ssh_2 = remoteSSHClient( - self.non_src_nat_ip.ipaddress.ipaddress, + self.non_src_nat_ip.ipaddress, self.services['lbrule']["publicport"], self.vm_1.username, self.vm_1.password @@ -1022,11 +1022,11 @@ class TestLoadBalancingRule(cloudstackTestCase): self.debug("SSHing into IP address: %s after removing VM (ID: %s) from LB rule" % ( - self.non_src_nat_ip.ipaddress.ipaddress, + self.non_src_nat_ip.ipaddress, self.vm_2.id )) ssh_1 = remoteSSHClient( - self.non_src_nat_ip.ipaddress.ipaddress, + self.non_src_nat_ip.ipaddress, self.services['lbrule']["publicport"], self.vm_1.username, self.vm_1.password @@ -1036,7 +1036,7 @@ class TestLoadBalancingRule(cloudstackTestCase): self.debug("Hostnames after removing VM2: %s" % str(hostnames)) except Exception as e: self.fail("%s: SSH failed for VM with IP Address: %s" % - (e, self.non_src_nat_ip.ipaddress.ipaddress)) + (e, self.non_src_nat_ip.ipaddress)) self.assertIn( self.vm_1.name, @@ -1048,11 +1048,11 @@ class TestLoadBalancingRule(cloudstackTestCase): with self.assertRaises(Exception): self.fail("SSHing into IP address: %s after removing VM (ID: %s) from LB rule" % ( - self.non_src_nat_ip.ipaddress.ipaddress, + self.non_src_nat_ip.ipaddress, self.vm_1.id )) ssh_1 = remoteSSHClient( - self.non_src_nat_ip.ipaddress.ipaddress, + self.non_src_nat_ip.ipaddress, self.services['lbrule']["publicport"], self.vm_1.username, self.vm_1.password @@ -1093,15 +1093,15 @@ class TestRebootRouter(cloudstackTestCase): self.apiclient, self.services["server"], templateid=template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) src_nat_ip_addrs = list_publicIP( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) try: src_nat_ip_addr = src_nat_ip_addrs[0] @@ -1129,7 +1129,7 @@ class TestRebootRouter(cloudstackTestCase): self.apiclient, self.services["lbrule"], src_nat_ip_addr.id, - self.account.account.name + self.account.name ) lb_rule.assign(self.apiclient, [self.vm_1]) self.nat_rule = NATRule.create( @@ -1159,8 +1159,8 @@ class TestRebootRouter(cloudstackTestCase): #Retrieve router for the user account routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(routers, list), @@ -1254,8 +1254,8 @@ class TestAssignRemoveLB(cloudstackTestCase): self.apiclient, self.services["server"], templateid=template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) @@ -1263,8 +1263,8 @@ class TestAssignRemoveLB(cloudstackTestCase): self.apiclient, self.services["server"], templateid=template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) @@ -1272,8 +1272,8 @@ class TestAssignRemoveLB(cloudstackTestCase): self.apiclient, self.services["server"], templateid=template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) @@ -1297,8 +1297,8 @@ class TestAssignRemoveLB(cloudstackTestCase): src_nat_ip_addrs = list_publicIP( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(src_nat_ip_addrs, list), @@ -1320,8 +1320,8 @@ class TestAssignRemoveLB(cloudstackTestCase): # Check if VM is in Running state before creating LB rule vm_response = VirtualMachine.list( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( @@ -1346,7 +1346,7 @@ class TestAssignRemoveLB(cloudstackTestCase): self.apiclient, self.services["lbrule"], self.non_src_nat_ip.id, - self.account.account.name + self.account.name ) lb_rule.assign(self.apiclient, [self.vm_1, self.vm_2]) @@ -1514,28 +1514,28 @@ class TestReleaseIP(cloudstackTestCase): self.apiclient, self.services["server"], templateid=template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) self.ip_address = PublicIPAddress.create( self.apiclient, - self.account.account.name, + self.account.name, self.zone.id, - self.account.account.domainid + self.account.domainid ) ip_addrs = list_publicIP( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) try: self.ip_addr = ip_addrs[0] except Exception as e: raise Exception("Failed: During acquiring source NAT for account: %s" % - self.account.account.name) + self.account.name) self.nat_rule = NATRule.create( self.apiclient, @@ -1547,7 +1547,7 @@ class TestReleaseIP(cloudstackTestCase): self.apiclient, self.services["lbrule"], self.ip_addr.id, - accountid=self.account.account.name + accountid=self.account.name ) self.cleanup = [ self.virtual_machine, @@ -1652,15 +1652,15 @@ class TestDeleteAccount(cloudstackTestCase): self.apiclient, self.services["server"], templateid=template.id, - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id ) src_nat_ip_addrs = list_publicIP( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) try: @@ -1674,7 +1674,7 @@ class TestDeleteAccount(cloudstackTestCase): self.apiclient, self.services["lbrule"], src_nat_ip_addr.id, - self.account.account.name + self.account.name ) self.lb_rule.assign(self.apiclient, [self.vm_1]) @@ -1717,8 +1717,8 @@ class TestDeleteAccount(cloudstackTestCase): try: list_lb_reponse = list_lb_rules( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( list_lb_reponse, @@ -1729,14 +1729,14 @@ class TestDeleteAccount(cloudstackTestCase): raise Exception( "Exception raised while fetching LB rules for account: %s" % - self.account.account.name) + self.account.name) # ListPortForwardingRules should not # list associated rules with deleted account try: list_nat_reponse = list_nat_rules( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( list_nat_reponse, @@ -1747,13 +1747,13 @@ class TestDeleteAccount(cloudstackTestCase): raise Exception( "Exception raised while fetching NAT rules for account: %s" % - self.account.account.name) + self.account.name) #Retrieve router for the user account try: routers = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( routers, @@ -1764,7 +1764,7 @@ class TestDeleteAccount(cloudstackTestCase): raise Exception( "Exception raised while fetching routers for account: %s" % - self.account.account.name) + self.account.name) return def tearDown(self): diff --git a/test/integration/smoke/test_nic.py b/test/integration/smoke/test_nic.py index ad30122cd47..bae6dfda15d 100644 --- a/test/integration/smoke/test_nic.py +++ b/test/integration/smoke/test_nic.py @@ -181,8 +181,8 @@ class TestDeployVM(cloudstackTestCase): self.test_network = Network.create( self.apiclient, self.services["network"], - self.account.account.name, - self.account.account.domainid, + self.account.name, + self.account.domainid, ) self.cleanup.insert(0, self.test_network) except Exception as ex: @@ -198,8 +198,8 @@ class TestDeployVM(cloudstackTestCase): self.virtual_machine = VirtualMachine.create( self.apiclient, self.services["small"], - accountid=self.account.account.name, - domainid=self.account.account.domainid, + accountid=self.account.name, + domainid=self.account.domainid, serviceofferingid=self.service_offering.id, mode=self.services['mode'] ) diff --git a/test/integration/smoke/test_non_contigiousvlan.py b/test/integration/smoke/test_non_contigiousvlan.py index 91b6325782c..4e130d97aa0 100644 --- a/test/integration/smoke/test_non_contigiousvlan.py +++ b/test/integration/smoke/test_non_contigiousvlan.py @@ -81,6 +81,6 @@ class TestUpdatePhysicalNetwork(cloudstackTestCase): self.network = phy_networks[0] self.networkid = phy_networks[0].id updateResponse = self.network.update(self.apiClient, id = self.networkid, removevlan = self.vlan["full"]) - self.assert_(updateResponse.vlan.find(self.vlan["full"]) > 0, + self.assert_(updateResponse.vlan.find(self.vlan["full"]) < 0, "VLAN was not removed successfully") diff --git a/test/integration/smoke/test_regions.py b/test/integration/smoke/test_regions.py new file mode 100644 index 00000000000..5d12e74e8dd --- /dev/null +++ b/test/integration/smoke/test_regions.py @@ -0,0 +1,93 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +from marvin.cloudstackTestCase import * +from marvin.cloudstackAPI import * +from marvin.integration.lib.utils import * +from marvin.integration.lib.base import * +from marvin.integration.lib.common import * +from nose.plugins.attrib import attr + +class Services: + def __init__(self): + self.services = { + "region": { + "regionid": "2", + "regionname": "Region2", + "regionendpoint": "http://region2:8080/client" + } + } + + +class TestRegions(cloudstackTestCase): + """Test Regions - basic region creation + """ + + @classmethod + def setUpClass(cls): + cls.api_client = super(TestRegions, cls).getClsTestClient().getApiClient() + cls.services = Services().services + cls.domain = get_domain(cls.api_client, cls.services) + cls.cleanup = [] + + @attr(tags=["simulator", "basic", "advanced"]) + def test_createRegion(self): + """ Test for create region + """ + region = Region.create(self.api_client, + self.services["region"] + ) + + list_region = Region.list(self.api_client, + id=self.services["region"]["regionid"] + ) + + self.assertEqual( + isinstance(list_region, list), + True, + "Check for list Region response" + ) + region_response = list_region[0] + + self.assertEqual( + str(region_response.id), + self.services["region"]["regionid"], + "listRegion response does not match with region Id created" + ) + + self.assertEqual( + region_response.name, + self.services["region"]["regionname"], + "listRegion response does not match with region name created" + ) + self.assertEqual( + region_response.endpoint, + self.services["region"]["regionendpoint"], + "listRegion response does not match with region endpoint created" + ) + self.cleanup.append(region) + return + + @classmethod + def tearDownClass(cls): + try: + #Clean up + cleanup_resources(cls.api_client, cls.cleanup) + list_region = Region.list(cls.api_client, id=cls.services["region"]["regionid"]) + assert list_region is None, "Region deletion fails" + except Exception as e: + raise Exception("Warning: Region cleanup/delete fails with : %s" % e) \ No newline at end of file diff --git a/test/integration/smoke/test_routers.py b/test/integration/smoke/test_routers.py index 7785576423a..9ec2e918c42 100644 --- a/test/integration/smoke/test_routers.py +++ b/test/integration/smoke/test_routers.py @@ -102,8 +102,8 @@ class TestRouterServices(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id ) cls.cleanup = [ @@ -143,8 +143,8 @@ class TestRouterServices(cloudstackTestCase): # Find router associated with user account list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -205,8 +205,8 @@ class TestRouterServices(cloudstackTestCase): # Find router associated with user account list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -284,8 +284,8 @@ class TestRouterServices(cloudstackTestCase): # Find router associated with user account list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -302,8 +302,8 @@ class TestRouterServices(cloudstackTestCase): while True: networks = list_networks( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(networks, list), @@ -332,8 +332,8 @@ class TestRouterServices(cloudstackTestCase): # Get router details after restart list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -364,8 +364,8 @@ class TestRouterServices(cloudstackTestCase): while True: networks = list_networks( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(networks, list), @@ -394,8 +394,8 @@ class TestRouterServices(cloudstackTestCase): # Get router details after restart list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -462,8 +462,8 @@ class TestRouterServices(cloudstackTestCase): list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -528,8 +528,8 @@ class TestRouterServices(cloudstackTestCase): list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -609,8 +609,8 @@ class TestRouterServices(cloudstackTestCase): list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -653,8 +653,8 @@ class TestRouterServices(cloudstackTestCase): list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -698,8 +698,8 @@ class TestRouterServices(cloudstackTestCase): list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_router_response, list), @@ -755,8 +755,8 @@ class TestRouterServices(cloudstackTestCase): list_vms = list_virtual_machines( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_vms, list), @@ -809,8 +809,8 @@ class TestRouterServices(cloudstackTestCase): #Check status of network router list_router_response = list_routers( self.apiclient, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) if isinstance(list_router_response, list): break diff --git a/test/integration/smoke/test_scale_vm.py b/test/integration/smoke/test_scale_vm.py index 64fe4dc9aa4..fa2418b7cd8 100644 --- a/test/integration/smoke/test_scale_vm.py +++ b/test/integration/smoke/test_scale_vm.py @@ -137,8 +137,8 @@ class TestScaleVm(cloudstackTestCase): cls.virtual_machine = VirtualMachine.create( cls.api_client, cls.services["small"], - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.small_offering.id, mode=cls.services["mode"] ) diff --git a/test/integration/smoke/test_templates.py b/test/integration/smoke/test_templates.py index a648098079f..382f56f8980 100644 --- a/test/integration/smoke/test_templates.py +++ b/test/integration/smoke/test_templates.py @@ -148,7 +148,7 @@ class TestCreateTemplate(cloudstackTestCase): cls.services["account"], domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -159,8 +159,8 @@ class TestCreateTemplate(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, mode=cls.services["mode"] ) @@ -235,8 +235,8 @@ class TestCreateTemplate(cloudstackTestCase): self.apiclient, self.services["template_1"], self.volume.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.cleanup.append(template) @@ -292,6 +292,7 @@ class TestTemplates(cloudstackTestCase): # Get Zone, Domain and templates cls.domain = get_domain(cls.api_client, cls.services) cls.zone = get_zone(cls.api_client, cls.services) + cls.services['mode'] = cls.zone.networktype #populate second zone id for iso copy cmd = listZones.listZonesCmd() zones = cls.api_client.listZones(cmd) @@ -332,7 +333,7 @@ class TestTemplates(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, @@ -343,8 +344,8 @@ class TestTemplates(cloudstackTestCase): cls.api_client, cls.services["virtual_machine"], templateid=template.id, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, mode=cls.services["mode"] ) @@ -393,15 +394,15 @@ class TestTemplates(cloudstackTestCase): cls.api_client, cls.services["template_1"], cls.volume.id, - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls.template_2 = Template.create( cls.api_client, cls.services["template_2"], cls.volume.id, - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls._cleanup = [ cls.service_offering, @@ -474,8 +475,8 @@ class TestTemplates(cloudstackTestCase): templatefilter=\ self.services["templatefilter"], id=self.template_1.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) if isinstance(list_template_response, list): break @@ -540,8 +541,8 @@ class TestTemplates(cloudstackTestCase): templatefilter=\ self.services["templatefilter"], id=self.template_1.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) # Verify template is deleted properly using ListTemplates self.assertEqual( @@ -626,8 +627,8 @@ class TestTemplates(cloudstackTestCase): self.apiclient, templatefilter='featured', id=self.template_2.id, - account=self.account.account.name, - domainid=self.account.account.domainid + account=self.account.name, + domainid=self.account.domainid ) self.assertEqual( isinstance(list_template_response, list), @@ -751,8 +752,8 @@ class TestTemplates(cloudstackTestCase): list_template_response = list_templates( self.apiclient, templatefilter='featured', - account=self.user.account.name, - domainid=self.user.account.domainid + account=self.user.name, + domainid=self.user.domainid ) self.assertEqual( isinstance(list_template_response, list), @@ -783,8 +784,8 @@ class TestTemplates(cloudstackTestCase): list_template_response = list_templates( self.apiclient, templatefilter='featured', - account=self.user.account.name, - domainid=self.user.account.domainid + account=self.user.name, + domainid=self.user.domainid ) self.assertEqual( isinstance(list_template_response, list), diff --git a/test/integration/smoke/test_vm_life_cycle.py b/test/integration/smoke/test_vm_life_cycle.py index ae36c648e0a..21c26357ab2 100644 --- a/test/integration/smoke/test_vm_life_cycle.py +++ b/test/integration/smoke/test_vm_life_cycle.py @@ -163,6 +163,8 @@ class TestDeployVM(cloudstackTestCase): cls.services["account"], domainid=domain.id ) + cls.debug(str("============" )) + cls.debug(cls.account.id) cls.service_offering = ServiceOffering.create( cls.apiclient, diff --git a/test/integration/smoke/test_vm_snapshots.py b/test/integration/smoke/test_vm_snapshots.py new file mode 100644 index 00000000000..353d499f7a1 --- /dev/null +++ b/test/integration/smoke/test_vm_snapshots.py @@ -0,0 +1,308 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +# Import Local Modules +import marvin +from nose.plugins.attrib import attr +from marvin.cloudstackTestCase import * +from marvin.cloudstackAPI import * +from marvin.integration.lib.utils import * +from marvin.integration.lib.base import * +from marvin.integration.lib.common import * +from marvin.remoteSSHClient import remoteSSHClient + +class Services: + """Test Snapshots Services + """ + + def __init__(self): + self.services = { + "account": { + "email": "test@test.com", + "firstname": "Test", + "lastname": "User", + "username": "test", + # Random characters are appended for unique + # username + "password": "password", + }, + "service_offering": { + "name": "Tiny Instance", + "displaytext": "Tiny Instance", + "cpunumber": 1, + "cpuspeed": 200, # in MHz + "memory": 256, # In MBs + }, + "server": { + "displayname": "TestVM", + "username": "root", + "password": "password", + "ssh_port": 22, + "hypervisor": 'XenServer', + "privateport": 22, + "publicport": 22, + "protocol": 'TCP', + }, + "mgmt_server": { + "ipaddress": '1.2.2.152', + "username": "root", + "password": "password", + "port": 22, + }, + "templates": { + "displaytext": 'Template', + "name": 'Template', + "ostype": "CentOS 5.3 (64-bit)", + "templatefilter": 'self', + }, + "test_dir": "/tmp", + "random_data": "random.data", + "snapshot_name":"TestSnapshot", + "snapshot_displaytext":"Test", + "ostype": "CentOS 5.3 (64-bit)", + "sleep": 60, + "timeout": 10, + "mode": 'advanced', # Networking mode: Advanced, Basic + } + +class TestVmSnapshot(cloudstackTestCase): + @classmethod + def setUpClass(cls): + cls.api_client = super(TestVmSnapshot, cls).getClsTestClient().getApiClient() + cls.services = Services().services + # Get Zone, Domain and templates + cls.domain = get_domain(cls.api_client, cls.services) + cls.zone = get_zone(cls.api_client, cls.services) + + template = get_template( + cls.api_client, + cls.zone.id, + cls.services["ostype"] + ) + cls.services["domainid"] = cls.domain.id + cls.services["server"]["zoneid"] = cls.zone.id + cls.services["templates"]["ostypeid"] = template.ostypeid + cls.services["zoneid"] = cls.zone.id + + # Create VMs, NAT Rules etc + cls.account = Account.create( + cls.api_client, + cls.services["account"], + domainid=cls.domain.id + ) + + cls.services["account"] = cls.account.name + + cls.service_offering = ServiceOffering.create( + cls.api_client, + cls.services["service_offering"] + ) + cls.virtual_machine = VirtualMachine.create( + cls.api_client, + cls.services["server"], + templateid=template.id, + accountid=cls.account.name, + domainid=cls.account.domainid, + serviceofferingid=cls.service_offering.id, + mode=cls.services["mode"] + ) + cls.random_data_0 = random_gen(100) + cls._cleanup = [ + cls.service_offering, + cls.account, + ] + return + + @classmethod + def tearDownClass(cls): + try: + # Cleanup resources used + cleanup_resources(cls.api_client, cls._cleanup) + except Exception as e: + raise Exception("Warning: Exception during cleanup : %s" % e) + return + + def setUp(self): + self.apiclient = self.testClient.getApiClient() + self.dbclient = self.testClient.getDbConnection() + self.cleanup = [] + return + + def tearDown(self): + try: + # Clean up, terminate the created instance, volumes and snapshots + cleanup_resources(self.apiclient, self.cleanup) + except Exception as e: + raise Exception("Warning: Exception during cleanup : %s" % e) + return + + @attr(tags=["advanced", "advancedns", "smoke"]) + def test_01_create_vm_snapshots(self): + + try: + # Login to VM and write data to file system + ssh_client = self.virtual_machine.get_ssh_client() + + cmds = [ + "echo %s > %s/%s" % (self.random_data_0, self.services["test_dir"], self.services["random_data"]), + "cat %s/%s" % (self.services["test_dir"], self.services["random_data"]) + ] + + for c in cmds: + self.debug(c) + result = ssh_client.execute(c) + self.debug(result) + + except Exception: + self.fail("SSH failed for Virtual machine: %s" % + self.virtual_machine.ipaddress) + self.assertEqual( + self.random_data_0, + result[0], + "Check the random data has be write into temp file!" + ) + + time.sleep(self.services["sleep"]) + + vm_snapshot = VmSnapshot.create( + self.apiclient, + self.virtual_machine.id, + "false", + self.services["snapshot_name"], + self.services["snapshot_displaytext"] + ) + self.assertEqual( + vm_snapshot.state, + "Ready", + "Check the snapshot of vm is ready!" + ) + return + + @attr(tags=["advanced", "advancedns", "smoke"]) + def test_02_revert_vm_snapshots(self): + try: + ssh_client = self.virtual_machine.get_ssh_client() + + cmds = [ + "rm -rf %s/%s" % (self.services["test_dir"], self.services["random_data"]), + "ls %s/%s" % (self.services["test_dir"], self.services["random_data"]) + ] + + for c in cmds: + self.debug(c) + result = ssh_client.execute(c) + self.debug(result) + + except Exception: + self.fail("SSH failed for Virtual machine: %s" % + self.virtual_machine.ipaddress) + + if str(result[0]).index("No such file or directory") == -1: + self.fail("Check the random data has be delete from temp file!") + + time.sleep(self.services["sleep"]) + + list_snapshot_response = VmSnapshot.list(self.apiclient,vmid=self.virtual_machine.id,listall=True) + + self.assertEqual( + isinstance(list_snapshot_response, list), + True, + "Check list response returns a valid list" + ) + self.assertNotEqual( + list_snapshot_response, + None, + "Check if snapshot exists in ListSnapshot" + ) + + self.assertEqual( + list_snapshot_response[0].state, + "Ready", + "Check the snapshot of vm is ready!" + ) + + VmSnapshot.revertToSnapshot(self.apiclient,list_snapshot_response[0].id) + + list_vm_response = list_virtual_machines( + self.apiclient, + id=self.virtual_machine.id + ) + + self.assertEqual( + list_vm_response[0].state, + "Stopped", + "Check the state of vm is Stopped!" + ) + + cmd = startVirtualMachine.startVirtualMachineCmd() + cmd.id = list_vm_response[0].id + self.apiclient.startVirtualMachine(cmd) + + time.sleep(self.services["sleep"]) + + try: + ssh_client = self.virtual_machine.get_ssh_client(reconnect=True) + + cmds = [ + "cat %s/%s" % (self.services["test_dir"], self.services["random_data"]) + ] + + for c in cmds: + self.debug(c) + result = ssh_client.execute(c) + self.debug(result) + + except Exception: + self.fail("SSH failed for Virtual machine: %s" % + self.virtual_machine.ipaddress) + + self.assertEqual( + self.random_data_0, + result[0], + "Check the random data is equal with the ramdom file!" + ) + @attr(tags=["advanced", "advancedns", "smoke"]) + def test_03_delete_vm_snapshots(self): + + list_snapshot_response = VmSnapshot.list(self.apiclient,vmid=self.virtual_machine.id,listall=True) + + self.assertEqual( + isinstance(list_snapshot_response, list), + True, + "Check list response returns a valid list" + ) + self.assertNotEqual( + list_snapshot_response, + None, + "Check if snapshot exists in ListSnapshot" + ) + """ + cmd = deleteVMSnapshot.deleteVMSnapshotCmd() + cmd.vmsnapshotid = list_snapshot_response[0].id + self.apiclient.deleteVMSnapshot(cmd) + """ + VmSnapshot.deleteVMSnapshot(self.apiclient,list_snapshot_response[0].id) + + time.sleep(self.services["sleep"]*3) + + list_snapshot_response = VmSnapshot.list(self.apiclient,vmid=self.virtual_machine.id,listall=True) + + self.assertEqual( + list_snapshot_response, + None, + "Check list vm snapshot has be deleted" + ) diff --git a/test/integration/smoke/test_volumes.py b/test/integration/smoke/test_volumes.py index 750f9856b22..4bf8203e74c 100644 --- a/test/integration/smoke/test_volumes.py +++ b/test/integration/smoke/test_volumes.py @@ -126,7 +126,7 @@ class TestCreateVolume(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, cls.services["service_offering"] @@ -134,8 +134,8 @@ class TestCreateVolume(cloudstackTestCase): cls.virtual_machine = VirtualMachine.create( cls.api_client, cls.services, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, mode=cls.services["mode"] ) @@ -167,8 +167,8 @@ class TestCreateVolume(cloudstackTestCase): self.apiClient, v, zoneid=self.zone.id, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, diskofferingid=self.disk_offering.id ) self.debug("Created a volume with ID: %s" % volume.id) @@ -177,8 +177,8 @@ class TestCreateVolume(cloudstackTestCase): volume = Volume.create_custom_disk( self.apiClient, self.services, - account=self.account.account.name, - domainid=self.account.account.domainid, + account=self.account.name, + domainid=self.account.domainid, ) self.debug("Created a volume with custom offering: %s" % volume.id) self.volumes.append(volume) @@ -287,6 +287,7 @@ class TestVolumes(cloudstackTestCase): # Get Zone, Domain and templates cls.domain = get_domain(cls.api_client, cls.services) cls.zone = get_zone(cls.api_client, cls.services) + cls.services['mode'] = cls.zone.networktype cls.disk_offering = DiskOffering.create( cls.api_client, cls.services["disk_offering"] @@ -320,7 +321,7 @@ class TestVolumes(cloudstackTestCase): domainid=cls.domain.id ) - cls.services["account"] = cls.account.account.name + cls.services["account"] = cls.account.name cls.service_offering = ServiceOffering.create( cls.api_client, cls.services["service_offering"] @@ -328,8 +329,8 @@ class TestVolumes(cloudstackTestCase): cls.virtual_machine = VirtualMachine.create( cls.api_client, cls.services, - accountid=cls.account.account.name, - domainid=cls.account.account.domainid, + accountid=cls.account.name, + domainid=cls.account.domainid, serviceofferingid=cls.service_offering.id, mode=cls.services["mode"] ) @@ -337,8 +338,8 @@ class TestVolumes(cloudstackTestCase): cls.volume = Volume.create( cls.api_client, cls.services, - account=cls.account.account.name, - domainid=cls.account.account.domainid + account=cls.account.name, + domainid=cls.account.domainid ) cls._cleanup = [ cls.resized_disk_offering, diff --git a/test/selenium/ReadMe.txt b/test/selenium/ReadMe.txt index 30b0e0df7a0..bc968f1dc93 100644 --- a/test/selenium/ReadMe.txt +++ b/test/selenium/ReadMe.txt @@ -1,31 +1,41 @@ ############################################## + +Questions? Post'em @ dev@cloudstack.apache.org + +############################################## + This files contains following: 1) Installation requirements -2) Test Pre requisites -3) Running the Test and Generating the report +2) Testing pre-requisites +3) Running the Tests and Generating the report ############################################## ########################################################################################################################################## -1) Installtion Requirements +1) Installation Requirements +--------------------------- -1)Firefox depending on your OS (Good to have Firebug and Selenium IDE for troubleshooting and dev work) +1) Firefox depending on your OS (Good to have Firebug and Selenium IDE for troubleshooting and dev work) -2)Install Python 2.7. Recommend to use Active State Python +2) Install Python 2.7. 3) Now Open CMD/Terminal and type all of following -- pypm install pycrypto (Installs Pycrypto) -- pypm install paramiko (Install paramiko) +- pip install pycrypto (Installs Pycrypto) +- pip install paramiko (Install paramiko) - pip install unittest-xml-reporting (Install XML Test Runner) - pip install -U selenium (Installs Selenium) +4) Get PhoantomJS for your OS from http://phantomjs.org/ + +- PhantomJS will run selenium test in headless mode. Follow the instruction on PhantomJS.org. +- Make sure the executable is in PATH. (TIP: Drop it in Python27 folder :-)) 5) Now get the HTMLTestRunner for nice looking report generation. - http://tungwaiyip.info/software/HTMLTestRunner.html @@ -35,18 +45,22 @@ This files contains following: ########################################################################################################################################## 2) Test Prerequisites +--------------------- + +- Download and install CS. /cwiki.apache.org has links to Installation Guide and API reference. +- Log into the management server and Add a Zone. (Must be Advance Zone and Hypervisor type must be Xen) -- Download and install CS -- Log into the management server nad Add a Zone. (Must be Advance Zone and Hypervisor type must be Xen) ########################################################################################################################################## 3) Running the Test and Generating the report +--------------------------------------------- - Folder smoke contains main.py - main.py is the file where all the tests are serialized. - main.py supports HTML and XML reporting. Please refer to end of file to choose either. -- Typical usage is: python main.py for XML Reporting -- And python main.py >> results.html for HTML Reporting. +- Typical usage is: python main.py 10.1.1.10 >> result.xml for XML Reporting +- And python main.py 10.1.1.10 >> result.html for HTML Reporting. +- 10.1.1.10 (your management server IP) is an argument required for main. ########################################################################################################################################## diff --git a/test/selenium/lib/initialize.py b/test/selenium/lib/initialize.py index e8cc49adff4..55e5d9aa3b1 100644 --- a/test/selenium/lib/initialize.py +++ b/test/selenium/lib/initialize.py @@ -21,11 +21,26 @@ This will help pass webdriver (Browser instance) across our test cases. from selenium import webdriver +import sys DRIVER = None +MS_ip = None + def getOrCreateWebdriver(): global DRIVER - DRIVER = DRIVER or webdriver.Firefox() + DRIVER = DRIVER or webdriver.PhantomJS('phantomjs') # phantomjs executable must be in PATH. return DRIVER + +def getMSip(): + global MS_ip + if len(sys.argv) >= 3: + sys.exit("Only One argument is required .. Enter your Management Server IP") + + if len(sys.argv) == 1: + sys.exit("Atleast One argument is required .. Enter your Management Server IP") + + for arg in sys.argv[1:]: + MS_ip = arg + return MS_ip \ No newline at end of file diff --git a/test/selenium/smoke/Login_and_Accounts.py b/test/selenium/smoke/Login_and_Accounts.py index c5132d9754c..44b1e836b4c 100644 --- a/test/selenium/smoke/Login_and_Accounts.py +++ b/test/selenium/smoke/Login_and_Accounts.py @@ -34,11 +34,12 @@ class login(unittest.TestCase): def setUp(self): + MS_URL = initialize.getMSip() self.driver = initialize.getOrCreateWebdriver() - self.base_url = "http://10.223.49.206:8080/" # Your management Server IP goes here + self.base_url = "http://"+ MS_URL +":8080/" # Your management Server IP goes here self.verificationErrors = [] - + def test_login(self): # Here we will clear the test box for Username and Password and fill them with actual login data. diff --git a/test/selenium/smoke/main.py b/test/selenium/smoke/main.py index 86bb9308c2f..921192dc847 100644 --- a/test/selenium/smoke/main.py +++ b/test/selenium/smoke/main.py @@ -21,7 +21,7 @@ import xmlrunner global DRIVER - +global MS_ip # Import test cases diff --git a/tools/apidoc/gen_toc.py b/tools/apidoc/gen_toc.py index f8bdae281b2..bd8c0f1668f 100644 --- a/tools/apidoc/gen_toc.py +++ b/tools/apidoc/gen_toc.py @@ -140,6 +140,7 @@ known_categories = { 'removeIpFromNic': 'Nic', 'listNics':'Nic', 'AffinityGroup': 'Affinity Group', + 'InternalLoadBalancer': 'Internal LB', } diff --git a/tools/appliance/definitions/systemvmtemplate/definition.rb b/tools/appliance/definitions/systemvmtemplate/definition.rb index 27336f17f8b..87dbfad09ad 100644 --- a/tools/appliance/definitions/systemvmtemplate/definition.rb +++ b/tools/appliance/definitions/systemvmtemplate/definition.rb @@ -3,9 +3,9 @@ Veewee::Definition.declare({ :memory_size=> '256', :disk_size => '2000', :disk_format => 'VDI', :hostiocache => 'off', :os_type_id => 'Debian', - :iso_file => "debian-wheezy-DI-rc1-i386-netinst.iso", - :iso_src => "http://cdimage.debian.org/cdimage/wheezy_di_rc1/i386/iso-cd/debian-wheezy-DI-rc1-i386-netinst.iso", - :iso_md5 => "db12ca9554bb8f121c98e268682a55d0", + :iso_file => "debian-7.0.0-i386-netinst.iso", + :iso_src => "http://cdimage.debian.org/debian-cd/7.0.0/i386/iso-cd/debian-7.0.0-i386-netinst.iso", + :iso_md5 => "a6b93666a5393334accb7ac4ee28d949", :iso_download_timeout => "1000", :boot_wait => "10", :boot_cmd_sequence => [ '', diff --git a/tools/appliance/definitions/systemvmtemplate/postinstall.sh b/tools/appliance/definitions/systemvmtemplate/postinstall.sh index ae8f1adfb9c..f532f88537c 100644 --- a/tools/appliance/definitions/systemvmtemplate/postinstall.sh +++ b/tools/appliance/definitions/systemvmtemplate/postinstall.sh @@ -37,10 +37,9 @@ install_packages() { apt-get --no-install-recommends -q -y --force-yes install sysstat # apache apt-get --no-install-recommends -q -y --force-yes install apache2 ssl-cert - # haproxy - apt-get --no-install-recommends -q -y --force-yes install haproxy + # dnsmasq - apt-get --no-install-recommends -q -y --force-yes install dnsmasq + apt-get --no-install-recommends -q -y --force-yes install dnsmasq dnsmasq-utils # nfs client apt-get --no-install-recommends -q -y --force-yes install nfs-common @@ -78,6 +77,11 @@ install_packages() { # cd $PREV # rm -fr /opt/vmware-tools-distrib # apt-get -q -y --force-yes purge build-essential + + # haproxy. Wheezy doesn't have haproxy, install from backports + #apt-get --no-install-recommends -q -y --force-yes install haproxy + wget http://ftp.us.debian.org/debian/pool/main/h/haproxy/haproxy_1.4.8-1_i386.deb + dpkg -i haproxy_1.4.8-1_i386.deb } setup_accounts() { diff --git a/tools/appliance/definitions/systemvmtemplate64/definition.rb b/tools/appliance/definitions/systemvmtemplate64/definition.rb index 35ef878d35a..38828da70de 100644 --- a/tools/appliance/definitions/systemvmtemplate64/definition.rb +++ b/tools/appliance/definitions/systemvmtemplate64/definition.rb @@ -3,9 +3,9 @@ Veewee::Definition.declare({ :memory_size=> '256', :disk_size => '2000', :disk_format => 'VDI', :hostiocache => 'off', :os_type_id => 'Debian_64', - :iso_file => "debian-wheezy-DI-rc1-amd64-netinst.iso", - :iso_src => "http://cdimage.debian.org/cdimage/wheezy_di_rc1/amd64/iso-cd/debian-wheezy-DI-rc1-amd64-netinst.iso", - :iso_md5 => "412f77d4b98adf2a7d575745fd282d78", + :iso_file => "debian-7.0.0-amd64-netinst.iso", + :iso_src => "http://cdimage.debian.org/debian-cd/7.0.0/amd64/iso-cd/debian-7.0.0-amd64-netinst.iso", + :iso_md5 => "6a55096340b5b1b7d335d5b559e13ea0", :iso_download_timeout => "1000", :boot_wait => "10", :boot_cmd_sequence => [ '', diff --git a/tools/appliance/definitions/systemvmtemplate64/postinstall.sh b/tools/appliance/definitions/systemvmtemplate64/postinstall.sh index ae8f1adfb9c..3ccf3cefdef 100644 --- a/tools/appliance/definitions/systemvmtemplate64/postinstall.sh +++ b/tools/appliance/definitions/systemvmtemplate64/postinstall.sh @@ -37,10 +37,9 @@ install_packages() { apt-get --no-install-recommends -q -y --force-yes install sysstat # apache apt-get --no-install-recommends -q -y --force-yes install apache2 ssl-cert - # haproxy - apt-get --no-install-recommends -q -y --force-yes install haproxy + # dnsmasq - apt-get --no-install-recommends -q -y --force-yes install dnsmasq + apt-get --no-install-recommends -q -y --force-yes install dnsmasq dnsmasq-utils # nfs client apt-get --no-install-recommends -q -y --force-yes install nfs-common @@ -78,6 +77,11 @@ install_packages() { # cd $PREV # rm -fr /opt/vmware-tools-distrib # apt-get -q -y --force-yes purge build-essential + + # haproxy. Wheezy doesn't have haproxy temporarily, install from backports + #apt-get --no-install-recommends -q -y --force-yes install haproxy + wget http://ftp.us.debian.org/debian/pool/main/h/haproxy/haproxy_1.4.8-1_amd64.deb + dpkg -i haproxy_1.4.8-1_amd64.deb } setup_accounts() { diff --git a/tools/marvin/marvin/cloudstackConnection.py b/tools/marvin/marvin/cloudstackConnection.py index 9a4c387a87a..803911721e9 100644 --- a/tools/marvin/marvin/cloudstackConnection.py +++ b/tools/marvin/marvin/cloudstackConnection.py @@ -113,7 +113,7 @@ class cloudConnection(object): ) signature = base64.encodestring(hmac.new( self.securityKey, hashStr, hashlib.sha1).digest()).strip() - self.logging.info("Computed Signature by Marvin: %s" % signature) + self.logging.debug("Computed Signature by Marvin: %s" % signature) return signature def request(self, command, auth=True, payload={}, method='GET'): diff --git a/tools/marvin/marvin/configGenerator.py b/tools/marvin/marvin/configGenerator.py index e2a6a24d69f..4e82bbe387d 100644 --- a/tools/marvin/marvin/configGenerator.py +++ b/tools/marvin/marvin/configGenerator.py @@ -133,6 +133,7 @@ class physical_network(): self.traffictypes = [] self.broadcastdomainrange = 'Zone' self.vlan = None + self.isolationmethods = [] '''enable default virtual router provider''' vrouter = provider() vrouter.name = 'VirtualRouter' diff --git a/tools/marvin/marvin/deployDataCenter.py b/tools/marvin/marvin/deployDataCenter.py index 5ca1ebfb4f8..7059059beb1 100644 --- a/tools/marvin/marvin/deployDataCenter.py +++ b/tools/marvin/marvin/deployDataCenter.py @@ -169,6 +169,7 @@ class deployDataCenters(): phynet = createPhysicalNetwork.createPhysicalNetworkCmd() phynet.zoneid = zoneid phynet.name = net.name + phynet.isolationmethods = net.isolationmethods phynetwrk = self.apiClient.createPhysicalNetwork(phynet) self.addTrafficTypes(phynetwrk.id, net.traffictypes) return phynetwrk @@ -215,6 +216,18 @@ class deployDataCenters(): vrconfig.id = vrprovid self.apiClient.configureVirtualRouterElement(vrconfig) self.enableProvider(pnetprovres[0].id) + elif provider.name == 'InternalLbVm': + internallbprov = listInternalLoadBalancerElements.listInternalLoadBalancerElementsCmd() + internallbprov.nspid = pnetprovres[0].id + internallbresponse = self.apiClient.listInternalLoadBalancerElements(internallbprov) + internallbid = internallbresponse[0].id + + internallbconfig = \ + configureInternalLoadBalancerElement.configureInternalLoadBalancerElementCmd() + internallbconfig.enabled = "true" + internallbconfig.id = internallbid + self.apiClient.configureInternalLoadBalancerElement(internallbconfig) + self.enableProvider(pnetprovres[0].id) elif provider.name == 'SecurityGroupProvider': self.enableProvider(pnetprovres[0].id) elif provider.name in ['Netscaler', 'JuniperSRX', 'F5BigIp']: diff --git a/tools/marvin/marvin/integration/lib/base.py b/tools/marvin/marvin/integration/lib/base.py index 1d86c6c1599..ecdc8412fdb 100755 --- a/tools/marvin/marvin/integration/lib/base.py +++ b/tools/marvin/marvin/integration/lib/base.py @@ -40,6 +40,9 @@ class Domain: cmd = createDomain.createDomainCmd() + if "domainUUID" in services: + cmd.domainid = "-".join([services["domainUUID"], random_gen()]) + if name: cmd.name = "-".join([name, random_gen()]) elif "name" in services: @@ -97,6 +100,13 @@ class Account: cmd.password = services["password"] cmd.username = "-".join([services["username"], random_gen()]) + if "accountUUID" in services: + cmd.accountid = "-".join([services["accountUUID"],random_gen()]) + + if "userUUID" in services: + cmd.userid = "-".join([services["userUUID"],random_gen()]) + + if domainid: cmd.domainid = domainid account = apiclient.createAccount(cmd) @@ -135,6 +145,9 @@ class User: cmd.firstname = services["firstname"] cmd.lastname = services["lastname"] + if "userUUID" in services: + cmd.userid = "-".join([services["userUUID"],random_gen()]) + # Password Encoding mdf = hashlib.md5() mdf.update(services["password"]) @@ -298,11 +311,10 @@ class VirtualMachine: if "userdata" in services: cmd.userdata = base64.b64encode(services["userdata"]) - virtual_machine = apiclient.deployVirtualMachine(cmd, method=method) - if group: cmd.group = group - virtual_machine = apiclient.deployVirtualMachine(cmd) + + virtual_machine = apiclient.deployVirtualMachine(cmd, method=method) if startvm == False: virtual_machine.ssh_ip = virtual_machine.nic[0].ipaddress @@ -2178,6 +2190,33 @@ class PhysicalNetwork: cmd.traffictype = type return apiclient.addTrafficType(cmd) + @classmethod + def dedicate(cls, apiclient, vlanrange, physicalnetworkid, account=None, domainid=None, projectid=None): + """Dedicate guest vlan range""" + + cmd = dedicateGuestVlanRange.dedicateGuestVlanRangeCmd() + cmd.vlanrange = vlanrange + cmd.physicalnetworkid = physicalnetworkid + cmd.account = account + cmd.domainid = domainid + cmd.projectid = projectid + return PhysicalNetwork(apiclient.dedicateGuestVlanRange(cmd).__dict__) + + def release(self, apiclient): + """Release guest vlan range""" + + cmd = releaseDedicatedGuestVlanRange.releaseDedicatedGuestVlanRangeCmd() + cmd.id = self.id + return apiclient.releaseDedicatedGuestVlanRange(cmd) + + @classmethod + def listDedicated(cls, apiclient, **kwargs): + """Lists all dedicated guest vlan ranges""" + + cmd = listDedicatedGuestVlanRanges.listDedicatedGuestVlanRangesCmd() + [setattr(cmd, k, v) for k, v in kwargs.items()] + return apiclient.listDedicatedGuestVlanRanges(cmd) + @classmethod def list(cls, apiclient, **kwargs): """Lists all physical networks""" @@ -3045,3 +3084,81 @@ class ASA1000V: cmd = listCiscoAsa1000vResources.listCiscoAsa1000vResourcesCmd() [setattr(cmd, k, v) for k, v in kwargs.items()] return(apiclient.listCiscoAsa1000vResources(cmd)) + +class VmSnapshot: + """Manage VM Snapshot life cycle""" + def __init__(self, items): + self.__dict__.update(items) + @classmethod + def create(cls,apiclient,vmid,snapshotmemory="false",name=None,description=None): + cmd = createVMSnapshot.createVMSnapshotCmd() + cmd.virtualmachineid = vmid + + if snapshotmemory: + cmd.snapshotmemory = snapshotmemory + if name: + cmd.name = name + if description: + cmd.description = description + return VmSnapshot(apiclient.createVMSnapshot(cmd).__dict__) + + @classmethod + def list(cls, apiclient, **kwargs): + cmd = listVMSnapshot.listVMSnapshotCmd() + [setattr(cmd, k, v) for k, v in kwargs.items()] + return(apiclient.listVMSnapshot(cmd)) + + @classmethod + def revertToSnapshot(cls, apiclient,vmsnapshotid): + cmd = revertToVMSnapshot.revertToVMSnapshotCmd() + cmd.vmsnapshotid = vmsnapshotid + + return apiclient.revertToVMSnapshot(cmd) + + @classmethod + def deleteVMSnapshot(cls,apiclient,vmsnapshotid): + cmd = deleteVMSnapshot.deleteVMSnapshotCmd() + cmd.vmsnapshotid = vmsnapshotid + + return apiclient.deleteVMSnapshot(cmd) + +class Region: + """ Regions related Api """ + def __init__(self, items): + self.__dict__.update(items) + + @classmethod + def create(cls, apiclient, services): + cmd = addRegion.addRegionCmd() + cmd.id = services["regionid"] + cmd.endpoint = services["regionendpoint"] + cmd.name = services["regionname"] + try: + region = apiclient.addRegion(cmd) + if region is not None: + return Region(region.__dict__) + except Exception as e: + raise e + + @classmethod + def list(cls, apiclient, **kwargs): + cmd = listRegions.listRegionsCmd() + [setattr(cmd, k, v) for k, v in kwargs.items()] + region = apiclient.listRegions(cmd) + return region + + def update(self, apiclient, services): + cmd = updateRegion.updateRegionCmd() + cmd.id = self.id + if services["regionendpoint"]: + cmd.endpoint = services["regionendpoint"] + if services["regionname"]: + cmd.name = services["regionname"] + region = apiclient.updateRegion(cmd) + return region + + def delete(self, apiclient): + cmd = removeRegion.removeRegionCmd() + cmd.id = self.id + region = apiclient.removeRegion(cmd) + return region diff --git a/tools/marvin/marvin/sandbox/advanced/advanced_env.py b/tools/marvin/marvin/sandbox/advanced/advanced_env.py index db78a84b33b..6343293aa62 100644 --- a/tools/marvin/marvin/sandbox/advanced/advanced_env.py +++ b/tools/marvin/marvin/sandbox/advanced/advanced_env.py @@ -46,9 +46,13 @@ def describeResources(config): z.name = 'Sandbox-%s'%(config.get('cloudstack', 'hypervisor')) z.networktype = 'Advanced' z.guestcidraddress = '10.1.1.0/24' + z.securitygroupenabled = 'false' vpcprovider = provider() vpcprovider.name = 'VpcVirtualRouter' + + lbprovider = provider() + lbprovider.name = 'InternalLbVm' pn = physical_network() pn.name = "Sandbox-pnet" @@ -57,14 +61,18 @@ def describeResources(config): pn.traffictypes = [traffictype("Guest"), traffictype("Management", {"simulator" : "cloud-simulator-mgmt"}), traffictype("Public", {"simulator":"cloud-simulator-public"})] + pn.isolationmethods = ["VLAN"] pn.providers.append(vpcprovider) + pn.providers.append(lbprovider) pn2 = physical_network() pn2.name = "Sandbox-pnet2" pn2.vlan = config.get('cloudstack', 'pnet2.vlan') pn2.tags = ["cloud-simulator-guest"] pn2.traffictypes = [traffictype('Guest', {'simulator': 'cloud-simulator-guest'})] + pn2.isolationmethods = ["VLAN"] pn2.providers.append(vpcprovider) + pn2.providers.append(lbprovider) z.physical_networks.append(pn) z.physical_networks.append(pn2) diff --git a/tools/marvin/marvin/sandbox/advanced/sandbox.cfg b/tools/marvin/marvin/sandbox/advanced/sandbox.cfg new file mode 100644 index 00000000000..01a84730dad --- /dev/null +++ b/tools/marvin/marvin/sandbox/advanced/sandbox.cfg @@ -0,0 +1,209 @@ +{ + "zones": [ + { + "name": "Sandbox-Simulator", + "guestcidraddress": "10.1.1.0/24", + "dns1": "10.147.28.6", + "physical_networks": [ + { + "providers": [ + { + "broadcastdomainrange": "ZONE", + "name": "VirtualRouter" + }, + { + "broadcastdomainrange": "ZONE", + "name": "VpcVirtualRouter" + }, + { + "broadcastdomainrange": "ZONE", + "name": "InternalLb" + } + ], + "name": "Sandbox-pnet", + "tags": [ + "cloud-simulator-public" + ], + "broadcastdomainrange": "Zone", + "vlan": "675-679", + "traffictypes": [ + { + "typ": "Guest" + }, + { + "typ": "Management", + "simulator": "cloud-simulator-mgmt" + }, + { + "typ": "Public", + "simulator": "cloud-simulator-public" + } + ], + "isolationmethods": [ + "VLAN" + ] + }, + { + "providers": [ + { + "broadcastdomainrange": "ZONE", + "name": "VirtualRouter" + }, + { + "broadcastdomainrange": "ZONE", + "name": "VpcVirtualRouter" + }, + { + "broadcastdomainrange": "ZONE", + "name": "InternalLb" + } + ], + "name": "Sandbox-pnet2", + "tags": [ + "cloud-simulator-guest" + ], + "broadcastdomainrange": "Zone", + "vlan": "800-1000", + "traffictypes": [ + { + "typ": "Guest", + "simulator": "cloud-simulator-guest" + } + ], + "isolationmethods": [ + "VLAN" + ] + } + ], + "securitygroupenabled": "false", + "ipranges": [ + { + "startip": "10.147.31.150", + "endip": "10.147.31.159", + "netmask": "255.255.255.0", + "vlan": "31", + "gateway": "10.147.31.1" + } + ], + "networktype": "Advanced", + "pods": [ + { + "endip": "10.147.29.159", + "name": "POD0", + "startip": "10.147.29.150", + "netmask": "255.255.255.0", + "clusters": [ + { + "clustername": "C0", + "hypervisor": "Simulator", + "hosts": [ + { + "username": "root", + "url": "http://simulator0", + "password": "password" + } + ], + "clustertype": "CloudManaged", + "primaryStorages": [ + { + "url": "nfs://10.147.28.6:/export/home/sandbox/primary", + "name": "PS0" + } + ] + } + ], + "gateway": "10.147.29.1" + } + ], + "internaldns1": "10.147.28.6", + "secondaryStorages": [ + { + "url": "nfs://10.147.28.6:/export/home/sandbox/sstor" + } + ] + } + ], + "dbSvr": { + "dbSvr": "localhost", + "passwd": "cloud", + "db": "cloud", + "port": 3306, + "user": "cloud" + }, + "logger": [ + { + "name": "TestClient", + "file": "testclient.log" + }, + { + "name": "TestCase", + "file": "testcase.log" + } + ], + "globalConfig": [ + { + "name": "storage.cleanup.interval", + "value": "300" + }, + { + "name": "direct.agent.load.size", + "value": "1000" + }, + { + "name": "default.page.size", + "value": "10000" + }, + { + "name": "instance.name", + "value": "QA" + }, + { + "name": "workers", + "value": "10" + }, + { + "name": "vm.op.wait.interval", + "value": "5" + }, + { + "name": "account.cleanup.interval", + "value": "600" + }, + { + "name": "guest.domain.suffix", + "value": "sandbox.simulator" + }, + { + "name": "expunge.delay", + "value": "60" + }, + { + "name": "vm.allocation.algorithm", + "value": "random" + }, + { + "name": "expunge.interval", + "value": "60" + }, + { + "name": "expunge.workers", + "value": "3" + }, + { + "name": "secstorage.allowed.internal.sites", + "value": "10.147.28.0/24" + }, + { + "name": "check.pod.cidrs", + "value": "true" + } + ], + "mgtSvr": [ + { + "mgtSvrIp": "localhost", + "passwd": "password", + "user": "root", + "port": 8096 + } + ] +} \ No newline at end of file diff --git a/tools/marvin/marvin/sandbox/basic/basic_env.py b/tools/marvin/marvin/sandbox/basic/basic_env.py index e588fdcc882..cf1869fa499 100644 --- a/tools/marvin/marvin/sandbox/basic/basic_env.py +++ b/tools/marvin/marvin/sandbox/basic/basic_env.py @@ -55,6 +55,7 @@ def describeResources(config): pn = physical_network() pn.name = "Sandbox-pnet" pn.traffictypes = [traffictype("Guest"), traffictype("Management")] + pn.isolationmethods = ["L3"] pn.providers.append(sgprovider) z.physical_networks.append(pn) diff --git a/tools/marvin/marvin/sandbox/demo/simulator/simulator_setup.py b/tools/marvin/marvin/sandbox/demo/simulator/simulator_setup.py index e4ec9b7b1b1..d45d48243bd 100644 --- a/tools/marvin/marvin/sandbox/demo/simulator/simulator_setup.py +++ b/tools/marvin/marvin/sandbox/demo/simulator/simulator_setup.py @@ -41,6 +41,7 @@ def describeResources(config): z.name = 'Sandbox-%s'%(config.get('environment', 'hypervisor')) z.networktype = 'Advanced' z.guestcidraddress = '10.1.1.0/24' + z.securitygroupenabled = 'false' vpcprovider = provider() vpcprovider.name = 'VpcVirtualRouter' @@ -48,6 +49,7 @@ def describeResources(config): pn = physical_network() pn.name = "Sandbox-pnet" pn.traffictypes = [traffictype("Guest"), traffictype("Management"), traffictype("Public")] + pn.isolationmethods = ["VLAN"] pn.providers.append(vpcprovider) pn.vlan = config.get('cloudstack', 'zone.vlan') diff --git a/tools/marvin/pom.xml b/tools/marvin/pom.xml index c0505664486..b8f7d7430a5 100644 --- a/tools/marvin/pom.xml +++ b/tools/marvin/pom.xml @@ -1,15 +1,14 @@ + information regarding copyright ownership. The ASF licenses this file to you under + the Apache License, Version 2.0 (the "License"); you may not use this file except + in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 + Unless required by applicable law or agreed to in writing, software distributed under + the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS + OF ANY KIND, either express or implied. See the License for the specific language + governing permissions and limitations under the License. --> + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 cloud-marvin Apache CloudStack marvin @@ -35,7 +34,7 @@ - + Deleting ${project.artifactId} API sources @@ -83,7 +82,7 @@
- + marvin.sync @@ -160,6 +159,26 @@ + + org.codehaus.gmaven + gmaven-plugin + 1.5 + + + setproperty + validate + + execute + + + + pom.properties['resolved.basedir']=project.basedir.absolutePath.replace('\','/').replace('D:','/cyg/d'); + pom.properties['resolved.userdir']='${user.dir}'.replace('\','/').replace('D:','/cyg/d'); + + + + + org.codehaus.mojo exec-maven-plugin @@ -177,18 +196,18 @@ deployAndRun.py -c - ${user.dir}/${marvin.config} + ${resolved.userdir}/${marvin.config} -t /tmp/t.log -r /tmp/r.log -f - ${basedir}/marvin/testSetupSuccess.py + ${resolved.basedir}/marvin/testSetupSuccess.py - - + + @@ -201,6 +220,30 @@ + + org.codehaus.gmaven + gmaven-plugin + 1.5 + + + setproperty + validate + + execute + + + + ${user.dir} + ${marvin.config} + + + project.properties['resolved.user.dir']='${user.dir}'.replace('\','/').replace('D:','/cyg/d'); + project.properties['resolved.marvin.config']='${marvin.config}'.replace('\','/').replace('D:','/cyg/d'); + + + + + org.codehaus.mojo exec-maven-plugin @@ -218,11 +261,11 @@ --with-marvin --marvin-config - ${user.dir}/${marvin.config} + ${resolved.user.dir}/${resolved.marvin.config} --load -a tags=${tag} - ${user.dir}/${test} + ${resolved.user.dir}/${test} -v diff --git a/tools/transifex/.tx/config b/tools/transifex/.tx/config new file mode 100644 index 00000000000..9c495cce520 --- /dev/null +++ b/tools/transifex/.tx/config @@ -0,0 +1,32 @@ +[main] +host = https://www.transifex.com + +[CloudStack_UI.2-2messagesproperties] +file_filter = translations/CloudStack_UI.2-2messagesproperties/.properties +source_lang = en + +[CloudStack_UI.30xmessagesproperties] +file_filter = translations/CloudStack_UI.30xmessagesproperties/.properties +source_lang = en + +[CloudStack_UI.41xmessageproperties] +file_filter = translations/CloudStack_UI.41xmessageproperties/.properties +source_lang = en + +[CloudStack_UI.42xmessagesproperties] +file_filter = translations/CloudStack_UI.42xmessagesproperties/.properties +source_file = work-dir/messages.properties +source_lang = en +trans.ar = work-dir/messages_ar.properties +trans.ca = work-dir/messages_ca.properties +trans.de_DE = work-dir/messages_de_DE.properties +trans.es = work-dir/messages_es.properties +trans.fr_FR = work-dir/messages_fr_FR.properties +trans.it_IT = work-dir/messages_it_IT.properties +trans.ja = work-dir/messages_ja.properties +trans.ko_KR = work-dir/messages_ko_KR.properties +trans.nb_NO = work-dir/messages_nb_NO.properties +trans.pt_BR = work-dir/messages_pt_BR.properties +trans.ru_RU = work-dir/messages_ru_RU.properties +trans.zh_CN = work-dir/messages_zh_CN.properties + diff --git a/tools/transifex/README-transifex.txt b/tools/transifex/README-transifex.txt new file mode 100644 index 00000000000..4b1cd8d00de --- /dev/null +++ b/tools/transifex/README-transifex.txt @@ -0,0 +1,71 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +sync-transifex-ui is a script to automate the synchronisation between +Apache CloudStack L10N resource files and Transifex CloudStack project. + +Requirements to use this script: +* A GNU/Linux or Unix machine +* Transifex client installed +http://support.transifex.com/customer/portal/topics/440187-transifex-client/articles +On Debian/Ubuntu: apt-get install transifex-client + +Commun usage is: + +1/ Init and configure the transifex client CLI +(Already made on git CloudStack repo) + + ./sync-transifex-ui.sh init-transifex https://www.transifex.com/projects/p/CloudStack_UI/ + +2/ Upload to Transifex the last version of the source language (en) +which generally have the new keys/values to translate. + + ./sync-transifex-ui.sh upload-source-language CloudStack_UI.42xmessagesproperties + +3/ Download the last L10N resource files from Transifex to resources +files directory in CloudStack tree to upade the L10N resource files +with the translatons from traductors. + + ./sync-transifex-ui.sh download-l10n-languages CloudStack_UI.42xmessagesproperties + +===== +The sync-transifex-ui provide too the ability to : + +* Download from Transifex the source language resource files. Be carrefully, +with this,you can remove some transation on Transifex if some keys has +been removed inside the source language resource files. + + ./sync-transifex-ui.sh download-source-language CloudStack_UI.42xmessagesproperties + +* Upload the L10N resource files on Transifex. + + ./sync-transifex-ui.sh upload-l10n-languages CloudStack_UI.42xmessagesproperties + +===== +Note 1: +Choose the good branch on git matching with the good resource on Transifex: +(no branch) <--> CloudStack_UI.2-2messagesproperties +(no branch) <--> CloudStack_UI.30xmessagesproperties +(4.1) <--> CloudStack_UI.41xmessageproperties +(master) <--> CloudStack_UI.42xmessagesproperties + +Note 2: +If you want add a new L10N language, we need edit the sync-transifex-ui.sh script +to add his language code in LIST_LANG variable, before run the download-l10n-languages +command. + + diff --git a/tools/transifex/sync-transifex-ui.sh b/tools/transifex/sync-transifex-ui.sh new file mode 100755 index 00000000000..9124ed6a633 --- /dev/null +++ b/tools/transifex/sync-transifex-ui.sh @@ -0,0 +1,160 @@ +#!/bin/sh +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +SRCLANG=en +LIST_LANG="ar ca de_DE es fr_FR it_IT ja ko_KR nb_NO pt_BR ru_RU zh_CN" + +DIRECTORY_RESOURCES="../../client/WEB-INF/classes/resources" +WORKDIR="./work-dir" + +AL2_STRING="# Licensed to the Apache Software Foundation (ASF) under one\n# or more contributor license agreements. See the NOTICE file\n# distributed with this work for additional information\n# regarding copyright ownership. The ASF licenses this file\n# to you under the Apache License, Version 2.0 (the\n# \"License\"); you may not use this file except in compliance\n# with the License. You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing,\n# software distributed under the License is distributed on an\n# \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n# KIND, either express or implied. See the License for the\n# specific language governing permissions and limitations\n# under the License.\n" + +doInit() +{ + tx init + tx set --auto-remote ${ARGUMENTS} +} + +doMakeWdir() +{ + mkdir -p ${WORKDIR} +} + +doCheckInit() +{ + if [ ! -f ./.tx/config ]; then + echo "Error: Transifex project isn't init. Please run $0 init-transifex URL-transifex-project" >&2 + exit 2 + fi +} + +doUploadL10NLangs() +{ + # l10n languages + for CODELANG in ${LIST_LANG} ; do + if [ -f "${DIRECTORY_RESOURCES}/messages_${CODELANG}.properties" ]; then + native2ascii -reverse -encoding UTF-8 ${DIRECTORY_RESOURCES}/messages_${CODELANG}.properties ${WORKDIR}/messages_${CODELANG}.properties + sed -i"" "s/\\\\\\\'/'/g" ${WORKDIR}/messages_${CODELANG}.properties + tx set -r ${ARGUMENTS} -l ${CODELANG} ${WORKDIR}/messages_${CODELANG}.properties + tx push -t -r ${ARGUMENTS} -l ${CODELANG} + else + echo "Warning: the resource file for language ${CODELANG} doesn't exist." + fi + done +} + +doDownloadL10NLangs() +{ + # prepare l10n languages + for CODELANG in ${LIST_LANG} ; do + if [ -f "${DIRECTORY_RESOURCES}/messages_${CODELANG}.properties" ]; then + native2ascii -reverse -encoding UTF-8 ${DIRECTORY_RESOURCES}/messages_${CODELANG}.properties ${WORKDIR}/messages_${CODELANG}.properties + sed -i"" "s/\\\\\\\'/'/g" ${WORKDIR}/messages_${CODELANG}.properties + tx set -r ${ARGUMENTS} -l ${CODELANG} ${WORKDIR}/messages_${CODELANG}.properties + else + echo "\nWarning: the resource file for language ${CODELANG} doesn't exist." + echo "Run this command to force get this language from transifex:" + echo "\ntx set -r ${ARGUMENTS} -l ${CODELANG} ${WORKDIR}/messages_${CODELANG}.properties\n" + fi + done + + # get all resource files from transifex + tx pull -f -r ${ARGUMENTS} + + # l10n languages + for CODELANG in ${LIST_LANG} ; do + #tx pull -r ${ARGUMENTS} -l ${CODELANG} + if [ -f "${WORKDIR}/messages_${CODELANG}.properties" ]; then + native2ascii -encoding UTF-8 ${WORKDIR}/messages_${CODELANG}.properties ${WORKDIR}/messages_${CODELANG}.properties.tmp1 + grep -v "^#" ${WORKDIR}/messages_${CODELANG}.properties.tmp1 | sort -f | uniq | sed "s/'/\\\\\\\\\'/g" > ${WORKDIR}/messages_${CODELANG}.properties.tmp2 + echo "$AL2_STRING" | cat - ${WORKDIR}/messages_${CODELANG}.properties.tmp2 > ${DIRECTORY_RESOURCES}/messages_${CODELANG}.properties + else + echo "Warning: the resource file for language ${CODELANG} doesn't exist on transifex" + fi + done +} + +doUploadSourceLang() +{ + # Source language + if [ -f ${DIRECTORY_RESOURCES}/messages.properties ]; then + native2ascii -reverse -encoding UTF-8 ${DIRECTORY_RESOURCES}/messages.properties ${WORKDIR}/messages.properties + sed -i"" "s/\\\\\\\'/'/g" ${WORKDIR}/messages.properties + tx set --source -r ${ARGUMENTS} -l ${SRCLANG} ${WORKDIR}/messages.properties + tx push -s -r ${ARGUMENTS} + else + echo "Warning: the source language doesn't exist!" + fi +} + +doDownloadSourceLang() +{ + # get all resource files from transifex + tx pull -s -r ${ARGUMENTS} + # Source language + if [ -f "${WORKDIR}/messages.properties" ]; then + native2ascii -encoding UTF-8 ${WORKDIR}/messages.properties ${WORKDIR}/messages.properties.tmp1 + grep -v "^#" ${WORKDIR}/messages.properties.tmp1 | sort -f | uniq | sed "s/'/\\\\\\\\\'/g" > ${WORKDIR}/messages.properties.tmp2 + echo "$AL2_STRING" | cat - ${WORKDIR}/messages.properties.tmp2 > ${DIRECTORY_RESOURCES}/messages.properties + else + echo "Warning: the source language hasn't been retrieve!" + fi +} + +if [ $# -ne 2 ]; then + COMMAND="error" +else + COMMAND="$1" + ARGUMENTS="$2" + doMakeWdir +fi + +case "$COMMAND" in + upload-source-language) + doCheckInit + doUploadSourceLang + ;; + + download-source-language) + doCheckInit + doDownloadSourceLang + ;; + + upload-l10n-languages) + doCheckInit + doUploadL10NLangs + ;; + + download-l10n-languages) + doCheckInit + doDownloadL10NLangs + ;; + + init-transifex) + doInit + ;; + + *|error) + echo "Usage: $0 [upload-source-language|download-source-language] [upload-l10n-languages|download-l10n-languages] transifex-resource" >&2 + echo "\n\tExemple: $0 download-l10n-languages CloudStack_UI-42xmessagesproperties\n" >&2 + echo "Usage: $0 init-transifex URL-transifex-project" >&2 + echo "\n\tExemple: $0 init-transifex https://www.transifex.com/projects/p/CloudStack_UI/\n" >&2 + exit 1 + ;; +esac + diff --git a/ui/css/cloudstack3.css b/ui/css/cloudstack3.css index 7ff7469ab67..7f6df22797e 100644 --- a/ui/css/cloudstack3.css +++ b/ui/css/cloudstack3.css @@ -1699,6 +1699,8 @@ div.list-view td.state.off span { max-height: 407px; overflow: auto; overflow-x: hidden; + width: 100%; + /*[empty]padding:;*/ margin-right: 12px; } @@ -1776,6 +1778,23 @@ div.list-view td.state.off span { background-position: 100% -431px; } +.detail-view .detail-group .button.add { + clear: both; + margin: 0px 21px 13px 0 !important; +} + +.detail-view .details.group-multiple { + float: left; + width: 100%; + margin-bottom: 30px; +} + +.detail-view .details.group-multiple .main-groups { + overflow: visible; + width: 98%; + margin-bottom: 35px; +} + /*List-view: subselect dropdown*/ .list-view .subselect { width: 116px; @@ -2002,6 +2021,40 @@ div.detail-group.actions td { vertical-align: middle; } +.details.group-multiple div.detail-group.actions { + float: right; + max-width: 75%; + height: 23px; + position: relative; + margin: -15px 0 -5px; +} + +.details.group-multiple div.detail-group.actions table { + background: none; +} + +.details.group-multiple div.detail-group.actions td.detail-actions { + background: none; + display: block; + height: 35px; + float: right; + padding: 0; +} + +.details.group-multiple div.detail-group.actions .detail-actions .action { + float: left; + width: 32px; + /*+placement:shift 11px 7px;*/ + position: relative; + left: 11px; + top: 7px; +} + +.details.group-multiple div.detail-group.actions .detail-actions .action a { + background: none; + width: 31px; +} + .detail-group table td.detail-actions { width: 59%; height: 26px; @@ -2768,7 +2821,8 @@ div.toolbar div.button.add, div.toolbar div.button.refresh, div.toolbar div.button.add, div.toolbar div.button.main-action, -.toolbar div.button.header-action { +.toolbar div.button.header-action, +.detail-group .button.add { /*+placement:shift 0px 5px;*/ position: relative; left: 0px; @@ -2800,7 +2854,8 @@ div.toolbar div.button.main-action, div.toolbar div.button.add:hover, div.toolbar div.button.refresh:hover, div.toolbar div.button.main-action:hover, -.toolbar div.button.header-action:hover { +.toolbar div.button.header-action:hover, +.detail-group .button.add:hover { background-position: 0 -132px; border-left: 1px solid #585D60; } @@ -2830,7 +2885,8 @@ div.toolbar div.button.refresh span { background-repeat: no-repeat; } -div.toolbar div.button.add span { +div.toolbar div.button.add span, +.detail-group .button.add span.icon { padding: 0px 0 0px 18px; background: url(../images/icons.png) no-repeat -626px -209px; /*+placement:shift 0px 0px;*/ @@ -5647,7 +5703,7 @@ label.error { /*** Select container*/ .multi-wizard .select-container { - height: 94%; + height: 352px; overflow: auto; overflow-x: hidden; border: 1px solid #D9DFE1; @@ -5660,6 +5716,12 @@ label.error { margin: 10px 10px 0px; } +.multi-wizard .select-container p { + padding: 11px; + color: #424242; + background: #DFDFDF; +} + .multi-wizard .select-container .select { font-size: 13px; margin: -1px 0 0; diff --git a/ui/dictionary.jsp b/ui/dictionary.jsp index d2b4a93503c..ded9ea063d4 100644 --- a/ui/dictionary.jsp +++ b/ui/dictionary.jsp @@ -25,6 +25,10 @@ under the License. <% long now = System.currentTimeMillis(); %> + diff --git a/ui/scripts/accounts.js b/ui/scripts/accounts.js index 7e82c0fc163..bad8435e27e 100644 --- a/ui/scripts/accounts.js +++ b/ui/scripts/accounts.js @@ -277,6 +277,7 @@ detailView: { name: 'Account details', + isMaximized: true, viewAll: { path: 'accounts.users', label: 'label.users' }, actions: { @@ -895,6 +896,56 @@ } }); } + }, + + // Granular settings for account + settings: { + title: 'Settings', + custom: cloudStack.uiCustom.granularSettings({ + dataProvider: function(args) { + $.ajax({ + url:createURL('listConfigurations&accountid=' + args.context.accounts[0].id), + data: { page: args.page, pageSize: pageSize, listAll: true }, + success:function(json){ + args.response.success({ + data:json.listconfigurationsresponse.configuration + + }); + + }, + + error:function(json){ + args.response.error(parseXMLHttpResponse(json)); + + } + }); + + }, + actions: { + edit: function(args) { + // call updateAccountLevelParameters + var data = { + name: args.data.jsonObj.name, + value: args.data.value + }; + + $.ajax({ + url:createURL('updateConfiguration&accountid=' + args.context.accounts[0].id), + data:data, + success:function(json){ + var item = json.updateconfigurationresponse.configuration; + args.response.success({data:item}); + }, + + error: function(json) { + args.response.error(parseXMLHttpResponse(json)); + } + + }); + + } + } + }) } } } diff --git a/ui/scripts/configuration.js b/ui/scripts/configuration.js index 4a64eeac1a5..9a08c4c56b1 100644 --- a/ui/scripts/configuration.js +++ b/ui/scripts/configuration.js @@ -1210,7 +1210,7 @@ } } }); - if(havingVpcVirtualRouterForAtLeastOneService == true || $guestTypeField.val() == 'Shared') { + if(havingVpcVirtualRouterForAtLeastOneService == true ) { $conservemode.find("input[type=checkbox]").attr("disabled", "disabled"); $conservemode.find("input[type=checkbox]").attr('checked', false); diff --git a/ui/scripts/instanceWizard.js b/ui/scripts/instanceWizard.js index f3deb66d6ba..ff130d3e301 100644 --- a/ui/scripts/instanceWizard.js +++ b/ui/scripts/instanceWizard.js @@ -317,7 +317,15 @@ url: createURL('listAffinityGroups'), success: function(json) { var items = json.listaffinitygroupsresponse.affinitygroup; - args.response.success({data: {affinityGroups: items}}); + var data = { + affinityGroups: items + }; + if('affinityGroups' in args.context) { + $.extend(data, { + selectedObj: args.context.affinityGroups[0] + }); + } + args.response.success({data: data}); } }); }, diff --git a/ui/scripts/instances.js b/ui/scripts/instances.js index f95f0a35dc9..c76d843ed6e 100644 --- a/ui/scripts/instances.js +++ b/ui/scripts/instances.js @@ -204,13 +204,7 @@ affinitygroupid: args.context.affinityGroups[0].id }); } - - if(args.context.zoneType != null && args.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data, { - zonetype: args.context.zoneType - }); - } - + $.ajax({ url: createURL('listVirtualMachines'), data: data, @@ -940,7 +934,7 @@ var serviceofferings = json.listserviceofferingsresponse.serviceoffering; var items = []; $(serviceofferings).each(function() { - items.push({id: this.id, description: this.displaytext}); + items.push({id: this.id, description: this.name}); }); args.response.success({data: items}); } @@ -1253,9 +1247,9 @@ dataType: "json", async: true, success: function(json) { - var jid = json.scalevirtualmachineresponse.jobid; - args.response.success( - {_custom: + // var jid = json.scalevirtualmachineresponse.jobid; + args.response.success(); + /* {_custom: {jobId: jid, getUpdatedItem: function(json) { return json.queryasyncjobresultresponse.jobresult.virtualmachine; @@ -1264,8 +1258,8 @@ return vmActionfilter; } } - } - ); + } */ + }, error:function(json){ args.response.error(parseXMLHttpResponse(json)); @@ -1434,8 +1428,124 @@ nics: { title: 'label.nics', multiple: true, + actions: { + add: { + label: 'Add network to VM', + messages: { + confirm: function(args) { + return 'Please confirm that you would like to add a new VM NIC for this network.'; + }, + notification: function(args) { + return 'Add network to VM'; + } + }, + createForm: { + title: 'Add network to VM', + desc: 'Please specify the network that you would like to add this VM to. A new NIC will be added for this network.', + fields: { + networkid: { + label: 'label.network', + select: function(args) { + $.ajax({ + url: createURL('listNetworks'), + data: { + listAll: true, + zoneid: args.context.instances[0].zoneid + }, + success: function(json) { + args.response.success({ + data: $.map(json.listnetworksresponse.network, function(network) { + return { + id: network.id, + description: network.name + }; + }) + }); + } + }); + } + } + } + }, + action: function(args) { + $.ajax({ + url: createURL('addNicToVirtualMachine'), + data: { + virtualmachineid: args.context.instances[0].id, + networkid: args.data.networkid + }, + success: function(json) { + args.response.success({ + _custom: { jobId: json.addnictovirtualmachineresponse.jobid } + }); + } + }); + }, + notification: { poll: pollAsyncJobResult } + }, + + makeDefault: { + label: 'Set default NIC', + messages: { + confirm: function() { + return 'Please confirm that you would like to make this NIC the default for this VM.'; + }, + notification: function(args) { + return 'Set default NIC' + } + }, + action: function (args) { + $.ajax({ + url: createURL('updateDefaultNicForVirtualMachine'), + data: { + virtualmachineid: args.context.instances[0].id, + nicid: args.context.nics[0].id + }, + success: function(json) { + args.response.success({ + _custom: { jobId: json.updatedefaultnicforvirtualmachineresponse.jobid } + }); + } + }); + }, + notification: { + poll: pollAsyncJobResult + } + }, + + // Remove NIC/Network from VM + remove: { + label: 'label.action.delete.nic', + messages: { + confirm: function(args) { + return 'message.action.delete.nic'; + }, + notification: function(args) { + return 'label.action.delete.nic'; + } + }, + action: function(args) { + $.ajax({ + url: createURL('removeNicFromVirtualMachine'), + data: { + virtualmachineid: args.context.instances[0].id, + nicid: args.context.nics[0].id + }, + success: function(json) { + args.response.success({ + _custom: { jobId: json.removenicfromvirtualmachineresponse.jobid } + }) + } + }); + }, + notification: { + poll: pollAsyncJobResult + } + } + }, fields: [ { + id: { label: 'ID' }, name: { label: 'label.name', header: true }, networkname: {label: 'Network Name' }, type: { label: 'label.type' }, @@ -1465,26 +1575,33 @@ } }, dataProvider: function(args) { - $.ajax({ - url:createURL("listVirtualMachines&details=nics&id=" + args.context.instances[0].id), - dataType: "json", - async:true, - success:function(json) { - // Handling the display of network name for a VM under the NICS tabs - args.response.success({ - data: $.map(json.listvirtualmachinesresponse.virtualmachine[0].nic, function(nic, index) { - var name = 'NIC ' + (index + 1); - if (nic.isdefault) { - name += ' (' + _l('label.default') + ')'; - } - return $.extend(nic, { + $.ajax({ + url:createURL("listVirtualMachines&details=nics&id=" + args.context.instances[0].id), + dataType: "json", + async:true, + success:function(json) { + // Handling the display of network name for a VM under the NICS tabs + args.response.success({ + actionFilter: function(args) { + if (args.context.item.isdefault) { + return []; + } else { + return ['remove', 'makeDefault']; + } + }, + data: $.map(json.listvirtualmachinesresponse.virtualmachine[0].nic, function(nic, index) { + var name = 'NIC ' + (index + 1); + if (nic.isdefault) { + name += ' (' + _l('label.default') + ')'; + } + return $.extend(nic, { name: name - }); - }) - }); - } - }); - } + }); + }) + }); + } + }); + } }, /** @@ -1501,7 +1618,16 @@ } ], dataProvider: function(args) { - args.response.success({data: args.context.instances[0].securitygroup}); + // args.response.success({data: args.context.instances[0].securitygroup}); + $.ajax({ + url:createURL("listVirtualMachines&details=secgrp&id=" + args.context.instances[0].id), + dataType: "json", + async:true, + success:function(json) { + args.response.success({data: json.listvirtualmachinesresponse.virtualmachine[0].securitygroup}); + } + + }); } }, @@ -1517,15 +1643,22 @@ networkkbswrite: { label: 'label.network.write' } }, dataProvider: function(args) { - var jsonObj = args.context.instances[0]; - args.response.success({ + $.ajax({ + url:createURL("listVirtualMachines&details=stats&id=" + args.context.instances[0].id), + dataType: "json", + async:true, + success:function(json) { + var jsonObj = json.listvirtualmachinesresponse.virtualmachine[0]; + args.response.success({ data: { totalCPU: jsonObj.cpunumber + " x " + cloudStack.converters.convertHz(jsonObj.cpuspeed), cpuused: jsonObj.cpuused, networkkbsread: (jsonObj.networkkbsread == null)? "N/A": cloudStack.converters.convertBytes(jsonObj.networkkbsread * 1024), networkkbswrite: (jsonObj.networkkbswrite == null)? "N/A": cloudStack.converters.convertBytes(jsonObj.networkkbswrite * 1024) - } - }); + } + }); + } + }); } } } diff --git a/ui/scripts/network.js b/ui/scripts/network.js index 9ba725a8574..6b310ce0e83 100755 --- a/ui/scripts/network.js +++ b/ui/scripts/network.js @@ -3981,13 +3981,12 @@ account: args.context.securityGroups[0].account }; - // TCP / ICMP if (args.data.icmptype && args.data.icmpcode) { // ICMP $.extend(data, { icmptype: args.data.icmptype, icmpcode: args.data.icmpcode }); - } else { // TCP + } else { // TCP/UDP $.extend(data, { startport: args.data.startport, endport: args.data.endport @@ -4081,121 +4080,142 @@ egressRules: { title: 'label.egress.rule', - custom: function(args) { - var context = args.context; + custom: cloudStack.uiCustom.securityRules({ + noSelect: true, + noHeaderActionsColumn: true, + fields: { + 'protocol': { + label: 'label.protocol', + select: function(args) { + args.$select.change(function() { + var $inputs = args.$form.find('th, td'); + var $icmpFields = $inputs.filter(function() { + var name = $(this).attr('rel'); - return $('
').multiEdit({ - context: context, - noSelect: true, - noHeaderActionsColumn: true, - fields: { - 'cidrlist': { edit: true, label: 'label.cidr' }, - 'protocol': { - label: 'label.protocol', - select: function(args) { - args.$select.change(function() { - var $inputs = args.$form.find('th, td'); - var $icmpFields = $inputs.filter(function() { - var name = $(this).attr('rel'); + return $.inArray(name, [ + 'icmptype', + 'icmpcode' + ]) > -1; + }); + var $otherFields = $inputs.filter(function() { + var name = $(this).attr('rel'); - return $.inArray(name, [ - 'icmptype', - 'icmpcode' - ]) > -1; - }); - var $otherFields = $inputs.filter(function() { - var name = $(this).attr('rel'); - - return name != 'cidrlist' && - name != 'icmptype' && - name != 'icmpcode' && - name != 'protocol' && - name != 'add-rule'; - }); - - if ($(this).val() == 'icmp') { - $icmpFields.show(); - $otherFields.hide(); - } else { - $icmpFields.hide(); - $otherFields.show(); - } + return name != 'icmptype' && + name != 'icmpcode' && + name != 'protocol' && + name != 'add-rule' && + name != 'cidr' && + name != 'accountname' && + name != 'securitygroup'; }); - args.response.success({ - data: [ - { name: 'tcp', description: 'TCP' }, - { name: 'udp', description: 'UDP' }, - { name: 'icmp', description: 'ICMP' } - ] - }); - } - }, - 'startport': { edit: true, label: 'label.start.port' }, - 'endport': { edit: true, label: 'label.end.port' }, - 'icmptype': { edit: true, label: 'ICMP.type', isHidden: true }, - 'icmpcode': { edit: true, label: 'ICMP.code', isHidden: true }, - 'add-rule': { - label: 'label.add', - addButton: true - } - }, - add: { - label: 'label.add', - action: function(args) { - var data = { - protocol: args.data.protocol, - cidrlist: args.data.cidrlist, - trafficType: 'Egress' - }; - - if (args.data.icmptype && args.data.icmpcode) { // ICMP - $.extend(data, { - icmptype: args.data.icmptype, - icmpcode: args.data.icmpcode - }); - } else { // TCP/UDP - $.extend(data, { - startport: args.data.startport, - endport: args.data.endport - }); - } - - // Get Source NAT IP - var sourceNATIP; - - $.ajax({ - url: createURL('listPublicIpAddresses'), - data: { - listAll: true, - associatednetworkid: args.context.networks[0].id - }, - async: false, - success: function(json) { - var ipAddresses = json.listpublicipaddressesresponse.publicipaddress; - - sourceNATIP = $.grep(ipAddresses, function(ipAddress) { - return ipAddress.issourcenat; - })[0]; + if ($(this).val() == 'icmp') { + $icmpFields.show(); + $otherFields.hide(); + } else { + $icmpFields.hide(); + $otherFields.show(); } }); - data.ipaddressid = sourceNATIP.id; + args.response.success({ + data: [ + { name: 'tcp', description: 'TCP' }, + { name: 'udp', description: 'UDP' }, + { name: 'icmp', description: 'ICMP' } + ] + }); + } + }, + 'startport': { edit: true, label: 'label.start.port' }, + 'endport': { edit: true, label: 'label.end.port' }, + 'icmptype': { edit: true, label: 'ICMP.type', isHidden: true }, + 'icmpcode': { edit: true, label: 'ICMP.code', isHidden: true }, + 'cidr': { edit: true, label: 'label.cidr', isHidden: true }, + 'accountname': { + edit: true, + label: 'label.account.and.security.group', + isHidden: true, + range: ['accountname', 'securitygroup'] + }, + 'add-rule': { + label: 'label.add', + addButton: true + } + }, + add: { + label: 'label.add', + action: function(args) { + var data = { + securitygroupid: args.context.securityGroups[0].id, + protocol: args.data.protocol, + domainid: args.context.securityGroups[0].domainid, + account: args.context.securityGroups[0].account + }; + if (args.data.icmptype && args.data.icmpcode) { // ICMP + $.extend(data, { + icmptype: args.data.icmptype, + icmpcode: args.data.icmpcode + }); + } else { // TCP/UDP + $.extend(data, { + startport: args.data.startport, + endport: args.data.endport + }); + } + + // CIDR / account + if (args.data.cidr) { + data.cidrlist = args.data.cidr; + } else { + data['usersecuritygrouplist[0].account'] = args.data.accountname; + data['usersecuritygrouplist[0].group'] = args.data.securitygroup; + } + + $.ajax({ + url: createURL('authorizeSecurityGroupEgress'), + data: data, + dataType: 'json', + async: true, + success: function(data) { + var jobId = data.authorizesecuritygroupegressresponse.jobid; + + args.response.success({ + _custom: { + jobId: jobId + }, + notification: { + label: 'label.add.egress.rule', + poll: pollAsyncJobResult + } + }); + } + }); + } + }, + actions: { + destroy: { + label: 'label.remove.rule', + action: function(args) { $.ajax({ - url: createURL('createFirewallRule'), - data: data, + url: createURL('revokeSecurityGroupEgress'), + data: { + domainid: args.context.securityGroups[0].domainid, + account: args.context.securityGroups[0].account, + id: args.context.multiRule[0].id + }, dataType: 'json', async: true, - success: function(json) { - var jobId = json.createfirewallruleresponse.jobid; + success: function(data) { + var jobID = data.revokesecuritygroupegress.jobid; args.response.success({ _custom: { - jobId: jobId + jobId: jobID }, notification: { - label: 'label.add.egress.rule', + label: 'label.remove.egress.rule', poll: pollAsyncJobResult } }); @@ -4205,60 +4225,29 @@ } }); } - }, - actions: { - destroy: { - label: 'label.remove.rule', - action: function(args) { - $.ajax({ - url: createURL('deleteFirewallRule'), - data: { - id: args.context.multiRule[0].id - }, - dataType: 'json', - async: true, - success: function(data) { - var jobID = data.deletefirewallruleresponse.jobid; - - args.response.success({ - _custom: { - jobId: jobID - }, - notification: { - label: 'label.remove.egress.rule', - poll: pollAsyncJobResult - } - }); - }, - error: function(json) { - args.response.error(parseXMLHttpResponse(json)); - } - }); - } - } - }, - ignoreEmptyFields: true, - dataProvider: function(args) { - $.ajax({ - url: createURL('listFirewallRules'), - data: { - listAll: true, - networkid: args.context.networks[0].id, - trafficType: 'Egress' - }, - dataType: 'json', - async: true, - success: function(json) { - var response = json.listfirewallrulesresponse.firewallrule; - - args.response.success({ - data: response - }); - } - }); } - }); - } + }, + ignoreEmptyFields: true, + dataProvider: function(args) { + $.ajax({ + url: createURL('listSecurityGroups'), + data: { + id: args.context.securityGroups[0].id + }, + dataType: 'json', + async: true, + success: function(data) { + args.response.success({ + data: $.map( + data.listsecuritygroupsresponse.securitygroup[0].egressrule ? + data.listsecuritygroupsresponse.securitygroup[0].egressrule : [], + ingressEgressDataMap + ) + }); + } + }); + } + }) } }, diff --git a/ui/scripts/plugins.js b/ui/scripts/plugins.js index 122f4a03491..6a886ba0ae6 100644 --- a/ui/scripts/plugins.js +++ b/ui/scripts/plugins.js @@ -20,15 +20,20 @@ } var loadCSS = function(path) { - var $link = $(''); + if (document.createStyleSheet) { + // IE-compatible CSS loading + document.createStyleSheet(path); + } else { + var $link = $(''); - $link.attr({ - rel: 'stylesheet', - type: 'text/css', - href: path - }); + $link.attr({ + rel: 'stylesheet', + type: 'text/css', + href: path + }); - $('head').append($link); + $('html head').append($link); + } }; $.extend(cloudStack.pluginAPI, { diff --git a/ui/scripts/storage.js b/ui/scripts/storage.js index 9b66083d4e6..e81633466bc 100644 --- a/ui/scripts/storage.js +++ b/ui/scripts/storage.js @@ -89,20 +89,7 @@ dataType: "json", async: true, success: function(json) { - var zoneObjs; - if(args.context.zoneType == null || args.context.zoneType == '') { //all types - zoneObjs = json.listzonesresponse.zone; - } - else { //Basic type or Advanced type - zoneObjs = []; - var items = json.listzonesresponse.zone; - if(items != null) { - for(var i = 0; i < items.length; i++) { - if(items[i].networktype == args.context.zoneType) - zoneObjs.push(items[i]); - } - } - } + var zoneObjs = json.listzonesresponse.zone; args.response.success({descriptionField: 'name', data: zoneObjs}); } }); @@ -227,20 +214,7 @@ dataType: "json", async: true, success: function(json) { - var zoneObjs; - if(args.context.zoneType == null || args.context.zoneType == '') { //all types - zoneObjs = json.listzonesresponse.zone; - } - else { //Basic type or Advanced type - zoneObjs = []; - var items = json.listzonesresponse.zone; - if(items != null) { - for(var i = 0; i < items.length; i++) { - if(items[i].networktype == args.context.zoneType) - zoneObjs.push(items[i]); - } - } - } + var zoneObjs = json.listzonesresponse.zone; args.response.success({descriptionField: 'name', data: zoneObjs}); } }); @@ -398,18 +372,12 @@ if(args.context != null) { if("instances" in args.context) { - $.extend(data, { - virtualMachineId: args.context.instances[0].id - }); + $.extend(data, { + virtualMachineId: args.context.instances[0].id + }); } } - - if(args.context.zoneType != null && args.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data, { - zonetype: args.context.zoneType - }); - } - + $.ajax({ url: createURL('listVolumes'), data: data, @@ -1644,7 +1612,7 @@ if(jsonObj.hypervisor != "Ovm" && jsonObj.state == "Ready") { allowedActions.push("takeSnapshot"); allowedActions.push("recurringSnapshot"); - if((jsonObj.hypervisor == "XenServer" || jsonObj.hypervisor == "KVM" || jsonObj.hypervisor == "VMware") && jsonObj.type == "DATADISK") { + if(jsonObj.type == "DATADISK") { allowedActions.push("resize"); } } diff --git a/ui/scripts/system.js b/ui/scripts/system.js index 8c962fc2b7b..34ba64c917d 100644 --- a/ui/scripts/system.js +++ b/ui/scripts/system.js @@ -184,16 +184,9 @@ dashboard: { dataProvider: function(args) { var dataFns = { - zoneCount: function(data) { - var data = {}; - if(cloudStack.context.zoneType != null && cloudStack.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data, { - networktype: cloudStack.context.zoneType - }); - } + zoneCount: function(data) { $.ajax({ - url: createURL('listZones'), - data: data, + url: createURL('listZones'), success: function(json) { dataFns.podCount($.extend(data, { zoneCount: json.listzonesresponse.count ? @@ -250,12 +243,7 @@ type: 'routing', page: 1, pagesize: 1 //specifying pagesize as 1 because we don't need any embedded objects to be returned here. The only thing we need from API response is "count" property. - }; - if(cloudStack.context.zoneType != null && cloudStack.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data2, { - zonetype: cloudStack.context.zoneType - }); - } + }; $.ajax({ url: createURL('listHosts'), data: data2, @@ -272,12 +260,7 @@ var data2 = { page: 1, pagesize: 1 //specifying pagesize as 1 because we don't need any embedded objects to be returned here. The only thing we need from API response is "count" property. - }; - if(cloudStack.context.zoneType != null && cloudStack.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data2, { - zonetype: cloudStack.context.zoneType - }); - } + }; $.ajax({ url: createURL('listStoragePools'), data: data2, @@ -294,12 +277,7 @@ type: 'SecondaryStorage', page: 1, pagesize: 1 //specifying pagesize as 1 because we don't need any embedded objects to be returned here. The only thing we need from API response is "count" property. - }; - if(cloudStack.context.zoneType != null && cloudStack.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data2, { - zonetype: cloudStack.context.zoneType - }); - } + }; $.ajax({ url: createURL('listHosts'), data: data2, @@ -333,12 +311,7 @@ projectid: -1, page: 1, pagesize: 1 //specifying pagesize as 1 because we don't need any embedded objects to be returned here. The only thing we need from API response is "count" property. - }; - if(cloudStack.context.zoneType != null && cloudStack.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data2, { - zonetype: cloudStack.context.zoneType - }); - } + }; $.ajax({ url: createURL('listRouters'), data: data2, @@ -349,12 +322,7 @@ listAll: true, page: 1, pagesize: 1 //specifying pagesize as 1 because we don't need any embedded objects to be returned here. The only thing we need from API response is "count" property. - }; - if(cloudStack.context.zoneType != null && cloudStack.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data3, { - zonetype: cloudStack.context.zoneType - }); - } + }; $.ajax({ url: createURL('listRouters'), data: data3, @@ -1050,12 +1018,7 @@ dataType: "json", success: function(json) { var jobId = json.updatephysicalnetworkresponse.jobid; - - var trafficType = getTrafficType(selectedPhysicalNetworkObj, 'Guest'); - - updateTrafficLabels(trafficType, args.data, function() { args.response.success({ _custom: { jobId: jobId }}); - }); }, error:function(json){ @@ -1103,10 +1066,7 @@ dataType: "json", success: function(json) { var jobId = json.updatephysicalnetworkresponse.jobid; - var trafficType = getTrafficType(selectedPhysicalNetworkObj, 'Guest'); - updateTrafficLabels(trafficType, args.data, function() { args.response.success({ _custom: { jobId: jobId }}); - }); }, error:function(json){ @@ -2332,12 +2292,7 @@ var data2 = { forvpc: false - }; - if(cloudStack.context.zoneType != null && cloudStack.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data2, { - zonetype: cloudStack.context.zoneType - }); - } + }; var routers = []; $.ajax({ url: createURL("listRouters&zoneid=" + selectedZoneObj.id + "&listAll=true&page=" + args.page + "&pagesize=" + pageSize + array1.join("")), @@ -2817,12 +2772,7 @@ var data2 = { forvpc: true - }; - if(cloudStack.context.zoneType != null && cloudStack.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data2, { - zonetype: cloudStack.context.zoneType - }); - } + }; var routers = []; $.ajax({ url: createURL("listRouters&zoneid=" + selectedZoneObj.id + "&listAll=true&page=" + args.page + "&pagesize=" + pageSize + array1.join("")), @@ -4708,12 +4658,7 @@ break; } } - } - - if(args.context.zoneType != null && args.context.zoneType.length > 0) { //Basic type or Advanced type - array1.push("&networktype=" + args.context.zoneType); - } - + } $.ajax({ url: createURL("listZones&page=" + args.page + "&pagesize=" + pageSize + array1.join("")), dataType: "json", @@ -4975,8 +4920,11 @@ async: true, success: function(json) { args.response.success({data:{}}); - } - }); + }, + error:function(json){ + args.response.error(parseXMLHttpResponse(json)); + } + }); }, notification: { poll: function(args) { args.complete(); } @@ -5424,6 +5372,83 @@ poll: pollAsyncJobResult } }, + + scaleUp:{ + label:'scaleUp System VM', + createForm: { + title: 'label.change.service.offering', + desc: '', + fields: { + serviceOfferingId: { + label: 'label.compute.offering', + select: function(args) { + var apiCmd = "listServiceOfferings&issystem=true"; + if(args.context.systemVMs[0].systemvmtype == "secondarystoragevm") + apiCmd += "&systemvmtype=secondarystoragevm"; + else if(args.context.systemVMs[0].systemvmtype == "consoleproxy") + apiCmd += "&systemvmtype=consoleproxy"; + $.ajax({ + url: createURL(apiCmd), + dataType: "json", + async: true, + success: function(json) { + var serviceofferings = json.listserviceofferingsresponse.serviceoffering; + var items = []; + $(serviceofferings).each(function() { + if(this.id != args.context.systemVMs[0].serviceofferingid) { + items.push({id: this.id, description: this.name}); + } + }); + args.response.success({data: items}); + } + }); + } + } + } + }, + + action: function(args) { + $.ajax({ + url: createURL("scaleVirtualMachine&id=" + args.context.systemVMs[0].id + "&serviceofferingid=" + args.data.serviceOfferingId), + dataType: "json", + async: true, + success: function(json) { + // var jid = json.scalevirtualmachineresponse.jobid; + args.response.success(); + /* {_custom: + {jobId: jid, + getUpdatedItem: function(json) { + return json.queryasyncjobresultresponse.jobresult.virtualmachine; + }, + getActionFilter: function() { + return vmActionfilter; + } + + } + } */ + + }, + error:function(json){ + args.response.error(parseXMLHttpResponse(json)); + } + + }); + }, + messages: { + confirm: function(args) { + return 'Do you really want to scale up the system VM ?'; + }, + notification: function(args) { + + return 'System VM Scaled Up'; + } + }, + notification: { + poll: pollAsyncJobResult + } + + }, + viewConsole: { label: 'label.view.console', @@ -5489,6 +5514,55 @@ } } } + }, + + // Granular settings for zone + settings: { + title: 'Settings', + custom: cloudStack.uiCustom.granularSettings({ + dataProvider: function(args) { + $.ajax({ + url:createURL('listConfigurations&zoneid=' + args.context.physicalResources[0].id), + data: { page: args.page, pageSize: pageSize, listAll: true }, + success:function(json){ + args.response.success({ + data:json.listconfigurationsresponse.configuration + + }); + + }, + + error:function(json){ + args.response.error(parseXMLHttpResponse(json)); + + } + }); + + }, + actions: { + edit: function(args) { + // call updateZoneLevelParamter + var data = { + name: args.data.jsonObj.name, + value: args.data.value + }; + + $.ajax({ + url:createURL('updateConfiguration&zoneid=' + args.context.physicalResources[0].id), + data:data, + success:function(json){ + var item = json.updateconfigurationresponse.configuration; + args.response.success({data:item}); + }, + + error: function(json) { + args.response.error(parseXMLHttpResponse(json)); + } + + }); + } + } + }) } } } @@ -5583,12 +5657,12 @@ var searchByArgs = args.filterBy.search.value.length ? '&name=' + args.filterBy.search.value : ''; - var data = { page: args.page, pageSize: pageSize, type: 'routing', listAll: true }; - if(args.context.zoneType != null && args.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data, { - zonetype: args.context.zoneType - }); - } + var data = { + page: args.page, + pageSize: pageSize, + type: 'routing', + listAll: true + }; $.ajax({ url: createURL('listHosts' + searchByArgs), @@ -5637,11 +5711,7 @@ pageSize: pageSize, listAll: true }; - if(args.context.zoneType != null && args.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data, { - zonetype: args.context.zoneType - }); - } + $.ajax({ url: createURL('listStoragePools' + searchByArgs), data: data, @@ -5684,12 +5754,12 @@ var searchByArgs = args.filterBy.search.value.length ? '&name=' + args.filterBy.search.value : ''; - var data = { type: 'SecondaryStorage', page: args.page, pageSize: pageSize, listAll: true }; - if(args.context.zoneType != null && args.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data, { - zonetype: args.context.zoneType - }); - } + var data = { + type: 'SecondaryStorage', + page: args.page, + pageSize: pageSize, + listAll: true + }; $.ajax({ url: createURL('listHosts' + searchByArgs), @@ -5773,18 +5843,11 @@ var listView = $.extend(true, {}, cloudStack.sections.system.subsections.virtualRouters.listView, { dataProvider: function (args) { var searchByArgs = args.filterBy.search.value.length ? - '&name=' + args.filterBy.search.value : ''; - - var data2 = {}; - if(cloudStack.context.zoneType != null && cloudStack.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data2, { - zonetype: cloudStack.context.zoneType - }); - } + '&name=' + args.filterBy.search.value : ''; + var routers = []; $.ajax({ - url: createURL("listRouters&listAll=true&page=" + args.page + "&pagesize=" + pageSize + searchByArgs), - data: data2, + url: createURL("listRouters&listAll=true&page=" + args.page + "&pagesize=" + pageSize + searchByArgs), async: true, success: function(json) { var items = json.listroutersresponse.router ? @@ -5796,8 +5859,7 @@ // Get project routers $.ajax({ - url: createURL("listRouters&listAll=true&page=" + args.page + "&pagesize=" + pageSize + "&projectid=-1"), - data: data2, + url: createURL("listRouters&listAll=true&page=" + args.page + "&pagesize=" + pageSize + "&projectid=-1"), async: true, success: function(json) { var items = json.listroutersresponse.router ? @@ -5884,11 +5946,7 @@ var data2 = { forvpc: false }; - if(cloudStack.context.zoneType != null && cloudStack.context.zoneType.length > 0) { //Basic type or Advanced type - $.extend(data2, { - zonetype: cloudStack.context.zoneType - }); - } + var routers = []; $.ajax({ url: createURL("listRouters&zoneid=" + selectedZoneObj.id + "&listAll=true&page=" + args.page + "&pagesize=" + pageSize + array1.join("")), @@ -6201,6 +6259,80 @@ } }, + scaleUp:{ + label:'scaleUp Router VM', + createForm: { + title: 'label.change.service.offering', + desc: '', + fields: { + + serviceOfferingId: { + label: 'label.compute.offering', + select: function(args) { + $.ajax({ + url: createURL('listServiceOfferings'), + data: { + issystem: true, + systemvmtype: 'domainrouter' + }, + success: function(json) { + var serviceofferings = json.listserviceofferingsresponse.serviceoffering; + var items = []; + $(serviceofferings).each(function() { + // if(this.id != args.context.routers[0].serviceofferingid) { + items.push({id: this.id, description: this.name}); //default one (i.e. "System Offering For Software Router") doesn't have displaytext property. So, got to use name property instead. + + }); + args.response.success({data: items}); + } + }); + } + } + } + }, + + action: function(args) { + $.ajax({ + url: createURL("scaleVirtualMachine&id=" + args.context.routers[0].id + "&serviceofferingid=" + args.data.serviceOfferingId), + dataType: "json", + async: true, + success: function(json) { + // var jid = json.scalevirtualmachineresponse.jobid; + args.response.success(); + /* {_custom: + {jobId: jid, + getUpdatedItem: function(json) { + return json.queryasyncjobresultresponse.jobresult.virtualmachine; + }, + getActionFilter: function() { + return vmActionfilter; + } + } + }*/ + + }, + error:function(json){ + args.response.error(parseXMLHttpResponse(json)); + } + + }); + }, + messages: { + confirm: function(args) { + return 'Do you really want to scale up the Router VM ?'; + }, + notification: function(args) { + + return 'Router VM Scaled Up'; + } + }, + notification: { + poll: pollAsyncJobResult + } + + }, + + viewConsole: { label: 'label.view.console', action: { @@ -6658,6 +6790,83 @@ } }, + scaleUp:{ + label:'scaleUp System VM', + createForm: { + title: 'label.change.service.offering', + desc: '', + fields: { + serviceOfferingId: { + label: 'label.compute.offering', + select: function(args) { + var apiCmd = "listServiceOfferings&issystem=true"; + if(args.context.systemVMs[0].systemvmtype == "secondarystoragevm") + apiCmd += "&systemvmtype=secondarystoragevm"; + else if(args.context.systemVMs[0].systemvmtype == "consoleproxy") + apiCmd += "&systemvmtype=consoleproxy"; + $.ajax({ + url: createURL(apiCmd), + dataType: "json", + async: true, + success: function(json) { + var serviceofferings = json.listserviceofferingsresponse.serviceoffering; + var items = []; + $(serviceofferings).each(function() { + if(this.id != args.context.systemVMs[0].serviceofferingid) { + items.push({id: this.id, description: this.name}); + } + }); + args.response.success({data: items}); + } + }); + } + } + } + }, + + action: function(args) { + $.ajax({ + url: createURL("scaleVirtualMachine&id=" + args.context.systemVMs[0].id + "&serviceofferingid=" + args.data.serviceOfferingId), + dataType: "json", + async: true, + success: function(json) { + var jid = json.scalevirtualmachineresponse.jobid; + args.response.success( + {_custom: + {jobId: jid, + getUpdatedItem: function(json) { + return json.queryasyncjobresultresponse.jobresult.virtualmachine; + }, + getActionFilter: function() { + return vmActionfilter; + } + } + } + ); + }, + error:function(json){ + args.response.error(parseXMLHttpResponse(json)); + } + + }); + }, + messages: { + confirm: function(args) { + return 'Do you really want to scale up the system VM ?'; + }, + notification: function(args) { + + return 'System VM Scaled Up'; + } + }, + notification: { + poll: pollAsyncJobResult + } + + }, + + + viewConsole: { label: 'label.view.console', action: { @@ -8931,6 +9140,57 @@ }); } } + }, + + // Granular settings for cluster + settings: { + title: 'Settings', + custom: cloudStack.uiCustom.granularSettings({ + dataProvider: function(args) { + $.ajax({ + url:createURL('listConfigurations&clusterid=' + args.context.clusters[0].id), + data: { page: args.page, pageSize: pageSize, listAll: true }, + success:function(json){ + args.response.success({ + data:json.listconfigurationsresponse.configuration + + }); + + }, + + error:function(json){ + args.response.error(parseXMLHttpResponse(json)); + + } + }); + + }, + actions: { + edit: function(args) { + // call updateClusterLevelParameters + + var data = { + name: args.data.jsonObj.name, + value: args.data.value + }; + + $.ajax({ + url:createURL('updateConfiguration&clusterid=' + args.context.clusters[0].id), + data:data, + success:function(json){ + var item = json.updateconfigurationresponse.configuration; + args.response.success({data:item}); + }, + + error: function(json) { + args.response.error(parseXMLHttpResponse(json)); + } + + }); + + } + } + }) } } } @@ -8981,11 +9241,7 @@ } else { array1.push("&hostid=" + args.context.instances[0].hostid); } - - if(args.context.zoneType != null && args.context.zoneType.length > 0) { //Basic type or Advanced type - array1.push("&zonetype=" + args.context.zoneType); - } - + $.ajax({ url: createURL("listHosts&type=Routing" + array1.join("") + "&page=" + args.page + "&pagesize=" + pageSize), dataType: "json", @@ -10370,6 +10626,7 @@ detailView: { name: "Primary storage details", + isMaximized: true, actions: { edit: { label: 'label.edit', @@ -10554,6 +10811,57 @@ } }); } + }, + + // Granular settings for storage pool + settings: { + title: 'Settings', + custom: cloudStack.uiCustom.granularSettings({ + dataProvider: function(args) { + + $.ajax({ + url:createURL('listConfigurations&storageid=' + args.context.primarystorages[0].id), + data: { page: args.page, pageSize: pageSize, listAll: true }, + success:function(json){ + args.response.success({ + data:json.listconfigurationsresponse.configuration + + }); + + }, + + error:function(json){ + args.response.error(parseXMLHttpResponse(json)); + + } + }); + + }, + actions: { + edit: function(args) { + // call updateStorageLevelParameters + var data = { + name: args.data.jsonObj.name, + value: args.data.value + }; + + $.ajax({ + url:createURL('updateConfiguration&storageid=' + args.context.primarystorages[0].id), + data:data, + success:function(json){ + var item = json.updateconfigurationresponse.configuration; + args.response.success({data:item}); + }, + + error: function(json) { + args.response.error(parseXMLHttpResponse(json)); + } + + }); + + } + } + }) } } } @@ -10593,10 +10901,6 @@ } array1.push("&zoneid=" + args.context.zones[0].id); - if(args.context.zoneType != null && args.context.zoneType.length > 0) { //Basic type or Advanced type - array1.push("&zonetype=" + args.context.zoneType); - } - $.ajax({ url: createURL("listHosts&type=SecondaryStorage&page=" + args.page + "&pagesize=" + pageSize + array1.join("")), dataType: "json", @@ -10697,6 +11001,7 @@ detailView: { name: 'Secondary storage details', + isMaximized: true, actions: { remove: { label: 'label.action.delete.secondary.storage' , @@ -10753,6 +11058,27 @@ }); } } + + // Granular settings for storage pool for secondary storage is not required + /* settings: { + title: 'label.menu.global.settings', + custom: cloudStack.uiCustom.granularSettings({ + dataProvider: function(args) { + args.response.success({ + data: [ + { name: 'config.param.1', value: 1 }, + { name: 'config.param.2', value: 2 } + ] + }); + }, + actions: { + edit: function(args) { + // call updateStorageLevelParameters + args.response.success(); + } + } + }) + } */ } } } @@ -11662,9 +11988,9 @@ if (jsonObj.state == 'Running') { allowedActions.push("stop"); - + allowedActions.push("scaleUp"); // if(jsonObj.vpcid != null) - allowedActions.push("restart"); + allowedActions.push("restart"); allowedActions.push("viewConsole"); if (isAdmin()) @@ -11672,7 +11998,8 @@ } else if (jsonObj.state == 'Stopped') { allowedActions.push("start"); - allowedActions.push("remove"); + allowedActions.push("scaleUp"); + allowedActions.push("remove"); if(jsonObj.vpcid != null) allowedActions.push("changeService"); @@ -11687,14 +12014,16 @@ if (jsonObj.state == 'Running') { allowedActions.push("stop"); allowedActions.push("restart"); - allowedActions.push("remove"); + allowedActions.push("remove"); + allowedActions.push("scaleUp"); allowedActions.push("viewConsole"); if (isAdmin()) allowedActions.push("migrate"); } else if (jsonObj.state == 'Stopped') { allowedActions.push("start"); - allowedActions.push("changeService"); + allowedActions.push("scaleUp"); + allowedActions.push("changeService"); allowedActions.push("remove"); } else if (jsonObj.state == 'Error') { diff --git a/ui/scripts/templates.js b/ui/scripts/templates.js index 52e1135c681..91038b904fa 100644 --- a/ui/scripts/templates.js +++ b/ui/scripts/templates.js @@ -116,27 +116,13 @@ dataType: "json", async: true, success: function(json) { - var zoneObjs; - if(args.context.zoneType == null || args.context.zoneType == '') { //all types - zoneObjs = []; - var items = json.listzonesresponse.zone; - if(items != null) { - for(var i = 0; i < items.length; i++) { - zoneObjs.push({id: items[i].id, description: items[i].name}); - } + var zoneObjs= []; + var items = json.listzonesresponse.zone; + if(items != null) { + for(var i = 0; i < items.length; i++) { + zoneObjs.push({id: items[i].id, description: items[i].name}); } - } - else { //Basic type or Advanced type - zoneObjs = []; - var items = json.listzonesresponse.zone; - if(items != null) { - for(var i = 0; i < items.length; i++) { - if(items[i].networktype == args.context.zoneType) { - zoneObjs.push({id: items[i].id, description: items[i].name}); - } - } - } - } + } if (isAdmin() && !(cloudStack.context.projects && cloudStack.context.projects[0])){ zoneObjs.unshift({id: -1, description: "All Zones"}); } @@ -548,27 +534,14 @@ async: true, success: function(json) { var zoneObjs = []; - var items = json.listzonesresponse.zone; - if(args.context.zoneType == null || args.context.zoneType == '') { //all types - if(items != null) { - for(var i = 0; i < items.length; i++) { - if(items[i].id != args.context.templates[0].zoneid) { //destination zone must be different from source zone - zoneObjs.push({id: items[i].id, description: items[i].name}); - } - } + var items = json.listzonesresponse.zone; + if(items != null) { + for(var i = 0; i < items.length; i++) { + if(items[i].id != args.context.templates[0].zoneid) { //destination zone must be different from source zone + zoneObjs.push({id: items[i].id, description: items[i].name}); + } } - } - else { //Basic type or Advanced type - if(items != null) { - for(var i = 0; i < items.length; i++) { - if(items[i].networktype == args.context.zoneType) { //type must be matched - if(items[i].id != args.context.templates[0].zoneid) { //destination zone must be different from source zone - zoneObjs.push({id: items[i].id, description: items[i].name}); - } - } - } - } - } + } args.response.success({data: zoneObjs}); } }); @@ -894,27 +867,13 @@ dataType: "json", async: true, success: function(json) { - var zoneObjs; - if(args.context.zoneType == null || args.context.zoneType == '') { //all types - zoneObjs = []; - var items = json.listzonesresponse.zone; - if(items != null) { - for(var i = 0; i < items.length; i++) { - zoneObjs.push({id: items[i].id, description: items[i].name}); - } + var zoneObjs = []; + var items = json.listzonesresponse.zone; + if(items != null) { + for(var i = 0; i < items.length; i++) { + zoneObjs.push({id: items[i].id, description: items[i].name}); } - } - else { //Basic type or Advanced type - zoneObjs = []; - var items = json.listzonesresponse.zone; - if(items != null) { - for(var i = 0; i < items.length; i++) { - if(items[i].networktype == args.context.zoneType) { - zoneObjs.push({id: items[i].id, description: items[i].name}); - } - } - } - } + } if (isAdmin() && !(cloudStack.context.projects && cloudStack.context.projects[0])){ zoneObjs.unshift({id: -1, description: "All Zones"}); } @@ -1224,27 +1183,14 @@ async: true, success: function(json) { var zoneObjs = []; - var items = json.listzonesresponse.zone; - if(args.context.zoneType == null || args.context.zoneType == '') { //all types - if(items != null) { - for(var i = 0; i < items.length; i++) { - if(items[i].id != args.context.isos[0].zoneid) { //destination zone must be different from source zone - zoneObjs.push({id: items[i].id, description: items[i].name}); - } - } + var items = json.listzonesresponse.zone; + if(items != null) { + for(var i = 0; i < items.length; i++) { + if(items[i].id != args.context.isos[0].zoneid) { //destination zone must be different from source zone + zoneObjs.push({id: items[i].id, description: items[i].name}); + } } - } - else { //Basic type or Advanced type - if(items != null) { - for(var i = 0; i < items.length; i++) { - if(items[i].networktype == args.context.zoneType) { //type must be matched - if(items[i].id != args.context.isos[0].zoneid) { //destination zone must be different from source zone - zoneObjs.push({id: items[i].id, description: items[i].name}); - } - } - } - } - } + } args.response.success({data: zoneObjs}); } }); diff --git a/vmware-base/test/com/cloud/hypervisor/vmware/mo/TestVmwareMO.java b/ui/scripts/ui-custom/granularSettings.js similarity index 52% rename from vmware-base/test/com/cloud/hypervisor/vmware/mo/TestVmwareMO.java rename to ui/scripts/ui-custom/granularSettings.js index c9807f443f1..02d5c1fcbaa 100644 --- a/vmware-base/test/com/cloud/hypervisor/vmware/mo/TestVmwareMO.java +++ b/ui/scripts/ui-custom/granularSettings.js @@ -14,26 +14,33 @@ // KIND, either express or implied. See the License for the // specific language governing permissions and limitations // under the License. -package com.cloud.hypervisor.vmware.mo; -import java.util.GregorianCalendar; - -import org.apache.log4j.Logger; - -import com.cloud.hypervisor.vmware.mo.SnapshotDescriptor.SnapshotInfo; -import com.cloud.hypervisor.vmware.util.VmwareContext; -import com.cloud.utils.Pair; -import com.cloud.utils.testcase.Log4jEnabledTestCase; -import com.google.gson.Gson; -import com.vmware.vim25.DynamicProperty; -import com.vmware.vim25.ManagedObjectReference; -import com.vmware.vim25.ObjectContent; -import com.vmware.vim25.VirtualMachineConfigSpec; - -public class TestVmwareMO extends Log4jEnabledTestCase { - private static final Logger s_logger = Logger.getLogger(TestVmwareMO.class); - - public void test() { +(function($, cloudStack) { + cloudStack.uiCustom.granularSettings = function(args) { + var dataProvider = args.dataProvider; + var actions = args.actions; + + return function(args) { + var context = args.context; + + var listView = { + id: 'settings', + fields: { + name: { label: 'label.name' }, + value: { label: 'label.value', editable: true } + }, + actions: { + edit: { + label: 'label.change.value', + action: actions.edit + } + }, + dataProvider: dataProvider + }; + + var $listView = $('
').listView({ context: context, listView: listView }); + + return $listView; } -} - + }; +}(jQuery, cloudStack)); diff --git a/ui/scripts/ui-custom/instanceWizard.js b/ui/scripts/ui-custom/instanceWizard.js index 2cb352aa53a..ea7acf8dca5 100644 --- a/ui/scripts/ui-custom/instanceWizard.js +++ b/ui/scripts/ui-custom/instanceWizard.js @@ -86,7 +86,7 @@ }); }; - var makeSelects = function(name, data, fields, options) { + var makeSelects = function(name, data, fields, options, selectedObj) { var $selects = $('
'); options = options ? options : {}; @@ -151,7 +151,11 @@ .append($('
').addClass('desc').html(_s(this[fields.desc]))) ) .data('json-obj', this); - + + if(selectedObj != null && selectedObj.id == item.id) { + $select.find('input[type=checkbox]').attr('checked', 'checked'); + } + $selects.append($select); if (item._singleSelect) { @@ -485,17 +489,32 @@ 'affinity': function($step, formData) { return { response: { - success: function(args) { - $step.find('.select-container').append( - makeSelects('affinity-groups', args.data.affinityGroups, { - name: 'name', - desc: 'description', - id: 'id' - }, { - type: 'checkbox', - 'wizard-field': 'affinity-groups' - }) - ); + success: function(args) { + if (args.data.affinityGroups && args.data.affinityGroups.length) { + $step.prepend( + $('
').addClass('main-desc').append( + $('

').html(_l('message.select.affinity.groups')) + ) + ); + $step.find('.select-container').append( + makeSelects( + 'affinity-groups', + args.data.affinityGroups, + { + name: 'name', + desc: 'description', + id: 'id' + }, + { + type: 'checkbox', + 'wizard-field': 'affinity-groups' + }, + args.data.selectedObj + ) + ); + } else { + $step.find('.select-container').append($('

').html(_l('message.no.affinity.groups'))); + } } } }; diff --git a/ui/scripts/ui-custom/vpc.js b/ui/scripts/ui-custom/vpc.js index 2bd26b11f1a..4edccf10211 100644 --- a/ui/scripts/ui-custom/vpc.js +++ b/ui/scripts/ui-custom/vpc.js @@ -152,6 +152,7 @@ addAction.action({ data: data, + $form:args.$form, context: gateways.context, response: { success: function(args) { diff --git a/ui/scripts/ui/widgets/detailView.js b/ui/scripts/ui/widgets/detailView.js index 0146b362948..a721a44ec05 100644 --- a/ui/scripts/ui/widgets/detailView.js +++ b/ui/scripts/ui/widgets/detailView.js @@ -62,13 +62,15 @@ * Default behavior for actions -- just show a confirmation popup and add notification */ standard: function($detailView, args, additional) { - var action = args.actions[args.actionName]; + var tab = args.tabs[args.activeTab]; + var isMultiple = tab.multiple; + var action = isMultiple ? tab.actions[args.actionName] : args.actions[args.actionName]; var preAction = action.preAction; var notification = action.notification ? action.notification : {}; var messages = action.messages; var id = args.id; - var context = $detailView.data('view-args').context; + var context = args.context ? args.context : $detailView.data('view-args').context; var _custom = $detailView.data('_custom'); var customAction = action.action.custom; var noAdd = action.noAdd; @@ -178,7 +180,7 @@ data: data, _custom: _custom, ref: options.ref, - context: $detailView.data('view-args').context, + context: context, $form: $form, response: { success: function(args) { @@ -197,7 +199,11 @@ $loading.remove(); if (!noRefresh && !viewArgs.compact) { - updateTabContent(args.data? args.data : args2.data); + if (isMultiple) { + $detailView.find('.refresh').click(); + } else { + updateTabContent(args.data? args.data : args2.data); + } } } @@ -286,43 +292,50 @@ after: function(args) { performAction(args.data, { ref: args.ref, - context: $detailView.data('view-args').context, + context: context, $form: args.$form }); }, ref: { id: id }, - context: $detailView.data('view-args').context + context: context }); } } }, remove: function($detailView, args) { + var tab = args.tabs[args.activeTab]; + var isMultiple = tab.multiple; + uiActions.standard($detailView, args, { noRefresh: true, complete: function(args) { - var $browser = $('#browser .container'); - var $panel = $detailView.closest('.panel'); + if (isMultiple && $detailView.is(':visible')) { + $detailView.find('.refresh').click(); // Reload tab + } else { + var $browser = $('#browser .container'); + var $panel = $detailView.closest('.panel'); - if ($detailView.is(':visible')) { - $browser.cloudBrowser('selectPanel', { - panel: $panel.prev() - }); - } - - if($detailView.data("list-view-row") != null) { - var $row = $detailView.data('list-view-row'); - var $tbody = $row.closest('tbody'); - - $row.remove(); - if(!$tbody.find('tr').size()) { - $("").addClass('empty').append( - $("").html(_l('label.no.data')) - ).appendTo($tbody); + if ($detailView.is(':visible')) { + $browser.cloudBrowser('selectPanel', { + panel: $panel.prev() + }); + } + + if($detailView.data("list-view-row") != null) { + var $row = $detailView.data('list-view-row'); + var $tbody = $row.closest('tbody'); + + $row.remove(); + if(!$tbody.find('tr').size()) { + $("").addClass('empty').append( + $("").html(_l('label.no.data')) + ).appendTo($tbody); + } + $tbody.closest('table').dataTable('refresh'); } - $tbody.closest('table').dataTable('refresh'); } } }); @@ -707,7 +720,10 @@ $.each(actions, function(key, value) { if ($.inArray(key, allowedActions) == -1 || - (key == 'edit' && options.compact)) return true; + (options.ignoreAddAction && key == 'add') || + (key == 'edit' && options.compact)) { + return true; + } var $action = $('

') .addClass('action').addClass(key) @@ -778,11 +794,13 @@ var detailViewArgs = $detailView.data('view-args'); var fields = tabData.fields; var hiddenFields; - var context = detailViewArgs ? detailViewArgs.context : cloudStack.context; + var context = $.extend(true, {}, detailViewArgs ? detailViewArgs.context : cloudStack.context); var isMultiple = tabData.multiple || tabData.isMultiple; + var actions = tabData.actions; if (isMultiple) { - context[tabData.id] = data; + context[tabData.id] = [data]; + $detailGroups.data('item-context', context); } // Make header @@ -992,7 +1010,8 @@ $tabContent.html(''); var targetTabID = $tabContent.data('detail-view-tab-id'); - var tabs = args.tabs[targetTabID]; + var tabList = args.tabs; + var tabs = tabList[targetTabID]; var dataProvider = tabs.dataProvider; var isMultiple = tabs.multiple || tabs.isMultiple; var viewAllArgs = args.viewAll; @@ -1073,7 +1092,11 @@ tabData.viewAll.path, { updateContext: function(args) { - return { nics: [item] }; + var obj = {}; + + obj[targetTabID] = [item]; + + return obj; }, title: tabData.viewAll.title } @@ -1081,8 +1104,52 @@ }) ); } + + // Add action bar + if (tabData.multiple && tabData.actions) { + var $actions = makeActionButtons(tabData.actions, { + actionFilter: actionFilter, + data: item, + context: $.extend(true, {}, $detailView.data('view-args').context, { + item: [item] + }), + ignoreAddAction: true + }); + + $fieldContent.find('th').append($actions); + } }); + // Add item action + if (tabData.multiple && tabData.actions && tabData.actions.add) { + $tabContent.prepend( + $('
').addClass('button add').append( + $('').addClass('icon').html(' '), + $('').html(_l(tabData.actions.add.label)) + ).click(function() { + uiActions.standard( + $detailView, + { + tabs: tabList, + activeTab: targetTabID, + actions: tabData.actions, + actionName: 'add' + }, { + noRefresh: true, + complete: function(args) { + if ($detailView.is(':visible')) { + loadTabContent( + $detailView.find('div.detail-group:visible'), + $detailView.data('view-args') + ); + } + } + } + ) + }) + ); + } + return true; } @@ -1301,9 +1368,10 @@ var $action = $target.closest('.action').find('[detail-action]'); var actionName = $action.attr('detail-action'); var actionCallback = $action.data('detail-view-action-callback'); - var detailViewArgs = $action.closest('div.detail-view').data('view-args'); + var detailViewArgs = $.extend(true, {}, $action.closest('div.detail-view').data('view-args')); var additionalArgs = {}; var actionSet = uiActions; + var $details = $action.closest('.details'); var uiCallback = actionSet[actionName]; if (!uiCallback) @@ -1311,6 +1379,10 @@ detailViewArgs.actionName = actionName; + if ($details.data('item-context')) { + detailViewArgs.context = $details.data('item-context'); + } + uiCallback($target.closest('div.detail-view'), detailViewArgs, additionalArgs); return false; diff --git a/ui/scripts/ui/widgets/listView.js b/ui/scripts/ui/widgets/listView.js index f368951f256..0d5ef6fc751 100644 --- a/ui/scripts/ui/widgets/listView.js +++ b/ui/scripts/ui/widgets/listView.js @@ -1687,6 +1687,9 @@ return false; }); + var tableHeight = $table.height(); + var endTable = false; + // Infinite scrolling event $listView.bind('scroll', function(event) { if (args.listView && args.listView.disableInfiniteScrolling) return false; @@ -1697,7 +1700,7 @@ var loadMoreData = $listView.scrollTop() >= ($table.height() - $listView.height()) - $listView.height() / 4; var context = $listView.data('view-args').context; - if (loadMoreData) { + if (loadMoreData && !endTable) { page = page + 1; var filterBy = { @@ -1725,6 +1728,7 @@ reorder: listViewData.reorder, detailView: listViewData.detailView }); + $table.height() == tableHeight ? endTable = true : tableHeight = $table.height(); } }, 500); diff --git a/ui/scripts/ui/widgets/multiEdit.js b/ui/scripts/ui/widgets/multiEdit.js index 27b14d16e61..a1272fda31c 100755 --- a/ui/scripts/ui/widgets/multiEdit.js +++ b/ui/scripts/ui/widgets/multiEdit.js @@ -653,6 +653,11 @@ }); }); + var itemState=multiRule._itemState ? item[multiRule._itemState] :item.state; + var $itemState = $('').html(_s(itemState)); + $tr.append($('').addClass('state').appendTo($tr).append("Application State - ").append($itemState)); + + if (itemActions) { var $itemActions = $('').addClass('actions item-actions'); diff --git a/ui/scripts/vm_snapshots.js b/ui/scripts/vm_snapshots.js index 0d6305bfbe4..190bf7521f3 100644 --- a/ui/scripts/vm_snapshots.js +++ b/ui/scripts/vm_snapshots.js @@ -170,7 +170,7 @@ }, action: function(args) { $.ajax({ - url: createURL("revertToSnapshot&vmsnapshotid=" + args.context.vmsnapshots[0].id), + url: createURL("revertToVMSnapshot&vmsnapshotid=" + args.context.vmsnapshots[0].id), dataType: "json", async: true, success: function(json) { diff --git a/ui/scripts/vpc.js b/ui/scripts/vpc.js index a4834f26c72..17cf42a5e91 100644 --- a/ui/scripts/vpc.js +++ b/ui/scripts/vpc.js @@ -48,6 +48,22 @@ return name != 'icmptype' && name != 'icmpcode' && name != 'cidrlist'; }); + var $protocolinput = args.$form.find('th,td'); + var $protocolFields = $protocolinput.filter(function(){ + var name = $(this).attr('rel'); + + return $.inArray(name,['protocolnumber']) > -1; + }); + + if($(this).val() == 'protocolnumber' ){ + + $protocolFields.show(); + } + else{ + $protocolFields.hide(); + } + + if ($(this).val() == 'icmp') { $icmpFields.show(); $icmpFields.attr('disabled', false); @@ -68,11 +84,16 @@ data: [ { name: 'tcp', description: 'TCP' }, { name: 'udp', description: 'UDP' }, - { name: 'icmp', description: 'ICMP' } + { name: 'icmp', description: 'ICMP' }, + { name: 'all', description: 'ALL'}, + { name: 'protocolnumber', description: 'Protocol Number'} + ] }); } }, + + 'protocolnumber': {label:'Protocol Number',isDisabled:true,isHidden:true,edit:true}, 'startport': { edit: true, label: 'label.start.port' }, 'endport': { edit: true, label: 'label.end.port' }, 'networkid': { @@ -136,7 +157,15 @@ label: 'label.add', action: function(args) { var $multi = args.$multi; - + //Support for Protocol Number between 0 to 255 + if(args.data.protocol == 'protocolnumber'){ + $.extend(args.data,{protocol:args.data.protocolnumber}); + delete args.data.protocolnumber; + } + else + delete args.data.protocolnumber; + + $.ajax({ url: createURL('createNetworkACL'), data: $.extend(args.data, { @@ -688,12 +717,28 @@ netmask: { label: 'label.netmask', validation: { required: true }, docID: 'helpVPCGatewayNetmask' + }, + sourceNat:{ + label:'Source NAT', + isBoolean:true, + isChecked:false + } + + } }, action: function(args) { + var array1=[]; + if(args.$form.find('.form-item[rel=sourceNat]').find('input[type=checkbox]').is(':Checked')== true) { + array1.push("&sourcenatsupported=true"); + } + else + array1.push("&sourcenatsupported=false"); + + $.ajax({ - url: createURL('createPrivateGateway'), + url: createURL('createPrivateGateway'+ array1.join("")), data: { physicalnetworkid: args.data.physicalnetworkid, vpcid: args.context.vpc[0].id, @@ -737,6 +782,12 @@ actions:{ add:{ label:'Add Private Gateway', + preFilter: function(args) { + if(isAdmin() || isDomainAdmin() ) + return true; + else + return false; + }, createForm:{ title: 'label.add.new.gateway', desc: 'message.add.new.gateway.to.vpc', @@ -776,15 +827,32 @@ netmask: { label: 'label.netmask', validation: { required: true }, docID: 'helpVPCGatewayNetmask' + }, + + sourceNat:{ + label:'Source NAT', + isBoolean:true, + isChecked:false + } + } }, action:function(args){ + + var array1=[]; + if(args.$form.find('.form-item[rel=sourceNat]').find('input[type=checkbox]').is(':Checked')== true) { + array1.push("&sourcenatsupported=true"); + } + else + array1.push("&sourcenatsupported=false"); + + $.ajax({ - url: createURL('createPrivateGateway'), + url: createURL('createPrivateGateway'+ array1.join("")), data: { physicalnetworkid: args.data.physicalnetworkid, vpcid: args.context.vpc[0].id, diff --git a/ui/scripts/zoneWizard.js b/ui/scripts/zoneWizard.js index b28258544b7..9b28c327b78 100755 --- a/ui/scripts/zoneWizard.js +++ b/ui/scripts/zoneWizard.js @@ -2376,6 +2376,110 @@ }); // ***** Virtual Router ***** (end) ***** + // ***** Internal LB ***** (begin) ***** + var internalLbProviderId; + $.ajax({ + url: createURL("listNetworkServiceProviders&name=Internallbvm&physicalNetworkId=" + thisPhysicalNetwork.id), + dataType: "json", + async: false, + success: function(json) { + var items = json.listnetworkserviceprovidersresponse.networkserviceprovider; + if(items != null && items.length > 0) { + internalLbProviderId = items[0].id; + } + } + }); + if(internalLbProviderId == null) { + alert("error: listNetworkServiceProviders API doesn't return internalLb provider ID"); + return; + } + + var internalLbElementId; + $.ajax({ + url: createURL("listInternalLoadBalancerElements&nspid=" + internalLbProviderId), + dataType: "json", + async: false, + success: function(json) { + var items = json.listinternalloadbalancerelementsresponse.internalloadbalancerelement; + if(items != null && items.length > 0) { + internalLbElementId = items[0].id; + } + } + }); + if(internalLbElementId == null) { + alert("error: listInternalLoadBalancerElements API doesn't return Internal LB Element Id"); + return; + } + + $.ajax({ + url: createURL("configureInternalLoadBalancerElement&enabled=true&id=" + internalLbElementId), + dataType: "json", + async: false, + success: function(json) { + var jobId = json.configureinternalloadbalancerelementresponse.jobid; + var enableInternalLbElementIntervalID = setInterval(function() { + $.ajax({ + url: createURL("queryAsyncJobResult&jobId="+jobId), + dataType: "json", + success: function(json) { + var result = json.queryasyncjobresultresponse; + if (result.jobstatus == 0) { + return; //Job has not completed + } + else { + clearInterval(enableInternalLbElementIntervalID); + + if (result.jobstatus == 1) { //configureVirtualRouterElement succeeded + $.ajax({ + url: createURL("updateNetworkServiceProvider&state=Enabled&id=" + internalLbProviderId), + dataType: "json", + async: false, + success: function(json) { + var jobId = json.updatenetworkserviceproviderresponse.jobid; + var enableInternalLbProviderIntervalID = setInterval(function() { + $.ajax({ + url: createURL("queryAsyncJobResult&jobId="+jobId), + dataType: "json", + success: function(json) { + var result = json.queryasyncjobresultresponse; + if (result.jobstatus == 0) { + return; //Job has not completed + } + else { + clearInterval(enableInternalLbProviderIntervalID); + + if (result.jobstatus == 1) { //Internal LB has been enabled successfully + //don't need to do anything here + } + else if (result.jobstatus == 2) { + alert("failed to enable Internal LB Provider. Error: " + _s(result.jobresult.errortext)); + } + } + }, + error: function(XMLHttpResponse) { + var errorMsg = parseXMLHttpResponse(XMLHttpResponse); + alert("failed to enable Internal LB Provider. Error: " + errorMsg); + } + }); + }, g_queryAsyncJobResultInterval); + } + }); + } + else if (result.jobstatus == 2) { + alert("configureVirtualRouterElement failed. Error: " + _s(result.jobresult.errortext)); + } + } + }, + error: function(XMLHttpResponse) { + var errorMsg = parseXMLHttpResponse(XMLHttpResponse); + alert("configureVirtualRouterElement failed. Error: " + errorMsg); + } + }); + }, g_queryAsyncJobResultInterval); + } + }); + // ***** Internal LB ***** (end) ***** + if(args.data.zone.sgEnabled != true) { //Advanced SG-disabled zone // ***** VPC Virtual Router ***** (begin) ***** var vpcVirtualRouterProviderId; diff --git a/usage/test/com/cloud/usage/UsageManagerTestConfiguration.java b/usage/test/com/cloud/usage/UsageManagerTestConfiguration.java index d7cf04644b8..1d3ed7b245d 100644 --- a/usage/test/com/cloud/usage/UsageManagerTestConfiguration.java +++ b/usage/test/com/cloud/usage/UsageManagerTestConfiguration.java @@ -25,7 +25,8 @@ import com.cloud.usage.dao.*; import com.cloud.usage.parser.*; import com.cloud.user.dao.AccountDaoImpl; import com.cloud.user.dao.UserStatisticsDaoImpl; -import com.cloud.utils.component.SpringComponentScanUtils; + +import org.apache.cloudstack.test.utils.SpringUtils; import org.mockito.Mockito; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.ComponentScan; @@ -87,7 +88,7 @@ public class UsageManagerTestConfiguration { public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException { mdr.getClassMetadata().getClassName(); ComponentScan cs = UsageManagerTestConfiguration.class.getAnnotation(ComponentScan.class); - return SpringComponentScanUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); + return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs); } } diff --git a/utils/pom.xml b/utils/pom.xml index d4bafbdcaf0..0690c35c57b 100644 --- a/utils/pom.xml +++ b/utils/pom.xml @@ -73,11 +73,12 @@ commons-discovery ${cs.discovery.version} - + commons-logging commons-logging @@ -172,15 +173,6 @@ ${project.basedir}/test/resources - org.apache.maven.plugins diff --git a/server/src/com/cloud/maint/Version.java b/utils/src/com/cloud/maint/Version.java similarity index 100% rename from server/src/com/cloud/maint/Version.java rename to utils/src/com/cloud/maint/Version.java diff --git a/utils/src/com/cloud/utils/AnnotationHelper.java b/utils/src/com/cloud/utils/AnnotationHelper.java index 954b870eb76..e7a6166677e 100755 --- a/utils/src/com/cloud/utils/AnnotationHelper.java +++ b/utils/src/com/cloud/utils/AnnotationHelper.java @@ -20,40 +20,38 @@ import javax.persistence.Table; import org.apache.log4j.Logger; -import com.cloud.utils.exception.CSExceptionErrorCode; - public class AnnotationHelper extends Object { // This class contains routines to help query annotation elements of objects. - + public static final Logger s_logger = Logger.getLogger(AnnotationHelper.class.getName()); - + public static String getTableName(Object proxyObj) { // The cglib class is generated by cglib during runtime. - + Class curClass = proxyObj.getClass(); if (curClass == null) { - s_logger.info("\nCould not retrieve class information for proxy object\n"); + s_logger.trace("Could not retrieve class information for proxy object"); return null; } - + while (curClass.getSuperclass() != null && curClass.getSuperclass().getName() != "java.lang.Object") { curClass = curClass.getSuperclass(); } // At this point, curClass is the root base class of proxyObj's class, and curClass is not java.lang.Object. - Table tabObj = (Table)curClass.getAnnotation(Table.class); + Table tabObj = curClass.getAnnotation(Table.class); if (tabObj == null) { - s_logger.info("\n" + curClass + "does not have a Table annotation\n"); + s_logger.trace(curClass + "does not have a Table annotation"); return null; } - + return tabObj.name(); } - + } - - - - + + + + diff --git a/utils/src/com/cloud/utils/cisco/n1kv/vsm/VsmCommand.java b/utils/src/com/cloud/utils/cisco/n1kv/vsm/VsmCommand.java index fdab390557d..d86b7100658 100644 --- a/utils/src/com/cloud/utils/cisco/n1kv/vsm/VsmCommand.java +++ b/utils/src/com/cloud/utils/cisco/n1kv/vsm/VsmCommand.java @@ -546,10 +546,15 @@ public class VsmCommand { vmware.appendChild(portgroup); portProf.appendChild(vmware); - // org root/%vdc% + // org %vdc% // vservice node profile + Element vdcValue = doc.createElement(s_paramvalue); + vdcValue.setAttribute("isKey", "true"); + vdcValue.setTextContent(vdc); + Element org = doc.createElement("org"); - org.appendChild(doc.createElement(vdc)); + org.appendChild(doc.createElement("orgname")) + .appendChild(vdcValue); portProf.appendChild(org); String asaNodeName = "ASA_" + vlanid; diff --git a/utils/src/com/cloud/utils/component/SpringComponentScanUtils.java b/utils/src/com/cloud/utils/component/SpringComponentScanUtils.java deleted file mode 100644 index 28b84e68ce9..00000000000 --- a/utils/src/com/cloud/utils/component/SpringComponentScanUtils.java +++ /dev/null @@ -1,41 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. - -package com.cloud.utils.component; - -import org.springframework.context.annotation.ComponentScan; - -import com.cloud.utils.exception.CloudRuntimeException; - -public class SpringComponentScanUtils { - - public static boolean includedInBasePackageClasses(String clazzName, ComponentScan cs) { - Class clazzToCheck; - try { - clazzToCheck = Class.forName(clazzName); - } catch (ClassNotFoundException e) { - throw new CloudRuntimeException("Unable to find " + clazzName); - } - Class[] clazzes = cs.basePackageClasses(); - for (Class clazz : clazzes) { - if (clazzToCheck.isAssignableFrom(clazz)) { - return true; - } - } - return false; - } -} diff --git a/utils/src/com/cloud/utils/net/NetUtils.java b/utils/src/com/cloud/utils/net/NetUtils.java index 77c593af84f..46f086d0e58 100755 --- a/utils/src/com/cloud/utils/net/NetUtils.java +++ b/utils/src/com/cloud/utils/net/NetUtils.java @@ -627,7 +627,7 @@ public class NetUtils { return result; } - public static Set getAllIpsFromCidr(String cidr, long size) { + public static Set getAllIpsFromCidr(String cidr, long size, Set usedIps) { assert (size < 32) : "You do know this is not for ipv6 right? Keep it smaller than 32 but you have " + size; Set result = new TreeSet(); long ip = ip2Long(cidr); @@ -639,8 +639,12 @@ public class NetUtils { end++; end = (end << (32 - size)) - 2; - while (start <= end) { - result.add(start); + int maxIps = 255; // get 255 ips as maximum + while (start <= end && maxIps > 0) { + if (!usedIps.contains(start)){ + result.add(start); + maxIps--; + } start++; } diff --git a/utils/src/org/apache/cloudstack/test/utils/SpringUtils.java b/utils/src/org/apache/cloudstack/test/utils/SpringUtils.java new file mode 100644 index 00000000000..220bd80e8d3 --- /dev/null +++ b/utils/src/org/apache/cloudstack/test/utils/SpringUtils.java @@ -0,0 +1,113 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.cloudstack.test.utils; + +import java.util.ArrayList; +import java.util.List; + +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.ComponentScan; + +import com.cloud.utils.component.ComponentContext; +import com.cloud.utils.component.ComponentInstantiationPostProcessor; +import com.cloud.utils.component.ComponentMethodInterceptor; +import com.cloud.utils.db.TransactionContextBuilder; +import com.cloud.utils.exception.CloudRuntimeException; + +public class SpringUtils { + + /** + * This method allows you to use @ComponentScan for your unit testing but + * it limits the scope of the classes found to the class specified in + * the @ComponentScan annotation. + * + * Without using this method, the default behavior of @ComponentScan is + * to actually scan in the package of the class specified rather than + * only the class. This can cause extra classes to be loaded which causes + * the classes these extra classes depend on to be loaded. The end effect + * is often most of the project gets loaded. + * + * In order to use this method properly, you must do the following:
  • + * - Specify @ComponentScan with basePackageClasses, includeFilters, and + * useDefaultFilters=true. See the following example. + * + *
    +     *     @ComponentScan(basePackageClasses={AffinityGroupServiceImpl.class, EventUtils.class},
    +     *     includeFilters={@Filter(value=TestConfiguration.Library.class, type=FilterType.CUSTOM)},
    +     *     useDefaultFilters=false)
    +     * 
    + * + * - Create a Library class and use that to call this method. See the + * following example. The Library class you define here is the Library + * class being added in the filter above. + * + *
    +     * public static class Library implements TypeFilter {
    +     *      @Override
    +     *      public boolean match(MetadataReader mdr, MetadataReaderFactory arg1) throws IOException {
    +     *          ComponentScan cs = TestConfiguration.class.getAnnotation(ComponentScan.class);
    +     *          return SpringUtils.includedInBasePackageClasses(mdr.getClassMetadata().getClassName(), cs);
    +     *      }
    +     * }
    +     * 
    + * + * @param clazzName name of the class that should be included in the Spring components + * @param cs ComponentScan annotation that was declared on the configuration + * + * @return + */ + public static boolean includedInBasePackageClasses(String clazzName, ComponentScan cs) { + Class clazzToCheck; + try { + clazzToCheck = Class.forName(clazzName); + } catch (ClassNotFoundException e) { + throw new CloudRuntimeException("Unable to find " + clazzName); + } + Class[] clazzes = cs.basePackageClasses(); + for (Class clazz : clazzes) { + if (clazzToCheck.isAssignableFrom(clazz)) { + return true; + } + } + return false; + } + + public static class CloudStackTestConfiguration { + + @Bean + public ComponentContext componentContext() { + return new ComponentContext(); + } + + @Bean + public TransactionContextBuilder transactionContextBuilder() { + return new TransactionContextBuilder(); + } + + @Bean + public ComponentInstantiationPostProcessor instantiatePostProcessor() { + ComponentInstantiationPostProcessor processor = new ComponentInstantiationPostProcessor(); + + List interceptors = new ArrayList(); + interceptors.add(new TransactionContextBuilder()); + processor.setInterceptors(interceptors); + + return processor; + } + } +} diff --git a/vmware-base/pom.xml b/vmware-base/pom.xml index 8fa811fb3f2..da4fb21c713 100644 --- a/vmware-base/pom.xml +++ b/vmware-base/pom.xml @@ -59,8 +59,4 @@ 1.4 - - install - src - diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/mo/VirtualMachineMO.java b/vmware-base/src/com/cloud/hypervisor/vmware/mo/VirtualMachineMO.java index 4503349edf1..660d9632baa 100644 --- a/vmware-base/src/com/cloud/hypervisor/vmware/mo/VirtualMachineMO.java +++ b/vmware-base/src/com/cloud/hypervisor/vmware/mo/VirtualMachineMO.java @@ -1281,6 +1281,7 @@ public class VirtualMachineMO extends BaseMO { long totalBytesDownloaded = 0; List deviceUrls = leaseInfo.getDeviceUrl(); + s_logger.info("volss: copy vmdk and ovf file starts " + System.currentTimeMillis()); if(deviceUrls != null) { OvfFile[] ovfFiles = new OvfFile[deviceUrls.size()]; for (int i = 0; i < deviceUrls.size(); i++) { @@ -1328,7 +1329,7 @@ public class VirtualMachineMO extends BaseMO { // tar files into OVA if(packToOva) { - // Important! we need to sync file system before we can safely use tar to work around a linux kernal bug(or feature) + // Important! we need to sync file system before we can safely use tar to work around a linux kernal bug(or feature) s_logger.info("Sync file system before we package OVA..."); Script commandSync = new Script(true, "sync", 0, s_logger); @@ -1351,8 +1352,11 @@ public class VirtualMachineMO extends BaseMO { } else { s_logger.error(exportDir + File.separator + exportName + ".ova is not created as expected"); } + } else { + success = true; } } + s_logger.info("volss: copy vmdk and ovf file finishes " + System.currentTimeMillis()); } catch(Throwable e) { s_logger.error("Unexpected exception ", e); } finally { diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareClient.java b/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareClient.java index e69a3d26c56..87c79096d60 100644 --- a/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareClient.java +++ b/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareClient.java @@ -528,7 +528,7 @@ public class VmwareClient { PropertySpec pSpec = new PropertySpec(); pSpec.setType(type); pSpec.setAll(false); - pSpec.getPathSet().add(name); + pSpec.getPathSet().add("name"); ObjectSpec oSpec = new ObjectSpec(); oSpec.setObj(root); diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareGuestOsMapper.java b/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareGuestOsMapper.java index c76ce84bc3d..eb16141045a 100755 --- a/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareGuestOsMapper.java +++ b/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareGuestOsMapper.java @@ -58,14 +58,14 @@ public class VmwareGuestOsMapper { s_mapper.put("Windows Server 2008 (32-bit)", VirtualMachineGuestOsIdentifier.WIN_LONGHORN_GUEST); s_mapper.put("Windows Server 2008 (64-bit)", VirtualMachineGuestOsIdentifier.WIN_LONGHORN_64_GUEST); - s_mapper.put("Windows 8", VirtualMachineGuestOsIdentifier.WINDOWS_8_GUEST); - s_mapper.put("Windows 8 (64 bit)", VirtualMachineGuestOsIdentifier.WINDOWS_8_64_GUEST); - s_mapper.put("Windows 8 Server (64 bit)", VirtualMachineGuestOsIdentifier.WINDOWS_8_SERVER_64_GUEST); + s_mapper.put("Windows 8 (32-bit)", VirtualMachineGuestOsIdentifier.WINDOWS_8_GUEST); + s_mapper.put("Windows 8 (64-bit)", VirtualMachineGuestOsIdentifier.WINDOWS_8_64_GUEST); + s_mapper.put("Windows Server 8 (64-bit)", VirtualMachineGuestOsIdentifier.WINDOWS_8_SERVER_64_GUEST); - s_mapper.put("Apple Mac OS X 10.6 (32 bits)", VirtualMachineGuestOsIdentifier.DARWIN_10_GUEST); - s_mapper.put("Apple Mac OS X 10.6 (64 bits)", VirtualMachineGuestOsIdentifier.DARWIN_10_64_GUEST); - s_mapper.put("Apple Mac OS X 10.7 (32 bits)", VirtualMachineGuestOsIdentifier.DARWIN_11_GUEST); - s_mapper.put("Apple Mac OS X 10.7 (64 bits)", VirtualMachineGuestOsIdentifier.DARWIN_11_64_GUEST); + s_mapper.put("Apple Mac OS X 10.6 (32-bit)", VirtualMachineGuestOsIdentifier.DARWIN_10_GUEST); + s_mapper.put("Apple Mac OS X 10.6 (64-bit)", VirtualMachineGuestOsIdentifier.DARWIN_10_64_GUEST); + s_mapper.put("Apple Mac OS X 10.7 (32-bit)", VirtualMachineGuestOsIdentifier.DARWIN_11_GUEST); + s_mapper.put("Apple Mac OS X 10.7 (64-bit)", VirtualMachineGuestOsIdentifier.DARWIN_11_64_GUEST); s_mapper.put("Open Enterprise Server", VirtualMachineGuestOsIdentifier.OES_GUEST); diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareHelper.java b/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareHelper.java index 9c467dc8b6b..4a6a135a5b8 100644 --- a/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareHelper.java +++ b/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareHelper.java @@ -524,7 +524,31 @@ public class VmwareHelper { return options; } - public static void setBasicVmConfig(VirtualMachineConfigSpec vmConfig, int cpuCount, int cpuSpeedMHz, int cpuReservedMhz, + public static void setVmScaleUpConfig(VirtualMachineConfigSpec vmConfig, int cpuCount, int cpuSpeedMHz, int cpuReservedMhz, + int memoryMB, int memoryReserveMB, boolean limitCpuUse) { + + // VM config for scaling up + vmConfig.setMemoryMB((long)memoryMB); + vmConfig.setNumCPUs(cpuCount); + + ResourceAllocationInfo cpuInfo = new ResourceAllocationInfo(); + if (limitCpuUse) { + cpuInfo.setLimit((long)(cpuSpeedMHz * cpuCount)); + } else { + cpuInfo.setLimit(-1L); + } + + cpuInfo.setReservation((long)cpuReservedMhz); + vmConfig.setCpuAllocation(cpuInfo); + + ResourceAllocationInfo memInfo = new ResourceAllocationInfo(); + memInfo.setLimit((long)memoryMB); + memInfo.setReservation((long)memoryReserveMB); + vmConfig.setMemoryAllocation(memInfo); + + } + + public static void setBasicVmConfig(VirtualMachineConfigSpec vmConfig, int cpuCount, int cpuSpeedMHz, int cpuReservedMhz, int memoryMB, int memoryReserveMB, String guestOsIdentifier, boolean limitCpuUse) { // VM config basics diff --git a/vmware-base/test/com/cloud/hypervisor/vmware/mo/TestVmwareContextFactory.java b/vmware-base/test/com/cloud/hypervisor/vmware/mo/TestVmwareContextFactory.java deleted file mode 100644 index 81a62d2993a..00000000000 --- a/vmware-base/test/com/cloud/hypervisor/vmware/mo/TestVmwareContextFactory.java +++ /dev/null @@ -1,43 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.hypervisor.vmware.mo; - -import com.cloud.hypervisor.vmware.util.VmwareClient; -import com.cloud.hypervisor.vmware.util.VmwareContext; - - -public class TestVmwareContextFactory { - private static volatile int s_seq = 1; - - static { - // skip certificate check - System.setProperty("axis.socketSecureFactory", "org.apache.axis.components.net.SunFakeTrustSocketFactory"); - } - - public static VmwareContext create(String vCenterAddress, String vCenterUserName, String vCenterPassword) throws Exception { - assert(vCenterAddress != null); - assert(vCenterUserName != null); - assert(vCenterPassword != null); - - String serviceUrl = "https://" + vCenterAddress + "/sdk/vimService"; - VmwareClient vimClient = new VmwareClient(vCenterAddress + "-" + s_seq++); - vimClient.connect(serviceUrl, vCenterUserName, vCenterPassword); - - VmwareContext context = new VmwareContext(vimClient, vCenterAddress); - return context; - } -} diff --git a/vmware-base/test/com/cloud/hypervisor/vmware/util/TestVmwareUtil.java b/vmware-base/test/com/cloud/hypervisor/vmware/util/TestVmwareUtil.java deleted file mode 100755 index d1dd11b7c8e..00000000000 --- a/vmware-base/test/com/cloud/hypervisor/vmware/util/TestVmwareUtil.java +++ /dev/null @@ -1,107 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.hypervisor.vmware.util; -import java.io.File; - -import junit.framework.Assert; - -import org.apache.log4j.Logger; - -import com.cloud.hypervisor.vmware.resource.SshHelper; -import com.cloud.hypervisor.vmware.resource.VmwareContextFactory; -import com.cloud.utils.Pair; -import com.cloud.utils.testcase.Log4jEnabledTestCase; -import com.vmware.vim25.ManagedObjectReference; - -public class TestVmwareUtil extends Log4jEnabledTestCase { - private static final Logger s_logger = Logger.getLogger(TestVmwareUtil.class); - - public void testContextCreation() { - try { - VmwareContext context = VmwareContextFactory.create("vsphere-1.lab.vmops.com", "Administrator", "Suite219"); - Assert.assertTrue(true); - context.close(); - } catch(Exception e) { - s_logger.error("Unexpected exception : ", e); - } - } - - public void testSearchIndex() { - try { - VmwareContext context = VmwareContextFactory.create("vsphere-1.lab.vmops.com", "Administrator", "Suite219"); - Assert.assertTrue(true); - - ManagedObjectReference morHost = context.getService().findByDnsName(context.getServiceContent().getSearchIndex(), - null, "esxhost-1.lab.vmops.com", false); - Assert.assertTrue(morHost.getType().equalsIgnoreCase("HostSystem")); - - morHost = context.getService().findByIp(context.getServiceContent().getSearchIndex(), - null, "192.168.1.168", false); - Assert.assertTrue(morHost == null); - context.close(); - } catch(Exception e) { - s_logger.error("Unexpected exception : ", e); - } - } - - public void testVmxFileDownload() { - try { - VmwareContext context = VmwareContextFactory.create("vsphere-1.lab.vmops.com", "Administrator", "Suite219"); - byte[] vmxContent = context.getResourceContent("https://vsphere-1.lab.vmops.com/folder/ServerRoom-Fedora32/ServerRoom-Fedora32.vmx?dcPath=cupertino&dsName=NFS%20datastore"); - System.out.print(new String(vmxContent)); - context.close(); - } catch(Exception e) { - s_logger.error("Unexpected exception : ", e); - } - } - - public void testVmxFileParser() { - String[] tokens = "[NFS datastore] Fedora-clone-test/Fedora-clone-test.vmx".split("\\[|\\]|/"); - - for(String str : tokens) { - System.out.println("Token " + str); - } - } - - public void testSsh() { - try { - File file = new File("c:\\temp\\id_rsa.kelven"); - if(!file.exists()) { - System.out.println("key file does not exist!"); - } - - Pair result = SshHelper.sshExecute("192.168.1.107", 22, "kelven", file, null, "ls -al"); - System.out.println("Result: " + result.second()); - } catch(Exception e) { - s_logger.error("Unexpected exception : ", e); - } - } - - public void testScp() { - try { - File file = new File("c:\\temp\\id_rsa.kelven"); - if(!file.exists()) { - System.out.println("key file does not exist!"); - } - - SshHelper.scpTo("192.168.1.107", 22, "kelven", file, null, "~", "Hello, world".getBytes(), - "hello.txt", null); - } catch(Exception e) { - s_logger.error("Unexpected exception : ", e); - } - } -} diff --git a/vmware-base/test/com/cloud/vmware/TestVMWare.java b/vmware-base/test/com/cloud/vmware/TestVMWare.java deleted file mode 100644 index f2d08e17f5a..00000000000 --- a/vmware-base/test/com/cloud/vmware/TestVMWare.java +++ /dev/null @@ -1,1342 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. -package com.cloud.vmware; - -import java.io.BufferedInputStream; -import java.io.BufferedOutputStream; -import java.io.BufferedReader; -import java.io.File; -import java.io.FileInputStream; -import java.io.IOException; -import java.io.InputStreamReader; -import java.net.URL; -import java.rmi.RemoteException; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import javax.net.ssl.HostnameVerifier; -import javax.net.ssl.HttpsURLConnection; -import javax.net.ssl.SSLSession; - -import org.apache.log4j.xml.DOMConfigurator; - -import com.cloud.hypervisor.vmware.mo.DatacenterMO; -import com.cloud.hypervisor.vmware.mo.DistributedVirtualSwitchMO; -import com.cloud.hypervisor.vmware.mo.HypervisorHostHelper; -import com.cloud.hypervisor.vmware.util.VmwareContext; -import com.cloud.utils.PropertiesUtil; -import com.vmware.vim25.HostIpConfig; -import com.vmware.vim25.HostVirtualNicSpec; -import com.vmware.vim25.ArrayOfManagedObjectReference; -import com.vmware.vim25.DVPortgroupConfigInfo; -import com.vmware.vim25.DVPortgroupConfigSpec; -import com.vmware.vim25.DVSSecurityPolicy; -import com.vmware.vim25.DVSTrafficShapingPolicy; -import com.vmware.vim25.DatastoreInfo; -import com.vmware.vim25.DynamicProperty; -import com.vmware.vim25.HostConfigManager; -import com.vmware.vim25.HostIpConfig; -import com.vmware.vim25.HostPortGroupSpec; -import com.vmware.vim25.HostVirtualNicSpec; -import com.vmware.vim25.HttpNfcLeaseDeviceUrl; -import com.vmware.vim25.HttpNfcLeaseInfo; -import com.vmware.vim25.HttpNfcLeaseState; -import com.vmware.vim25.InvalidProperty; -import com.vmware.vim25.ManagedObjectReference; -import com.vmware.vim25.ObjectContent; -import com.vmware.vim25.ObjectSpec; -import com.vmware.vim25.OvfCreateImportSpecParams; -import com.vmware.vim25.OvfCreateImportSpecResult; -import com.vmware.vim25.OvfFileItem; -import com.vmware.vim25.PropertyFilterSpec; -import com.vmware.vim25.PropertySpec; -import com.vmware.vim25.RuntimeFault; -import com.vmware.vim25.SelectionSpec; -import com.vmware.vim25.TraversalSpec; -import com.vmware.vim25.VMwareDVSPortSetting; -import com.vmware.vim25.VirtualDeviceConfigSpec; -import com.vmware.vim25.VirtualDeviceConfigSpecOperation; -import com.vmware.vim25.VirtualEthernetCard; -import com.vmware.vim25.VirtualEthernetCardNetworkBackingInfo; -import com.vmware.vim25.VirtualMachineCloneSpec; -import com.vmware.vim25.VirtualMachineConfigSpec; -import com.vmware.vim25.VirtualMachineRelocateSpec; -import com.vmware.vim25.VirtualNicManagerNetConfig; -import com.vmware.vim25.VirtualPCNet32; -import com.vmware.vim25.VmwareDistributedVirtualSwitchVlanSpec; - -public class TestVMWare { - private static ExtendedAppUtil cb; - private static String[] _args; - - private static final int IND_DATACENTER_MOR = 3; - private static final int IND_DVSWITCH_MOR = 4; - private static final int IND_DVSWITCH_NAME = 5; - private static final int IND_DVPORTGROUP_NAME = 6; - private static final int IND_DVPORTGROUP_VLAN = 7; - private static final int IND_DVPORTGROUP_PORTCOUNT = 8; - private static final int MAX_ARGS = 9; - static { - try { - javax.net.ssl.TrustManager[] trustAllCerts = new javax.net.ssl.TrustManager[1]; - javax.net.ssl.TrustManager tm = new TrustAllManager(); - trustAllCerts[0] = tm; - javax.net.ssl.SSLContext sc = javax.net.ssl.SSLContext.getInstance("SSL"); - sc.init(null, trustAllCerts, null); - javax.net.ssl.HttpsURLConnection.setDefaultSSLSocketFactory(sc.getSocketFactory()); - } catch (Exception e) { - } - } - - private static void setupLog4j() { - File file = PropertiesUtil.findConfigFile("log4j-cloud.xml"); - - if(file != null) { - System.out.println("Log4j configuration from : " + file.getAbsolutePath()); - DOMConfigurator.configureAndWatch(file.getAbsolutePath(), 10000); - } else { - System.out.println("Configure log4j with default properties"); - } - } - - private void getAndPrintInventoryContents() throws Exception { - TraversalSpec resourcePoolTraversalSpec = new TraversalSpec(); - resourcePoolTraversalSpec.setName("resourcePoolTraversalSpec"); - resourcePoolTraversalSpec.setType("ResourcePool"); - resourcePoolTraversalSpec.setPath("resourcePool"); - resourcePoolTraversalSpec.setSkip(new Boolean(false)); - resourcePoolTraversalSpec.setSelectSet( - new SelectionSpec [] { new SelectionSpec(null,null,"resourcePoolTraversalSpec") }); - - TraversalSpec computeResourceRpTraversalSpec = new TraversalSpec(); - computeResourceRpTraversalSpec.setName("computeResourceRpTraversalSpec"); - computeResourceRpTraversalSpec.setType("ComputeResource"); - computeResourceRpTraversalSpec.setPath("resourcePool"); - computeResourceRpTraversalSpec.setSkip(new Boolean(false)); - computeResourceRpTraversalSpec.setSelectSet( - new SelectionSpec [] { new SelectionSpec(null,null,"resourcePoolTraversalSpec") }); - - TraversalSpec computeResourceHostTraversalSpec = new TraversalSpec(); - computeResourceHostTraversalSpec.setName("computeResourceHostTraversalSpec"); - computeResourceHostTraversalSpec.setType("ComputeResource"); - computeResourceHostTraversalSpec.setPath("host"); - computeResourceHostTraversalSpec.setSkip(new Boolean(false)); - - TraversalSpec datacenterHostTraversalSpec = new TraversalSpec(); - datacenterHostTraversalSpec.setName("datacenterHostTraversalSpec"); - datacenterHostTraversalSpec.setType("Datacenter"); - datacenterHostTraversalSpec.setPath("hostFolder"); - datacenterHostTraversalSpec.setSkip(new Boolean(false)); - datacenterHostTraversalSpec.setSelectSet( - new SelectionSpec [] { new SelectionSpec(null,null,"folderTraversalSpec") }); - - TraversalSpec datacenterVmTraversalSpec = new TraversalSpec(); - datacenterVmTraversalSpec.setName("datacenterVmTraversalSpec"); - datacenterVmTraversalSpec.setType("Datacenter"); - datacenterVmTraversalSpec.setPath("vmFolder"); - datacenterVmTraversalSpec.setSkip(new Boolean(false)); - datacenterVmTraversalSpec.setSelectSet( - new SelectionSpec [] { new SelectionSpec(null,null,"folderTraversalSpec") }); - - TraversalSpec folderTraversalSpec = new TraversalSpec(); - folderTraversalSpec.setName("folderTraversalSpec"); - folderTraversalSpec.setType("Folder"); - folderTraversalSpec.setPath("childEntity"); - folderTraversalSpec.setSkip(new Boolean(false)); - folderTraversalSpec.setSelectSet( - new SelectionSpec [] { new SelectionSpec(null,null,"folderTraversalSpec"), - datacenterHostTraversalSpec, - datacenterVmTraversalSpec, - computeResourceRpTraversalSpec, - computeResourceHostTraversalSpec, - resourcePoolTraversalSpec }); - - PropertySpec[] propspecary = new PropertySpec[] { new PropertySpec() }; - propspecary[0].setAll(new Boolean(false)); - propspecary[0].setPathSet(new String[] { "name" }); - propspecary[0].setType("ManagedEntity"); - - PropertyFilterSpec spec = new PropertyFilterSpec(); - spec.setPropSet(propspecary); - spec.setObjectSet(new ObjectSpec[] { new ObjectSpec() }); - spec.getObjectSet(0).setObj(cb.getServiceConnection3().getRootFolder()); - spec.getObjectSet(0).setSkip(new Boolean(false)); - spec.getObjectSet(0).setSelectSet( - new SelectionSpec[] { folderTraversalSpec }); - - // Recursively get all ManagedEntity ManagedObjectReferences - // and the "name" property for all ManagedEntities retrieved - ObjectContent[] ocary = - cb.getServiceConnection3().getService().retrieveProperties( - cb.getServiceConnection3().getServiceContent().getPropertyCollector(), - new PropertyFilterSpec[] { spec } - ); - - // If we get contents back. print them out. - if (ocary != null) { - ObjectContent oc = null; - ManagedObjectReference mor = null; - DynamicProperty[] pcary = null; - DynamicProperty pc = null; - for (int oci = 0; oci < ocary.length; oci++) { - oc = ocary[oci]; - mor = oc.getObj(); - pcary = oc.getPropSet(); - - System.out.println("Object Type : " + mor.getType()); - System.out.println("Reference Value : " + mor.get_value()); - - if (pcary != null) { - for (int pci = 0; pci < pcary.length; pci++) { - pc = pcary[pci]; - System.out.println(" Property Name : " + pc.getName()); - if (pc != null) { - if (!pc.getVal().getClass().isArray()) { - System.out.println(" Property Value : " + pc.getVal()); - } - else { - Object[] ipcary = (Object[])pc.getVal(); - System.out.println("Val : " + pc.getVal()); - for (int ii = 0; ii < ipcary.length; ii++) { - Object oval = ipcary[ii]; - if (oval.getClass().getName().indexOf("ManagedObjectReference") >= 0) { - ManagedObjectReference imor = (ManagedObjectReference)oval; - - System.out.println("Inner Object Type : " + imor.getType()); - System.out.println("Inner Reference Value : " + imor.get_value()); - } - else { - System.out.println("Inner Property Value : " + oval); - } - } - } - } - } - } - } - } else { - System.out.println("No Managed Entities retrieved!"); - } - } - - private void listDataCenters() { - try { - ManagedObjectReference[] morDatacenters = getDataCenterMors(); - if(morDatacenters != null) { - for(ManagedObjectReference mor : morDatacenters) { - System.out.println("Datacenter : " + mor.get_value()); - - Map properites = new HashMap(); - properites.put("name", null); - properites.put("vmFolder", null); - properites.put("hostFolder", null); - - getProperites(mor, properites); - for(Map.Entry entry : properites.entrySet()) { - if(entry.getValue() instanceof ManagedObjectReference) { - ManagedObjectReference morProp = (ManagedObjectReference)entry.getValue(); - System.out.println("\t" + entry.getKey() + ":(" + morProp.getType() + ", " + morProp.get_value() + ")"); - } else { - System.out.println("\t" + entry.getKey() + ":" + entry.getValue()); - } - } - - System.out.println("Datacenter clusters"); - ManagedObjectReference[] clusters = getDataCenterClusterMors(mor); - if(clusters != null) { - for(ManagedObjectReference morCluster : clusters) { - Object[] props = this.getProperties(morCluster, new String[] {"name"}); - System.out.println("cluster : " + props[0]); - - System.out.println("cluster hosts"); - ManagedObjectReference[] hosts = getClusterHostMors(morCluster); - if(hosts != null) { - for(ManagedObjectReference morHost : hosts) { - Object[] props2 = this.getProperties(morHost, new String[] {"name"}); - System.out.println("host : " + props2[0]); - } - } - } - } - - System.out.println("Datacenter standalone hosts"); - ManagedObjectReference[] hosts = getDataCenterStandaloneHostMors(mor); - if(hosts != null) { - for(ManagedObjectReference morHost : hosts) { - Object[] props = this.getProperties(morHost, new String[] {"name"}); - System.out.println("host : " + props[0]); - } - } - - System.out.println("Datacenter datastores"); - ManagedObjectReference[] stores = getDataCenterDatastoreMors(mor); - if(stores != null) { - for(ManagedObjectReference morStore : stores) { - // data store name property does not work for some reason - Object[] props = getProperties(morStore, new String[] {"info" }); - - System.out.println(morStore.getType() + ": " + ((DatastoreInfo)props[0]).getName()); - } - } - - System.out.println("Datacenter VMs"); - ManagedObjectReference[] vms = getDataCenterVMMors(mor); - if(stores != null) { - for(ManagedObjectReference morVm : vms) { - Object[] props = this.getProperties(morVm, new String[] {"name"}); - System.out.println("VM name: " + props[0] + ", ref val: " + morVm.get_value()); - } - } - } - } - } catch(RuntimeFault e) { - e.printStackTrace(); - } catch(RemoteException e) { - e.printStackTrace(); - } - } - - private void listInventoryFolders() { - TraversalSpec folderTraversalSpec = new TraversalSpec(); - folderTraversalSpec.setName("folderTraversalSpec"); - folderTraversalSpec.setType("Folder"); - folderTraversalSpec.setPath("childEntity"); - folderTraversalSpec.setSkip(new Boolean(false)); - folderTraversalSpec.setSelectSet( - new SelectionSpec [] { new SelectionSpec(null, null, "folderTraversalSpec")} - ); - - PropertySpec[] propSpecs = new PropertySpec[] { new PropertySpec() }; - propSpecs[0].setAll(new Boolean(false)); - propSpecs[0].setPathSet(new String[] { "name" }); - propSpecs[0].setType("ManagedEntity"); - - PropertyFilterSpec filterSpec = new PropertyFilterSpec(); - filterSpec.setPropSet(propSpecs); - filterSpec.setObjectSet(new ObjectSpec[] { new ObjectSpec() }); - filterSpec.getObjectSet(0).setObj(cb.getServiceConnection3().getRootFolder()); - filterSpec.getObjectSet(0).setSkip(new Boolean(false)); - filterSpec.getObjectSet(0).setSelectSet( - new SelectionSpec[] { folderTraversalSpec } - ); - - try { - ObjectContent[] objContent = cb.getServiceConnection3().getService().retrieveProperties( - cb.getServiceConnection3().getServiceContent().getPropertyCollector(), - new PropertyFilterSpec[] { filterSpec } - ); - printContent(objContent); - } catch (InvalidProperty e) { - e.printStackTrace(); - } catch (RuntimeFault e) { - e.printStackTrace(); - } catch (RemoteException e) { - e.printStackTrace(); - } - } - - private TraversalSpec getFolderRecursiveTraversalSpec() { - SelectionSpec recurseFolders = new SelectionSpec(); - recurseFolders.setName("folder2childEntity"); - - TraversalSpec folder2childEntity = new TraversalSpec(); - folder2childEntity.setType("Folder"); - folder2childEntity.setPath("childEntity"); - folder2childEntity.setName(recurseFolders.getName()); - folder2childEntity.setSelectSet(new SelectionSpec[] { recurseFolders }); - - return folder2childEntity; - } - - private ManagedObjectReference[] getDataCenterMors() throws RuntimeFault, RemoteException { - PropertySpec pSpec = new PropertySpec(); - pSpec.setType("Datacenter"); - pSpec.setPathSet(new String[] { "name"} ); - - ObjectSpec oSpec = new ObjectSpec(); - oSpec.setObj(cb.getServiceConnection3().getRootFolder()); - oSpec.setSkip(Boolean.TRUE); - oSpec.setSelectSet(new SelectionSpec[] { getFolderRecursiveTraversalSpec() }); - - PropertyFilterSpec pfSpec = new PropertyFilterSpec(); - pfSpec.setPropSet(new PropertySpec[] { pSpec }); - pfSpec.setObjectSet(new ObjectSpec[] { oSpec }); - - ObjectContent[] ocs = cb.getServiceConnection3().getService().retrieveProperties( - cb.getServiceConnection3().getServiceContent().getPropertyCollector(), - new PropertyFilterSpec[] { pfSpec }); - - if(ocs != null) { - ManagedObjectReference[] morDatacenters = new ManagedObjectReference[ocs.length]; - for(int i = 0; i < ocs.length; i++) - morDatacenters[i] = ocs[i].getObj(); - - return morDatacenters; - } - return null; - } - - private ManagedObjectReference[] getDataCenterVMMors(ManagedObjectReference morDatacenter) throws RuntimeFault, RemoteException { - PropertySpec pSpec = new PropertySpec(); - pSpec.setType("VirtualMachine"); - pSpec.setPathSet(new String[] { "name"} ); - - ObjectSpec oSpec = new ObjectSpec(); - oSpec.setObj(morDatacenter); - oSpec.setSkip(Boolean.TRUE); - - TraversalSpec tSpec = new TraversalSpec(); - tSpec.setName("dc2VMFolder"); - tSpec.setType("Datacenter"); - tSpec.setPath("vmFolder"); - tSpec.setSelectSet(new SelectionSpec[] { getFolderRecursiveTraversalSpec() } ); - - oSpec.setSelectSet(new SelectionSpec[] { tSpec }); - - PropertyFilterSpec pfSpec = new PropertyFilterSpec(); - pfSpec.setPropSet(new PropertySpec[] { pSpec }); - pfSpec.setObjectSet(new ObjectSpec[] { oSpec }); - - ObjectContent[] ocs = cb.getServiceConnection3().getService().retrieveProperties( - cb.getServiceConnection3().getServiceContent().getPropertyCollector(), - new PropertyFilterSpec[] { pfSpec }); - - if(ocs != null) { - ManagedObjectReference[] morVMs = new ManagedObjectReference[ocs.length]; - for(int i = 0; i < ocs.length; i++) - morVMs[i] = ocs[i].getObj(); - - return morVMs; - } - return null; - } - - private ManagedObjectReference[] getDataCenterDatastoreMors(ManagedObjectReference morDatacenter) throws RuntimeFault, RemoteException { - Object[] stores = getProperties(morDatacenter, new String[] { "datastore" }); - if(stores != null && stores.length == 1) { - return ((ArrayOfManagedObjectReference)stores[0]).getManagedObjectReference(); - } - return null; - } - - private ManagedObjectReference[] getDataCenterClusterMors(ManagedObjectReference morDatacenter) throws RuntimeFault, RemoteException { - PropertySpec pSpec = new PropertySpec(); - pSpec.setType("ClusterComputeResource"); - pSpec.setPathSet(new String[] { "name"} ); - - ObjectSpec oSpec = new ObjectSpec(); - oSpec.setObj(morDatacenter); - oSpec.setSkip(Boolean.TRUE); - - TraversalSpec tSpec = new TraversalSpec(); - tSpec.setName("traversalHostFolder"); - tSpec.setType("Datacenter"); - tSpec.setPath("hostFolder"); - tSpec.setSkip(false); - tSpec.setSelectSet(new SelectionSpec[] { getFolderRecursiveTraversalSpec() }); - - oSpec.setSelectSet(new TraversalSpec[] { tSpec }); - - PropertyFilterSpec pfSpec = new PropertyFilterSpec(); - pfSpec.setPropSet(new PropertySpec[] { pSpec }); - pfSpec.setObjectSet(new ObjectSpec[] { oSpec }); - - ObjectContent[] ocs = cb.getServiceConnection3().getService().retrieveProperties( - cb.getServiceConnection3().getServiceContent().getPropertyCollector(), - new PropertyFilterSpec[] { pfSpec }); - - if(ocs != null) { - ManagedObjectReference[] morDatacenters = new ManagedObjectReference[ocs.length]; - for(int i = 0; i < ocs.length; i++) - morDatacenters[i] = ocs[i].getObj(); - - return morDatacenters; - } - return null; - } - - private ManagedObjectReference[] getDataCenterStandaloneHostMors(ManagedObjectReference morDatacenter) throws RuntimeFault, RemoteException { - PropertySpec pSpec = new PropertySpec(); - pSpec.setType("ComputeResource"); - pSpec.setPathSet(new String[] { "name"} ); - - ObjectSpec oSpec = new ObjectSpec(); - oSpec.setObj(morDatacenter); - oSpec.setSkip(Boolean.TRUE); - - TraversalSpec tSpec = new TraversalSpec(); - tSpec.setName("traversalHostFolder"); - tSpec.setType("Datacenter"); - tSpec.setPath("hostFolder"); - tSpec.setSkip(false); - tSpec.setSelectSet(new SelectionSpec[] { getFolderRecursiveTraversalSpec() }); - - oSpec.setSelectSet(new TraversalSpec[] { tSpec }); - - PropertyFilterSpec pfSpec = new PropertyFilterSpec(); - pfSpec.setPropSet(new PropertySpec[] { pSpec }); - pfSpec.setObjectSet(new ObjectSpec[] { oSpec }); - - ObjectContent[] ocs = cb.getServiceConnection3().getService().retrieveProperties( - cb.getServiceConnection3().getServiceContent().getPropertyCollector(), - new PropertyFilterSpec[] { pfSpec }); - - if(ocs != null) { - List listComputeResources = new ArrayList(); - for(ObjectContent oc : ocs) { - if(oc.getObj().getType().equalsIgnoreCase("ComputeResource")) - listComputeResources.add(oc.getObj()); - } - - List listHosts = new ArrayList(); - for(ManagedObjectReference morComputeResource : listComputeResources) { - ManagedObjectReference[] hosts = getComputeResourceHostMors(morComputeResource); - if(hosts != null) { - for(ManagedObjectReference host: hosts) - listHosts.add(host); - } - } - - return listHosts.toArray(new ManagedObjectReference[0]); - } - return null; - } - - private ManagedObjectReference[] getComputeResourceHostMors(ManagedObjectReference morCompute) throws RuntimeFault, RemoteException { - PropertySpec pSpec = new PropertySpec(); - pSpec.setType("HostSystem"); - pSpec.setPathSet(new String[] { "name"} ); - - ObjectSpec oSpec = new ObjectSpec(); - oSpec.setObj(morCompute); - oSpec.setSkip(true); - - TraversalSpec tSpec = new TraversalSpec(); - tSpec.setName("computeResource2Host"); - tSpec.setType("ComputeResource"); - tSpec.setPath("host"); - tSpec.setSkip(false); - oSpec.setSelectSet(new TraversalSpec[] { tSpec }); - - PropertyFilterSpec pfSpec = new PropertyFilterSpec(); - pfSpec.setPropSet(new PropertySpec[] { pSpec }); - pfSpec.setObjectSet(new ObjectSpec[] { oSpec }); - - ObjectContent[] ocs = cb.getServiceConnection3().getService().retrieveProperties( - cb.getServiceConnection3().getServiceContent().getPropertyCollector(), - new PropertyFilterSpec[] { pfSpec }); - - if(ocs != null) { - ManagedObjectReference[] morDatacenters = new ManagedObjectReference[ocs.length]; - for(int i = 0; i < ocs.length; i++) - morDatacenters[i] = ocs[i].getObj(); - - return morDatacenters; - } - return null; - } - - private ManagedObjectReference[] getClusterHostMors(ManagedObjectReference morCluster) throws RuntimeFault, RemoteException { - // ClusterComputeResource inherits from ComputeResource - return getComputeResourceHostMors(morCluster); - } - - private ObjectContent[] getDataCenterProperites(String[] properites) throws RuntimeFault, RemoteException { - PropertySpec pSpec = new PropertySpec(); - pSpec.setType("Datacenter"); - pSpec.setPathSet(properites ); - - SelectionSpec recurseFolders = new SelectionSpec(); - recurseFolders.setName("folder2childEntity"); - - TraversalSpec folder2childEntity = new TraversalSpec(); - folder2childEntity.setType("Folder"); - folder2childEntity.setPath("childEntity"); - folder2childEntity.setName(recurseFolders.getName()); - folder2childEntity.setSelectSet(new SelectionSpec[] { recurseFolders }); - - ObjectSpec oSpec = new ObjectSpec(); - oSpec.setObj(cb.getServiceConnection3().getRootFolder()); - oSpec.setSkip(Boolean.TRUE); - oSpec.setSelectSet(new SelectionSpec[] { folder2childEntity }); - - PropertyFilterSpec pfSpec = new PropertyFilterSpec(); - pfSpec.setPropSet(new PropertySpec[] { pSpec }); - pfSpec.setObjectSet(new ObjectSpec[] { oSpec }); - - return cb.getServiceConnection3().getService().retrieveProperties( - cb.getServiceConnection3().getServiceContent().getPropertyCollector(), - new PropertyFilterSpec[] { pfSpec }); - } - - private void printContent(ObjectContent[] objContent) { - if(objContent != null) { - for(ObjectContent oc : objContent) { - ManagedObjectReference mor = oc.getObj(); - DynamicProperty[] objProps = oc.getPropSet(); - - System.out.println("Object type: " + mor.getType()); - if(objProps != null) { - for(DynamicProperty objProp : objProps) { - if(!objProp.getClass().isArray()) { - System.out.println("\t" + objProp.getName() + "=" + objProp.getVal()); - } else { - Object[] ipcary = (Object[])objProp.getVal(); - System.out.print("\t" + objProp.getName() + "=["); - int i = 0; - for(Object item : ipcary) { - if (item.getClass().getName().indexOf("ManagedObjectReference") >= 0) { - ManagedObjectReference imor = (ManagedObjectReference)item; - System.out.print("(" + imor.getType() + "," + imor.get_value() + ")"); - } else { - System.out.print(item); - } - - if(i < ipcary.length - 1) - System.out.print(", "); - i++; - } - - System.out.println("]"); - } - } - } - } - } - } - - private void getProperites(ManagedObjectReference mor, Map properties) throws RuntimeFault, RemoteException { - PropertySpec pSpec = new PropertySpec(); - pSpec.setType(mor.getType()); - pSpec.setPathSet(properties.keySet().toArray(new String[0])); - - ObjectSpec oSpec = new ObjectSpec(); - oSpec.setObj(mor); - - PropertyFilterSpec pfSpec = new PropertyFilterSpec(); - pfSpec.setPropSet(new PropertySpec[] {pSpec} ); - pfSpec.setObjectSet(new ObjectSpec[] {oSpec} ); - - ObjectContent[] ocs = cb.getServiceConnection3().getService().retrieveProperties( - cb.getServiceConnection3().getServiceContent().getPropertyCollector(), - new PropertyFilterSpec[] {pfSpec} ); - - if(ocs != null) { - for(ObjectContent oc : ocs) { - DynamicProperty[] propSet = oc.getPropSet(); - if(propSet != null) { - for(DynamicProperty prop : propSet) { - properties.put(prop.getName(), prop.getVal()); - } - } - } - } - } - - private Object[] getProperties(ManagedObjectReference moRef, String[] properties) throws RuntimeFault, RemoteException { - PropertySpec pSpec = new PropertySpec(); - pSpec.setType(moRef.getType()); - pSpec.setPathSet(properties); - - ObjectSpec oSpec = new ObjectSpec(); - // Set the starting object - oSpec.setObj(moRef); - - PropertyFilterSpec pfSpec = new PropertyFilterSpec(); - pfSpec.setPropSet(new PropertySpec[] {pSpec} ); - pfSpec.setObjectSet(new ObjectSpec[] {oSpec} ); - ObjectContent[] ocs = cb.getServiceConnection3().getService().retrieveProperties( - cb.getServiceConnection3().getServiceContent().getPropertyCollector(), - new PropertyFilterSpec[] {pfSpec} ); - - Object[] ret = new Object[properties.length]; - if(ocs != null) { - for(int i = 0; i< ocs.length; ++i) { - ObjectContent oc = ocs[i]; - DynamicProperty[] dps = oc.getPropSet(); - if(dps != null) { - for(int j = 0; j < dps.length; ++j) { - DynamicProperty dp = dps[j]; - for(int p = 0; p < ret.length; ++p) { - if(properties[p].equals(dp.getName())) { - ret[p] = dp.getVal(); - } - } - } - } - } - } - return ret; - } - - private void powerOnVm() throws Exception { - ManagedObjectReference morVm = new ManagedObjectReference(); - morVm.setType("VirtualMachine"); - morVm.set_value("vm-480"); - - cb.getServiceConnection3().getService().powerOnVM_Task(morVm, null); - } - - private void powerOffVm() throws Exception { - ManagedObjectReference morVm = new ManagedObjectReference(); - morVm.setType("VirtualMachine"); - morVm.set_value("vm-66"); - - cb.getServiceConnection3().getService().powerOffVM_Task(morVm); - } - - private void createSnapshot() throws Exception { - ManagedObjectReference morVm = new ManagedObjectReference(); - morVm.setType("VirtualMachine"); - morVm.set_value("vm-66"); - cb.getServiceConnection3().getService().createSnapshot_Task(morVm, "RunningSnapshotProg", "", false, false); - } - - private void registerTemplate() throws Exception { - ManagedObjectReference morFolder = new ManagedObjectReference(); - morFolder.setType("Folder"); - morFolder.set_value("group-v3"); - - ManagedObjectReference morHost = new ManagedObjectReference(); - morHost.setType("HostSystem"); - morHost.set_value("host-48"); - - System.out.println("Begin registerVM_Task"); - ManagedObjectReference taskmor = cb.getServiceConnection3().getService().registerVM_Task( - morFolder, "[NFS datastore] Template-Fedora/Template-Fedora.vmtx", "Template-Fedora", true, - null, morHost); - System.out.println("End registerVM_Task"); - - String result = cb.getServiceUtil3().waitForTask(taskmor); - if (result.equalsIgnoreCase("Sucess")) { - System.out.println("Registering The Virtual Machine ..........Done"); - } else { - System.out.println("Some Exception While Registering The VM"); - } - } - - private void createVmFromTemplate() throws Exception { - VirtualMachineCloneSpec cloneSpec = new VirtualMachineCloneSpec(); - - ManagedObjectReference morDatastore = new ManagedObjectReference(); - morDatastore.setType("Datastore"); - morDatastore.set_value("datastore-30"); - - ManagedObjectReference morHost = new ManagedObjectReference(); - morHost.setType("HostSystem"); - morHost.set_value("host-48"); - - ManagedObjectReference morPool = new ManagedObjectReference(); - morPool.setType("ResourcePool"); - morPool.set_value("resgroup-41"); - - VirtualMachineRelocateSpec relocSpec = new VirtualMachineRelocateSpec(); - cloneSpec.setLocation(relocSpec); - cloneSpec.setPowerOn(false); - cloneSpec.setTemplate(false); - - relocSpec.setDatastore(morDatastore); - relocSpec.setHost(morHost); - relocSpec.setPool(morPool); - - ManagedObjectReference morTemplate = new ManagedObjectReference(); - morTemplate.setType("VirtualMachine"); - morTemplate.set_value("vm-76"); - - ManagedObjectReference morFolder = new ManagedObjectReference(); - morFolder.setType("Folder"); - morFolder.set_value("group-v3"); - - ManagedObjectReference cloneTask - = cb.getServiceConnection3().getService().cloneVM_Task(morTemplate, morFolder, - "Fedora-clone-test", cloneSpec); - - String status = cb.getServiceUtil3().waitForTask(cloneTask); - if(status.equalsIgnoreCase("failure")) { - System.out.println("Failure -: Virtual Machine cannot be cloned"); - } - - if(status.equalsIgnoreCase("sucess")) { - System.out.println("Virtual Machine Cloned successfully."); - } - } - - private void addNic() throws Exception { - ManagedObjectReference morVm = new ManagedObjectReference(); - morVm.setType("VirtualMachine"); - morVm.set_value("vm-77"); - - ManagedObjectReference morNetwork = new ManagedObjectReference(); - morNetwork.setType("DistributedVirtualPortgroup"); - morNetwork.set_value("dvportgroup-56"); - - VirtualDeviceConfigSpec nicSpec = new VirtualDeviceConfigSpec(); - nicSpec.setOperation(VirtualDeviceConfigSpecOperation.add); - VirtualEthernetCard nic = new VirtualPCNet32(); - VirtualEthernetCardNetworkBackingInfo nicBacking - = new VirtualEthernetCardNetworkBackingInfo(); - nicBacking.setDeviceName("Adapter to dSwitch-vlan26"); - nicBacking.setNetwork(morNetwork); - - nic.setAddressType("generated"); - nic.setBacking(nicBacking); - nic.setKey(4); - nicSpec.setDevice(nic); - - VirtualMachineConfigSpec vmConfigSpec = new VirtualMachineConfigSpec(); - VirtualDeviceConfigSpec [] nicSpecArray = {nicSpec}; - vmConfigSpec.setDeviceChange(nicSpecArray); - - ManagedObjectReference tmor - = cb.getServiceConnection3().getService().reconfigVM_Task( - morVm, vmConfigSpec); - - String status = cb.getServiceUtil3().waitForTask(tmor); - if(status.equalsIgnoreCase("failure")) { - System.out.println("Failure -: Virtual Machine cannot be cloned"); - } - - if(status.equalsIgnoreCase("sucess")) { - System.out.println("Virtual Machine Cloned successfully."); - } - } - - // add virtual NIC to vmkernel - private void addNicToNetwork() throws Exception { - ManagedObjectReference morHost = new ManagedObjectReference(); - morHost.setType("HostSystem"); - morHost.set_value("host-48"); - - HostPortGroupSpec portgrp = new HostPortGroupSpec(); - portgrp.setName("VM Network vlan26"); - - Object cmobj = cb.getServiceUtil3().getDynamicProperty(morHost, "configManager"); - HostConfigManager configMgr = (HostConfigManager)cmobj; - ManagedObjectReference nwSystem = configMgr.getNetworkSystem(); - - HostVirtualNicSpec vNicSpec = new HostVirtualNicSpec(); - HostIpConfig ipConfig = new HostIpConfig(); - ipConfig.setDhcp(false); - ipConfig.setIpAddress("192.168.26.177"); - ipConfig.setSubnetMask("255.255.255.0"); - - vNicSpec.setIp(ipConfig); - vNicSpec.setPortgroup("VM Network vlan26"); - - cb.getServiceConnection3().getService().addVirtualNic(nwSystem, - "dvPortGroup-vlan26", vNicSpec); - } - - private void createDatacenter() throws Exception { - cb.getServiceConnection3().getService().createDatacenter( - cb.getServiceConnection3().getRootFolder(), - "cloud.dc.test"); - } - - private void getPropertyWithPath() throws Exception { - ManagedObjectReference morHost = new ManagedObjectReference(); - morHost.setType("HostSystem"); - morHost.set_value("host-161"); - - VirtualNicManagerNetConfig[] netConfigs = (VirtualNicManagerNetConfig[])cb.getServiceUtil3().getDynamicProperty(morHost, "config.virtualNicManagerInfo.netConfig"); - } - - private void getHostVMs() throws Exception { - ManagedObjectReference morHost = new ManagedObjectReference(); - morHost.setType("HostSystem"); - morHost.set_value("host-48"); - - PropertySpec pSpec = new PropertySpec(); - pSpec.setType("VirtualMachine"); - pSpec.setPathSet(new String[] { "name", "runtime.powerState", "config.template" }); - - TraversalSpec host2VmTraversal = new TraversalSpec(); - host2VmTraversal.setType("HostSystem"); - host2VmTraversal.setPath("vm"); - host2VmTraversal.setName("host2VmTraversal"); - - ObjectSpec oSpec = new ObjectSpec(); - oSpec.setObj(morHost); - oSpec.setSkip(Boolean.TRUE); - oSpec.setSelectSet(new SelectionSpec[] { host2VmTraversal }); - - PropertyFilterSpec pfSpec = new PropertyFilterSpec(); - pfSpec.setPropSet(new PropertySpec[] { pSpec }); - pfSpec.setObjectSet(new ObjectSpec[] { oSpec }); - - ObjectContent[] ocs = cb.getServiceConnection3().getService().retrieveProperties( - cb.getServiceConnection3().getServiceContent().getPropertyCollector(), - new PropertyFilterSpec[] { pfSpec }); - this.printContent(ocs); - } - - private void testFT() throws Exception { - - ManagedObjectReference morVm = new ManagedObjectReference(); - morVm.setType("VirtualMachine"); - morVm.set_value("vm-480"); - - ManagedObjectReference morHost = new ManagedObjectReference(); - morHost.setType("HostSystem"); - morHost.set_value("host-470"); - - System.out.println("Create secondary VM"); - ManagedObjectReference morTask = cb.getServiceConnection3().getService().createSecondaryVM_Task(morVm, morHost); - String result = cb.getServiceUtil3().waitForTask(morTask); - - System.out.println("Create secondary VM resutl : " + result); - } - - private void testFTEnable() throws Exception { - ManagedObjectReference morVm = new ManagedObjectReference(); - morVm.setType("VirtualMachine"); - morVm.set_value("vm-480"); - - ManagedObjectReference morHost = new ManagedObjectReference(); - morHost.setType("HostSystem"); - morHost.set_value("host-470"); - - ManagedObjectReference morSecondaryVm = new ManagedObjectReference(); - morSecondaryVm.setType("VirtualMachine"); - morSecondaryVm.set_value("vm-485"); - - System.out.println("Enable FT"); - ManagedObjectReference morTask = cb.getServiceConnection3().getService().enableSecondaryVM_Task(morVm, - morSecondaryVm, morHost); - String result = cb.getServiceUtil3().waitForTask(morTask); - - System.out.println("Enable FT resutl : " + result); - } - private DatacenterMO setupDatacenterObject(String serverAddress, String dcMor) { - VmwareContext context = new VmwareContext(cb, serverAddress); - - ManagedObjectReference morDc = new ManagedObjectReference(); - morDc.setType("Datacenter"); - morDc.set_value(dcMor); - - return new DatacenterMO(context, morDc); - } - - private DistributedVirtualSwitchMO setupDistributedVirtualSwitchObject(String dvsMor, String serverAddress) { - VmwareContext context = new VmwareContext(cb, serverAddress); - return new DistributedVirtualSwitchMO(context, setupDVS(dvsMor)); - } - - private ManagedObjectReference setupDVS(String dvsMor) { - ManagedObjectReference morDvs = new ManagedObjectReference(); - morDvs.setType("VmwareDistributedVirtualSwitch"); - morDvs.set_value(dvsMor); - return morDvs; - } - - private void testDvSwitchOperations() throws Exception { - String dvSwitchName, dcMor; - ManagedObjectReference queriedDvs; - ManagedObjectReference morDvs; - DatacenterMO dcMo; - URL serviceUrl; - - // Initialize mor for existing DVS - if (_args.length <= IND_DVSWITCH_NAME) { - System.out.println("Using default parameters as required command line arguments are not provided."); - System.out.println("Sequence of arguments: "); - morDvs = setupDVS("dvs-921"); - dvSwitchName = "dvSwitch0"; - dcMor = "datacenter-2"; - } else { - morDvs = setupDVS(_args[IND_DVSWITCH_MOR]); - dvSwitchName = _args[IND_DVSWITCH_NAME]; - dcMor = _args[IND_DATACENTER_MOR]; - } - - serviceUrl = new URL(cb.getServiceUrl()); - - // Initialize Datacenter Object that pertains to above DVS - dcMo = setupDatacenterObject(serviceUrl.getHost(), dcMor); - - // Query for DVS with name - queriedDvs = dcMo.getDvSwitchMor(dvSwitchName); - - System.out.print("\nTest fetch dvSwitch object from vCenter : "); - if (morDvs.equals(queriedDvs)) { - System.out.println("Success\n"); - } else { - System.out.println("Failed\n"); - } - } - - private void testDvPortGroupOpearations() throws Exception { - // addDvPortGroup, updateDvPortGroup, getDvPortGroup, hasDvPortGroup - ManagedObjectReference morDvs, morDvPortGroup; - DatacenterMO dcMo; - DistributedVirtualSwitchMO dvsMo; - int networkRateMbps; - int networkRateMbpsToUpdate; - DVSTrafficShapingPolicy shapingPolicy; - VmwareDistributedVirtualSwitchVlanSpec vlanSpec; - DVSSecurityPolicy secPolicy; - VMwareDVSPortSetting dvsPortSetting; - DVPortgroupConfigSpec dvPortGroupSpec; - DVPortgroupConfigInfo dvPortgroupInfo = null; - String dvPortGroupName, dcMor; - Integer vid; - int numPorts; - int timeOutMs; - URL serviceUrl; - - if (_args.length < MAX_ARGS) { - System.out.println("Using default parameters as required command line arguments are not provided."); - System.out.println("Sequence of arguments: "); - morDvs = setupDVS("dvs-921"); - dvPortGroupName = "cloud.public.201.dvSwitch0.1"; - networkRateMbps = 201; - vid = new Integer(399); // VLAN 399 - timeOutMs = 7000; - numPorts = 64; - dcMor = "datacenter-2"; - } else { - morDvs = setupDVS(_args[IND_DVSWITCH_MOR]); - dvPortGroupName = _args[IND_DVPORTGROUP_NAME]; - vid = new Integer(IND_DVPORTGROUP_VLAN); - dcMor = _args[IND_DATACENTER_MOR]; - numPorts = Integer.parseInt(_args[IND_DVPORTGROUP_PORTCOUNT]); - timeOutMs = 7000; - networkRateMbps = 201; - } - serviceUrl = new URL(cb.getServiceUrl()); - - // Initialize Datacenter Object that pertains to above DVS - dcMo = setupDatacenterObject(serviceUrl.getHost(), dcMor); - // Create dvPortGroup configuration spec - dvsMo = setupDistributedVirtualSwitchObject(morDvs.get_value(), serviceUrl.getHost()); - - shapingPolicy = HypervisorHostHelper.getDVSShapingPolicy(networkRateMbps); - secPolicy = HypervisorHostHelper.createDVSSecurityPolicy(); - if (vid != null) { - vlanSpec = HypervisorHostHelper.createDVPortVlanIdSpec(vid); - } else { - vlanSpec = HypervisorHostHelper.createDVPortVlanSpec(); - } - dvsPortSetting = HypervisorHostHelper.createVmwareDVPortSettingSpec(shapingPolicy, secPolicy, vlanSpec); - dvPortGroupSpec = HypervisorHostHelper.createDvPortGroupSpec(dvPortGroupName, dvsPortSetting, numPorts); - if (!dcMo.hasDvPortGroup(dvPortGroupName)) { - System.out.print("\nTest create dvPortGroup : "); - try { - // Call method to create dvPortGroup - dvsMo.createDVPortGroup(dvPortGroupSpec); - System.out.println("Success\n"); - HypervisorHostHelper.waitForDvPortGroupReady(dcMo, dvPortGroupName, timeOutMs); - } catch (Exception e) { - System.out.println("Failed\n"); - throw new Exception(e); - } - } - - // Test for presence of dvPortGroup - System.out.print("\nTest presence of dvPortGroup : "); - if (dcMo.hasDvPortGroup(dvPortGroupName)) { - System.out.println("Success\n"); - } else { - System.out.println("Failed\n"); - } - - // Test get existing dvPortGroup - System.out.print("\nTest fetch dvPortGroup configuration : "); - try { - dvPortgroupInfo = dcMo.getDvPortGroupSpec(dvPortGroupName); - if (dvPortgroupInfo != null) - System.out.println("Success\n"); - } catch (Exception e) { - System.out.println("Failed\n"); - } - // Test compare dvPortGroup configuration - System.out.print("\nTest compare dvPortGroup configuration : "); - - if (HypervisorHostHelper.isSpecMatch(dvPortgroupInfo, vid, shapingPolicy)) { - System.out.println("Success\n"); - // We haven't modified the dvPortGroup after creating above. - // Hence expecting to be matching. - // NOTE : Hopefully nothing changes the configuration externally. - } else { - System.out.println("Failed\n"); - } - - // Test update dvPortGroup configuration - networkRateMbpsToUpdate = 210; - shapingPolicy = HypervisorHostHelper.getDVSShapingPolicy(networkRateMbpsToUpdate); - dvsPortSetting = HypervisorHostHelper.createVmwareDVPortSettingSpec(shapingPolicy, secPolicy, vlanSpec); - dvPortGroupSpec.setDefaultPortConfig(dvsPortSetting); - dvPortGroupSpec.setConfigVersion(dvPortgroupInfo.getConfigVersion()); - morDvPortGroup = dcMo.getDvPortGroupMor(dvPortGroupName); - System.out.print("\nTest update dvPortGroup configuration : "); - if (!HypervisorHostHelper.isSpecMatch(dvPortgroupInfo, vid, shapingPolicy)) { - try { - dvsMo.updateDvPortGroup(morDvPortGroup, dvPortGroupSpec); - System.out.println("Success\n"); - } catch (Exception e) { - System.out.println("Failed\n"); - throw new Exception(e); - } - } - } - private void importOVF() throws Exception { - ManagedObjectReference morHost = new ManagedObjectReference(); - morHost.setType("HostSystem"); - morHost.set_value("host-223"); - - ManagedObjectReference morRp = new ManagedObjectReference(); - morRp.setType("ResourcePool"); - morRp.set_value("resgroup-222"); - - ManagedObjectReference morDs = new ManagedObjectReference(); - morDs.setType("Datastore"); - morDs.set_value("datastore-30"); - - ManagedObjectReference morVmFolder = new ManagedObjectReference(); - morVmFolder.setType("Folder"); - morVmFolder.set_value("group-v3"); - - ManagedObjectReference morNetwork = new ManagedObjectReference(); - morNetwork.setType("Network"); - morNetwork.set_value("network-32"); - - ManagedObjectReference morOvf = cb.getServiceConnection3().getServiceContent().getOvfManager(); - - OvfCreateImportSpecParams importSpecParams = new OvfCreateImportSpecParams(); - importSpecParams.setHostSystem(morHost); - importSpecParams.setLocale("US"); - importSpecParams.setEntityName("winxpsp3-ovf-deployed"); - importSpecParams.setDeploymentOption(""); - importSpecParams.setDiskProvisioning("thin"); - -/* - OvfNetworkMapping networkMapping = new OvfNetworkMapping(); - networkMapping.setName("VM Network"); - networkMapping.setNetwork(morNetwork); // network); - importSpecParams.setNetworkMapping(new OvfNetworkMapping[] { networkMapping }); -*/ - importSpecParams.setPropertyMapping(null); - - String ovfDescriptor = readOvfContent("C:\\research\\vmware\\winxpsp3-ovf\\winxpsp3-ovf.ovf"); - OvfCreateImportSpecResult ovfImportResult = cb.getServiceConnection3().getService().createImportSpec( - morOvf, ovfDescriptor, morRp, morDs, importSpecParams); - - if(ovfImportResult != null) { - long totalBytes = addTotalBytes(ovfImportResult); - - ManagedObjectReference morLease = cb.getServiceConnection3().getService().importVApp(morRp, - ovfImportResult.getImportSpec(), morVmFolder, morHost); - - HttpNfcLeaseState state; - for(;;) { - state = (HttpNfcLeaseState)cb.getServiceUtil3().getDynamicProperty(morLease, "state"); - if(state == HttpNfcLeaseState.ready || state == HttpNfcLeaseState.error) - break; - } - - if(state == HttpNfcLeaseState.ready) { - HttpNfcLeaseInfo httpNfcLeaseInfo = (HttpNfcLeaseInfo)cb.getServiceUtil3().getDynamicProperty(morLease, "info"); - HttpNfcLeaseDeviceUrl[] deviceUrls = httpNfcLeaseInfo.getDeviceUrl(); - long bytesAlreadyWritten = 0; - for (HttpNfcLeaseDeviceUrl deviceUrl : deviceUrls) { - - String deviceKey = deviceUrl.getImportKey(); - for (OvfFileItem ovfFileItem : ovfImportResult.getFileItem()) { - if (deviceKey.equals(ovfFileItem.getDeviceId())) { - System.out.println("Import key==OvfFileItem device id: " + deviceKey); - System.out.println("device URL: " + deviceUrl.getUrl()); - - String absoluteFile = "C:\\research\\vmware\\winxpsp3-ovf\\" + ovfFileItem.getPath(); - String urlToPost = deviceUrl.getUrl().replace("*", "esxhost-1.lab.vmops.com"); - - uploadVmdkFile(ovfFileItem.isCreate(), absoluteFile, urlToPost, bytesAlreadyWritten, totalBytes); - bytesAlreadyWritten += ovfFileItem.getSize(); - System.out.println("Completed uploading the VMDK file:" + absoluteFile); - } - } - } - cb.getServiceConnection3().getService().httpNfcLeaseProgress(morLease, 100); - cb.getServiceConnection3().getService().httpNfcLeaseComplete(morLease); - } - } - } - - private static void uploadVmdkFile(boolean put, String diskFilePath, String urlStr, long bytesAlreadyWritten, long totalBytes) throws IOException { - HttpsURLConnection.setDefaultHostnameVerifier(new HostnameVerifier() { - public boolean verify(String urlHostName, SSLSession session) { - return true; - } - }); - - HttpsURLConnection conn = (HttpsURLConnection) new URL(urlStr).openConnection(); - - conn.setDoOutput(true); - conn.setUseCaches(false); - - int CHUCK_LEN = 64*1024; - conn.setChunkedStreamingMode(CHUCK_LEN); - conn.setRequestMethod(put? "PUT" : "POST"); // Use a post method to write the file. - conn.setRequestProperty("Connection", "Keep-Alive"); - conn.setRequestProperty("Content-Type", "application/x-vnd.vmware-streamVmdk"); - conn.setRequestProperty("Content-Length", Long.toString(new File(diskFilePath).length())); - BufferedOutputStream bos = new BufferedOutputStream(conn.getOutputStream()); - BufferedInputStream diskis = new BufferedInputStream(new FileInputStream(diskFilePath)); - int bytesAvailable = diskis.available(); - int bufferSize = Math.min(bytesAvailable, CHUCK_LEN); - byte[] buffer = new byte[bufferSize]; - long totalBytesWritten = 0; - while (true) { - int bytesRead = diskis.read(buffer, 0, bufferSize); - if (bytesRead == -1) - { - System.out.println("Total bytes written: " + totalBytesWritten); - break; - } - totalBytesWritten += bytesRead; - bos.write(buffer, 0, bufferSize); - bos.flush(); - System.out.println("Total bytes written: " + totalBytesWritten); - -/* - int progressPercent = (int) (((bytesAlreadyWritten + totalBytesWritten) * 100) / totalBytes); - leaseUpdater.setPercent(progressPercent); -*/ - } - diskis.close(); - bos.flush(); - bos.close(); - conn.disconnect(); - } - - public static long addTotalBytes(OvfCreateImportSpecResult ovfImportResult) { - OvfFileItem[] fileItemArr = ovfImportResult.getFileItem(); - long totalBytes = 0; - if (fileItemArr != null) { - for (OvfFileItem fi : fileItemArr) { - printOvfFileItem(fi); - totalBytes += fi.getSize(); - } - } - return totalBytes; - } - - private static void printOvfFileItem(OvfFileItem fi) { - System.out.println("================ OvfFileItem ================"); - System.out.println("chunkSize: " + fi.getChunkSize()); - System.out.println("create: " + fi.isCreate()); - System.out.println("deviceId: " + fi.getDeviceId()); - System.out.println("path: " + fi.getPath()); - System.out.println("size: " + fi.getSize()); - System.out.println("=============================================="); - } - - public static String readOvfContent(String ovfFilePath) throws IOException { - StringBuffer strContent = new StringBuffer(); - BufferedReader in = new BufferedReader(new InputStreamReader(new FileInputStream(ovfFilePath))); - String lineStr; - while ((lineStr = in.readLine()) != null) { - strContent.append(lineStr); - } - - in.close(); - return strContent.toString(); - } - - public static String escapeSpecialChars(String str) { - str = str.replaceAll("<", "<"); - return str.replaceAll(">", ">"); // do not escape "&" -> "&", "\"" -> """ - } - - public static void main(String[] args) throws Exception { - setupLog4j(); - TestVMWare client = new TestVMWare(); - - // skip certificate check - System.setProperty("axis.socketSecureFactory", "org.apache.axis.components.net.SunFakeTrustSocketFactory"); - - String serviceUrl = "https://" + args[0] + "/sdk/vimService"; - - try { - String[] params = new String[] {"--url", serviceUrl, "--username", args[1], "--password", args[2] }; - - cb = ExtendedAppUtil.initialize("Connect", params); - cb.connect(); - System.out.println("Connection Succesful."); - _args = args; - - // client.listInventoryFolders(); - // client.listDataCenters(); - // client.powerOnVm(); - // client.createSnapshot(); - // client.registerTemplate(); - // client.createVmFromTemplate(); - // client.addNic(); - // client.addNicToNetwork(); - - // client.createDatacenter(); - // client.getPropertyWithPath(); - // client.getHostVMs(); - // client.testFT(); - // client.testFTEnable(); - - // client.importOVF(); - - // Test get DvSwitch - client.testDvSwitchOperations(); - // Test add DvPortGroup, - // Test update vPortGroup, - // Test get DvPortGroup, - // Test compare DvPortGroup - client.testDvPortGroupOpearations(); - - // Test addDvNic - // Test deleteDvNic - // client.testDvNicOperations(); - - cb.disConnect(); - } catch (Exception e) { - e.printStackTrace(); - } - } - - public static class TrustAllManager implements javax.net.ssl.TrustManager, javax.net.ssl.X509TrustManager { - - public java.security.cert.X509Certificate[] getAcceptedIssuers() { - return null; - } - - public boolean isServerTrusted(java.security.cert.X509Certificate[] certs) { - return true; - } - - public boolean isClientTrusted(java.security.cert.X509Certificate[] certs) { - return true; - } - - public void checkServerTrusted(java.security.cert.X509Certificate[] certs, String authType) - throws java.security.cert.CertificateException { - return; - } - public void checkClientTrusted(java.security.cert.X509Certificate[] certs, String authType) - throws java.security.cert.CertificateException { - return; - } - } -} -