Bug 16060 - excessive logging of get_printer_list_db: Failed to open printer_list.tdb
Summary: excessive logging of get_printer_list_db: Failed to open printer_list.tdb
Status: ASSIGNED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: Printing (show other bugs)
Version: 4.23.0
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Andreas Schneider
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2026-04-19 05:57 UTC by Michael Tokarev
Modified: 2026-04-19 07:18 UTC (History)
2 users (show)

See Also:


Attachments
log.rpcd_spoolss (1.28 MB, text/x-log)
2026-04-19 05:57 UTC, Michael Tokarev
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Tokarev 2026-04-19 05:57:34 UTC
Created attachment 18949 [details]
log.rpcd_spoolss

for a few months we observe excessive logging of the above log message.  The message is repeated every 10s, sometimes more often:

...
Apr 19 08:49:54 panda rpcd_spoolss[49526]: [2026/04/19 08:49:54.829688,  0] source3/printing/printer_list.c:57(get_printer_list_db)
Apr 19 08:49:54 panda rpcd_spoolss[49526]:   get_printer_list_db: Failed to open /run/samba/printer_list.tdb
Apr 19 08:50:04 panda rpcd_spoolss[49526]: [2026/04/19 08:50:04.842877,  0] source3/printing/printer_list.c:57(get_printer_list_db)
Apr 19 08:50:04 panda rpcd_spoolss[49526]:   get_printer_list_db: Failed to open /run/samba/printer_list.tdb
Apr 19 08:50:14 panda rpcd_spoolss[49526]: [2026/04/19 08:50:14.856452,  0] source3/printing/printer_list.c:57(get_printer_list_db)
Apr 19 08:50:14 panda rpcd_spoolss[49526]:   get_printer_list_db: Failed to open /run/samba/printer_list.tdb
Apr 19 08:50:24 panda rpcd_spoolss[49526]: [2026/04/19 08:50:24.871128,  0] source3/printing/printer_list.c:57(get_printer_list_db)
Apr 19 08:50:24 panda rpcd_spoolss[49526]:   get_printer_list_db: Failed to open /run/samba/printer_list.tdb
Apr 19 08:50:34 panda rpcd_spoolss[49526]: [2026/04/19 08:50:34.881158,  0] source3/printing/printer_list.c:57(get_printer_list_db)
Apr 19 08:50:34 panda rpcd_spoolss[49526]:   get_printer_list_db: Failed to open /run/samba/printer_list.tdb
Apr 19 08:50:44 panda rpcd_spoolss[49526]: [2026/04/19 08:50:44.884347,  0] source3/printing/printer_list.c:57(get_printer_list_db)
Apr 19 08:50:44 panda rpcd_spoolss[49526]:   get_printer_list_db: Failed to open /run/samba/printer_list.tdb
Apr 19 08:50:54 panda rpcd_spoolss[49526]: [2026/04/19 08:50:54.899767,  0] source3/printing/printer_list.c:57(get_printer_list_db)
Apr 19 08:50:54 panda rpcd_spoolss[49526]:   get_printer_list_db: Failed to open /run/samba/printer_list.tdb
Apr 19 08:51:04 panda rpcd_spoolss[49526]: [2026/04/19 08:51:04.908679,  0] source3/printing/printer_list.c:57(get_printer_list_db)
Apr 19 08:51:04 panda rpcd_spoolss[49526]:   get_printer_list_db: Failed to open /run/samba/printer_list.tdb
Apr 19 08:51:14 panda rpcd_spoolss[49526]: [2026/04/19 08:51:14.920763,  0] source3/printing/printer_list.c:57(get_printer_list_db)
Apr 19 08:51:14 panda rpcd_spoolss[49526]:   get_printer_list_db: Failed to open /run/samba/printer_list.tdb
...

===== testparam: =====

# testparm -s
Load smb config files from /etc/samba/smb.conf
Loaded services file OK.
Weak crypto is allowed by GnuTLS (e.g. NTLM as a compatibility fallback)

Server role: ROLE_DOMAIN_MEMBER

# Global parameters
[global]
	bind interfaces only = Yes
	disable netbios = Yes
	dns update command = /bin/true
	hostname lookups = Yes
	interfaces = linux/24 localhost
	kerberos encryption types = strong
	load printers = No
	netbios aliases = FS
	prefork children = 2
	printcap name = /dev/null
	realm = TLS.MSK.RU
	security = ADS
	server role = member server
	server smb transports = 445
	template homedir = /home/%U
	template shell = /bin/bash
	winbind use default domain = Yes
	workgroup = TLS
	idmap_ldb:use rfc2307 = yes
	idmap config tls : backend = ad
	idmap config tls : range = 1000-4999
	idmap config tls : schema_mode = rfc2307
	idmap config tls : unix_primary_group = yes
	idmap config * : range = 5000-5099
	idmap config * : backend = tdb
	acl allow execute always = Yes
	force printername = Yes
	print command = lpr -P%p -l -h -r %s
	printing = bsd
	vfs objects = btrfs

[hp1020]
	comment = HP LaserJet 1020
	path = /var/tmp
	printable = Yes
	printer name = hp1020

[print$]
	path = /var/lib/samba/printers
	read only = No

[homes]
	browseable = No
	read only = No

[mailstore]
	browseable = No
	path = /var/mail
	read only = No

[soft]
	comment = Software Area
	path = /share/soft

[ekis]
	comment = EKIS RDS (net install)
	path = /share/soft/ekis


[ws]
	comment = Workspace Area
	create mask = 0775
	path = /ws/ws
	read only = No
	veto oplock files = strakh.plx
=====================

Logging of rpcd_spoolss of level 10 is attached.  I've added a trivial patch trying to debug the issue, so the "Failed to open" message is slightly different:

diff --git a/source3/printing/printer_list.c b/source3/printing/printer_list.c
index 7fd07ed1f34..0b319531547 100644
--- a/source3/printing/printer_list.c
+++ b/source3/printing/printer_list.c
@@ -53,10 +53,10 @@ static struct db_context *get_printer_list_db(void)
                                 0644,
                                 DBWRAP_LOCK_ORDER_1,
                                 DBWRAP_FLAG_NONE);
-       TALLOC_FREE(db_path);
        if (printerlist_db == NULL) {
-               DBG_ERR("Failed to open printer_list.tdb\n");
+               DBG_ERR("Failed to open %s\n", db_path);
        }
+       TALLOC_FREE(db_path);
        return printerlist_db;
 }
 
rpcd_spoolss seems to ignore log_level setting in smb.conf, so I had to increase the log level using smbcontrol.
Comment 1 Michael Tokarev 2026-04-19 06:10:53 UTC
This happens with samba 4.22 and 4.23, at least.