util-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
To: Jonny Grant <jg@jguk.org>
Cc: util-linux@vger.kernel.org
Subject: Re: fsck needs /dev in path to check an ext4 partition
Date: Fri, 15 Jan 2021 21:15:02 +0100	[thread overview]
Message-ID: <4930f03e-dbd0-7a2f-4b56-9f7cef88d9d2@physik.fu-berlin.de> (raw)
In-Reply-To: <5483a74b-106e-1c6c-0265-55ed960826d8@jguk.org>

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@debian.org
`. `'   Freie Universitaet Berlin - glaubitz@physik.fu-berlin.de
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913


  reply	other threads:[~2021-01-15 20:15 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-15 20:06 fsck needs /dev in path to check an ext4 partition Jonny Grant
2021-01-15 20:15 ` John Paul Adrian Glaubitz [this message]
2021-01-15 21:35   ` Jonny Grant
2021-01-15 21:59   ` Theodore Ts'o
2021-01-15 22:10     ` John Paul Adrian Glaubitz
2021-01-15 22:56     ` Jonny Grant

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4930f03e-dbd0-7a2f-4b56-9f7cef88d9d2@physik.fu-berlin.de \
    --to=glaubitz@physik.fu-berlin.de \
    --cc=jg@jguk.org \
    --cc=util-linux@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).