404 error

cancel
Showing results for 
Search instead for 
Did you mean: 
DavidJM
Active Member

404 error

The ongoing saga of me getting Alfresco installed! First i tried docker, couldnt find out how to fix the users not being shown error. So moved to the Loftux install and got 404 errors after a restart, so tried Loftux on a vanilla 16.04, same problem. Undaunted i tried Abhinav Kumar Mishra coprehensive instructions on Centos and ran into a Pgadmin install problem, So i swapped to Win10 and again i get a 404 error.

This really cannot (shouldnt) be this difficult. I dont understand, i am a pretty good small company sys admin, but alfresco appears to resist being installed at all costs!!

Any ideas why i am getting licence errors?

9 Replies
DavidJM
Active Member

Re: 404 error

NOTE: Picked up JDK_JAVA_OPTIONS: --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED
01-May-2021 15:34:55.825 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Server version: Apache Tomcat/8.5.43
01-May-2021 15:34:55.832 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Server built: Jul 4 2019 20:53:15 UTC
01-May-2021 15:34:55.832 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Server number: 8.5.43.0
01-May-2021 15:34:55.833 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log OS Name: Windows 10
01-May-2021 15:34:55.834 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log OS Version: 10.0
01-May-2021 15:34:55.836 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Architecture: amd64
01-May-2021 15:34:55.837 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Java Home: C:\Program Files\Java\jdk-11.0.11
01-May-2021 15:34:55.838 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Version: 11.0.11+9-LTS-194
01-May-2021 15:34:55.838 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log JVM Vendor: Oracle Corporation
01-May-2021 15:34:55.840 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_BASE: C:\alfresco-community62ga\tomcat
01-May-2021 15:34:55.841 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log CATALINA_HOME: C:\alfresco-community62ga\tomcat
01-May-2021 15:34:55.842 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: --add-opens=java.base/java.lang=ALL-UNNAMED
01-May-2021 15:34:55.842 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: --add-opens=java.base/java.io=ALL-UNNAMED
01-May-2021 15:34:55.843 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED
01-May-2021 15:34:55.843 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.config.file=C:\alfresco-community62ga\tomcat\conf\logging.properties
01-May-2021 15:34:55.844 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
01-May-2021 15:34:55.844 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djdk.tls.ephemeralDHKeySize=2048
01-May-2021 15:34:55.845 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.protocol.handler.pkgs=org.apache.catalina.webresources
01-May-2021 15:34:55.847 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dignore.endorsed.dirs=
01-May-2021 15:34:55.847 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.base=C:\alfresco-community62ga\tomcat
01-May-2021 15:34:55.848 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Dcatalina.home=C:\alfresco-community62ga\tomcat
01-May-2021 15:34:55.848 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Command line argument: -Djava.io.tmpdir=C:\alfresco-community62ga\tomcat\temp
01-May-2021 15:34:55.849 INFO [main] org.apache.catalina.core.AprLifecycleListener.lifecycleEvent The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: [C:\Program Files\Java\jdk-11.0.11\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:\alfresco-community62ga\imagemagick;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows\System32\OpenSSH\;C:\Users\david\AppData\Local\Microsoft\WindowsApps;;.]
01-May-2021 15:34:55.962 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-8080"]
01-May-2021 15:34:56.085 INFO [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
01-May-2021 15:34:56.115 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["ajp-nio-8009"]
01-May-2021 15:34:56.120 INFO [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
01-May-2021 15:34:56.122 INFO [main] org.apache.catalina.startup.Catalina.load Initialization processed in 1363 ms
01-May-2021 15:34:56.300 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Catalina]
01-May-2021 15:34:56.303 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet Engine: Apache Tomcat/8.5.43
01-May-2021 15:34:56.424 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployWAR Deploying web application archive [C:\alfresco-community62ga\tomcat\webapps\alfresco.war]
May 01, 2021 3:35:30 PM org.apache.catalina.core.ApplicationContext log
(FATAL: role "alfresco" is not permitted to log in)

SEVERE: Exception sending context initialized event to listener instance of class [org.alfresco.web.app.ContextLoaderListener]
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.beans.factory.config.CustomEditorConfigurer#0' defined in class path resource [alfresco/core-services-context.xml]: Cannot resolve reference to bean 'customPropertyEditorRegistrar' while setting bean property 'propertyEditorRegistrars' with key [0]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'customPropertyEditorRegistrar' defined in class path resource [alfresco/core-services-context.xml]: Cannot resolve reference to bean 'NamespaceService' while setting bean property 'namespaceService'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dictionaryDAO' defined in class path resource [alfresco/core-services-context.xml]: Cannot resolve reference to bean 'tenantService' while setting bean property 'tenantService'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'tenantService' defined in URL [jar:file:/C:/alfresco-community62ga/tomcat/webapps/alfresco/WEB-INF/lib/alfresco-repository-7.134.1.jar!/alfresco/mt/mt-context.xml]: Cannot resolve reference to bean 'tenantAdminDAO' while setting bean property 'tenantAdminDAO'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'tenantAdminDAO' defined in class path resource [alfresco/dao/dao-context.xml]: Cannot resolve reference to bean 'repoSqlSessionTemplate' while setting bean property 'sqlSessionTemplate'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'repoSqlSessionTemplate' defined in class path resource [alfresco/ibatis/ibatis-context.xml]: Cannot resolve reference to bean 'repoSqlSessionFactory' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'repoSqlSessionFactory' defined in class path resource [alfresco/ibatis/ibatis-context.xml]: Cannot resolve reference to bean 'dialectResourceLoader' while setting bean property 'resourceLoader'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dialectResourceLoader' defined in class path resource [alfresco/ibatis/ibatis-context.xml]: Cannot create inner bean 'org.springframework.beans.factory.config.PropertyPathFactoryBean#336e2ea5' of type [org.springframework.beans.factory.config.PropertyPathFactoryBean] while setting bean property 'dialectClass'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.beans.factory.config.PropertyPathFactoryBean#336e2ea5' defined in class path resource [alfresco/ibatis/ibatis-context.xml]: Initialization of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dialect': FactoryBean threw exception on object creation; nested exception is org.springframework.jdbc.CannotGetJdbcConnectionException: Failed to obtain JDBC Connection; nested exception is org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (FATAL: role "alfresco" is not permitted to log in)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:314)

 

May 01, 2021 3:35:42 PM org.apache.catalina.core.StandardContext listenerStart
SEVERE: Exception sending context initialized event to listener instance of class [org.alfresco.repo.webdav.WebDAVSessionListener]

SEVERE: Exception sending context initialized event to listener instance of class [org.alfresco.web.app.servlet.CORSContextListener]
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.beans.factory.config.CustomEditorConfigurer#0' defined in class path resource [alfresco/core-services-context.xml]: Cannot resolve reference to bean 'customPropertyEditorRegistrar' while setting bean property 'propertyEditorRegistrars' with key [0]; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'customPropertyEditorRegistrar' defined in class path resource [alfresco/core-services-context.xml]: Cannot resolve reference to bean 'NamespaceService' while setting bean property 'namespaceService'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dictionaryDAO' defined in class path resource [alfresco/core-services-context.xml]: Cannot resolve reference to bean 'tenantService' while setting bean property 'tenantService'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'tenantService' defined in URL [jar:file:/C:/alfresco-community62ga/tomcat/webapps/alfresco/WEB-INF/lib/alfresco-repository-7.134.1.jar!/alfresco/mt/mt-context.xml]: Cannot resolve reference to bean 'tenantAdminDAO' while setting bean property 'tenantAdminDAO'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'tenantAdminDAO' defined in class path resource [alfresco/dao/dao-context.xml]: Cannot resolve reference to bean 'repoSqlSessionTemplate' while setting bean property 'sqlSessionTemplate'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'repoSqlSessionTemplate' defined in class path resource [alfresco/ibatis/ibatis-context.xml]: Cannot resolve reference to bean 'repoSqlSessionFactory' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'repoSqlSessionFactory' defined in class path resource [alfresco/ibatis/ibatis-context.xml]: Cannot resolve reference to bean 'dialectResourceLoader' while setting bean property 'resourceLoader'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dialectResourceLoader' defined in class path resource [alfresco/ibatis/ibatis-context.xml]: Cannot create inner bean 'org.springframework.beans.factory.config.PropertyPathFactoryBean#336e2ea5' of type [org.springframework.beans.factory.config.PropertyPathFactoryBean] while setting bean property 'dialectClass'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.beans.factory.config.PropertyPathFactoryBean#336e2ea5' defined in class path resource [alfresco/ibatis/ibatis-context.xml]: Initialization of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dialect': FactoryBean threw exception on object creation; nested exception is org.springframework.jdbc.CannotGetJdbcConnectionException: Failed to obtain JDBC Connection; nested exception is org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (FATAL: role "alfresco" is not permitted to log in)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:314)

01-May-2021 15:35:42.711 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.startInternal One or more listeners failed to start. Full details will be found in the appropriate container log file
01-May-2021 15:35:42.752 SEVERE [localhost-startStop-1] org.apache.catalina.core.StandardContext.startInternal Context [/alfresco] startup failed due to previous errors
May 01, 2021 3:35:42 PM org.apache.catalina.core.ApplicationContext log

01-May-2021 15:35:42.996 WARNING [localhost-startStop-1] org.apache.catalina.startup.SetContextPropertiesRule.begin [SetContextPropertiesRule]{Context} Setting property 'debug' to '100' did not find a matching property.

2021-05-01 15:36:35,462 INFO [web.site.EditionInterceptor] [http-nio-8080-exec-8] Unable to retrieve License information from Alfresco: 404

venur
Established Member

Re: 404 error

It seems like alfresco user and role is not setup correctly. This error indicates the same: Cannot create PoolableConnectionFactory (FATAL: role "alfresco" is not permitted to log in)
at

Just checking the steps in docs and blog, this should be done to allow alfresco connect to db

  • Create a new user named “alfresco” and set a password which will be used by alfresco content service to connect to database. Here we will be using username as “alfresco” and password “alfresco”.
  • Create a new database named : “alfresco”, make sure you select default encoding which is “utf8”.
  • Grant all permissions for user “alfresco” on database “alfresco”.
  • Alternatively, you can open the query tool and execute following SQL queries:
create role alfresco LOGIN password 'alfresco';

create database alfresco encoding 'utf8';

grant all on database alfresco to alfresco;

 

 

DavidJM
Active Member

Re: 404 error

Its been an interesting day, thanks for the assistance venur, you were correct, i simply couldnt see the wood for the trees after lots of playing. I dropped the DB and user, recreated both and reset permissions. I then found that i had made some errors in the scripts, double checked all and eventually it started OK.

I then noticed that i didnt have shared services, did some googling and found this ran applie_amps and it broke alfresco with another 404 error. After i recovered my PC from the window i'd thrown it out of i restarted and tried again. This time it all worked.

My only issues now are performance tuning, i am running on a W10 machine in a VM with 32GB RAM. Does anyone have any Java mem recomendations?

I have some startup problems, i am using this batch file and i get this once or twice untill it eventually works;

C:\alfresco-community62ga>start.bat
################ Starting ACS, DB and Solr Services ##############

Starting DB...
pg_ctl: old server process (PID: 3272) seems to be gone
starting server anyway
waiting for server to start....2021-05-02 16:02:52.062 BST [8932] LOG: could not bind IPv6 address "::": Only one usage of each socket address (protocol/network address/port) is normally permitted.

2021-05-02 16:02:52.062 BST [8932] HINT: Is another postmaster already running on port 5432? If not, wait a few seconds and retry.
2021-05-02 16:02:52.063 BST [8932] LOG: could not bind IPv4 address "0.0.0.0": Only one usage of each socket address (protocol/network address/port) is normally permitted.

2021-05-02 16:02:52.063 BST [8932] HINT: Is another postmaster already running on port 5432? If not, wait a few seconds and retry.
2021-05-02 16:02:52.066 BST [8932] WARNING: could not create listen socket for "*"
2021-05-02 16:02:52.067 BST [8932] FATAL: could not create any TCP/IP sockets
2021-05-02 16:02:52.068 BST [8932] LOG: database system is shut down
stopped waiting
pg_ctl: could not start server
Examine the log output.

And finally i get a few errors in the logs;

WARNING: office process died with exit code 81; restarting it

WARN [heartbeat.datasender.HBDataSenderServiceBuilder] [localhost-startStop-1] Setting the Heartbeat sender cron with property 'heartbeat.sender.cronExpression' is no longer supported.

ERROR [transform.magick.AbstractImageMagickContentTransformerWorker] [localhost-startStop-1] ImageMagickContentTransformerWorker not available: 04020018 Failed to perform ImageMagick transformation: Execution result: os: Windows 10 command: C:/alfresco-community62ga/imagemagick/convert.exe C:\alfresco-community62ga\tomcat\temp\Alfresco\ImageMagickContentTransformerWorker_init_source_4794826070520575262.gif -strip -quiet C:\alfresco-community62ga\tomcat\temp\Alfresco\ImageMagickContentTransformerWorker_init_target_13212482397439134095.png succeeded: false exit code: 1 out: err: Cannot run program "C:/alfresco-community62ga/imagemagick/convert.exe": CreateProcess error=2, The system cannot find the file specified

WARN [scripts.servlet.X509ServletFilterBase] [localhost-startStop-1] clientAuth does not appear to be set for Tomcat. clientAuth must be set to 'want' for X509 Authentication

WARN [scripts.servlet.X509ServletFilterBase] [localhost-startStop-1] Attempting to set clientAuth=want through JMX...

WARN [scripts.servlet.X509ServletFilterBase] [localhost-startStop-1] Unable to set clientAuth=want through JMX.

WARNING [localhost-startStop-1] org.apache.catalina.startup.SetContextPropertiesRule.begin [SetContextPropertiesRule]{Context} Setting property 'debug' to '100' did not find a matching property.

DavidJM
Active Member

Re: 404 error

I think i've fixed the imageconvertor problem, it would appear Imagemagick has renamed convert.exe to magick.exe and the dynamic version doesnt work in Win10. So i simply downloaded the static version, installed it on another PC, copied magick.exe out, renamed to convert.exe and dropped it into C:/alfresco-community62ga/imagemagick/

EddieMay
Alfresco Employee

Re: 404 error

Hi @DavidJM 

Wow! Well done for perseverance! Hopefully all is up and running correctly now?

Digital Community Manager, Alfresco Software.
Problem solved? Click Accept as Solution!
DavidJM
Active Member

Re: 404 error

Yes thanks Eddie, all up and running. The moral of the story being RTFM.

Still got the tuning quesiton to answer, i.e. what are best settings for 32G RAM and cannot connect to our SMTP using self cert. Have pretty much gone through every Javamail option, have installed the cert in Java, still complaining.

Regards, David

afaust
Master

Re: 404 error

The question is not necessarily "What are best settings for 32G RAM" but "What are best settings for the dimension of Alfresco system you are planning to run", e.g. how many concurrent users, number of nodes (content / folders) are expected, complexity of metadata model etc. In general, the default configuration of Alfresco would not even be able to really use 32G if you gave the process that much.

In general, I would say running the Repository Java process with

-XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:+UseStringDeduplication -Xmx4G -Xms4G

should be more than sufficient for most "standard" (unaltered Alfresco) use cases with a few hundreds of thousands of nodes, externalised transformations etc. (as expected for a 6.2 install). The Share process can be run with only 512M of RAM, while the Search Services is highly dependent on the size of the index, and I typically give it at least 1G.

In addition to the Java process memory, care should be taken to give the DB access ample memory (based on the size of the tablespace) to ensure most of its common operations can be performed in memory to limit/avoid IO-induced latencies. And last but not least, having memory "remaining" on the OS is also recommended to allow for OS-level IO caching to again limit/avoid IO-induced latencies for DB / Search Service operations.

DavidJM
Active Member

Re: 404 error

Thanks Afaust, perfect. We are a small company, 10 users, 100 or so folders. So quite light.

Any thoughts on forcing Alfresco to accept our mail server's self cert?

EddieMay
Alfresco Employee

Re: 404 error

Hi @DavidJM 

You may find this blog useful. There's also this thread that might help.

HTH,

Digital Community Manager, Alfresco Software.
Problem solved? Click Accept as Solution!