Can't log in to CUPS admin

Asked by Alf Haakon Lund on 2013-12-17

While trying to install my printer, a Brother MFC-J4510DW, on Ubuntu Studio 13.10 I completely fail to log in to CUPS admin pages at http://localhost:631/printers/

I tried my username and password (there is one user on the system).

I edited /etc/cups/cupsd.conf:
    added Allow localhost under <Location /admin/> and <Location /admin/conf>
    at <Location /admin/conf> I changed Require user @SYSTEM
        (there is no group called SYSTEM available to me)
        to Require user @lpadmin

I suspect my problems might be related to the printer driver installation. I got the printer drivers from here: http://welcome.solutions.brother.com/bsc/public_s/id/linux/en/download_prn.html#MFC-J4510DW

I checked dependencies and installed lib32stdc++ as requested by "my brother" (installed both lib32stdc++4.8-dev and lib32stdc++6-4.7-dev as I have no idea what is the difference between them).

The driver debs I installed through Ubuntu Software Center, having to ignore a warning about bad quality (E: mfcj4510dwlpr: maintainer-address-missing Brother Industries, Ltd.). However, after install, the package didn't show as installed, the button in USC still said 'install'. But with dpkg -l | grep Brother it seems to be installed anyway. I made sure to install the lpr driver before the cupswrapper as per install instructions on brother's website.

The printer shows as installed and I can print a test page, but neither through http://localhost:631/printers/ (can't log in as described above) or the printers dialogue ('apply' button is grey) am I able to change printer settings.

Thankful for any and all input on this headache!

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu cups Edit question
Assignee:
No assignee Edit question
Solved by:
Alf Haakon Lund
Solved:
2013-12-20
Last query:
2013-12-20
Last reply:
2013-12-17
Manfred Hampl (m-hampl) said : #1

Maybe the terminal command

sudo system-config-printer

helps.

Alf Haakon Lund (alf-c) said : #2

Thank you for answering, but sorry: The command doesn't help. I still cannot change settings.

Please don't run GUI applications with sudo. Please use and advise gksudo. It sets up the environment correctly and does not break files in the OS.

If you run:

gksudo firefox http://localhost:631

Does it work ok?

Also what is the output of :

lsb_release -a; uname -a; groups

Thanks

Alf Haakon Lund (alf-c) said : #5

Thanks you for answering!

Output of lsb_release:

No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 13.10
Release: 13.10
Codename: saucy
Linux musikkmaskinen 3.11.0-14-lowlatency #6-Ubuntu SMP PREEMPT Wed Nov 20 23:59:04 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux
username adm cdrom sudo audio dip plugdev lpadmin sambashare

gksudo firefox http://localhost:631 does not enable me to edit config files - I still cannot log in.

For some reason gksudo had to be installed manually. Does XCFE use something else by default?

I reverted to the original config file, but still no luck. /etc/cups/cupsd.conf says 'Require user @OWNER @SYSTEM' or 'Require user @SYSTEM' in all sections regarding authentication. Do I have to change these values? And if I have to, why doesn't the default installation 'just work'?

I'll check my file later and give you a link to download mine.
Gimme an hour or so

Alf Haakon Lund (alf-c) said : #7

I uninstalled the drivers and reinstalled from command line, getting these messages:

mkdir: cannot create directory ‘/var/spool/lpd/mfcj4510dw’: No such file or directory
chown: cannot access ‘/var/spool/lpd/mfcj4510dw’: No such file or directory
chgrp: cannot access ‘/var/spool/lpd/mfcj4510dw’: No such file or directory
chmod: cannot access ‘/var/spool/lpd/mfcj4510dw’: No such file or directory

Created /var/spool/lpd and installed again, without error messages. Printer shows in cups and print dialogue, but still no go on changing printer settings.

/var/spool/cups is owned by root, shows group lp 'none' and 'none' for the rest. Could this be the cause?

andy@fileserver:~$ ls -l /etc/cups/cupsd.conf
-rw-r--r-- 1 root root 4617 May 13 2013 /etc/cups/cupsd.conf

https://dl.dropboxusercontent.com/u/8850924/cupsd.conf

That's my cupsd.conf file. I have not manually edited it myself. Hope this helps

Alf Haakon Lund (alf-c) said : #9

For unrelated reasons I had to shut down my laptop and leave it for a couple of days. When restarting, I tried again and... (drum roll)... Now it works. No updates, nothing, just restarting. I'm happy about that, but I feel none the wiser. I guess I was too stressed to remember rebooting was an option.

So restarting CUPS through sudo /etc/init.d/cups restart didn't do the trick, the machine had to reboot. Graargh.

Merry X-mas to all you guys, and thanks again for providing help.