deploy error

127 views
Skip to first unread message

Mihalis

unread,
Jan 26, 2011, 3:40:39 AM1/26/11
to calipso-users
When tomcat is started I get the following error:

2011-01-26 08:01:26,657 [main] ERROR
[gr.abiss.calipso.wicket.CalipsoApplication] - Failed to initialize
velocity engine
java.lang.Exception: Unable to configure AvalonLogSystem :
java.io.FileNotFoundException: /var/lib/tomcat6/velocity.log
(Permission denied)

However the application seems to work fine...

Ervis Zikas

unread,
Jan 26, 2011, 3:48:11 AM1/26/11
to calips...@googlegroups.com
It seems that you don't have permission to write to /var/lib/tomcat/
directory. Either change the permissions to the directory using chmod -R
a+w /var/lib/tomcat/ as root or just download the tomcat from apache
website and extract it somewhere in your home directory and use that.

Mihalis

unread,
Jan 26, 2011, 4:04:41 AM1/26/11
to calipso-users
What I did is:
chown tomcat6 /var/lib/tomcat6 and it is ok now...
So the velocity log goes by default in tomcat home?
Another problem when first deployed was the following:

2011-01-26 08:59:04,420 [main] INFO
[gr.abiss.calipso.config.CalipsoConfigurer] - directory already
exists: '/home/calypso/calypso'
2011-01-26 08:59:04,420 [main] INFO
[gr.abiss.calipso.config.CalipsoConfigurer] - directory does not
exist, created '/home/calypso/calypso/attachments'
2011-01-26 08:59:04,420 [main] INFO
[gr.abiss.calipso.config.CalipsoConfigurer] - directory does not
exist, created '/home/calypso/calypso/indexes'

It said "created", however the dir was NOT created and I got the
following message:
2011-01-26 08:59:07,527 [main] ERROR
[org.springframework.web.context.ContextLoader] - Context
initialization failed
org.springframework.beans.factory.BeanCreationException: Error
creating bean with name 'calipsoService' defined in ServletContext
resource [/WEB-INF/applicationContext.xml]: Cannot create inner bean
'gr.abiss.calipso.CalipsoServiceImpl#2a63b2e6' of type
[gr.abiss.calipso.CalipsoServiceImpl] while setting bean property
'target'; nested exception is
org.springframework.beans.factory.BeanCreationException: Error
creating bean with name 'gr.abiss.calipso.CalipsoServiceImpl#2a63b2e6'
defined in ServletContext resource [/WEB-INF/applicationContext.xml]:
Cannot resolve reference to bean 'indexer' while setting bean property
'indexer'; nested exception is
org.springframework.beans.factory.BeanCreationException: Error
creating bean with name 'indexer' defined in ServletContext resource [/
WEB-INF/applicationContext-lucene.xml]: Cannot resolve reference to
bean 'indexFactory' while setting bean property 'indexFactory'; nested
exception is org.springframework.beans.factory.BeanCreationException:
Error creating bean with name 'indexFactory'defined in ServletContext
resource [/WEB-INF/applicationContext-lucene.xml]: Cannot resolve
reference to bean 'indexDirectory' while setting bean property
'directory'; nested
exception is org.springframework.beans.factory.BeanCreationException:
Error creating bean with name 'indexDirectory' defined in
ServletContext resource [/WEB-INF/applicationContext-lucene.xml]:
Invocation of init method failed; nested exception is
org.springframework.beans.factory.BeanInitializationException:
location does not exist

I guess this again is another permissions problem, probably the tomcat
user does not have permission to create those dirs...
I think that the install manual should be more clear about users,
permissions, etc...in order to have a more trouble-free installation.
since many calypso users/admins are not java/tomcat experts.

Ervis Zikas

unread,
Jan 26, 2011, 4:37:34 AM1/26/11
to calips...@googlegroups.com
It seems again that it's a Linux permission problem when you deploy
calipso. I think the problem is in your configuration
file(build.properties) Can you please post your build.properties file
contexts?
Try to delete and re-deploy calipso using "ant clean tomcat-clean
tomcat-reload" and check if the problem still exists.

I'll show you an example of proper configuration.

mvn.executable=mvn
tomcat.home=/home/ervis/devprojects/servers/apache-tomcat-7.0.0
calipso.version=2.1.2
calipso.home=/home/ervis/calipso
calipso.deploy.mode=DEPLOYMENT
war.name=calipso

I hope it will help you and i'm sure that the calipso dev team will add
more informations about calipso configuration.

Mihalis

unread,
Jan 26, 2011, 4:47:16 AM1/26/11
to calips...@googlegroups.com
When I create the dirs the app is deployed fine...

mvn.executable=mvn
tomcat.home=/var/lib/tomcat6
calipso.version=2.1.2
calipso.home=/home/calypso/calypso
calipso.deploy.mode=DEPLOYMENT
war.name=calipso

Tomcat version is 6 and it is installed using the standard debian package management. which creates a "tomcat6" user, etc...

Ervis Zikas

unread,
Jan 26, 2011, 5:13:00 AM1/26/11
to calips...@googlegroups.com
your configuration it's ok and i think the problem now is in your dependencies. Maybe a corrupted jar file when maven tried to download the dependencies from the web is causing this problem. Try to re-download the dependencies
using maven (just delete the jars inside in /home/$username/.m2/repository directory and then inside calipso:

ant mvn-add-jars
mvn antprops:generate
mvn org.apache.maven.plugins:maven-eclipse-plugin:2.6:clean org.apache.maven.plugins:maven-eclipse-plugin:2.6:eclipse -DdownloadSources=true -DdownloadJavadocs=true
Build the project:
ant clean tomcat-clean tomcat-reload

assuming of course that you did not made any changes in calipso source code.

manos

unread,
Jan 26, 2011, 7:31:47 AM1/26/11
to calipso-users


On 26 Ιαν, 11:04, Mihalis <miliara...@gmail.com> wrote:
> I guess this again is another permissions problem, probably the tomcat
> user does not have permission to create those dirs...
> I think that the install manual should be more clear about users,
> permissions, etc...in order to have a more trouble-free installation.
> since many calypso users/admins are not java/tomcat experts.

True, although covering even the most popular combinations of
platforms, components and other deployment factors is not as simple
without help from the community ;-)

Regarding your logging error: It is possible that your linux(?)
distro's tomcat folder layout is supposed to work via sudo.

Also, even with the directories created manually, Calipso may not be
able to create/update files within them. You probably want to

chmod -R a+w /home/calypso/calypso

The above assumes a dev/test environment. For production deployments,
rights should be to the appserver user/group. If you still have
troubles, please post your config file and complete exception.

hth,

Manos
Reply all
Reply to author
Forward
0 new messages