LabelMeAnnotationTool icon indicating copy to clipboard operation
LabelMeAnnotationTool copied to clipboard

[Ubuntu 18.04] Can't locate globalvariables.pl

Open fzd9752 opened this issue 4 years ago • 4 comments

OS: Ubuntu 18.04 Follow Instruction: UBUNTU_16_04

I tried solution from https://github.com/CSAILVision/LabelMeAnnotationTool/issues/69 and https://github.com/CSAILVision/LabelMeAnnotationTool/issues/1:

Setting $LM_HOME by input in shell

export LM_HOME=/var/www/html/LabelMeAnnotationTool

But it doesn't work, the tool.html still shows "Fatal: there are problems with fetch_image.cgi" when loading.

I have tried ubuntu 16 docker and it works well in my local server. I'm not sure whether there is special configure for ubuntu 18. It will be really appreciate, if you could help me to solve this problem.


Error Log:

[Mon Oct 28 16:48:05.529643 2019] [cgi:error] [pid 6417] [client 127.0.0.1:42144] AH01215: Can't locate globalvariables.pl in @INC (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/x86_64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /var/www/html/LabelMeAnnotationTool/annotationTools/perl/write_logfile.cgi line 2.: /var/www/html/LabelMeAnnotationTool/annotationTools/perl/write_logfile.cgi, referer: http://127.0.0.1/LabelMeAnnotationTool/tool.html?collection=LabelMe&mode=i&folder=null&image=null [Mon Oct 28 16:48:05.529709 2019] [cgi:error] [pid 6417] [client 127.0.0.1:42144] End of script output before headers: write_logfile.cgi, referer: http://127.0.0.1/LabelMeAnnotationTool/tool.html?collection=LabelMe&mode=i&folder=null&image=null [Mon Oct 28 16:48:05.529900 2019] [cgi:error] [pid 6386] [client 127.0.0.1:42146] AH01215: Can't locate globalvariables.pl in @INC (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/x86_64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /var/www/html/LabelMeAnnotationTool/annotationTools/perl/write_logfile.cgi line 2.: /var/www/html/LabelMeAnnotationTool/annotationTools/perl/write_logfile.cgi, referer: http://127.0.0.1/LabelMeAnnotationTool/tool.html?collection=LabelMe&mode=i&folder=null&image=null [Mon Oct 28 16:48:05.529952 2019] [cgi:error] [pid 6386] [client 127.0.0.1:42146] End of script output before headers: write_logfile.cgi, referer: http://127.0.0.1/LabelMeAnnotationTool/tool.html?collection=LabelMe&mode=i&folder=null&image=null

fzd9752 avatar Oct 28 '19 08:10 fzd9752

I don't know anything about perl or apache…… Since it can't locate globalvariables.pl in @inc, I copied that to /etc/perl and it works……

Lafite-Yu avatar Apr 09 '20 14:04 Lafite-Yu

I don't know anything about perl or apache…… Since it can't locate globalvariables.pl in @inc, I copied that to /etc/perl and it works……

You are right!Thanks!

znstj avatar Jun 10 '21 05:06 znstj

Being on ubuntu 18.04 that runs apache 2.4 and perl v5.26.1 and having followed the insufficient instructions in aforementioned UBUNTU.md, I hit the same issue as well.

The solution was to add to apache configuration (sites-available/default.conf) the following line:

SetEnv PERL5LIB /var/www/html/LabelMeAnnotationTool/annotationTools/perl

# and this one did not work
#PerlSwitches -I/var/www/html/LabelMeAnnotationTool/annotationTools/perl

This directive needs to be placed outside of <Directory/> block.

nkrot avatar Jul 14 '21 10:07 nkrot

Being on ubuntu 18.04 that runs apache 2.4 and perl v5.26.1 and having followed the insufficient instructions in aforementioned UBUNTU.md, I hit the same issue as well.

The solution was to add to apache configuration (sites-available/default.conf) the following line:

SetEnv PERL5LIB /var/www/html/LabelMeAnnotationTool/annotationTools/perl

# and this one did not work
#PerlSwitches -I/var/www/html/LabelMeAnnotationTool/annotationTools/perl

This directive needs to be placed outside of <Directory/> block.

This works for me! Many thanks

huynhbaobk avatar Jul 31 '21 05:07 huynhbaobk