Thunderbird лог ошибок соединения

Вначале было слово. Потом появились логи. Разработчики почтового клиента Thunderbird почему-то решили, что по умолчанию смотреть на работу протокола SMTP — вещь обычному пользователю не особо нужная и затолкали отображение логов далеко под корку настроек. К счастью, наша археологическая экспедиция нашла способ быстро это исправить.

Заходим в «Настройки» и скроллим в самый низ до кнопки «Редактор настроек»

Вбиваем в поиск параметр mailnews.smtp.loglevel и меняем его с помощью кнопки редактирования (карандаша) в конце строки на All (по умолчанию стоит warn)

После этого в консоли ошибок (ctrl+shift+j, либо через «Инструменты» -> «Инструменты разработчика») мы увидим логи SMTP при отправке сообщения:

SMTPThunderbirdСети



How to enable logging on mozilla thunderbird?

This is how to temporatly allow logging of thunderbird imap4, php3 or smtp connection events to a file to find out why things don’t work as expected.
The only permanent changes it makes, is the creation of your logfile… the logging mode will turn off, as soon as you close thunderbird and the commandline.

Open your commandline and type in these settings:

Windows command line:
set MOZ_LOG=IMAP:5,timestamp
set MOZ_LOG_FILE=%USERPROFILE%Desktopimap.log
“%ProgramFiles(x86)%Mozilla Thunderbirdthunderbird.exe”

Mac OS X:
#!/bin/sh
export MOZ_LOG=IMAP:5,timestamp
export MOZ_LOG_FILE=$HOME/imap.log
/Applications/Thunderbird.app/Contents/MacOS/thunderbird-bin &
if on 10.5 change the above line to arch -arch i386 /Applications/Thunderbird.app/Contents/MacOS/thunderbird-bin

Linux Bash:
# For bash shell (the default shell on most GNU/Linux systems):
export MOZ_LOG=IMAP:5,timestamp
export MOZ_LOG_FILE=/tmp/imap.log

Linux TCSH CSH:
# For tcsh / csh (which is not as common):
setenv MOZ_LOG IMAP:5
setenv MOZ_LOG_FILE /tmp/imap.log

As seen on

https://wiki.mozilla.org/MailNews:Logging#Windows

Не могу получить писма по pop, хочу посмотреть причину. Где лог?

А «Инструменты» — «Консоль ошибок» и «Диспетчер работы» — не помогут?

Тэги: Админ

Комментарии доступны только авторизированным пользователям

Похожие вопросы 1С

В этой группе 1С

<< Back to MailNews:Home Page

Logs provide data to help developers and triagers understand what is causing an issue. Please provide a log file when requested. If you have difficulty or questions, please ask for help.

Contents

  • 1 Introduction
  • 2 Thunderbird Logging
    • 2.1 Thunderbird Logging Types
    • 2.2 Setting a Preference
  • 3 Gecko Logging
    • 3.1 Thunderbird Module Names
    • 3.2 Environment Variables to set
      • 3.2.1 MOZ_LOG_FILE
      • 3.2.2 MOZ_LOG
        • 3.2.2.1 Logging Level
    • 3.3 Generating a Gecko Log
      • 3.3.1 Windows
      • 3.3.2 Mac OS X
      • 3.3.3 Linux/unix
    • 3.4 Missing Log File
  • 4 NSPR Logging Options
  • 5 Enhancement Ideas
  • 6 Logging prior to Thunderbird 55.0a1 / SeaMonkey 2.52a1

Introduction

Logging in recent years has evolved in:

  • where logging is enabled — possibilities include command line, and Thunderbird preferences
  • location of log data — possibilities include logging to a file, and logging to the Error Console

Also, we have two types of logging:

  • Thunderbird logging, for calendar, chat, gloda indexing and seach, ldap, nntp (news), pop, and smtp (sending mail)
  • Gecko logging, which uses case senstive module names, such as IMAP and IMAPAutoSync

Thunderbird Logging

Modern logging is specified by setting a preference in Thunderbird.

Unless otherwise specified, logging output goes to the Error Console, at Tools > Developer > Error Console or use the hotkey Control+Shift+J (Command+Shift+J on macOS).

Thunderbird Logging Types

