incubator-cloudstack-users-cn mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chengh <che...@gdeii.com.cn>
Subject EC2接口访问问题
Date Fri, 14 Dec 2012 08:00:45 GMT
如果直接通过 http get 访问 json, 直接通过http heard 去访问的时候 提示key不对,
请问如何获取到API_KEY 和 secret_key ???
我在用paas cloudify 里面有个对cloudstack的驱动 需要提供 api_key 和 secret_key.
恳请大牛们回答啊




chengh

发件人: Gavin Lee
发送时间: 2012-12-14 15:22
收件人: cloudstack-users-cn
主题: Re: 关于系统VM的启动问题
Hello,
管理服务器(Management Server)可以建在虚机上.
如果主机要建在虚机上, 即所谓的二层虚拟化, 那需要做些额外的工作,
比如 KVM的主机建在Esxi上, 以下测试只针对Esxi 5.1:

1. 正常创建虚拟机。
2. 完成创建后,点击‘编辑设置’,选项―常规选项-客户端操作系统-,此处选择
 vmware esxi5.x
3. ssh登录你的 ESXI5.1 主机,编辑 你刚才创建的虚拟机的配置。
a) 修改 /etc/vmware/config,追加 下面一行
vhv.allow = ”TRUE“
b) 修改虚拟机的配置。比如你创建的centos62,那么找到此虚拟机的目录,编辑
centos62.vmx.将下面的信息追加到文件末尾。(esxi5.1的主机必须支持vt-x 和EPT)
monitor.virtual_mmu = "hardware"
monitor.virtual_exec = "hardware"
cpuid.1.ecx="----:----:----:----:----:----:--h-:----"
cpuid.80000001.ecx.amd="----:----:----:----:----:----:----:-h--"
cpuid.8000000a.eax.amd="hhhh:hhhh:hhhh:hhhh:hhhh:hhhh:hhhh:hhhh"
cpuid.8000000a.ebx.amd="hhhh:hhhh:hhhh:hhhh:hhhh:hhhh:hhhh:hhhh"
cpuid.8000000a.edx.amd="hhhh:hhhh:hhhh:hhhh:hhhh:hhhh:hhhh:hhhh"
vcpu.hotadd = "FALSE"
featMask.vm.hv.capable = "Min:1"
vhv.enable = "true"
4. 回到你的vphere或者vcenter. 右键 你刚才创建的虚拟机,点击‘升级硬件配置’,并确定。
5. 升级完成后,可以安装支持kvm的虚拟机。



