LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   CUPS - Can't get it to work (https://www.linuxquestions.org/questions/slackware-14/cups-cant-get-it-to-work-64471/)

cstiger 06-09-2003 12:24 AM

CUPS - Can't get it to work
 
Ok I've been struggling with CUPS for the whole weekend without making any progress.
I installed it using pkgtool and when i do a reboot i see a line that says CUPS: started scheduler.
So everything is fine at this point.
There is a directory named /dev/usb/lp0 (it's a usb printer by the way, Canon i70) so i don't need to use the command mknod or whatever that is, right?
when i try to use my web browser to configure cups by typing http://localhost:631 i get an error (Could not connect to host local host (port 631))
I repeat the cupsd is already running, there is even a PID for it, 671 or something.
my /etc/cups/cupsd.conf file is almost all commented out except for a few lines that supposedly enables cups to talk to port 631
I was thinking about showing the cupsd.conf file but i can't attach any files here, it's against the rules.
I just included the error_log file. I THINK cups appends the error messages every time i type http://localhost:631 in the browser's address text box.
What the heck is wrong?


[08/Jun/2003:13:49:36 -0700] Listening to 0:631
I [08/Jun/2003:13:49:36 -0700] Configured for up to 100 clients.
I [08/Jun/2003:13:49:36 -0700] Allowing up to 10 client connections per host.
I [08/Jun/2003:13:49:36 -0700] LoadPPDs: Read "/etc/cups/ppds.dat", 209 PPDs...
I [08/Jun/2003:13:49:36 -0700] LoadPPDs: No new or changed PPDs...
E [08/Jun/2003:14:11:01 -0700] httpGetHostByName("hostname") failed - Resource temporarily unavailable!
E [08/Jun/2003:14:11:01 -0700] Bad Listen address hostname:631 at line 356.
I [08/Jun/2003:14:11:01 -0700] Listening to 0:631
I [08/Jun/2003:14:11:01 -0700] Configured for up to 100 clients.
I [08/Jun/2003:14:11:01 -0700] Allowing up to 10 client connections per host.
I [08/Jun/2003:14:11:01 -0700] LoadPPDs: Read "/etc/cups/ppds.dat", 209 PPDs...
I [08/Jun/2003:14:11:01 -0700] LoadPPDs: No new or changed PPDs...
E [08/Jun/2003:15:21:41 -0700] Scheduler shutting down due to SIGTERM.
E [08/Jun/2003:15:51:08 -0700] httpGetHostByName("hostname") failed - Resource temporarily unavailable!
E [08/Jun/2003:15:51:08 -0700] Bad Listen address hostname:631 at line 356.
I [08/Jun/2003:15:51:08 -0700] Listening to 0:631
I [08/Jun/2003:15:51:08 -0700] Configured for up to 100 clients.
I [08/Jun/2003:15:51:08 -0700] Allowing up to 10 client connections per host.
I [08/Jun/2003:15:51:08 -0700] LoadPPDs: Read "/etc/cups/ppds.dat", 209 PPDs...
I [08/Jun/2003:15:51:08 -0700] LoadPPDs: No new or changed PPDs...

whansard 06-09-2003 12:58 AM

is your current hostname set under the loopback
address in /etc/hosts?
127.0.0.1 localhost
like that with your hostname in it.

cstiger 06-11-2003 08:09 PM

yes, the contents of the hosts file are the following:
127.0.0.1 localhost
127.0.0.1 darkstar.example.net darkstar

is that what it's supposed to look like?

Tinkster 06-11-2003 08:16 PM

Is cups defined in your /etc/services?
You have to actually permit access to
port 631 by adding a line for it.

Cheers,
Tink

Rodrin 06-11-2003 09:42 PM

If you installed the package from the Slack 9 extras directory, then CUPS should already be defined correctly in services. It sounds like you uncommented the line in the config file that reads

# Listen hostname:631

You don't need to uncomment this line. Leave it commented out. If you were to uncomment it, you would need to replace "hostname" with the actual hostname of your machine, but I recommend leaving it commented. There should be a line a little further down that reads merely

Port 631

That's all you should need as far as the port goes (other than that, you will have the log level set, and you need <location> information, but these things should be OK to begin with). In fact, you shouldn't need to touch this file at all for CUPS to work from the Slack package.

ToolBoy 06-19-2003 09:37 PM

Hey,

Just as a warning I am an extreme noob at Linux, I know almost nothing about it and anything I say should probably not be tried by anyone. I also realize that this is a somewhat old post but I figured it would comment in case it will help someone else. Anyway, I have had success getting http://localhost:631 to come up. Basically from researching stuff online I found that in order for this to work the user trying to connect to localhost:631 has to be a member of the "sys" group. I did it like this and now it works for me.

# usrmod -G sys <user>

If this helps anyone great, I hope it does not wind up causing more problems for anyone.

If a more experienced user reads this and determines this is a bad move please post a reply.

Have a good one,
Tool

moses 06-20-2003 02:01 AM

Quote:

Originally posted by ToolBoy
. . .has to be a member of the "sys" group. I did it like this and now it works for me.

# usrmod -G sys <user>

If this helps anyone great, I hope it does not wind up causing more problems for anyone.

If a more experienced user reads this and determines this is a bad move please post a reply.
This is not the problem. In the error message, one sees this:
Quote:

E [08/Jun/2003:15:21:41 -0700] Scheduler shutting down due to SIGTERM.
E [08/Jun/2003:15:51:08 -0700] httpGetHostByName("hostname") failed - Resource temporarily unavailable!
E [08/Jun/2003:15:51:08 -0700] Bad Listen address hostname:631 at line 356.
In the /etc/cups/cupsd.conf, line 356, you will find your error, which is what Rodrin has already stated, that the line, Listen hostname:631 shouldn't be uncommented. It should say Listen localhost:631.


All times are GMT -5. The time now is 03:31 PM.