Log settings of type string are Case Sensitive. For example, use All, not ALL.

  • Calendar — set both calendar.debug.log and calendar.debug.log.verbose to true, and reload calendar pane. Reference: Calendar/Calendar logging
  • Chat — purple.debug.loglevel set to [1]
    • 0 Show all libpurple messages (PURPLE_DEBUG_ALL)
    • 1 Very verbose (PURPLE_DEBUG_MISC)
    • 2 Verbose (PURPLE_DEBUG_INFO)
    • 3 Show warnings (PURPLE_DEBUG_WARNING)
    • 4 Show errors (PURPLE_DEBUG_ERROR)
    • 5 Show only fatal errors (PURPLE_DEBUG_FATAL)
  • Chat Off-The-Record (OTR) protocol for exchanging encrypted chat messages — chat.otr.trace boolean preference
  • Gloda Indexing (global search) activity to Error Console
  • imap — mailnews.imap.loglevel string, set to All (if you have set mailnews.imap.jsmodule=true, Daily channel builds only)
  • ldap — mailnews.ldap.loglevel, string, set to All
  • NNTP — mailnews.nntp.loglevel, string, set to All
  • OpenPGP/e2ee — logging is described at OpenPGP Debugging
  • pop3 — mailnews.pop3.loglevel, string, set to All
  • smtp — mailnews.smtp.loglevel, string, set to All

Setting a Preference

To configure logging via a Thunderbird Preference, you must create a hidden Thunderbird preference, not an environment variable. In Thunderbird :

  1. do Settings > General
  2. in the search field type config editor
  3. click Config Editor in the search results
  4. in the search field paste or type the preference name, for example mailnews.pop3.loglevel
  5. if you are presented with choices of Boolean, Number, String
    1. choose Boolean for true or false settings, otherwise choose String
    2. click the + (plus sign) to add the preference
  6. change the preferences’ value to the desired logging value
    • for string preferences click the pencil icon, change the value, then click the check mark
    • for boolean preferences click the double headed arror to switch between true and false

Logging is permanent until you reset or delete a preference (by clicking the trash can).

It is not necessary to restart Thunderbird — logging starts immediately.

You can view the output at Tools > Developer > Error Console. To expose timestamp, click the gear icon in top-right of the Error Console, turn on «Show Timestamps».

Gecko Logging

Gecko logging using module names is the classic method of getting log data. Gecko logging may be enabled via preferences (not discussed in this document), or command line, which is discussed here.

Thunderbird gets its module logging capabilities from Firefox core aka Gecko. Gecko logging capabilities are thoroughly documented in this excellent reference.

Thunderbird Module Names

All names are CASE SENSITIVE.

  1. AbOutlookDirectory (before Thunderbird version 59: nsAbOutlookDirectoryLog)
  2. AbWinHelper (before Thunderbird version 59: nsAbWinHelperLog)
  3. BayesianFilter
  4. CMS (for S/MIME)
  5. Filters
  6. IMAP
  7. IMAP_CS (for CONDSTORE)
  8. IMAP_KW (for keyword (tag) processing)
  9. IMAPAutoSync (before Thunderbird version 59: ImapAutoSync)
  10. IMAPCache (for IMAP caching of messages in no-sync folders)
  11. IMAPOffline (before Thunderbird version 59: IMAPOFFLINE)
  12. Import (before Thunderbird version 59: IMPORT)
  13. ldap (After Thunderbird 90 use Thunderbird logging)
  14. Mailbox (before Thunderbird version 59: MAILBOX)
  15. MailDirStore
  16. MAPI
  17. MAPIAddressBook
  18. MIME
  19. MsgBiff
  20. MsgCompose (before Thunderbird version 59: msgcompose)
  21. MsgCopyService (3.3a4 nightly builds starting 5/2/2011)
  22. MsgDB (level 1=opens/closes, level 5 lists open db’s on close, number of msg hdrs in use) (before Thunderbird version 59: MSGDB)
  23. MsgPurge
  24. NNTP (After Thunderbird 95 use Thunderbird logging)
  25. pop3 (After Thunderbird 98 use Thunderbird logging)
  26. smtp (After Thunderbird 90 use «Thunderbird logging)

Notes:

  • The current, full list of Thunderbird module names is seen in this searchfox query.
  • Gecko modules potentially useful to Thunderbird users:
    • nsHostResolver (for DNS)
    • GetAddrInfo (for DNS)
    • nsSocketTransport (basic networking)
    • negotiateauth (authentication)
  • Version 59 bug 1353919 changed these options to be mixed case. The old, inconsistent case options are in parenthesis above.
  • Deprecated:
    • Movemail
    • AbOutlookDirFactory (before Thunderbird version 59: nsAbOutlookDirFactoryLog)
    • WABAddressBook

Environment Variables to set

NOTE — do not use this section for ldap, nntp, pop3 and smtp, which are configured per Thunderbird logging.

Two variables must be set, MOZ_LOG and MOZ_LOG_FILE as local environment variables in a batch file/script (described below) or on a command line. (using global system environment variables is not recommended)

MOZ_LOG_FILE

MOZ_LOG_FILE is the path and file name to the log file. An extension of .moz_log will be added to the file name (since Thunderbird 70). If MOZ_LOG_FILE is not set, then the output will be logged to the console/terminal (stdout) where the application was launched.

Example:
set MOZ_LOG_FILE=thunderbird-log-file

Note:

  • The log file is written over every time you re-launch the application.
  • You must have write access to the directory of the log file. The user’s desktop directory or system temp directory are often a good choices.
  • If you run multiple applications at the same time, such as Firefox and Thunderbird, then might both write to the log file and possibly wipe out the other’s log entries. Workarounds:
    • Run only one application at a time
    • Use the append option
    • Force logging to the console by setting MOZ_LOG_FILE to null, MOZ_LOG_FILE=.

MOZ_LOG

MOZ_LOG syntax is a list of terms, separated by commas. There are two types of terms:

  • A CASE SENSITIVE module name and its log level, separated by a colon (:), such as example_module:5 to enable the module example_module at logging level 5 (verbose).
  • Optional special strings (switches) to configure the logging behaviour. Some configuration switches take an integer parameter, in which case the integer is separated from the string by a colon (:). Most switches only apply in a specific output context. Full documentation at [2].

Example module and loglevel: IMAP:4,IMAPAutoSync:5,timestamp

,timestamp adds a timestamp to all log lines — generally recommended, and required for all timeouts and issues which need to be correlated to an action at a given time of day

Logging Level

NOTE — do not use this section for ldap, nntp, pop3 and smtp, which are configured per Thunderbird logging.

The number in MOZ_LOG specifies the level of logging to be used. A lower number reduces the amount of information being logged. Use «5» unless requested otherwise.

  • 0 = Disabled /* Indicates logging is disabled. Progammers should not use this directly in code. */
  • 1 = Error /* An error occurred. Also generally something a programmer would consider asserting in a debug build. */
  • 2 = Warning /* A warning often indicates an unexpected state. */
  • 3 = Info /* An informational message, which often indicates the current program state. */
  • 4 = Debug /* A debug message, which is useful for debugging but too verbose to be turned on normally. */
  • 5 = Verbose /* A message that will be printed a lot, useful for debugging program flow and will probably impact performance. */ Verbose is not recommended for IMAP.

Some modules may not work exactly according to the log levels noted above. Very few modules actually have more than one logging level.

Generating a Gecko Log

NOTE — do not use this section for ldap, nntp, pop3 and smtp, which are configured per Thunderbird logging.

For Gecko logging, use module names.

Windows

Create a batch file by copying the lines below and paste them into the notepad application, and save the file as «create_log.bat». Variables MOZ_LOG and MOZ_LOG_file must not contain quotation marks.

set MOZ_LOG=moduleName:5,timestamp
set MOZ_LOG_FILE=%USERPROFILE%Desktoplog_file
"%ProgramFiles(x86)%Mozilla Thunderbirdthunderbird.exe"
  • On versions with User Account Control (UAC), the batch file must be run with administrator privileges. Right click on the batch file and select «Run as administrator». Otherwise the log file will not be created and no UAC warnings will be generated.
  • XP and Vista users should specify %ProgramFiles% instead of %ProgramFiles(x86)% (which is for Windows 7) — assuming Thunderbird was installed to it’s default location.

Now run the batch file. The example puts the log file on your desktop:

You can set up the batch file to be run using of these methods: double click the batch file, create a shortcut, add it to start menu, from a command window prompt, or from the start>run dialog.

Logging commands can also typed directly in the command prompt instead of running a batch file. On Windows 2000, XP, 2003 Server: Start>Programs>Accessories>Command Prompt. On later windows versions, you may type «cmd» and press enter in the launch dialog of the Start button.

Mac OS X

To generate an log, create a text file that contains the desired commands in a text editor such as BBEdit:

#!/bin/sh
export MOZ_LOG=moduleName:5,timestamp
export MOZ_LOG_FILE=$HOME/Desktop/log_file
/Applications/Thunderbird.app/Contents/MacOS/thunderbird-bin &

If on MacOS 10.5, change the last line to arch -arch i386 /Applications/Thunderbird.app/Contents/MacOS/thunderbird-bin &

Save this file with a filename ending in .command, add execute permission by typing «chmod a+x filename» in a Terminal window, then double-click it.

Alternatively, you can setup a file so that the protocol tracing will always be in effect. (Not recommended if you use both Firefox and Thunderbird) To do this open a Terminal window, cd into the .MacOSX directory under your login directory and create a file named environment.plist containing the following. Non-unix users can use the «pico» editor which I think is available on OS X by default:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>MOZ_LOG_FILE</key>
<string>/tmp/log_file.txt</string>
<key>MOZ_LOG</key>
<string>moduleName:5,timestamp</string>
</dict>
</plist>

Note, line starting with «<!DOCTYPE» should be oneline all the way to «dtd», but I’m not sure if that makes a difference.

Linux/unix

To generate a log, run the following commands before running the application from the command line:

# For bash shell (the default shell on most GNU/Linux systems):
export MOZ_LOG=moduleName:5,timestamp
export MOZ_LOG_FILE=/tmp/log_file
# For tcsh / csh (which is not as common):
setenv MOZ_LOG moduleName:5,timestamp 
setenv MOZ_LOG_FILE /tmp/log_file

Missing Log File

If your log file is empty or missing, review this document again, and check for these common problems:

  • Are you logging ldap, nntp, pop3, or smtp? You must use Thunderbird logging, not Gecko module logging using environment variables.
  • Do you have write access to the directory specified in MOZ_LOG_FILE?
  • Did you shut down the application? (the log file is buffered in memory until the application is closed)
  • Did you restart your mailnews application, and wipe out the log of the session you wanted to debug? (every restart wipes out the previous log)
  • If you used a batch file on Windows, is the batch file set to run with administrator privileges?
  • Do your log variables contain quotation marks or other invalid characters?
  • Are your log module names correctly CASE SENSITIVE? (meaning mixed case, or camel case which is not all upper case, nor all lower case)

NSPR Logging Options

NSPR also has logging. Miscellaneous NSPR Reference (logging).

Enhancement Ideas

  • bug 492620 — better, easier logging/diagnostics for Thunderbird [meta]
  • bug 193873 — Add Mozilla logging to UI / Thunderbird:Logging_UI
  • bug 697522 — precise logging of message filter runs and actions

Logging prior to Thunderbird 55.0a1 / SeaMonkey 2.52a1

Around April 5, 2017, via bug 1222244 and blockers of bug 1219461, changes were merged to the Mozilla trunk which impacted logging functionality. Prior to these changes, the variable names used to configure logging were NSPR_LOG_MODULES and NSPR_LOG_FILE rather than MOZ_LOG and MOZ_LOG_FILE. If you are working with an older version, use the old variable names.

In addition, some log module names changed. The old names are documented below, but will eventually be removed (along with this section) when enough time has past that it is no longer necessary for most people to debug older versions of the applications. Of course, the obsolete documentation will remain accessible in the history of this page.

Note that log module names are CASE SENSITIVE.

This article is about troubleshooting techniques for advanced users who are investigating problems with servers. It applies to all of the server types that Thunderbird connects to:

POP3  For getting mail
IMAP  For getting mail
SMTP  For sending mail
NNTP  For usenet news
HTTP  For RSS feeds
LDAP  For address books

These methods are only useful for investigating problems that occur after Thunderbird establishes a connection to a server. If Thunderbird cannot connect to the server, then it is pointless trying to log the connection—in these cases, see: Network tools for server connections

To use these methods for investigating secure authentication, you will need additional tools depending on the authentication method.

Contents

  • 1 Methods for logging
    • 1.1 Using Thunderbird
      • 1.1.1 Sample batch files for Windows
      • 1.1.2 Other types of problems you can solve
    • 1.2 Using a proxy
    • 1.3 Using a packet sniffer
  • 2 Interpreting a connection log
    • 2.1 POP3 connection states
    • 2.2 SMTP connection states
    • 2.3 NNTP connection states
  • 3 Examples
  • 4 Rich logging using Gloda
  • 5 See also
  • 6 External links

Methods for logging

There are three methods for logging server connections:

  • Thunderbird itself
  • A logging proxy
  • A packet sniffer

Using Thunderbird

Thunderbird can create a log file for the server types POP3, IMAP, SMTP, NNTP and HTTP, and MIME and LDAP protocols.

When you use Thunderbird to log a connection:

  • You do not see all the authentication information, so you might not be able to investigate authentication problems in detail.
  • You can log secure (SSL and TLS) connections.

To create the log file, follow the instructions on the Mozilla web page linked below. Use log level 5, and remember to specify POP3:5, IMAP:5, SMTP:5, NNTP:5, nsHttp:5, MIME:5 or LDAP:5, depending on which type of server or protocol you are investigating. (The module nsHttp is not mentioned on the linked page.)

MailNews Logging

Exiting Thunderbird usually does not close any existing connections to a mail server, it can take 5-10 minutes for them to time out. It’s much easier to debug a problem when you can also log it making a new connection. For example, if you enabled IMAP logging and the connection to the AIM mail server was still open you would see something roughly like:

0[34988]: 2310cc0:imap.cs.com:NA:SetupWithUrl: clearing IMAP_CONNECTION_IS_OPEN

