cancel
Showing results for 
Search instead for 
Did you mean: 

NETBiosNameServer setup error on starting Alfresco

drbaz
Champ in-the-making
Champ in-the-making
Please can anyone help resolve the error I get when starting the Alfresco server, which is running on Linux.

09:37:43,366 ERROR [org.alfresco.smb.protocol.netbios] NetBIOSNameServer setup error:
java.net.BindException: Permission denied
   at java.net.PlainDatagramSocketImpl.bind0(Native Method)
   at java.net.PlainDatagramSocketImpl.bind(PlainDatagramSocketImpl.java:82)
   at java.net.DatagramSocket.bind(DatagramSocket.java:368)
   at java.net.DatagramSocket.<init>(DatagramSocket.java:210)
   at java.net.DatagramSocket.<init>(DatagramSocket.java:261)
   at java.net.DatagramSocket.<init>(DatagramSocket.java:234)
   at org.alfresco.filesys.netbios.server.NetBIOSNameServer.openSocket(NetBIOSNameServer.java:1080)
   at org.alfresco.filesys.netbios.server.NetBIOSNameServer.run(NetBIOSNameServer.java:1489)
   at java.lang.Thread.run(Thread.java:595)
09:37:43,402 ERROR [org.alfresco.smb.protocol] [SMB] 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:249)
   at org.alfresco.filesys.smb.server.NetBIOSSessionSocketHandler.createSessionHandlers(NetBIOSSessionSocketHandler.java:157)
   at org.alfresco.filesys.smb.server.SMBServer.run(SMBServer.java:522)
   at java.lang.Thread.run(Thread.java:595)
09:37:43,440 ERROR [org.alfresco.ftp.protocol] FTP Socket 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.ftp.FTPNetworkServer.run(FTPNetworkServer.java:377)
   at java.lang.Thread.run(Thread.java:595)
10 REPLIES 10

gary_spencer
Champ in-the-making
Champ in-the-making
Hi,

The CIFS and FTP servers use ports below 1024 so you need to run the server under a privileged account.

It's possible to change the FTP server port to use an unprivileged socket number but CIFS requires particular port numbers to work correctly.

Cheers

Gary

drbaz
Champ in-the-making
Champ in-the-making
Hi Gary … running the Alfresco server as su worked a treat. Also I stopped the samba service ….. assuming that Alfresco starts it.

Now I get this error reported in the alfresco.log file

12:55:47,795 ERROR [org.alfresco.smb.protocol.mailslot] HostAnnouncer error
java.io.IOException: Invalid argument
   at java.net.PlainDatagramSocketImpl.send(Native Method)
   at java.net.DatagramSocket.send(DatagramSocket.java:612)
   at org.alfresco.filesys.netbios.NetBIOSDatagramSocket.sendBroadcastDatagram(NetBIOSDatagramSocket.java:170)
   at org.alfresco.filesys.netbios.NetBIOSDatagram.SendDatagram(NetBIOSDatagram.java:430)
   at org.alfresco.filesys.smb.mailslot.TcpipNetBIOSHostAnnouncer.sendAnnouncement(TcpipNetBIOSHostAnnouncer.java:204)
   at org.alfresco.filesys.smb.mailslot.HostAnnouncer.run(HostAnnouncer.java:288)

gary_spencer
Champ in-the-making
Champ in-the-making
Hi,

Try changing the <broadcast> setting in the file-servers.xml to match your network settings, the default settings use the 255.255.255.255 broadcast address which doesn't work on some networks.

Cheers

Gary

simon
Champ in-the-making
Champ in-the-making
Try changing the <broadcast> setting in the file-servers.xml to match your network settings, the default settings use the 255.255.255.255 broadcast address which doesn't work on some networks.

Why is that? Alfresco doesn't run when we change the broadcast mask from 255.255.255.255 to the broadcast mask of the compmany. It works with the deault (and for our company worng) settings. Any idea?

Update: I think we fixed it, probably some wrong broadcast address, sorry to bother you guys.

gary_spencer
Champ in-the-making
Champ in-the-making
Hi Simon,

Could you email me the output from an ipconfig command on Windows, or ifconfig on linux and also send me the file-servers.xml you're using (with the updated broadcast mask).

Thanks

Gary

fthamura
Champ in-the-making
Champ in-the-making
Guys,

so, what should i do to make the alfresco netbios server run well here.

is that mean must run in root mode?

Frans

gary_spencer
Champ in-the-making
Champ in-the-making
Hi,

You'll need to run Tomcat/JBoss from a privileged account under linux/Mac OSX/Solaris as the CIFS server uses privileged ports (137/138/139/445).

You can either use root or setup a less privileged account with the required privileges only.

Cheers

Gary

fthamura
Champ in-the-making
Champ in-the-making
Still cannot get it, right now I just run it on Centos Linux, and as root, work well, but i dont like this privilage, root .

i want under frans, but still new in CIFS world.

do you know how to setup the less priviage in linux?

and how can i know that the CIFS server run well?

i use the server on the net you can see at http://www.blueoxygen.org:8080/alfresco

i use the jboss bundle, and run on root.


Frans

gary_spencer
Champ in-the-making
Champ in-the-making
Hi,

After some investigation it looks like you may have to run as root if you want the CIFS server enabled under linux.

To check if the CIFS server is running first check the alfresco.log log file, there should be some entries for [alfresco.smb.protocol]. Then try and connect to the CIFS server from a Windows PC using Start->Run and enter \\<servername>. The Alfresco CIFS server name defaults to the name of the system it is running on with _A appended to the name, so if the server name is CENTOS the Alfresco CIFS server is CENTOS_A.

Cheers

Gary