hpcups crashes and core dumps

Asked by friday

Recently mine installation of hplip (3.9.12 and 3.10.2) stop working with printer p1006. Deeping in the trouble i've found hpcups crashes every time on printing. How can I get core dump of hpcups on this crashes? Usual ways doesn't give any results (i.e. ulimit in global profile, limits.conf...) with hpcups which invoked from cups.

Question information

Language:
English Edit question
Status:
Answered
For:
HPLIP Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Naga Samrat Chowdary, Narla (samrat-hplip) said :
#1

please run "hpcheck -t" and post the output.

Thanks!
Naga Samrat Chowdary, Narla

Revision history for this message
Naga Samrat Chowdary, Narla (samrat-hplip) said :
#2

i found small typo in above comment.

please run "hp-check -t" and post the output.

Thanks!
Naga Samrat Chowdary, Narla

Revision history for this message
friday (b3nder) said :
#3

Initializing. Please wait...

---------------
| SYSTEM INFO |
---------------

Basic system information:
Linux noname 2.6.32-gentoo-r7 #1 SMP Sat Mar 20 15:33:07 MSK 2010 i686 Intel(R) Pentium(R) Dual CPU E2160 @ 1.80GHz GenuineIntel GNU/Linux

Distribution:
gentoo 0.0

Checking Python version...
OK, version 2.6.4 installed

Checking PyQt 4.x version...
OK, version 4.6.2 installed.

Checking for CUPS...
Status: scheduler is running
Version: 1.4.2
error_log is set to level: info

Checking for dbus/python-dbus...
dbus daemon is running.
python-dbus version: 0.83.0

------------------------------------
| COMPILE AND RUNTIME DEPENDENCIES |
------------------------------------

note: To check for compile-time only dependencies, re-run hp-check with the -c parameter (ie, hp-check -c).
note: To check for run-time only dependencies, re-run hp-check with the -r parameter (ie, hp-check -r).

Checking for dependency: CUPS - Common Unix Printing System...
OK, found.

Checking for dependency: CUPS devel- Common Unix Printing System development files...
OK, found.

Checking for dependency: CUPS image - CUPS image development files...
OK, found.

Checking for dependency: DBus - Message bus system...
OK, found.

Checking for dependency: gcc - GNU Project C and C++ Compiler...
OK, found.

Checking for dependency: GhostScript - PostScript and PDF language interpreter and previewer...
OK, found.

Checking for dependency: libcrypto - OpenSSL cryptographic library...
OK, found.

Checking for dependency: libjpeg - JPEG library...
OK, found.

Checking for dependency: libnetsnmp-devel - SNMP networking library development files...
error: NOT FOUND! This is a REQUIRED dependency. Please make sure that this dependency is installed before installing or running HPLIP.

Checking for dependency: libpthread - POSIX threads library...
OK, found.

Checking for dependency: libtool - Library building support services...
OK, found.

Checking for dependency: libusb - USB library...
OK, found.

Checking for dependency: make - GNU make utility to maintain groups of programs...
OK, found.

Checking for dependency: PIL - Python Imaging Library (required for commandline scanning with hp-scan)...
warning: NOT FOUND! This is an OPTIONAL/RUNTIME ONLY dependency. Some HPLIP functionality may not function properly.

Checking for dependency: PolicyKit - Administrative policy framework...
OK, found.

Checking for dependency: PyQt 4 DBus - DBus Support for PyQt4...
OK, found.

Checking for dependency: Python DBus - Python bindings for DBus...
OK, found.

Checking for dependency: Python devel - Python development files...
OK, found.

Checking for dependency: Python libnotify - Python bindings for the libnotify Desktop notifications...
OK, found.

Checking for dependency: Python XML libraries...
OK, found.

Checking for dependency: Python 2.3 or greater - Required for fax functionality...
OK, found.

Checking for dependency: Python 2.2 or greater - Python programming language...
OK, found.

Checking for dependency: Reportlab - PDF library for Python...
warning: NOT FOUND! This is an OPTIONAL/RUNTIME ONLY dependency. Some HPLIP functionality may not function properly.

Checking for dependency: SANE - Scanning library...
error: NOT FOUND! This is a REQUIRED/RUNTIME ONLY dependency. Please make sure that this dependency is installed before installing or running HPLIP.

Checking for dependency: SANE - Scanning library development files...
error: NOT FOUND! This is a REQUIRED/COMPILE TIME ONLY dependency. Please make sure that this dependency is installed before installing or running HPLIP.

