gparted 自行挂载分区吗?

gparted 自行挂载分区吗?

我有一个用于备份的 USB 驱动器,并且我必须扩展一个在启动时使用 /etc/fstab 中的正确行安装的分区。

启动 gparted 时,我遇到的第一个问题是无法从 gparted 卸载分区:尝试执行此操作时,我立即发现它再次被安装,并且 gparted 不允许我对该分区执行任何操作。

在我看来,这种行为只发生在 USB 驱动器上,但我不明白 gparted 为什么会这样做!

无论如何,从终端卸载分区,我将其卸载,显然它保持卸载状态,我可以告诉 gparted 增大它,它开始增大它,但过了一会儿(20 秒?)它停止说:

/dev/sde 上的分区 5 已写入,但我们无法通知内核此更改,可能是因为该分区正在使用中。因此,旧分区将继续使用。您应该立即重新启动,然后再进行进一步的更改。

保存详细信息,如下所示:

GParted 0.25.0 --enable-libparted-dmraid --enable-online-resize
Libparted 3.2
Move /dev/sde5 to the left and grow it from 682.17 GiB to 931.51 GiB  00:01:57    ( ERROR ) 
    
calibrate /dev/sde5  00:00:00    ( SUCCESS ) 
    
path: /dev/sde5 (partition)
start: 522913792
end: 1953523711
size: 1430609920 (682.17 GiB) 


check file system on /dev/sde5 for errors and (if possible) fix them  00:00:10    ( SUCCESS ) 
    
e2fsck -f -y -v -C 0 /dev/sde5  00:00:10    ( SUCCESS ) 
    
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure 
Pass 3: Checking directory connectivity 
Pass 4: Checking reference counts
Pass 5: Checking group summary information 

77300 inodes used (0.17%, out of 44711936)
1078 non-contiguous files (1.4%)
2 non-contiguous directories (0.0%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 77291/1
105061981 blocks used (58.75%, out of 178826240)
0 bad blocks
1 large file

77256 regular files
35 directories
0 character device files
0 block device files
0 fifos
105 links
0 symbolic links (0 fast symbolic links)
0 sockets
------------
77396 files
e2fsck 1.42.13 (17-May-2015)




grow partition from 682.17 GiB to 931.51 GiB  00:00:00    ( SUCCESS ) 
    
old start: 522913792
old end: 1953523711
old size: 1430609920 (682.17 GiB) 
new start: 4096
new end: 1953523711
new size: 1953519616 (931.51 GiB) 


move file system to the left  00:00:00    ( ERROR ) 
    
e2image -ra -p -o 267729764352 /dev/sde5  00:00:00    ( ERROR ) 
    

e2image 1.42.13 (17-May-2015)

Running e2image on a R/W mounted filesystem can result in an
inconsistent image which will not be useful for debugging purposes.
Use -f option if you really want to do that.




rollback last change to the partition table  00:01:47    ( SUCCESS ) 
    
shrink partition from 931.51 GiB to 682.17 GiB  00:01:47    ( SUCCESS ) 
    
old start: 4096
old end: 1953523711
old size: 1953519616 (931.51 GiB) 
new start: 522913792
new end: 1953523711
new size: 1430609920 (682.17 GiB) 




check file system on /dev/sde5 for errors and (if possible) fix them  00:00:00    ( ERROR ) 
    
e2fsck -f -y -v -C 0 /dev/sde5  00:00:00    ( ERROR ) 
    
/dev/sde5 is mounted.
e2fsck 1.42.13 (17-May-2015)
e2fsck: Cannot continue, aborting.





libparted messages    ( INFO ) 
    
Partition(s) 5 on /dev/sde have been written, but we have been unable to inform the kernel of the change, probably because it/they are in use. As a result, the old partition(s) will remain in use. You should reboot now before making further changes. 




========================================

您可以看到,当运行 e2image 时,它​​会停止并抱怨它在 ar/w 挂载的文件系统上运行。但是 - 再次 - 我没有做任何事情来挂载它。

让 gparted 增大我的分区的唯一方法是使用命令不断卸载分区

sudo watch -n 0.1 umount /dev/sde5

这样 gparted 就可以调整分区大小。

我的问题是:

  • 实际上是 gparted 挂载了分区吗???
  • 有没有其他方法可以让 gparted 调整分区大小,而无需使用 watch/umount 命令?

相关内容