OnWorks Linux and Windows Online WorkStations

Logo

Free Hosting Online for WorkStations

< Previous | Contents | Next >

1.1. Reporting Bugs With apport-cli


The preferred way to report a bug is with the apport-cli command. It must be invoked on the machine affected by the bug because it collects information from the system on which it is being run and publishes it to the bug report on Launchpad. Getting that information to Launchpad can therefore be a challenge if the system is not running a desktop environment in order to use a browser (common with servers) or if it does not have Internet access. The steps to take in these situations are described below.


image

The commands apport-cli and ubuntu-bug should give the same results on a CLI server. The latter is actually a symlink to apport-bug which is intelligent enough to know whether a desktop environment is in use and will choose apport-cli if not. Since server systems tend to be CLI-only apport-cli was chosen from the outset in this guide.


Bug reports in Ubuntu need to be filed against a specific software package, so the name of the package (source package or program name/path) affected by the bug needs to be supplied to apport-cli:


apport-cli PACKAGENAME


image

See Chapter 3, Package Management [p. 27] for more information about packages in Ubuntu.


Once apport-cli has finished gathering information you will be asked what to do with it. For instance, to report a bug in vim:


apport-cli vim


*** Collecting problem information


The collected information can be sent to the developers to improve the application. This might take a few minutes.

...


*** Send problem report to the developers?


After the problem report has been sent, please fill out the form in the automatically opened web browser.


What would you like to do? Your options are: S: Send report (2.8 KB)


image

1 https://launchpad.net/

2 https://help.launchpad.net/YourAccount/NewAccount


V: View report

K: Keep report file for sending later or copying to somewhere else I: Cancel and ignore future crashes of this program version

C: Cancel

Please choose (S/V/K/I/C):


The first three options are described below:


Send: submits the collected information to Launchpad as part of the process of filing a new bug report. You will be given the opportunity to describe the bug in your own words.


*** Uploading problem information


The collected information is being sent to the bug tracking system. This might take a few minutes.

94%


*** To continue, you must visit the following URL:


https://bugs.launchpad.net/ubuntu/+source/vim/+filebug/09b2495a- e2ab-11e3-879b-68b5996a96c8?


You can launch a browser now, or copy this URL into a browser on another computer.


Choices:

1: Launch a browser now C: Cancel

Please choose (1/C): 1


The browser that will be used when choosing '1' will be the one known on the system as www-browser via the Debian alternatives system3. Examples of text-based browsers to install include links, elinks, lynx, and w3m. You can also manually point an existing browser at the given URL.

View: displays the collected information on the screen for review. This can be a lot of information. Press 'Enter' to scroll by screenful. Press 'q' to quit and return to the choice menu.

Keep: writes the collected information to disk. The resulting file can be later used to file the bug report, typically after transferring it to another Ubuntu system.


What would you like to do? Your options are: S: Send report (2.8 KB)

V: View report

K: Keep report file for sending later or copying to somewhere else I: Cancel and ignore future crashes of this program version

C: Cancel

Please choose (S/V/K/I/C): k

Problem report file: /tmp/apport.vim.1pg92p02.apport


image

3 http://manpages.ubuntu.com/manpages/en/man8/update-alternatives.8.html


To report the bug, get the file onto an internet-enabled Ubuntu system and apply apport-cli to it. This will cause the menu to appear immediately (the information is already collected). You should then press 's' to send:


apport-cli apport.vim.1pg92p02.apport


To directly save a report to disk (without menus) you can do:


apport-cli vim --save apport.vim.test.apport


Report names should end in .apport .


image

If this internet-enabled system is non-Ubuntu/Debian, apport-cli is not available so the bug will need to be created manually. An apport report is also not to be included as an attachment to a bug either so it is completely useless in this scenario.


Top OS Cloud Computing at OnWorks: