cancel
Showing results for 
Search instead for 
Did you mean: 

CIFS troubleshooting

paulhh
Champ in-the-making
Champ in-the-making
If you cannot map a drive to the Alfresco CIFS server then it's likely a name lookup problem. Check whether you are using WINS or broadcast lookups on your LAN. If you're using broadcasts, is your network split into more than one subnet?  Did you change the broadcast mask setting in the file-servers.xml configuration file?  Do you use NetBIOS name scopes on your LAN? (nbtstat -n should show if a scope id is set).

If a PC cannot access the Alfresco CIFS server you could try adding an entry to the lmhosts file (in windows\system32\drivers\etc), there's usually a sample file in that folder, you may need to create the file. Then try and access the CIFS server using Start->Run and enter \\<Alfresco servername>.

You could also try doing some name lookups using nbtstat, again from any of the PCs that are having trouble accessing the server. If you try the following commands to see which are successful :-

  nbtstat -a <Alfresco server name>
  nbtstat -A <server ip address>
  nbtstat -a <Windows server name>
73 REPLIES 73

ccappelletti
Champ in-the-making
Champ in-the-making
Hi all,
I'm trying to make CIFS server work on Linux Ubuntu 7.1 but have some troubles.
I'm making it work on reserved ports and using iptables to open them to make it live together with SAMBA.

If I connect with smbclient locally I have what espected:
root@srv-alea:/home/ccappelletti# smbclient -U admin \\\\127.0.0.1\\alfresco admin
Domain=[SRV-ALEA_A] OS=[Java] Server=[Alfresco CIFS Server 3.5.1]
smb: \> ls
  .                                   D        0  Wed Dec 31 21:00:00 1969
  ..                                  D        0  Wed Dec 31 21:00:00 1969
  __Alfresco.url                      R      130  Wed Apr 30 10:39:18 2008
  Data Dictionary                     D        0  Mon Apr 28 12:39:08 2008
  Guest Home                          D        0  Mon Apr 28 12:39:09 2008
  User Homes                          D        0  Mon Apr 28 12:39:09 2008
  Proyectos                           D        0  Mon Apr 28 12:46:43 2008

                40000 blocks of size 2097152. 36000 blocks available
smb: \>

The strange thing here is that it is taking the Alfresco server name as a domain!

Other stange staff:

root@srv-alea:/home/ccappelletti# smbclient -L 192.0.2.64 -U admin%admin
Domain=[SCHEMA] OS=[Unix] Server=[Samba 3.0.26a]

        Sharename       Type      Comment
        ———       —-      ——-
        print$          Disk      Printer Drivers
        Public          Disk
        IPC$            IPC       IPC Service (srv-alea server (Samba, Ubuntu))
Domain=[SCHEMA] OS=[Unix] Server=[Samba 3.0.26a]

        Server               Comment
        ———            ——-
        SRV-ALEA             srv-alea server (Samba, Ubuntu)
        SRV-SCIENTIA         Servidor Linux

        Workgroup            Master
        ———            ——-
        SCHEMA               SRV-SCIENTIA
       
root@srv-alea:/home/ccappelletti# smbclient -L srv-alea -U admin%admin
Domain=[SRV-ALEA_A] OS=[Java] Server=[Alfresco CIFS Server 3.5.1]

        Sharename       Type      Comment
        ———       —-      ——-
cli_rpc_pipe_open_noauth: rpc_pipe_bind for pipe \srvsvc failed with error NT_STATUS_BUFFER_TOO_SMALL
        Alfresco        Disk
        IPC$            IPC
        AVM             Disk
Receiving SMB: Server stopped responding
session request to SRV-ALEA failed (Call returned zero bytes (EOF))
Domain=[SRV-ALEA_A] OS=[Java] Server=[Alfresco CIFS Server 3.5.1]

        Server               Comment
        ———            ——-

        Workgroup            Master
        ———            ——-

If I connect with DNS name, I see the Alfresco stuff but not my samba stuff. If I connect by IP I see the Alfresco stuff.

My Alfresco version is community 2.1.
my file-servers-custom.xml:

<alfresco-config area="file-servers">

   <!– To override the default Alfresco filesystem use replace="true", to –>
   <!– add additional filesystems remove the replace="true" attribute     –>

   <config evaluator="string-compare" condition="CIFS Server">
      <serverEnable enabled="true"/>
      <host name="${localname}_A" domain="SCHEMA"/>
      <comment>Alfresco CIFS Server</comment>
      <broadcast>192.0.2.255</broadcast>
      <tcpipSMB platforms="linux,solaris,macosx"/>
      <netBIOSSMB platforms="linux,solaris,macosx"/>
      <tcpipSMB port="1445" platforms="linux,solaris,macosx"/>
      <netBIOSSMB sessionPort="1139" namePort="1137" datagramPort="1138" platforms="linux,solaris,macosx"/>
      <hostAnnounce interval="5"/>
      <sessionDebug flags="Negotiate,Socket"/>
   </config>
  
  
   <config evaluator="string-compare" condition="Filesystems" replace="true">
      <filesystems>

         <filesystem name="Alfresco">
            <store>workspace://SpacesStore</store>
            <rootPath>/app:company_home</rootPath>

            <!– Add a URL file to each folder that links back to the web client –>
            <urlFile>
               <filename>__Alfresco.url</filename>
               <webpath>http://${localname}:8080/alfresco/</webpath>
            </urlFile>

            <!– Mark locked files as offline –>
            <offlineFiles/>

            <!– Desktop actions –>

            <desktopActions>
               <global>
                  <path>alfresco/desktop/Alfresco.exe</path>
                  <webpath>http://${localname}:8080/alfresco/</webpath>
               </global>
               <action>
                  <class>org.alfresco.filesys.smb.server.repo.desk.CheckInOutDesktopAction</class>
                  <name>CheckInOut</name>
                  <filename>__CheckInOut.exe</filename>
               </action>
               <action>
                  <class>org.alfresco.filesys.smb.server.repo.desk.JavaScriptDesktopAction</class>
                  <name>JavaScriptURL</name>
                  <filename>__ShowDetails.exe</filename>
                  <script>alfresco/desktop/showDetails.js</script>
                  <attributes>anyFiles</attributes>
                  <preprocess>copyToTarget</preprocess>
               </action>

            </desktopActions>

<!–
            <accessControl default="Write">
               <user name="admin" access="Write"/>
               <address subnet="90.1.0.0" mask="255.255.0.0" access="Write"/>
            </accessControl>
–>
         </filesystem>
       
       <!– AVM virtualization view of all stores/versions for WCM –>
         <avmfilesystem name="AVM">
            <virtualView/>
         </avmfilesystem>
       
      </filesystems>
   </config>

</alfresco-config>

I think it is a problem with Linux configuration (obviously I'm not an expert) but I can't solve this (tried during a week). The problem is the same with or without DHCP.

In the net win machines only see the name srv-alea not (srv-alea_a). And only can connect to the samba stuff (not CIFS).

Any help ideas will be welcome!

Thanyou, Carlo.

opapo
Champ in-the-making
Champ in-the-making
I couldn't connect on the Alfresco server to the CIFS server once it was installed and running.
daniel@alf2:alfresco$ smbclient -U admin \\\\alf2A\\alfresco admin
Error connecting to XXX.XXX.XXX.106 (Connection refused)
Connection to alf2A failed (Error NT_STATUS_CONNECTION_REFUSED)
alfresco.log:

–snip–

16:15:15,645 INFO  [org.alfresco.service.descriptor.DescriptorService] Alfresco started (Community Network): Current version 2.1.0 (484) schema 64 - Installed version 2.1.0 (484) schema 64
16:15:15,644 ERROR [org.alfresco.smb.protocol] Server error :
java.net.BindException: Permission denied
        at java.net.PlainSocketImpl.socketBind(Native Method)
        at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:359)
        at java.net.ServerSocket.bind(ServerSocket.java:319)
        at java.net.ServerSocket.<init>(ServerSocket.java:185)
        at java.net.ServerSocket.<init>(ServerSocket.java:141)
        at org.alfresco.filesys.smb.server.SessionSocketHandler.initialize(SessionSocketHandler.java:257)
        at org.alfresco.filesys.smb.server.NetBIOSSessionSocketHandler.createSessionHandlers(NetBIOSSessionSocketHandler.java:165)
        at org.alfresco.filesys.smb.server.SMBServer.run(SMBServer.java:495)
        at java.lang.Thread.run(Thread.java:619)
–end–

Solution:
I added export JAVA_HOME='/usr/lib/jvm/java-6-sun-1.6.06'  to /opt/alfresco/alfresco.sh and ran it.  This worked.  Maybe I missed something in the README.txt file.  Thanks for the help.

-Daniel