Checking for dependency: scanimage - Shell scanning program...
warning: NOT FOUND! This is an OPTIONAL/RUNTIME ONLY dependency. Some HPLIP functionality may not function properly.

Checking for dependency: xsane - Graphical scanner frontend for SANE...
warning: NOT FOUND! This is an OPTIONAL/RUNTIME ONLY dependency. Some HPLIP functionality may not function properly.

----------------------
| HPLIP INSTALLATION |
----------------------

Currently installed HPLIP version...
HPLIP 3.10.2 currently installed in '/usr/share/hplip'.

Current contents of '/etc/hp/hplip.conf' file:
# hplip.conf. Generated from hplip.conf.in by configure.

[hplip]
version=3.10.2

[dirs]
home=/usr/share/hplip
run=/var/run
ppd=/usr/share/ppd/HP
ppdbase=/usr/share/ppd
doc=/usr/share/doc/hplip-3.10.2
html=/usr/share/doc/hplip-3.10.2/html
icon=/usr/share/applications
cupsbackend=/usr/libexec/cups/backend
cupsfilter=/usr/libexec/cups/filter
drv=/usr/share/cups/drv/hp

# Following values are determined at configure time and cannot be changed.
[configure]
network-build=no
pp-build=no
gui-build=yes
scanner-build=no
fax-build=no
dbus-build=yes
cups11-build=no
doc-build=no
shadow-build=no
hpijs-install=no
foomatic-drv-install=no
foomatic-ppd-install=no
foomatic-rip-hplip-install=no
hpcups-install=yes
cups-drv-install=yes
cups-ppd-install=no
internal-tag=3.10.2rc1.9
restricted-build=no
ui-toolkit=qt4
qt3=no
qt4=yes
policy-kit=yes
hpijs-only-build=no
lite-build=no
udev-acl-rules=no
hpcups-only-build=no
hpijs-only-build=no

Current contents of '/var/lib/hp/hplip.state' file:
# hplip.state - HPLIP runtime persistent variables.

[plugin]
installed=0
eula=0

Current contents of '~/.hplip/hplip.conf' file:
[last_used]
working_dir = /root
device_uri = hp:/usb/HP_LaserJet_P1006?serial=AC1940S

--------------------------
| DISCOVERED USB DEVICES |
--------------------------

  Device URI Model
  -------------------------------- -----------------
  hp:/usb/HP_LaserJet_P1006?serial HP LaserJet P1006
  =AC1940S

---------------------------------
| INSTALLED CUPS PRINTER QUEUES |
---------------------------------

HP_LaserJet_P1006
-----------------
Type: Printer
Device URI: hp:/usb/HP_LaserJet_P1006?serial=AC1940S
PPD: /etc/cups/ppd/HP_LaserJet_P1006.ppd
PPD Description: HP LaserJet p1006, hpcups 3.9.10
Printer status: printer HP_LaserJet_P1006 is idle. enabled since Вск 21 Мар 2010 16:49:ready to print
error: Required plug-in status: Not installed
Communication status: Good

---------------------
| PYTHON EXTENSIONS |
---------------------

Checking 'cupsext' CUPS extension...
OK, found.

Checking 'pcardext' Photocard extension...
OK, found.

Checking 'hpmudext' I/O extension...
OK, found.

-----------------
| USB I/O SETUP |
-----------------

Checking for permissions of USB attached printers...

HP Device 0x3e17 at 008:007:
    Device URI: hp:/usb/HP_LaserJet_P1006?serial=AC1940S
    Device node: /dev/bus/usb/008/007
    Mode: 0660
getfacl: Removing leading '/' from absolute path names
# file: dev/bus/usb/008/007
# owner: root
# group: lp
user::rw-
group::rw-
other::---

---------------
| USER GROUPS |
---------------

root bin daemon sys adm disk wheel floppy audio cdrom tape cal login home httpd cdrw source vboxusers

-----------
| SUMMARY |
-----------

error: 8 errors and/or warnings.

Revision history for this message
Naga Samrat Chowdary, Narla (samrat-hplip) said :
#4

change the following entries in file /etc/cups/cupsd.conf from
change "LogLevel warn"
to
#hpLogLevel 15
LogLevel debug

remove file /var/log/cups/error_log

and restart cups (sudo /etc/init.c/cups restart)

Please give printout to your printer. if hpcups crashes, please attach /var/log/cups/error_log messages.

this link has more details about how to enable core dump http://www.dedoimedo.com/computers/www.dedoimedo.com-lkcd-tutorial-lm.pdf

Thanks!
Naga Samrat Chowdary, Narla

Revision history for this message
Naga Samrat Chowdary, Narla (samrat-hplip) said :
#5

i hope you set "ulimit -c unlimited"
Following link will give you how to enable core dump at application level
http://www.akadia.com/services/ora_enable_core.html

Thanks,
Naga Samrat Chowdary, Narla

Revision history for this message
friday (b3nder) said :
#6

Thank you for help. I've already tried standard technique for cores, but it doesn't work especially for hpcups. Ok, this is the bt for mine hpcups on working environment. Do you have any idea why this happens?

Program received signal SIGSEGV, Segmentation fault.
0x0804f727 in ModeJbig::compress (this=0x81c9b80, plane_number=0) at prnt/hpcups
/ModeJbig.cpp:332
(gdb) bt
#0 0x0804f727 in ModeJbig::compress (this=0x81c9b80, plane_number=0) at prnt/hp
cups/ModeJbig.cpp:332
#1 0x0804f920 in ModeJbig::processZXStream (this=0x81c9b80, input=0x81c9b94) at
 prnt/hpcups/ModeJbig.cpp:258
#2 0x0804fa2c in ModeJbig::Process (this=0x81c9b80, input=0xb762d380) at prnt/h
pcups/ModeJbig.cpp:207
#3 0x0805c130 in Pipeline::Execute (this=0x81ce9d0, InputRaster=0x81c9b94) at p
rnt/hpcups/Pipeline.cpp:79
#4 0x0805c17e in Pipeline::Execute (this=0x81d24a0, InputRaster=0x81c9684) at p
rnt/hpcups/Pipeline.cpp:83
#5 0x0805c17e in Pipeline::Execute (this=0x81d2488, InputRaster=0x81ce6f4) at p
rnt/hpcups/Pipeline.cpp:83
#6 0x0804bc20 in HPCupsFilter::processRasterData (this=0x80a1840, cups_raster=0
x81c7ca0) at prnt/hpcups/HPCupsFilter.cpp:639
#7 0x0804c271 in HPCupsFilter::StartPrintJob (this=0x80a1840, argc=6, argv=0xbf
b9d504) at prnt/hpcups/HPCupsFilter.cpp:516
#8 0x0804c5ec in main (argc=6, argv=0xbfb9d504) at prnt/hpcups/HPCupsFilter.cpp
:53

Revision history for this message
friday (b3nder) said :
#7

properly formatted output, hplip-3.10.2

Program received signal SIGSEGV, Segmentation fault.
0x0804f727 in ModeJbig::compress (this=0x81c9b80, plane_number=0) at prnt/hpcups/ModeJbig.cpp:332
(gdb) bt
#0 0x0804f727 in ModeJbig::compress (this=0x81c9b80, plane_number=0) at prnt/hpcups/ModeJbig.cpp:332
#1 0x0804f920 in ModeJbig::processZXStream (this=0x81c9b80, input=0x81c9b94) at prnt/hpcups/ModeJbig.cpp:258
#2 0x0804fa2c in ModeJbig::Process (this=0x81c9b80, input=0xb762d380) at prnt/hpcups/ModeJbig.cpp:207
#3 0x0805c130 in Pipeline::Execute (this=0x81ce9d0, InputRaster=0x81c9b94) at prnt/hpcups/Pipeline.cpp:79
#4 0x0805c17e in Pipeline::Execute (this=0x81d24a0, InputRaster=0x81c9684) at prnt/hpcups/Pipeline.cpp:83
#5 0x0805c17e in Pipeline::Execute (this=0x81d2488, InputRaster=0x81ce6f4) at prnt/hpcups/Pipeline.cpp:83
#6 0x0804bc20 in HPCupsFilter::processRasterData (this=0x80a1840, cups_raster=0x81c7ca0) at prnt/hpcups/HPCupsFilter.cpp:639
#7 0x0804c271 in HPCupsFilter::StartPrintJob (this=0x80a1840, argc=6, argv=0xbfb9d504) at prnt/hpcups/HPCupsFilter.cpp:516
#8 0x0804c5ec in main (argc=6, argv=0xbfb9d504) at prnt/hpcups/HPCupsFilter.cpp:53

Revision history for this message
Launchpad Janitor (janitor) said :
#8

This question was expired because it remained in the 'Open' state without activity for the last 15 days.

Revision history for this message
Arkadiusz Miśkiewicz (arekm) said :
#9

I'm getting similar thing with hplip 3.11.10:

==2149== Command: /usr/lib/cups/filter/hpcups 214207 root Test\ Page 1 job-uuid=urn:uuid:76ac3927-77ef-37a7-614f-b04d748545d9\ job-originating-host-name=localhost\ time-at-creation=1322658916\ time-at-processing=1322663327\ AP_D_InputSlot=
==2149==
PAGE: 1 1==2149== Invalid write of size 4
==2149== at 0x804EE07: ModeJbig::compress(int) (ModeJbig.cpp:342)
==2149== by 0x804F034: ModeJbig::processZJStream(RASTERDATA*) (ModeJbig.cpp:244)
==2149== by 0x804F0C1: ModeJbig::Process(RASTERDATA*) (ModeJbig.cpp:208)
==2149== by 0x805A911: Pipeline::Execute(RASTERDATA*) (Pipeline.cpp:72)
==2149== by 0x805A962: Pipeline::Execute(RASTERDATA*) (Pipeline.cpp:83)
==2149== by 0x805A962: Pipeline::Execute(RASTERDATA*) (Pipeline.cpp:83)
==2149== by 0x804B8ED: HPCupsFilter::processRasterData(_cups_raster_s*) (HPCupsFilter.cpp:657)
==2149== by 0x804C035: HPCupsFilter::StartPrintJob(int, char**) (HPCupsFilter.cpp:519)
==2149== by 0x8049569: main (HPCupsFilter.cpp:52)
==2149== Address 0x38 is not stack'd, malloc'd or (recently) free'd
==2149==
==2149==
==2149== Process terminating with default action of signal 11 (SIGSEGV)
==2149== Access not within mapped region at address 0x38
==2149== at 0x804EE07: ModeJbig::compress(int) (ModeJbig.cpp:342)
==2149== by 0x804F034: ModeJbig::processZJStream(RASTERDATA*) (ModeJbig.cpp:244)
==2149== by 0x804F0C1: ModeJbig::Process(RASTERDATA*) (ModeJbig.cpp:208)
==2149== by 0x805A911: Pipeline::Execute(RASTERDATA*) (Pipeline.cpp:72)
==2149== by 0x805A962: Pipeline::Execute(RASTERDATA*) (Pipeline.cpp:83)
==2149== by 0x805A962: Pipeline::Execute(RASTERDATA*) (Pipeline.cpp:83)
==2149== by 0x804B8ED: HPCupsFilter::processRasterData(_cups_raster_s*) (HPCupsFilter.cpp:657)
==2149== by 0x804C035: HPCupsFilter::StartPrintJob(int, char**) (HPCupsFilter.cpp:519)
==2149== by 0x8049569: main (HPCupsFilter.cpp:52)
==2149== If you believe this happened as a result of a stack
==2149== overflow in your program's main thread (unlikely but
==2149== possible), you can try to increase the size of the
==2149== main thread stack using the --main-stacksize= flag.
==2149== The main thread stack size used in this run was 8388608.

Revision history for this message
Arkadiusz Miśkiewicz (arekm) said :
#10

Looks like binary plugin is bahaving badly:

ModeJbig::compress calls:

    HPLJJBGCompress (m_iWidth * 8 * m_iBPP, m_iLastRaster, &p, &myBuffer, &se);

where:

*(void **) (&HPLJJBGCompress) = dlsym (m_hHPLibHandle, "hp_encode_bits_to_jbig");

and

$ objdump -T lj-x86_32.so |grep hp_encode_bits_to_jbig
00000bd4 g DF .text 000000fe hp_encode_bits_to_jbig

Revision history for this message
Sarbeswar Meher (sarbeswar-meher) said :
#11

Please download the latest hplip-3.11.10 from http://hplipopensource.com/hplip-web/install/manual/distros/gentoo.html and follow the instructions of installation. Connect the printer via USB and run "hp-setup" in terminal. It will ask for a plugin file to download. Once setup is done, you can print.

If you still face any issue, get back to us.

Revision history for this message
Sarbeswar Meher (sarbeswar-meher) said :
#12

Please follow the installation steps in http://hplipopensource.com/hplip-web/install/manual/distros/gentoo.html and Connec the printer and run "hp-setup" to install a plugin file.

Revision history for this message
Arkadiusz Miśkiewicz (arekm) said :
#13

@Sarbeswar: this is caused by "Bug #666780: hplip-3.{9,10}, blob lj-x86_32.so dynamically resolves its "statically" linked symbols". Verified that - patching binary plugin fixed the issue (and I was already using 3.11.10).

Can you help with this problem?

Provide an answer of your own, or ask friday for more information if necessary.

To post a message you must log in.