Re: fsck needs /dev in path to check an ext4 partition

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello Jonny!

On 1/15/21 9:06 PM, Jonny Grant wrote:
> Apologies I am not using 2.36.1 yet. I'm on latest Ubuntu LTS, but it's using 2.34
> 
> I noticed fsck only works if I write as "/dev/sdb1" not just "sdb1" I was in /dev/ as
> root, so it shouldn't need long path?
> 
> These work as expected when called from /dev/ as user root
> 
> # fsck.ext4 sdb1  
> # fsck.ext4 /dev/sdb1  
> 
> This does not work:
> # fsck sdb1

That's because it must be:

# fsck.ext4 ./sdb1

Filenames are expanded by your shell in this case, not by the fsck utilities.

Adrian

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaubitz@xxxxxxxxxx
`. `'   Freie Universitaet Berlin - glaubitz@xxxxxxxxxxxxxxxxxxx
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913




[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux