zoukankan      html  css  js  c++  java
  • Build VM Cluster on CentOS Host

    Host Machine

    [root@bocoty49 ~]# lsb_release -a LSB Version: :base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch Distributor ID: CentOS Description: CentOS release 6.4 (Final) Release: 6.4 Codename: Final

    VirtualBox

    AMD64 version of "Oracle Linux 6("OL6")/Red Hat Enterprise Linux 6("RHEL6")/CentOS 6" on download page of VirtualBox website File name: VirtualBox-4.3-4.3.8_92456_el6-1.x86_64.rpm

    Vagrant

    CentOS/RedHat/Fedora 64-bit Vagrant Installer on Vagrant download page File name: vagrant_1.4.3_x86_64.rpm

    Usage

    1. Install Virtualbox and vagrant;

    2. When 'vagrant up', a "vboxdrv kernel module is not loaded" error raise,

    The "Release" of yum info kernel-headers is "431.5.1.el6", which mismatched the result of uname -r(2.6.32-358.23.2.el6.x86_64), so kernel-headers package is unavailable to the current kernel. The solution is update the kernel release to match the packages:

    # yum update    (this will install kernel-2.6.32-431.5.1.el6.x86_64)
    # reboot (after reboot `uname -r` returns "2.6.32-431.5.1.el6.x86_64", too)
    # yum install gcc
    # yum install kernel-devel
    # /etc/init.d/vboxdrv setup  (Recompiling VirtualBox kernel modules)
    
    1. vagrant up again. The network for the VM is "bvtserver.vm.network :public_network", which is suspent when configuring the network. I change the type of network to "host-only":

      production.vm.network "private_network", ip: "192.168.50.5", virtualbox__intnet: "gcptest-network"

    Now you can use ssh between each other via host-only NIC, and use apt-get to install packages via NAT NIC, so cool!

  • 相关阅读:
    Netty学习(四)-TCP粘包和拆包
    Netty学习(三)-Netty重要接口讲解
    Netty学习(二)-Helloworld Netty
    Netty学习(一)-为什么选择Netty
    java学习-NIO(五)NIO学习总结以及NIO新特性介绍
    java学习-NIO(四)Selector
    哈希表 HashTable(又名散列表)
    设计模式-外观模式
    设计模式-装饰模式
    设计模式-适配器模式
  • 原文地址:https://www.cnblogs.com/darkmatter/p/3605582.html
Copyright © 2011-2022 走看看