summaryrefslogtreecommitdiffstats
path: root/ipaserver/install/server
diff options
context:
space:
mode:
Diffstat (limited to 'ipaserver/install/server')
-rw-r--r--ipaserver/install/server/install.py14
-rw-r--r--ipaserver/install/server/replicainstall.py43
2 files changed, 57 insertions, 0 deletions
diff --git a/ipaserver/install/server/install.py b/ipaserver/install/server/install.py
index 6644a6b31..2ef9bdb76 100644
--- a/ipaserver/install/server/install.py
+++ b/ipaserver/install/server/install.py
@@ -609,6 +609,20 @@ def install_check(installer):
not installer.interactive, False,
options.ip_addresses)
+ for ip in ip_addresses:
+ if ip.is_network_addr():
+ root_logger.warning("IP address %s might be network address", ip)
+ # fixme: once when loggers will be fixed, we can remove this print
+ print(
+ "WARNING: IP address {} might be network address".format(ip),
+ file=sys.stderr)
+ if ip.is_broadcast_addr():
+ root_logger.warning("IP address %s might be broadcast address", ip)
+ # fixme: once when loggers will be fixed, we can remove this print
+ print(
+ "WARNING: IP address {} might be broadcast address".format(ip),
+ file=sys.stderr)
+
# installer needs to update hosts file when DNS subsystem will be
# installed or custom addresses are used
if options.ip_addresses or options.setup_dns:
diff --git a/ipaserver/install/server/replicainstall.py b/ipaserver/install/server/replicainstall.py
index c73600cca..5edc0021b 100644
--- a/ipaserver/install/server/replicainstall.py
+++ b/ipaserver/install/server/replicainstall.py
@@ -13,6 +13,7 @@ import dns.reversename as dnsreversename
import os
import shutil
import socket
+import sys
import tempfile
import six
@@ -735,6 +736,28 @@ def install_check(installer):
config.host_name, not installer.interactive, False,
options.ip_addresses)
+ for ip in config.ips:
+ if ip.is_network_addr():
+ root_logger.warning(
+ "IP address %s might be network address", ip)
+ # fixme: once when loggers will be fixed, we can remove this
+ # print
+ print(
+ "WARNING: IP address {} might be network address".format(
+ ip),
+ file=sys.stderr
+ )
+ if ip.is_broadcast_addr():
+ root_logger.warning(
+ "IP address %s might be broadcast address", ip)
+ # fixme: once when loggers will be fixed, we can remove this
+ # print
+ print(
+ "WARNING: IP address {} might be broadcast address".format(
+ ip),
+ file=sys.stderr
+ )
+
except errors.ACIError:
raise ScriptError("\nThe password provided is incorrect for LDAP server "
"%s" % config.master_host_name)
@@ -1306,6 +1329,26 @@ def promote_check(installer):
config.host_name, not installer.interactive,
False, options.ip_addresses)
+ for ip in config.ips:
+ if ip.is_network_addr():
+ root_logger.warning(
+ "IP address %s might be network address", ip)
+ # fixme: once when loggers will be fixed, we can remove this
+ # print
+ print(
+ "WARNING: IP address {} might be network address".format(
+ ip), file=sys.stderr
+ )
+ if ip.is_broadcast_addr():
+ root_logger.warning(
+ "IP address %s might be broadcast address", ip)
+ # fixme: once when loggers will be fixed, we can remove this
+ # print
+ print(
+ "WARNING: IP address {} might be broadcast address".format(
+ ip), file=sys.stderr
+ )
+
except errors.ACIError:
raise ScriptError("\nInsufficient privileges to promote the server.")
except errors.LDAPError: