LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 02-09-2011, 02:39 PM   #1
HyperTrey
Member
 
Registered: Sep 2006
Posts: 127

Rep: Reputation: 15
LPR question


I am trying to write a BASH script that will help people print on Linux Servers (CentOS). I am asking the file in the script.

We use a print server That have specific named print queue/ports. The syntax I am using is:

lpr -H at-test.college.edu:Test-BWQ -U test test.doc

and I get a "lpr : Error - Scheduler is not responding!". What dit I do wrong?

[Examples used:]
Server: at-test.college.edu
Port/queues: Test-BWQ
user: test
 
Old 02-09-2011, 06:24 PM   #2
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911
Is CUPS actually running?
 
Old 02-10-2011, 09:44 AM   #3
HyperTrey
Member
 
Registered: Sep 2006
Posts: 127

Original Poster
Rep: Reputation: 15
to be honest, I do not know how to check.
 
Old 02-10-2011, 09:54 AM   #4
HyperTrey
Member
 
Registered: Sep 2006
Posts: 127

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by HyperTrey View Post
to be honest, I do not know how to check.

Check that, I figured out how to check. lpstat -r show that the scheduler is running. And I still can't print with command. Did I get the syntax right?
 
Old 02-10-2011, 11:14 AM   #5
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911
And can you post the output of lpstat -t?
 
Old 02-10-2011, 12:45 PM   #6
HyperTrey
Member
 
Registered: Sep 2006
Posts: 127

Original Poster
Rep: Reputation: 15
lpstat -t
scheduler is running
no system default destination
lpstat: No destinations added.
lpstat: No destinations added.
lpstat: No destinations added.
lpstat: No destinations added.


How ever I assumed that with: lpr -H at-test.college.edu:Test-BWQ -U test test.doc that the destination was the printer attached to the print server at port Test-BWQ.
 
Old 02-10-2011, 01:10 PM   #7
paulsm4
LQ Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
Hi -

First verify that CUPS is installed (it sounds like it probably is):
Quote:
rpm -qa |grep -i cpus
Second, see if you can configure one or more printers from the GUI:
Chap 33: Printer Configuration

'Hope that helps
 
Old 02-10-2011, 01:32 PM   #8
HyperTrey
Member
 
Registered: Sep 2006
Posts: 127

Original Poster
Rep: Reputation: 15
ok, so there is no way to print to a server without installing a printer first? (was trying to make it easy for the linux server guys without having to manage printers on their server too
 
Old 02-10-2011, 02:22 PM   #9
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911Reputation: 911
Quote:
Originally Posted by HyperTrey View Post
ok, so there is no way to print to a server without installing a printer first? (was trying to make it easy for the linux server guys without having to manage printers on their server too
You answered your own question; w/o a defined queue and printer
printing via CUPS is not possible.



Cheers,
Tink
 
  


Reply

Tags
[bash]


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
lpr and /dev/usb/lp0 ---- simple question v333k Linux - Software 19 11-01-2009 01:23 PM
what is the different between lp, lpr, llpr, lpr.cups... lnthai2002 Linux - Software 5 04-13-2006 05:09 PM
confused... lpr/ lpr-cups shadow.blue Linux - Software 1 04-06-2004 06:15 PM
lpr & lpr-cups commands not working with CUPS trinbellwoods Debian 2 01-08-2004 09:25 AM
lpr / printcaps question jkcunningham Linux - Software 0 10-22-2002 12:16 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 08:05 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration