Manjaro XFCE Edition
   333

[Решено] Не печатает принтер (win smb)

Добрый день, после одного из обновлений сломалась печать по smb (видимо обновился smbclient). в логах cups пишется что backend вызывается не с теми параметрами.
Помогите починить…

Вот выдержка из /var/log/cups/error_log.
D [29/May/2018:16:16:30 +0500] Print-Job ipp://localhost/printers/P2055-Expert
D [29/May/2018:16:16:30 +0500] [Job ???] Auto-typing file…
I [29/May/2018:16:16:30 +0500] [Job ???] Request file type is application/vnd.cups-pdf-banner.
D [29/May/2018:16:16:30 +0500] cupsdMarkDirty(---J-)
D [29/May/2018:16:16:30 +0500] cupsdSetBusyState: newbusy=«Active clients and dirty files», busy=«Active clients and dirty files»
D [29/May/2018:16:16:30 +0500] [Job 346] Applying default options…
D [29/May/2018:16:16:30 +0500] [Job 346] Adding default job-cancel-after=10800
D [29/May/2018:16:16:30 +0500] [Job 346] Adding default media=13
D [29/May/2018:16:16:30 +0500] [Job 346] Adding default output-bin=0
D [29/May/2018:16:16:30 +0500] [Job 346] Adding default print-color-mode=color
D [29/May/2018:16:16:30 +0500] [Job 346] Adding default print-quality=4
D [29/May/2018:16:16:30 +0500] add_job: requesting-user-name=«my_username»
D [29/May/2018:16:16:30 +0500] Adding default job-sheets values «none,none»…
I [29/May/2018:16:16:30 +0500] [Job 346] Adding start banner page «none».
D [29/May/2018:16:16:30 +0500] Discarding unused job-created event…
D [29/May/2018:16:16:30 +0500] cupsdMarkDirty(---J-)
D [29/May/2018:16:16:30 +0500] cupsdSetBusyState: newbusy=«Active clients and dirty files», busy=«Active clients and dirty files»
I [29/May/2018:16:16:30 +0500] [Job 346] Adding end banner page «none».
I [29/May/2018:16:16:30 +0500] [Job 346] File of type application/vnd.cups-pdf-banner queued by «my_username».
D [29/May/2018:16:16:30 +0500] [Job 346] hold_until=0
I [29/May/2018:16:16:30 +0500] [Job 346] Queued on «P2055-Expert» by «my_username».
D [29/May/2018:16:16:30 +0500] [Job 346] time-at-processing=1527592590
D [29/May/2018:16:16:30 +0500] cupsdMarkDirty(---J-)
D [29/May/2018:16:16:30 +0500] cupsdSetBusyState: newbusy=«Active clients and dirty files», busy=«Active clients and dirty files»
D [29/May/2018:16:16:30 +0500] cupsdSetBusyState: newbusy=«Active clients and dirty files», busy=«Active clients and dirty files»
D [29/May/2018:16:16:30 +0500] cupsdMarkDirty(----S)
D [29/May/2018:16:16:30 +0500] cupsdSetBusyState: newbusy=«Active clients and dirty files», busy=«Active clients and dirty files»
D [29/May/2018:16:16:30 +0500] [Job 346] 4 filters for job:
D [29/May/2018:16:16:30 +0500] [Job 346] bannertopdf (application/vnd.cups-pdf-banner to application/pdf, cost 32)
D [29/May/2018:16:16:30 +0500] [Job 346] pdftopdf (application/pdf to application/vnd.cups-pdf, cost 66)
D [29/May/2018:16:16:30 +0500] [Job 346] gstoraster (application/vnd.cups-pdf to application/vnd.cups-raster, cost 99)
D [29/May/2018:16:16:30 +0500] [Job 346] hpcups (application/vnd.cups-raster to printer/P2055-Expert, cost 0)
D [29/May/2018:16:16:30 +0500] [Job 346] job-sheets=none,none
D [29/May/2018:16:16:30 +0500] [Job 346] argv[0]=«P2055-Expert»
D [29/May/2018:16:16:30 +0500] [Job 346] argv[1]=«346»
D [29/May/2018:16:16:30 +0500] [Job 346] argv[2]=«my_username»
D [29/May/2018:16:16:30 +0500] [Job 346] argv[3]=«Test Page»
D [29/May/2018:16:16:30 +0500] [Job 346] argv[4]=«1»
D [29/May/2018:16:16:30 +0500] [Job 346] argv[5]=«job-uuid=urn:uuid:812813e2-271b-3668-6dc4-c22fb6ce22b7 media=13 output-bin=0 print-color-mode=color print-quality=4 job-originating-host-name=localhost date-time-at-creation= date-time-at-processing= time-at-creation=1527592590 time-at-processing=1527592590 cupsPrintQuality=Normal»
D [29/May/2018:16:16:30 +0500] [Job 346] argv[6]="/var/spool/cups/d00346-001"
D [29/May/2018:16:16:30 +0500] [Job 346] envp[0]=«CUPS_CACHEDIR=/var/cache/cups»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[1]=«CUPS_DATADIR=/usr/share/cups»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[2]=«CUPS_DOCROOT=/usr/share/cups/doc»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[3]=«CUPS_FONTPATH=/usr/share/cups/fonts»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[4]=«CUPS_REQUESTROOT=/var/spool/cups»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[5]=«CUPS_SERVERBIN=/usr/lib/cups»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[6]=«CUPS_SERVERROOT=/etc/cups»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[7]=«CUPS_STATEDIR=/run/cups»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[8]=«HOME=/var/spool/cups/tmp»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[9]=«PATH=/usr/lib/cups/filter:/usr/bin:/usr/bin:/bin:/usr/bin»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[10]=«SERVER_ADMIN=root@my_hostname»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[11]=«SOFTWARE=CUPS/2.2.7»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[12]=«TMPDIR=/var/spool/cups/tmp»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[13]=«USER=root»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[14]=«CUPS_MAX_MESSAGE=2047»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[15]=«CUPS_SERVER=/run/cups/cups.sock»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[16]=«CUPS_ENCRYPTION=IfRequested»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[17]=«IPP_PORT=631»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[18]=«CHARSET=utf-8»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[19]=«LANG=ru_RU.UTF-8»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[20]=«PPD=/etc/cups/ppd/P2055-Expert.ppd»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[21]=«RIP_MAX_CACHE=128m»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[22]=«CONTENT_TYPE=application/vnd.cups-pdf-banner»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[23]=«DEVICE_URI=smb://expert/hplaserj»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[24]=«PRINTER_INFO=hplj2055»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[25]=«PRINTER_LOCATION=»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[26]=«PRINTER=P2055-Expert»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[27]=«PRINTER_STATE_REASONS=none»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[28]=«CUPS_FILETYPE=document»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[29]=«FINAL_CONTENT_TYPE=application/vnd.cups-raster»
D [29/May/2018:16:16:30 +0500] [Job 346] envp[30]=«AUTH_I****»
I [29/May/2018:16:16:30 +0500] [Job 346] Started filter /usr/lib/cups/filter/bannertopdf (PID 20713)
I [29/May/2018:16:16:30 +0500] [Job 346] Started filter /usr/lib/cups/filter/pdftopdf (PID 20714)
I [29/May/2018:16:16:30 +0500] [Job 346] Started filter /usr/lib/cups/filter/gstoraster (PID 20715)
I [29/May/2018:16:16:30 +0500] [Job 346] Started filter /usr/lib/cups/filter/hpcups (PID 20716)
I [29/May/2018:16:16:30 +0500] [Job 346] Started backend /usr/lib/cups/backend/smb (PID 20717)
D [29/May/2018:16:16:30 +0500] Discarding unused job-state-changed event…
D [29/May/2018:16:16:30 +0500] [Client 24] Returning IPP successful-ok for Print-Job (ipp://localhost/printers/P2055-Expert) from localhost
D [29/May/2018:16:16:30 +0500] [Client 24] Content-Length: 193
D [29/May/2018:16:16:30 +0500] [Client 24] cupsdSendHeader: code=200, type=«application/ipp», auth_type=0
D [29/May/2018:16:16:30 +0500] [Client 24] con->http=0x55fec8fc68c0
D [29/May/2018:16:16:30 +0500] [Client 24] cupsdWriteClient error=0, used=0, state=HTTP_STATE_POST_SEND, data_encoding=HTTP_ENCODING_LENGTH, data_remaining=193, response=0x55fec8fb5870(IPP_STATE_IDLE), pipe_pid=0, file=-1
D [29/May/2018:16:16:30 +0500] [Client 24] Writing IPP response, ipp_state=IPP_STATE_DATA, old wused=0, new wused=0
D [29/May/2018:16:16:30 +0500] [Client 24] bytes=0, http_state=0, data_remaining=193
D [29/May/2018:16:16:30 +0500] [Client 24] Flushing write buffer.
D [29/May/2018:16:16:30 +0500] [Client 24] New state is HTTP_STATE_WAITING
D [29/May/2018:16:16:30 +0500] [Client 24] Waiting for request.
D [29/May/2018:16:16:30 +0500] cupsdSetBusyState: newbusy=«Printing jobs and dirty files», busy=«Active clients and dirty files»
D [29/May/2018:16:16:30 +0500] [Job 346] Usage: smb://expert/hplaserj [DEVICE_URI] job-id user title copies options [file]
D [29/May/2018:16:16:30 +0500] [Job 346] The DEVICE_URI environment variable can also contain the
D [29/May/2018:16:16:30 +0500] [Job 346] destination printer:
D [29/May/2018:16:16:30 +0500] [Job 346] smb://[username:password@][workgroup/]server[:port]/printer
D [29/May/2018:16:16:30 +0500] [Job 346] PID 20717 (/usr/lib/cups/backend/smb) stopped with status 1.


UPD: Решилось обновлением samba (4.8.1-1 -> 4.8.2-1)

см. www.samba.org/samba/history/samba-4.8.2.html
o Andreas Schneider <asn@samba.org>
* BUG 13417: s3:smbspool: Fix cmdline argument handling.

7 комментариев

avatar
P2055 ведь сетевой. Почему бы просто не печатать по сети?
0
avatar
Это P2055DN сетевой, у нас просто P2055D.
2055 я привел как пример, с остальными расшаренными принтерами то же самое.
Идеальным вариантом было бы вообще отключить везде smb, но… раньше работало, а потом все сломалось.
Подозреваю, что что-то накрутили в новой версии libsmbclient либо cups.
0
avatar
Print-Job ipp://localhost/printers/P2055-Expert
Принтер ведь не через «Windows Printer via SAMBA» настроен?
Локально на проблемной машине печатает?
Последний раз редактировалось
0
avatar
именно через windows printer via samba.
D [29/May/2018:16:16:30 +0500] [Job 346] envp[23]=«DEVICE_URI=smb://expert/hplaserj»



причем кнопки «обзор» и «проверить» не работают

если вручную выполнить:
sudo /usr/lib/cups/backend/smb "smb://guest:guest@expert/hplaserj" 347 localuser "Test Page" 1 "job-uuid=urn:uuid:880a10be-94f9-34cb-429d-05af8df9039f" /var/spool/cups/d00349-001
DEBUG: Connected with username/password...

то задание хотя бы уходит в очередь печати windows (как низкоуровневый документ) и уходит на принтер, но принтер не печатает его. Но тут уже надо смотреть файл задания.
Ну и да, guest:guest в форме естественно тоже вводил, не в этом дело.
0
avatar
А локально если подключить печатает?
0
avatar
Оказывается, я не один такой. Схожая проблема, тоже пока решения не нашел.
0
avatar
Урааа!
Сегодня прилетело обновление, обновилась samba (4.8.1-1 -> 4.8.2-1)
И печать заработала.
0
Только зарегистрированные и авторизованные пользователи могут оставлять комментарии.