[Cluster-devel] [PATCHv2 dlm/next] fs: dlm: log plock operation time

2023-01-30 Thread Alexander Aring
This patch adds more debug logging regarding to plock operation time. Currently plocks are handled by user space and we are waiting for a reply of the user space. To measure this upcall and downcall again we introduce logging information of how much time the response took and additional posix lock

[Cluster-devel] [PATCH dlm/next] fs: dlm: log plock operation time

2023-01-30 Thread Alexander Aring
This patch adds more debug logging regarding to plock operation time. Currently plocks are handled by user space and we are waiting for a reply of the user space. To measure this upcall and downcall again we introduce logging information of how much time the response took and additional posix lock

Re: [Cluster-devel] [PATCH dlm-tool 6/8] dlm_controld: log lock/pending/waiter state changes

2023-01-30 Thread Alexander Aring
Hi, On Mon, Jan 30, 2023 at 2:24 PM Alexander Aring wrote: > > This patch will trace lock state changes of the used dlm posix locks. In > combination with the plock logfile we can see state changes over time > and follow posix locks and their state. > --- > dlm_controld/dlm_daemon.h | 2 +- >

Re: [Cluster-devel] [PATCH dlm-tool 8/8] dlm_controld: add time diff for state time intervals

2023-01-30 Thread Alexander Aring
Hi, On Mon, Jan 30, 2023 at 2:24 PM Alexander Aring wrote: > > This patch adds functionality to see how long a posix lock is alive or > is in waiting or pending state. It can be used to filter out interesting > locks which are stuck in e.g. waiting state to know that a user space > process probab

[Cluster-devel] [PATCH dlm-tool 8/8] dlm_controld: add time diff for state time intervals

2023-01-30 Thread Alexander Aring
This patch adds functionality to see how long a posix lock is alive or is in waiting or pending state. It can be used to filter out interesting locks which are stuck in e.g. waiting state to know that a user space process probably has contention on it. The logging information will printout addition

[Cluster-devel] [PATCH dlm-tool 3/8] dlm_controld: add plock logfile

2023-01-30 Thread Alexander Aring
The current plock logging is limited due a in-memory log buffer which can be dumped via dlm_contol log_plock functionality. To trace plock performance issues it's necessary to log plock activity in a bigger log buffer such as a file. This patch will add functionality that plock logging information

[Cluster-devel] [PATCH dlm-tool 1/8] dlm_tool: add fail functionality if dump failed

2023-01-30 Thread Alexander Aring
Currently dlm_controld sets a embedded data int value of dlm_controld dump functionality failed for e.g. if lockspace cannot be found. The dlm_tool does not parse this possible error functionality and will exit successfully. This patch will add dlm_tool fail functionality if dlm_controld sets an em

[Cluster-devel] [PATCH dlm-tool 7/8] dlm_controld: constify timeval of dt_usec()

2023-01-30 Thread Alexander Aring
Those parameters are only used read only. We don't change any data where those pointers point to. --- dlm_controld/plock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlm_controld/plock.c b/dlm_controld/plock.c index 77c043fd..d83a79d2 100644 --- a/dlm_controld/plock.c +++

[Cluster-devel] [PATCH dlm-tool 6/8] dlm_controld: log lock/pending/waiter state changes

2023-01-30 Thread Alexander Aring
This patch will trace lock state changes of the used dlm posix locks. In combination with the plock logfile we can see state changes over time and follow posix locks and their state. --- dlm_controld/dlm_daemon.h | 2 +- dlm_controld/logging.c| 2 +- dlm_controld/plock.c | 124 +++

[Cluster-devel] [PATCH dlm-tool 5/8] dlm_controld: remove ls parameter

2023-01-30 Thread Alexander Aring
The ls parameter in write_result() is not used, so we can remove it. --- dlm_controld/plock.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/dlm_controld/plock.c b/dlm_controld/plock.c index c2c80360..462c9212 100644 --- a/dlm_controld/plock.c +++ b/dlm_controld/

[Cluster-devel] [PATCH dlm-tool 2/8] dlm_controld: always create logdir

2023-01-30 Thread Alexander Aring
Currently the logdir will be created only if logfile does contain a string. To add another logfiles we simple create the logdir always on startup. --- dlm_controld/logging.c | 34 +- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/dlm_controld/loggin

[Cluster-devel] [PATCH dlm-tool 4/8] dlm_controld: move processing of saved messages to plock level

2023-01-30 Thread Alexander Aring
Ad the loglevel is for save plock messages during corosync resource membership upate. This patch will put the processing of saved messages on the same loglevel. --- dlm_controld/plock.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dlm_controld/plock.c b/dlm_controld/ploc

[Cluster-devel] [PATCH 0/6] gfs2-utils: Cleanups and fsck.gfs2 fixes

2023-01-30 Thread Andrew Price
This set is mainly cleanups but patches 5 and 6 are small fixes for fsck.gfs2 which I would like to draw attention to. PR is https://pagure.io/gfs2-utils/pull-request/14 awaiting CI testing should you prefer to comment there. Andy Andrew Price (6): libgfs2: Return the inode from lgfs2_lookupi(

[Cluster-devel] [PATCH 4/6] fsck.gfs2: Remove de variable from dirref_find()

2023-01-30 Thread Andrew Price
It always points to 'dentry' so it can be replaced in all uses. Signed-off-by: Andrew Price --- gfs2/fsck/pass2.c | 13 ++--- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/gfs2/fsck/pass2.c b/gfs2/fsck/pass2.c index 0c2e0146..002bf2cb 100644 --- a/gfs2/fsck/pass2.c +++ b/

[Cluster-devel] [PATCH 6/6] fsck.gfs2: fix_hashtable: Decrement i_blocks when freeing leaf blocks

2023-01-30 Thread Andrew Price
fsck.gfs2 can leave i_blocks too large when it removes empty leaf blocks, so decrease the count when freeing them. Signed-off-by: Andrew Price --- gfs2/fsck/pass2.c | 1 + 1 file changed, 1 insertion(+) diff --git a/gfs2/fsck/pass2.c b/gfs2/fsck/pass2.c index 5327ee43..71459978 100644 --- a/gfs

[Cluster-devel] [PATCH 5/6] fsck.gfs2: Fix wrong entry used in dentry comparison

2023-01-30 Thread Andrew Price
'dent' points to the on-disk data that 'dentry' was converted from, so this comparison always evaluates to true. Compare to 'entry' instead. Signed-off-by: Andrew Price --- gfs2/fsck/pass2.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gfs2/fsck/pass2.c b/gfs2/fsck/pass2.c

[Cluster-devel] [PATCH 1/6] libgfs2: Return the inode from lgfs2_lookupi()

2023-01-30 Thread Andrew Price
Instead of returning a -errno with the inode set via a passed in pointer, return the inode and use errno. This is more consistent and simplifies some calling code. Signed-off-by: Andrew Price --- gfs2/convert/gfs2_convert.c | 7 +++ gfs2/edit/hexedit.c | 2 +- gfs2/fsck/fs_recovery

[Cluster-devel] [PATCH 3/6] libgfs2: Reorganise lgfs2_createi()

2023-01-30 Thread Andrew Price
Move the lookup for an existing inode to lgfs2_createi itself and then create the inode in __createi (renamed to do_createi) unconditionally. Signed-off-by: Andrew Price --- gfs2/libgfs2/fs_ops.c | 80 --- 1 file changed, 45 insertions(+), 35 deletions(-)

[Cluster-devel] [PATCH 2/6] libgfs2: Remove lgfs2_gfs_createi()

2023-01-30 Thread Andrew Price
The one caller sets sdp->gfs1 and modifies the mode itself so we can use sdp->gfs1 in __createi() and update the caller to use lgfs2_createi() instead. Signed-off-by: Andrew Price --- gfs2/fsck/lost_n_found.c | 6 +- gfs2/libgfs2/fs_ops.c| 19 ++- gfs2/libgfs2/libgfs2.h

Re: [Cluster-devel] [PATCH] gfs2: Fix uaf for qda in gfs2_quota_sync

2023-01-30 Thread Andreas Gruenbacher
Hello Edward, On Fri, Jan 27, 2023 at 6:12 AM wrote: > From: Edward Adam Davis > > [ 81.372851][ T5532] CPU: 1 PID: 5532 Comm: syz-executor.0 Not tainted > 6.2.0-rc1-syzkaller-dirty #0 > [ 81.382080][ T5532] Hardware name: Google Google Compute Engine/Google > Compute Engine, BIOS Google 0

[Cluster-devel] [PATCH] gfs2: Fix uaf for qda in gfs2_quota_sync

2023-01-30 Thread eadavis
From: Edward Adam Davis [ 81.372851][ T5532] CPU: 1 PID: 5532 Comm: syz-executor.0 Not tainted 6.2.0-rc1-syzkaller-dirty #0 [ 81.382080][ T5532] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/12/2023 [ 81.392343][ T5532] Call Trace: [ 81.395654][ T5532