opapo
Champ in-the-making
Champ in-the-making
ccappelletti,

This link may help.  It discusses having samba and alfresco on the same box:
http://wiki.alfresco.com/wiki/Changing_Bind_Addresses_and_Ports_for_Samba_and_FTP

-Daniel

ccappelletti
Champ in-the-making
Champ in-the-making
Daniel,
thankyou very much, both your posts were a solution to me.

I was using the script at this http://wiki.alfresco.com/wiki/Installing_Alfresco_on_Ubuntu_7.10 (without redirecting ports because I created a new IP address to have samba and CIFS on the same box) to start alfresco.
There you can see lines like this:
sudo -H -u alfresco
starting processes as alfresco user. That is… no access to priviledges ports.
So I modified it like this:

#
# Alfresco init script for Ubuntu
# 2 nov 2007 Joost Horward
# 05 may 2008 modified by Carlo Cappelletti to run as root and get access to priviledges ports.
#

export ALFRESCO_HOME=/opt/alfresco
export CATALINA_BASE=/opt/alfresco/tomcat
export CATALINA_HOME=/opt/alfresco/tomcat
export PIDFILE=/var/run/alfresco
export LOGFILE=/var/log/alfresco/alfresco.log

# Set any default JVM values
export JAVA_OPTS='-Xms128m -Xmx512m -server -Djava.io.tmpdir=/var/lib/alfresco/tmp'


cd "$ALFRESCO_HOME"

#
# redirect FROM TO PROTOCOL
# setup port redirect using iptables
redirect() {
   echo "Redirecting port $1 to $2 ($3)"
   iptables -t nat -A OUTPUT -d localhost -p $3 –dport $1 -j REDIRECT –to-ports $2
   iptables -t nat -A PREROUTING -d $HOSTNAME -p $3 –dport $1 -j REDIRECT –to-ports $2
   iptables -t nat -A OUTPUT -d $HOSTNAME -p $3 –dport $1 -j REDIRECT –to-ports $2
}

#
# setup_iptables
# setup iptables for redirection of CIFS and FTP
setup_iptables () {
   echo "Not redirecting…"
   # echo "1" >/proc/sys/net/ipv4/ip_forward
   # Clear NATing tables
   # iptables -t nat -F
   # FTP NATing
   # redirect 21 2021 tcp

   # CIFS NATing
   # redirect 445 1445 tcp
   # redirect 139 1139 tcp
   # redirect 137 1137 udp
   # redirect 138 1138 udp
}

#
# start_openoffice
#
start_openoffice(){
   sudo -H -u alfresco xvfb-run /usr/lib/openoffice/program/soffice "-accept=socket,host=localhost,port=8100;urp;StarOffice.ServiceManager" -nologo -headless -nofirststartwizard &
}

case $1 in
start)
   if [ -f $PIDFILE ] ; then
      echo "Alfresco is already running!"
      exit 1
   fi
   touch $PIDFILE
   echo "Starting OpenOffice service …"
   start_openoffice

   echo "Setting up iptables …"
   setup_iptables   

   echo "Starting Alfresco …"
   echo  -e "\n\n\n\n\n\n\n\n\n\n`date` Starting Alfresco …" >>$LOGFILE
   sudo chown alfresco:alfresco $LOGFILE

   sh $CATALINA_HOME/bin/startup.sh
        ;;
stop) 
   sh $CATALINA_HOME/bin/shutdown.sh
   killall -w -u alfresco
        echo  -e "`date` Stopping Alfresco …" >>$LOGFILE
   rm $PIDFILE
        ;;
restart)
   rm $PIDFILE
   sh $CATALINA_HOME/bin/shutdown.sh
   killall -w -u alfresco
    echo  -e "\n\n\n\n\n\n\n\n\n`date` Restarting Alfresco …" >>$LOGFILE
   sh $CATALINA_HOME/bin/startup.sh
   touch $PIDFILE
        ;;
zap)
   echo "Zapping $PIDFILE …"
   rm $PIDFILE
   ;;
*)
   echo "Usage: alfresco [start|stop|restart|zap] [tail]"
   exit 1
   ;;

esac  

case $2 in
tail)
   tail -f $LOGFILE
   ;;
esac


exit 0




And everithing is working.

Bye

Carlo.

