Note: This web site is only kept up to date for OSG Software 1.2 (VDT 2.0.0). If you are looking for information for the most recent release, the RPM-based OSG Software 3.0, please see the OSG documentation web site

A Few Notes About RT


This section is out-of-date since Nate Griswold merged the VDT and NMI RT instances in mid-2008.

RT code/p/vdt/workspace/rt
Site config file/p/vdt/workspace/rt/etc/
HTML code (with Mason)/p/vdt/public/html/rt
Locally modified HTML/p/vdt/workspace/rt/local/html

Mail filters

The script that processes incoming email is located at:


Note that the aliases directory contains one symlink to the filter for each email address that can be used:

lrwxr-xr-x 1 griswold griswold   10 Aug  4  2008 vdt-internal -> vdt_filter*
lrwxr-xr-x 1 griswold griswold   10 Aug  4  2008 vdt-internal-comment -> vdt_filter*
lrwxr-xr-x 1 griswold griswold   10 Feb 12 09:19 vdt-links -> vdt_filter*
lrwxr-xr-x 1 griswold griswold   10 Feb 12 09:19 vdt-links-comment -> vdt_filter*
lrwxr-xr-x 1 griswold griswold   10 Feb 12 09:18 vdt-security -> vdt_filter*
lrwxr-xr-x 1 griswold griswold   10 Feb 12 09:19 vdt-security-comment -> vdt_filter*
lrwxr-xr-x 1 griswold griswold   10 Aug  4  2008 vdt-support -> vdt_filter*
lrwxr-xr-x 1 griswold griswold   10 Aug  4  2008 vdt-support-comment -> vdt_filter*

Paragraph out-of-date: The vdt_filter script puts all incoming mail into /scratch/{queue} on chopin. We use SPAM assassin. All incoming mail, including SPAM, is logged to /scratch/{queue}.mbox. If mail is incorrectly detected as SPAM, put it in email client and redirect to vdt-support. SPAM assassin is pretty good: only a couple of failures in Nate’s (Mueller) experience.

The VDT mail filter also looks for email coming from the OSG GOC and edits the subject line to have the correct ticket label. This is the only reliable way (as of August 2006) to avoid mail loops with them: without it, the GOC’s ticketing system acknowledges every email from us but doesn’t set the [vdt-support #nnnn] tag into the subject line automatically. When we acknowledge the creation of a ticket, their acknowledgement makes a new ticket. So the VDT mail filter now queries RT to find any existing GOC tickets and edit the subject auotmatically. See Ticket 2064 for more details.

Caching Issues

In our environment, RT runs under mod_perl and Mason, both of which cache the Perl code that comprises the system. Thus if you make a change to RT code, mod_perl will not pick up that change until it (read: Apache) is restarted. The Apache instance that runs RT is rebooted every night, but that may not be often enough to do serious debugging. Furthermore, the Mason caches are on the filesystem, so even an Apache restart, which only clears in-memory caches, may not pick up all types of changes.

A Hack for Forcing mod_perl To Reload

You may be able to force mod_perl to pick up changed code under some (unclear) circumstances.

  1. Edit /p/vdt/public/html/rt/.htaccess
  2. Comment out the SetHandler lines
  3. Save the file
  4. Use a browser to access a page (which will fail)
  5. Uncomment the SetHandler lines
  6. Save the file
  7. Use a browser to access a page (which should work again)

Sometimes this trick works, sometimes it doesn’t — I don’t understand the inconsistency or how to predict when it will work.

Restarting Apache

Restarting Apache (obviously) clears out the mod_perl in-memory caches. Apache is VERY quick to restart, usually just a second or two, so don’t worry about doing this in the middle of the day. However, we cannot restart Apache ourselves. Get Michelle in the CSL to do it — she said that she doesn’t mind doing it whenever. If we really need to do a lot of restarts in a short period of time, she could grant one or more of us the rights to restart Apache.

Clearing Mason Caches

Mason creates a cache of precompiled source code. The Mason website has an FAQ page that describes Mason caching.

With some help from Michelle Craft in the CSL, I found the actual directory in which the Mason cache lives. Look in:


Most of the files and subdirectories therein are very old and must represent some different sort of cache from 2005 and early 2006. The real cache directories appear to be the ones that are simply large numbers:

drwxr-xr-x  71 www-vdt www-user  6144 May 29 09:31 1249693838/
drwxr-xr-x  72 www-vdt www-user  6144 Apr 11 08:44 1163448460/
drwxr-xr-x  67 www-vdt www-user  6144 Nov 23  2007 276677478/
drwxr-xr-x  70 www-vdt www-user  6144 May 11  2007 109036483/

I think it’s safe to say that the most recently modified directory is the current cache directory (i.e., 1249693838 in the listing above).

Inside this directory are the precompiled *.obj files that correspond to pages (and other Mason files) on our website. Based on very hasty experimentation, it seems completely safe to remove object files — they seem to be recreated with no trouble when the original page is requested via Apache. So that’s the method for clearing Mason cached pages.

The good thing is that the VDT has complete AFS access to these files, so we can remove object files ourselves without needing to bother the CSL.

Learning More About Our mod_perl System

Michelle gave me a couple URLs that are interesting for looking into our running mod_perl instance on teal:

The RT PostgreSQL Database

This section is out-of-date since Nate Griswold merged the VDT and NMI RT instances in mid-2008.

> /s/postgresql/bin/psql -h -p 49173 -d vdt_tickets
vdt_tickets=> \d
                      List of relations
 Schema |             Name             |   Type   |  Owner   
 public | acl                          | table    | nmueller
 public | acl_id_seq                   | sequence | nmueller
 public | attachments                  | table    | nmueller
 public | attachments_id_seq           | sequence | nmueller
 public | attributes                   | table    | nmueller
 public | attributes_id_seq            | sequence | nmueller
 public | cachedgroupmembers           | table    | nmueller
 public | cachedgroupmembers_id_seq    | sequence | nmueller
 public | customfields                 | table    | nmueller
 public | customfields_id_seq          | sequence | nmueller
 public | customfieldvalues            | table    | nmueller
 public | customfieldvalues_id_seq     | sequence | nmueller
 public | groupmembers                 | table    | nmueller
 public | groupmembers_id_seq          | sequence | nmueller
 public | groups                       | table    | nmueller
 public | groups_id_seq                | sequence | nmueller
 public | links                        | table    | nmueller
 public | links_id_seq                 | sequence | nmueller
 public | objectcustomfields           | table    | nmueller
 public | objectcustomfields_id_s      | sequence | nmueller
 public | objectcustomfieldvalues      | table    | nmueller
 public | objectcustomfieldvalues_id_s | sequence | nmueller
 public | principals                   | table    | nmueller
 public | principals_id_seq            | sequence | nmueller
 public | queues                       | table    | nmueller
 public | queues_id_seq                | sequence | nmueller
 public | scripactions                 | table    | nmueller
 public | scripactions_id_seq          | sequence | nmueller
 public | scripconditions              | table    | nmueller
 public | scripconditions_id_seq       | sequence | nmueller
 public | scrips                       | table    | nmueller
 public | scrips_id_seq                | sequence | nmueller
 public | sessions                     | table    | nmueller
 public | templates                    | table    | nmueller
 public | templates_id_seq             | sequence | nmueller
 public | tickets                      | table    | nmueller
 public | tickets_id_seq               | sequence | nmueller
 public | transactions                 | table    | nmueller
 public | transactions_id_seq          | sequence | nmueller
 public | users                        | table    | nmueller
 public | users_id_seq                 | sequence | nmueller
(41 rows)
vdt_tickets=> \d users
                                         Table "public.users"
        Column         |            Type             |                   Modifiers                    
 id                    | integer                     | not null default nextval('users_id_seq'::text)
 name                  | character varying(200)      | not null
 password              | character varying(40)       | 
 comments              | text                        | 
 signature             | text                        | 
 emailaddress          | character varying(120)      | 
 freeformcontactinfo   | text                        | 
 organization          | character varying(200)      | 
 realname              | character varying(120)      | 
 nickname              | character varying(16)       | 
 lang                  | character varying(16)       | 
 emailencoding         | character varying(16)       | 
 webencoding           | character varying(16)       | 
 externalcontactinfoid | character varying(100)      | 
 contactinfosystem     | character varying(30)       | 
 externalauthid        | character varying(100)      | 
 authsystem            | character varying(30)       | 
 gecos                 | character varying(16)       | 
 homephone             | character varying(30)       | 
 workphone             | character varying(30)       | 
 mobilephone           | character varying(30)       | 
 pagerphone            | character varying(30)       | 
 address1              | character varying(200)      | 
 address2              | character varying(200)      | 
 city                  | character varying(100)      | 
 state                 | character varying(100)      | 
 zip                   | character varying(16)       | 
 country               | character varying(50)       | 
 timezone              | character varying(50)       | 
 pgpkey                | text                        | 
 creator               | integer                     | not null default 0
 created               | timestamp without time zone | 
 lastupdatedby         | integer                     | not null default 0
 lastupdated           | timestamp without time zone | 
    "users_pkey" primary key, btree (id)
    "users1" unique, btree (name)
    "users2" btree (name)
    "users3" btree (id, emailaddress)
    "users4" btree (emailaddress)