Colors of Ray+Hue'

KVM xml 에디트

virtualization2016. 3. 22. 03:58



xml file 위치: /etc/libvirt/qemu

CPU 개수 바꾸기 


    sed -i "s/<vcpu>1/<vcpu>2/g" /etc/libvirt/qemu/vm1.xml


1. vhd 이름이 여러개 일 경우, 


#!/bin/bash


for (( i=$1 ; i <= $2 ; i++  )) ;

do

    echo " vm$i: <vcpu>1 --> <vcpu>2 "

    sed -i "s/<vcpu>1/<vcpu>2/g" /etc/libvirt/qemu/vm$i.xml


    # validation

    echo " vm$i ... validation"

    grep -RE "<vcpu>" /etc/libvirt/qemu/vm$i.xml


2. 여러개의 vm을 실행시킬때 


#!/bin/bash


for (( i=1 ; i <= $1 ; i++  )) ;

do

    echo "virsh start vm$i" ; 

    virsh start vm$i ;

done


3. 여러개 vm의 커넥션을 확인 할때,


#!/bin/bash


for (( i=1 ; i <=$1 ; i++  )) ;

do

    echo "ssh  jm@vm$i" ; 

    ssh  jm@vm$i "echo vm$i is connected"

done


4. 여러개의 vm을 잠깐 정지


#!/bin/bash


for (( i=$1 ; i <= $2 ; i++  )) ;

do

    echo "virsh suspend vm$i" ; 

    virsh suspend vm$i ;

done


5. 여러개의 vm을 다시 진행


#!/bin/bash


for (( i=$1 ; i <= $2 ; i++  )) ;

do

    echo "virsh resume vm$i" ; 

    virsh resume vm$i ;

done


6. 여러개의 vm을 종료 


#!/bin/bash


for (( i=1 ; i <= $1 ; i++  )) ;

do

    echo "virsh shutdown vm$i" ; 

    virsh shutdown vm$i ;

done


7. 여러개의 vm을 강제종료


#!/bin/bash


for (( i=1 ; i <= $1 ; i++  )) ;

do

    echo "virsh destroy vm$i" ; 

    virsh destroy vm$i ;

done


8. speccpu test (같은 환경을 vm내에 구축할 시에만 동작)


#!/bin/bash


for (( i=1 ; i <=$1 ; i++  )) ;

do

    echo "ssh  jm@vm$i" ; 

    ssh  jm@vm$i "echo vm$i is connected"

#    scp /work/execute.sh jm@vm$i:/work/

#    ssh  jm@vm$i "cd /work && time -p ./execute.sh 1 >> time.temp"

    ssh  jm@vm$i 'rm -rf /work/dlog$i && echo "dlog$i: data log file is deleted"'

    ssh  jm@vm$i 'rm -rf /work/tlog$i && echo "tlog$i: time log file is deleted"'

    ssh  jm@vm$i "cd /work && /usr/bin/time -p --output=/work/tlog$i ./execute.sh 1 >> dlog$i" & 

    

done



9. 하나의 vm에서 여러개의 vm을 생성 할때 (--original 원본 vm 이름, --name 생성할 vm 이름, --file 생성할 이미지 이름)


 for (( i =1 ;  i< 33 ; i++ )) ; do  echo "virt-clone --original u13 --name vm$i --file uvm$i" ; virt-clone --original u13 --name vm$i --file uvm$i ; done

'virtualization' 카테고리의 다른 글

SPEC virt working history  (0) 2016.02.09
KVM on ubuntu  (0) 2016.02.03
kvm bridge on ubuntu  (0) 2016.01.28
ESXi remote shell 설정 (ESXi 5.5)  (0) 2015.11.12
ESX  (0) 2015.11.07

1./opt/SPECvirt/webInit.sh

starting httpd: httpd: Could not reliably determine the server's fully qualified domain name, using 20.20.20.3 for ServerNam


--> /etc/httpd/conf/httpd.conf 수정

--> www.yourwebserver.com:80 주석 풀어주기

--> check the duplication of Listen:81 on /etc/httpd/conf/httpd.conf, 여러번 실행하다 보면 중복된다. (by makeme_infraserver.sh)


update

--> infraserver에서 

--> /etc/httpd/conf/httpd.conf

--> line 1018: Listen 81

--> line 1019: ServerName: *:81

일단 서프넷 모든 아이피에 존재하는 81포트는 무조건 client로 처리한다. --> 에러 발생 그냥 servername warning 을 그냥 놔둔다.



2. jAppInitRstr.sh

- ssh: Could not resolve hostname specdriver: Name or service not known


- + ssh specdelivery -n 'cd /opt/SPECjAppServer2004/bin;./appsrv-ctrl.sh stop'

  CLI306: Warning - The server located at /opt/glassfish4/glassfish/domains/spec2004-1 is not running.


