62. 双系统安装:win10 + ubuntu 18.04
说明
以 Dell 游匣 为例
设置BIOS
进入BIOS,每台机型都不同,这里以戴尔为例,按住
F2
将
Setting-System Configuration-SATA Operation
设置为AHCI
Secure Boot-Secure Boot Enable
设置为Disabled
Apply - Exit
安装 win10
下载
微PE
(由于微PE比较干净,不会强制安装软件,且版本为win10PE,由于低版本的会出现很多问题,如:硬盘识别不出来;U盘识别不出来……),点击这里下载微PE使用键盘快捷键,进入PE
将系统盘(或者全部的盘(想删除干净的话)) 删除分区,提交
快速建立分区(一定要用这个,否则没有引导)
【注意】:如果要是安装双系统,并且在固态上安装 ubuntu 系统,那么,要分成两个区,删除其中的一个,不要弄成一个区,然后,==压缩卷==,这样的话,系统就会出现bug:安装完 ubuntu 之后,win10 就坏了
还原win10镜像系统
安装 Ubuntu 18.04
- 首先,在官网下载镜像,点击这里下载;
- 使用
UltraISO
制作系统盘(或者使用rufus
制作,具体百度吧): - 开始装系统:
按住
F12
,选择UEFI
选择:
Install Ubuntu
选择中文简体-继续
键盘布局默认选择-继续
不联网-继续
更新和其他软件-默认-继续
安装类型-其它选项-继续
分区:
以系统安装在固态为例
- 单击
固态的空闲内存
(此处为51636),点+
, 挂载点选/
,ok - 单击
机械硬盘的空闲内存
(此处为216372),点+
,输入200000(大约以这个比例输入),挂载点选/home
,ok - 单击
剩余的空闲内存
(此处为16372),点+
,设置为用于交换空间
,点现在安装
,继续;
- 单击
都安装在机械硬盘:
- 类似于上面,更加简单而已,
大小
类比于安装Ubuntu 18.04 - 3.8.1
。
- 类似于上面,更加简单而已,
继续安装
位置-默认
设置用户名和密码,密码一定要记住
重启
重启,如果卡住了,就直接用电源强心关机,然后再开机,这个没关系的,放心弄就行
配置 Ubuntu
(非常重要)
进入
Ubuntu高级设置
进入
Ubuntu,with Linux 4.10.0-15-generis (recovery mode)
(第二个)进入
resume resume normal boot
回车,继续进入此时,已经进入了Ubuntu了
运行以下命令:
1
2sudo apt-get update
sudo apt-get install -f1
2sudo su
sudo gedit /etc/defaul/grub得到下图:
【补】:全部命令
找到
GRUB_CMDLINE_LINUX_DEFAULT
这一行,在quiet splash
后面添加nouveau.modeset=0
下面是我的电脑的grub配置:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
# info -f grub -n 'Simple configuration'
GRUB_DEFAULT=0
GRUB_TIMEOUT_STYLE=hidden
GRUB_TIMEOUT=10
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash nouveau.modeset=0"
GRUB_CMDLINE_LINUX=""
# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"
# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console
# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true
# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_RECOVERY="true"
# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"更新grub
1
sudo update-grub
美化
设置 GRUB 主题
开机时有个漂亮的 GRUB 也是很舒服的。
在这里下载 Distro 的 GRUB 主题并解压。接下来 cd
进解压出来的文件夹,打开 konsole 输入
1 | sudo cp . /usr/share/grub/themes/Distro -rf |
以将主题放置在系统的 GRUB 默认文件夹内。
接着编辑 /etc/default/grub
文件,找到 #GRUB_THEME=
一行,将前面的注释去掉,并指向主题的 theme.txt
文件。即
1 | #GRUB_THEME= |
然后再在终端输入
1 | grub-mkconfig -o /boot/grub/grub.cfg |
更新 GRUB 即可。
方法2
How to install a grub theme:
- Extract the theme to
/boot/grub/themes/
- Edit
/etc/default/grub
file. Find the line starting with “#GRUB_THEME” and change it to “GRUB_THEME=/boot/grub/themes/[THEME_FOLDER]/[theme.txt]” (replace [THEME_FOLDER] ; [theme.txt] is probably OK ; remove “[]” brackets) - Run
sudo update-grub
Plymouth Themes安装
Plymouth
Plymouth is a bootsplash for Linux supporting animations using Direct Rendering Manager and KMS driver. It gets packed into the initrd. Besides eye-candy, Plymouth also handles user interaction during boot. Wikipedia
Installation instructions:
copy YOURTHEME folder to usr/share/plymouth/themes/YOURTHEME
run in terminal:
1
sudo plymouth-set-default-theme *YOURTHEME* -R