Using the Linux Binary Distributions
This page provides important information for users of the Ice binary distributions on Linux platforms. You can obtain these distributions at the ZeroC web site.
On this page:
Overview of the Ice Binary Distributions for Linux
DEB Packages
ZeroC provides the following DEB packages for Debian and Ubuntu:
| Package | Description |
|---|---|
zeroc-ice-all-dev | Meta package that installs all development packages |
zeroc-ice-all-runtime | Meta package that installs all run-time packages, servers and utilities |
libzeroc-ice-dev | C++ header files and libraries |
libzeroc-ice3.7-java | Ice for Java JAR files |
libzeroc-ice3.7 | C++ run-time libraries |
libzeroc-icestorm3.7 | IceStorm service for IceBox C++ |
php-zeroc-ice | PHP extension and run-time files |
python3-zeroc-ice | Python 3 extension and run-time files |
zeroc-glacier2 | Glacier2 service |
zeroc-icebox | IceBox server for C++ |
zeroc-icebridge | IceBridge service |
zeroc-ice-compilers | Slice compilers, such as slice2cpp, slice2java and slice2php |
zeroc-icegrid | IceGrid service |
zeroc-icegridgui | IceGrid GUI application |
zeroc-icepatch2 | IcePatch2 service |
| Slice files |
zeroc-ice-utils | Utilities necessary for administering an Ice installation |
RPM Packages
ZeroC provides the following RPMs for Amazon Linux, Red Hat Enterprise Linux and SUSE Linux Enterprise Server:
| RPM | Description |
|---|---|
ice-all-devel | Meta package that installs all development packages |
ice-all-runtime | Meta package that installs all run-time packages, servers and utilities |
glacier2 | Glacier2 service |
icebox | IceBox server for C++ |
icebridge | IceBridge service |
icegrid | IceGrid service |
icegridgui | IceGrid GUI application |
icepatch2 | IcePatch2 executable |
ice-compilers | Slice compilers, such as slice2cpp, slice2java and slice2py |
| Slice files |
ice-utils | Utilities necessary for administering an Ice installation |
libice-c++-devel | C++ header files and symbolic links to the C++ run-time libraries |
libice3.7-c++ | C++ run-time libraries |
libicestorm3.7 | IceStorm service |
| PHP extension and run-time files (RHEL 9, and RHEL 10) |
| PHP extension and run-time files (Amazon Linux 2023 only) |
python3-ice | Python 3 extension and run-time files |
ZeroC also supplies RPMs for the following third-party packages:
RPM | Description |
|---|---|
| Admin tools for LMDB (statically linked) |
| Header file and static library for LMDB |
| Static library for the MCPP C++ preprocessor |
Third party RPMs are not provided for Amazon Linux 2023 as they are already included in as system packages.
The RPM distribution no longer includes an RPM with the Ice for Java JAR files. See Building Ice Application in Java or more information.
Installing the Linux Distributions
This section describes how to install Ice binary packages for all of the supported Linux platforms.
Installing Ice on Debian
Follow the instructions below to install Ice 3.7 on Debian using the packages from ZeroC repositories.
1. install the ZeroC Ice 3.7 repository for your distribution:
wget "https://download.zeroc.com/ice/3.7/debian12/ice-repo-3.7-nightly_1.0.0_all.deb" -O ice-repo-3.7-nightly.deb sudo dpkg -i ice-repo-3.7-nightly.deb rm ice-repo-3.7-nightly.deb
wget "https://download.zeroc.com/ice/3.7/debian13/ice-repo-3.7-nightly_1.0.0_all.deb" -O ice-repo-3.7-nightly.deb sudo dpkg -i ice-repo-3.7-nightly.deb rm ice-repo-3.7-nightly.deb
2. Update the package list and install:
sudo apt-get update sudo apt-get install zeroc-ice-all-runtime zeroc-ice-all-dev
Refer to the package summary if you would like to install fewer packages.
3. Install the source package (optional):
apt-get source zeroc-ice
Debian 12 (Bookworm) includes the Ice 3.7.8 packages.
Debian 13 (Trixie) includes the Ice 3.7.10 packages.
If you would rather install these Ice packages included in Universe, skip the instructions above and use the following command:
sudo apt-get install zeroc-ice-all-runtime zeroc-ice-all-dev
Installing Ice on Ubuntu
Follow the instructions below to install Ice 3.7 on Ubuntu. ZeroC provide Ice 3.7 packages for Ubuntu Jammy (22.04), and Ubuntu Noble (24.04)
1. install the ZeroC Ice 3.7 repository for your distribution:
wget "https://download.zeroc.com/ice/3.7/ubuntu22.04/ice-repo-3.7-nightly_1.0.0_all.deb" -O ice-repo-3.7-nightly.deb sudo dpkg -i ice-repo-3.7-nightly.deb rm ice-repo-3.7-nightly.deb
wget "https://download.zeroc.com/ice/3.7/ubuntu24.04/ice-repo-3.7-nightly_1.0.0_all.deb" -O ice-repo-3.7-nightly.deb sudo dpkg -i ice-repo-3.7-nightly.deb rm ice-repo-3.7-nightly.deb
2. Update the package list and install:
sudo apt-get update sudo apt-get install zeroc-ice-all-runtime zeroc-ice-all-dev
Refer to the package summary if you would like to install fewer packages.
3. Install the source package (optional):
apt-get source zeroc-ice
Ubuntu 22.04 (Jammy Jellyfish)'s universe includes the Ice 3.7.6 packages.
Ubuntu 24.04 (Noble Numbat)'s universe includes the Ice 3.7.10 packages.
If you would rather install these Ice 3.7 packages included in Universe, skip the instructions above and use the following command:
sudo apt-get install zeroc-ice-all-runtime zeroc-ice-all-dev
Installing Ice on Amazon Linux 2023
Follow the instructions below to install Ice on Amazon Linux 2023 (amzn2023):
1. Add the Ice repositories to your Amazon Linux system:
sudo dnf install https://download.zeroc.com/ice/3.7/amzn2023/ice-repo-3.7.amzn2023.noarch.rpm
2. Install Ice:
sudo yum install ice-all-runtime ice-all-devel
Refer to the package summary if you would like to install fewer packages.
The EC2 documentation provides more information about installing packages on Amazon Linux.
Installing Ice on Red Hat Enterprise Linux 9 or 10
Follow the instructions below to install Ice on RHEL 8 or 9:
1. Add the Ice repositories to your system:
sudo dnf install https://zeroc.com/download/ice/3.7/el9/ice-repo-3.7.el9.noarch.rpm
sudo dnf install https://zeroc.com/download/ice/3.7/el10/ice-repo-3.7.el10.noarch.rpm
2. Install Ice:
sudo dnf install ice-all-runtime ice-all-devel
Refer to the package summary if you would like to install fewer packages.
Setting Up your Linux Environment to Use Ice
After installing Ice, read the relevant language-specific sections below to learn how to configure your environment and start programming with Ice.
C++
When compiling and linking Ice for C++ programs, you must pass the -pthread option. A typical compile command would look like this:
c++ -c -std=c++11 -DICE_CPP11_MAPPING -pthread myprogram.cpp
c++ -c -pthread myprogram.cpp
If you specify a non-default C++ compilation mode for your application with the -std option, you may need to rebuild Ice for C++98 from source. See Known Issues and Platform Notes for more information.
C++11 and C++98 in the tabs above correspond to the Ice C++ mapping you're using.
When linking a program you must link with at least the Ice library. A typical link command would look like this:
c++ -std=c++11 -o myprogram myprogram.o -pthread -lIce++11
c++ -o myprogram myprogram.o -pthread -lIce
Additional libraries are necessary if you are using an Ice service such as IceGrid or Glacier2.
PHP
The Ice extension for PHP is loaded automatically when the interpreter loads the contents of the file /etc/php.d/ice.ini (on Red Hat Enterprise Linux and Amazon Linux). This file contains the line shown below:
extension=ice.so
You can modify this file to include additional configuration directives.
At run time, the PHP interpreter requires the Ice shared libraries.
You can verify that the Ice extension is installed properly by examining the output of the php -m command, or by calling the phpinfo() function from a script.
Your application will also need to include at least some of the Ice for PHP run-time source files (installed in /usr/share/php on RHEL, Amazon Linux, and Ubuntu. This installation directory is included in PHP's default include path, which you can verify by executing the following command:
php -i | grep include_path
If the installation directory is listed, no further action is necessary to make the run-time source files available to your application. Otherwise, you can modify the include_path setting in php.ini to add the installation directory:
include_path = /usr/share/php:...
Another option is to modify the include path from within your script prior to including any Ice run-time file:
ini_set('include_path', ini_get('include_path') . PATH_SEPARATOR . '/usr/share/php');
require 'Ice.php'; // Load the core Ice run time definitions.
Using the Sample Programs on Linux
Sample programs for all programming languages are available in a separate ice-demos GitHub repository. Simply clone this repository:
git clone -b 3.7 https://github.com/zeroc-ice/ice-demos.git cd ice-demos
Starting IceGrid GUI on Linux
You can launch IceGrid GUI with the icegridgui command. IceGrid GUI is a Java-based application.
Startup Scripts for IceGrid and Glacier2 Services
All distributions include the following service configuration files:
/etc/icegridregistry.conf/etc/icegridnode.conf/etc/glacier2router.conf
Distributions which use sysvinit or upstart contain the following sample scripts:
/etc/init.d/icegridregistry/etc/init.d/icegridnode/etc/init.d/glacier2router
Distributions which use systemd contain the following services:
icegridregistry.serviceicegridnode.serviceglacier2router.service
The installation also creates a user account and group for running these services (account ice and group ice), and data directories for icegridregistry and icegridnode (/var/lib/ice/icegrid/registry and /var/lib/ice/icegrid/node1).
By default, all these services are off at all runlevels. You need to manually switch on one or more runlevels, as shown below:
# # On systems using svsvinit, configure the icegridregistry to start at the # default run levels: # sudo chkconfig icegridregistry on # # On systems using systemd, start icegridregistry with the multi-user target # sudo systemctl enable icegridregistry.service
Before doing so, please review the script itself and its associated configuration file.