Updated general section to include more about current capabilities. Added
[samba.git] / docs / textdocs / BUGS.txt
1 This file describes how to report Samba bugs. 
2
3 >> The email address for bug reports is samba-bugs@anu.edu.au <<
4
5 (NOTE: This mail may not be in place yet. If you have troubles with it
6 then use samba-bugs@arvidsjaur.anu.edu.au)
7
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 I
11 may be changing the bug reporting mechanism sometime soon.
12
13 Please also do as much as you can yourself to help track down the
14 bug. I only develop Samba in my spare time and I receive far more mail
15 about it than I can possibly answer, so you have a much higher chance
16 of an answer and a fix if you send me a "developer friendly" bug
17 report that lets me fix it fast. 
18
19 Do not assume that if you post the bug to the comp.protocols.smb
20 newsgroup that I will read it. I do read all postings to the samba
21 mailing list (see the README). If you suspect that your problem is not
22 a bug but a configuration problem then it is better to send it to the
23 Samba mailing list, as there are (at last count) 1900 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.canberra.edu.au/pub/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 If you include part of a log file with your bug report then be sure to
40 annotate it with exactly what you were doing on the client at the
41 time, and exactly what the results were.
42
43
44 DEBUG LEVELS
45 ------------
46
47 If the bug has anything to do with Samba behaving incorrectly as a
48 server (like refusing to open a file) then the log files will probably
49 be very useful. Depending on the problem a log level of between 3 and
50 10 showing the problem may be appropriate. A higher level givesmore
51 detail, but may use too much disk space.
52
53 To set the debug level use "log level =" in your smb.conf. You may
54 also find it useful to set the log level higher for just one machine
55 and keep separate logs for each machine. To do this use:
56
57 log file = /usr/local/samba/lib/log.%m
58 include = /usr/local/samba/lib/smb.conf.%m
59
60 then create a file "/usr/local/samba/lib/smb.conf.machine" where
61 "machine" is the name of the client you wish to debug. In that file
62 put any smb.conf commands you want, for example "log level=" may be
63 useful. This also allows you to experiment with different security
64 systems, protocol levels etc on just one machine.
65
66
67 INTERNAL ERRORs
68 ---------------
69
70 If you get a "INTERNAL ERROR" message in your log files it means that
71 Samba got an unexpected signal while running. It is probably a
72 segmentation fault and almost certainly means a bug in Samba (unless
73 you have faulty hardware or system software)
74
75 If the message came from smbd then it will probably be accompanied by
76 a message which details the last SMB message received by smbd. This
77 info is often very useful in tracking down the problem so please
78 include it in your bug report.
79
80 You should also detail how to reproduce the problem, if
81 possible. Please make this reasonably detailed.
82
83 You may also find that a core file appeared in a "corefiles"
84 subdirectory of the directory where you keep your samba log
85 files. This file is the most useful tool for tracking down the bug. To
86 use it you do this:
87
88 gdb smbd core
89
90 adding appropriate paths to smbd and core so gdb can find them. If you
91 don't have gdb then try "dbx". Then within the debugger use the
92 command "where" to give a stack trace of where the problem
93 occurred. Include this in your mail.
94
95 If you known any assembly language then do a "disass" of the routine
96 where the problem occurred (if its in a library routine then
97 disassemble the routine that called it) and try to work out exactly
98 where the problem is by looking at the surrounding code. Even if you
99 don't know assembly then incuding this info in the bug report can be
100 useful. 
101
102
103 ATTACHING TO A RUNNING PROCESS
104 ------------------------------
105
106 Unfortunately some unixes (in particular some recent linux kernels)
107 refuse to dump a core file if the task has changed uid (which smbd
108 does often). To debug with this sort of system you could try to attach
109 to the running process using "gdb smbd PID" where you get PID from
110 smbstatus. Then use "c" to continue and try to cause the core dump
111 using the client. The debugger should catch the fault and tell you
112 where it occurred.
113
114
115 PATCHES
116 -------
117
118 The best sort of bug report is one that includes a fix! If you send me
119 patches please use "diff -u" format if your version of diff supports
120 it, otherwise use "diff -c4". Make sure your do the diff against a
121 clean version of the source and let me know exactly what version you
122 used. 
123