Installing xis

Contents:

Installing using rpms and configuring.

xis and xrootd rpms for some distributions are provided here.

WARNING! See the note regarding xrootd packages before attempting to install!

Installing an xis structure using rpms consists in few steps (all as root):

  1. Install xis server.

    This requires the xrootd executable. It is easier if you install xis server on a different machine than xrootd redirector and servers. I use the EGEE IS machine for xis server. You must install the following packages: xrootd, xrootd-clients, xrootd-servers, xis, xis-server

  2. Configure xis server.

    The default configuration allows connections only from localhost. You should also allow access for the dataservers and the EGEE IS machine. Edit /etc/xis/xisd.conf and add lines like:

    xrd.allow host localhost.localdomain
    xrd.allow host mydataserver.mydomain
    xrd.allow host myEGEEIS.mydomain
    

    The default configuration uses port 2194. You may change it in /etc/xis/xisd.conf.

    Once you configured the xis server you may start it with

    /etc/rc.d/init.d/xisd start
    

    On the xis server, you should also configure the aggregator. Edit /etc/xis/xis.config and uncomment and modify (if necessary) the xis_url line like:

    xis_url="root://myXISSERVER.mydomain:2194"
    

    (if you use the port 2194).

    It is advisable to put firewall rules on the xis server machine to allow connections to the chosen port only from the dataservers and EGEE IS machine.

  3. Install sensors on the xrootd server machines.

    The required rpms are xrootd, xrootd-clients, xis, xis-disk-sensor.

  4. Tell to the sensor where the xis server is by editing /etc/xis/xis.config like:

    xis_url="root://myXISSERVER.mydomain:2194"
    
  5. On the dataservers, add the partitions served by xrootd to the sensor:

    /usr/libexec/xis/scripts/setup-disk-sensor --command create\
    	    --name "Partition1"\
    	    --path "/data/mypart1"
    

    In principle, you may use spaces or other special characters in --name, but this is not tested, so don't.

    There are also --comand delete and --comand update options.

    In the default configuration, the sensor sends informations to xis server every 5 minutes, so after 5 minutes you should see this information present on the xis server machine like:

    cat /var/xis/data/hosts/<dataserver hostname>/xrootd/<partition name>
    

    Note that <dataserver hostname> is what /bin/hostname returns on the dataserver. <partition name> is what you put as --name when you set it with setup-disk-sensor.

  6. On the xis sever, define one (or more) xrootd SEs:

    /usr/libexec/xis/scripts/setup-xrootd-SE --command create\
    				--name "MySE"\
    				--server <xrootd redirector hostname>\
    				--port 1094\
    				--software-version 20090312.1017\
    				--protocol-version 2.9.5\
    				--security-protocol tkauthz
    

    This info is required by Glue schema usage rules.

    There are also --command delete and --command update options.

    Once you defined a SE, you may add partitions to it:

    /usr/libexec/xis/scripts/setup-xrootd-SE --command addsource\
    				--name "MySE"\
    				--dataserver <dataserver hostname>\
    				--partition <partition name>
    

    Note that <dataserver hostname> is what /bin/hostname returns on that dataserver. <partition name> is what you put as --name when you setup it with setup-disk-sensor on that dataserver.

    There is also --command delsource option.

    Use this commands to add all the partitions related to a SE.

    In the default configuration, the aggregator is run by cron every 5 minutes. 5 minutes after setting up a SE, you should be able to see the result in:

    cat /var/xis/data/services/SE/<SE Name>
    
  7. Install the xis gip provider on the EGEE IS machine (the one running site bdii).

    The required packages are xrootd, xrootd-client, xis, xis-gip-provider.

  8. Tell to the gip provider where the xis server is, by editing /etc/xis/xis.config like:

    xis_url="root://myXISSERVER.mydomain:2194"
    

    Make sure that xis server allows connections from IS machine by issuing the commands (on the IS machine):

    xrdcp root://myXISSERVER.mydomain:2194//services/SE/<SE Name> /tmp/test
    cat /tmp/test
    

    where <SE Name> is the name of the SE configured before on the xis server. If the xis server allows connections from the IS machine, you should be able to get the file.

  9. (most likely not necessary) Tell to the gip provider where the gip directories are, by editing /etc/xis/gip-provider.config like:

    gip_site_ldif="/opt/glite/etc/gip/ldif"
    gip_site_plugin="/opt/glite/etc/gip/plugin"
    

    Most likely you don't need to set this, unless you have a very, very special installation of glite software.

  10. Set up SEs to be reported by the gip provider:

    /usr/libexec/xis/scripts/setup-gip-provider --command create\
    			--name <SE name>\
    			--vo <voname>
    

    There are also --command delete and --command update options.

    Make sure all your partitions have been reported at least once to the xis server before you set up the gip provider. The reason is that, according to Glue schema usage rules, the total installed capacity have to be static (in this case it is set when you run setup-gip-provider), and not changed when, for example, some dataservers are stopped. When you add new partitions, or remove some partitions from a SE, update the static data by running:

    .../setup-gip-provider --command update --name <SE name> --vo <voname>
    

    to reflect the changes.

    setup-gip-provider finds the (EGEE) site name by looking up in the bdii at localhost:2170 (this script should be run only on the machine running site bdii!). If, for some reason, the lookup fails, you may put the (EGEE) sitename in /etc/xis/gip-provider.config, like:

    gip_bdii_sitename="MySite"
    

    If you do this, make sure you put the accurate site name.

    The site bdii is usually updated every few minutes. Wait few minutes and check your bdii publish data for your SE. Gstat is usually 1-2 hour behind, it will show the new storage data after a while.

