useradd doesn't add the default shell to /etc/passwd entry
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
shadow (Ubuntu) |
Fix Released
|
Medium
|
Unassigned | ||
Trusty |
Triaged
|
Medium
|
Unassigned |
Bug Description
useradd is not honoring the default shell listed in /etc/defaults/
useradd -D showing the defaults. SHELL=/bin/bash
# useradd -D
GROUP=100
HOME=/home
INACTIVE=-1
EXPIRE=
SHELL=/bin/bash
SKEL=/etc/skel
CREATE_
Using useradd to create user test1. The /etc/passwd entry has a blank shell field:
# useradd test1
# grep test1 /etc/passwd
test1:x:
Using useradd -s does populate the shell field:
# useradd -s /bin/bash test2
#grep test2 /etc/passwd
test2:x:
Why useradd instead of adduser: puppet uses useradd to do user creation.
ProblemType: Bug
DistroRelease: Ubuntu 14.04
Package: passwd 1:4.1.5.1-1ubuntu9
ProcVersionSign
Uname: Linux 3.13.0-24-generic x86_64
ApportVersion: 2.14.1-0ubuntu3
Architecture: amd64
Date: Wed May 21 17:51:57 2014
Ec2AMI: ami-42dc302a
Ec2AMIManifest: (unknown)
Ec2Availability
Ec2InstanceType: m3.large
Ec2Kernel: aki-919dcaf8
Ec2Ramdisk: unavailable
ProcEnviron:
TERM=xterm
PATH=(custom, no user)
LANG=en_US.UTF-8
SHELL=/bin/bash
SourcePackage: shadow
UpgradeStatus: No upgrade log present (probably fresh install)
mtime.conffile.
Related branches
- Serge Hallyn: Approve
-
Diff: 106 lines (+22/-27)2 files modifieddebian/changelog (+7/-0)
debian/patches/1000_configure_userns (+15/-27)
Status changed to 'Confirmed' because the bug affects multiple users.