Getting avahi to automatically publish CUPS printers











up vote
3
down vote

favorite
1












I know I can manually add a .service file for each printer I have. But I would like to have them published automatically.



But from what I've read, it is also possible to get CUPS to inform avahi about its printers. (both cups and avahi are compiled with dbus support.)



The printers do not show up (despite marking CUPS to Share printers connected to this system). Any recommendations about how to configure either CUPS or Avahi or about how to debug this?



FWIW, I already have BrowseLocalProtocols all in cupsd.conf.



CUPS version is 1.5.4, and avahi is 0.6.31.










share|improve this question
























  • I know the mentioned script, but as i understand jcups is using avahi to find any published printers on the net but not to automatically publish it over avahi. But I'm searching for that feature too. If you have any news (cough) I would appreciate it
    – JackGrinningCat
    Jul 13 at 16:18















up vote
3
down vote

favorite
1












I know I can manually add a .service file for each printer I have. But I would like to have them published automatically.



But from what I've read, it is also possible to get CUPS to inform avahi about its printers. (both cups and avahi are compiled with dbus support.)



The printers do not show up (despite marking CUPS to Share printers connected to this system). Any recommendations about how to configure either CUPS or Avahi or about how to debug this?



FWIW, I already have BrowseLocalProtocols all in cupsd.conf.



CUPS version is 1.5.4, and avahi is 0.6.31.










share|improve this question
























  • I know the mentioned script, but as i understand jcups is using avahi to find any published printers on the net but not to automatically publish it over avahi. But I'm searching for that feature too. If you have any news (cough) I would appreciate it
    – JackGrinningCat
    Jul 13 at 16:18













up vote
3
down vote

favorite
1









up vote
3
down vote

favorite
1






1





I know I can manually add a .service file for each printer I have. But I would like to have them published automatically.



But from what I've read, it is also possible to get CUPS to inform avahi about its printers. (both cups and avahi are compiled with dbus support.)



The printers do not show up (despite marking CUPS to Share printers connected to this system). Any recommendations about how to configure either CUPS or Avahi or about how to debug this?



FWIW, I already have BrowseLocalProtocols all in cupsd.conf.



CUPS version is 1.5.4, and avahi is 0.6.31.










share|improve this question















I know I can manually add a .service file for each printer I have. But I would like to have them published automatically.



But from what I've read, it is also possible to get CUPS to inform avahi about its printers. (both cups and avahi are compiled with dbus support.)



The printers do not show up (despite marking CUPS to Share printers connected to this system). Any recommendations about how to configure either CUPS or Avahi or about how to debug this?



FWIW, I already have BrowseLocalProtocols all in cupsd.conf.



CUPS version is 1.5.4, and avahi is 0.6.31.







cups avahi






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 15 '13 at 19:05

























asked Mar 15 '13 at 16:07









Francisco

1,095815




1,095815












  • I know the mentioned script, but as i understand jcups is using avahi to find any published printers on the net but not to automatically publish it over avahi. But I'm searching for that feature too. If you have any news (cough) I would appreciate it
    – JackGrinningCat
    Jul 13 at 16:18


















  • I know the mentioned script, but as i understand jcups is using avahi to find any published printers on the net but not to automatically publish it over avahi. But I'm searching for that feature too. If you have any news (cough) I would appreciate it
    – JackGrinningCat
    Jul 13 at 16:18
















I know the mentioned script, but as i understand jcups is using avahi to find any published printers on the net but not to automatically publish it over avahi. But I'm searching for that feature too. If you have any news (cough) I would appreciate it
– JackGrinningCat
Jul 13 at 16:18




I know the mentioned script, but as i understand jcups is using avahi to find any published printers on the net but not to automatically publish it over avahi. But I'm searching for that feature too. If you have any news (cough) I would appreciate it
– JackGrinningCat
Jul 13 at 16:18










1 Answer
1






active

oldest

votes

















up vote
0
down vote













you can use this script (thanks to Timothy J Fontaine) to generate the service-files via cron and move them to /etc/avahi/services/ like



./airprint-generate.py -d /etc/avahi/services
/etc/init.d/avahi-daemon restart





share|improve this answer

















  • 1




    Sorry, but this is what I meant with I know I can manually add a .service file for each printer I have., what I would like to have is for CUPS to just inform Avahi of its (current) printers without having to resort to a script to create the necessary files. So when using Fontaine's script, if a CUPS printer is created/deleted/renamed, I need to modify Avahi service files to reflect that (instead of having CUPS and Avahi figuring it out themselves).
    – Francisco
    Aug 28 '13 at 8:48










  • Can you check whether Avahi option had been switched ON during build time for your case? Because apparently it is off bugs.freebsd.org/bugzilla/show_bug.cgi?id=188751
    – silpol
    Dec 15 '14 at 18:04










  • I have the same problem on my Gentoo, and cups is certainly built with Avahi support.
    – L29Ah
    Aug 10 at 23:42











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "3"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f566552%2fgetting-avahi-to-automatically-publish-cups-printers%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes








up vote
0
down vote













you can use this script (thanks to Timothy J Fontaine) to generate the service-files via cron and move them to /etc/avahi/services/ like



./airprint-generate.py -d /etc/avahi/services
/etc/init.d/avahi-daemon restart





share|improve this answer

















  • 1




    Sorry, but this is what I meant with I know I can manually add a .service file for each printer I have., what I would like to have is for CUPS to just inform Avahi of its (current) printers without having to resort to a script to create the necessary files. So when using Fontaine's script, if a CUPS printer is created/deleted/renamed, I need to modify Avahi service files to reflect that (instead of having CUPS and Avahi figuring it out themselves).
    – Francisco
    Aug 28 '13 at 8:48










  • Can you check whether Avahi option had been switched ON during build time for your case? Because apparently it is off bugs.freebsd.org/bugzilla/show_bug.cgi?id=188751
    – silpol
    Dec 15 '14 at 18:04










  • I have the same problem on my Gentoo, and cups is certainly built with Avahi support.
    – L29Ah
    Aug 10 at 23:42















up vote
0
down vote













you can use this script (thanks to Timothy J Fontaine) to generate the service-files via cron and move them to /etc/avahi/services/ like



./airprint-generate.py -d /etc/avahi/services
/etc/init.d/avahi-daemon restart





share|improve this answer

















  • 1




    Sorry, but this is what I meant with I know I can manually add a .service file for each printer I have., what I would like to have is for CUPS to just inform Avahi of its (current) printers without having to resort to a script to create the necessary files. So when using Fontaine's script, if a CUPS printer is created/deleted/renamed, I need to modify Avahi service files to reflect that (instead of having CUPS and Avahi figuring it out themselves).
    – Francisco
    Aug 28 '13 at 8:48










  • Can you check whether Avahi option had been switched ON during build time for your case? Because apparently it is off bugs.freebsd.org/bugzilla/show_bug.cgi?id=188751
    – silpol
    Dec 15 '14 at 18:04










  • I have the same problem on my Gentoo, and cups is certainly built with Avahi support.
    – L29Ah
    Aug 10 at 23:42













up vote
0
down vote










up vote
0
down vote









you can use this script (thanks to Timothy J Fontaine) to generate the service-files via cron and move them to /etc/avahi/services/ like



./airprint-generate.py -d /etc/avahi/services
/etc/init.d/avahi-daemon restart





share|improve this answer












you can use this script (thanks to Timothy J Fontaine) to generate the service-files via cron and move them to /etc/avahi/services/ like



./airprint-generate.py -d /etc/avahi/services
/etc/init.d/avahi-daemon restart






share|improve this answer












share|improve this answer



share|improve this answer










answered Aug 18 '13 at 20:38









Stephan

1012




1012








  • 1




    Sorry, but this is what I meant with I know I can manually add a .service file for each printer I have., what I would like to have is for CUPS to just inform Avahi of its (current) printers without having to resort to a script to create the necessary files. So when using Fontaine's script, if a CUPS printer is created/deleted/renamed, I need to modify Avahi service files to reflect that (instead of having CUPS and Avahi figuring it out themselves).
    – Francisco
    Aug 28 '13 at 8:48










  • Can you check whether Avahi option had been switched ON during build time for your case? Because apparently it is off bugs.freebsd.org/bugzilla/show_bug.cgi?id=188751
    – silpol
    Dec 15 '14 at 18:04










  • I have the same problem on my Gentoo, and cups is certainly built with Avahi support.
    – L29Ah
    Aug 10 at 23:42














  • 1




    Sorry, but this is what I meant with I know I can manually add a .service file for each printer I have., what I would like to have is for CUPS to just inform Avahi of its (current) printers without having to resort to a script to create the necessary files. So when using Fontaine's script, if a CUPS printer is created/deleted/renamed, I need to modify Avahi service files to reflect that (instead of having CUPS and Avahi figuring it out themselves).
    – Francisco
    Aug 28 '13 at 8:48










  • Can you check whether Avahi option had been switched ON during build time for your case? Because apparently it is off bugs.freebsd.org/bugzilla/show_bug.cgi?id=188751
    – silpol
    Dec 15 '14 at 18:04










  • I have the same problem on my Gentoo, and cups is certainly built with Avahi support.
    – L29Ah
    Aug 10 at 23:42








1




1




Sorry, but this is what I meant with I know I can manually add a .service file for each printer I have., what I would like to have is for CUPS to just inform Avahi of its (current) printers without having to resort to a script to create the necessary files. So when using Fontaine's script, if a CUPS printer is created/deleted/renamed, I need to modify Avahi service files to reflect that (instead of having CUPS and Avahi figuring it out themselves).
– Francisco
Aug 28 '13 at 8:48




Sorry, but this is what I meant with I know I can manually add a .service file for each printer I have., what I would like to have is for CUPS to just inform Avahi of its (current) printers without having to resort to a script to create the necessary files. So when using Fontaine's script, if a CUPS printer is created/deleted/renamed, I need to modify Avahi service files to reflect that (instead of having CUPS and Avahi figuring it out themselves).
– Francisco
Aug 28 '13 at 8:48












Can you check whether Avahi option had been switched ON during build time for your case? Because apparently it is off bugs.freebsd.org/bugzilla/show_bug.cgi?id=188751
– silpol
Dec 15 '14 at 18:04




Can you check whether Avahi option had been switched ON during build time for your case? Because apparently it is off bugs.freebsd.org/bugzilla/show_bug.cgi?id=188751
– silpol
Dec 15 '14 at 18:04












I have the same problem on my Gentoo, and cups is certainly built with Avahi support.
– L29Ah
Aug 10 at 23:42




I have the same problem on my Gentoo, and cups is certainly built with Avahi support.
– L29Ah
Aug 10 at 23:42


















draft saved

draft discarded




















































Thanks for contributing an answer to Super User!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f566552%2fgetting-avahi-to-automatically-publish-cups-printers%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

"Incorrect syntax near the keyword 'ON'. (on update cascade, on delete cascade,)

Alcedinidae

Origin of the phrase “under your belt”?