* [PATCH 0/2] serviceability: add event log when missing device is created @ 2015-04-27 4:46 Anand Jain 2015-04-27 4:46 ` [PATCH 1/2] Btrfs: " Anand Jain 2015-04-27 4:46 ` [PATCH 2/2] Btrfs: check error before reporting missing device and add uuid Anand Jain 0 siblings, 2 replies; 6+ messages in thread From: Anand Jain @ 2015-04-27 4:46 UTC (permalink / raw) To: linux-btrfs; +Cc: Wolfgang_Mader, dsterba Wolfgang was in a situation that he wanted to know the device-id of a missing device as indicated by 'btrfs fi show' sysfs patches sent before would help. And irrespective of that, these are system events must be logged for better pathological analysis of the btrfs issues. Anand Jain (2): Btrfs: log when missing device is created Btrfs: check error before reporting missing device and add uuid fs/btrfs/volumes.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) -- 2.0.0.153.g79dcccc ^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 1/2] Btrfs: log when missing device is created 2015-04-27 4:46 [PATCH 0/2] serviceability: add event log when missing device is created Anand Jain @ 2015-04-27 4:46 ` Anand Jain 2015-05-05 15:52 ` David Sterba 2015-04-27 4:46 ` [PATCH 2/2] Btrfs: check error before reporting missing device and add uuid Anand Jain 1 sibling, 1 reply; 6+ messages in thread From: Anand Jain @ 2015-04-27 4:46 UTC (permalink / raw) To: linux-btrfs; +Cc: Wolfgang_Mader, dsterba Signed-off-by: Anand Jain <anand.jain@oracle.com> --- fs/btrfs/volumes.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c index f2b5cc9..693745e 100644 --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c @@ -6109,6 +6109,8 @@ static int read_one_chunk(struct btrfs_root *root, struct btrfs_key *key, free_extent_map(em); return -EIO; } + btrfs_warn(root->fs_info, "devid %llu uuid %pU is missing", + devid, uuid); } map->stripes[i].dev->in_fs_metadata = 1; } -- 2.0.0.153.g79dcccc ^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 1/2] Btrfs: log when missing device is created 2015-04-27 4:46 ` [PATCH 1/2] Btrfs: " Anand Jain @ 2015-05-05 15:52 ` David Sterba 0 siblings, 0 replies; 6+ messages in thread From: David Sterba @ 2015-05-05 15:52 UTC (permalink / raw) To: Anand Jain; +Cc: linux-btrfs, Wolfgang_Mader, dsterba On Mon, Apr 27, 2015 at 12:46:18PM +0800, Anand Jain wrote: > Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.cz> ^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 2/2] Btrfs: check error before reporting missing device and add uuid 2015-04-27 4:46 [PATCH 0/2] serviceability: add event log when missing device is created Anand Jain 2015-04-27 4:46 ` [PATCH 1/2] Btrfs: " Anand Jain @ 2015-04-27 4:46 ` Anand Jain 2015-05-05 15:43 ` David Sterba 2015-05-07 20:34 ` Anand Jain 1 sibling, 2 replies; 6+ messages in thread From: Anand Jain @ 2015-04-27 4:46 UTC (permalink / raw) To: linux-btrfs; +Cc: Wolfgang_Mader, dsterba Report missing device when add is successful, otherwise it would exit as ENOMEM. And add uuid to the report. Signed-off-by: Anand Jain <anand.jain@oracle.com> --- fs/btrfs/volumes.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c index 693745e..d722ee5 100644 --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c @@ -6255,10 +6255,11 @@ static int read_one_dev(struct btrfs_root *root, if (!btrfs_test_opt(root, DEGRADED)) return -EIO; - btrfs_warn(root->fs_info, "devid %llu missing", devid); device = add_missing_dev(root, fs_devices, devid, dev_uuid); if (!device) return -ENOMEM; + btrfs_warn(root->fs_info, "devid %llu uuid %pU missing", + devid, uuid); } else { if (!device->bdev && !btrfs_test_opt(root, DEGRADED)) return -EIO; -- 2.0.0.153.g79dcccc ^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 2/2] Btrfs: check error before reporting missing device and add uuid 2015-04-27 4:46 ` [PATCH 2/2] Btrfs: check error before reporting missing device and add uuid Anand Jain @ 2015-05-05 15:43 ` David Sterba 2015-05-07 20:34 ` Anand Jain 1 sibling, 0 replies; 6+ messages in thread From: David Sterba @ 2015-05-05 15:43 UTC (permalink / raw) To: Anand Jain; +Cc: linux-btrfs, Wolfgang_Mader, dsterba On Mon, Apr 27, 2015 at 12:46:19PM +0800, Anand Jain wrote: > Report missing device when add is successful, > otherwise it would exit as ENOMEM. And add uuid > to the report. > > Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.cz> ^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 2/2] Btrfs: check error before reporting missing device and add uuid 2015-04-27 4:46 ` [PATCH 2/2] Btrfs: check error before reporting missing device and add uuid Anand Jain 2015-05-05 15:43 ` David Sterba @ 2015-05-07 20:34 ` Anand Jain 1 sibling, 0 replies; 6+ messages in thread From: Anand Jain @ 2015-05-07 20:34 UTC (permalink / raw) To: linux-btrfs; +Cc: Wolfgang_Mader, dsterba Report missing device when add is successful, otherwise it would exit as ENOMEM. And add uuid to the report. Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.cz> --- v1->v2: rebase to 4.1, fix compile error, still wonder why it wasn't in 3.19x. fs/btrfs/volumes.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c index ef1124f..228f26b 100644 --- a/fs/btrfs/volumes.c +++ b/fs/btrfs/volumes.c @@ -6299,10 +6299,11 @@ static int read_one_dev(struct btrfs_root *root, if (!btrfs_test_opt(root, DEGRADED)) return -EIO; - btrfs_warn(root->fs_info, "devid %llu missing", devid); device = add_missing_dev(root, fs_devices, devid, dev_uuid); if (!device) return -ENOMEM; + btrfs_warn(root->fs_info, "devid %llu uuid %pU missing", + devid, dev_uuid); } else { if (!device->bdev && !btrfs_test_opt(root, DEGRADED)) return -EIO; -- 2.0.0.153.g79dcccc ^ permalink raw reply related [flat|nested] 6+ messages in thread
end of thread, other threads:[~2015-05-08 4:37 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2015-04-27 4:46 [PATCH 0/2] serviceability: add event log when missing device is created Anand Jain 2015-04-27 4:46 ` [PATCH 1/2] Btrfs: " Anand Jain 2015-05-05 15:52 ` David Sterba 2015-04-27 4:46 ` [PATCH 2/2] Btrfs: check error before reporting missing device and add uuid Anand Jain 2015-05-05 15:43 ` David Sterba 2015-05-07 20:34 ` Anand Jain
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).