Page 1 of 1

CUPS-PDF returns "invalid filename" error (SOLVED)

Posted: Wed Mar 13, 2024 12:17 pm
by fernan

Hello. I'm using Bionicup64, CUPS 2.2.7

When trying to print a PDF file, I get an "invalid filename" error (pict attached)

In a fresh install, RAM session, it works fine, so it's something that was broken in my install.

Would it be possible to fix this, without installing the whole system again?

Thanks very much!

ERROR SCREEN:

screenshot2.png
screenshot2.png (134.41 KiB) Viewed 1824 times

RAM SESSION SCREEN (WORKING OK)

Screenshot.png
Screenshot.png (83.26 KiB) Viewed 1824 times

Re: CUPS-PDF returns "invalid filename" error

Posted: Wed Mar 13, 2024 12:45 pm
by fernan

I've found a difference between a RAM session and my install:

Searching for "pdf-writer" gives me a file in my install, not present in the RAM session, perhaps it's creating some conflict:

(file highlighted is not present in a RAM session, it was installed by some package)

pdf-writer1.png
pdf-writer1.png (24.49 KiB) Viewed 1810 times
pdf-writer2.png
pdf-writer2.png (23.72 KiB) Viewed 1810 times

RAM SESSION:

pdf-writer-ram.png
pdf-writer-ram.png (12.97 KiB) Viewed 1807 times

Re: CUPS-PDF returns "invalid filename" error

Posted: Wed Mar 13, 2024 3:50 pm
by mikewalsh

@fernan :-

'Kayyy...

Um; you ARE aware, I take it, that the CUPS-PDF option doesn't print anything out.....but instead creates a PDF out of your chosen document? You probably know this anyway, but I still needed to ask..! :o

Mike. ;)


Re: CUPS-PDF returns "invalid filename" error

Posted: Thu Mar 14, 2024 1:28 am
by fernan

Yes, I know, I'm trying to create a PDF file but my install doesn't allow me to save the file. I can do it in a RAM session. So something is wrong in my install.

