Using RT to track system changes

We are looking at RT for use in both tracking client and internal technical
issues as well as tracking changes that we make to systems. The first use
is obviously what RT was designed to do. As for tracking system changes,
that is another matter altogether. Essentially, we would like to have a
standardized system whereby when we make a change to a server, be it UNIX
or Windows, we can either send an email or submit a change entry via the
web to a database. I’m thinking that we can RT for just this.

Has anyone done anything like this? How did this work out for you? Have you
used any other software to do something like this? If so, what?

Right now we use a combination of high-level management logs (ie.,
installed LDAP service for…) in a spreadsheet for each client down to
system-level change logs (ie., chmod xxx to file xyz so that…) via a local
script on each machine that dumps to a text file. This works, but isn’t
scaling very well. I’d like something that is searchable, allows comments,
file uploads, and so forth. RT does all this, but isn’t really designed for
it. So, there may be issues I’m thinking.

One thing I would like to see is a way for one of us to send an email
through rt-mailgate that creates a closed ticket item. Say, a tech. sends
mail to clientname-change@example.com and then rt adds this item to the
queue clientname-changes as a closed ticket. (Alternatively, we could just
periodically go through all tickets for queue clientname-changes and
resolve them.) Does this sound viable? I’m thinking we would then have a
nice, searchable database of changes made to systems that can be added to
via a webpage or email.

Any further ideas or suggestions on this idea? I doubt this is too
original, so if anyone else has done this, please step forward!

Regards, Dustin

Dustin Puryear dustin@puryear-it.com
Puryear Information Technology
Windows, UNIX, and IT Consulting

At 11:24 PM 11/2/2002 -0600, Dustin Puryear wrote:

We are looking at RT for use in both tracking client and internal
technical issues as well as tracking changes that we make to systems. The
first use is obviously what RT was designed to do. As for tracking system
changes, that is another matter altogether. Essentially, we would like to
have a standardized system whereby when we make a change to a server, be
it UNIX or Windows, we can either send an email or submit a change entry
via the web to a database. I’m thinking that we can RT for just this.

Hi Dustin,

This is what we do at Lumeta:

My mentor and co-worker, Tom Limoncelli, set up our systems to use
Makefiles a lot. So we make changes to files like named.conf-master and
dhcpd.conf and such, and do a make which then (if necessary) builds the
actual live conf files or such, and checks things into RCS. I don’t see why
you couldn’t do things like send an email to an RT queue with a copy of the
file you just edited, or even something more advanced by tagging along the
“diff” version of the RCS checked-in code, or what-have-you… We run
FreeBSD, so RCS is built-in–nothing says that CVS wouldnt’ work! :slight_smile:

One of the big things I’ve learned from Tom–Automate! Automate! Automate!
If you have to do it once, it’s a pain. If you have to do it twice, it’s
worth writing a script for! :slight_smile:

Here’s an example Makefile I use on my own personal server (remembering
that tabs are necessary in Makefiles…):

$ cat /etc/Makefile

all: postfixstuff dnsstuff

postfixstuff: /etc/postfix/transport.db /etc/postfix/aliases.db
/etc/postfix/relocated.db /usr/local/mailman/aliases/aliases.mailman.db

/etc/postfix/aliases.db: /etc/postfix/aliases
ci -q -l -mAliases\ update /etc/postfix/aliases
newaliases

/usr/local/mailman/aliases/aliases.mailman.db:
/usr/local/mailman/aliases/aliases.mailman
ci -q -l -mMailman\ Aliases\ Update
/usr/local/mailman/aliases/aliases.mailman
newaliases

/etc/postfix/transport.db: /etc/postfix/transport
ci -q -l -mPostfix\ Transport\ Update /etc/postfix/transport
postmap /etc/postfix/transport

/etc/postfix/relocated.db: /etc/postfix/relocated
ci -q -l -mPostfix\ Relocated\ Update /etc/postfix/relocated
postmap /etc/postfix/relocated

