Bug 1247822 - Report an unclear error while set password for a non-exsitent user inside the guest
Report an unclear error while set password for a non-exsitent user inside the...
Status: CLOSED WONTFIX
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: qemu-guest-agent (Show other bugs)
7.2
x86_64 Unspecified
unspecified Severity low
: rc
: ---
Assigned To: Ademar Reis
Virtualization Bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-07-28 22:23 EDT by zhenfeng wang
Modified: 2015-07-30 07:11 EDT (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-07-30 07:11:05 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description zhenfeng wang 2015-07-28 22:23:03 EDT
Description of problem:
Report an unclear error while set password for a non-exsitent user inside the guest

Version-Release number of selected component (if applicable):
kernel-3.10.0-300.el7.x86_64
libvirt-1.2.17-2.el7.x86_64
qemu-kvm-rhev-2.3.0-13.el7.x86_64

guest info
qemu-guest-agent-2.3.0-2.el7.x86_64.rpm

How reproducible:
100%

Steps to Reproduce:
1.Prepare a running guest with guest agent installed
2.Get selinux to permissive mode since bug 1243458 haven't fixed yet
#setenforce 0
# getenforce
Permissive

3.Set password for a non-exsitent user inside the guest, will get an unclear error,this info should be improved

# virsh set-user-password  virt-tests-vm1  --user user1 --password redhat 
error: internal error: unable to execute QEMU agent command 'guest-set-user-password': child process has failed to set user password


Actual results:
report an unclear error while set password for a non-exsitent user inside the guest

Expected results:
should get clear error info, such as "user user1 didn't exsit"

Additional info:
Comment 2 Marc-Andre Lureau 2015-07-30 06:38:15 EDT
this is really minor and perhaps wontfix: if it fails to set password it is very likely because the user didn't exist, so the generic error is enough.

Parsing chpasswd error output is cumbersome and could potentially break on various systems or updates.

Daniel, since you implemented it, I suppose you came to similar conclusion?
Comment 3 Daniel Berrange 2015-07-30 06:53:54 EDT
Yeah, I don't think it is worth the complexity to try to parse chpassword output here, the generic error is sufficient IMHO.
Comment 4 Marc-Andre Lureau 2015-07-30 07:11:05 EDT
agree, let's close as wontfix then

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