"Can't locate [xxx] in @INC" after system upgrade

Hello,

After upgrading my version of Debian to 13 (with perl v5.40), I am getting errors in RT, of this style:

Can't locate Module/Runtime.pm in @INC (you may need to install the Module::Runtime module) (@INC entries checked: /opt/rt6/sbin/../local/lib /opt/rt6/sbin/../lib /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.40.1 /usr/local/share/perl/5.40.1 /usr/lib/x86_64-linux-gnu/perl5/5.40 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl-base /usr/lib/x86_64-linux-gnu/perl/5.40 /usr/share/perl/5.40 /usr/local/lib/site_perl) at /opt/rt6/sbin/../lib/RT/StaticUtil.pm line 56.
BEGIN failed--compilation aborted at /opt/rt6/sbin/../lib/RT/StaticUtil.pm line 56.
Compilation failed in require at /opt/rt6/sbin/../lib/RT.pm line 60.
BEGIN failed--compilation aborted at /opt/rt6/sbin/../lib/RT.pm line 60.
Compilation failed in require at /opt/rt6/sbin/rt-server.fcgi line 86.
[Tue Apr 21 12:33:43.400909 2026] [fcgid:info] [pid 1050:tid 1050] mod_fcgid: process /opt/rt6/sbin/rt-server.fcgi(24963) exit(communication error), terminated by calling exit(), return code: 2

I can install the module manually but then it just gets to another module, on and on. I have a feeling that the @INC variable has been overwritten during my upgrade and does not contain the directories that RT needs. Here is what it contains now:

@INC:
    /etc/perl
    /usr/local/lib/x86_64-linux-gnu/perl/5.40.1
    /usr/local/share/perl/5.40.1
    /usr/lib/x86_64-linux-gnu/perl5/5.40
    /usr/share/perl5
    /usr/lib/x86_64-linux-gnu/perl-base
    /usr/lib/x86_64-linux-gnu/perl/5.40
    /usr/share/perl/5.40
    /usr/local/lib/site_perl

Is there a way to fix that ? I feel that re-running the installation should work but I don’t want my installation to be overwritten

Thank you.

If you’ve built RT from source (rather than using a Debian package) you can do make testdeps and then make fixdeps to find module dependencies that are missing and install them from CPAN.

Yes I have tried that but it doesn’t say anything about perl (I have some missing user/group but I’m not sure that’s related)

fixdeps tells me the same thing

Looks like RT is expecting some users/groups that aren’t there so it is error’ing out early before testing your Perl deps.

Which version of Linux?

I have just upgraded to Debian 13

Ok it’s repaired. I had to run ./configure, which reinstalled a whole lot of dependencies that had been lost somehow. Following this, I still had an issue with the DBD::Pg module, which couldn’t be installed because I was lacking libpq-dev. After installing libpq-dev with apt, I installed DBD::Pg with the cpan console and it worked again.