dnsstuff:
(cd /chroot/named/etc/namedb && make )

You can always add something along these lines to each of the above:

mail -s “Postfix Aliases updated” help@yourdomain.tld < /etc/postfix/aliases

Hope this helps,
Glenn

The original portions of this message are the copyright of the author
(c)1998-2002 Glenn E. Sieb. ICQ UIN: 300395 IRC Nick: Rainbear

“Religion is for those who do what they are told regardless of what is right.
Spirituality is for those who do what is right regardless of what
they are told.” – unattributed

At 01:30 PM 11/3/2002 -0500, you wrote:

At 11:24 PM 11/2/2002 -0600, Dustin Puryear wrote:

We are looking at RT for use in both tracking client and internal
technical issues as well as tracking changes that we make to systems. The
first use is obviously what RT was designed to do. As for tracking system
changes, that is another matter altogether. Essentially, we would like to
have a standardized system whereby when we make a change to a server, be
it UNIX or Windows, we can either send an email or submit a change entry
via the web to a database. I’m thinking that we can RT for just this.

Hi Dustin,

This is what we do at Lumeta:

My mentor and co-worker, Tom Limoncelli, set up our systems to use
Makefiles a lot. So we make changes to files like named.conf-master and
dhcpd.conf and such, and do a make which then (if necessary) builds the
actual live conf files or such, and checks things into RCS. I don’t see
why you couldn’t do things like send an email to an RT queue with a copy
of the file you just edited, or even something more advanced by tagging
along the “diff” version of the RCS checked-in code, or what-have-you…
We run FreeBSD, so RCS is built-in–nothing says that CVS wouldnt’ work! :slight_smile:

Glenn, we do indeed use RCS quite a bit already on the UNIX systems that we
manage. However, you forget that we mentioned more than UNIX systems, so
this style of managing configuration changes can only be applied to some of
the systems we manage. (Unless RCS now works with the Windows Registry? :slight_smile:
We wanted a system that works with everything, so we decided to see what RT
could do for us. We will continue to use RCS on UNIX systems, and have in
fact considered sending rcsdiff output to RT whenever a change is made with
comments.

Thanks for the quick reply!

Regards, Dustin

Dustin Puryear dustin@puryear-it.com
Puryear Information Technology
Windows, UNIX, and IT Consulting

One thing I would like to see is a way for one of us to send an email
through rt-mailgate that creates a closed ticket item. Say, a tech. sends
mail to clientname-change@example.com and then rt adds this item to the
queue clientname-changes as a closed ticket. (Alternatively, we could just
periodically go through all tickets for queue clientname-changes and
resolve them.) Does this sound viable? I’m thinking we would then have a
nice, searchable database of changes made to systems that can be added to
via a webpage or email.

The enhanced mailgate (look at
http://www.fsck.com/pub/rt/contrib/2.0/rt-addons/enhanced-mailgate)
allows you to do things like modify the status of tickets.

I’ve often considered creating function-specific mail aliases, like you
allude to above, that perform certain actions, i.e., mail to
rt-1234-status=closed@foo.com would change the status of ticket 1234 to
closed (after checking that the user sending the message has the right
to do so, of course), with the body of the message as a comment. This
would be pretty simple to do with procmail:

:0

  • ^RT-Ticket:
    | /opt/rt2/bin/do-stuff.pl

Where do-stuff.pl does something like:

#!/usr/bin/perl

use Mail::Internet;

my $mail = Mail::Internet->new(*STDIN);

validate_user does RT authentication

This doesn’t yet exist, of course

validate_user($mail->head->get(“From”));

my $to = $mail->head->get(“To”);
my ($ticket, $action, $value) = $to =~ /rt-(\d+)-(\w+)=(.+)@/;

Now perform $action with argument $value to ticket $ticket

And so on.

I have discovered that all human evil comes from this, man’s being
unable to sit still in a room.
– Blaise Pascal