This commit was manufactured by cvs2svn to create branch 'SAMBA_3_0'.
[kai/samba-autobuild/.git] / docs / textdocs / BUGS.txt
1 Contributor:    Samba Team
2 Updated:        June 27, 1997
3
4 Subject: This file describes how to report Samba bugs. 
5 ============================================================================
6
7 >> The email address for bug reports is samba@samba.org <<
8
9 Please take the time to read this file before you submit a bug
10 report. Also, please see if it has changed between releases, as we
11 may be changing the bug reporting mechanism at some time.
12
13 Please also do as much as you can yourself to help track down the
14 bug. Samba is maintained by a dedicated group of people who volunteer
15 their time, skills and efforts. We receive far more mail about it than
16 we can possibly answer, so you have a much higher chance of an answer
17 and a fix if you send us a "developer friendly" bug report that lets
18 us fix it fast. 
19
20 Do not assume that if you post the bug to the comp.protocols.smb
21 newsgroup or the mailing list that we will read it. If you suspect that your 
22 problem is not a bug but a configuration problem then it is better to send 
23 it to the Samba mailing list, as there are (at last count) 5000 other users on
24 that list that may be able to help you.
25
26 You may also like to look though the recent mailing list archives,
27 which are conveniently accessible on the Samba web pages
28 at http://samba.org/samba/ 
29
30
31 GENERAL INFO
32 ------------
33
34 Before submitting a bug report check your config for silly
35 errors. Look in your log files for obvious messages that tell you that
36 you've misconfigured something and run testparm to test your config
37 file for correct syntax.
38
39 Have you run through DIAGNOSIS.txt? This is very important.
40
41 If you include part of a log file with your bug report then be sure to
42 annotate it with exactly what you were doing on the client at the
43 time, and exactly what the results were.
44
45
46 DEBUG LEVELS
47 ------------
48
49 If the bug has anything to do with Samba behaving incorrectly as a
50 server (like refusing to open a file) then the log files will probably
51 be very useful. Depending on the problem a log level of between 3 and
52 10 showing the problem may be appropriate. A higher level givesmore
53 detail, but may use too much disk space.
54
55 To set the debug level use "log level =" in your smb.conf. You may
56 also find it useful to set the log level higher for just one machine
57 and keep separate logs for each machine. To do this use:
58
59 log level = 10
60 log file = /usr/local/samba/lib/log.%m
61 include = /usr/local/samba/lib/smb.conf.%m
62
63 then create a file "/usr/local/samba/lib/smb.conf.machine" where
64 "machine" is the name of the client you wish to debug. In that file
65 put any smb.conf commands you want, for example "log level=" may be
66 useful. This also allows you to experiment with different security
67 systems, protocol levels etc on just one machine.
68
69 The smb.conf entry "log level =" is synonymous with the entry
70 "debuglevel =" that has been used in older versions of Samba and
71 is being retained for backwards compatibility of smb.conf files.
72
73 As the "log level =" value is increased you will record a significantly
74 increasing level of debugging information. For most debugging operations
75 you may not need a setting higher than 3. Nearly all bugs can be tracked
76 at a setting of 10, but be prepared for a VERY large volume of log data.
77
78
79 INTERNAL ERRORs
80 ---------------
81
82 If you get a "INTERNAL ERROR" message in your log files it means that
83 Samba got an unexpected signal while running. It is probably a
84 segmentation fault and almost certainly means a bug in Samba (unless
85 you have faulty hardware or system software)
86
87 If the message came from smbd then it will probably be accompanied by
88 a message which details the last SMB message received by smbd. This
89 info is often very useful in tracking down the problem so please
90 include it in your bug report.
91
92 You should also detail how to reproduce the problem, if
93 possible. Please make this reasonably detailed.
94
95 You may also find that a core file appeared in a "corefiles"
96 subdirectory of the directory where you keep your samba log
97 files. This file is the most useful tool for tracking down the bug. To
98 use it you do this:
99
100 gdb smbd core
101
102 adding appropriate paths to smbd and core so gdb can find them. If you
103 don't have gdb then try "dbx". Then within the debugger use the
104 command "where" to give a stack trace of where the problem
105 occurred. Include this in your mail.
106
107 If you known any assembly language then do a "disass" of the routine
108 where the problem occurred (if its in a library routine then
109 disassemble the routine that called it) and try to work out exactly
110 where the problem is by looking at the surrounding code. Even if you
111 don't know assembly then incuding this info in the bug report can be
112 useful. 
113
114
115 ATTACHING TO A RUNNING PROCESS
116 ------------------------------
117
118 Unfortunately some unixes (in particular some recent linux kernels)
119 refuse to dump a core file if the task has changed uid (which smbd
120 does often). To debug with this sort of system you could try to attach
121 to the running process using "gdb smbd PID" where you get PID from
122 smbstatus. Then use "c" to continue and try to cause the core dump
123 using the client. The debugger should catch the fault and tell you
124 where it occurred.
125
126
127 PATCHES
128 -------
129
130 The best sort of bug report is one that includes a fix! If you send us
131 patches please use "diff -u" format if your version of diff supports
132 it, otherwise use "diff -c4". Make sure your do the diff against a
133 clean version of the source and let me know exactly what version you
134 used. 
135