Bug 447973
Summary: | running ipa-server-install with bad options produces a 0 return code | ||||||
---|---|---|---|---|---|---|---|
Product: | [Retired] freeIPA | Reporter: | Michael Gregg <mgregg> | ||||
Component: | ipa-server | Assignee: | Rob Crittenden <rcritten> | ||||
Status: | CLOSED ERRATA | QA Contact: | Chandrasekar Kannan <ckannan> | ||||
Severity: | medium | Docs Contact: | |||||
Priority: | high | ||||||
Version: | unspecified | CC: | benl | ||||
Target Milestone: | --- | ||||||
Target Release: | --- | ||||||
Hardware: | All | ||||||
OS: | Linux | ||||||
Whiteboard: | |||||||
Fixed In Version: | freeipa-2.0.0-1.fc15 | Doc Type: | Bug Fix | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | Type: | --- | |||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Bug Depends On: | |||||||
Bug Blocks: | 429034 | ||||||
Attachments: |
|
Description
Michael Gregg
2008-05-22 18:11:15 UTC
What is the bad option in this command-line? It looks ok to me. The hostname is probably not going to work but that is not a bad option. The bad option is the hostname. It's not a full hostname. So when ipa-server-install hits a ERROR, I'd like to see a non-zero result. This is the current output of that string, notice the return code at the bottom: [root@dhcp-114 tmp]# /usr/sbin/ipa-server-install -U --hostname=dhcp-114 -r SJCTEST.REDHAT.COM -p Secret123 -P Secret123 -a Secret123 --setup-bind -u admin -d The log file for this installation can be found in /var/log/ipaserver-install.log root : DEBUG Loading Index file from '/var/lib/ipa/sysrestore/sysrestore.index' ============================================================================== This program will setup the IPA Server. This includes: * Configure the Network Time Daemon (ntpd) * Create and configure an instance of Directory Server * Create and configure a Kerberos Key Distribution Center (KDC) * Configure Apache (httpd) * Configure TurboGears To accept the default shown in brackets, press the Enter key. root : DEBUG Loading StateFile from '/var/lib/ipa/sysrestore/sysrestore.state' root : DEBUG Loading Index file from '/var/lib/ipa/sysrestore/sysrestore.index' root : ERROR Invalid hostname: dhcp-114 Return code: [root@dhcp-114 tmp]# echo $? 0 Created attachment 306415 [details]
Fix up function return values so we can return 1 on an installation error.
ipa-1-0: 4a1862075e88cb48f226bb1c1b575e9484bdd845 master: 927447b144bbe0afd1d099a71dd482f61b431749 ipa-server-install -U --hostname=BOGUSNAME -r BOGUSRELM -p Secret123 -P Secret123 -a Secret123 --setup-bind -u admin -d + ssh root.sjc2.redhat.com ipa-server-install -U --hostname=BOGUSNAME -r BOGUSRELM -p Secret123 -P Secret123 -a Secret123 --setup-bind -u admin -d root : DEBUG Loading Index file from '/var/lib/ipa/sysrestore/sysrestore.index' The log file for this installation can be found in /var/log/ipaserver-install.log ============================================================================== This program will setup the IPA Server. This includes: * Configure the Network Time Daemon (ntpd) * Create and configure an instance of Directory Server * Create and configure a Kerberos Key Distribution Center (KDC) * Configure Apache (httpd) * Configure TurboGears * Configure DNS (bind) To accept the default shown in brackets, press the Enter key. root : ERROR Invalid hostname: BOGUSNAME + ret=1 Verified against: 1.1.0-2.20081119.el5ipa |