ocfs2/cluster: Make o2net connect messages KERN_NOTICE
PATCH 1/1 ocfs2/cluster: Make o2net connect messages KERN_NOTICE
Connect and disconnect messages are more than informational as they are required during root cause analysis for failures. This patch changes them from KERN_INFO to KERN_NOTICE.
--- fs/ocfs2/cluster/tcp.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-)
fs/ocfs2/cluster/tcp.c +3 -3
@@ -486,7 +486,7 @@ static void o2net_set_nn_state(struct o2net_node *nn, }if (was_valid && !valid) { -printk (KERN_INFO "o2net: no longer connected to " +printk (KERN_NOTICE "o2net: no longer connected to " SC_NODEF_FMT "\n" ,SC_NODEF_ARGS (old_sc));o2net_complete_nodes_nsw (nn); }
@@ -494,7 +494,7 @@ static void o2net_set_nn_state(struct o2net_node *nn,if (!was_valid && valid) {o2quo_conn_up (o2net_num_from_nn (nn));cancel_delayed_work (&nn->nn_connect_expired); -printk (KERN_INFO "o2net: %s " SC_NODEF_FMT "\n" , +printk (KERN_NOTICE "o2net: %s " SC_NODEF_FMT "\n" ,o2nm_this_node () > sc->sc_node->nd_num ?"connected to" :"accepted connection from" ,SC_NODEF_ARGS (sc));
@@ -1477,7 +1477,7 @@ static void o2net_idle_timer(unsigned long data)do_gettimeofday (&now); -printk (KERN_INFO "o2net: connection to " SC_NODEF_FMT " has been idle for %u.%u " +printk (KERN_NOTICE "o2net: connection to " SC_NODEF_FMT " has been idle for %u.%u " "seconds, shutting it down.\n" ,SC_NODEF_ARGS (sc),o2net_idle_timeout () /1000 ,o2net_idle_timeout () %1000 );
Signature · 1 line
1.6.3.3
PATCH 1/1 ocfs2/dlm: Fix printing of lockname
The debug call printing the name of the lock resource was chopping off the last character. This patch fixes the problem.
--- fs/ocfs2/dlm/dlmdebug.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)
fs/ocfs2/dlm/dlmdebug.c +2 -2
@@ -97,12 +97,12 @@ void __dlm_print_one_lock_resource(struct dlm_lock_resource *res) {struct list_head *iter2;struct dlm_lock *lock; -char buf[DLM_LOCKID_NAME_MAX ]; +char buf[DLM_LOCKID_NAME_MAX +1 ];assert_spin_locked (&res->spinlock);stringify_lockname (res->lockname.name, res->lockname.len, - buf,sizeof (buf) -1 ); + buf,sizeof (buf));printk ("lockres: %s, owner=%u, state=%u\n" , buf, res->owner, res->state); printk(" last used: %lu, refcnt: %u, on purge list: %s\n",
Signature · 1 line
1.6.3.3
PATCH 1/1 ocfs2/dlm: Fix printing of lockname
Quoted 14 lines · Sunil Mushran
The debug call printing the name of the lock resource was chopping off the last character. This patch fixes the problem.
Signed-off-by Sunil Mushran <[email protected]>--- fs/ocfs2/dlm/dlmdebug.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)fs/ocfs2/dlm/dlmdebug.c +0
-0@@ -97,12 +97,12 @@ void __dlm_print_one_lock_resource(struct dlm_lock_resource *res) {
fs/ocfs2/dlm/dlmdebug.c void __dlm_print_one_lock_resource(struct dlm_lock_resource *res) · line 105
Quoted 10 lines
fs/ocfs2/dlm/dlmdebug.c +2
-2struct list_head *iter2;struct dlm_lock *lock; -char buf[DLM_LOCKID_NAME_MAX ]; +char buf[DLM_LOCKID_NAME_MAX +1 ];assert_spin_locked (&res->spinlock);stringify_lockname (res->lockname.name, res->lockname.len, - buf,sizeof (buf) -1 ); + buf,sizeof (buf));
I'm confused - isn't this part then increasing the value of the parameter by 2?
--Mark
Quoted 11 lines
fs/ocfs2/dlm/dlmdebug.c +0
-0printk ("lockres: %s, owner=%u, state=%u\n" , buf, res->owner, res->state); printk(" last used: %lu, refcnt: %u, on purge list: %s\n",Signature · 7 lines
1.6.3.3 _______________________________________________ Ocfs2-devel mailing list Ocfs2-devel at oss.oracle.com http://oss.oracle.com/mailman/listinfo/ocfs2-devel
--
Mark Fasheh
PATCH 1/1 ocfs2/dlm: Fix printing of lockname
Quoted 23 lines · Mark Fasheh
Quoted 21 lines · Sunil Mushran
The debug call printing the name of the lock resource was chopping off the last character. This patch fixes the problem.
Signed-off-by Sunil Mushran <[email protected]>--- fs/ocfs2/dlm/dlmdebug.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-)fs/ocfs2/dlm/dlmdebug.c +1
-1@@ -97,12 +97,12 @@ void __dlm_print_one_lock_resource(struct dlm_lock_resource *res) {struct list_head *iter2;struct dlm_lock *lock; -char buf[DLM_LOCKID_NAME_MAX ]; +char buf[DLM_LOCKID_NAME_MAX +1 ];assert_spin_locked (&res->spinlock);
Quoted 9 lines
fs/ocfs2/dlm/dlmdebug.c void __dlm_print_one_lock_resource(struct dlm_lock_resource *res)
Quoted 4 lines
fs/ocfs2/dlm/dlmdebug.c +1
-1stringify_lockname (res->lockname.name, res->lockname.len, - buf,sizeof (buf) -1 ); + buf,sizeof (buf));I'm confused - isn't this part then increasing the value of the parameter by 2?
--Mark
1 is for luck. ;) I'll resend the patch.
PATCH 1/1 ocfs2/cluster: Make o2net connect messages KERN_NOTICE
In reply to Sunil MushranQuoted 5 lines · Sunil Mushran
Connect and disconnect messages are more than informational as they are required during root cause analysis for failures. This patch changes them from
KERN_INFOtoKERN_NOTICE.Signed-off-by Sunil Mushran <[email protected]>
--Mark
--
Mark Fasheh
PATCH 1/1 ocfs2/cluster: Make o2net connect messages KERN_NOTICE
In reply to Sunil MushranQuoted 5 lines · Sunil Mushran
Connect and disconnect messages are more than informational as they are required during root cause analysis for failures. This patch changes them from
KERN_INFOtoKERN_NOTICE.Signed-off-by Sunil Mushran <[email protected]>
This patch is now in the 'fixes' branch of ocfs2.git.
Joel
Signature · 9 lines
Life's Little Instruction Book #207 "Swing for the fence." Joel Becker Principal Software Developer Oracle E-mail: joel.becker at oracle.com Phone: (650) 506-8127