Bug 14345 - Can't get 'log events generated from smbclient'
Summary: Can't get 'log events generated from smbclient'
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: libsmbclient (show other bugs)
Version: unspecified
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Karolin Seeger
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-04-14 11:16 UTC by Amit Kumar
Modified: 2020-07-17 09:34 UTC (History)
2 users (show)

See Also:


Attachments
patch for 4.12 and 4.11 (4.81 KB, patch)
2020-05-07 11:39 UTC, Andreas Schneider
ab: review+
Details
additional patch for 4.11 (4.81 KB, patch)
2020-05-12 09:28 UTC, Andreas Schneider
no flags Details
patch for 4.11 (4.81 KB, patch)
2020-05-12 09:36 UTC, Andreas Schneider
ab: review+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Amit Kumar 2020-04-14 11:16:57 UTC
smbclient command is not logging to the log.smbclient file. 

The command is issued with the "-l" flag with a directory location set to "/var/log/samba" 

# smbclient -l /var/log/samba //samba-server/share -d10
- This Does not dump logs inside /var/log/samba/log.smbclient

Issue not present in :samba-3.6.23
Issue present in: samba-4.9.1 onwards

How reproducible? always
Comment 1 Amit Kumar 2020-04-14 11:19:57 UTC
There is significant change in introduction of debug_backends between samba-3.6.23 and samba-4.9.1

(gdb) ptype debug_backends
type = struct debug_backend {
    const char *name;
    int log_level;
    int new_log_level;
    void (*reload)(_Bool, _Bool, const char *, char *);
    void (*log)(int, const char *, const char *);
    char *option;
} [5]
(gdb) p debug_backends[0]
$8 = {
  name = <> "file", 
  log_level = -1, 
  new_log_level = -1, 
  reload = 0x0, 
  log = <> <debug_file_log>, 
  option = 0x0
}
Comment 3 Andreas Schneider 2020-05-07 11:39:56 UTC
Created attachment 15957 [details]
patch for 4.12 and 4.11
Comment 4 Andreas Schneider 2020-05-07 18:27:39 UTC
Karolin, please apply to the relevant branches.


Btw. is there still a 4.10 maintenance release planned? I have some bugs which should be fixed in 4.10 too, this included.
Comment 5 Karolin Seeger 2020-05-12 08:19:43 UTC
(In reply to Andreas Schneider from comment #4)
Hi Andreas,

we can schedule an additional 4.10 bugfix release if needed. Please let me know which other issues should be addressed. Thanks!

Cheers,
Karo
Comment 6 Karolin Seeger 2020-05-12 08:28:03 UTC
Pushed to autobuild-v4-12-test.
Patchset does not apply on v4-11-test, re-assigning to Andreas.
Comment 7 Andreas Schneider 2020-05-12 09:28:59 UTC
Created attachment 15973 [details]
additional patch for 4.11

Cherry-picked patches from v4-12-test.
Comment 8 Andreas Schneider 2020-05-12 09:35:59 UTC
It isn't an additional patch for 4.11 it the patch generated from the v4-11-test branch. Copy and Paste error in the attachement description.
Comment 9 Andreas Schneider 2020-05-12 09:36:21 UTC
Created attachment 15974 [details]
patch for 4.11
Comment 10 Alexander Bokovoy 2020-05-12 10:33:59 UTC
Comment on attachment 15974 [details]
patch for 4.11

LGTM
Comment 11 Ralph Böhme 2020-06-29 16:05:38 UTC
This patch seems to introduce a regression resulting in broken auth_audit logging. When I revert the change it works again. Looking...
Comment 12 Ralph Böhme 2020-07-09 09:55:33 UTC
Fixes for bug 14426 that tracks the regression introduced by this commit are now available.
Comment 13 Karolin Seeger 2020-07-09 09:57:54 UTC
(In reply to Andreas Schneider from comment #9)
Pushed to autobuild-v4-11-test.
Comment 14 Karolin Seeger 2020-07-17 09:34:38 UTC
Pushed to v4-11-test.
Closing out bug report.

Thanks!