lukekendall@optushome.com.au
2002-Sep-03 12:42 UTC
[Samba] Suddenly can't print: "rec_read bad magic..."
Suddenly, today, my wife's Windows 95 machine can't print to the network printer on my Linux machine. It complains that "there was an error printing to \\posh\lp ... There was a problem printing to the port." The error 1st occurred (coincidentally?) after I had upgraded the kernel from 2.4.18 to 2.4.19. But rebooting to 2.4.18 has made no difference. We're running smbd 2.2.1a. /var/log/samba/coo.log contains a lot of messages like this: [2002/09/03 09:56:30, 0] tdb/tdbutil.c:tdb_log(342) tdb(/var/cache/samba/printing.tdb): rec_free_read bad magic 0xfee1dead at offset=17772 [2002/09/03 09:56:31, 0] tdb/tdbutil.c:tdb_log(342) tdb(/var/cache/samba/printing.tdb): rec_read bad magic 0xd9fee666 at offset=16684 (What's the chance that a hex number spells out what looks like "feel dead"? A flagged value or pure chance?) Anyway, I noticed that someone else had what looks like the same problem in 2.2.3 on February 22nd, but apparently no one replied. Any suggestion about what I can do to fix the problem? What would happen if I were to remove /var/cache/samba/printing.tdb ? Should I simply grab the latest Samba and try that? luke From: Federico Sevilla III <jijo@leathercollection.ph> Subject: [Samba] rec_free_read bad magic and tdb corruption with Samba 2.2.3 Date: Fri, 22 Feb 2002 20:37:01 +0800 (PHT) To: Samba Mailing List <samba@lists.samba.org> Hi everyone, Our system is a Debian GNU/Linux box running Linux kernel 2.4.17-xfs and Samba 2.2.3 (from the 2.2.3-5 package from Sid), built using gcc-3.0.3. With Samba 2.2.2 we hit certain tdb errors where make_connection would reject connections arbitrarily. Supposedly this was fixed using 2.2.3 so we upgraded right away (thankfully we do only have Windows 95, 98 and ME clients so we weren't hit by the problem with Windows 2000). Things were going smoothly until today when suddenly workstations started being unable to connect to the server. Running smbstatus and checking various Samba logs (per machine) reported that a problem was hit with tdb again. Here is a sample of the error messages received (there were -LOTS- of these, and nothing particularly interesting happening before they started appearing): [2002/02/22 14:11:45, 1] smbd/service.c:make_connection(615) boss (192.168.0.3) connect to service jomaster as user boss (uid=1001, gid=50) (pid 18353) [2002/02/22 14:23:48, 0] tdb/tdbutil.c:tdb_log(475) tdb(/var/run/samba/connections.tdb): rec_free_read bad magic 0x26011999 at offset=286720 [2002/02/22 14:23:48, 0] smbd/connection.c:claim_connection(187) claim_connection: tdb_store failed with error Corrupt database. [2002/02/22 14:23:48, 1] smbd/service.c:make_connection(505) too many connections - rejected I am rebuilding Samba using the 2.2.3-6 package sources (no Debian package for 2.2.3a yet, it seems), again using gcc-3.0.3. Would anyone have any tips about how I can go about isolating the problem? Up to now I haven't figured out how to reproduce the problem despite the fact it's happened before (perhaps this is the fourth or fifth time including 2.2.2, the first for 2.2.3, and the first time those "bad magic" errors came out). Thank you very much in advance. --> Jijo PS- I am not part of this list and will appreciate if I can be cc'd replies. I will check the archives regularly to check things out, though. -- Federico Sevilla III :: jijo@leathercollection.ph Network Administrator :: The Leather Collection, Inc. GnuPG Key: http://jijo.leathercollection.ph/jijo.gpg
lukekendall@optushome.com.au
2002-Sep-03 13:41 UTC
[Samba] Suddenly can't print: "rec_read bad magic..."
On 3 Sep, Knut Ove Hauge wrote:> Maybe the port is not opened. > Which firewall do u use? > Does the printer print from your lindoze? > It shouldent had something to do with your kernel version except from > the firewalls and what firewall system the kernel is compiled for.No changes were made to the firewall configuration (which is an external box, not part of the kernel), and the Windows machine could still browse files on the Linux machine - it just couldn't print. After a bit of poking about through old emails on the list, I found that it was safe to remove /var/cache/samba/printing.tdb and restart samba, so that's what I did. That fixed the problem. I have no idea what corrupted the printing.tdb file, however. Thanks for the suggestion anyway, Knut. luke
Gerald (Jerry) Carter
2002-Sep-03 16:21 UTC
[Samba] Suddenly can't print: "rec_read bad magic..."
On Tue, 3 Sep 2002 lukekendall@optushome.com.au wrote:> Any suggestion about what I can do to fix the problem? > What would happen if I were to remove /var/cache/samba/printing.tdb ?no problem. it is a volatile tdb used to cache the contents of print queues. cheers, jerry --------------------------------------------------------------------- Hewlett-Packard http://www.hp.com SAMBA Team http://www.samba.org -- http://www.plainjoe.org "Sam's Teach Yourself Samba in 24 Hours" 2ed. ISBN 0-672-32269-2 --"I never saved anything for the swim back." Ethan Hawk in Gattaca--
Maybe Matching Threads
- rec_free_read bad magic and tdb corruption with Samba 2.2.3
- Sudden Bug
- Samba 2.2.5 under Debian 3.0 i386: Still frequent connections.tdb corruption
- REPOST: Samba 2.2.5 under Debian 3.0 i386: Still frequent connections.tdb corruption
- Countless "rec_read bad magic" lines in log.smbd