LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 02-26-2005, 10:12 PM   #1
rossjman1
Member
 
Registered: Oct 2004
Location: Chicago, IL, USA
Distribution: Debian
Posts: 71

Rep: Reputation: 15
Cups server not working


Hi. Whenever I try to got into to the Printing Manager, I get this error.

Unable to retrieve the printer list. Error message received from manager:
Connection to CUPS server failed. Check that the CUPS server is correctly installed and running. Error: connection refused.

I tried:
Code:
apt-get remove cupsys
apt-get install cupsys
with no luck. I also get this error when using lpq in bash.
Code:
lpq: Unable to contact server!.
Please help me! I got a school report due in 2 days! Thanks in advance.

Last edited by rossjman1; 02-26-2005 at 10:17 PM.
 
Old 02-26-2005, 10:23 PM   #2
Dead Parrot
Senior Member
 
Registered: Mar 2004
Distribution: Debian GNU/kFreeBSD
Posts: 1,597

Rep: Reputation: 46
I'm no good at configuring printers, but I do know that the following command (run as root) should ensure that you've got all the necessary packages installed:
Code:
aptitude -r install foomatic-bin cupsys-driver-gimpprint
 
Old 02-26-2005, 10:30 PM   #3
rossjman1
Member
 
Registered: Oct 2004
Location: Chicago, IL, USA
Distribution: Debian
Posts: 71

Original Poster
Rep: Reputation: 15
nope, still get the same errors.
 
Old 02-26-2005, 10:51 PM   #4
Dead Parrot
Senior Member
 
Registered: Mar 2004
Distribution: Debian GNU/kFreeBSD
Posts: 1,597

Rep: Reputation: 46
Well, the error messages suggest that the CUPS server is not running. You need to start this server before you can configure any printers. To start CUPS, you can either reboot or run (as root) the following command:
Code:
invoke-rc.d cupsys start
 
Old 02-26-2005, 10:53 PM   #5
utanja
Member
 
Registered: Apr 2004
Location: Europe:Salzburg Austria USA:Orlando,Florida;
Distribution: Debian
Posts: 643

Rep: Reputation: 32
i am running the 2.8.10 kernel with cups and several canon i560's

no problems here....

try this

Code:
apt-get install cupsys  cupsys-bsd cupsys-client cupsys-driver-gimpprint cupsys-driver-gimpprint-data cupsys-pt foomatic-db foomatic-db-engine foomatic-db-gimpprint 
foomatic-filters foomatic-gui
after installing....using your web browser

http://localhost:631

go to the manage printers dialogue and add printers...

utanja
 
Old 02-26-2005, 11:03 PM   #6
rossjman1
Member
 
Registered: Oct 2004
Location: Chicago, IL, USA
Distribution: Debian
Posts: 71

Original Poster
Rep: Reputation: 15
Thanks Dead Parrot! Rebooting works. I activated my deskjet, and printed my report. Thanks so much.
 
Old 02-26-2005, 11:57 PM   #7
rossjman1
Member
 
Registered: Oct 2004
Location: Chicago, IL, USA
Distribution: Debian
Posts: 71

Original Poster
Rep: Reputation: 15
I got another issue. The cause of these 2 issues were that I did
Code:
apt-get dist-upgrade
.

For some reason the above code also uninstalled frozen bubble, and now I cant get it back.
Code:
root@HP_PAVILION:~# apt-get install frozen-bubble
Reading Package Lists... Done
Building Dependency Tree... Done
frozen-bubble is already the newest version.
The following extra packages will be installed:
  frozen-bubble-data
The following packages will be upgraded:
  frozen-bubble-data
1 upgraded, 0 newly installed, 0 to remove and 3 not upgraded.
2 not fully installed or removed.
Need to get 0B/5155kB of archives.
After unpacking 1651kB of additional disk space will be used.
Do you want to continue? [Y/n] y
(Reading database ... 109410 files and directories currently installed.)
Preparing to replace frozen-bubble-data 1.0.0-4 (using .../frozen-bubble-data_1.0.0-6_all.deb) ...
Unpacking replacement frozen-bubble-data ...
mv: cannot stat `/usr/games/frozen-bubble.wav': No such file or directory
dpkg: warning - old post-removal script returned error exit status 1
dpkg - trying script from the new package instead ...
dpkg: error processing /var/cache/apt/archives/frozen-bubble-data_1.0.0-6_all.deb (--unpack):
 there is no script in the new version of the package - giving up
preinst called with unknown argument `abort-upgrade'
dpkg: error while cleaning up:
 subprocess pre-installation script returned error exit status 1
Errors were encountered while processing:
 /var/cache/apt/archives/frozen-bubble-data_1.0.0-6_all.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
It says I already have frozen-bubble because I did the apt-get a few times before posting the errors here. The first time it installed it, so obviously the problem lies in the frozen-bubble-data.deb package...

Code:
apt-get install frozen-bubble-data
apt-get remove frozen-bubble
apt-get remove frozen-bubble-data
apt-get install -f
all produce similar errors.

Last edited by rossjman1; 02-27-2005 at 12:08 AM.
 
Old 02-27-2005, 04:06 AM   #8
Dead Parrot
Senior Member
 
Registered: Mar 2004
Distribution: Debian GNU/kFreeBSD
Posts: 1,597

Rep: Reputation: 46
When you encounter a new problem that is not related to the earlier problem, you'll get more attention for this new problem if you introduce it in a new thread.

Personally I haven't met apt-related problems for a long time, so I've kinda forgotten how to solve them. But in general, you can use the --purge option (apt-get --purge remove some_package) to get rid of also the configuration files that came with the package. Sometimes it's the left-over configuration files that can cause problems.

If this doesn't help, you can try to re-install the problematic package(s) and then go to the cache directory where apt stores downloaded packages (cd /var/cache/apt/archives) and then use dpkg (as root) to force the installation (dpkg -i --force-overwrite *) and also to make sure that the installed packages are configured (dpkg --configure -a).

At least, this is how I seem to recall it should go when apt chokes on half-installed packages. But as I said, I cannot remember for sure. There are probably many threads about similar situations, so maybe you should search this forum (or, indeed, start a new thread).

EDIT:
Come to think of it, if you haven't cleaned apt's cache for a while (apt-get clean), then you've got tons of downloaded packages and "dpkg -i --force-overwrite *" will re-install ALL of them, which might be overkill. If the only packages that cause problems are frozen-bubble related, you should do something like "dpkg -i --force-overwrite frozen*" instead. Also, frozen-bubble probably doesn't need configuration via dpkg.

Last edited by Dead Parrot; 02-27-2005 at 07:48 AM.
 
Old 02-27-2005, 10:22 AM   #9
rossjman1
Member
 
Registered: Oct 2004
Location: Chicago, IL, USA
Distribution: Debian
Posts: 71

Original Poster
Rep: Reputation: 15
dpkg -i --force-overwrite frozen*
Code:
root@HP_PAVILION:/var/cache/apt/archives# dpkg -i --force-overwrite frozen*
Selecting previously deselected package frozen-bubble-data.
(Reading database ... 109387 files and directories currently installed.)
Preparing to replace frozen-bubble-data 1.0.0-4 (using frozen-bubble-data_1.0.0-6_all.deb) ...
Unpacking replacement frozen-bubble-data ...
mv: cannot stat `/usr/games/frozen-bubble.wav': No such file or directory
dpkg: warning - old post-removal script returned error exit status 1
dpkg - trying script from the new package instead ...
dpkg: error processing frozen-bubble-data_1.0.0-6_all.deb (--install):
 there is no script in the new version of the package - giving up
preinst called with unknown argument `abort-upgrade'
dpkg: error while cleaning up:
 subprocess pre-installation script returned error exit status 1
Selecting previously deselected package frozen-bubble.
Unpacking frozen-bubble (from frozen-bubble_1.0.0-6_i386.deb) ...
dpkg: dependency problems prevent configuration of frozen-bubble:
 frozen-bubble depends on frozen-bubble-data (= 1.0.0-6); however:
  Package frozen-bubble-data is not installed.
dpkg: error processing frozen-bubble (--install):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 frozen-bubble-data_1.0.0-6_all.deb
 frozen-bubble
dpkg --configure -a
Code:
Setting up apache-utils (1.3.33-3) ...
Setting up comerr-dev (2.1-1.36release-1) ...

dpkg: dependency problems prevent configuration of frozen-bubble:
 frozen-bubble depends on frozen-bubble-data (= 1.0.0-6); however:
  Package frozen-bubble-data is not installed.
dpkg: error processing frozen-bubble (--configure):
 dependency problems - leaving unconfigured
Setting up autofs (4.1.3+4.1.4beta2-2) ...
Stopping automounter: done.
Starting automounter: done.
and also:
dpkg -i frozen-bubble-data.deb
Code:
root@HP_PAVILION:/home/jantosh/Installation Files/Games# ls
TuxRacer  cowsay.deb  frozen-bubble-data.deb
root@HP_PAVILION:/home/jantosh/Installation Files/Games# dpkg -i frozen-bubble-data.deb
(Reading database ... 109410 files and directories currently installed.)
Preparing to replace frozen-bubble-data 1.0.0-4 (using frozen-bubble-data.deb) ...
Unpacking replacement frozen-bubble-data ...
mv: cannot stat `/usr/games/frozen-bubble.wav': No such file or directory
dpkg: warning - old post-removal script returned error exit status 1
dpkg - trying script from the new package instead ...
dpkg: error processing frozen-bubble-data.deb (--install):
 there is no script in the new version of the package - giving up
preinst called with unknown argument `abort-upgrade'
dpkg: error while cleaning up:
 subprocess pre-installation script returned error exit status 1
Errors were encountered while processing:
 frozen-bubble-data.deb

Last edited by rossjman1; 02-27-2005 at 10:32 AM.
 
Old 02-27-2005, 11:25 AM   #10
Dead Parrot
Senior Member
 
Registered: Mar 2004
Distribution: Debian GNU/kFreeBSD
Posts: 1,597

