Hylafax Mailing List Archives

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [hylafax-users] Caldera faxsetup problem with useradd




Try this patch. It's a start.
It will work for most cases but I havent' had time to finish it.

On Fri, 8 Sep 2000, Lee Howard wrote:

> I'm testing HylaFAX on Caldera OpenLinux eServer 2.3, and I'm having the
> following error when I run faxsetup:
> ------------------------
> You do not appear to have a "fax" user in the password file.
> HylaFAX needs this to work properly, add it [yes]?
> 
> There was a problem adding user "fax" to /etc/passwd;
> the command failed with:
> 
> "useradd: illegal option -- o
> usage:  useradd [-u uid] [-g group] [-m] [-d home] [-s shell] [-r rootdir]
>                 [-e expire dd/mm/yyyy] [-f inactive] name
>         useradd -D
>         useradd -v "
> 
> HylaFAX will not work until you have corrected this problem.
> ------------------------
> It appears that Caldera uses a different useradd than others (i.e. RedHat).
>  Caldera's useradd options are:
> 
> [root@metroid hylafax]# useradd
> usage:  useradd [-u uid] [-g group] [-m] [-d home] [-s shell] [-r rootdir]
>                 [-e expire dd/mm/yyyy] [-f inactive] name
>         useradd -D
>         useradd -v
> [root@metroid hylafax]# useradd -v
> useradd version 1.7
> [root@metroid hylafax]#
> 
> Has anybody encountered this already and made a fix?  I did search through
> the archives.  It works just fine if you 'useradd fax' and *then* run
> faxsetup and allow it to adjust the user settings.  It would be nice if
> this worked without the (minimal, yes) hassle, though.
> 
> Lee Howard
> 
> 
> 
> ____________________ HylaFAX(tm) Users Mailing List _______________________
>  To unsub: mail -s unsubscribe hylafax-users-request@hylafax.org < /dev/null
> 

-- 
Tim Rice				Multitalents	(707) 887-1469
tim@multitalents.net
tim@trr.metro.net
*** hylafax/etc/faxsetup.linux.old	Fri Jun  2 18:42:36 2000
--- hylafax/etc/faxsetup.linux	Fri Jun  2 18:35:08 2000
***************
*** 30,51 ****
  # Linux-specific definitions for faxsetup.
  #
  
! addPasswd()
! {
!     useradd -m -c 'Facsimile Agent' -d $4 -u $2 -o -g $3 $1
! }
! deletePasswd()
! {
!     userdel -r $1
! }
! lockPasswd()
! {
!     return 0
! }
! modifyPasswd()
! {
!     usermod -d $4 -m -u $2 -o -g $3 $1
! # NB: we must do it twice to keep Linux happy if the
! #     home directory allready exists
!     usermod -d $4 -m -u $2 -o -g $3 $1
! }
--- 30,64 ----
  # Linux-specific definitions for faxsetup.
  #
  
! if [ -f /usr/sbin/pwconv ]; then
!     addPasswd()
!     {
! 	echo "${1}:NOLOGIN:${2}:${3}:Facsimile Agent:${4}:/bin/false" >> ${PASSWD}
! 	/usr/sbin/pwconv
!     }
!     lockPasswd()
!     {
! 	return 0			# entries are always locked
!     }
! else
!     addPasswd()
!     {
!     echo "how did it read this file?"
! 	useradd -m -c 'Facsimile Agent' -d $4 -u $2 -o -g $3 $1
!     }
!     deletePasswd()
!     {
! 	userdel -r $1
!     }
!     lockPasswd()
!     {
! 	return 0
!     }
!     modifyPasswd()
!     {
! 	usermod -d $4 -m -u $2 -o -g $3 $1
!     # NB: we must do it twice to keep Linux happy if the
!     #     home directory allready exists
! 	usermod -d $4 -m -u $2 -o -g $3 $1
!     }
! fi


Home
Report any problems to webmaster@hylafax.org

HylaFAX is a trademark of Silicon Graphics Corporation.
Internet connectivity for hylafax.org is provided by:
VirtuALL Private Host Services