( I'm a prepress technician with 30 years of experience dealing with PS and PDF files...)


Re: CUPS-PDF returns "invalid filename" error

Posted: Thu Mar 14, 2024 11:25 am
by rockedge

I also have seen this error. I used another type of PDF print option which created and saved the PDF page. I'll review that issue again.


Re: CUPS-PDF returns "invalid filename" error

Posted: Thu Mar 14, 2024 11:30 am
by fernan

Thanks. Iĺl try it and report back.


Re: CUPS-PDF returns "invalid filename" error

Posted: Sat Mar 16, 2024 4:30 pm
by fernan

Update: No way. I can't save any PDF.

I think I'll start uninstalling packages and retry until (luckily) find the one that caused the problem... I'm not sure if uninstalling everything from the package manager will end in a clean OS again.


Re: CUPS-PDF returns "invalid filename" error

Posted: Sun Mar 17, 2024 1:35 pm
by fernan

Update: Reinstalling a fresh Bionicpup64. I didn't find any other way to make CUPS-PDF to work.


Re: CUPS-PDF returns "invalid filename" error

Posted: Sun Mar 17, 2024 1:48 pm
by rockedge
fernan wrote: Sun Mar 17, 2024 1:35 pm

Update: Reinstalling a fresh Bionicpup64. I didn't find any other way to make CUPS-PDF to work.

does printing to PDF work again?

The problem I seem to have run into is tied to the two different methods to print to PDF. One option was to print to a virtual PDF printer and the other option was "save to PDF". In my case saving worked but the virtual PDF printer option refused to work at all always noting a "filter failure" as the cause.


Re: CUPS-PDF returns "invalid filename" error

Posted: Sun Mar 17, 2024 11:20 pm
by fernan

So, it seems my install is not the only install with problems printing to PDF...

In my fresh install, CUPS-PDF printer works (printing to that virtual printer)

I' ll check step by step, printing a PDF after each package I install, to see which one is the offending one. I bet it's something related to HPLIP, the only thing I've installed evidently related to printing. But it could be some other graphics package too. I've installed Scribus and Inkscape in my previous system.


Re: CUPS-PDF returns "invalid filename" error

Posted: Wed Mar 20, 2024 12:29 pm
by vtpup

Is the filename "Test Page.pdf" a problem?

Does "TestPage.pdf' work?

Also what about "Testpage1.pdf"

Also type "lpstat" in terminal to see if any unfinished job #s are queued and blocking output.

If so, type "clear" and the job number to drop it, eg "clear 147"


Re: CUPS-PDF returns "invalid filename" error

Posted: Thu Mar 21, 2024 11:32 am
by fernan

Hello. Thanks for your interest.

The CUPS-PDF printer doesn't work in the "old" install, it can't print any file, including the test page or any other file with any other name in any other locations (already tried to change the file name and destination folders). It works OK (by now) in a fresh install.

I'm checking it everyday , specially after installing some packages in the fresh install.

Only once it failed, unable to print the test page from the CUPS web interface, after changing the language in the Puppy Setup screen. But after changing the language again, it keeps working by now. I'll keep testing and post any relevant results here for reference. I still need to install HPLIP to install my "real" hardware printer.


Re: CUPS-PDF returns "invalid filename" error

Posted: Thu Mar 21, 2024 1:24 pm
by vtpup

Did you try the suggestions?


Re: CUPS-PDF returns "invalid filename" error

Posted: Fri Mar 22, 2024 12:25 pm
by fernan
vtpup wrote: Wed Mar 20, 2024 12:29 pm

Is the filename "Test Page.pdf" a problem?

Does "TestPage.pdf' work?

Also what about "Testpage1.pdf"

Also type "lpstat" in terminal to see if any unfinished job #s are queued and blocking output.

If so, type "clear" and the job number to drop it, eg "clear 147"

Thanks for your answer. As stated, the problem is the invalid filename error in the CUPS-PDF printer. I can print to a hardware printer.

Everything suggested previously was already tested and there was no way to print a PDF through the CUPS-PDF virtual printer in my "old" install. A bit inconvenient (due to the lot of custom settings I was doing on my install to fit my needs), but the only solution was a fresh session.

Something broke my previous pdf-writer, but I couldn't revert the situation, even uninstalling all the packages with the PPM.

Something similar happened in another computer some time ago, CUPS stopped working, I had to install puppy again.


Re: CUPS-PDF returns "invalid filename" error

Posted: Fri Mar 22, 2024 2:27 pm
by fernan

Update: Installed HPLIP in the new Puppy, hardware printer working, CUPS-PDF still working.. Fingers crossed.


Re: CUPS-PDF returns "invalid filename" error

Posted: Fri Mar 22, 2024 9:24 pm
by p310don

Can you copy the CUPS (/etc/cups or /etc/cups/ppd) directory from the working install to the non-working install, overwriting the problematic files?


Re: CUPS-PDF returns "invalid filename" error

Posted: Sat Mar 23, 2024 1:52 am
by fernan

I've tried those kind of "transplants" previously (in my other computer, some time ago when CUPS stopped working), and never worked. It seems CUPS is spread in many directories, actually I couldn't find on the net any definitive answer about completely resetting CUPS without reinstalling the package.

It seems, but I could be wrong (I'm a veteran Puppy linux user but never a linux expert), that being CUPS included in the main SFS file (a read only file system), when you start copying directories or files over it, written on your pupsave SFS (read-write file system), the result is not satisfactory.

What I could try, now that I have a working install, is to boot in RAM , mount both pupsave SFS (old and new), and compare (or copy) that directory from the working install to the broken install, and reboot.


Re: CUPS-PDF returns "invalid filename" error

Posted: Sat Mar 23, 2024 12:17 pm
by fernan

IT'S ALIVE !! IT WORKED !!

I booted a RAM session, mounted both pupsave files (old and new), deleted the following 2 folders from the old (non working) install:

/etc/cups
/usr/lib/cups

and replaced them with the folders from the new pupsave, and now CUPS-PDF works normally.

Previously, I had installed my hardware printer and hplip package in the new puppy install. After this "folder swap", the hardware printer works fine in the old puppy install.

What I was doing wrong in other occasions, is to copy folders or files from the session in use, to another pupsave file. It seems doing that, I was messing with the read only files in use being copied to the 2nd pupsave sfs. Booting a fresh RAM session and copying from one pupsave.sfs to another pupsave.sfs worked fine.

I want to thank you all who offered ideas and solutions. Thanks again.


Re: CUPS-PDF returns "invalid filename" error (SOLVED)

Posted: Sun Apr 21, 2024 10:48 pm
by fernan

Thanks. I've copied 2 folders from a fresh install and solved the issue without reinstalling the OS.