If the log file is empty that normally means you either didn’t configure the logging correctly (you need to specify POP3:5 , not POP:5 for example) or you couldn’t make a TCP-IP connection to the mail server for some reason. You could use netstat to list your connections. Run it from a console window/DOS box.

Its recommended that you add a timestamp. A combination like

MOZ_LOG=imap:5,timestamp

would add the time of an event to each entry.

Sample batch files for Windows

The environmental variables NSPR_LOG_MODULES and NSPR_LOG_FILE are being replaced with MOZ_LOG and MOZ_LOG_FILE starting with Thunderbird 55.0a1. These sample batch files use both so that they should work with any version.

To enable logging for a IMAP account create a imap.bat file at %APPDATA%ThunderbirdProfiles (enter that string in the Windows search box and press Enter to go there using Windows Explorer) using a text editor such as Notepad. This is the default location that profiles are created in (as child directories). The log file will be created in the same directory as the imap.bat file.

Double click on the batch file and it will start Thunderbird with IMAP logging enabled. Duplicate the problem and exit Thunderbird. Afterwards open the imap.log log file with a text editor to view the log. The log file is usually too long to post in the forums. If you are asking for help in the forums it is suggested that you log into https://pastebin.com , https://www.dropbox.com or https://docs.google.com/document/ , upload the log file and then post a link to it in the forum. The log file does not contain passwords. It will contain some strings that use portions of your email address but it is garbled, so that spammers using a spider to collect email addresses should ignore it.

For a IMAP account create the following imap.bat file:

set MOZ_LOG=IMAP:5,timestamp
set MOZ_LOG_FILE=%APPDATA%ThunderbirdProfilesimap.log
set NSPR_LOG_MODULES=IMAP:5,timestamp
set NSPR_LOG_FILE=%APPDATA%ThunderbirdProfilesimap.log
"%ProgramFiles(x86)%Mozilla Thunderbirdthunderbird.exe"

For a POP account create the following pop.bat file instead:

set MOZ_LOG=POP3:5,timestamp
set MOZ_LOG_FILE=%APPDATA%ThunderbirdProfilespop.log
set NSPR_LOG_MODULES=POP3:5,timestamp
set NSPR_LOG_FILE=%APPDATA%ThunderbirdProfilespop.log
"%ProgramFiles(x86)%Mozilla Thunderbirdthunderbird.exe"

To log sending a email message (SMTP) create the following smtp.bat file instead:

set MOZ_LOG=SMTP:5,timestamp
set MOZ_LOG_FILE=%APPDATA%ThunderbirdProfilessmtp.log
set NSPR_LOG_MODULES=SMTP:5,timestamp
set NSPR_LOG_FILE=%APPDATA%ThunderbirdProfilessmtp.log
"%ProgramFiles(x86)%Mozilla Thunderbirdthunderbird.exe"

You can replace %APPDATA%ThunderbirdProfiles with %USERPROFILE%Desktop if you want to display the log file on your desktop instead. Or replace it with any path you want.

The logging is not account specific, it will log everything for that type of account. It is usually a good idea to temporarily disable checking for new mail in the other accounts by unchecking «check for new mail on startup» etc. before using the batch file, and not selecting any of the other accounts folders in the folder pane while duplicating the problem. Otherwise not only will it log everything for every account of that type, but it may intermingle the logging (making it much harder to read).

Other types of problems you can solve

You can also log memory usage using MSGDB:5 to help diagnose memory usage problems. If you build a debug version of Thunderbird there are other logging options such as MAPI, msgcompose, imapoffline etc. that may be useful for debugging.

Using a proxy

A logging proxy is an additional program that logs a specific connection.

When you use a proxy:

  • You can log any server type.
  • You do not see Thunderbird’s connection states. This simplifies the log, but it might make some problems more difficult to discover.
  • You see the raw data with no explanatory information.
  • You see all the authentication information. However, investigating secure authentication requires additional tools.
  • You cannot successfully log a secure (SSL) connection, nor a TLS connection after the initial negotiation.

To configure a proxy, either change Thunderbird’s server settings, or use Thunderbird’s proxy settings to specify localhost (your own computer, where the proxy is running) as the proxy server. By changing settings in Thunderbird, you risk changing the nature of the problem that you are investigating. If possible, check the proxy configuration with a working server before you use it with the server you are investigating.

To change Thunderbird’s server settings, point Thunderbird at the server localhost and point the logging proxy at the real server.

To change Thunderbird’s proxy settings, choose: Tools – Options… – General – Connection Settings…, choose «Manual proxy configuration», set the HTTP proxy to localhost, and check the box «Use this proxy server for all protocols». Use whatever port you have configured in the proxy—for example, 80. Point the logging proxy at the real server and port.

Some examples of logging proxies that you can download are:

  • Trivial Proxy (Windows only)
  • TCPreen (cross-platform)

