haiku/docs/welcome/zh_CN/bugreports.html
Joachim Seemer 834e58f9b7 Update of user guide and welcome page and their translations.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@38032 a95241bf-73f2-0310-859d-f6bbb57e9c96
2010-08-11 17:56:45 +00:00

172 lines
17 KiB
HTML
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US" xml:lang="en-US">
<head>
<!--
*
* Copyright 2008-2010, Haiku. All rights reserved.
* Distributed under the terms of the MIT License.
*
* Authors:
* Niels Reedijk, Matt Madia and Ingo Weinhold who wrote
* http://dev.haiku-os.org/wiki/ and http://dev.haiku-os.org/wiki/ReportingBugs
* Humdinger <humdingerb@gmail.com>
* Translators:
* Pengphei Han
*
-->
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<meta name="robots" content="all" />
<title>报告错误</title>
<link rel="stylesheet" type="text/css" href="../Haiku-doc.css" />
</head>
<body>
<div id="banner">
<div><span>User guide</span></div>
</div>
<div class="nav">
<div class="inner">
<ul class="lang-menu">
<li class="now"><img src="../images/flags/zh_CN.png" alt="" />  中文 [中文]</li>
<li><a href="../fr/bugreports.html"><img src="../images/flags/fr.png" alt="" />Français</a></li>
<li><a href="../de/bugreports.html"><img src="../images/flags/de.png" alt="" />Deutsch</a></li>
<li><a href="../it/bugreports.html"><img src="../images/flags/it.png" alt="" />Italiano</a></li>
<li><a href="../ru/bugreports.html"><img src="../images/flags/ru.png" alt="" />Русский</a></li>
<li><a href="../es/bugreports.html"><img src="../images/flags/es.png" alt="" />Español</a></li>
<li><a href="../sv_SE/bugreports.html"><img src="../images/flags/sv_SE.png" alt="" />Svensk</a></li>
<li><a href="../jp/bugreports.html"><img src="../images/flags/jp.png" alt="" />日本語</a></li>
<li><a href="../uk/bugreports.html"><img src="../images/flags/uk.png" alt="" />Українська</a></li>
<li><a href="../pt_PT/bugreports.html"><img src="../images/flags/pt_PT.png" alt="" />Português</a></li>
<li><a href="../en/bugreports.html"><img src="../images/flags/gb.png" alt="" />English</a></li>
</ul>
<span>
<a href="../welcome_zh_CN.html" class="uplink">Welcome</a>
</span></div>
</div>
<div id="content">
<div>
<div class="box-info">The translation of this page isn't yet complete. Until it is, unfinished parts use the English original.</div>
<table class="index" id="index" summary="index">
<tr class="heading"><td>报告错误</td></tr>
<tr class="index"><td><a href="#account">Getting a Trac account</a><br />
<a href="#report">Creating a bug report</a><br />
<a href="#app">Application bugs</a><br />
<a href="#server">Server bugs</a><br />
<a href="#kernel">Kernel bugs</a><br />
<a href="#kdl">Kernel Debugging Land - KDL</a><br />
<a href="#syslog">Syslog</a><br />
<a href="#onscreen">On screen debug output</a><br />
<a href="#hardware">Hardware/Driver bugs</a><br />
<a href="#next">What's next?</a></td></tr>
</table>
<h1>报告错误</h1>
<p>由于我们的开发人员不可能测试每种硬件组合和每种不同的系统交互方式所以我们依赖于用户通过用户来给予我们Haiku的运行情况。由于Haiku还很年轻您在使用时很有可能会遇到错误。我们非常感谢您能够分出时间来提交这些错误报告。我们可以共同的一位一位的提高Haiku的性能。</p>
<p>为了确保我们的错误跟踪系统的有效性,遵守共同的<a href="http://dev.haiku-os.org/wiki/BugTrackerEtiquette">错误报告规范</a>是很有必要的。</p>
<h2><a href="#"><img src="../images/up.png" style="border:none;float:right" alt="index" /></a>
<a id="account" name="accout">Getting a Trac account</a></h2>
<p>为了提交任务单,您需要在<a href="http://dev.haiku-os.org/register" title="Register at Haiku's Bugtracker">Haiku的错误跟踪系统</a>中注册一个账户。
<br />
在新建账户时,你需要<b>提供自己的电子邮箱</b> ,否则您将不具有基本的任务单修改权限。之后,您一定要保证<b>检查您的垃圾邮件文件夹</b>,因为所有重要的验证邮件都会被发送到那儿去。</p>
<h2><a href="#"><img src="../images/up.png" style="border:none;float:right" alt="index" /></a>
<a id="report" name="report">Creating a bug report</a></h2>
<p>在报告一个错误之前,请您<a href="http://dev.haiku-os.org/query?status=new&amp;status=assigned&amp;status=reopened&amp;status=closed&amp;summary=%7Etext+you+want+to+search+for&amp;order=priority">确保</a>该错误报告之前不存在。你可以使用<a href="http://dev.haiku-os.org/search?q=&amp;noquickjump=1&amp;ticket=on">查找</a>功能来查找其是否存在。
<br />
在确定它是一个独特的错误之后,您需要尽可能的找出有关的详细信息:</p>
<ul>
<li><p>Attempt to reproduce your issue on the current revision of Haiku. Pre-built images for testing purposes are  <a href="http://haiku-files.org/">available</a>.</p></li>
<li><p>包括基本的信息例如以何种方式测试Haiku利用真实的硬件VMware还是QEMU</p></li>
<li><p>Mention which revision from <acronym title="Subversion, the source code management system we use">SVN</acronym> you are running. You can find this information in <span class="menu">About Haiku...</span> from the Deskbar menu. Also mention what kind of Haiku build you are testing (gcc2, gcc4, gcc2hybrid, gcc4hybrid). The downloadable images are named accordingly, for a self-built image you should know how you built it.</p></li>
<li><p>描述您所遇到的问题。尽量把问题讲得精确和明白:描述详细的系统行为反馈,和您期望的反馈。</p></li>
<li><p>描述暴露该错误所需要的操作步骤。这将会有助于开发者重现该错误,并对其进行修复和完善。</p></li>
<li><p>Attach as much information as you have. If it is a GUI bug, or a bug in one of the applications, try to take a screenshot by pressing the <span class="key">PRINT</span> key.</p></li>
</ul>
<h2><a href="#"><img src="../images/up.png" style="border:none;float:right" alt="index" /></a>
<a id="app" name="app">Application bugs</a></h2>
<p>When an application crashed, you should invoke the debugger from the alert that pops up. This will open a Terminal window with gdb (the GNU debugger) running in it. Entering <span class="cli">bt</span>, you create a "backtrace" that you should copy in its entirety (including the part before you entered the <span class="cli">bt</span> command) and attach it to the ticket.</p>
<h2><a href="#"><img src="../images/up.png" style="border:none;float:right" alt="index" /></a>
<a id="server" name="server">Server bugs</a></h2>
<p>When vital servers like the app server, the registrar or the input server crash, you won't see the usual crash alert. Instead the whole screen will be cleared white and a gdb session will be started, its output appearing directly on screen. Likely you will still be able to move the mouse, which will overwrite the white and gdb output on screen. Applications still running (like ProcessController or the clock in the Deskbar) might also draw over the debugger output on screen.<br />
Besides everything being more ugly and inconvenient, basically the same applies as for application bugs. Most importantly procure a back trace (<span class="cli">bt</span> command). You may need to take a picture of the screen with a digital camera, since you won't be able to copy the text anywhere.</p>
<h2><a href="#"><img src="../images/up.png" style="border:none;float:right" alt="index" /></a>
<a id="kernel" name="kernel">Kernel bugs</a></h2>
<p>Kernel bugs are usual the ones with the most severe effects while at the same time being the hardest to debug. There are different kinds of symptoms, which most likely point to a kernel or driver issue:</p>
<ul>
<li><p>The system enters kernel debugging land (KDL) on its own volition. The upper part of the screen is cleared white and several lines of text are printed on it. The second line says "<i>Welcome to Kernel Debugging Land...</i>", the one above it states the immediate reason for entering KDL.</p></li>
<li><p>The system reboots spontaneously.</p></li>
<li><p>The system freezes completely. You can't move the mouse and no application draws anything anymore. An important test in that situation is, whether you still can enter KDL via the shortcut <span class="key">ALT</span> <span class="key">SysReq</span> <span class="key">D</span> (<span class="key">SysReq</span> being <span class="key">PRINT</span> on most keyboards). Wait at least a minute to see, if anything happens.</p></li>
<li><p>The system doesn't boot up correctly. It may reboot spontaneously or stop at some point (e.g. at some icon of the boot screen). In the latter case also try <span class="key">ALT</span> <span class="key">SysReq</span> <span class="key">D</span>.</p></li>
<li><p>The whole system or some piece of hardware doesn't behave correctly. For example, it could be very slow, errors occur, or something doesn't work at all. If some hardware doesn't work at all, the first obvious check is whether Haiku supports it at all at the moment (e.g. ask on a mailing list or a forum).</p></li>
</ul>
<p>Note that while only the last point seems to indicate hardware relation, all the other symptoms could be caused by a bug in a hardware driver as well. If you have a suspicion what piece of hardware or corresponding driver might have to do with the problem, check whether removing/disabling the hardware or the driver makes a difference. For example, if you suspect Wifi you may find that your BIOS has an option to disable it. Or if not, you could remove the responsible Wifi driver from your Haiku installation (in <span class="path">/boot/system/add-ons/kernel/drivers/bin</span>).</p>
<h3><a href="#"><img src="../images/up.png" style="border:none;float:right" alt="index" /></a>
<a id="kdl" name="kdl">Kernel Debugging Land - KDL</a></h3>
<p>If the system hasn't entered KDL by itself, you can do that intentionally by invoking the keyboard shortcut <span class="key">ALT</span> <span class="key">SysReq</span> <span class="key">D</span>.<br />
Note that in KDL your keyboard may not work. PS/2 keyboards always do, USB keyboards connected via UHCI controllers do only, if one has entered KDL via the keyboard shortcut at least once. USB OHCI is not supported at the moment.</p>
<p>KDL itself is a kind of a shell. One can execute commands that print information about the system. The following commands might be of interest:</p>
<table summary="layout" border="0" cellpadding="2" cellspacing="0">
<tr><td><span class="cli">bt</span> (aka sc)</td><td> </td><td>Prints a back trace. If the system entered KDL on its on volition, always enter that one.</td></tr>
<tr><td><span class="cli">ints</span></td><td> </td><td>Shows the handled and unhandled hardware interrupts.</td></tr>
<tr><td class="onelinetop"><span class="cli">co</span> (aka continue)</td><td> </td><td>Leaves the kernel debugger and continues normal operation of the system, if that is possible.</td></tr>
<tr><td><span class="cli">reboot</span></td><td> </td><td>Reboots the system immediately. You will lose all unsaved data and even those that have been saved, but have not yet been written back to disk.</td></tr>
</table>
<p>For more information, see the article <a href="http://www.haiku-os.org/documents/dev/welcome_to_kernel_debugging_land">Welcome to Kernel Debugging Land</a>.</p>
<p>The KDL output is written to the serial port (if you have one, a respective cable, and a second computer to connect with, you can capture the output there via a terminal program) and to the syslog. If you can't leave KDL it won't be written to the syslog file, though. There's a boot loader debug option that allows you to capture it nonetheless (see below).</p>
<h3><a href="#"><img src="../images/up.png" style="border:none;float:right" alt="index" /></a>
<a id="syslog" name="syslog">Syslog</a></h3>
<p><b>This is the preferred method for gaining information from a non-booting system.</b><br />
The syslog (short for system log) contains valuable information about what has happened in your system, including the output of KDL sessions. It's usually a good idea to attach it to the kernel related Trac ticket. The syslog is written to the file <span class="path">/boot/common/var/log/syslog</span>. Since writing to a file requires a working system, the most recent output might not have made it to the syslog when a kernel problem occurs (particularly on spontaneous reboots or uncontinuable KDL sessions).</p>
<p>The option <span class="menu">Enable debug syslog</span> in the boot loader's <span class="menu">Debug menu</span> makes the syslog somewhat persistent in memory. By default the option is enabled. "Somewhat persistent" means that it survives a reset and will still be accessible when you enter the boot loader menu directly afterwards. Booting an operating system (Haiku definitely, others likely) destroys the information, though. So you have to enter the boot loader menu by holding down <span class="key">SHIFT</span> while booting.<br />
In the boot loader's <span class="menu">Debug menu</span> you should now find the entries <span class="menu">Display syslog from previous session</span> and <span class="menu">Save syslog from previous session</span>. The former displays the syslog on screen, the latter allows you to save it as a file to disk. Note that at the moment only FAT32 volumes are supported for saving the file. If you want to use a USB stick, but have plugged it in too late so that it isn't recognized yet, you can reset the machine and re-enter the boot loader menu. But again: Don't accidentally boot any operating system or the data will be lost.</p>
<h3><a href="#"><img src="../images/up.png" style="border:none;float:right" alt="index" /></a>
<a id="onscreen" name="onscreen">On screen debug output</a></h3>
<p><b>The on-screen debug output is useful only for debugging very specific issues and is known to have (timing) issues. Don't use it, if you don't have to.</b><br />
This is only relevant when Haiku fails to boot on your machine and the <span class="menu">Debug syslog option</span> doesn't work for some reason. Before the Haiku boot logo appears, hold <span class="key">SHIFT</span> to enter the boot loader menu. Select <span class="menu">Select safe mode options</span>. Near the bottom, <span class="menu">[ ] Enable on screen debug output</span> will be listed. (Note: The other options could be enabled in an attempt to boot Haiku. If Haiku will boot only when one or more options are activated, be sure to mention which ones.)<br />
Finally select <span class="menu">Return to main menu</span> and then <span class="menu">Continue booting</span>.<br />
One or more pages of text will display on the screen, only the last few lines need to be included on your ticket. There's more information on the <a href="../../../userguide/zh_CN/bootloader.html">Boot Loader</a>.</p>
<h2><a href="#"><img src="../images/up.png" style="border:none;float:right" alt="index" /></a>
<a id="hardware" name="hardware">Hardware/Driver bugs</a></h2>
<p>When dealing with a hardware/driver related bug, you should attach the following information as text files:</p>
<table summary="layout" border="0" cellpadding="2" cellspacing="0">
<tr><td>- <span class="cli">listdev</span></td><td> </td><td>A detailed listing of your hardware, including vendor and pci id's, similar to Linux' <span class="cli">lshw</span> and <span class="cli">lspci</span>.</td></tr>
<tr><td>- <span class="cli">listusb -v</span></td><td> </td><td>Assuming its a USB related issue, similar to <span class="cli">lsusb</span>.</td></tr>
<tr><td>- <span class="cli">open /var/log/syslog</span></td><td> </td><td>The primary system log used by Haiku, akin to on screen debugging during boot. With the <span class="cli">open</span> command you can crop down the relevant part of the syslog in a text editor.</td></tr>
<tr><td class="onelinetop">- <span class="cli">listimage | grep drivers/</span></td><td> </td><td>Lists all used drivers.</td></tr>
<tr><td>- <span class="cli">ints</span></td><td> </td><td>Only available within <i>Kernel Debugging Land</i> (see above). Shows interrupt usage. There shouldn't be too many that are shared by different devices.</td></tr>
<tr><td colspan="3">- On screen debug output (a safe mode boot time option).</td></tr>
</table>
<p>The first four commands are entered into Terminal. Add a <span class="cli"> &gt; output.txt</span> after a command, and it's piped into a text file called "output.txt" that you can attach to your bug report or email.</p>
<h2><a href="#"><img src="../images/up.png" style="border:none;float:right" alt="index" /></a>
<a id="next" name="next">What's next?</a></h2>
<p>在您提交了错误报告之后,开发人员将会检查您的错误,然后尝试进行修复。但是需要注意的是,我们所有的人员都是志愿者,有时候一个错误报告可能会很长时间没有人来进行回答。如果可以的话,添加新的信息将会有助于早点修复错误,但是请不要添加非描述性的评论来将“炒热”该错误。</p>
<p>切记提交错误报告不是花些很少的时间写个报告的事。如果您提交了一个错误然后您属于Haiku开发过程中的一部分。开发人员在解决您的错误过程中可能会遇到问题因此请你一定要始终关注该错误然后回答相关的问题。如果该问题没有“fixed”你的任务就没有“done”。</p>
</div>
</div>
<div class="nav">
<div class="inner"><span>
<a href="../welcome_zh_CN.html" class="uplink">Welcome</a>
</span></div>
</div>
</body>
</html>