Re: [rt-users] Error in article history

2013-11-04 Thread Guadagnino Cristiano
Hi all,
I'm replying here to document where the problem lies and how I solved it.

The problem: it seems that the 'upgrade-articles' script somehow doesn't update 
all records in the ObjectCustomFieldValues table. Specifically, it only updates 
articles that have the 'Disabled' flag set to 0. Those that have 'Disabled' set 
to 1 (i.e. the old revisions of an article) retain the old (now wrong) 
ObjectType.

If you have mysql, you can check for this type of problem by running this query 
against your rt4 database:
select Disabled, ObjectType, count(*)
from ObjectCustomFieldValues
where ObjectType like '%article%'
group by Disabled, ObjectType;

If you see a row where ObjectType = 'RT::FM::Article', than you have the 
problem.

I fixed the problem with this simple update:
update ObjectCustomFieldValues
set ObjectType = 'RT::Article'
where ObjectType = 'RT::FM::Article'

I hope this can help others having this problem.

Bye
Cris



Da: Guadagnino Cristiano 
<mailto:guadagnino.cristi...@creval.it>
Inviato: Fri Oct 18 2013 10:45:30 GMT+0200 (CEST)
A: rt-users@lists.bestpractical.com<mailto:rt-users@lists.bestpractical.com> 
<mailto:rt-users@lists.bestpractical.com>
Oggetto: Re: [rt-users] Error in article history
Hi Kevin,
it's been quite some time since we migrted to RT 4.
Fortunately, I have a migration procedure I wrote down while migrating our test 
environment, so that I could re-apply the same steps in production.

We migrated to RT 4 while also migrating to new CentOS servers, so this is what 
I did after installing the servers and downbloading all the required components 
(packages):

- I followed RT's README till step 6a
- in step 6a I only did the first part (i.e. I did not do "make initialize 
database")
- I restored the backup from our RT 3.x production system (in rt4 db)
- I did "make upgrade database" from step 6b
- I ran ./etc/upgrade/upgrade-articles from the directory where I uncompressed 
the tarball

I think this is the relevant part.
Then I followed by porting my old Apache/sendmail/Sphinx configurations to the 
new servers, etc.

Is that enough? Or, is there something more I should have done?

Thank you
Cris



Cristiano Guadagnino

Servizio Data Administration
___
Bankadati Servizi Informatici Soc.Cons.P.A.
Gruppo bancario Credito Valtellinese
Via Trento, 22 - 23100 SONDRIO
tel +39 0342522172  - fax +39 0342522992
guadagnino.cristi...@creval.it<mailto:guadagnino.cristi...@creval.it>
www.creval.it<http://www.creval.it>

[Seguici suFacebook]<https://www.facebook.com/creval/>  [Creval 
Tube] <http://www.youtube.com/user/GruppoCreval/>   [CrevalApp] 
<https://www.creval.it/comunicazione/appICreval/appICreval.html>

Il presente messaggio non è di natura personale ma inviato per esigenze 
lavorative; l’eventuale messaggio di risposta potrà essere conosciuto anche da 
altri soggetti diversi dall’originatore di questo messaggio per dette esigenze 
o per controllo aziendale. Questo messaggio, corredato dei relativi allegati, 
contiene informazioni da considerarsi strettamente riservate, ed è destinato 
esclusivamente al destinatario sopra indicato, il quale è l'unico autorizzato 
ad usarlo, copiarlo e, sotto la propria responsabilità, diffonderlo. Chiunque 
ricevesse questo messaggio per errore o comunque lo leggesse senza esserne 
legittimato è avvertito che trattenerlo, copiarlo, divulgarlo, distribuirlo a 
persone diverse dal destinatario è severamente proibito, ed è pregato di 
rinviarlo immediatamente al mittente distruggendone l'originale.


Da: Kevin Falcone <mailto:falc...@bestpractical.com>
Inviato: Thu Oct 17 2013 16:40:50 GMT+0200 (CEST)
A: rt-users@lists.bestpractical.com<mailto:rt-users@lists.bestpractical.com>
Oggetto: Re: [rt-users] Error in article history

