【问题收录】Ubuntu(14.04)那些我遇到的各种事
1.“启动会话失败”的解决方法1.1问题描述在登录的时候输入密码总是出现启动会话失败的提示 1.2 解决方案按住 ctrl + Alt + F1 进入到tty 输入你自己的用户名 之后输入如下命令: sudo apt-get install ubuntu-session 这个办法应对于删东西时auto-remove把session删了的情况 最后: sudo shutdown -r now 或者是: sudo reboot Ubuntu Recovery Mode怎么进入到安全模式: (注:图片来自网上) 点击进入到recovery mode 之后我们可以看到下面的界面: resume Resume normal boot clean Try to make free space dpkg Repair broken packages fsck Check all file systems grub update grub bootloader network Enable networking root Drop to root shell prompt system-summary System summary * 3. Starting the Winbind daemon winbind [fail] 解决方案*首先可以选择进入tty模式,或者是recovery mode sudo dpkg --configure -a sudo apt-get -f install 如果失效,输入下面的语句 strace -f dpkg --configure winbind 2>&1 | grep execve 重启: sudo reboot 参考连接: https://ubuntuforums.org/showthread.php?t=1593333 4. Starting SMB/CIFS File and Active Directory Server. [FAIL]安装smaba: sudo apt-get smaba Starting SMB/CIFS File and Active Directory Server. [FAIL] 解决方案: echo manual |sudo tee /etc/init/samba-ad-dc.override 5. 安装桌面环境如果某些情况下Ubuntu的桌面环境垮了,或者说在安装完系统之后没有出现桌面环境,这个时候我们需要重新安装整个图形界面,和桌面环境。 一般这种情况,我是进入到recovery mode 中选择root选项直接安装的,或者是在tty这个模式下安装的 sudo apt-get install gdm 或者安装一个轻量级的 sudo apt-get install lightdm 安装完这个时候的呢,你会得到一个图形界面,但是并没有其他东西,也就是说你能看到一个桌面,但是这个桌面上什么 也没有,没有状态栏,没有桌面图标,等等,就是一个非常干净的桌面,这个时候我们可以为我们的Ubuntu安装桌面系统 一般我采取的命令就是下面这个 sudo apt-get install ubuntu-desktop 还有不同的版本可以自己选择 輕巧的桌面環境Xfce ubuntu:~$ sudo apt-get install xubuntu-desktop KDE桌面環境 ubuntu:~$ sudo apt-get install kubuntu-desktop 亲测有效 当然还有其他的方法,然而可能是因为我之前少了什么库,所以没有成功。主要是自己拿自己的电脑开刀,各种删,我也不知道少了什么。 参考其他的人的方法如下操作: sudo apt-get install gnome-applets gnome-panel gnome-session gnome-terminal nautilus metacity gdm firefox 或者是: sudo apt-get install gnome-desktop 参考文献: http://blog.lefthander.tw/2010/03/ubuntu-server.html http://www.voidcn.com/article/p-fzozfdns-mg.html 6. Install with sudo app-get install doesn’t work,“Not using locking for read only file /var/lib/dpkg/lock” 当我们在安装某个东西的时候如果提示出:
这个时候的解决办法就是: sudo mount -o remount,rw / 7. apt-get update fails to fetch files,“Temporary failure resolving …” error 参考文献 https://askubuntu.com/questions/91543/apt-get-update-fails-to-fetch-files-temporary-failure-resolving-error 我进入到recovery mode模式下修复了一下我可能出问题的包就好了。 然后: sudo apt-get clean 之后是: sudo apt-get update 如果我们知道我们要添加的源我们可以下面这么做 假设我们要添加一个临时的DNS 的服务器到我们的系统中,我们可以这么做: 假设我们添加Google的DNS服务器: echo "nameserver 8.8.8.8" | sudo tee /etc/resolv.conf > /dev/null 之后更新一下; sudo apt-get update 如果永久的添加一个已知的DNS的服务到我们的系统,我们可以这么做: echo "nameserver 8.8.8.8" | sudo tee /etc/resolvconf/resolv.conf.d/base > /dev/null 这个时候我们需要更新安装包的下载源的文件: sudo vi /etc/apt/sources.list 假设那个旧的源是 deb http:/archive.canonical.com/ natty backports 我们可以直接替换掉旧的这个下载源的网站。 或者根据之前我们做的操作,对这行注释,就是加一个#上去。 #deb http:/archive.canonical.com/ natty backports 保存我们的文档,之后重新更新: sudo apt-get update && sudo apt-get upgrade 参考文献: http://www.voidcn.com/article/p-qasrnsdt-mc.html 8. Failed to get canonical path of /cow 问题描述: 对于ubuntu 14.04来说: mount /dev/sda1 /mnt chroot /mnt update-grub2 Ubuntu16.04 mount /dev/sda1 /mnt for dir in /dev /dev/pts /proc /sys /run; do mount --bind $dir /mnt$dir done chroot /mnt update-grub2 参考文献 https://askubuntu.com/questions/254491/failed-to-get-canonical-path-of-cow (编辑:台州站长网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |