Tips for the VOMS EMI 2 certification

1 Configuring vomsdir without YAIM

Normally the vomsdir is configured by YAIM. On some platforms YAIM is not available (e.g. Debian), so the configuration must be done manually.

In practice, you have to create (as root):

mkdir /etc/grid-security/vomsdir

For each VO that you want to support, create a subdirectory


where you're going to place a


file which describes the certificate chain of the VOMS server.


For the vo the configuration is as follows:

[ceccanti@emitestbed08]$ ls /etc/grid-security/vomsdir/

Two files are listed in the VO directory since there are two VOMS replicas for the VOs. The content of the lsc files is:

[ceccanti@emitestbed08]$ cat /etc/grid-security/vomsdir/ 

[ceccanti@emitestbed08]$ cat /etc/grid-security/vomsdir/ 

Runnning the following script on the VOMS server will produce an lsc file for such server:

hostname=`hostname -f`

subject=`openssl x509 -in /etc/grid-security/hostcert.pem -noout -subject | sed 's/subject= //'`
issuer=`openssl x509 -in /etc/grid-security/hostcert.pem -noout -issuer | sed 's/issuer= //'`

echo $subject >> $hostname.lsc
echo $issuer >> $hostname.lsc

More instructions can be found in the voms user guide in the Host setup section.

2 Configuring vomses without YAIM

Normally the vomses is configured by YAIM. On some platforms YAIM is not available (e.g. Debian), so the configuration must be done manually.

In practice, you have to create (as root):

mkdir /etc/vomses

Then put a vomses file in such directory for each supported VO.


For the vo the configuration is as follows:

[ceccanti@emitestbed08 vomses]$ ls /etc/vomses
[ceccanti@emitestbed08 vomses]$ cat 
"" "" "15002" "/C=IT/O=INFN/OU=Host/L=CNAF/" ""
[ceccanti@emitestbed08 vomses]$ cat 
"" "" "15002" "/C=IT/O=INFN/OU=Host/L=CNAF/" ""

The vomses information can be obtained from the voms admin configuration page for such VO.

3 VOMS Admin server configuration settings

In order to quickly certify the VOMS Admin service, the default value for some settings has to be changed. All these changes should be put in the YAIM configuration used for certification, in particular in the



3.1 More frequent membership check

The membership control checkes are done by a VOMS Admin background task that is run, by default, every 10 minutes. In order to quickly see if VOMS Admin membership check behavior works as expected set a more convenient value for the membership check interval using the following YAIM variable:


3.2 Short Sign AUP task lifetime

Sign AUP tasks are created for users in two cases:

  • when their AUP acceptance record expires (tipycally one year after they have signed the AUP the last time)
  • when explictly requested by the administrator using the "Trigger reacceptance" button in the user detail page or in the AUP details page.

When a Sign AUP task is assigned to a user an expiration time is linked to the task. If the user doesn't sign the aup by this expiration time it is suspended. The time interval given to a user to sign the AUP is a VOMS Admin configuration parameter, with default value 15 days.

For the certification it is convenient to set this value to a negative value:


In this way Sign AUP tasks are created with the expiration date equal to the creation date is easy to check whether users that didn't sign the AUP are indeed suspended.

A trick below explains another way for changing Sign AUP tasks expiration date.

3.3 YAIM VOMS defaults

The default values and the documentation for VOMS YAIM variables can be found in:


3.4 VOMS and VOMS Admin configuration files

Configuration files for VOMS are found in:


Configuration files for VOMS Admin are found in:


3.5 VOMS and VOMS Admin log files

Log files for VOMS are found in:


Log files for VOMS admin are found:

/var/log/tomcat5 (SL5)
/var/log/tomcat6 (SL6)

4 Tips and tricks

4.1 VOMS admin commands help

voms-admin --list-commands  (displays all commands available)
voms-admin --help <command-name> (displays help about a given command)

4.2 VOMS admin and command line arguments

The voms admin client enforce the following convention when parsing command-line arguments:

   voms-admin [options] <command> <arg0> <arg1> <arg2> 

This means that options, i.e. those things prepended by --, MUST always be given before the command. In practice:

  voms-admin --vo cert.mysql --description "test" create-group /cert.mysql/test (OK)

  voms-admin create-group --vo cert.mysql --description "test" /cert.mysql/test (ERROR)

4.3 VOMS admin client and certificates

If you run voms-admin client as root, it will use the host certificate in etc/grid-security/hostcert.pem to authenticate against the voms-admin-server.

If you run voms-admin as a normal user, it will look for a proxy in /tmp and if it doesn't find it it will look in $HOME/.globus. If the private key is protected by a password it will ask for a password whenever a command is run.

A convenient way to use voms-admin as a non-root user is to run voms-proxy-init first to create a grid proxy:


voms-admin will then use the proxy and will not bother about passwords until proxy expiration.

Note that voms-proxy-init is not usually installed on a VOMS node, but can be easily installed with:

yum install voms-clients

4.4 Create multiple users in a row

The following command creates 150 users in VOMS (n.b. change the email address to your own):

for i in `seq 1 150`; do \
  voms-admin --nousercert --vo cert.mysql --name "User $i" \
                       --surname "Test" --institution "IGI" \
                       --address "No address" 
                       --phoneNumber "051 150 051" \
                       create-user \
                       "Test$i" \
                       "/C=IT/O=INFN/CN=INFN CA" \
                       "Test User $i" ""; \

4.5 Create multiple groups in a row

for i in `seq 1 150`; do \
voms-admin --vo cert.mysql --description "This is test group $i" \
   create-group /cert.mysql/test-group-$i; \

4.6 How to find out which credentials are used by VOMS to connect to the database

In the default configuration VOMS and VOMS Admin use the same credentials to access the database. These can be found in:

/etc/voms/<vo>/voms.conf (VOMS)
/etc/voms-admin/<vo>/ (VOMS Admin)

4.7 How to quickly change membership expiration date for users

The membership expiration date for each user is stored in the VOMS database in the usr table. To change the end time for all users use the following command on the db:

update usr set end_time = "2012-04-24";

To change it only for a given set of users, use the where clause:

update usr set end_time = "2012-04-24" where userid > 2 and userid  < 10;

The command above changes the end_time only for users whose id is between 3 and 10.

4.8 How to quickly change expiration date for pending Sign AUP tasks

update task set expiryDate = "2012-04-28" where status = "CREATED";

-- AndreaCeccanti - 2012-04-25

Topic revision: r3 - 2012-11-13 - AndreaCeccanti
This site is powered by the TWiki collaboration platformCopyright © 2008-2023 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback