HylaFax needs fonts

30 Nov 2011 by David (admin)
Tags: ,
Trying to use HylaFax on CentOS 6, I got the following message:
/usr/sbin/textfmt: No font metric information found for "Courier-Bold".
Usage: /usr/sbin/textfmt [-1] [-2] [-B] [-c] [-D] [-f fontname] [-F fontdir(s)] [-m N] [-o #] [-p #] [-r] [-U] [-Ml=#,r=#,t=#,b=#] [-V #] files... >out.ps
Default options: -f Courier -1 -p 11bp -o 0
Error converting data; command was "/usr/sbin/textfmt -B -f Courier-Bold        -Ml=0.4in -p 11 -s default
This means that the font Courier-Bold is not installed on the system. On my CentOS 6 installation, I got it working by performing the following actions:
  • adding /usr/share/enscript/afm to both FontMap: and FontPath: in /etc/hylafax/hyla.conf
  • run sed -i "s/Courier-Bold/cob/g" /etc/hylafax/typerules
  • also, you need to install the package enscript: yum -y install enscript
© GeekLabInfo

Was this page useful?

Please rate this page and/or leave a comment.
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...

2 Comments

  1. Koray says:

    Can You help me please

    Centos 5 last version

    Uname -a

    2.6.18-274.12.1.el5

    # sed -i "s/Courier-Bold/cob/g" /etc/hylafax/typerules

    # vim /etc/hylafax/hyla.conf

    FontPath: /usr/local/lib/ghostscript/fonts:/usr/share/ghostscript/8.70/Resource/Init:/usr/share/ghostscript/8.70/lib:/usr/share/ghostscript
    /8.70/Resource/Font:/usr/share/ghostscript/fonts:/usr/share/fonts/default/ghostscript:/usr/share/fonts/default/Type1:/usr/share/fonts/default/amspsfnt/pfb:/usr/share/fonts/default/cmpsfont/pfb:/usr/share/fonts/japanese:/etc/ghostscript:/usr/share/enscript/afm
    #FontPath: /usr/share/fonts/default/Type1
    FontMap: /usr/share/ghostscript/8.70/lib:/usr/share/enscript/afm

    # ls /usr/share/enscript/afm

    -rw-r--r-- 1 root root 18K 2008-10-29 00:44 agd.afm
    -rw-r--r-- 1 root root 18K 2008-10-29 00:44 agdo.afm
    -rw-r--r-- 1 root root 18K 2008-10-29 00:44 agw.afm
    -rw-r--r-- 1 root root 18K 2008-10-29 00:44 agwo.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 bkd.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 bkdi.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 bkl.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 bkli.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 cob.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 cobo.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 com.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 coo.afm
    -rw-r--r-- 1 root root 1.4K 2008-10-29 00:44 font.map
    -rw-r--r-- 1 root root 19K 2008-10-29 00:44 hv.afm
    -rw-r--r-- 1 root root 18K 2008-10-29 00:44 hvb.afm
    -rw-r--r-- 1 root root 18K 2008-10-29 00:44 hvbo.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 hvc.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 hvcb.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 hvcbo.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 hvcdo.afm
    -rw-r--r-- 1 root root 18K 2008-10-29 00:44 hvn.afm
    -rw-r--r-- 1 root root 18K 2008-10-29 00:44 hvnb.afm
    -rw-r--r-- 1 root root 18K 2008-10-29 00:44 hvnbo.afm
    -rw-r--r-- 1 root root 19K 2008-10-29 00:44 hvno.afm
    -rw-r--r-- 1 root root 19K 2008-10-29 00:44 hvo.afm
    -rw-r--r-- 1 root root 12K 2008-10-29 00:44 matrix.afm
    -rw-r--r-- 1 root root 56K 2008-10-29 00:44 matrix.pfa
    -rw-r--r-- 1 root root 17K 2008-10-29 00:44 ncb.afm
    -rw-r--r-- 1 root root 18K 2008-10-29 00:44 ncbi.afm
    -rw-r--r-- 1 root root 18K 2008-10-29 00:44 nci.afm
    -rw-r--r-- 1 root root 17K 2008-10-29 00:44 ncr.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 pob.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 pobi.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 poi.afm
    -rw-r--r-- 1 root root 16K 2008-10-29 00:44 por.afm
    -rw-r--r-- 1 root root 9.7K 2008-10-29 00:44 sy.afm
    -rw-r--r-- 1 root root 19K 2008-10-29 00:44 tib.afm
    -rw-r--r-- 1 root root 19K 2008-10-29 00:44 tibi.afm
    -rw-r--r-- 1 root root 19K 2008-10-29 00:44 tii.afm
    -rw-r--r-- 1 root root 19K 2008-10-29 00:44 tir.afm
    -rw-r--r-- 1 root root 17K 2008-10-29 00:44 zcmi.afm
    -rw-r--r-- 1 root root 9.5K 2008-10-29 00:44 zd.afm

    ERROR LOG

    Command died with status 255:
    "/usr/bin/faxmail". Command output: Font Courier:
    /usr/share/enscript/afm/Courier: Can not open font metrics file; using
    fixed widths. Font Helvetica-Bold: /usr/share/enscript/afm/Helvetica-Bold:
    Can not open font metrics file; using fixed widths. Font Helvetica-Oblique:
    /usr/share/enscript/afm/Helvetica-Oblique: Can not open font metrics file;
    using fixed widths. faxmail: listen: Permission denied

  2. David (admin) says:

    Hi Koray,

    Please post the output of:
    grep -viE "^#" /etc/hylafax/typerules

    I'm running CentOS 6, my instructions may not work on CentOS 5. But let's see.

    I first thought of a permissions problem, but now I'm not so sure. But it's worth a shot. Do you have SELinux running? Don't permanently switch off SELinux, but you can disable it temporarily to debug.
    1. See the status by running sestatus
    2. Temporarily disable it by running setenforce 0
    3. Test faxmail again
    4. Re-enable security by running setenforce 1
    If it works with a disabled SELinux, you can write custom SELinux rules.

    What is the output of ls -aslZ /usr/bin/faxmail

Leave a Reply

Pages

Search

Tags

3com 4250T 5216k access point acpi Acrobat Active Directory AD ad-hoc wifi Adobe Apache Asterisk Asterisk 1.8 autorepair backdoor barcode bash bat batch Belkin bios bootloader CentOS CentOS 5 CentOS 6 certificates checksum cmos console access cookies CUPS database databases Dead default password Dell dhcp digital invoice dns dnsmasq dovecot Dymo dynamic dns dyndns e-commerce EAN13 Esx Esx4 Exchange Exchange 2007 fax Fedora Fedora 13 Fedora 15 Fedora 16 Firefox firewall firmware fix FoIP fonts ftp fuckup ghostscript Google Google apps Google Chrome Google Maps Google Talk GPO grub gvfs-open H200 hibernation http hushlogin initrd internet explorer iproute2 iptables IPv6 jQuery KB953297 KB974417 KBsomething KDE Konsole layer8 LDAP ldifde Linux login Lovelock lpd magento mkinitrd mplayer ms office ms office 2010 mysql Nagios networking NetworkManager NoteToSelf NTLM nullmodem nvram Omniview OpenSSL openvpn password patch pcl pdf PERC PHP Postfix PostScript preload printer privacy proxy pstn pureftpd pxe rant reboot RedHat remote remote wipe reset password Review root root access route router rpm Samba Samsung Galaxy S2 scripting securit security SELinux Sendmail SEO Servicetag shutdown SMTP socat software deployment Spam speed-up SQL Server Express squid ssh SSL starttls stupid switch sysinternals syslinux talk tftp thawte Thunderbird Trend Micro updates v4l v4l2 vdr viclient video VMWare VMWare Data Recovery vnc voice voip vpn vSphere vsphere client wbinfo webapps webcam wf.msc wifi winbind Windows Windows 7 Windows 2003 Windows 2008 SBS windows internal database Windows Updates Windows XP wmic WordPress WordPress plugins wscript WSUS wsusutil WYukon