Using a packet sniffer

A packet sniffer is an additional program that logs network traffic. You usually configure the packet sniffer to filter the log, so that you only see the parts that interest you. The resulting log contains information similar to a proxy log, but it might be presented in a much more complex way, depending on the sniffer and on how you configure it.

When you use a packet sniffer:

  • You can log any server type.
  • You do not change any settings in Thunderbird.
  • You see the raw data with no explanatory information.
  • You do not see Thunderbird’s connection states. This simplifies the log, but it might make some problems more difficult to discover.
  • You see all the authentication information. However, investigating secure authentication requires additional tools.
  • You cannot successfully log a secure (SSL) connection, nor a TLS connection after the initial negotiation.

Configuring a packet sniffer depends on the sniffer.

Some examples of packet sniffers that you can download are:

  • Wireshark (cross-platform) (was Ethereal)
  • tcpdump (cross-platform)
  • Snort (cross-platform)

Interpreting a connection log

To interpret a connection log, you need to understand something about how the server works and how Thunderbird works.

The server specifications are Internet standards published as RFCs.
There are some links to them in the External links section below.

For POP3, SMTP and NNTP, Thunderbird works by computing a connection state that tells it what to expect from the server and what to do next. These connection states are internal to Thunderbird. They might be different in different releases of Thunderbird. To understand the connection states in detail, you might have to read Thunderbird’s C++ source code.

POP3 connection states

 0 READ_PASSWORD 
 1 START_CONNECT 
 2 FINISH_CONNECT 
  3 WAIT_FOR_RESPONSE 
  4 WAIT_FOR_START_OF_CONNECTION_RESPONSE 
  5 SEND_USERNAME 
  6 SEND_PASSWORD 
  7 SEND_STAT 
 8 GET_STAT 
 9 SEND_LIST 
10 GET_LIST 
11 SEND_UIDL_LIST 
12 GET_UIDL_LIST 
13 SEND_XTND_XLST_MSGID 
14 GET_XTND_XLST_MSGID 
15 GET_MSG 
16 SEND_TOP 
17 TOP_RESPONSE 
18 SEND_RETR 
19 RETR_RESPONSE 
20 SEND_DELE 
21 DELE_RESPONSE 
22 SEND_QUIT 
23 DONE 
24 ERROR_DONE 
25 FREE 
26 START_USE_TOP_FOR_FAKE_UIDL 
27 SEND_FAKE_UIDL_TOP 
28 GET_FAKE_UIDL_TOP 
29 SEND_AUTH 
30 AUTH_RESPONSE 
31 SEND_CAPA 
32 CAPA_RESPONSE 
33 PROCESS_AUTH 
34 AUTH_FALLBACK 
35 AUTH_LOGIN 
36 AUTH_LOGIN_RESPONSE 
37 AUTH_NTLM 
38 AUTH_NTLM_RESPONSE 
39 SEND_XSENDER 
40 XSENDER_RESPONSE 
41 SEND_GURL 
42 GURL_RESPONSE 
43 QUIT_RESPONSE 
44 INTERRUPTED 
45 TLS_RESPONSE 
46 AUTH_GSSAPI 
47 AUTH_GSSAPI_FIRST 
48 AUTH_GSSAPI_STEP 

SMTP connection states

 0 RESPONSE
 1 START_CONNECT
 2 FINISH_CONNECT
 3 SEND_HELO_RESPONSE
 4 SEND_EHLO_RESPONSE
 5 SEND_VRFY_RESPONSE
 6 SEND_MAIL_RESPONSE
 7 SEND_RCPT_RESPONSE
 8 SEND_DATA_RESPONSE
 9 SEND_POST_DATA
10 SEND_MESSAGE_RESPONSE
11 DONE
12 ERROR_DONE
13 FREE
14 AUTH_LOGIN_STEP0_RESPONSE
15 EXTN_LOGIN_RESPONSE
16 SEND_AUTH_LOGIN_STEP0
17 SEND_AUTH_LOGIN_STEP1
18 SEND_AUTH_LOGIN_STEP2
19 AUTH_LOGIN_RESPONSE
20 TLS_RESPONSE
21 AUTH_EXTERNAL_RESPONSE
22 AUTH_PROCESS_STATE
23 AUTH_CRAM_MD5_CHALLENGE_RESPONSE
24 SEND_AUTH_GSSAPI_FIRST
25 SEND_AUTH_GSSAPI_STEP

NNTP connection states

 0 RESPONSE
 1 CONNECT
 2 CONNECT_WAIT
 3 LOGIN_RESPONSE
 4 SEND_MODE_READER
 5 SEND_MODE_READER_RESPONSE
 6 SEND_LIST_EXTENSIONS
 7 SEND_LIST_EXTENSIONS_RESPONSE
 8 SEND_LIST_SEARCHES
 9 SEND_LIST_SEARCHES_RESPONSE
