.. _installer: Deploy from Console Installer --------------------------------------------------------------- To deploy FindFace Multi, use a developer-friendly console installer. .. tip:: Before deployment, be sure to consult the :ref:`system requirements `. .. important:: The FindFace Multi host must have a static IP address in order to be running successfully. To make the IP address static, open the ``/etc/network/interfaces`` file and modify the current primary network interface entry as shown in the case study below. Be sure to substitute the suggested addresses with the actual ones, subject to your network specification. .. code:: sudo vi /etc/network/interfaces iface eth0 inet static address 192.168.112.144 netmask 255.255.255.0 gateway 192.168.112.254 dns-nameservers 192.168.112.254 Restart networking. .. code:: sudo service networking restart Be sure to edit the ``etc/network/interfaces`` file with extreme care. Please refer to the Ubuntu `guide on networking `_ before proceeding. To deploy FindFace Multi from the console installer, do the following: #. Download the installer file ``findface-multi-1.1-and-server-5.1.run``. #. Put the ``.run`` file into some directory on the designated host (for example, ``/home/username``). #. From this directory, make the ``.run`` file executable. .. code:: chmod +x findface-multi-1.1-and-server-5.1.run #. Execute the ``.run`` file. .. code:: sudo ./findface-multi-1.1-and-server-5.1.run The installer will ask you a few questions and perform several automated checks to ensure that the host meets the system requirements. Fill out the prompts appropriately once requested. The questions and answers are the following: #. Product to install: FindFace Multi. #. Installation type: * ``1``: install FindFace Multi standalone. * ``2``: install FindFace Multi and configure it to interact with additional remote ``findface-video-worker`` instances. .. tip:: To install only ``findface-video-worker`` on a host, refer to :ref:`video-worker-installer`. * ``3``: install the apt repository for the :ref:`step-by-step deployment `. * ``4``: :ref:`fully customized installation `. .. note:: If you select installation type #3 or #4, keep in mind to install necessary neural network models along with the ``findface-extraction-api`` component. #. Type of ``findface-video-worker`` package: CPU or GPU. #. Type of ``findface-extraction-api`` package: CPU or GPU. After all the questions are answered, the answers will be saved to a file ``/tmp/.json``. You can edit this file and use it to install FindFace Multi on other hosts without having to answer the questions again. Should you choose to install FindFace Multi standalone, its components will be automatically installed, configured and/or started in the following configuration: .. important:: In the case of a clean install, the installer will automatically configure ``findface-extraction-api`` to use the ``kiwi_320`` neural network. Otherwise, you will be able to choose between ``kiwi_320`` and the previous model. It is strictly not recommended to use the installer to update the system. See :ref:`update` for the instructions. +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | Service | Configuration | +======================================+=======================================================================================================+ | postgresql-10 | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | nats-server | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | etcd | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | pgbouncer | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | memcached | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | nginx | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | django | Installed and started as a web framework for the FindFace Multi web interface. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | findface-ntls | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | findface-tarantool-server | Installed and started. The number of instances (shards) is calculated using the formula: | | | ``N = min(max(min(mem_mb // 2000, cpu_cores), 1), 16 * cpu_cores)``. I.e., it is equal to the RAM | | | size in MB divided by 2000, or the number of CPU physical cores (but at least one shard), | | | or the number of CPU physical cores multiplied by 16, if the first obtained value is greater. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | findface-extraction-api | Installed and started (CPU/GPU-acceleration). | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | findface-sf-api | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | findface-upload | Installed. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | findface-video-manager | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | findface-video-worker-* | Installed and started (CPU/GPU-acceleration). | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | findface-data-* | Neural network models for object and object attribute recognition. Installed. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | findface-security | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | findface-counter | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | findface-liveness-api | Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | jq | Installed. Used to pretty-print API responses from FindFace Multi. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ | python3-ntech.* | Internal and auxiliary services. Installed and started. | +--------------------------------------+-------------------------------------------------------------------------------------------------------+ After the installation is complete, the following output is shown on the console: .. tip:: Be sure to save this data: you will need it later. .. code:: ############################################################################# # Installation is complete # ############################################################################# - upload your license to http://172.20.77.17/#/license/ - user interface: http://172.20.77.17/ superuser: admin password: admin documentation: http://172.20.77.17/doc/ #. Specify your time zone in the ``/etc/findface-security/config.py`` configuration file either in the ``Region/Country/City`` or ``Etc/GMT+H`` format. The time zone determines the time in reports, logs, and names of such FindFace Multi artifacts as event full frames and thumbnails, counter screenshots, etc. .. tip:: See `this table `_ for reference. .. code:: sudo vi /etc/findface-security/config.py # time zone TIME_ZONE = 'America/Argentina/Buenos_Aires' #. Upload the FindFace Multi license file via the main web interface ``http:///#/license``. To access the web interface, use the provided ``superuser`` credentials. .. note:: The host IP address is shown in the links to FindFace web services in the following way: as an external IP address if the host belongs to a network, or ``127.0.0.1`` otherwise. .. important:: Do not disclose the ``superuser`` (Super Administrator) credentials to others. To administer the system, create a new user with administrator privileges. Whatever the role, the Super Administrator cannot be deprived of its rights. #. To automatically install FindFace Multi on another host without answering the installation questions, use the ``/tmp/.json`` file. Execute: .. code:: sudo ./findface-multi-1.1-and-server-5.1.run -f /tmp/.json .. tip:: You can find an example of the installation file in :ref:`installation-file`. .. important:: To preserve the FindFace Multi compatibility with the installation environment, we highly recommend you to disable the Ubuntu automatic update. In this case, you will be able to update your OS manually, fully controlling which packages to update. To disable the Ubuntu automatic update, execute the following commands: .. code:: sudo apt-get remove unattended-upgrades sudo systemctl stop apt-daily.timer sudo systemctl disable apt-daily.timer sudo systemctl disable apt-daily.service sudo systemctl daemon-reload .. important:: The FindFace Multi services log a large amount of data, which can eventually lead to disc overload. To prevent this from happening, we advise you to disable ``rsyslog`` due to its suboptimal log rotation scheme and use the appropriately configured ``systemd-journal`` service instead. See :ref:`logs` for the step-by-step instructions.