faxadduser doesn't write in hosts.hfaxd

Bug #477478 reported by Alessandro Ranellucci
42
This bug affects 8 people
Affects Status Importance Assigned to Milestone
hylafax (Ubuntu)
Fix Released
Undecided
Giuseppe Sacco

Bug Description

The Hylafax package shipped with Ubuntu 9.10 freshly installed (2:6.0.3-2ubuntu1) seems to have something broken with the hosts.hfaxd file.

1) If I populate it manually (for example by putting 127.0.0.1 into it), programs like faxstat ignore it and keep requesting a password.

2) If I run the command faxadduser (with or without arguments), then hosts.hfaxd is emptied and nothing is written to it. No errors are returned.

I can't find anything in the logs. I found the same report in a forum from a user who upgraded his Ubuntu to 9.10.

Revision history for this message
Alessandro Ranellucci (aar) wrote :

Just to make it clear, this is the problem:

root@intranet:/etc/hylafax# faxadduser -a pwd admin
root@intranet:/etc/hylafax# cat /etc/hylafax/hosts.hfaxd
root@intranet:/etc/hylafax# cat /var/spool/hylafax/etc/hosts.hfaxd
root@intranet:/etc/hylafax#

Revision history for this message
Alessandro Ranellucci (aar) wrote :
Download full text (14.2 KiB)

root@intranet:/etc/hylafax# uname -a
Linux intranet 2.6.31-14-generic #48-Ubuntu SMP Fri Oct 16 14:05:01 UTC 2009 x86_64 GNU/Linux

root@intranet:/etc/hylafax# ls -la /etc/hylafax/hosts.hfaxd
-rw-rw-rw- 1 uucp uucp 0 2009-11-10 10:43 /etc/hylafax/hosts.hfaxd
root@intranet:/etc/hylafax# ls -la /var/spool/hylafax/etc/hosts.hfaxd
-rw-rw-rw- 1 uucp uucp 0 2009-11-10 10:43 /var/spool/hylafax/etc/hosts.hfaxd

root@intranet:/etc/hylafax# strace faxadduser -a pwd admin
execve("/usr/sbin/faxadduser", ["faxadduser", "-a", "pwd", "admin"], [/* 20 vars */]) = 0
brk(0) = 0x6c9000
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f9337783000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f9337781000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/usr/lib/hylafax/tls/x86_64/libcrypt.so.1", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/usr/lib/hylafax/tls/x86_64", 0x7fffc8bc6c90) = -1 ENOENT (No such file or directory)
open("/usr/lib/hylafax/tls/libcrypt.so.1", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/usr/lib/hylafax/tls", 0x7fffc8bc6c90) = -1 ENOENT (No such file or directory)
open("/usr/lib/hylafax/x86_64/libcrypt.so.1", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/usr/lib/hylafax/x86_64", 0x7fffc8bc6c90) = -1 ENOENT (No such file or directory)
open("/usr/lib/hylafax/libcrypt.so.1", O_RDONLY) = -1 ENOENT (No such file or directory)
stat("/usr/lib/hylafax", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
open("/etc/ld.so.cache", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=54512, ...}) = 0
mmap(NULL, 54512, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f9337773000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/lib/libcrypt.so.1", O_RDONLY) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0P\n\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=43296, ...}) = 0
mmap(NULL, 2326976, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f933732d000
mprotect(0x7f9337336000, 2097152, PROT_NONE) = 0
mmap(0x7f9337536000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x9000) = 0x7f9337536000
mmap(0x7f9337538000, 184768, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f9337538000
close(3) = 0
open("/usr/lib/hylafax/libhylafax-6.0.so.3", O_RDONLY) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\200\237\2\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=524208, ...}) = 0
mmap(NULL, 2620176, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f93370ad000
mprotect(0x7f9337127000, 2097152, PROT_NONE) = 0
mmap(0x7f9337327000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x7a000) = 0x7f9337327000
close(3) = 0
open("/usr/lib/hylafax/libtiff.so.4", O_RDONLY) = -1 ENOENT (No such file or directory)
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (...

Revision history for this message
Ponder One (pondero) wrote :

I have the same exactly the same problem

Revision history for this message
antonio parrilli (antonio-parrilli) wrote :

I have the same problem, too.

who have an idea, when this bug will be fixed?

Revision history for this message
ronzo (ronaldw) wrote :

Same problem here on Ubuntu Karmic Server 64bit.

Revision history for this message
ronzo (ronaldw) wrote :

This bug was initially filed in November 2009. Why isn't there any reaction of the package maintainer or another ubuntu team member?

Revision history for this message
Alessandro Ranellucci (aar) wrote :

Greetings. The bug was discussed on the HylaFAX mailing list. See this thread:

http://groups.google.com/group/fa.hylafax/browse_thread/thread/9b97221987042924

I don't remember how I worked around it. I probably populated the hosts.hfaxd file manually.

Revision history for this message
ronzo (ronaldw) wrote :

Hi Alessandro,

populating the file manually works perfectly. What i did was a

faxuser -f ~/hosts.hfaxd -otheroptions

and copied the generated file over /etc/hylafax/hosts.hfaxd.

Revision history for this message
sebele67 (sebastien-famille-berger) wrote :

Hi everybody,

I'm just finished doing some tests with my avantfax and hylafax system.

I saw that when you use -f option the file you declare in option was written as well as the original file hosts.hfaxd

My workaround is to set in avantfax $FAXADDUSER to 'faxadduser -f /opt/faxuser' with this the two files are written.

Revision history for this message
franz-unix (franz-unix) wrote :

Same problem on Ubuntu Lucid 64 bit with hylafax package present in the repository

Changed in hylafax (Ubuntu):
status: New → Confirmed
assignee: nobody → Giuseppe Sacco (giuseppe-eppesuigoccas)
Revision history for this message
Giuseppe Sacco (eppesuig) wrote :
Revision history for this message
Giuseppe Sacco (eppesuig) wrote :

I am closing this bug report since I received a confirmation that new packages works on Ubuntu too. For any other architecture you may download the relevant packages from Debian archive.

Changed in hylafax (Ubuntu):
status: Confirmed → Fix Released
Revision history for this message
Alessandro Ranellucci (aar) wrote : Re: [Bug 477478] Re: faxadduser doesn't write in hosts.hfaxd

On 11/08/2010 at 20:25, Giuseppe Sacco wrote:

  >I fixed the problem on Debian. Could you try if this works on Ubuntu
  >without rebuilding it?
  >http://eppesuigoccas.homedns.org/~giuseppe/debian/hylafax-client_6.0.4
  >- 9_i386.deb
  >http://eppesuigoccas.homedns.org/~giuseppe/debian/hylafax-server_6.0.4
  >- 9_i386.deb

Hi, thanks for your bugfix. However, I don't have a Ubuntu box
available right now to test your package. :/

     - alessandro.

Revision history for this message
Paul McNett (root-paulmcnett) wrote :

I'm commenting on this here just in case it helps someone else out. Running Ubuntu 10.04, upgraded from 8.04 and initially hylafax was working great. Then I noticed the following symptoms appeared, probably after restarting hylafax:

+ Every time I start hylafax, a new mount point is created /etc/hylafax <-> /var/spool/hylafax/etc. IOW, it isn't unmounted when the service is stopped.

+ Something changed the permissions of /etc/hosts.hfaxd from uucp:uucp rw------- to root:root rw-r--r--

+ Running faxstat or sendfax like I used to do without a password now results in password prompts, and trying all kinds of things in /etc/hosts.hfaxd didn't help.

Turns out, the changed permissions were the culprit. As soon as I umounted all those extra mounts, changed the permissions back to uucp:uucp rw------, and restarted the service, I could once again interact with sendfax and faxstat without entering a password, because of my localhost entry in /etc/hosts.hfaxd.

I'm also having the faxadduser problem, but have worked around it as I really don't need it in my configuration by editing /var/www/avantfax/include/config.php and changing the $FAXADDUSER cmd to 'faxadduser -f /tmp/bogus'. I need my users managed in the MySQL Avantfax database but I only need the localhost entry in /etc/hosts.hfaxd.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.