Bug 571653 - wrong parameter for useradd
Summary: wrong parameter for useradd
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora EPEL
Classification: Fedora
Component: mock
Version: el5
Hardware: All
OS: Linux
low
urgent
Target Milestone: ---
Assignee: David Cantrell
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 565181
TreeView+ depends on / blocked
 
Reported: 2010-03-09 07:03 UTC by Frank Büttner
Modified: 2013-01-10 05:45 UTC (History)
4 users (show)

Fixed In Version: mock-1.0.7-1.el5
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-03-10 07:03:15 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Frank Büttner 2010-03-09 07:03:54 UTC
Description of problem:
After update to the last version an build of packages is imposable 

Version-Release number of selected component (if applicable):
mock-1.0.5-1.el5

How reproducible:
everytime

Steps to Reproduce:
1. run mock with "mock -r epel-5-x86_64 pathToSRPM"
  
Actual results:
get the error:
ERROR: Command failed. See logs for output.
 # /usr/sbin/useradd -o -m -u 500 -g 109 -d /builddir -N mockbuild


Expected results:
working build

Comment 1 Frank Büttner 2010-03-09 07:05:08 UTC
locking at the log files I see:
DEBUG util.py:280:  Executing command: /usr/sbin/useradd -o -m -u 500 -g 109 -d /builddir -N mockbuild
DEBUG util.py:256:  /usr/sbin/useradd: Ungültige Option -- N
DEBUG util.py:256:  Usage: useradd [options] LOGIN
DEBUG util.py:256:  Options:
DEBUG util.py:256:    -b, --base-dir BASE_DIR   base directory for the new user account
DEBUG util.py:256:                              home directory
DEBUG util.py:256:    -c, --comment COMMENT             set the GECOS field for the new user account
DEBUG util.py:256:    -d, --home-dir HOME_DIR   home directory for the new user account
DEBUG util.py:256:    -D, --defaults            print or save modified default useradd
DEBUG util.py:256:                              configuration
DEBUG util.py:256:    -e, --expiredate EXPIRE_DATE      set account expiration date to EXPIRE_DATE
DEBUG util.py:256:    -f, --inactive INACTIVE   set password inactive after expiration
DEBUG util.py:256:                              to INACTIVE
DEBUG util.py:256:    -g, --gid GROUP           force use GROUP for the new user account
DEBUG util.py:256:    -G, --groups GROUPS               list of supplementary groups for the new
DEBUG util.py:256:                              user account
DEBUG util.py:256:    -h, --help                        display this help message and exit
DEBUG util.py:256:    -k, --skel SKEL_DIR               specify an alternative skel directory
DEBUG util.py:256:    -K, --key KEY=VALUE               overrides /etc/login.defs defaults
DEBUG util.py:256:    -m, --create-home         create home directory for the new user
DEBUG util.py:256:                              account
DEBUG util.py:256:    -l,                       do not add user to lastlog database file
DEBUG util.py:256:    -M,                       do not create user's home directory(overrides /etc/login.defs)
DEBUG util.py:256:    -r,                       create system account
DEBUG util.py:256:    -o, --non-unique          allow create user with duplicate
DEBUG util.py:256:                              (non-unique) UID
DEBUG util.py:256:    -p, --password PASSWORD   use encrypted password for the new user
DEBUG util.py:256:                              account
DEBUG util.py:256:    -s, --shell SHELL         the login shell for the new user account
DEBUG util.py:256:    -u, --uid UID                     force use the UID for the new user account
DEBUG util.py:256:    -Z, --selinux-user SEUSER use a specific SEUSER for the SELinux user mapping
DEBUG util.py:319:  Child returncode was: 2

Comment 2 Jesse Keating 2010-03-09 15:36:58 UTC
Do you have custom epel configs, that have a .rpmnew file sitting next to them?  The useradd default was either wrong for Fedora, or wrong for EL, so we changed the default and overrode the default in the epel config files we ship.

Comment 3 Frank Büttner 2010-03-10 07:03:15 UTC
Hello,
yes there was an rpnew file.
And after add the line
"config_opts['useradd'] = '/usr/sbin/useradd -m -u %(uid)s -g %(gid)s -d %(home)s -n %(user)s'"
to the old one, all will be work again.
Thanks.

Comment 4 Fedora Update System 2010-03-11 22:28:09 UTC
mock-1.0.7-1.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/mock-1.0.7-1.el5

Comment 5 Fedora Update System 2010-04-26 23:26:30 UTC
mock-1.0.7-1.el5 has been pushed to the Fedora EPEL 5 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.