1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-22 13:34:15 +03:00
samba-mirror/source3
Jones Syue 318fd95d5e s3:smbd multichannel: always refresh the network information
To maintain SMB Multichannel, windows client might periodically query with
FSCTL_QUERY_NETWORK_INTERFACE_INFO to get SMB server's network information,
in my case windows server 2022 would do this every 10 minutes (600 seconds).

Consider a scenario: the network information might have changed between
these queries, some become link down, new interface is link up, network
speed is changed, and etc. So far smbd might not aware of these changes and
still report out-of-date network information to windows client, until we
manually send a SIGHUP to smbd in order to trigger load_interfaces():
smbd_sig_hup_handler() > reload_services () > load_interfaces()
This might be a bit inconvenient because it is hard to decide when should
we manually send a SIGHUP to smbd for refreshing network information.

This patch adds load_interfaces() at fsctl_network_iface_info(), while smbd
received FSCTL_QUERY_NETWORK_INTERFACE_INFO would go through this and refresh
local_interfaces, then respond to client with up-to-date network information;
also refresh num_ifaces to make sure interfaces count is consistent.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=15547

Signed-off-by: Jones Syue <jonessyue@qnap.com>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Björn Jacke <bjacke@samba.org>
2024-01-04 11:39:36 +00:00
..
auth s3:auth: Allow 'Unix Users' and 'Unix Groups' to create a local token 2023-12-01 08:06:44 +00:00
build
client s3/libsmb: reuse smbXcli_conn_have_posix() 2023-10-26 15:29:29 +00:00
exports
groupdb s3:groupdb: Add missing newline to logging message 2023-08-08 04:39:38 +00:00
include s3/lib: add log_panic_action() 2023-12-21 23:48:46 +00:00
intl
lib s3/lib: add log_panic_action() 2023-12-21 23:48:46 +00:00
libads s3:libads: Fix code spelling 2023-10-25 22:23:37 +00:00
libgpo/gpext
libnet s3:libnet: Remove always‐false comparison (CID 241309) 2023-10-13 02:18:31 +00:00
librpc librpc:ndr: Introduce ‘ndr_flags_type’ type 2023-11-01 20:10:45 +00:00
libsmb Use python.h from libreplace 2023-11-20 15:37:33 +00:00
locale s3:utils: Fix code spelling 2023-08-08 04:39:38 +00:00
locking libcli/security: Rename dup_nt_token() -> security_token_duplicate() 2023-09-26 23:45:36 +00:00
modules smbd: Give source3/smbd/dir.c its own header file 2023-12-19 16:05:36 +00:00
nmbd VERSION: move COPYRIGHT_STARTUP_MESSAGE as SAMBA_COPYRIGHT_STRING into version.h 2023-12-15 10:44:42 +00:00
param s3:param: Remove unnecessary use of discard_const_p() 2023-12-21 20:21:34 +00:00
passdb Use python.h from libreplace 2023-11-20 15:37:33 +00:00
printing s3:printing: Fix code spelling 2023-08-08 04:39:38 +00:00
profile profile: Fix rusage reporting 2023-12-19 16:05:36 +00:00
registry libcli/security: Rename dup_nt_token() -> security_token_duplicate() 2023-09-26 23:45:36 +00:00
rpc_client s3:rpc_client: Remove unused rpccli_lsa_open_policy2() 2023-11-21 12:21:18 +00:00
rpc_server Revert "rpc_server:srvsvc - retrieve share ACL via root context" 2023-12-20 11:20:51 +00:00
rpcclient s3:rpcclient: Use dcerpc_lsa_open_policy_fallback() in cmd_lsarpc.c 2023-11-21 11:16:37 +00:00
script shadow_copy: Add test for missing directory in "current" fileset 2024-01-02 19:39:37 +00:00
selftest s3:selftest: add samba3.blackbox.smbXsrv_client_ctdb_registered_ips 2023-12-15 11:06:34 +00:00
services
smbd s3:smbd multichannel: always refresh the network information 2024-01-04 11:39:36 +00:00
torture smbd: Give source3/smbd/dir.c its own header file 2023-12-19 16:05:36 +00:00
utils s3:utils: Fix the auth function to print correct values to the user 2024-01-04 11:26:52 +00:00
web
winbindd VERSION: move COPYRIGHT_STARTUP_MESSAGE as SAMBA_COPYRIGHT_STRING into version.h 2023-12-15 10:44:42 +00:00
.clang_complete
.dmallocrc
.indent.pro
Doxyfile
mainpage.dox
smbadduser.in
wscript s3:rpc_server/wkssvc: Remove get logged on user list from utmp 2023-10-26 22:27:44 +00:00
wscript_build VERSION: move COPYRIGHT_STARTUP_MESSAGE as SAMBA_COPYRIGHT_STRING into version.h 2023-12-15 10:44:42 +00:00
wscript_configure_system_ncurses