- Feb 08, 2016 11:09:01 AM org.apache.catalina.startup.Catalina stopServer

  SEVERE: Could not contact localhost:8005. Tomcat may not be running


- SEVERE: Catalina.stop: 

  java.net.ConnectException: Connection refused

at java.net.PlainSocketImpl.socketConnect(Native Method)

at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)

at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200)

at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182)

at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)

at java.net.Socket.connect(Socket.java:579)

at java.net.Socket.connect(Socket.java:528)

at java.net.Socket.<init>(Socket.java:425)

at java.net.Socket.<init>(Socket.java:208)

at org.apache.catalina.startup.Catalina.stopServer(Catalina.java:498)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:606)

at org.apache.catalina.startup.Bootstrap.stopServer(Bootstrap.java:370)

at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:457)


- + ssh specdb /usr/pgsql-9.2/bin/psql -U spec specdb

  bash: /usr/pgsql-9.2/bin/psql: No such file or directory


- + ssh specdriver 'echo "`date`: Ending jappInitRstr.sh"'

  ssh: Could not resolve hostname specdriver: Name or service not known


--> 서버커넥션을 보통 한번에 못한다. 따라서 두번 이상 restart_service.sh 를 반복한다. 


3. Client Error Message


3.1-->For txRate(100), loadFactor(5), and load_scale_factor(1.0), your DBIR must be built for 500IR

3.2-->SPECweb_Support: [ERROR] STATE 3; makeHttpRequest() failed

3.3-->[ERROR] SocketTimeoutException encountered during run

3.4-->Connection: Still expecting 8054 bytes. Expected length is 57408 bytes, but only received 49354 bytes

3.5-->SPECweb_Support: [ERROR] STATE 6; RESPONSE INVALID on GET /support/downloads/dir0000000240/download6_0 HTTP/1.1




'virtualization' 카테고리의 다른 글

KVM xml 에디트  (0) 2016.03.22
KVM on ubuntu  (0) 2016.02.03
kvm bridge on ubuntu  (0) 2016.01.28
ESXi remote shell 설정 (ESXi 5.5)  (0) 2015.11.12
ESX  (0) 2015.11.07

KVM on ubuntu

virtualization2016. 2. 3. 11:52

bridge setting


- click the (i) button on right side from monitor icon. 

- add virtual NIC

- eth0 is for virbr0 (default), eth1 is for br0 (network bridge)

인터넷도 하면서 내부통신이 가능하다. 



'virtualization' 카테고리의 다른 글

KVM xml 에디트  (0) 2016.03.22
SPEC virt working history  (0) 2016.02.09
kvm bridge on ubuntu  (0) 2016.01.28
ESXi remote shell 설정 (ESXi 5.5)  (0) 2015.11.12
ESX  (0) 2015.11.07

http://4008.tistory.com/50

http://skylit.tistory.com/116 --> virbr0 다시 살리는 방법 on 우분투 desktop


'virtualization' 카테고리의 다른 글

KVM xml 에디트  (0) 2016.03.22
SPEC virt working history  (0) 2016.02.09
KVM on ubuntu  (0) 2016.02.03
ESXi remote shell 설정 (ESXi 5.5)  (0) 2015.11.12
ESX  (0) 2015.11.07

Use the vSphere Client to enable local and remote access to the ESXi Shell:

  1. Log in to a vCenter Server system using the vSphere Client.
  2. Select the host in the Inventory panel.
  3. Click the Configuration tab and click Security Profile.
  4. In the Services section, click Properties.
  5. Select ESXi Shell from this list:

    ESXi Shell
    SSH
    Direct Console UI


  6. Click Options and select Start and stop manually.

    Note: When you select Start and stop manually, the service does not start when you reboot the host. If you want the service to start when you reboot the host, select Start and stop with host.

  7. Click Start to enable the service.
  8. Click OK.


'virtualization' 카테고리의 다른 글

KVM xml 에디트  (0) 2016.03.22
SPEC virt working history  (0) 2016.02.09
KVM on ubuntu  (0) 2016.02.03
kvm bridge on ubuntu  (0) 2016.01.28
ESX  (0) 2015.11.07

ESX

virtualization2015. 11. 7. 05:23

https://www.youtube.com/watch?v=HtNJD5cDpL8


'virtualization' 카테고리의 다른 글

KVM xml 에디트  (0) 2016.03.22
SPEC virt working history  (0) 2016.02.09
KVM on ubuntu  (0) 2016.02.03
kvm bridge on ubuntu  (0) 2016.01.28
ESXi remote shell 설정 (ESXi 5.5)  (0) 2015.11.12