Scientific Linux Forum.org



  Reply to this topicStart new topicStart Poll

> Printer Woes, Brother HL3045CN connected but not worki
foxinsocks
 Posted: May 4 2012, 12:17 PM
Quote Post


SLF Member
***

Group: Members
Posts: 63
Member No.: 137
Joined: 8-May 11









Running SL 6.0 on my desktop. Wired network from the modem/router with a Brother HL-2170W working nicely since for ever.

Yesterday I attached a Brother HL3045CN to the network with appropriate driver and CUPS wrapper downloaded from Brother web site. Used exactly the same setup routine as previously with the HL-2170W and gave it a fixed address on the network, just as I did with the HL-2170W.

These are the Settings details from the Printer Properties dialoge box:
Description: Brother HL3045CN
Location: 192.168.0.7
Device URI: lpd://192.168.0.7/PASSTHRU
Make and Model: Brother HL3045CN CUPS

The printer is Enabled, Accepting jobs and Shared. Access Control allows printing for everyone.

However... sending any print job to the HL-3045CN - test page or anyrhing else - and all that happens is that the 'Data" light on the printer flashes twice and then stays on for a while, but the printer does not wake up and nothing prints.

What am I missing? Any help would be appreciated.

foxinsocks
PMEmail Poster
^
toracat
 Posted: May 4 2012, 12:35 PM
Quote Post


SLF Geek
****

Group: Members
Posts: 244
Member No.: 11
Joined: 10-April 11









I have a similar Brother printer. My DeviceURI like says:

lpd://(IPaddress)/binary_p1

Have you tried 'binary_p1' ? If this also does not work, try something like socket://(IPaddress):9100. Not sure it that makes any difference since you seem to have the network connection right. It could be the driver itself or some other setup (options).


--------------------
ELRepo: repository specializing in hardware support for EL
PMUsers Website
^
foxinsocks
 Posted: May 4 2012, 01:07 PM
Quote Post


SLF Member
***

Group: Members
Posts: 63
Member No.: 137
Joined: 8-May 11









QUOTE (toracat @ May 4 2012, 10:35 PM)
I have a similar Brother printer. My DeviceURI like says:

lpd://(IPaddress)/binary_p1

Have you tried 'binary_p1' ?  If this also does not work, try something like socket://(IPaddress):9100. Not sure it that makes any difference since you seem to have the network connection right. It could be the driver itself or some other setup (options).



Thanks for the early reply, toracat. I already tried 'binay_p1' :-(
I just tried your 'socket' suggestion but had no luck there either.

foxinsocks
PMEmail Poster
^
toracat
 Posted: May 4 2012, 04:00 PM
Quote Post


SLF Geek
****

Group: Members
Posts: 244
Member No.: 11
Joined: 10-April 11









As I suspected, network communication may not be an issue. Do you see anything unusual in /var/log/cups/error_log ? In other words, as far as the sending machine (SL box) is concerned, there is nothing wrong with the queuing ?

Have you looked through the options and see if all seems fine (paper size, tray setting, etc)?


--------------------
ELRepo: repository specializing in hardware support for EL
PMUsers Website
^
foxinsocks
 Posted: May 7 2012, 12:03 AM
Quote Post


SLF Member
***

Group: Members
Posts: 63
Member No.: 137
Joined: 8-May 11









QUOTE (toracat @ May 5 2012, 02:00 AM)
As I suspected, network communication may not be an issue. Do you see anything unusual in /var/log/cups/error_log ?  In other words, as far as the sending machine (SL box) is concerned, there is nothing wrong with the queuing ?

Have you looked through the options and see if all seems fine (paper size, tray setting, etc)?



I'm looking at the error_log - some of which I don't follow sad.gif As far as paper size is concerned, I have it set for A4 (there seem to be 2 places where it paper size to be specified - one hidden) but there's this entry in error_log:
D [06/May/2012:20:41:16 +1000] [Job 1098] argv[5]="job-uuid=urn:uuid:c192227c-067c-3c8c-538e-9832eed56cbf media=na_letter_8.5x11in job-originating-host-name=localhost"

Further down it has:
D [06/May/2012:20:41:16 +1000] [Job 1098] envp[22]="DEVICE_URI=ipp://192.168.0.7:631/ipp"
but in the Printer Properties dialog box I have:
lpd://192.168.0.7/PASSTHRU

At the end of the job:
D [06/May/2012:20:41:16 +1000] [Job 1098] /usr/lib/cups/filter/brlpdwrapperhl3045cn: line 118: /opt/brother/Printers/hl3045cn/cupswrapper/brcupsconfpt1: Permission denied
D [06/May/2012:20:41:16 +1000] [Job 1098] /usr/lib/cups/filter/brlpdwrapperhl3045cn: line 125: /opt/brother/Printers/hl3045cn/lpd/filterhl3045cn: Permission denied
D [06/May/2012:20:41:16 +1000] [Job 1098] Set job-printer-state-message to "Empty print file!", current level=ERROR
D [06/May/2012:20:41:16 +1000] [Job 1098] Backend returned status 1 (failed)
D [06/May/2012:20:41:16 +1000] [Job 1098] Printer stopped due to backend errors; please consult the error_log file for details.
D [06/May/2012:20:41:16 +1000] [Job 1098] End of messages
D [06/May/2012:20:41:16 +1000] [Job 1098] printer-state=5(stopped)
D [06/May/2012:20:41:16 +1000] [Job 1098] printer-state-message="Empty print file!"
D [06/May/2012:20:41:16 +1000] [Job 1098] printer-state-reasons=paused
W [06/May/2012:20:54:17 +1000] [Job 1099] Remote host did not respond with data status byte after 300 seconds!

The 'bottom line' is, I'm completely confused sad.gif


foxinsocks
PMEmail Poster
^
scottro
 Posted: May 7 2012, 02:03 AM
Quote Post


SLF Member
***

Group: Members
Posts: 71
Member No.: 49
Joined: 14-April 11









Firstly, Toracat, I like the icon.

More seriously....

I would troubleshoot this way:

If you have another computer, especially with Windows or OS X, does that print to it? If not, a more current version of Linux, e.g., Ubuntu, or Fedora.
If that works, I'd probably then try troubleshooting SELinux and iptables--they sound unlikely culprits in this case, but it just takes a few minutes to test.

You could temporarily disable SELinux and see if it prints then. If so, you know it is an SELinux issue and can troubleshoot it that way. (To temporarily disable, as root, setenforce 0 will tod it, with no need for restarts or relabling. When done, put it back with setenforce 1)

If still not working, especially if it's not on a public network--that is, if it's behind a router and such---I'd temporarily disable iptables with service iptables -F as in flush, and try again. I'd probably be restarting cups after making each change too, just takes a second to do so.

You can put iptables back with service iptables start

However, if other printers have worked in the past, neither of those two sound like likely issues. I'm most curious to know if Ubuntu, or other more current version of Linux, will print.
PM
^
toracat
 Posted: May 7 2012, 04:52 AM
Quote Post


SLF Geek
****

Group: Members
Posts: 244
Member No.: 11
Joined: 10-April 11









Nice to see you here, scottro ! smile.gif

I was just about to suggest temporarily disabling SELinux. As you said, it is easy to test.


--------------------
ELRepo: repository specializing in hardware support for EL
PMUsers Website
^
scottro
 Posted: May 9 2012, 02:44 AM
Quote Post


SLF Member
***

Group: Members
Posts: 71
Member No.: 49
Joined: 14-April 11









By the way, while on Brother, this may come in useful to someone. I have the HL2170W. Recently, the toner light was going on, but printing quality seemed normal, and even though we're still on the cartridge that came with the printer, it seemed unlikely.

Some googling indicated that the sensor lens on the right hand side of the toner cartridge could be covered with black electrical tape, or even colored over with a black marker. I did that (the black marker, using a Sharpie is always fun)* replaced the toner, and it's printing without issues now.



* (Quote from Doctor Who) " Big flashy lighty things have got me written all
over them. Not actually, but give me time and a crayon"
PM
^
foxinsocks
 Posted: May 9 2012, 04:37 AM
Quote Post


SLF Member
***

Group: Members
Posts: 63
Member No.: 137
Joined: 8-May 11









QUOTE (scottro @ May 7 2012, 12:03 PM)
Firstly, Toracat, I like the icon. 

Sorry for the delay in replying.

<SNIP>
You could temporarily disable SELinux and see if it prints then. If so, you know it is an SELinux issue and can troubleshoot it that way.  (To temporarily disable, as root, setenforce 0 will tod it, with no need for restarts or relabling.  When done, put it back with setenforce 1)



Yessss!!!! Thanks for this workaround. I got a test page to print, then a page of text and a colour illustration from a .pdf file. Now all I have to do is work out how to have SELinux running and allow printing to the HL3045CN. But this raises for me the question as to why the HL-2170W runs with SELinux on. (It's the default printer on the LAN)

I guess that, at worst, I can cut SELIinux when I want to use the HL3045CN and then bring it up again when I've finished the occasional colour print job.

Thanks again for the ideas, guys. How good is this forum!!!
PMEmail Poster
^
toracat
 Posted: May 9 2012, 08:01 AM
Quote Post


SLF Geek
****

Group: Members
Posts: 244
Member No.: 11
Joined: 10-April 11









This seems to be a common problem with certain brother printers. Mine works fine, too, like your other model.

Take a look at this TUV bugzilla. It will give you some hint as to how to handle SELinux.


--------------------
ELRepo: repository specializing in hardware support for EL
PMUsers Website
^
foxinsocks
 Posted: May 9 2012, 08:56 AM
Quote Post


SLF Member
***

Group: Members
Posts: 63
Member No.: 137
Joined: 8-May 11









QUOTE (toracat @ May 9 2012, 06:01 PM)
This seems to be a common problem with certain brother printers. Mine works fine, too, like your other model.

Take a look at this TUV bugzilla. It will give you some hint as to how to handle SELinux.


Thanks. I'll check it out :-)
PMEmail Poster
^
scottro
 Posted: May 10 2012, 02:15 AM
Quote Post


SLF Member
***

Group: Members
Posts: 71
Member No.: 49
Joined: 14-April 11









I also have no trouble, with SELinux enabled, in printing to a networked Brother H2170W.

PM
^
zxq9
 Posted: May 10 2012, 09:47 AM
Quote Post


SLF Advocate
*****

Group: Members
Posts: 376
Member No.: 611
Joined: 5-August 11









As for as handling SELinux...

Don't be scared of jumping into SELinux with both feet. Do be afraid of "just turning it off" like so many people do; it both weakens security and is just a weak decision to make. Its the equivalent of saying "file permissions prevent my system from working like WindowsXP?!? A pox on those who write security inconveniences and force me to learn things!
CODE
'chmod --no-preserve-root --recursive 777 /'
Glad I took care of that...".

Fedora based distros provide a great set of tools to help you parse your SELinux audit logs and convert selected portions into functional policy automatically. They can even package the policies up into distributable bundles for you so if you are writing or packaging a new software package that needs a custom SELinux policy you can bundle any needed policy with the RPMs you're pushing out, or pass the policy bundle to other machines facing the same SELinux blocking issues.

Read (or skim) the following:
The last two things there are wonderful resources, and so is Dan Walsh's blog about SELinux (but you might only be able to make sense of his blog once you grok SELinux a bit). I suggest skimming the audit2allow and auditd man pages first, then skimming over the selinux man page, then actually reading the Fedora troubleshooting SELinux page, then returning to the audit2allow man page and actually reading it, paying particular attention to the last section "Using audit2allow to generate and build module policy".

Most of this will sort of stick by then, and forever will 90% of your SELinux woes be gone (the remaining 10% will be demoted from "First Class Hairpullers" to being "Researchable/Resolvable").

The reason I'm going to such length to urge you to learn a bit about SELinux and list canonical resources many folks just don't know exist is because it will help you forever with understanding all sorts of things, not just this particular printer issue.
PMEmail PosterUsers Website
^
toracat
 Posted: May 10 2012, 03:05 PM
Quote Post


SLF Geek
****

Group: Members
Posts: 244
Member No.: 11
Joined: 10-April 11









Nice writing, zxq9.

Let me add just one link which I believe is useful: Stop Disabling SELinux.


--------------------
ELRepo: repository specializing in hardware support for EL
PMUsers Website
^
zxq9
 Posted: May 10 2012, 04:43 PM
Quote Post


SLF Advocate
*****

Group: Members
Posts: 376
Member No.: 611
Joined: 5-August 11









Not (just) to toot my own horn, but that post looks strikingly similar to the long version of my old tl;dr post about setting up Drupal 7 on rpm-based systems with SELinux enabled that I never wound up finishing (the link is to the tl;dr version only).

What is interesting isn't that he and I had the same idea for a blog post a year apart. What is amazing is the ridiculous arguments going on in his blog post comments about how "hard" SELinux is right after he explains how its no longer hard.

Web developers are notorious for being bad developers. That doesn't even need softening. Its simply true that if you can't hack it in electrical engineering courses and think Java is a reasonable substitute for C in school that you are likely to become a web or at least an iOS developer because system-level issues are simply beyond you.

Thinking that disabling SELinux is a reasonable step for a public-facing server falls right in line with other diseases like thinking that php is a reasonable development environment in 2012, mistaking the "web" for a new technology, or "browser technology" for a platform of its own (which I wrote an extensive rant about on this forum months ago in a thread that evolved into a programming thread, which wound up turning into a "let's study C under zxq9" movement that I subsequently wasn't able to follow up on due to major time constraints IRL (sorry guys... (>.<) )...).

Meh. The neckbeard anger is strong with me tonight...
PMEmail PosterUsers Website
^
Nathan
 Posted: May 10 2012, 04:51 PM
Quote Post


SLF Geek
****

Group: Members
Posts: 288
Member No.: 928
Joined: 15-October 11









The problem with SELinux is that its documentation isn't just something you read when you have a couple minutes spare time - you need to actually invest a fair amount of time in it in order to understand how it works and how you should work with it. Many people do not have this time or, if they do, would rather invest it in something else, hence they just disable SELinux to get rid of all their problems immediately.

I personally think SELinux is an unholy mess and disable it ASAP. I have barely any use for it, and enabling it (even in permissive mode) is to me like using Tor as your default browser: an utterly ridiculous waste of time. Might as well start wearing a tin foil hat.
PM
^
foxinsocks
 Posted: May 12 2012, 10:57 AM
Quote Post


SLF Member
***

Group: Members
Posts: 63
Member No.: 137
Joined: 8-May 11









I've been away for a few day.
Thanks, guys, for all the helpful comments, links and opinions.

I'll delve into the links and documentation over time and try to get some understanding of what SELinux is trying to do and how to work with it. At least for the time being I have workaround that enables me to do the occasional colour print job. And as I indicated earlier in this topic my very basic network is behind a firewall.

PMEmail Poster
^
foxinsocks
 Posted: May 12 2012, 10:57 AM
Quote Post


SLF Member
***

Group: Members
Posts: 63
Member No.: 137
Joined: 8-May 11









I've been away for a few day.
Thanks, guys, for all the helpful comments, links and opinions.

I'll delve into the links and documentation over time and try to get some understanding of what SELinux is trying to do and how to work with it. At least for the time being I have workaround that enables me to do the occasional colour print job. And as I indicated earlier in this topic my very basic network is behind a firewall.

PMEmail Poster
^
0 User(s) are reading this topic (0 Guests and 0 Anonymous Users)
0 Members:

Topic Options Reply to this topicStart new topicStart Poll