Re: [rt-users] Error Condition Unimplemented in RT::Handle migration from 3.6.5 to 4.0.5 database
On Tue, Mar 20, 2012 at 12:06:46PM +0100, Juanjo wrote: >I installa the new scenario, dump the old database and import in the new > database. > >I try to upgrade the old to rt 4.0.5 installation. > >I do a Make initalize-database >import the rt3 database on rt4 database and do: > >./rt-setup-database --prompt-for-dba-password --action upgrade > >From 3.6.5 to 3.7.10 works fine > >but from 3.7.10 to 3.7.19 i get this error. > >Proceed [y/N]:y >Processing 3.7.15 >Now inserting data. >Processing 3.7.19 >Now inserting data. >Couldn't finish 'upgrade' step. > >ERROR: Couldn't load data from './etc/upgrade/3.7.19/content' for import: > >ERROR:RT::Scrip::Condition Unimplemented in RT::Handle. > (./etc/upgrade/3.7.19/content line 27) >Compilation failed in require at /opt/rt4/sbin/../lib/RT/Handle.pm line > 760. Try setting Set($LogToScreen,'debug') in your RT_SiteConfig.pm and run just the 3.7.19 step ./sbin/rt-setup-database --action insert --datadir etc/upgrade/3.7.19 It'd also be interesting to see what you have in your Scrips table. -kevin pgpntKHE3MFx8.pgp Description: PGP signature
Re: [rt-users] Renaming instance when no tickets
On Tue, Mar 20, 2012 at 06:19:21PM +0100, Guillaume Hilt wrote: > Still with RT 3.8.7, I updated rtname and rt organisation from > support.domain.tld to domain to match our company name. > > I don't have any tickets in the database. > > But, now, RT won't work, it fails to find the queue for the new > emails I sent : > temporary failure - RT couldn't find the queue: English Turn your RT logs up to debug and show the full logs. That looks like a mail log output. -kevin pgp2zj1Q8uV72.pgp Description: PGP signature
Re: [rt-users] Oddity within the RT database
On Mon, Mar 19, 2012 at 04:54:30PM +, Tim Cutts wrote: > It looks as though at some point, probably a long time ago during an upgrade, > that I accidentally ran part of the upgrade database task twice, and as a > result some of the standard portlet searches are duplicated: > > select id, Name from Attributes where ObjectType = 'RT::System' order by Name > > returns: > > id,Name > 1470,BrandedSubjectTag > 494,HomepageSettings > 497,HomepageSettings > 18200,QueueCacheNeedsUpdate > 498,"Search - Bookmarked Tickets" > 499,"Search - My Requested Tickets" > 492,"Search - My Tickets" > 495,"Search - My Tickets" > 493,"Search - Unowned Tickets" > 496,"Search - Unowned Tickets" > > Obviously in the RT-at-a-glance page, and in dashboard content pages, these > searches appear twice, which is a bit messy, if harmless. > > If I wanted to clean this up, obviously I could remove one of the duplicated > entries in each case, but then I presumably need to also sanitise where they > are referenced from. Are the references going to be embedded in blobs in > other Attributes? I can see some of them are referenced in the Name of some > other Attributes (for example Pref-RT::Attribute-492 and likewise 493 and > 496) which presumably could be fairly easily fixed with a simple update. But > I imagine these things are referenced within saved home page settings and > dashboards somewhere, which could be messy to fix. You can edit the global RT At a Glance to remove the dupes before shredding or deleting them, but keep in mind that individual users may have their own clone of HomepageSettings with their user-specific homepage and that's where you would run into problems with references to the deleted attribute. -kevin pgpiLlvobSSGT.pgp Description: PGP signature
Re: [rt-users] Name in use
On Tue, Mar 20, 2012 at 12:15:01PM +0100, Diego Roccia wrote: > I have RT4.0.5 with RT::Authen::ExternalAuth, and I'm experiencing exactly > this problem > > http://lists.fsck.com/pipermail/rt-users/2011-May/070489.html > > 1 - u...@domain1.com send an email -> the user is created and the ticket > opened > 2 - u...@domain2.com send an email -> the user is not created and the ticket > not opened, because of the "Name in use" problem > > my question is: is possible to have unprivileged users created without > stripping the @domain.tld part? Please show a sanitized version of your RT-Authen-ExternalAuth configuration. Also, please show us Name, RealName and EmailAddress for user 1. -kevin pgpzByAVDBFqa.pgp Description: PGP signature
Re: [rt-users] callback for autoclose in RT4
On Tue, Mar 20, 2012 at 10:34:42AM +0100, inb...@telenet.be wrote: > >We automatically close our tickets when replying to the requestor. > > > >In RT3 I changed .../Ticket/Update.html > > > >from: > > > >if ($DefaultStatus =~ '~new$') { > > > > $DefaultStatus = 'open'; > > > >} > > >>We actually removed this code in 4.0, because all the status changes > >>are controlled by Lifecycles or Scrips > > >*** If you use a scrip, the ticket will always be closed (it's a post > > action). > >Default behavior should be: close it, but users should be able to > > override this by selecting > >another status from the drop down box. > > >>That's what happens with On Correspond Open Ticket, the default RT > >>scrip. If you notice, you can pick Resolve on the list and it'll end > >>up resolved, even if you correspond. You can also use Lifecycles to > >>control some of the tabs that users use to get to the Reply page. > >>You may need to use a callback to modify the Menu that links Reply. > > Lifecycles can't do the trick for this scenario. > I'm trying to write a callback that changes the status depending on > comment/respond. > > SelectStatus DefaultLabel should become 'resolved' in the update.html screen > when you select Correspond. > SelectStatus DefaultLabel should stay unchanged in the update.html screen > when you select Comment. > > But I don't seem t find the correct 'hook' to do this. You want the Privileged callback in Elements/Tabs so you can change the arguments passed in the link. You'll need to poke around in the data structure you get back from PageMenu using the API in RT::Interface::Web::Menu. There's a wiki page about adding menu items you might find helpful. -kevin pgpbGk8DzAB1l.pgp Description: PGP signature
Re: [rt-users] What determines "external auth" vs. "local auth"
On Mon, Mar 19, 2012 at 04:12:56PM -0400, Jeff Blaine wrote: > When using RT-Extension-ExternalAuth, what is the logic for > determining whether to authenticate to the external source > or via RT's database? > > Will it always try the external source and then only use > local if that was a connection failure or similar? > > I hope 'root' never tried via external. Is that true? I suggest turning your preferred log mechanism up to 'debug' RT-Authen-ExternalAuth is quite chatty about who it's asking for information. -kevin pgp8fRfh6t4R3.pgp Description: PGP signature
Re: [rt-users] How to delete reminders of unexisted tickets
On Mon, Mar 19, 2012 at 06:52:02PM +0100, Wiktor Cetera wrote: >I`ve deleted all tickets from RT by Shredder, but I had active Reminders. >Now in the 'My Reminders' box i see information: "Couldn't find Ticket for > reminder 63. Please >contact administrator." > >How can I delete this? >From normal and root account I can`t find any suitable option. You can visit ticket 63 (which is a reminder) and mark it deleted and shred it later. You may want to use the with_linked feature for shredder in the future. There are also some branches open to help deal with the case where you remove the ticket a reminder refers to that should be available in future RT releases. -kevin pgpRrKlRTQ6Nv.pgp Description: PGP signature
Re: [rt-users] ExternalAuth problem
Hello, Turns out my problem was that when I added MergeUsers, I had both: Set( @Plugins, (qw( RT::Authen::ExternalAuth RT::Extension::LDAPImport RT::Extension::MergeUsers RT::Extension::CommandByMail))); And a separate line; Set(@Plugins, qw(RT::Extension::MergeUsers)); It appears RT was not happy with the duplicate settings. Never found a useful error message in the logs. Cheers, Sandra On 03/15/2012 04:24 PM, Sandra Wittenbrock wrote: Hello, About 6 months ago, I set up External Auth to use the ExternalAuth, with our ldap authentication server. Recently, it stopped working. I checked the syslog, and turned up the log level, but still did not get any useful error messages. Mar 15 13:12:15 hpcrdticket RT: FAILED LOGIN for sandra from xxx.xxx.xxx.xxx (/usr/share/request-tracker3.8/lib/RT/Interface/Web.pm:457) The same user was able to authenticate to the ldap service via another application. Using TCP dump on the RT server, I don't see any network traffic between the RT server and the ldap server, when I try to use ldap authentication. So, it looks like RT isn't trying to communicate with the LDAP server. I am able to see pings between the machines using tcpdump. Does anyone know how I can get some better log messages? Or better yet, have some good idea of where/why RT seems to not be enabling the ExteralAuth? As I mentioned, the config was working a couple weeks ago. Between when it was working and now, I did install mergeuser, so my users can use multiple email addresses to create tickets. You think the two could be interfering? I double checked the settings in RT_SiteConfig.pm. Set( @Plugins, (qw( RT::Authen::ExternalAuth RT::Extension::LDAPImport RT::Extension::MergeUsers RT::Extension::CommandByMail))); Regards, Sandra
Re: [rt-users] Error Condition Unimplemented in RT::Handle migration from 3.6.5 to 4.0.5 database
Anybody could help me? Thanks. El 20 de marzo de 2012 12:06, Juanjo escribió: > Hi again. > > I installa the new scenario, dump the old database and import in the new > database. > > I try to upgrade the old to rt 4.0.5 installation. > > I do a Make initalize-database > import the rt3 database on rt4 database and do: > > ./rt-setup-database --prompt-for-dba-password --action upgrade > > From 3.6.5 to 3.7.10 works fine > > but from 3.7.10 to 3.7.19 i get this error. > > Proceed [y/N]:y > Processing 3.7.15 > Now inserting data. > Processing 3.7.19 > Now inserting data. > Couldn't finish 'upgrade' step. > > ERROR: Couldn't load data from './etc/upgrade/3.7.19/content' for import: > > ERROR:RT::Scrip::Condition Unimplemented in RT::Handle. > (./etc/upgrade/3.7.19/content line 27) > Compilation failed in require at /opt/rt4/sbin/../lib/RT/Handle.pm line > 760. > > > Any help?? > Thanks > > Best regards. > > -- > Un saludo. > Juanjo Corral > -- Un saludo. Juanjo Corral
Re: [rt-users] RT 3.8.8 to RT 4.0.5 DB Upgrade Warning
On 3/20/2012 5:17 PM, UnixMan wrote: Thanks - do you know how I can rename it ? UPDATE Queues SET Name = '___Approvals' WHERE Name = 'Approvals';
Re: [rt-users] RT 3.8.8 to RT 4.0.5 DB Upgrade Warning
Thanks - do you know how I can rename it ? Thanks for all your efforts, Scott Thomas Sibley wrote: > > On 03/20/2012 04:59 PM, UnixMan wrote: >> ahh - here it is again with the right case : >> >> mysql> select Name from Queues; >> ++ >> | Name | >> ++ >> | A General Request | >> | Approvals | > > Someone renamed your ___Approvals queue to Approvals. RT's approvals > workflow won't work for you if you do that. You should rename it back > to ___Approvals (three leading underscores) before doing the upgrade to > 4.0.5. > > -- View this message in context: http://old.nabble.com/RT-3.8.8-to-RT-4.0.5-DB-Upgrade-Warning-tp33541424p33541764.html Sent from the Request Tracker - User mailing list archive at Nabble.com.
Re: [rt-users] RT 3.8.8 to RT 4.0.5 DB Upgrade Warning
On 03/20/2012 04:59 PM, UnixMan wrote: > ahh - here it is again with the right case : > > mysql> select Name from Queues; > ++ > | Name | > ++ > | A General Request | > | Approvals | Someone renamed your ___Approvals queue to Approvals. RT's approvals workflow won't work for you if you do that. You should rename it back to ___Approvals (three leading underscores) before doing the upgrade to 4.0.5.
Re: [rt-users] RT 3.8.8 to RT 4.0.5 DB Upgrade Warning
ahh - here it is again with the right case : mysql> select Name from Queues; ++ | Name | ++ | A General Request | | Approvals | | Audit-related | | backup issue | | Backup-related | | Data Center Issue | | Data Center Project| | Database Account | | Database Issue | | Database-clients | | Database-related | | DBA_Work_Tracking | | General_queue | | Infrastructure Service | | ldap-related | | nagios-related | | RT Configuration/Enhancement/Issue | ++ -- View this message in context: http://old.nabble.com/RT-3.8.8-to-RT-4.0.5-DB-Upgrade-Warning-tp33541424p33541655.html Sent from the Request Tracker - User mailing list archive at Nabble.com.
Re: [rt-users] RT 3.8.8 to RT 4.0.5 DB Upgrade Warning
ahh - here it is again with the right case : mysql> select Name from Queues; ++ | Name | ++ | A General Request | | Approvals | | Audit-related | | backup issue | | Backup-related | | Data Center Issue | | Data Center Project| | Database Account | | Database Issue | | Database-clients | | Database-related | | DBA_Work_Tracking | | General_queue | | Infrastructure Service | | ldap-related | | nagios-related | | RT Configuration/Enhancement/Issue | ++ UnixMan wrote: > > I do the below and it looks like the queues table exists though : > > mysql> show tables; > +-+ > | Tables_in_rt405 | > +-+ > | ACL | > | AT_Assets | > | AT_IPs | > | AT_Ports| > | AT_Types| > | Articles| > | Attachments | > | Attributes | > | CachedGroupMembers | > | Classes | > | CustomFieldValues | > | CustomFields| > | FM_Articles | > | FM_Classes | > | FM_ObjectTopics | > | FM_Topics | > | GroupMembers| > | Groups | > | Links | > | ObjectClasses | > | ObjectCustomFieldValues | > | ObjectCustomFields | > | ObjectTopics| > | Principals | > | Queues | > | ScripActions| > | ScripConditions | > | Scrips | > | Templates | > | Tickets | > | Topics | > | Transactions| > | Users | > | sessions| > +-+ > 34 rows in set (0.01 sec) > > > > > UnixMan wrote: >> >> I get : >> >> mysql> select name from queues; >> ERROR 1146 (42S02): Table 'rt405.queues' doesn't exist >> >> I ran this on the source system too and get the same thing for its rt388 >> DB >> >> >> >> >> Thomas Sibley wrote: >>> >>> On 03/20/2012 04:02 PM, senior.unix wrote: I'm getting the below warning when I'm upgrading my RT 3.8.8 mySQL DB to RT 4.0.5. I checked the source DB I used mysql> SELECT * FROM `rt388`.`Tickets` where Type = 'approval'; and the upgraded DB using the below command mysql> SELECT * FROM `rt405`.`Tickets` where Type = 'approval'; >>> >>> Tickets of a certain type have nothing to do with the warning about a >>> _queue_. What does 'select Name from Queues;' return? >>> >>> Not having an ___Approvals queue will be... interesting. >>> >>> >> >> > > -- View this message in context: http://old.nabble.com/RT-3.8.8-to-RT-4.0.5-DB-Upgrade-Warning-tp33541424p33541557.html Sent from the Request Tracker - User mailing list archive at Nabble.com.
Re: [rt-users] RT 3.8.8 to RT 4.0.5 DB Upgrade Warning
I do the below and it looks like the queues table exists though : mysql> show tables; +-+ | Tables_in_rt405 | +-+ | ACL | | AT_Assets | | AT_IPs | | AT_Ports| | AT_Types| | Articles| | Attachments | | Attributes | | CachedGroupMembers | | Classes | | CustomFieldValues | | CustomFields| | FM_Articles | | FM_Classes | | FM_ObjectTopics | | FM_Topics | | GroupMembers| | Groups | | Links | | ObjectClasses | | ObjectCustomFieldValues | | ObjectCustomFields | | ObjectTopics| | Principals | | Queues | | ScripActions| | ScripConditions | | Scrips | | Templates | | Tickets | | Topics | | Transactions| | Users | | sessions| +-+ 34 rows in set (0.01 sec) UnixMan wrote: > > I get : > > mysql> select name from queues; > ERROR 1146 (42S02): Table 'rt405.queues' doesn't exist > > I ran this on the source system too and get the same thing for its rt388 > DB > > > > > Thomas Sibley wrote: >> >> On 03/20/2012 04:02 PM, senior.unix wrote: >>> I'm getting the below warning when I'm upgrading my RT 3.8.8 mySQL DB to >>> RT 4.0.5. >>> >>> I checked the source DB I used >>> mysql> SELECT * FROM `rt388`.`Tickets` where Type = 'approval'; >>> >>> and the upgraded DB using the below command >>> mysql> SELECT * FROM `rt405`.`Tickets` where Type = 'approval'; >> >> Tickets of a certain type have nothing to do with the warning about a >> _queue_. What does 'select Name from Queues;' return? >> >> Not having an ___Approvals queue will be... interesting. >> >> > > -- View this message in context: http://old.nabble.com/RT-3.8.8-to-RT-4.0.5-DB-Upgrade-Warning-tp33541424p33541546.html Sent from the Request Tracker - User mailing list archive at Nabble.com.
Re: [rt-users] RT 3.8.8 to RT 4.0.5 DB Upgrade Warning
On 03/20/2012 04:39 PM, UnixMan wrote: > mysql> select name from queues; > ERROR 1146 (42S02): Table 'rt405.queues' doesn't exist > > I ran this on the source system too and get the same thing for its rt388 DB You didn't type the query I typed, you lowercased it. See below: > Thomas Sibley wrote: >> Tickets of a certain type have nothing to do with the warning about a >> _queue_. What does 'select Name from Queues;' return? >> >> Not having an ___Approvals queue will be... interesting.
Re: [rt-users] RT 3.8.8 to RT 4.0.5 DB Upgrade Warning
I get : mysql> select name from queues; ERROR 1146 (42S02): Table 'rt405.queues' doesn't exist I ran this on the source system too and get the same thing for its rt388 DB Thomas Sibley wrote: > > On 03/20/2012 04:02 PM, senior.unix wrote: >> I'm getting the below warning when I'm upgrading my RT 3.8.8 mySQL DB to >> RT 4.0.5. >> >> I checked the source DB I used >> mysql> SELECT * FROM `rt388`.`Tickets` where Type = 'approval'; >> >> and the upgraded DB using the below command >> mysql> SELECT * FROM `rt405`.`Tickets` where Type = 'approval'; > > Tickets of a certain type have nothing to do with the warning about a > _queue_. What does 'select Name from Queues;' return? > > Not having an ___Approvals queue will be... interesting. > > -- View this message in context: http://old.nabble.com/RT-3.8.8-to-RT-4.0.5-DB-Upgrade-Warning-tp33541424p33541521.html Sent from the Request Tracker - User mailing list archive at Nabble.com.
Re: [rt-users] RT 3.8.8 to RT 4.0.5 DB Upgrade Warning
On 03/20/2012 04:02 PM, senior.unix wrote: > I'm getting the below warning when I'm upgrading my RT 3.8.8 mySQL DB to > RT 4.0.5. > > I checked the source DB I used > mysql> SELECT * FROM `rt388`.`Tickets` where Type = 'approval'; > > and the upgraded DB using the below command > mysql> SELECT * FROM `rt405`.`Tickets` where Type = 'approval'; Tickets of a certain type have nothing to do with the warning about a _queue_. What does 'select Name from Queues;' return? Not having an ___Approvals queue will be... interesting.
[rt-users] RT 3.8.8 to RT 4.0.5 DB Upgrade Warning
I'm getting the below warning when I'm upgrading my RT 3.8.8 mySQL DB to RT 4.0.5. I checked the source DB I used mysql> SELECT * FROM `rt388`.`Tickets` where Type = 'approval'; and the upgraded DB using the below command mysql> SELECT * FROM `rt405`.`Tickets` where Type = 'approval'; and all looks the same. It appears that this is a benign Warning I just need to clarify because it will soon be the prod RT instance. Other than this and the RTFM error (the upgrade script worked flawlessly) the rest of the DB upgrade went very well. Thanks for all your help, Scott --- Enter RT version if you want to stop upgrade at some point, or leave it blank if you want apply above upgrades: IT'S VERY IMPORTANT TO BACK UP BEFORE THIS STEP Proceed [y/N]:y Processing 3.8.9 Now inserting data. Processing 3.9.1 Now inserting data. Processing 3.9.2 Now inserting data. Processing 3.9.3 Now populating database schema. Processing 3.9.5 Now populating database schema. Processing 3.9.6 Now populating database schema. Processing 3.9.7 Now populating database schema. Now inserting data. Processing 3.9.8 Now populating database schema. Now inserting data. [Tue Mar 20 19:40:37 2012] [error]: We found RTFM tables in your database. Checking for content. (./etc/upgrade/3.9.8/content:17) [Tue Mar 20 19:40:37 2012] [error]: You appear to have RTFM Articles. You can upgrade using the etc/upgrade/upgrade-articles script. Read more about it in UPGRADING (./etc/upgrade/3.9.8/content:22) Processing 4.0.0rc2 Now populating database schema. Processing 4.0.0rc4 Now populating database schema. Processing 4.0.0rc7 Now inserting data. [Tue Mar 20 19:40:41 2012] [warning]: There is no ___Approvals queue in the DB (./etc/upgrade/4.0.0rc7/content:8) Processing 4.0.1 Now inserting data. Processing 4.0.3 Now inserting data. Processing 4.0.4 Now inserting data. Done.
[rt-users] Renaming instance when no tickets
Hi all, Still with RT 3.8.7, I updated rtname and rt organisation from support.domain.tld to domain to match our company name. I don't have any tickets in the database. But, now, RT won't work, it fails to find the queue for the new emails I sent : temporary failure - RT couldn't find the queue: English Any idea ? Thanks, -- Guillaume Hilt
Re: [rt-users] ERD (with relationships) for MySQL databases for versions 3.8.8 and 4.0.5 of RT?
On 03/20/2012 12:28 PM, Jeff Lucas wrote: > Hello folks. > Does anybody have an ERD (with relationships) for the databases for > version 3.8.8 and 4.0.5 of RT? I tried to create one with MySQL > Workbench but all I can get is primary keys, are there any foreign keys > or are the relationships defined anywhere? If it includes Asset > Tracker, that would be a bonus! FK relationships aren't enforced at the database level. Refer to http://requesttracker.wikia.com/wiki/DBSchema for a start. There is a relationship diagram that ships with RT, which is rendered on the wiki.
[rt-users] ERD (with relationships) for MySQL databases for versions 3.8.8 and 4.0.5 of RT?
Hello folks. Does anybody have an ERD (with relationships) for the databases for version 3.8.8 and 4.0.5 of RT? I tried to create one with MySQL Workbench but all I can get is primary keys, are there any foreign keys or are the relationships defined anywhere? If it includes Asset Tracker, that would be a bonus! Thanks in advance! -Jeff
Re: [rt-users] Oddity within the RT database
On 20 Mar 2012, at 10:52, Ruslan Zakirov wrote: > > > Ruslan from phone. > 20.03.2012 14:31 пользователь "Tim Cutts" написал: > > > > > > On 20 Mar 2012, at 08:26, Ruslan Zakirov wrote: > > > > > Have you tried to delete them in ui? > > > > Is that possible? These don't show up in the query builder is loadable > > saved searches - they're the RT::System standard ones, not user or group > > saved searches. > > > > > Use rt-attributes viewer that is shipped with rt and installed into sbin > > > directory. > > > > I've been using that to investigate them, yes. > > > > > Decide which one you need and just delete an attribute. > > > > From what I can see, both are in use by the various dashboards and things > > that users have set. I think I may have to write a script to go through > > all the Attributes blob, and for these duplicated things set them to one > > particular one, and only once I've done that can I safely delete the > > redundant saved search. > > This is better way to go. Yep. After all that care, it turned out only one dashboard needed updating before I deleted the duplicate rows, but for the record here's what I did. Up front information: Two system saved searches were duplicated, so I wanted to replace references to search 495 with 492, and search 496 with 493. Step 1, update Dashboard references to the redundant searches, for which I used the script attached at the end of this mail. Step 2, with straightforwards SQL, rename preferences associated with the redundant searches: UPDATE Attributes SET Name = 'Pref-RT::Attribute-492' WHERE Name = 'Pref-RT::Attribute-495'; UPDATE Attributes SET Name = 'Pref-RT::Attribute-493' WHERE Name = 'Pref-RT::Attribute-496'; Step 3, delete the redundant searches: DELETE FROM Attributes WHERE id = 495; DELETE FROM Attributes WHERE id = 496; I think that's about all that's required. Certainly no-one's screaming... I don't think anything's needed for homepage portlet preferences, since those appear to be store by search name rather than by id. It's possible some users might have saved graphs, but I think I'll cross that bridge if someone complains, because the numbers will be single digits. I'd always assumed that the home page was simply a special case of a dashboard, and was rather surprised to see that the implementation is completely different. Is that for historical reasons? I'm trying to remember - I suspect the customisable homepage was written first (3.6?) and dashboards came later (3.8?). Regards, Tim PS. Here's my little script: #!/usr/bin/perl use strict; use warnings; use lib qw(/opt/rt4/lib /opt/rt4/local/lib); use Data::Dumper; use RT; use RT::Attributes; use RT::Dashboard; use RT::User; RT::LoadConfig(); RT::Init(); # These are the system search id's I want to map across my %attr_map = ( 495 => 492, 496 => 493 ); my $attributes = RT::Attributes->new(RT->SystemUser); my $dashboard = RT::Dashboard->new(RT->SystemUser); my $user = RT::User->new(RT->SystemUser); $attributes->Limit( FIELD => 'Name', VALUE => 'Dashboard'); my ($res, $err); while (my $attr = $attributes->Next) { # RT::SystemUser has no rights to load user's # dashboards, so we load the creating user's object to # use when loading the dashboard. ($res, $err) = $user->LoadById($attr->Creator); unless ($res) { warn "Could not load user: ", $attr->Creator, $err; next; } my $dashboard = RT::Dashboard->new($user); ($res, $err) = $dashboard->LoadById($attr->Id); unless ($res) { warn "Could not load dashboard ", $attr->Id, " as user ", $user->Name, ":", $err; next; } my ($pane, $portlets); my $panes = $dashboard->Panes; my $before = Dumper($panes); while (($pane, $portlets) = each %$panes) { foreach my $portlet (@$portlets) { next unless ($portlet->{portlet_type} eq 'search'); if (exists($attr_map{$portlet->{id}})) { $portlet->{id} = $attr_map{$portlet->{id}}; } } } my $after = Dumper($panes); if ($before ne $after) { ($res, $err) = $dashboard->Update(Panes => $panes); if ($res) { printf q( User: %s Dashboard: %s (%d) Before: %s After: %s ), $user->Name, $dashboard->Name, $dashboard->Id, $before, $after; } else { warn "Failed to update dashboard ", $dashboard->Id, ': ', $err; } } } -- The Wellcome Trust Sanger Institute is operated by Genome Research Limited, a charity registered in England with number 1021457 and a company registered in England with number 2742969, whose registered office is 215 Euston Road, London, NW1 2BE.
[rt-users] Migrate Tickets from Trac to RT
Hello, I was wondering if there are any tips/guides on migrating tickets from Trac to RT? Thanks, Tom
Re: [rt-users] Create an user using Rest API
Ok, I just noticed that, despite the error, the users were created in the database. Strange, but as long as it works. Guillaume Hilt Le 20/03/2012 14:16, Guillaume Hilt a écrit : No, I got no users right now, it's a fresh install. I tried again, adding Password and Privileged fields, same error. Guillaume Hilt Le 20/03/2012 14:13, sunnavy a écrit : Is it possible that user "test" already exists? sunnavy On 12-03-20 13:38, Guillaume Hilt wrote: Hello, I'd like to create an user using RT API (with RT 3.8.7 on Ubuntu 10.04). I tried in PHP with a request to /user/new using this post data : id: user/new Name: test EmailAddress: t...@test.com RealName: test Lang: fr-fr Organization: test But all I got is a bad quest error : RT/3.8.7 400 Bad Request # Could not create user. Is it possible ? Regards, -- Guillaume Hilt
Re: [rt-users] Create an user using Rest API
No, I got no users right now, it's a fresh install. I tried again, adding Password and Privileged fields, same error. Guillaume Hilt Le 20/03/2012 14:13, sunnavy a écrit : Is it possible that user "test" already exists? sunnavy On 12-03-20 13:38, Guillaume Hilt wrote: Hello, I'd like to create an user using RT API (with RT 3.8.7 on Ubuntu 10.04). I tried in PHP with a request to /user/new using this post data : id: user/new Name: test EmailAddress: t...@test.com RealName: test Lang: fr-fr Organization: test But all I got is a bad quest error : RT/3.8.7 400 Bad Request # Could not create user. Is it possible ? Regards, -- Guillaume Hilt
Re: [rt-users] Create an user using Rest API
Is it possible that user "test" already exists? sunnavy On 12-03-20 13:38, Guillaume Hilt wrote: > Hello, > > I'd like to create an user using RT API (with RT 3.8.7 on Ubuntu 10.04). > > I tried in PHP with a request to /user/new using this post data : > id: user/new > Name: test > EmailAddress: t...@test.com > RealName: test > Lang: fr-fr > Organization: test > > But all I got is a bad quest error : > > RT/3.8.7 400 Bad Request > > # Could not create user. > > Is it possible ? > > Regards, > > -- > Guillaume Hilt >
Re: [rt-users] Name in use
On 03/20/2012 07:15 AM, Diego Roccia wrote: > I have RT4.0.5 with RT::Authen::ExternalAuth, and I'm experiencing exactly > this problem > > http://lists.fsck.com/pipermail/rt-users/2011-May/070489.html > > 1 - u...@domain1.com send an email -> the user is created and the ticket > opened > 2 - u...@domain2.com send an email -> the user is not created and the ticket > not opened, because of the "Name in use" problem Did you read the rest of the thread? Click the Next Message link a few times. You are probably matching users based on the realname or something else equally non-unique. Send your config to the list. > my question is: is possible to have unprivileged users created without > stripping the @domain.tld part? Yes, that's the default behaviour.
[rt-users] Create an user using Rest API
Hello, I'd like to create an user using RT API (with RT 3.8.7 on Ubuntu 10.04). I tried in PHP with a request to /user/new using this post data : id: user/new Name: test EmailAddress: t...@test.com RealName: test Lang: fr-fr Organization: test But all I got is a bad quest error : RT/3.8.7 400 Bad Request # Could not create user. Is it possible ? Regards, -- Guillaume Hilt
[rt-users] Name in use
Hi All, I have RT4.0.5 with RT::Authen::ExternalAuth, and I'm experiencing exactly this problem http://lists.fsck.com/pipermail/rt-users/2011-May/070489.html 1 - u...@domain1.com send an email -> the user is created and the ticket opened 2 - u...@domain2.com send an email -> the user is not created and the ticket not opened, because of the "Name in use" problem my question is: is possible to have unprivileged users created without stripping the @domain.tld part? thanks -- Diego Roccia System & Network Admin - Subito.it Via della Moscova 3 - Milano www.subito.it
[rt-users] Error Condition Unimplemented in RT::Handle migration from 3.6.5 to 4.0.5 database
Hi again. I installa the new scenario, dump the old database and import in the new database. I try to upgrade the old to rt 4.0.5 installation. I do a Make initalize-database import the rt3 database on rt4 database and do: ./rt-setup-database --prompt-for-dba-password --action upgrade >From 3.6.5 to 3.7.10 works fine but from 3.7.10 to 3.7.19 i get this error. Proceed [y/N]:y Processing 3.7.15 Now inserting data. Processing 3.7.19 Now inserting data. Couldn't finish 'upgrade' step. ERROR: Couldn't load data from './etc/upgrade/3.7.19/content' for import: ERROR:RT::Scrip::Condition Unimplemented in RT::Handle. (./etc/upgrade/3.7.19/content line 27) Compilation failed in require at /opt/rt4/sbin/../lib/RT/Handle.pm line 760. Any help?? Thanks Best regards. -- Un saludo. Juanjo Corral
Re: [rt-users] How to automatically activate/enable created accounts.
You can do it with a scrip that checks creator's record and makes user privileged and enabled. Ruslan from phone. 20.03.2012 13:00 пользователь "Adrian Stel" написал: > Hi, > > > > I would like to automatically activate/enable accounts when account > are created. > Right now when accounts are created I must go to "Access control" and > check: "Let this user access RT" and "Let this user be granted rights > (Privileged)". In my case when some accounts are created automatically > a would be nice to make automatically active this account. > > > > > > > -- > Best Regards > Adrian Stelmaszyk >
Re: [rt-users] Oddity within the RT database
Ruslan from phone. 20.03.2012 14:31 пользователь "Tim Cutts" написал: > > > On 20 Mar 2012, at 08:26, Ruslan Zakirov wrote: > > > Have you tried to delete them in ui? > > Is that possible? These don't show up in the query builder is loadable saved searches - they're the RT::System standard ones, not user or group saved searches. > > > Use rt-attributes viewer that is shipped with rt and installed into sbin directory. > > I've been using that to investigate them, yes. > > > Decide which one you need and just delete an attribute. > > From what I can see, both are in use by the various dashboards and things that users have set. I think I may have to write a script to go through all the Attributes blob, and for these duplicated things set them to one particular one, and only once I've done that can I safely delete the redundant saved search. This is better way to go. > > > As far as I recall dashboards handle this properly. > > If they referred to their saved searches by name, they probably would, but judging by the output of rt-attributes-viewer, they're referring to them by id. > > This could be a fun script to write... :-) Nothing extream, enough examples in rt code and easy to find them. > > Tim > > -- > The Wellcome Trust Sanger Institute is operated by Genome Research > Limited, a charity registered in England with number 1021457 and a > company registered in England with number 2742969, whose registered > office is 215 Euston Road, London, NW1 2BE.
Re: [rt-users] Oddity within the RT database
On 20 Mar 2012, at 08:26, Ruslan Zakirov wrote: > Have you tried to delete them in ui? Is that possible? These don't show up in the query builder is loadable saved searches - they're the RT::System standard ones, not user or group saved searches. > Use rt-attributes viewer that is shipped with rt and installed into sbin > directory. I've been using that to investigate them, yes. > Decide which one you need and just delete an attribute. From what I can see, both are in use by the various dashboards and things that users have set. I think I may have to write a script to go through all the Attributes blob, and for these duplicated things set them to one particular one, and only once I've done that can I safely delete the redundant saved search. > As far as I recall dashboards handle this properly. If they referred to their saved searches by name, they probably would, but judging by the output of rt-attributes-viewer, they're referring to them by id. This could be a fun script to write... :-) Tim -- The Wellcome Trust Sanger Institute is operated by Genome Research Limited, a charity registered in England with number 1021457 and a company registered in England with number 2742969, whose registered office is 215 Euston Road, London, NW1 2BE.
Re: [rt-users] callback for autoclose in RT4
>We automatically close our tickets when replying to the requestor. > >In RT3 I changed .../Ticket/Update.html > >from: > >if ($DefaultStatus =~ '~new$') { > > $DefaultStatus = 'open'; > >} >>We actually removed this code in 4.0, because all the status changes >>are controlled by Lifecycles or Scrips >*** If you use a scrip, the ticket will always be closed (it's a post > action). >Default behavior should be: close it, but users should be able to override > this by selecting >another status from the drop down box. >>That's what happens with On Correspond Open Ticket, the default RT >>scrip. If you notice, you can pick Resolve on the list and it'll end >>up resolved, even if you correspond. You can also use Lifecycles to >>control some of the tabs that users use to get to the Reply page. >>You may need to use a callback to modify the Menu that links Reply. Lifecycles can't do the trick for this scenario. I'm trying to write a callback that changes the status depending on comment/respond. SelectStatus DefaultLabel should become 'resolved' in the update.html screen when you select Correspond. SelectStatus DefaultLabel should stay unchanged in the update.html screen when you select Comment. But I don't seem t find the correct 'hook' to do this.
[rt-users] How to automatically activate/enable created accounts.
Hi, I would like to automatically activate/enable accounts when account are created. Right now when accounts are created I must go to "Access control" and check: "Let this user access RT" and "Let this user be granted rights (Privileged)". In my case when some accounts are created automatically a would be nice to make automatically active this account. -- Best Regards Adrian Stelmaszyk
Re: [rt-users] Oddity within the RT database
Have you tried to delete them in ui? Use rt-attributes viewer that is shipped with rt and installed into sbin directory. Decide which one you need and just delete an attribute. As far as I recall dashboards handle this properly. Ruslan from phone. 19.03.2012 20:54 пользователь "Tim Cutts" написал: > > It looks as though at some point, probably a long time ago during an upgrade, that I accidentally ran part of the upgrade database task twice, and as a result some of the standard portlet searches are duplicated: > > select id, Name from Attributes where ObjectType = 'RT::System' order by Name > > returns: > > id,Name > 1470,BrandedSubjectTag > 494,HomepageSettings > 497,HomepageSettings > 18200,QueueCacheNeedsUpdate > 498,"Search - Bookmarked Tickets" > 499,"Search - My Requested Tickets" > 492,"Search - My Tickets" > 495,"Search - My Tickets" > 493,"Search - Unowned Tickets" > 496,"Search - Unowned Tickets" > > Obviously in the RT-at-a-glance page, and in dashboard content pages, these searches appear twice, which is a bit messy, if harmless. > > If I wanted to clean this up, obviously I could remove one of the duplicated entries in each case, but then I presumably need to also sanitise where they are referenced from. Are the references going to be embedded in blobs in other Attributes? I can see some of them are referenced in the Name of some other Attributes (for example Pref-RT::Attribute-492 and likewise 493 and 496) which presumably could be fairly easily fixed with a simple update. But I imagine these things are referenced within saved home page settings and dashboards somewhere, which could be messy to fix. > > Any thoughts? > > Tim > > -- > The Wellcome Trust Sanger Institute is operated by Genome Research > Limited, a charity registered in England with number 1021457 and a > company registered in England with number 2742969, whose registered > office is 215 Euston Road, London, NW1 2BE.
Re: [rt-users] User performance reporting
Try SLA extension from repository, there is a branch that implements this report. Ruslan from phone. 20.03.2012 0:38 пользователь "David Hollinger" написал: > I’m looking for an effective way to create/run a report on tickets from a > specific queue, with specific owners and find out how often during the > tickets’ lifetime (from open to close) the owner missed the response Due > Date (as set by SLA). I want the report to return every instance that a > ticket has a missed Due Date, showing the columns for ticket number, Due > Date, the corresponding update transaction for that Due Date (our Due Dates > update every time there is a response, until close), and the ticket > Priority. Any suggestions? > > ** ** > > ** ** > > ** ** > > *David Hollinger III* > > *IT Infrastructure Coordinator* > > *Handwriting Without Tears* > > *(301)263-2700 ext 285* > > *(402)430-3127* > > ** ** >