Ubuntu 不再挂载整个驱动器

Ubuntu 不再挂载整个驱动器

我无法再更新我的 ubuntu-server。 df/仍然只有4.7M,但lsblk74GB...另外对我来说,似乎 74GB 根本/dev/sda3没有安装。到目前为止,这些设置都是默认的,`/etc/fstab' 中没有更改。在我重新启动之前,它已安装。我现在必须手动安装它吗?我应该把它挂载到哪里?

谢谢你,

nessie@media:~$ sudo apt-get update
Hit:1 http://ch.archive.ubuntu.com/ubuntu focal InRelease
Get:2 http://ch.archive.ubuntu.com/ubuntu focal-updates InRelease [111 kB]
Err:2 http://ch.archive.ubuntu.com/ubuntu focal-updates InRelease
  Error writing to output file - write (28: No space left on device) [IP: 2001:1620::1620 80]
Get:3 http://ch.archive.ubuntu.com/ubuntu focal-backports InRelease [98.3 kB]
Err:3 http://ch.archive.ubuntu.com/ubuntu focal-backports InRelease
  Error writing to output file - write (28: No space left on device) [IP: 2001:1620::1620 80]
Get:4 http://ch.archive.ubuntu.com/ubuntu focal-security InRelease [107 kB]
Err:4 http://ch.archive.ubuntu.com/ubuntu focal-security InRelease
  Error writing to output file - write (28: No space left on device) [IP: 2001:1620::1620 80]
Get:5 https://download.docker.com/linux/ubuntu focal InRelease [36.2 kB]
Err:5 https://download.docker.com/linux/ubuntu focal InRelease
  Error writing to output file - write (28: No space left on device) [IP: 2600:9000:2190:ee00:3:db06:4200:93a1 443]
Reading package lists... Done
W: Failed to fetch http://ch.archive.ubuntu.com/ubuntu/dists/focal-updates/InRelease  Error writing to output file - write (28: No space left on device) [IP: 2001:1620::1620 80]
W: Failed to fetch http://ch.archive.ubuntu.com/ubuntu/dists/focal-backports/InRelease  Error writing to output file - write (28: No space left on device) [IP: 2001:1620::1620 80]
W: Failed to fetch http://ch.archive.ubuntu.com/ubuntu/dists/focal-security/InRelease  Error writing to output file - write (28: No space left on device) [IP: 2001:1620::1620 80]
W: Failed to fetch https://download.docker.com/linux/ubuntu/dists/focal/InRelease  Error writing to output file - write (28: No space left on device) [IP: 2600:9000:2190:ee00:3:db06:4200:93a1 443]
W: Some index files failed to download. They have been ignored, or old ones used instead.
nessie@media:~$ df -ih
Filesystem                        Inodes IUsed IFree IUse% Mounted on
udev                                238K   601  237K    1% /dev
tmpfs                               249K   981  248K    1% /run
/dev/mapper/ubuntu--vg-ubuntu--lv   4.7M  300K  4.4M    7% /
tmpfs                               249K     4  249K    1% /dev/shm
tmpfs                               249K     3  249K    1% /run/lock
tmpfs                               249K    18  249K    1% /sys/fs/cgroup
/dev/sda2                            64K   312   64K    1% /boot
/dev/loop0                           13K   13K     0  100% /snap/core/9993
/dev/loop1                           13K   13K     0  100% /snap/core/10126
/dev/loop2                           11K   11K     0  100% /snap/core18/1885
/dev/loop3                          3.4K  3.4K     0  100% /snap/docker/471
/dev/loop4                           11K   11K     0  100% /snap/core18/1880
/dev/loop5                          1.5K  1.5K     0  100% /snap/lxd/16099
/dev/loop7                           472   472     0  100% /snap/snapd/9279
/dev/loop6                          1.5K  1.5K     0  100% /snap/lxd/16922
/dev/loop8                           472   472     0  100% /snap/snapd/9607
tmpfs                               249K    22  249K    1% /run/user/1000
tmpfs                               249K     1  249K    1% /tmp
nessie@media:~$ sudo lsblk -o NAME,FSTYPE,SIZE,MOUNTPOINT,LABEL
NAME                      FSTYPE        SIZE MOUNTPOINT        LABEL
fd0                                       4K
loop0                     squashfs     97.1M /snap/core/9993
loop1                     squashfs     97.7M /snap/core/10126
loop2                     squashfs     55.3M /snap/core18/1885
loop3                     squashfs    125.9M /snap/docker/471
loop4                     squashfs       55M /snap/core18/1880
loop5                     squashfs     71.3M /snap/lxd/16099
loop6                     squashfs     70.6M /snap/lxd/16922
loop7                     squashfs     30.3M /snap/snapd/9279
loop8                     squashfs       31M /snap/snapd/9607
sda                                   149.1G
├─sda1                                    1M
├─sda2                    ext4            1G /boot
└─sda3                    LVM2_member   148G
  └─ubuntu--vg-ubuntu--lv ext4           74G /
nessie@media:~$ sudo fdisk -l
Disk /dev/sda: 149.5 GiB, 160041885696 bytes, 312581808 sectors
Disk model: SAMSUNG SP1654N
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: gpt
Disk identifier: 8DDAC3C1-57E4-48A1-A034-8A905F32B3ED

Device       Start       End   Sectors  Size Type
/dev/sda1     2048      4095      2048    1M BIOS boot
/dev/sda2     4096   2101247   2097152    1G Linux filesystem
/dev/sda3  2101248 312578047 310476800  148G Linux filesystem
nessie@media:~$ 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/ubuntu-vg/ubuntu-lv during curtin installation
/dev/disk/by-id/dm-uuid-LVM-y3gRYv9ja3ZkF0FDdztxzsx3gEldTa9qd9BJmfvrTVf5tkOfaTFTu60KPYX6oueM / ext4 defaults 0 0
# /boot was on /dev/sda2 during curtin installation
/dev/disk/by-uuid/b1593203-e59b-4cd0-af2b-4bf7b273e1d3 /boot ext4 defaults 0 0
/swap.img   none    swap    sw  0   0
nessie@media:~$ blkid
/dev/sda2: UUID="b1593203-e59b-4cd0-af2b-4bf7b273e1d3" TYPE="ext4" PARTUUID="36cb0c83-ec38-4971-bc17-2f3554b41d47"
/dev/sda3: UUID="aO2T4S-ZxEU-RyLI-U7nG-gPYY-dGiL-AnyB1t" TYPE="LVM2_member" PARTUUID="09fba423-bee5-4104-b9e3-015d3528b8f9"
/dev/mapper/ubuntu--vg-ubuntu--lv: UUID="e3de6996-c10d-473c-9882-12ba559b7d6b" TYPE="ext4"

答案1

谢谢 :) 阅读上面评论中的完整答案

df -ih
/dev/mapper/ubuntu--vg-ubuntu--lv   73G   70G     0 100% /

If you're asking why the LVM2_member size shows 148G but / shows only 74G, that's presumably because you only created a 74G filesystem on the LV

相关内容