On Thu, Oct 17, 2013 at 08:33:27AM +, Guadagnino Cristiano wrote:


   How can I verify the ObjectTypes? Would you be so kind to send me a query to 
run against mysql
   to verify that everything is ok with my articles?


You'll need to write your own SQL query - as noted previously, you're
looking for RT::FM::Article in the ObjectType field on Transactions
and ObjectCustomFieldValues.

Also - please confirm which upgrade steps you ran.  There is a
standalone documented and warned about script you must run to upgrade
articles.

-kevin



 You likely still have a Transaction record or ObjectCustomFieldValue
 record with the wrong ObjectType that those scripts should have fixed
 for you.


--

--
<><><>

Re: [rt-users] Error in article history

2013-10-18 Thread Guadagnino Cristiano
Hi Kevin,
it's been quite some time since we migrted to RT 4.
Fortunately, I have a migration procedure I wrote down while migrating our test 
environment, so that I could re-apply the same steps in production.

We migrated to RT 4 while also migrating to new CentOS servers, so this is what 
I did after installing the servers and downbloading all the required components 
(packages):

- I followed RT's README till step 6a
- in step 6a I only did the first part (i.e. I did not do "make initialize 
database")
- I restored the backup from our RT 3.x production system (in rt4 db)
- I did "make upgrade database" from step 6b
- I ran ./etc/upgrade/upgrade-articles from the directory where I uncompressed 
the tarball

I think this is the relevant part.
Then I followed by porting my old Apache/sendmail/Sphinx configurations to the 
new servers, etc.

Is that enough? Or, is there something more I should have done?

Thank you
Cris



Cristiano Guadagnino

Servizio Data Administration
___
Bankadati Servizi Informatici Soc.Cons.P.A.
Gruppo bancario Credito Valtellinese
Via Trento, 22 - 23100 SONDRIO
tel +39 0342522172  - fax +39 0342522992
guadagnino.cristi...@creval.it
www.creval.it<http://www.creval.it>

[Seguici su Facebook]<https://www.facebook.com/creval/>  [Creval Tube] 
<http://www.youtube.com/user/GruppoCreval/>   [CrevalApp] 
<https://www.creval.it/comunicazione/appICreval/appICreval.html>

Il presente messaggio non è di natura personale ma inviato per esigenze 
lavorative; l'eventuale messaggio di risposta potrà essere conosciuto anche da 
altri soggetti diversi dall'originatore di questo messaggio per dette esigenze 
o per controllo aziendale. Questo messaggio, corredato dei relativi allegati, 
contiene informazioni da considerarsi strettamente riservate, ed è destinato 
esclusivamente al destinatario sopra indicato, il quale è l'unico autorizzato 
ad usarlo, copiarlo e, sotto la propria responsabilità, diffonderlo. Chiunque 
ricevesse questo messaggio per errore o comunque lo leggesse senza esserne 
legittimato è avvertito che trattenerlo, copiarlo, divulgarlo, distribuirlo a 
persone diverse dal destinatario è severamente proibito, ed è pregato di 
rinviarlo immediatamente al mittente distruggendone l'originale.


Da: Kevin Falcone <mailto:falc...@bestpractical.com>
Inviato: Thu Oct 17 2013 16:40:50 GMT+0200 (CEST)
A: rt-users@lists.bestpractical.com<mailto:rt-users@lists.bestpractical.com>
Oggetto: Re: [rt-users] Error in article history

On Thu, Oct 17, 2013 at 08:33:27AM +, Guadagnino Cristiano wrote:


   How can I verify the ObjectTypes? Would you be so kind to send me a query to 
run against mysql
   to verify that everything is ok with my articles?


You'll need to write your own SQL query - as noted previously, you're
looking for RT::FM::Article in the ObjectType field on Transactions
and ObjectCustomFieldValues.

Also - please confirm which upgrade steps you ran.  There is a
standalone documented and warned about script you must run to upgrade
articles.

-kevin



 You likely still have a Transaction record or ObjectCustomFieldValue
 record with the wrong ObjectType that those scripts should have fixed
 for you.


--
<><><>

Re: [rt-users] Error in article history

2013-10-17 Thread Kevin Falcone
On Thu, Oct 17, 2013 at 08:33:27AM +, Guadagnino Cristiano wrote:
>How can I verify the ObjectTypes? Would you be so kind to send me a query 
> to run against mysql
>to verify that everything is ok with my articles?

You'll need to write your own SQL query - as noted previously, you're
looking for RT::FM::Article in the ObjectType field on Transactions
and ObjectCustomFieldValues.

Also - please confirm which upgrade steps you ran.  There is a
standalone documented and warned about script you must run to upgrade
articles.

-kevin

>  You likely still have a Transaction record or ObjectCustomFieldValue
>  record with the wrong ObjectType that those scripts should have fixed
>  for you.


pgpHZI7y9onsw.pgp
Description: PGP signature


Re: [rt-users] Error in article history

2013-10-17 Thread Guadagnino Cristiano
Kevin,
I did run all the upgrade steps.

How can I verify the ObjectTypes? Would you be so kind to send me a query to 
run against mysql to verify that everything is ok with my articles?

T.I.A.

Cris


Cristiano Guadagnino

Servizio Data Administration
___
Bankadati Servizi Informatici Soc.Cons.P.A.
Gruppo bancario Credito Valtellinese
Via Trento, 22 - 23100 SONDRIO
tel +39 0342522172  - fax +39 0342522992
guadagnino.cristi...@creval.it
www.creval.it<http://www.creval.it>

[Seguici su Facebook]<https://www.facebook.com/creval/>  [Creval Tube] 
<http://www.youtube.com/user/GruppoCreval/>   [CrevalApp] 
<https://www.creval.it/comunicazione/appICreval/appICreval.html>

Il presente messaggio non è di natura personale ma inviato per esigenze 
lavorative; l'eventuale messaggio di risposta potrà essere conosciuto anche da 
altri soggetti diversi dall'originatore di questo messaggio per dette esigenze 
o per controllo aziendale. Questo messaggio, corredato dei relativi allegati, 
contiene informazioni da considerarsi strettamente riservate, ed è destinato 
esclusivamente al destinatario sopra indicato, il quale è l'unico autorizzato 
ad usarlo, copiarlo e, sotto la propria responsabilità, diffonderlo. Chiunque 
ricevesse questo messaggio per errore o comunque lo leggesse senza esserne 
legittimato è avvertito che trattenerlo, copiarlo, divulgarlo, distribuirlo a 
persone diverse dal destinatario è severamente proibito, ed è pregato di 
rinviarlo immediatamente al mittente distruggendone l'originale.


Da: Kevin Falcone <mailto:falc...@bestpractical.com>
Inviato: Tue Oct 15 2013 19:24:15 GMT+0200 (CEST)
A: rt-users@lists.bestpractical.com<mailto:rt-users@lists.bestpractical.com>
Oggetto: Re: [rt-users] Error in article history

On Tue, Oct 15, 2013 at 10:56:11AM +, Guadagnino Cristiano wrote:


we've been using RT 4.0.17 since a couple months without problems.
However, I realized just today that asking for an article's history
generates an error page.

The log reports:

[Tue Oct 15 10:50:40 2013] [error]: Can't locate object method "new" via
package "RT::FM::Article" (perhaps you forgot to load
"RT::FM::Article"?) at /opt/rt4/sbin/../lib/RT/ObjectCustomFieldValue.pm
line 306.


When you upgraded from 3.8 to 4.0, did you run the various upgrading
steps for the RT::FM => Articles conversion.

You likely still have a Transaction record or ObjectCustomFieldValue
record with the wrong ObjectType that those scripts should have fixed
for you.

-kevin


--
<><><>

Re: [rt-users] Error in article history

2013-10-15 Thread Kevin Falcone
On Tue, Oct 15, 2013 at 10:56:11AM +, Guadagnino Cristiano wrote:
> we've been using RT 4.0.17 since a couple months without problems.
> However, I realized just today that asking for an article's history
> generates an error page.
> 
> The log reports:
> 
> [Tue Oct 15 10:50:40 2013] [error]: Can't locate object method "new" via
> package "RT::FM::Article" (perhaps you forgot to load
> "RT::FM::Article"?) at /opt/rt4/sbin/../lib/RT/ObjectCustomFieldValue.pm
> line 306.

When you upgraded from 3.8 to 4.0, did you run the various upgrading
steps for the RT::FM => Articles conversion.

You likely still have a Transaction record or ObjectCustomFieldValue
record with the wrong ObjectType that those scripts should have fixed
for you.

-kevin


pgpOJqHwyL0OM.pgp
Description: PGP signature


[rt-users] Error in article history

2013-10-15 Thread Guadagnino Cristiano
Hi all,
we've been using RT 4.0.17 since a couple months without problems.
However, I realized just today that asking for an article's history
generates an error page.

The log reports:

[Tue Oct 15 10:50:40 2013] [error]: Can't locate object method "new" via
package "RT::FM::Article" (perhaps you forgot to load
"RT::FM::Article"?) at /opt/rt4/sbin/../lib/RT/ObjectCustomFieldValue.pm
line 306.

Stack:
   [/opt/rt4/sbin/../lib/RT/ObjectCustomFieldValue.pm:306]
   [/opt/rt4/sbin/../lib/RT/ObjectCustomFieldValue.pm:235]
   [/opt/rt4/sbin/../lib/RT/ObjectCustomFieldValue.pm:254]
   [/opt/rt4/sbin/../lib/RT/Transaction.pm:1186]
   [/opt/rt4/sbin/../lib/RT/Transaction.pm:794]
   [/opt/rt4/sbin/../lib/RT/Transaction.pm:748]
   [/opt/rt4/sbin/../lib/RT/Transaction.pm:671]
   [/opt/rt4/share/html/Articles/Article/Elements/ShowHistory:54]
   [/opt/rt4/share/html/Articles/Article/History.html:50]
   [/opt/rt4/sbin/../lib/RT/Interface/Web.pm:635]
   [/opt/rt4/sbin/../lib/RT/Interface/Web.pm:335]
   [/opt/rt4/share/html/autohandler:53]
(/opt/rt4/sbin/../lib/RT/Interface/Web/Handler.pm:208)

I am at a loss... can anybody shed some light on this error?

If it can be of any interest, I have an experimental installation of RT
4.2, where I restored a copy of our production db and ran it through the
update routine. It shows this same behaviour.

Bye
Cris

--

Cristiano Guadagnino

Servizio Data Administration
___
Bankadati Servizi Informatici Soc.Cons.P.A.
Gruppo bancario Credito Valtellinese
Via Trento, 22 - 23100 SONDRIO
tel +39 0342522172  - fax +39 0342522992
guadagnino.cristi...@creval.it
www.creval.it


Il presente messaggio non è di natura personale ma inviato per esigenze 
lavorative; l’eventuale messaggio di risposta potrà essere conosciuto anche da 
altri soggetti diversi dall’originatore di questo messaggio per dette esigenze 
o per controllo aziendale. Questo messaggio, corredato dei relativi allegati, 
contiene informazioni da considerarsi strettamente riservate, ed è destinato 
esclusivamente al destinatario sopra indicato, il quale è l'unico autorizzato 
ad usarlo, copiarlo e, sotto la propria responsabilità, diffonderlo. Chiunque 
ricevesse questo messaggio per errore o comunque lo leggesse senza esserne 
legittimato è avvertito che trattenerlo, copiarlo, divulgarlo, distribuirlo a 
persone diverse dal destinatario è severamente proibito, ed è pregato di 
rinviarlo immediatamente al mittente distruggendone l'originale.