Web lists-archives.com

Re: Partition information as text file?

On Fri 01 Feb 2019 at 16:23:04 (+0100), tomas@xxxxxxxxxx wrote:

> Not yet what we wanted. But:
>   tomas@trotzki:~$ sudo file -s /dev/dm-4
>   /dev/dm-4: Linux rev 1.0 ext4 filesystem data, UUID=c5d1ae98-df63-4c04-913d-661b82d38075 (needs journal recovery) (extents) (64bit) (large files) (huge files)
> I guess that's not all info you want, but hey. Sudo is needed, because mere
> mortals have no business in reading raw disks, usually; The "needs journal
> recovery" sounds alarming, but remember that the thing is mounted, i.e.
> active, so that's OK too.

I hadn't bothered to say this already, but not replaying the journal
could be one reason that wrong information is returned from unmounted
filesystems, as Pascal mentioned earlier.

That could be another reason to mount them (readonly) and let df
complete the dirty work of finding the information you want (as
I outlined much earlier in this thread).