maggot84
Champ in-the-making
Champ in-the-making
I keep getting the same error over and over: Error accessing Win32 NetBIOS, check DLL is on the path, even though I copied the neccessary dll files on the path, 'C:\windos\system32' directory to be exact. I'm using the SVN version of Alfresco, cuz I wanted to make some slight modifications. Anybody got an idea for a solution?

skorde
Champ in-the-making
Champ in-the-making
any one pls help me,
my CIFS server is not working on LAN with win 2003 server

skorde
Champ in-the-making
Champ in-the-making
Hi
I have tried it on my environment and now CIFS work fine (some times) on windows 2003 VPN
I did DNS entry and now I am facing a problem like some time remote machine can access the CIFS server and some time not, it giving the error like "no network path found" or "permission denied"
Would you please help me to get out of this problem?

System info:
Alfresco Community 2.1/Tomcat/Oracle/Windows Server 2003

Thanks in advance,
Sudhir korde

peterh_nl
Champ in-the-making
Champ in-the-making
Addition (and possible answer) to the last posts in here: somewhere between 2.1 and 3.0.0-dev the dll's used/needed for cifs on windows machines changed.
If you download latest nightly build or download from svn you find the proper dll's in there. (in bin-dir of nightly-build and in /head/root/projects/alfresco-jlan/jni pf svn-download)

Hope this helps someone (took me quite some time to figure this out..:0)
Regards,
Peter

ptstudent
Champ in-the-making
Champ in-the-making
Hi…

I'm having a problem with mapping CIFS in Windows XP
\\servernameA\alfresco gives me network address not found
\\servernameA gives me duplicate name exists

the server(test server) is running on windows Vista, I've already ran all nbtstats from the first post, and all of them display:


       Nome               Tipo         Estado
    ———————————————
    UTILIZADOR-PC  <00>  Único       Registado
    WORKGROUP      <00>  Grupo       Registado
    WORKGROUP      <1E>  Grupo       Registado
    UTILIZADOR-PC  <20>  Único       Registado
    WORKGROUP      <1D>  Único       Registado
    ..__MSBROWSE__.<01>  Grupo       Registado
    UTILIZADOR-PCA <20>  Único       Registado
    UTILIZADOR-PCA <00>  Único       Registado


…-PCA is the alfresco server


file-servers.xml:

<alfresco-config area="file-servers">

   <config evaluator="string-compare" condition="CIFS Server">
     <serverEnable enabled="true"/>
      <host name="${localname}A" />
      <comment>Alfresco CIFS Server</comment>

      <!– Set to the broadcast mask for the subnet –>
      <broadcast>10.0.0.255</broadcast>

my network has no domain

I successfuly connected from other Vista machines…
while writing this post, i've checked that i'm still not using SP1 for Vista
didn't try lmhosts, because i that that wouldn't be a viable solution

hope any-one can help…
thanks in advance for any reply

witho
Champ on-the-rise
Champ on-the-rise
Hi,

I have the same problem. I have Alfresco installed in a Windows Server 2003 and I am able to map the Alfresco Network drive in teh server local machine, but when I try to map the network drive from a PC of the LAN I am asked to provide user /password but then I enter a valid user/password of Alfresco I get an error of "The Network path was not found".

This is my file-servers.xml


<alfresco-config area="file-servers">

   <config evaluator="string-compare" condition="CIFS Server">
     <serverEnable enabled="true"/>
      <host name="${localname}_a"/>
      <comment>Alfresco CIFS Server</comment>

      <!– Set to the broadcast mask for the subnet –>
      <broadcast>255.255.255.255</broadcast>

      <!– Use Java socket based NetBIOS over TCP/IP and native SMB on linux –>
      <tcpipSMB platforms="linux,solaris,macosx"/>
      <netBIOSSMB platforms="linux,solaris,macosx"/>

      <!– Can be mapped to non-privileged ports, then use firewall rules to forward
          requests from the standard ports –>
     <!–      
      <tcpipSMB port="1445" platforms="linux,solaris,macosx"/>
      <netBIOSSMB sessionPort="1139" namePort="1137" datagramPort="1138" platforms="linux,solaris,macosx"/>
     –>
      
      <hostAnnounce interval="5"/>

      <!– Use Win32 NetBIOS interface on Windows –>
      <Win32NetBIOS/>
      <Win32Announce interval="5"/>

<!–
      <WINS>
         <primary>1.2.3.4</primary>
         <secondary>5.6.7.8</secondary>
      </WINS>
–>
      <sessionDebug flags="Negotiate,Socket"/>
   </config>

Anyone has any solution???