Installing from source.

Alternatively, you may use the source tarball available here and install it with ./configure ... , make, make install.

Apart from usual options (like --prefix), configure has --with-xrootd=<location of xrootd installation> option.

make install will install everything under <prefix> (default is /usr/local). All the scripts should have the paths properly set after make install.

You should take care to have the cron jobs run. You may use as a template the files created in <prefix>/etc/cron.d to figure out what you have to do. Only the appropriate cron jobs have to be run (i.e. on a dataserver you have to run only <prefix>/libexec/xis/disk-sensor and on the xis server only <prefix>/libexec/xis/SE-aggregator).

Your xrootd installation may need special variables to be set (like LD_LIBRARY_PATH and PATH). All the scripts (except <prefix>/etc/rc.d/init.d/xisd) are sourcing <prefix>/etc/xis/xis.config, so this is the appropriate place to set up this variables, like:

export LD_LIBRARY_PATH=...
export PATH=${PATH}:...

The xisd startup script (<prefix>/etc/rc.d/init.d/xisd) is sourcing <prefix>/etc/sysconfig/xis , so this is the appropriate place to set this variables for it.

Of course, the xisd server have to be able to write log files, etc. If you are using <prefix>/etc/rc.d/init.d/xisd , then you may set this things in <prefix>/etc/sysconfig/xis and in <prefix>/etc/xis/xisd.conf . make install creates all (hopefully) the directories required for the default configuration in <prefix>/var . If you change them, you should take care to create the required directories with the appropriate permissions. A special note regarding the localroot used by the xis server: if you change it ( in <prefix>/etc/xis/xisd.conf ) then you should also change it in <prefix>/etc/xis/SE-aggregator.config, variable basedir.

The setup scripts (located in <prefix>/libexec/xis/scripts) are using some directories/files to store the configuration (which is used by the cron jobs and the gip provider). The appropriate places to change them are:

Special note for ALICE SEs.

ALICE have an officially supported installation procedure for pure xrootd SEs. If you are running an ALICE pure xrootd SE, most likely you used it when you installed the SE.

For xis server you may use a different machine and most likely you are not using the bdii machine as xrootd server. The problem might be with the dataservers. Installing the provided rpms required for disk sensor (xis and xis-disk-sensor) also requires the installation of xrootd and xrootd-clients. If your xrootd installation is not system-wide, then, most likely the rpm installation (using my rpms), described above, works. I don't think it will interfere with the official installation. If you want to use the already installed xrootd instead of my rpms, then I think the easiest way to do so is the following:

On the dataservers:

  1. copy all the files and directories from the xis rpm (actually, 1 file, /etc/xis/xis.config, and 1 empty directory, /usr/libexec/xis/scripts) and put them in the corresponding locations (i.e. /etc/xis/xis.config). Alternatively you may install the xis rpm with rpm -i --nodeps .

  2. copy all the files and directories from the xis-disk-sensor rpm and put them in the corresponding locations. Alternatively you may install the xis-disk-sensor rpm with rpm -i --nodeps .

  3. edit /etc/xis/xis.config as following:

    export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:<xrootd dir>/lib
    export PATH=${PATH}:<xrootd dir>/bin
    # xrdcp command to use
    xrdcp_cmd="<xrootd dir>/bin/xrdcp"
    

    where <xrootd dir> is the directory you installed xrootd.

At this moment, the disk sensor should use xrdcp from your installation. You may continue with configuration according to the instructions above.

I think the disk sensor is easy to integrate in xrd-installer, and maybe in the future it will be so. However, I think it is wise to have the xis server separate from the dataservers, because it is desirable not to mix dataserving and bdii.

Claudiu Schiaua ( schiaua#at#nipne.ro)