On Fri, Dec 14, 2012 at 12:38 PM, 哈哈 <shoutingating@126.com> wrote:
> 环境:
> management:redhat6.2+cloudstack3.0.2+mysql+nfs
> agent:redhat 6.2 kvm
> management和agent都装在ESXi主机上,已打开虚拟化,并修改vhv.allow="TRUE"
>
>
> 搭建好后主机能识别,但是两个系统VM一直起不来,查看agent.log,报下面的错误:
>
>
> /usr/bin/build-classpath: error: Could not find commons-collections.jar Java ext
> ension for this JVM
> /usr/bin/build-classpath: error: Could not find commons-dbcp.jar Java extension
> for this JVM
> /usr/bin/build-classpath: error: Could not find commons-pool.jar Java extension
> for this JVM
> /usr/bin/build-classpath: error: Could not find ws-commons-util.jar Java extensi
> on for this JVM
> /usr/bin/build-classpath: error: Could not find jnetpcap.jar Java extension for
> this JVM
> /usr/bin/build-classpath: error: Could not find tomcat6-servlet-2.5-api.jar Java
>  extension for this JVM
> /usr/bin/build-classpath: error: Could not find tomcat6-el-2.1-api-6.0.24.jar Ja
> va extension for this JVM
> /usr/bin/build-classpath: error: Could not find tomcat6-jsp-2.1-api-6.0.24.jar J
> ava extension for this JVM
> /usr/bin/build-classpath: error: Some specified jars were not found
> Current directory is /usr/lib64/cloud/agent
> CLASSPATH to run the agent: /usr/share/java/commons-collections.jar:/usr/share/j
> ava/commons-dbcp.jar:/usr/share/java/commons-logging.jar:/usr/share/java/commons
> -logging-api.jar:/usr/share/java/commons-pool.jar:/usr/share/java/commons-httpcl
> ient.jar:/usr/share/java/ws-commons-util.jar:/usr/share/java/jnetpcap.jar:/usr/s
> hare/java/tomcat6-servlet-2.5-api.jar:/usr/share/java/tomcat6-el-2.1-api-6.0.24.
> jar:/usr/share/java/tomcat6-jsp-2.1-api-6.0.24.jar:/usr/share/java/cloud-google-
> gson-1.7.1.jar:/usr/share/java/vmware-vim25.jar:/usr/share/java/cloud-backport-u
> til-concurrent-3.0.jar:/usr/share/java/cloud-servlet-api.jar:/usr/share/java/clo
> ud-xenserver-5.6.100-1.jar:/usr/share/java/cloud-mysql-connector-java-5.1.7-bin.
> jar:/usr/share/java/cloud-iControl.jar:/usr/share/java/vmware-apputils.jar:/usr/
> share/java/vmware-vim.jar:/usr/share/java/cloud-commons-pool-1.5.6.jar:/usr/shar
> e/java/cloud-axis.jar:/usr/share/java/cloud-bcprov-jdk16-1.45.jar:/usr/share/jav
> a/cloud-commons-httpclient-3.1.jar:/usr/share/java/cloud-wsdl4j.jar:/usr/share/j
> ava/cloud-httpcore-4.0.jar:/usr/share/java/cloud-log4j.jar:/usr/share/java/cloud
> -commons-codec-1.5.jar:/usr/share/java/cloud-commons-dbcp-1.4.jar:/usr/share/jav
> a/cloud-xstream-1.3.1.jar:/usr/share/java/cloud-commons-discovery.jar:/usr/share
> /java/cloud-log4j-extras.jar:/usr/share/java/cloud-xmlrpc-common-3.1.3.jar:/usr/
> share/java/cloud-email.jar:/usr/share/java/cloud-xmlrpc-client-3.1.3.jar:/usr/sh
> are/java/jetty-util-6.1.26.jar:/usr/share/java/vmware-lib-jaxrpc.jar:/usr/share/
> java/cloud-netscaler.jar:/usr/share/java/jetty-6.1.26.jar:/usr/share/java/cloud-
> jstl-1.2.jar:/usr/share/java/cloud-cglib.jar:/usr/share/java/cloud-manageontap.j
> ar:/usr/share/java/cloud-commons-configuration-1.8.jar:/usr/share/java/cloud-com
> mons-logging-1.1.1.jar:/usr/share/java/cloud-jnetpcap.jar:/usr/share/java/cloud-
> trilead-ssh2-build213.jar:/usr/share/java/cloud-junit.jar:/usr/share/java/cloud-
> commons-lang-2.6.jar:/usr/share/java/cloud-jsch-0.1.42.jar:/usr/share/java/cloud
> -commons-collections-3.2.1.jar:/usr/share/java/cloud-ws-commons-util-1.0.2.jar:/
> usr/share/java/cloud-netscaler-sdx.jar:/usr/share/java/cloud-libvirt-0.4.5.jar:/
> usr/share/java/cloud-ehcache.jar:/usr/share/java/cloud-jasypt-1.8.jar:/usr/share
> /java/cloud-utils.jar:/usr/share/java/cloud-api.jar:/usr/share/java/cloud-core.j
> ar:/usr/share/java/cloud-server.jar:/usr/share/java/cloud-server-extras.jar:/usr
> /share/java/cloud-agent.jar:/usr/share/java/cloud-console-common.jar:/usr/share/
> java/cloud-console-proxy.jar:/usr/share/java/cloud-core-extras.jar:/usr/share/ja
> va/cloud-agent-extras.jar:/usr/share/java/jna.jar:/etc/cloud/agent
> Using manually-configured network device
> Using manually-configured network device
> Agent started.  PID: 5096
> log4j:WARN No appenders could be found for logger (com.cloud.agent.AgentShell).
> log4j:WARN Please initialize the log4j system properly.
> log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more in
> fo.
> 2012-12-11 17:05:39,798{GMT} INFO  [utils.component.ComponentLocator] (main:) Un
> able to find components.xml
> 2012-12-11 17:05:39,798 INFO  [utils.component.ComponentLocator] (main:null) Una
> ble to find components.xml
> 2012-12-11 17:05:39,800{GMT} INFO  [utils.component.ComponentLocator] (main:) Sk
> ipping configuration using components.xml
> 2012-12-11 17:05:39,800 INFO  [utils.component.ComponentLocator] (main:null) Ski
> pping configuration using components.xml
> 2012-12-11 17:05:39,800{GMT} INFO  [cloud.agent.AgentShell] (main:) Implementati
> on Version is 3.0.2.20120506223416
> 2012-12-11 17:05:39,800 INFO  [cloud.agent.AgentShell] (main:null) Implementatio
> n Version is 3.0.2.20120506223416
> 2012-12-11 17:05:39,802{GMT} INFO  [cloud.agent.AgentShell] (main:) Defaulting t
> o using properties file for storage
> 2012-12-11 17:05:39,802 INFO  [cloud.agent.AgentShell] (main:null) Defaulting to
>  using properties file for storage
> 2012-12-11 17:05:39,805{GMT} INFO  [cloud.agent.AgentShell] (main:) Defaulting t
> o the constant time backoff algorithm
> 2012-12-11 17:05:39,805 INFO  [cloud.agent.AgentShell] (main:null) Defaulting to
>  the constant time backoff algorithm
> 2012-12-11 17:05:40,086{GMT} INFO  [cloud.agent.Agent] (main:) id is
> 2012-12-11 17:05:40,086 INFO  [cloud.agent.Agent] (main:null) id is
> 2012-12-11 17:05:40,339{GMT} INFO  [resource.virtualnetwork.VirtualRoutingResour
> ce] (main:) VirtualRoutingResource _scriptDir to use: scripts/network/domr/kvm
> 2012-12-11 17:05:40,339 INFO  [resource.virtualnetwork.VirtualRoutingResource] (
> main:null) VirtualRoutingResource _scriptDir to use: scripts/network/domr/kvm
> 2012-12-11 17:05:40,359{GMT} INFO  [resource.virtualnetwork.VirtualRoutingResour
> ce] (main:) ipassoc.sh found in /usr/lib64/cloud/agent/./scripts/network/domr/ip
> assoc.sh
> 2012-12-11 17:05:40,359 INFO  [resource.virtualnetwork.VirtualRoutingResource] (
> main:null) ipassoc.sh found in /usr/lib64/cloud/agent/./scripts/network/domr/ipa
> ssoc.sh
> 2012-12-11 17:05:41,572{GMT} INFO  [resource.computing.LibvirtComputingResource]
>  (main:) agent.properties found at /etc/cloud/agent/agent.properties
> 2012-12-11 17:05:41,572 INFO  [resource.computing.LibvirtComputingResource] (mai
> n:null) agent.properties found at /etc/cloud/agent/agent.properties
> 2012-12-11 17:05:41,586{GMT} INFO  [cloud.agent.Agent] (main:) Agent [id = new :
>  type = LibvirtComputingResource : zone = 1 : pod = 1 : workers = 5 : host = 218
> .193.126.124 : port = 8250
> 2012-12-11 17:05:41,586 INFO  [cloud.agent.Agent] (main:null) Agent [id = new :
> type = LibvirtComputingResource : zone = 1 : pod = 1 : workers = 5 : host = 218.
> 193.126.124 : port = 8250
> 2012-12-11 17:05:41,628{GMT} INFO  [utils.nio.NioClient] (Agent-Selector:) Conne
> cting to 218.193.126.124:8250
> 2012-12-11 17:05:41,628 INFO  [utils.nio.NioClient] (Agent-Selector:null) Connec
> ting to 218.193.126.124:8250
> 2012-12-11 17:05:42,069{GMT} INFO  [utils.nio.NioClient] (Agent-Selector:) SSL:
> Handshake done
> 2012-12-11 17:05:42,069 INFO  [utils.nio.NioClient] (Agent-Selector:null) SSL: H
> andshake done
> libvir: Storage error : Storage pool not found: no pool with matching uuid
> 2012-12-11 17:05:42,492{GMT} INFO  [cloud.serializer.GsonHelper] (Agent-Handler-
> 1:) Default Builder inited.
> 2012-12-11 17:05:42,492 INFO  [cloud.serializer.GsonHelper] (Agent-Handler-1:nul
> l) Default Builder inited.
> 2012-12-11 17:05:42,669{GMT} INFO  [cloud.agent.Agent] (Agent-Handler-2:) Procce
> ss agent startup answer, agent id = 1
> 2012-12-11 17:05:42,669 INFO  [cloud.agent.Agent] (Agent-Handler-2:null) Procces
> s agent startup answer, agent id = 1
> 2012-12-11 17:05:42,669{GMT} INFO  [cloud.agent.Agent] (Agent-Handler-2:) Set ag
> ent id 1
> 2012-12-11 17:05:42,669 INFO  [cloud.agent.Agent] (Agent-Handler-2:null) Set age
> nt id 1
> 2012-12-11 17:05:42,671{GMT} INFO  [cloud.agent.Agent] (Agent-Handler-2:) Startu
> p Response Received: agent id = 1
> 2012-12-11 17:05:42,671 INFO  [cloud.agent.Agent] (Agent-Handler-2:null) Startup
>  Response Received: agent id = 1
> libvir: Storage error : Storage pool not found: no pool with matching uuid
> libvir: Storage error : Storage pool not found: no pool with matching uuid
> libvir: QEMU error : Unable to create cgroup for v-2-VM: No such file or directo
> ry
> 2012-12-11 17:07:01,712{GMT} WARN  [resource.computing.LibvirtComputingResource]
>  (agentRequest-Handler-1:) Failed to start domain: v-2-VM: Unable to create cgro
> up for v-2-VM: No such file or directory
> 2012-12-11 17:07:01,712 WARN  [resource.computing.LibvirtComputingResource] (age
> ntRequest-Handler-1:null) Failed to start domain: v-2-VM: Unable to create cgrou
> p for v-2-VM: No such file or directory
> 2012-12-11 17:07:01,713{GMT} WARN  [resource.computing.LibvirtComputingResource]
>  (agentRequest-Handler-1:) Exception
> org.libvirt.LibvirtException: Unable to create cgroup for v-2-VM: No such file o
> r directory
>         at org.libvirt.ErrorHandler.processError(Unknown Source)
>         at org.libvirt.Connect.processError(Unknown Source)
>         at org.libvirt.Domain.processError(Unknown Source)
>         at org.libvirt.Domain.create(Unknown Source)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.startDoma
> in(LibvirtComputingResource.java:860)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.execute(L
> ibvirtComputingResource.java:2515)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.executeRe
> quest(LibvirtComputingResource.java:985)
>         at com.cloud.agent.Agent.processRequest(Agent.java:517)
>         at com.cloud.agent.Agent$AgentRequestHandler.doTask(Agent.java:827)
>         at com.cloud.utils.nio.Task.run(Task.java:79)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.
> java:1110)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
> .java:603)
>         at java.lang.Thread.run(Thread.java:679)
> 2012-12-11 17:07:01,713 WARN  [resource.computing.LibvirtComputingResource] (age
> ntRequest-Handler-1:null) Exception
> org.libvirt.LibvirtException: Unable to create cgroup for v-2-VM: No such file o
> r directory
>         at org.libvirt.ErrorHandler.processError(Unknown Source)
>         at org.libvirt.Connect.processError(Unknown Source)
>         at org.libvirt.Domain.processError(Unknown Source)
>         at org.libvirt.Domain.create(Unknown Source)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.startDoma
> in(LibvirtComputingResource.java:860)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.execute(L
> ibvirtComputingResource.java:2515)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.executeRe
> quest(LibvirtComputingResource.java:985)
>         at com.cloud.agent.Agent.processRequest(Agent.java:517)
>         at com.cloud.agent.Agent$AgentRequestHandler.doTask(Agent.java:827)
>         at com.cloud.utils.nio.Task.run(Task.java:79)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.
> java:1110)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
> .java:603)
>         at java.lang.Thread.run(Thread.java:679)
> libvir: error : invalid argument: virStoragePoolLookupByUUIDString
> libvir: QEMU error : Unable to create cgroup for s-1-VM: No such file or directo
> ry
> 2012-12-11 17:07:14,228{GMT} WARN  [resource.computing.LibvirtComputingResource]
>  (agentRequest-Handler-4:) Failed to start domain: s-1-VM: Unable to create cgro
> up for s-1-VM: No such file or directory
> 2012-12-11 17:07:14,228 WARN  [resource.computing.LibvirtComputingResource] (age
> ntRequest-Handler-4:null) Failed to start domain: s-1-VM: Unable to create cgrou
> p for s-1-VM: No such file or directory
> 2012-12-11 17:07:14,229{GMT} WARN  [resource.computing.LibvirtComputingResource]
>  (agentRequest-Handler-4:) Exception
> org.libvirt.LibvirtException: Unable to create cgroup for s-1-VM: No such file o
> r directory
>         at org.libvirt.ErrorHandler.processError(Unknown Source)
>         at org.libvirt.Connect.processError(Unknown Source)
>         at org.libvirt.Domain.processError(Unknown Source)
>         at org.libvirt.Domain.create(Unknown Source)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.startDoma
> in(LibvirtComputingResource.java:860)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.execute(L
> ibvirtComputingResource.java:2515)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.executeRe
> quest(LibvirtComputingResource.java:985)
>         at com.cloud.agent.Agent.processRequest(Agent.java:517)
>         at com.cloud.agent.Agent$AgentRequestHandler.doTask(Agent.java:827)
>         at com.cloud.utils.nio.Task.run(Task.java:79)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.
> java:1110)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
> .java:603)
>         at java.lang.Thread.run(Thread.java:679)
> 2012-12-11 17:07:14,229 WARN  [resource.computing.LibvirtComputingResource] (age
> ntRequest-Handler-4:null) Exception
> org.libvirt.LibvirtException: Unable to create cgroup for s-1-VM: No such file o
> r directory
>         at org.libvirt.ErrorHandler.processError(Unknown Source)
>         at org.libvirt.Connect.processError(Unknown Source)
>         at org.libvirt.Domain.processError(Unknown Source)
>         at org.libvirt.Domain.create(Unknown Source)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.startDoma
> in(LibvirtComputingResource.java:860)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.execute(L
> ibvirtComputingResource.java:2515)
>         at com.cloud.agent.resource.computing.LibvirtComputingResource.executeRe
> quest(LibvirtComputingResource.java:985)
>         at com.cloud.agent.Agent.processRequest(Agent.java:517)
>         at com.cloud.agent.Agent$AgentRequestHandler.doTask(Agent.java:827)
>         at com.cloud.utils.nio.Task.run(Task.java:79)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.
> java:1110)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
> .java:603)
>         at java.lang.Thread.run(Thread.java:679)
> libvir: QEMU error : Unable to create cgroup for v-2-VM: No such file or directo
> ry
> 2012-12-11 17:07:25,849{GMT} WARN  [resource.computing.LibvirtComputingResource]
>  (agentRequest-Handler-5:) Failed to start domain: v-2-VM: Unable to create cgro
> up for v-2-VM: No such file or directory
>
>
> 开头提示缺少的包安装了还是不行,难道cloudstack一定要装在物理机才行嘛



-- 
Gavin
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message