zoukankan      html  css  js  c++  java
  • centos6.7 安装 virtualBox 再安装 centos 7

    Tag: 黄色为自己实际情况需要设置的部分,绿色部分为虚拟机名称(自定义)

    1.创建虚拟机
    VBoxManage createvm --name centos7 --ostype Linux26_64 --register --basefolder /home/virtualbox/

    VBoxManage list ostypes(查看支持的操作系统类型)

    2.创建磁盘
    VBoxManage createvdi --filename /home/virtualbox/centos7.vdi --size 40000

    3.创建硬盘控制器
    VBoxManage storagectl centos7 --name storage_controller_1 --add ide

    4.挂载虚拟机硬盘
    VBoxManage storageattach centos7 --storagectl storage_controller_1 --type hdd --port 0 --device 0 --medium /home/virtualbox/centos7.vdi

    5.挂载虚拟机光驱(操作系统镜像)
    VBoxManage storageattach centos7 --storagectl storage_controller_1 --type dvddrive --port 1 --device 0 --medium /home/download/VirtualBox/CentOS-7-x86_64-Minimal-1804.iso

    6.设置启动顺序,光驱第一,硬盘第二
    VBoxManage modifyvm centos7 --boot1 dvd
    VBoxManage modifyvm centos7 --boot2 disk

    7.创建桥接的网络
    VBoxManage modifyvm centos7 --nic1 bridged --cableconnected1 on --nictype1 82540EM --bridgeadapter1 p2p1 --intnet1 brigh1 --macaddress1 auto

    8.开启vrde 模块(关闭),需要安装VirtualBox 扩展模块,以支持RDP协议,镜像桌面连接
    VBoxManage modifyvm centos7 --vrde on
    VBoxManage modifyvm centos7 --vrde off(暂时不用)

    9.设置虚拟机内存和CPU
    VBoxManage modifyvm centos7 --memory 8192
    VBoxManage modifyvm centos7 --cpus 2

    10.启动虚拟机
    VBoxManage -startvm centos7 -type headless (后台启动)

    ps: 更新宿主机操作系统内核 yum -y install kernel

  • 相关阅读:
    第四次实验报告
    第三次实验报告
    第五章 循环结构课后反思
    第二次实验报告
    5-508寝室第六小组课后习题作业
    第一次实验报告
    第九章 构造数据类型实验
    第八章 指针实验
    第七章 数组实验
    第六章 函数和宏定义实验(2)
  • 原文地址:https://www.cnblogs.com/yako/p/9264912.html
Copyright © 2011-2022 走看看