This blog is mainly recording environment configuration and download some software (ubuntu version 18.04.3) Personal use ubuntu:
Article Directory
Graphics driver installation
Sometimes just installed ubuntu system startup stuck, the Internet, said the problem is not ubuntu nvidia graphics driver, you need to install the graphics driver N card.
- Guide interface at boot grub press
e
enter the edit mode,quiet splash
followed bynomodeset
press F10 to enter the system (refer to this blog ); every start without need to re-install the graphics driver image, then this setting. - After entering the system is installed N card reference this blog , using ppa source installation; but it is possible ppa download very slow, can the head loss Sheriff network query download driver
download directory into the finished download, open a terminal, change the file properties to drive its plus execute permissionssudo chmod a+x NVIDIA-Linux-x86_64-440.59.run
, and then execute the file with administrator privilegessudo ./NVIDIA-Linux-x86_64-440.59.run
to install.
Or may also be in software and updates - choose the machine driving the additional drive, to apply the changes.
Download Source Replacement
To avoid downloading from abroad ubuntu server command line to install the software turtle speed, download source software need to be replaced to improve the download speed of the software. Generally newly installed will be prompted to update some software, the replacement may wish to download the source, and faster time to update this software.
- Method 1: Manually change the download source profile.
Ctrl+Alt+T
Call up the terminal, enter the following command to openapt
the package download manager source profile
Then open the file in all source.list empty the contents (if any), enter the following will download the source for the replacement of Tsinghua mirror source (can be replaced with other image sources, such as Ali mirror source):sudo gedit /etc/apt/source.list
# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释 deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic main restricted universe multiverse # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic main restricted universe multiverse deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-updates main restricted universe multiverse # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-updates main restricted universe multiverse deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-backports main restricted universe multiverse # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-backports main restricted universe multiverse deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-security main restricted universe multiverse # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-security main restricted universe multiverse # 预发布软件源,不建议启用 # deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-proposed main restricted universe multiverse # deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ bionic-proposed main restricted universe multiverse ```
Save close, after performing sudo apt update
the update source
- 方法2:自动选择最佳源
在所有程序中打开软件和更新
,去掉其他软件中的所有选项,选中ubuntu软件中的所有选项
下载自-其他站点-选择最佳服务器;完了关闭之后重新载入即可。
wine的安装与微信安装
wine是wine is not emulator的简称,是一个在linux上运行windows应用的软件。尽管很多windows下的软件都有linux对应版本,但是微信以及office套件之类的少部分但是不可或缺的软件在linux下还是缺席的,所以需要wine这样的东西来运行windows程序以弥补。以下参考知乎上的这篇文章
- 安装winehq,参考winehq官网安装教程(如果打不开,上面的的知乎文章安装的也差不多)
- 安装winetricks
- 配置wine bottle
- 修改默认.desktop链接
ubuntu下使用wine安装微信就是个巨坑,不要轻易尝试
- 我一开始是直接
sudo apt install wine
安装的,成功安装了wine的3.0版本,但是后来发现3.0版本安装的微信不一会就卡死 - 然后按照网上教程卸载低版本wine,但是wine这个东西怎么也卸载不掉;不管了,直接安装高级版本的,但是高版本的怎么都安不上,不管是直接用的官网的方法,还是用的deepin版本的,都失败了,瞎折腾了一晚上
一个不完美的且不知道怎么就成了的解决方案
- 安装wine。如上所述,我安装最新版本的wine失败了,卸载旧版的也失败了,所以还是用的3.0版本的,安装方法就是
sudo apt install wine
,可能还需要添加下载源之类的,反正安装3.0的很简单 - 安装PlayOnLinux。
- playonlinux其实就是个前端,它以wine为后端,在我看来它相当于个应用商店和虚拟系统的管理器,在上面可以方便地安装一些上面有的应用以及自己下的windows下的
.exe
安装包,还可以方便地进行一些虚拟windows系统设置,比如设置程序分辨率、编辑注册表、打开任务管理器、使用windows命令行、卸载程序等 - 安装方法以及在playonlinux上安装微信参考链接
- playonlinux其实就是个前端,它以wine为后端,在我看来它相当于个应用商店和虚拟系统的管理器,在上面可以方便地安装一些上面有的应用以及自己下的windows下的
- 安装微信的依赖项。打开playonlinux,
- 打开playonlinux,打开配置
- 选择
安装内容
,安装一些依赖项。以为我不知道缺什么依赖项,就把所有的都安装上了,过程当中有些下载失败,没安上;有些可能不兼容啥的原因没安上;最后可以在配置wine中查看安上了哪些库
以及在wine control中可以查看与卸载程序
- 打开playonlinux,打开配置
- 经过上述步骤,微信莫名其妙就能运行了。但是安装的qq不幸不能用。上面的步骤中我也不知道是哪些依赖项起了作用,总之把一些msvc、vc、vb、dotnet以及一些名字奇奇怪怪的库都装上试一下。
搜狗输入法安装
- 安装,参考这篇教程,全图形操作,不需要输入命令
- 如果没有安装fcitx,无法在语言支持中切换键盘输入法系统为fcitx,可参考这篇教程解决(我的已经装了fcitx,所以这个没有测试)
- 如果第1步安装过程中配置当前输入法时提示没有安装图形界面,将使用文本界面,则按照提示安装输入法配置的图形界面,使用
sudo apt install 软件
安装fcitx-config-gtk
或fcitx-config-gtk3
或fcitx-configtool
- 安装完搜狗输入法户出现中文乱码问题,参考这篇文章解决
- 安装完搜狗输入法无法通过page up,page down切换待选词。点击配置-全局配置即可设置
上一页
,下一页
的快捷键。
其他一般软件的安装
一般以以下次序以此尝试:
- 使用apt包管理器安装。
sudo apt install 软件名
(如果安装失败,一般可解决的错误apt会给出提示,按照提示执行命令即可;也可能是软件名拼写错误,或是apt包管理器中没有该软件,没有该软件的话尝试下一项) - 使用snap宝管理器安装。
sudo snap install 软件名
(如果没有snap宝管理器,可先执行sudo apt install snap
安装;snap管理器安装失败基本也像apt一样,如果是snap宝管理器中没有该软件,尝试下一项) - 从网站上下载安装包。一般可以在网上直接搜相应软件进入其官网下载对应版本即可(Ubuntu是Linux版本中的
.deb
后缀版本),下载安装包后进入下载目录,在当前目录下执行sudo apt install ./刚刚下载的软件名称.deb
,即可安装。有些软件下载后是.sh
结尾的,这是一个脚本,执行命令sudo sh ./刚刚下载的文件.sh
。有些下载的是.run
结尾的,可以更改该文件的权限,赋予其执行权限:sudo chmod a+x 下载文件名.run
;然后执行该文件:sudo ./下载文件名.run
;如果该安装包还是更奇怪的一些类型,可以查看网站上相关的安装说明。 - 从源码编译安装。这个一般有固定步骤:从github上下载源码,进入源码文件夹下,创建一个
build
目录,进入该目录下,执行cmake ..
进行编译指令生成,执行make
编译源代码,执行sudo make install
执行安装步骤。有的项目需要其他一些依赖项,可以查看项目的Readme.md
获取具体的编译、安装步骤。
关于4从源码安装: Because the installation did not go through the package manager, and finally remove the software if you want to uninstall, then will be very troublesome from the source, so I do not recommend using the direct sudo make install
command installed directly recommended bycheckinstallGenerating .deb
installation package to install.
sudo apt install checkinstall
Install checkinstall- The general steps for a source program, the general use cmake to build and install is: New in source main directory build folder into the folder Executive
cmake ..
generate MakeFiles, executemake
compile the source code, then executesudo make install
to install (in fact, the relevant documents copied to various directories go), and finally if you do not want this software can performsudo make uninstall
to uninstall, but only in the source author wrote this command only when the unloading operation with, and often source the authors did not write. - MakeFiles generation and compilation process when using checkinstall to install the same program (but not use the new compiler build a directory, the directory name because this is the last name of the software packaged into the above, not all open source software is packaged you to build the software to?). When using the installation
sudo checkinstall
placesudo make install
, then execution will pop up a series of packaged configuration issues, etc., in accordance with the prompts y / n can; be a packaged finished in the current directory.deb
packet, and the software has been installed. Uninstall can be usedsudo dpkg -r 软件名
, or other package manager to uninstallsudo apt remove 软件名
.