[Samba] Suddenly can't print: "rec_read bad magic..."

lukekendall at optushome.com.au lukekendall at optushome.com.au
Tue Sep 3 12:42:00 GMT 2002


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 at 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 at 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 at leathercollection.ph
Network Administrator :: The Leather Collection, Inc.
GnuPG Key: http://jijo.leathercollection.ph/jijo.gpg





More information about the samba mailing list