setup-ds-admin.pl running in silent mode does not fill in FullMachineName nor ServerPort if not specified. If creating the configuration DS, this means the ConfigDirectoryLdapURL will not be filled in with a correct default either.
Created attachment 362703 [details] patch
To ssh://git.fedorahosted.org/git/389/admin.git ec71bac..eb25bdf master -> master commit eb25bdff89df7f3f3a7dc31ffa5d8ac1aaf1cc78 Author: Rich Megginson <rmeggins> Date: Fri Sep 25 11:59:14 2009 -0600 Reviewed by: nkinder (Thanks!) Fix Description: We were not setting a default hostname and port in silent mode. I also fixed a problem with the SysUser setting. Platforms tested: RHEL5 x86_64 Flag Day: no Doc impact: no
Testing : =========== 1. Left blank below fields in inf file : [General] FullMachineName = [admin] Port = [slapd] ServerPort = Executed - [root@amsharma tmp]# setup-ds-admin.pl --silent --file=/home/setupadmin.inf --debug Creating directory server . . . The port is not a valid port. Please choose a valid port. Error: Could not create directory server instance 'amsharma'. Exiting . . . Log file is '/tmp/setuphmKO_g.log' [11/07/28:14:43:06] - [Setup] Info Creating directory server . . . [11/07/28:14:43:06] - [Setup] Info The port is not a valid port. Please choose a valid port. [11/07/28:14:43:06] - [Setup] Fatal Error: Could not create directory server instance 'amsharma'. Please guide here. [11/07/28:14:43:06] - [Setup] Fatal Exiting . . . Log file is '/tmp/setuphmKO_g.log'
(In reply to comment #3) > Testing : > =========== > 1. Left blank below fields in inf file : > [General] > FullMachineName = > [admin] > Port = > [slapd] > ServerPort = I believe you need to not have those parameters in your inf file at all. You are explicitly setting them to an empty value, so that overrides any default you have set. If you remove the parameters from your inf file, the setup script should use the appropriate defaults.
Also note that it does not apply to [admin] Port - only [slapd] ServerPort. If after you take into consideration the comments of Nathan and I, you still have problems/questions, please reproduce the problem with setup-ds-admin.pl and add -ddd to the arguments and attach the output of that to this bug.
Is this bug VERIFIED yet?
Removed FullMachineName = snmaptest.pnq.redhat.com and ServerPort = 389 from inf file . [General] AdminDomain = pnq.redhat.com SuiteSpotGroup = amsharma ConfigDirectoryLdapURL = ldap://snmaptest.pnq.redhat.com:389/o=NetscapeRoot ConfigDirectoryAdminID = admin SuiteSpotUserID = amsharma ConfigDirectoryAdminPwd = Secret123 [admin] ServerAdminID = admin ServerAdminPwd = Secret123 SysUser = amsharma ServerIpAddress = 0.0.0.0 Port = 9830 [slapd] InstallLdifFile = suggest ServerIdentifier = snmaptest AddOrgEntries = Yes RootDN = cn=Directory Manager RootDNPwd = Secret123 SlapdConfigForMC = yes Suffix = dc=example,dc=com UseExistingMC = 0 AddSampleEntries = No Admin server was successfully created, configured, and started. Exiting . . . Log file is '/tmp/setupDxOlz1.log' Hence VERIFIED.