zoukankan      html  css  js  c++  java
  • ubuntu12.04 + virtualbox

    今天启动virtualbox,竟然报错, 并提示运行/etc/init.d/vboxdrv setup , 但运行完了报错:

    * Stopping VirtualBox kernel modules [ OK ]
    * Uninstalling old VirtualBox DKMS kernel modules [ OK ]
    * Trying to register the VirtualBox kernel modules using DKMS Error! Your kernel headers for kernel 3.2.0-65-generic cannot be found.
    Please install the linux-headers-3.2.0-65-generic package,
    or use the --kernelsourcedir option to tell DKMS where it's located

    * Failed, trying without DKMS
    * Recompiling VirtualBox kernel modules
    * Look at /var/log/vbox-install.log to find out what went wrong    //去日志里面查了, kernel header 未找到问题

    百度查了一下 , 发现有人用VMware Tools也碰到过类似的问题 , 

    先检查:

    uname -a   //查看当前kernel版本

    解决方案

     sudo apt-get update                         // 更新

     sudo apt-get autoremove                 //  删除没有用的           报错会提示运行sudo apt-get -f install    //  Error: Unmet dependencies. Try using -f.

     sudo apt-get install build-essential   //  编译程序有了这个软件包 它才知道 头文件在哪 才知道库函数在哪  关于build-essential作用见备注链接

    sudo apt-get install linux-headers-3.2.0-65-generic // 安装对应版本的,如果不知道自己当前kernel版本,可以用uname -a查看

    sudo /etc/init.d/vboxdrv setup         //成功了 , 说明它找到对应的header了

    备注链接:

    http://baike.baidu.com/view/4126257.htm?fr=aladdin  //讲DKMS的

    http://www.cppblog.com/wuxu/archive/2013/10/25/203913.html  //VMware Tools碰到同样问题的人

    http://blog.163.com/zhangjinqing1234@126/blog/static/307302602009538137113  //build-essential作用

    1、以专家为榜样,不必自己重新探索
    2、解构技能,找出实现80%效果的那20%
    3、不要一心二用
    4、练习练习再练习!然后获得即时反馈
    5、坚持,不要在低谷期放弃
  • 相关阅读:
    滴滴快车奖励政策,高峰奖励,翻倍奖励,按成交率,指派单数分级(4月19日)
    2016年小升初海淀区全部初中排名分析
    LVM Linear vs Striped Logical Volumes
    Spring Data Redis实现消息队列——发布/订阅模式
    Redis Pubsub命令用法
    mysql 截取身份证出生日期
    MA均线组合
    Eclipse代码格式化规范
    JSON Web Token实际应用
    JSON Web Token单点登录设计
  • 原文地址:https://www.cnblogs.com/zhongyuan/p/3822286.html
Copyright © 2011-2022 走看看