10 LIST_SEARCH_HEADERS
11 LIST_SEARCH_HEADERS_RESPONSE
12 GET_PROPERTIES
13 GET_PROPERTIES_RESPONSE
14 SEND_LIST_SUBSCRIPTIONS
15 SEND_LIST_SUBSCRIPTIONS_RESPONSE
16 SEND_FIRST_NNTP_COMMAND
17 SEND_FIRST_NNTP_COMMAND_RESPONSE
18 SETUP_NEWS_STREAM
29 BEGIN_AUTHORIZE
20 AUTHORIZE_RESPONSE
21 PASSWORD_RESPONSE
22 READ_LIST_BEGIN
23 READ_LIST
24 DISPLAY_NEWSGROUPS
25 NEWGROUPS_BEGIN
26 NEWGROUPS
27 BEGIN_ARTICLE
28 READ_ARTICLE
29 XOVER_BEGIN
30 FIGURE_NEXT_CHUNK
31 XOVER_SEND
32 XOVER_RESPONSE
33 XOVER
34 PROCESS_XOVER
35 READ_GROUP
36 READ_GROUP_RESPONSE
37 READ_GROUP_BODY
38 SEND_GROUP_FOR_ARTICLE
39 SEND_GROUP_FOR_ARTICLE_RESPONSE
40 PROFILE_ADD
41 PROFILE_ADD_RESPONSE
42 PROFILE_DELETE
43 PROFILE_DELETE_RESPONSE
44 SEND_ARTICLE_NUMBER
45 PROCESS_BODIES
46 PRINT_ARTICLE_HEADERS
47 SEND_POST_DATA
48 SEND_POST_DATA_RESPONSE
49 CHECK_FOR_MESSAGE
50 NEWS_RC_POST
51 DISPLAY_NEWS_RC
52 DISPLAY_NEWS_RC_RESPONSE
53 START_CANCEL
54 DO_CANCEL
55 XPAT_SEND
56 XPAT_RESPONSE
57 SEARCH
58 SEARCH_RESPONSE
59 SEARCH_RESULTS
60 LIST_PRETTY_NAMES
61 LIST_PRETTY_NAMES_RESPONSE
62 LIST_XACTIVE
63 LIST_XACTIVE_RESPONSE
64 LIST_GROUP
65 LIST_GROUP_RESPONSE
66 NEWS_DONE
67 NEWS_POST_DONE
68 NEWS_ERROR
69 ERROR
70 NEWS_FREE
71 NEWS_FINISHED

Examples

Here is a proxy log of a connection to a POP3 server. There are no messages on the server:

+OK Hello there.
AUTH
-ERR Invalid command.
CAPA
+OK Here's what I can do:
SASL LOGIN CRAM-MD5 CRAM-SHA1
TOP
USER
LOGIN-DELAY 10
PIPELINING
UIDL
IMPLEMENTATION Courier Mail Server
.
AUTH LOGIN
+ VXNlcm5hbWU6
anVzdC50ZXN0aW5nQGV4YW1wbGUubmV0DQo=
+ UGFzc3dvcmQ6
Zm9vYmFyMTIzDQo=
+OK logged in.
STAT
+OK 0 0
QUIT
+OK Bye-bye.

The base64 strings that you see are:

VXNlcm5hbWU6 Username:
anVzdC50ZXN0aW5nQGV4YW1wbGUubmV0DQo=   just.testing@example.net (the username)
UGFzc3dvcmQ6 Password:
Zm9vYmFyMTIzDQo= foobar123 (the password)

Here is a Thunderbird log of the same connection:

0[ef1790]: Entering NET_ProcessPop3 18
0[ef1790]: POP3: Entering state: 1
0[ef1790]: POP3: Entering state: 2
0[ef1790]: POP3: Entering state: 4
0[ef1790]: RECV: +OK Hello there.
0[ef1790]: POP3: Entering state: 29
0[ef1790]: SEND: AUTH

0[ef1790]: Entering NET_ProcessPop3 23
0[ef1790]: POP3: Entering state: 3
0[ef1790]: RECV: -ERR Invalid command.
0[ef1790]: POP3: Entering state: 30
0[ef1790]: POP3: Entering state: 31
0[ef1790]: SEND: CAPA

