Re: Recover from "journal entries X-Y missing! (replaying X-Z)", "IO error on writing btree."

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

 



On Freitag, 22. März 2019 09:41:15 CET Dennis Schridde wrote:
> On Freitag, 22. März 2019 09:23:29 CET Coly Li wrote:
> > On 2019/3/22 4:18 下午, Dennis Schridde wrote:
> > > On Freitag, 22. März 2019 08:04:20 CET Coly Li wrote:
> > >> On 2019/3/22 2:14 下午, Coly Li wrote:
> > >>> On 2019/3/21 10:16 下午, Coly Li wrote:
> > >>>> Now I am able to understand your patch. Yes this patch may
> > >>>> fix one of the condition that jset get lost.
> > >>>> 
> > >>>> We should have this fix in v5.1, I will handle the format
> > >>>> issue. And if you don't mind I may re-compose a commit log to
> > >>>> explain what exactly is fixed.
> > >>> 
> > >>> When I review the patch, I feel there is one point I still do
> > >>> not understand, could you please give me more hint ?
> > >>> 
> > >>> From your commit log, "so when we doing replay, journals from
> > >>> last_seq_wrote to last_seq_now are missing.", can you show me
> > >>> the code to explain how such condition happens ?
> > >> 
> > >> Aha, I realize this is for discard enabled condition. Hmm, but
> > >> discard is disabled by default.
> > >> 
> > >> Hi Dennis,
> > >> 
> > >> Is discard enabled in your environment ? Or it is just disabled
> > >> by default.
> > > 
> > > How do I figure that out?  (I currently only have access to /etc,
> > > my previous 4.18 or 4.19 kernel build config and whatever metadata
> > > bcache tools can provide me with.)
> > 
> > Hi Dennis,
> > 
> > The sysfs interface is /sys/fs/bcache/<cacheset UUID>/cache0/discard
> > 
> > By default it should be 0 (disabled).
> 
> I used a Fedora 29 live system with Linux 4.18.16-300.fc29.  /sys/fs/bcache
> is empty except for "regiter" and "register_quiet".  Probably because the
> bcache kernel module unregisters the cache set after encountering the I/O
> errors?

bcache-super-show was helpful:

$ sudo bcache-super-show /dev/nvme0n1 
sb.magic                ok
sb.first_sector         8 [match]
sb.csum                 HEX1 [match]
sb.version              3 [cache device]

dev.label               (empty)
dev.uuid                UUID1
dev.sectors_per_block   8
dev.sectors_per_bucket  4096
dev.cache.first_sector  4096
dev.cache.cache_sectors 488390656
dev.cache.total_sectors 488394752
dev.cache.ordered       yes
dev.cache.discard       yes
dev.cache.pos           0
dev.cache.replacement   0 [lru]

cset.uuid               UUID0
$ sudo bcache-super-show /dev/sda3 
sb.magic                ok
sb.first_sector         8 [match]
sb.csum                 HEX2 [match]
sb.version              1 [backing device]

dev.label               (empty)
dev.uuid                UUID2
dev.sectors_per_block   8
dev.sectors_per_bucket  4096
dev.data.first_sector   16
dev.data.cache_mode     1 [writeback]
dev.data.cache_state    2 [dirty]

cset.uuid               UUID0

Attachment: signature.asc
Description: This is a digitally signed message part.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux ARM Kernel]     [Linux Filesystem Development]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux