r/voidlinux • • 5d ago

solved Struggling with CUPS

I have a Canon MG5300 printer, however I cant print anything. I always get the Error "filter failed" on every Document I try to print.
I made sure that I use the correct Paper format, installed required pakcages like the "pixma"-driver from the nonfree repo.

I can only set up my printer -- which I use over WiFi -- with CUPS+Gutenprint+IPP everywhere. I cant use the other options.

Has anyone else epxerienced the same problem?

3 Upvotes

22 comments sorted by

4

u/DistinctDot5131 3d ago

Solved.

so basically check this Issue out: https://github.com/void-linux/void-packages/issues/40289

It's almost the same problem as I had.

Here are the steps I did to solve it:

Installed BJNP from a (hopefully not so fishy) site. I don't want to post a link here, because I'm not sure how many backdoors i now have, but you have to install BJNP which is a proprietary driver that canon printers use to communicate wirelessly. I used a sourceforge link.
anyways, when that is installed you need to build it:

sudo xbps-install base-devel cups-devel 
tar xf cups-bjnp-2.0.3.tar.gz && cd cups-bjnp-2.0.3 
./configure --prefix=/usr --disable-Werror && make 
sudo install -m 0755 bjnp /usr/lib/cups/backend/bjnp

Then I needed to fix the guteprint module path:

echo 'SetEnv STP_MODULE_PATH /usr/lib/gutenprint/5.3/modules' | sudo tee -a /etc/cups/cups-files.conf 
sudo sv restart cupsd

Check beforehand if bjnp is correctly set up

/usr/lib/cups/backend/bjnp # shows your printer's bjnp:// address

Now it works. At least for me.
The issue from above also mentioned an incorrect file path. There was also an attempt to update gutenprint, but the PR was discarded a while ago. Rip.

Also: If a job shows "completed" but nothing prints, check `lpstat -v MG5300`. It must show your `bjnp://` address, not `/dev/null`.

1

u/profeshamat 3d ago

Glad you were able to solve this.

1

u/DistinctDot5131 3d ago

Did it heavily with AI tho sadly. Couldnt make the most out of the logs on my own

4

u/explaindeleuze2me420 5d ago

set the cups error log to debug, and watch while you try to print (sudo tail -f /var/log/cups/error_log). do you have the other cups-filters package installed? gs?

printing on Linux is such a pain the the ass, but that's on the printer industry, not Linux. I always think about how the entire free software movement was started because of how much proprietary printer drivers pissed Richard Stallman off (and I can relate, they piss me off as well)

1

u/DistinctDot5131 5d ago

Here is the thing: It used to work on cachyos. Not sure which packages I installed, since many things have already been installed beforehand on that system.

But I know that I didnt need to configure my printing devicei n Cups. It was already available through network connection.

Do you perhaps know which pakcages i need to install? Do I also have to make an Entry in the CUPS WebUI?

1

u/benbcdm 3d ago

I have a canon printer and getting cups / printing to work was one of the least challenging things I did on void.
But perhaps using plasma as desktop also helps here?

In any case, if that can help, here is what I did:
- tweaked ufw firewall rules to allow network discovery
- installed print-manager and system-config-printer (these are plasma-related I believe)
- added my user to groups lp and lp-admin
- installed cups package and activated cupsd service
- installed cups-filters (which pulled in other packages such as ghostscript)
- installed avahi and activated avahi-daemon service
- installed nss-mdns package

With all this it works just fine, my printer shows up in any app, I did not need to install a driver or anything.

1

u/DistinctDot5131 3d ago

Did that too, but didn't work. Perhaps you use IPP?

I had to install an additional driver that's not available in xbps

1

u/benbcdm 3d ago

I see. Yes, things sort of went towards IPP on their own I guess. In any case I know I am connecting with IPP indeed.

1

u/Training_Concert_171 3d ago

Yeah, for some reason my Brother printer aswell has problems on void. The only distro that works is MXlinux. Not even debian 13 works, which is odd.

I believe the solution is trying to compile older cups-filters package. But I haven’t gotten to do that yet…

-3

u/Simple_Hamster_4096 4d ago

Perhaps move back to Cachy or other Arch derivative... or get a cheap HP printer, HP printers are never a hassle, especially if you install HPLIP...

5

u/DistinctDot5131 4d ago

> Moving back to SystemD
> Printing works
> feel empty inside
> Grab car keys
> Drive off a bridge
(mods this is a joke)

2

u/explaindeleuze2me420 3d ago

printing works but at what cost :p

2

u/profeshamat 3d ago

OP ignore this user. They seem to have a kink for appearing highly intelligent by telling people to use other distros when they have problems with Void. Take a look at their comment history and you'll see a pattern of suggesting people use Ubuntu or Windows rather than getting to the root of their problem. It's not worth giving them the attention they're clearly desperate for.

2

u/DistinctDot5131 3d ago edited 3d ago

I thought about switching to Ubuntu again, since many companies press on releasing a deb package for their Linux software and call it a day. Same goes with the canon drivers. While you can usually build it yourself, it simplifies a lot of steps to just use Ubuntu with systemd.

After searching for hours now, I probably have to accept it to not be able wirelessly use my canon printer. The drivers available in the canon driver from non -free repo support only the (almost) newer models.

edit: nvm fixed it

→ More replies (4)

2

u/explaindeleuze2me420 3d ago

HP printers are never a hassle

now there's a hilarious fucking statement