AnsweredAssumed Answered

Configuration order and CIFS '11030000 NetBIOS SMB..' error

Question asked by annakan on Dec 4, 2009
Latest reply on Dec 7, 2009 by dward
Hello all.

I am trying to get Alfresco running in a FreeBSD jail with linux compat.
I say that for reference but my question is much more general  with a precise implication.

I have everything working fine, except I had to use the "text installer" and do the @@—@@ replace by myself. I was never able to figure out what requirement the installer has for starting graphically, It never did under the few X11 client I started, even under KDE, always defaulting to the console one.

Now the last thing I need to get working is CIFS.

Problem description

Each time I lauch Alfresco the log report this (both in alfresco.log and catalina.out):
tomcat/logs/catalina.out-39-org.alfresco.error.AlfrescoRuntimeException: 11030000 NetBIOS SMB, TCP/IP SMB or Win32 NetBIOS must be enabled
16:59:29,845 ERROR [org.alfresco.fileserver] CIFS server configuration error, 11030000 NetBIOS SMB, TCP/IP SMB or Win32 NetBIOS must be enabled
org.alfresco.error.AlfrescoRuntimeException: 11030000 NetBIOS SMB, TCP/IP SMB or Win32 NetBIOS must be enabled
        at org.alfresco.filesys.config.ServerConfigurationBean.processCIFSServerConfig(ServerConfigurationBean.java:906)
        at org.alfresco.filesys.AbstractServerConfigurationBean.init(AbstractServerConfigurationBean.java:475)
        at org.alfresco.filesys.AbstractServerConfigurationBean.onApplicationEvent(AbstractServerConfigurationBean.java:824)
        at org.springframework.context.event.SimpleApplicationEventMulticaster$1.run(SimpleApplicationEventMulticaster.java:77)
        at org.springframework.core.task.SyncTaskExecutor.execute(SyncTaskExecutor.java:49)
        at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:75)
        at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:246)
        at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:617)
        at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:355)
        at org.alfresco.repo.management.subsystems.ChildApplicationContextFactory$ApplicationContextState.start(ChildApplicationContextFactory.java:637)
        at org.alfresco.repo.management.subsystems.AbstractPropertyBackedBean.start(AbstractPropertyBackedBean.java:454)
        at org.alfresco.repo.management.subsystems.AbstractPropertyBackedBean.onApplicationEvent(AbstractPropertyBackedBean.java:377)
        at org.springframework.context.event.SimpleApplicationEventMulticaster$1.run(SimpleApplicationEventMulticaster.java:77)
        at org.springframework.core.task.SyncTaskExecutor.execute(SyncTaskExecutor.java:49)
        at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:75)
        at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:246)
        at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:617)
        at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:355)
        at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:246)
        at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:189)
        at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:49)
        at org.alfresco.web.app.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:69)
        at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3843)
        at org.apache.catalina.core.StandardContext.start(StandardContext.java:4342)
        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791)
        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771)
        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:525)
        at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:627)
        at org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:553)
        at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:488)
        at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1149)
        at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
        at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
        at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053)
        at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
        at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
        at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
        at org.apache.catalina.core.StandardService.start(StandardService.java:516)
        at org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)

I did my homework and found this http://tech.barwick.de/java/alfresco-enabling-cifs-in-freebsd.html that explains that CIFS needs a platform information to determine if it must use the jni implementation or the pure jlan one.
The code is good enough to default to the jlan one when no platform is specified in
<tcpipSMB platforms="linux,solaris,macosx"/>
<netBIOSSMB platforms="linux,solaris,macosx"/>

in the WEB-INF/classes/alfresco/file-servers.xml file…
I checked it is still the case in the sources line 658-680 of source\java\org\alfresco\filesys\ServerConfigurationBean.java.

But removing the platforms="linux,solaris,macosx" attribute seems to do nothing.
In fact changing anything in the file WEB-INF/classes/alfresco/file-servers.xml seems to do nothing.
Even REMOVING the file WEB-INF/classes/alfresco/file-servers.configuration file from the whole Alfresco directory tree seems to change nothing either.

Questions

Where does the default configuration values come from ?

Am I right to deduce from the fact that removing the file-servers.xml is without consequence on the startup sequence (CIFS fail, FTP is enabled etc ..) means the default are coming from somewhere else (another file perhaps) ? Or are those defaults hard-coded in the java source and the same as the one in the file-servers.xml file ?

What is the configuration strategy ?
Alfresco seems to move from the multiple file everywhere configuration structure to a more centralized one in alfresco-global.properties , at least for common values. I can only applaud this since, for now, even basic configuration is daunting for newbies , and we really lack a map of the maze :).  Plus I really don't appreciate the -custom override strategy where I have to DUPLICATE a whole file to change ONE parameter.. somehow it smells wrong : duplication IS evil right ? :)
Anyhow my question is : Where can I find the valid parameters for the alfresco-global.properties file ?
Can I put in there any value from any $(xxx.yyy) (like ${cifs.broadcast}) stance I find in a .xml configuration file with xxx.yyy=value in the alfresco-global.properties file, and it will be picked up by the configuration machinery ? Or is it true only for specific values that have a "special treatment" ?
I tried to had
cifs.enabled=true
cifs.serverName=${localname}
cifs.domain="Alfresco"
cifs.hostannounce=true
cifs.broadcast=10.255.255.255
cifs.ipv6.enabled=false

cifs.tcpipSMB.port=6301
cifs.netBIOSSMB.namePort=6001
cifs.netBIOSSMB.datagramPort=6101
cifs.netBIOSSMB.sessionPort=6201
into the alfresco-global.properties file but it changed nothing.

CIFS requirement
More specifically, has anybody a pointer about the enabled / disabled cifs determination strategy that could explain why it refuses to start in my case ?
Has anyone succeeded activating it under freeBSD with the 3.2 community release ?


Thanks a lot for your time and answers.

Cheers.

Outcomes