在尝试了一些 Linux 虚拟机一段时间后,我想了解有关使用 Linux 系统的更多信息,并将我的笔记本电脑设置为双启动 Xubuntu。
我以为 Xubuntu 的运行速度会比 Windows 快得多,但目前看来并非如此。我在两个方面都遇到了速度问题。
澄清:
-启动时间很慢。以下是 systemd-analyze blame 的结果。
6.849s dev-sdb9.device
6.319s NetworkManager-wait-online.service
4.423s NetworkManager.service
4.044s ModemManager.service
3.943s accounts-daemon.service
3.777s networking.service
3.583s preload.service
3.396s lm-sensors.service
3.333s grub-common.service
3.044s apparmor.service
2.988s gpu-manager.service
2.926s plymouth-read-write.service
2.799s polkit.service
2.141s [email protected]
2.138s snapd.service
1.895s systemd-fsck@dev-disk-by\x2duuid-4208\x2d230E.service
1.820s keyboard-setup.service
1.528s avahi-daemon.service
1.515s systemd-modules-load.service
1.514s systemd-tmpfiles-setup-dev.service
1.476s systemd-fsck@dev-disk-by\x2duuid-d325b9ad\x2d72b1\x2d4ad3\x2da9
1.319s thermald.service
1.237s resolvconf.service
1.087s [email protected]
888ms systemd-rfkill.service
864ms systemd-udevd.service
860ms vpnagentd.service
778ms dev-hugepages.mount
731ms dev-mqueue.mount
731ms sys-kernel-debug.mount
669ms upower.service
627ms rsyslog.service
504ms systemd-sysctl.service
464ms systemd-resolved.service
449ms systemd-journald.service
435ms setvtrgb.service
406ms ufw.service
399ms bluetooth.service
371ms home.mount
333ms lightdm.service
331ms plymouth-quit-wait.service
320ms boot-efi.mount
301ms kmod-static-nodes.service
293ms systemd-backlight@backlight:intel_backlight.service
276ms irqbalance.service
250ms systemd-update-utmp.service
- 第一次打开时,所有东西都很慢,即使笔记本电脑已经运行了一段时间。这在 RStudio 中的 R markdown 文件上尤其明显。当我第一次打开一个文件时,需要很长时间才能加载。即使我关闭了 RStudio 及其中已打开的任何文件,后续文件也会加载得相当快。Firefox、终端和启动菜单在我第一次打开时也明显很慢,但之后通常打开得很快。偶尔它们仍会出现故障并缓慢打开,但第一次总是很慢。
有什么想法吗?我的安装是否出了问题?
编辑:
sudo fdisk -l 的输出:
Disk /dev/sda: 22.4 GiB, 24015495168 bytes, 46905264 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x74f02dea
Device Boot Start End Sectors Size Id Type
/dev/sda1 2048 46903295 46901248 22.4G 73 unknown
Disk /dev/sdb: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: A60B118A-A9C4-4349-A026-5216417DB9A9
Device Start End Sectors Size Type
/dev/sdb1 2048 2050047 2048000 1000M Windows recovery environment
/dev/sdb2 2050048 2582527 532480 260M EFI System
/dev/sdb3 2582528 4630527 2048000 1000M Lenovo boot partition
/dev/sdb4 4630528 4892671 262144 128M Microsoft reserved
/dev/sdb5 4892672 1237063679 1232171008 587.6G Microsoft basic data
/dev/sdb6 1874814976 1927243775 52428800 25G Microsoft basic data
/dev/sdb7 1927243776 1953523711 26279936 12.5G Windows recovery environment
/dev/sdb8 1237063680 1268314111 31250432 14.9G Linux swap
/dev/sdb9 1268314112 1317142527 48828416 23.3G Linux filesystem
/dev/sdb10 1317142528 1874814975 557672448 265.9G Linux filesystem
Partition table entries are not in disk order.
Disk /dev/mapper/cryptswap1: 14.9 GiB, 15999696896 bytes, 31249408 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
free -h 的输出:
total used free shared buff/cache available
Mem: 7.7G 898M 5.8G 100M 1.0G 6.5G
Swap: 14G 0B 14G
swapon -s 的输出:
Filename Type Size Used Priority
/dev/dm-0 partition 15624700 0 -1
sudo blkid 的输出:
/dev/sda1: PARTUUID="74f02dea-01"
/dev/sdb1: LABEL="WINRE_DRV" UUID="647805AC78057E54" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="958cee58-c55f-42c3-874c-e7f0e0546cd0"
/dev/sdb2: LABEL="SYSTEM_DRV" UUID="4208-230E" TYPE="vfat" PARTLABEL="EFI system partition" PARTUUID="4c6a560c-5a4a-45c5-84f1-246b0ec72768"
/dev/sdb3: LABEL="LRS_ESP" UUID="520B-D1D6" TYPE="vfat" PARTLABEL="Basic data partition" PARTUUID="ee90f060-1cd1-4baa-b835-e5abe0a5dec3"
/dev/sdb4: PARTLABEL="Microsoft reserved partition" PARTUUID="f8733595-73d8-4577-96b6-10802f98d03a"
/dev/sdb5: LABEL="Windows8_OS" UUID="16520F24520F0867" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="b6f4a650-125f-4572-9d5d-a5f516dcc58f"
/dev/sdb6: LABEL="LENOVO" UUID="762EC6FC2EC6B481" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="4784a048-5e2b-4af6-a579-65e7453a8717"
/dev/sdb7: LABEL="PBR_DRV" UUID="848E12EB8E12D590" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="c67b416c-36e4-4f3d-af35-b1ee9f971db5"
/dev/sdb8: UUID="420659b5-1054-4c55-b182-1e72fc913781" TYPE="swap" PARTUUID="8c8be854-6d0b-43c1-a161-dcdf14e952e9"
/dev/sdb9: UUID="714498ed-b999-46c1-a2f6-95d010bfeb28" TYPE="ext4" PARTUUID="f04127f4-a9dc-4cf3-87d6-66e317b28683"
/dev/sdb10: UUID="d325b9ad-72b1-4ad3-a954-081f05b66d1f" TYPE="ext4" PARTUUID="d170b378-bcf8-4ec9-b639-2b1e4661df1f"
/dev/mapper/cryptswap1: UUID="1438bafc-ee9d-44b5-bca8-801225646e14" TYPE="swap"
cat /etc/fstab 的输出:
# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
# / was on /dev/sdb9 during installation
UUID=714498ed-b999-46c1-a2f6-95d010bfeb28 / ext4 errors=remount-ro 0 1
# /boot/efi was on /dev/sdb2 during installation
UUID=4208-230E /boot/efi vfat umask=0077 0 1
# /home was on /dev/sdb10 during installation
UUID=d325b9ad-72b1-4ad3-a954-081f05b66d1f /home ext4 defaults 0 2
# swap was on /dev/sdb8 during installation
#UUID=420659b5-1054-4c55-b182-1e72fc913781 none swap sw 0 0
/dev/mapper/cryptswap1 none swap sw 0 0
sudo hdparm -t /dev/sdb 的输出:
/dev/sdb:
Timing buffered disk reads: 326 MB in 3.01 seconds = 108.41 MB/sec
sudo parted 的输出:
GNU Parted 3.2
Using /dev/sdb
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) print
Model: ATA ST1000LM024 HN-M (scsi)
Disk /dev/sdb: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags:
Number Start End Size File system Name Flags
1 1049kB 1050MB 1049MB ntfs Basic data partition hidden, diag
2 1050MB 1322MB 273MB fat32 EFI system partition boot, hidden, esp
3 1322MB 2371MB 1049MB fat32 Basic data partition hidden
4 2371MB 2505MB 134MB Microsoft reserved partition msftres
5 2505MB 633GB 631GB ntfs Basic data partition msftdata
8 633GB 649GB 16.0GB linux-swap(v1)
9 649GB 674GB 25.0GB ext4
10 674GB 960GB 286GB ext4
6 960GB 987GB 26.8GB ntfs Basic data partition msftdata
7 987GB 1000GB 13.5GB ntfs Basic data partition hidden, diag
所有这些都对齐
磁盘输出: 磁盘结果