Bug 739666 - uuid generation returns NULL on minimal installation profiles
Summary: uuid generation returns NULL on minimal installation profiles
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: matahari
Version: 6.2
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: rc
: ---
Assignee: Russell Bryant
QA Contact: IDM QE LIST
URL:
Whiteboard:
Depends On:
Blocks: 743047
TreeView+ depends on / blocked
 
Reported: 2011-09-19 18:40 UTC by Adam Stokes
Modified: 2011-12-06 11:43 UTC (History)
2 users (show)

Fixed In Version: matahari-0.4.4-4.el6
Doc Type: Bug Fix
Doc Text:
No description required.
Clone Of:
Environment:
Last Closed: 2011-12-06 11:43:15 UTC


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2011:1569 normal SHIPPED_LIVE matahari bug fix and enhancement update 2011-12-06 00:39:06 UTC

Description Adam Stokes 2011-09-19 18:40:30 UTC
Description of problem:
Fresh install of RHEL 6.2 choosing the 'minimal' configuration causes matahari agents who attempt to capture a UUID to return NULL. Since c++ doesn't like this we are hit with an exception

terminate called after throwing an instance of 'std::logic_error'
  what():  basic_string::_S_construct NULL not valid
Aborted


Version-Release number of selected component (if applicable):
0.4.4-x

How reproducible:
100%

Steps to Reproduce:
1. install minimal os
2. install matahari 0.4.4
3. attempt to start an agent where both /etc/machine-id or /var/lib/dbus/machine-id are not present
  
Actual results:
terminate called after throwing an instance of 'std::logic_error'
  what():  basic_string::_S_construct NULL not valid
Aborted


Expected results:
agents to connect to broker

Additional info:
https://github.com/matahari/matahari/blob/master/src/lib/utilities_linux.c#L83

We need to be returning an empty string here.

Comment 1 Dave Johnson 2011-09-19 20:16:07 UTC
This worked for me.  dbus gets installed and creates the machine-id file.

here is the ks file for the install

# Kickstart file automatically generated by anaconda.

#version=DEVEL
install
url --url=http://download.devel.redhat.com/nightly/RHEL6.2-20110919.n.0/6.2/Server/x86_64/os/
lang en_US.UTF-8
keyboard us
network --onboot yes --device eth0 --bootproto dhcp --ipv6 auto
rootpw  --iscrypted $6$DM3EWdHNCJPZUOk7$cVm0siBeU7BicmcsnqtLpOO87WYCdfY8UBWFHCgGhJ96ESWFeogXhQzWpycgBzf/gWiVeU9yxxTRS.tMlO10C0
firewall --service=ssh
authconfig --enableshadow --passalgo=sha512
selinux --enforcing
timezone --utc America/New_York
bootloader --location=mbr --driveorder=sda --append=" rhgb crashkernel=auto quiet"
# The following is the partition information you requested
# Note that any partitions you deleted are not expressed
# here so unless you clear all partitions first, this is
# not guaranteed to work
#clearpart --linux --drives=sda
#volgroup VolGroup --pesize=4096 pv.008002
#logvol / --fstype=ext4 --name=lv_root --vgname=VolGroup --grow --size=1024 --maxsize=51200
#logvol swap --name=lv_swap --vgname=VolGroup --grow --size=1488 --maxsize=2976

#part /boot --fstype=ext4 --size=500
#part pv.008002 --grow --size=1


repo --name="Red Hat Enterprise Linux"  --baseurl=http://download.devel.redhat.com/nightly/RHEL6.2-20110919.n.0/6.2/Server/x86_64/os/ --cost=100

%packages
@core
@server-policy
%end

Comment 2 Russell Bryant 2011-09-19 22:38:50 UTC
Fixed upstream:

https://github.com/matahari/matahari/commit/050aac205efebd2f9779a33605bd88ff3a99da49

This change will ensure the agents don't crash if neither systemd or dbus are installed.  The UUID field will be blank, but at least it doesn't crash ...

Comment 4 Dave Johnson 2011-11-03 22:43:07 UTC
good 2 go with v0.4.4-9

Comment 5 Russell Bryant 2011-11-16 22:27:03 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
No description required.

Comment 6 errata-xmlrpc 2011-12-06 11:43:15 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2011-1569.html


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