I realized that my line numbers will be different as I&#39;ve edited the script.<div><br></div><div>Line 70: my $ldaphandle = RT::User::LdapConnect();<br clear="all">Jonah Hirsch<br>-----------------------<br>
<br><br><div class="gmail_quote">On Thu, Jul 8, 2010 at 12:07 PM, Jonah Hirsch <span dir="ltr">&lt;<a href="mailto:crazydog115@gmail.com">crazydog115@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

We just migrated our RT system from an old installation on an old server to a new one that will use LDAP to create users.<div><br></div><div>The issue is that we already have a good number of users on the old system, and would like to keep them around.</div>


<div><br></div><div>I realize the most straight forward decision is to simply rename the users (and change their email addresses), and when they are recreated when a user first logs in, just shred the old accounts and replace the relations to the new ones.</div>


<div><br></div><div>I then got to thinking that there must be a way to update the users in RT through LDAP, not only for this reason but for regular maintenance.</div><div><br></div><div>Anyway, I was googling around and found this old script from 2005</div>


<div><a href="http://lists.bestpractical.com/pipermail/rt-devel/2005-August/007451.html" target="_blank">http://lists.bestpractical.com/pipermail/rt-devel/2005-August/007451.html</a></div><div>As it is 5 years old, it doesn&#39;t work well. I&#39;m no RT developer, so it&#39;d take a while to figure out what needs to be changed, so my question is, would anyone out there be able to update this script to work with a more current version of RT (as of emailing, 3.8.8). There really only is one error, so I&#39;m hoping it wouldn&#39;t take too long.</div>


<div><br></div><div>The one warning and one critical error I get are:</div><div><div><br></div><blockquote class="gmail_quote" style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0.8ex;border-left-width:1px;border-left-color:rgb(204, 204, 204);border-left-style:solid;padding-left:1ex">


<font face="&#39;courier new&#39;, monospace">[Thu Jul  8 19:00:13 2010] [warning]: Use of inherited AUTOLOAD for non-method RT::User::LdapConnect() is deprecated at <a href="http://updateldap.pm" target="_blank">updateldap.pm</a> line 70. (<a href="http://updateldap.pm:70" target="_blank">updateldap.pm:70</a>)</font></blockquote>


<blockquote class="gmail_quote" style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0.8ex;border-left-width:1px;border-left-color:rgb(204, 204, 204);border-left-style:solid;padding-left:1ex">
<font face="&#39;courier new&#39;, monospace">[Thu Jul  8 19:00:13 2010] [crit]: Can&#39;t call method &quot;_Accessible&quot; on an undefined value at /usr/local/share/perl/5.10.0/DBIx/SearchBuilder/Record.pm line 423. (/opt/rt3/lib/RT.pm:382)</font></blockquote>


<blockquote class="gmail_quote" style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0.8ex;border-left-width:1px;border-left-color:rgb(204, 204, 204);border-left-style:solid;padding-left:1ex">
<font face="&#39;courier new&#39;, monospace">Can&#39;t call method &quot;_Accessible&quot; on an undefined value at /usr/local/share/perl/5.10.0/DBIx/SearchBuilder/Record.pm line 423.</font></blockquote>
</div><div><br></div><div>Thanks for the help.</div><div><br></div><font color="#888888"><div>Jonah Hirsch</div><div>-----------------------<br>
</div>
</font></blockquote></div><br></div>