此内容没有您所选择的语言版本。
3.3. Example: Running the Script Interactively and Silently
3.3.1. Basic Interactive Installation 复制链接链接已复制到粘贴板!
复制链接链接已复制到粘贴板!
All that is required to set up an IdM server is to run the
ipa-server-install
script. This launches the script interactively, which prompts for the required information to set up a server, but without more advanced configuration like DNS and CA options.
- Run the
ipa-server-install
script.ipa-server-install
[root@server ~]# ipa-server-install
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Enter the hostname. This is determined automatically using reverse DNS.
Server host name [ipaserver.example.com]:
Server host name [ipaserver.example.com]:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Enter the domain name. This is determined automatically based on the hostname.
Please confirm the domain name [example.com]:
Please confirm the domain name [example.com]:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Enter the new Kerberos realm name. This is usually based on the domain name.
Please provide a realm name [EXAMPLE.COM]:
Please provide a realm name [EXAMPLE.COM]:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Enter the password for the Directory Server superuser,
cn=Directory Manager
. There are password strength requirements for this password, including a minimum password length (eight characters).Directory Manager password: Password (confirm):
Directory Manager password: Password (confirm):
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Enter the password for the IdM system user account,
admin
. This user is created on the machine.IPA admin password: Password (confirm):
IPA admin password: Password (confirm):
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - The script then reprints the hostname, IP address, and domain name. Confirm that the information is correct.
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - After that, the script configures all of the associated services for IdM, with task counts and progress bars.
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Restart the
SSH
service to retrieve the Kerberos principal and to refresh the name server switch (NSS) configuration file:service sshd restart
[root@server ~]# service sshd restart
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Authenticate to the Kerberos realm using the admin user's credentials to ensure that the user is properly configured and the Kerberos realm is accessible.
kinit admin
[root@server ~]# kinit admin Password for admin@EXAMPLE.COM:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Test the IdM configuration by running a command like
ipa user-find
. For example:Copy to Clipboard Copied! Toggle word wrap Toggle overflow
3.3.2. Silent (Non-Interactive) Installation 复制链接链接已复制到粘贴板!
复制链接链接已复制到粘贴板!
As shown in Section 3.3.1, “Basic Interactive Installation”, only a few pieces of information are required to configure an IdM server. While the setup script can prompt for this information in interactive mode, this information can also be passed with the setup command to allow automated and unattended configuration:
- Passwords for the IdM administrative user and the Directory Server super user (Directory Manager)
- The server hostname
- The Kerberos realm name
- The DNS domain name
This information can be passed with the
ipa-server-install
, along with the -U
to force it to run without requiring user interaction.
Example 3.1. Basic Installation without Interaction
ipa-server-install -a secret12 --hostname=ipaserver.example.com -r EXAMPLE.COM -p secret12 -n example.com -U
[root@server ~]# ipa-server-install -a secret12 --hostname=ipaserver.example.com -r EXAMPLE.COM -p secret12 -n example.com -U
The script then prints the submitted values:
The server name must be a valid DNS name, which means only numbers, alphabetic characters, and hyphens (-) are allowed. Other characters, like underscores, in the hostname will cause DNS failures. Additionally, the hostname must be all lower-case. No capital letters are allowed.
Then the script runs through the configuration progress for each IdM service, as in Section 3.3.1, “Basic Interactive Installation”.