Rep: Reputation: 46
It is quite rare that apt-get stumbles into missing dependencies, but it happens -- especially in Debian Unstable. Apparently the package frozen-bubble-data requires a file /usr/games/frozen-bubble.wav but apt cannot find it. It also says something about "old post-removal script", which may be the cause of all this trouble.

This is just a guesswork but maybe you could create a dummy file to fool frozen-bubble-data (touch /usr/games/frozen-bubble.wav) and then try the "dpkg -i --force-overwrite frozen*" thing again. However, even if this is successful it will leave you with frozen-bubble that has no sound, so you might want to remove frozen-bubble with "apt-get --purge remove frozen-bubble".

Then, if you're lucky, you may be able to fix the dependency problem by updating apt's database (apt-get update) and doing another "apt-get dist-upgrade". If this works, then you should be able to install frozen-bubble as usual (apt-get install frozen-bubble).

It's wise not to keep too many entries in /etc/apt/sources.list. Also, you should always do "apt-get update" before you run "apt-get upgrade" ("apt-get dist-upgrade" is used mainly for switching from one branch to another, like from testing to unstable, and for fixing the kind of dependency problems you're experiencing at the moment).

And, if you haven't already done that, you should install the apt-listbugs utility that will warn you of bugs and dependency problems that other users have already spotted and reported.

EDIT: I just checked my own installation of frozen-bubble and I don't have /usr/games/frozen-bubble.wav. If the above doesn't help, maybe you should read /var/lib/dpkg/info/frozen-bubble.postrm and if it mentions something about frozen-bubble.wav, you might want to either edit the frozen-bubble.postrm file or remove it entirely.

Last edited by Dead Parrot; 02-27-2005 at 12:14 PM.
 
Old 02-28-2005, 04:06 PM   #11
rossjman1
Member
 
Registered: Oct 2004
Location: Chicago, IL, USA
Distribution: Debian
Posts: 71

Original Poster
Rep: Reputation: 15
Thanks for your help so far.
IGNORE ---------
This is a clip from my /var/lib/dpkg/info/frozen-bubble-data.postrm file. This clip, I think, is the problem. It's in the begining of the file and includes the "mv /usr/games/frozen-bubble.wav" line that has given me errors. However I'm somewhat new to Linux and very new to debian, and dont want to mess things up. Please help me edit this file.
Code:
case "$1" in
       purge|remove|failed-upgrade|abort-install|abort-upgrade|disappear|upgrade)
       mv /usr/games/frozen-bubble.wav /usr/games/frozen-bubble
       dpkg-divert --package frozen-bubble-data --remove /usr/games/frozen-bubble
        ;;

    *)
        echo "postrm called with unknown argument \`$1'" >&2
        exit 1

esac

# dh_installdeb will replace this with shell code automatically
# generated by other debhelper scripts.
END IGNORE ---------

I did the touch command, and it worked!
Code:
root@HP_PAVILION:~# apt-get install frozen-bubble-data
Reading Package Lists... Done
Building Dependency Tree... Done
Recommended packages:
  frozen-bubble
The following packages will be upgraded:
  frozen-bubble-data
1 upgraded, 0 newly installed, 0 to remove and 3 not upgraded.
2 not fully installed or removed.
Need to get 0B/5260kB of archives.
After unpacking 1651kB of additional disk space will be used.
Preconfiguring packages ...
(Reading database ... 109387 files and directories currently installed.)
Preparing to replace console-common 0.7.49 (using .../console-common_0.7.49_all.deb) ...
Unpacking replacement console-common ...
Selecting previously deselected package frozen-bubble-data.
Preparing to replace frozen-bubble-data 1.0.0-4 (using .../frozen-bubble-data_1.0.0-6_all.deb) ...
Unpacking replacement frozen-bubble-data ...
Removing `diversion of /usr/games/frozen-bubble to /usr/games/frozen-bubble.distrib by frozen-bubble-data'
Setting up console-common (0.7.49) ...
Looking for keymap to install:
NONE

Setting up frozen-bubble-data (1.0.0-6) ...

Last edited by rossjman1; 02-28-2005 at 04:26 PM.
 
Old 02-28-2005, 05:00 PM   #12
Dead Parrot
Senior Member
 
Registered: Mar 2004
Distribution: Debian GNU/kFreeBSD
Posts: 1,597

Rep: Reputation: 46
Heh, it appears that the dummy file fooled the post-install script. If Frozen Bubble seems to work all right, then there's no need for any further actions.

It has been said of the ancient Chinese philosopher Confucius: "If the mat was not straight, the Master would not sit." Sometimes APT can be quite Confucian.
 
  


Reply



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
connection to cups server failed only if from server itself in KDE applications kyuso Fedora 0 01-22-2005 10:34 PM
lpd server with CUPS not working Palacista Linux - Software 1 11-11-2004 11:32 AM
remote cups printing to a smb/cups print server? justanothergeek Linux - Networking 2 09-15-2004 08:31 AM
Cannot get CUPS Working! klatu Slackware 3 03-07-2004 06:59 PM
lpr & lpr-cups commands not working with CUPS trinbellwoods Debian 2 01-08-2004 08:25 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 04:38 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
Open Source Consulting | Domain Registration