zoukankan      html  css  js  c++  java
  • Ubuntu虚拟机安装

    曾经多次安装Ubuntu虚拟机,但是都没有将安装遇到的问题进行总计,这次准备搭建hadoop集群,因此又折腾起来。将安装遇到的问题,进行总结。

    使用Ubuntu10.04LTS镜像。

    安装完成后,先配置成国内更新源

    由于默认情况下没有vim可用,因此先用gedit进行文本可视化编辑。

    sudo gedit /etc/apt/sources.list

    将需要的源拷贝进入此list中:

    ## 163 sources
    deb http://mirrors.163.com/ubuntu/ trusty main restricted universe multiverse
    deb http://mirrors.163.com/ubuntu/ trusty-security main restricted universe multiverse
    deb http://mirrors.163.com/ubuntu/ trusty-updates main restricted universe multiverse
    deb http://mirrors.163.com/ubuntu/ trusty-proposed main restricted universe multiverse
    deb http://mirrors.163.com/ubuntu/ trusty-backports main restricted universe multiverse
    deb-src http://mirrors.163.com/ubuntu/ trusty main restricted universe multiverse
    deb-src http://mirrors.163.com/ubuntu/ trusty-security main restricted universe multiverse
    deb-src http://mirrors.163.com/ubuntu/ trusty-updates main restricted universe multiverse
    deb-src http://mirrors.163.com/ubuntu/ trusty-proposed main restricted universe multiverse
    deb-src http://mirrors.163.com/ubuntu/ trusty-backports main restricted universe multiverse
    
    ## ali source
    deb http://mirrors.aliyun.com/ubuntu/ utopic main restricted universe multiverse
    deb http://mirrors.aliyun.com/ubuntu/ utopic-security main restricted universe multiverse
    deb http://mirrors.aliyun.com/ubuntu/ utopic-updates main restricted universe multiverse
    deb http://mirrors.aliyun.com/ubuntu/ utopic-proposed main restricted universe multiverse
    deb http://mirrors.aliyun.com/ubuntu/ utopic-backports main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ utopic main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ utopic-security main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ utopic-updates main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ utopic-proposed main restricted universe multiverse
    deb-src http://mirrors.aliyun.com/ubuntu/ utopic-backports main restricted universe multiverse
    
    ## osChina sources
    deb http://mirrors.oschina.net/ubuntu/ utopic main restricted universe multiverse
    deb http://mirrors.oschina.net/ubuntu/ utopic-security main restricted universe multiverse
    deb http://mirrors.oschina.net/ubuntu/ utopic-updates main restricted universe multiverse
    deb http://mirrors.oschina.net/ubuntu/ utopic-proposed main restricted universe multiverse
    deb http://mirrors.oschina.net/ubuntu/ utopic-backports main restricted universe multiverse
    deb-src http://mirrors.oschina.net/ubuntu/ utopic main restricted universe multiverse
    deb-src http://mirrors.oschina.net/ubuntu/ utopic-security main restricted universe multiverse
    deb-src http://mirrors.oschina.net/ubuntu/ utopic-updates main restricted universe multiverse
    deb-src http://mirrors.oschina.net/ubuntu/ utopic-proposed main restricted universe multiverse
    deb-src http://mirrors.oschina.net/ubuntu/ utopic-backports main restricted universe multiverse

    此时需要update及upgrade,否则会报如下错误:

    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    Package vim is not available, but is referred to by another package.
    This may mean that the package is missing, has been obsoleted, or
    is only available from another source

    所以,update以及upgrade先:

    sudo apt-get update
    sudo apt-get upgrade

    update时候会报类似“wick”的错误提示,可以忽略。然后进入漫长的等待upgrade。

    [后来发现,不用upgrade,直接update之后,就可以安装自己需要的工具了,如vim、git等]

    sudo apt-get install git
    sudo apt-get install vim

    upgrade会将一些常见的基础以及依赖都更新下来。

    PS:ubuntu官方的下载速度都可以在2.5MB/s,真是良心。

  • 相关阅读:
    南大《软件分析》课程笔记——Intermediate Representation
    leetcode刷题
    shiro550反序列化分析
    南大《软件分析》课程笔记——第一课
    再见2020
    S2-002漏洞分析
    编码&解码工具
    正码、反码和补码
    Java数据结构(二)
    Java数据集合
  • 原文地址:https://www.cnblogs.com/crafet/p/4656281.html
Copyright © 2011-2022 走看看