0[ef1790]: Entering NET_ProcessPop3 142
0[ef1790]: POP3: Entering state: 3
0[ef1790]: RECV: +OK Here's what I can do:
0[ef1790]: POP3: Entering state: 32
0[ef1790]: RECV: SASL LOGIN CRAM-MD5 CRAM-SHA1
0[ef1790]: POP3: Entering state: 32
0[ef1790]: RECV: TOP
0[ef1790]: POP3: Entering state: 32
0[ef1790]: RECV: USER
0[ef1790]: POP3: Entering state: 32
0[ef1790]: RECV: LOGIN-DELAY 10
0[ef1790]: POP3: Entering state: 32
0[ef1790]: RECV: PIPELINING
0[ef1790]: POP3: Entering state: 32
0[ef1790]: RECV: UIDL
0[ef1790]: POP3: Entering state: 32
0[ef1790]: RECV: IMPLEMENTATION Courier Mail Server
0[ef1790]: POP3: Entering state: 32
0[ef1790]: RECV: .
0[ef1790]: POP3: Entering state: 33
0[ef1790]: POP3: Entering state: 35
0[ef1790]: SEND: AUTH LOGIN

0[ef1790]: Entering NET_ProcessPop3 16
0[ef1790]: POP3: Entering state: 3
0[ef1790]: RECV: + VXNlcm5hbWU6
0[ef1790]: POP3: Entering state: 36
0[ef1790]: POP3: Entering state: 5
0[ef1790]: SEND: anVzdC50ZXN0aW5nQGV4YW1wbGUubmV0DQo=

0[ef1790]: Entering NET_ProcessPop3 16
0[ef1790]: POP3: Entering state: 3
0[ef1790]: RECV: + UGFzc3dvcmQ6
0[ef1790]: POP3: Entering state: 34
0[ef1790]: POP3: Entering state: 6
0[ef1790]: Logging suppressed for this command (it probably contained authentication information)
0[ef1790]: Entering NET_ProcessPop3 16
0[ef1790]: POP3: Entering state: 3
0[ef1790]: RECV: +OK logged in.
0[ef1790]: POP3: Entering state: 34
0[ef1790]: POP3: Entering state: 7
0[ef1790]: SEND: STAT

0[ef1790]: Entering NET_ProcessPop3 9
0[ef1790]: POP3: Entering state: 3
0[ef1790]: RECV: +OK 0 0
0[ef1790]: POP3: Entering state: 8
0[ef1790]: POP3: Entering state: 22
0[ef1790]: SEND: QUIT

0[ef1790]: Entering NET_ProcessPop3 14
0[ef1790]: POP3: Entering state: 3
0[ef1790]: RECV: +OK Bye-bye.
0[ef1790]: POP3: Entering state: 43
0[ef1790]: POP3: Entering state: 23
0[ef1790]: POP3: Entering state: 25

Rich logging using Gloda

The global database (gloda) has been enhanced to support additional logging and context information. Logsploder is a XULRunner application that supports using these features. See logsploder, circa a year+ ago for more information. This functionality isn’t useful for most users, its intended mainly to support unit testing.

See also

  • Connection errors — POP3
  • Connection errors — SMTP

External links

Wikipedia articles (including links to RFCs):

  • Post Office Protocol (POP3)
  • Internet Message Access Protocol (IMAP)
  • Simple Mail Transfer Protocol (SMTP)
  • Network News Transfer Protocol (NNTP)
  • Hypertext Transfer Protocol (HTTP)
  • Lightweight Directory Access Protocol (LDAP)

Protocol guides (they focus on the actual commands and which RFC applies to a specific protocol command):

  • Post Office Protocol (POP3)
  • Internet Message Access Protocol (IMAP)
    • List of registered CAPABILITY names for IMAP
  • Simple Mail Transfer Protocol (SMTP)
  • Network News Transfer Protocol (NNTP)
  • Hypertext Transfer Protocol (HTTP)
  • Lightweight Directory Access Protocol (LDAP)

Sometimes its useful to compare session logs for another email client and Thunderbird.

  • How to enable and interpret the Outlook Express Pop3.log File
  • How to enable and interpret the Outlook Express Smtp.log File

Additional information on how the logging works:

  • Thunderbird:Backend Hacking Guide For Newbies describes several frameworks used by Thunderbird, such as NSPR. NSPR performs the logging.
  • IMAP — MozillaWiki helps you understand the calls to various methods that are logged in the IMAP log file. It has more than just a IMAP protocol trace.
  • NSPR logging
  • Web Site Quality Assurance Testing using Mozilla describes NSPR JavaScript, Cookie and HTTP logging in release builds.
  • MozillaZine thread about complete list of protocols/modules for NSPR_LOG_MODULES

Понравилась статья? Поделить с друзьями:
  • These are his dog где ошибка
  • Thunderbird адресная книга ldap ошибка репликации
  • Thermowatt we460130007500 ошибки
  • Thunderbird ldap address book ошибка репликации
  • Thermotrans ошибка е01