<HTML>
<HEAD>
<TITLE>RISCOS Samba Server</TITLE>
</HEAD>
<BODY bgcolor=white text=black  LINK="#0000FF" VLINK="#8700BA" ALINK="#FF0000">
<H1 ALIGN=centre><IMG SRC="images/logo.jpg"> RISCOS Samba Server <IMG SRC="images/logo.jpg"></H1>
<P>
<A HREF="samba_02.htm"><IMG SRC="images/left.gif" ALIGH=LEFT BORDER=0></A> <A HREF="SAMBA.htm"><IMG SRC="images/cont.jpg" ALIGH=CENTRE BORDER=0></A> <A HREF="samba_04.htm" ALIGN=right><IMG SRC="images/right.gif"  ALIGN=RIGHT BORDER=0></A>  
<HR>

<H2><A NAME="run1">3 Running and Configuring</H2><P>
<H3><A NAME="run2">3.1 Running</H3><P>
To run !SmbServer double click on the application as normal. Only one copy can be run at once. If you  try to run more than one copy, the second copy will detect this and report an error before exiting.<P>
<P>
Samba uses well known port 139, if !SmbServer fails to bind to this port than an error box will appear telling you which port it is using instead. Whilst you will still be able to connect to !SmbServer from UNIX if this happens, you won't be able to from Windows. (I haven't figured out how you tell Windows to use a different port). In this case you'll have to reboot RISCOS I'm afraid!<P>
<P>
If Samba crashes it will close all open sockets and files before dieing. <P>
<P>
If you have machines connected to shares it is quite safe to quit and restart !smbserver if you need to, the protocols can recover from this! <P>
<P>
<H3><A NAME="conf">3.2 Configuring</H3><P>
Select "Configure..." from !smbserver's icon bar menu to show the configuration window.<P>
<IMG SRC="images/configRO4">
<P> 
Click on smbserver to show the Global Server Options window.<P>
Click on Shares to show the Shares configuration window.<P>     
The configuration is stored in !smbserver.Resources.smb/conf. This file is read when !smbserver starts up. If the configuration has changed clicking OK saves the new configuration back to !smbserver.Resources.smb/conf.<P>
<H4><A NAME="confglobals">3.2.1 Global Server Options</H4><P>
<IMG SRC="images/globals"><P>
<TABLE BORDER=2>
<tr><td VALIGN=TOP><B>Server String</B><td>This is the name of the Samba Server. It can be anything you want.
<tr><td VALIGN=TOP><B>Interfaces</B><td>Normally this will be left blank but if the RISCOS machine does not appear in the Network Neighbourhood then you might want to set it. See <A HREF="samba_13.htm#neight2">RiscOs Machine Does Not Appear in Network Neighbourhood</A><P>
This option allows you to setup multiple network interfaces, so that Samba can properly handle browsing on all interfaces. The option takes a list of ip/netmask pairs. The netmask may either be a bitmask, or a bitlength. For example, the following line:
<PRE>
192.168.2.10/24 192.168.3.10/24
</PRE>
would configure two network interfaces with IP addresses 192.168.2.10 and 192.168.3.10. The netmasks of both interfaces would be set to 255.255.255.0. You could produce an equivalent result by using:
<PRE>192.168.2.10/255.255.255.0 192.168.3.10/255.255.255.0
</PRE>
if you prefer that format.<P>
If this option is not set then Samba will attempt to find a primary interface, but won't attempt to configure more than one interface.
<tr><td VALIGN=TOP><B>Workgroup</B><td>This is the Lan Manager work group. In this version of Samba it is not used.
<tr><td VALIGN=TOP><B>Password Level</B><td>Some client/server combinations have difficulty with mixed-case passwords. One offending client is Windows for Workgroups, which for some reason forces passwords to upper case when using the LANMAN1 protocol, but leaves them alone when using COREPLUS!<P>
This parameter defines the maximum number of characters that may be upper case in passwords.<P>
For example, say the password given was "FRED". If password level is set to 1 (one), the following combinations would be tried if "FRED" failed: "Fred", "fred", "fRed", "frEd", "freD". If password level was set to 2 (two), the following combinations would also be tried: "FRed", "FrEd", "FreD", "fREd", "fReD", "frED". And so on.<P>
The higher value this parameter is set to the more likely it is that a mixed case password will be matched against a single case password. However, you should be aware that use of this parameter reduces security and increases the time taken to process a new connection.<P>
A value of zero will cause only two attempts to be made - the password as is and the password in all-lower case.
<tr><td VALIGN=TOP><B>Debuglevel</B><td>This is used for debugging !smbserver. !smbserver writes debugging information to
the file !smbserver.Resources.ALogFile. Normally debug level should be 0.
<tr><td VALIGN=TOP><B>socket TX buf size</B><td>Set the RISCOS socket transmit buffer size.
<tr><td VALIGN=TOP><B>socket RX buf size</B><td>Set the RISCOS soclet receive buffer size.
<tr><td VALIGN=TOP><B>Encrypt Passwords<B><td>This parameter controls whether encrypted passwords will be negotiated with the client. If set the client may send passwords encrypted to the server.Note that Windows 98, Windows NT 4.0 SP3 and above and some versions of Window 95 will by default expect encrypted passwords unless a registry entry is changed. See <A HREF="samba_03.htm#winPass">Win 95/98 Passwords</A> and <A HREF="samba_03.htm#winNTpass">Win NT Passwords</A>.
<tr><td VALIGN=TOP><B>Null Passwords</B><td>Allow or disallow access to shares that have null passwords.
<tr><td VALIGN=TPP><B>Detect !LanMan98</B><td>If set then !smbserver will detect !LanMan98 clients. If !smbserver detects a !LanMan98 client it will pass file names to it with the filetype appended as an hex number rather than an extension. For example the file fred with filetype jpeg will be served as fred,c85 instead of fred.jpg. This makes the filer on the client look eactly like the filer would do on the server. When !LanMan98 creates a file called fred,c85 !smbserver creates a file called fred and sets the filetype to JPEG.
<tr><td VALIGN=TPP><B>nameserver enabled</B><td>Enables the <A HREF="samba_13.htm#nameserver">Netbios Nameserver</A>.
<tr><td VALIGN=TOP><B>Protocol</B><td>This is used to select the protocol level. NT1 is the highest, CORE is the lowest. NT1 and LANMAN2 support long files names. With the other protocols filenames longer than 8 characters will be mangled on the client.
</td></tr></table>
<P>
Clicking <B>OK</B> makes the changes take effect. Clicking <B>Cancel</B> forgets
the current changes.<P>
<H4><A NAME="shareswind">3.3.1 Shares Window</A></H4><P>
<I>Large view</I><P>
<IMG SRC="images/sharewind"><P>
<I>Small view</I><P>
<IMG SRC="images/sharewindS"><P>
<I>Information view</I><P>
<IMG SRC="images/sharewindF"><P>
This version shows the Share name, whether is read only (ro) or writable (rw) and the pathname.<P> 
The shares window is used to add, delete, copy and rename shares.<P>
<B>Adding a share</B><P>
To add a share drag a directory (or image file) from anywhere and drop it
on the shares window. The share will be given the name of the leaf name
of the directory dropped on the window.<P>
Alternatively select NewShare from the Shares Window menu.<P>
<IMG SRC="images/menu5"><P>
Type in a name and click OK.<P>
<B>Copying a share</B><P>
To copy a share select Copy from the Shares Window menu.<P>
<IMG SRC="images/menu3"><P>
To rename a share select Rename from the Shares Window menu.<P>
<IMG SRC="images/menu4"><P>
To delete a share select Delete from the Shares Window menu.<P>
<IMG SRC="images/menu6"><P> 
To set a password on a share select Set Password from the Shares Windoe menu. The password is set immediately for the share and is stored encryped in &lt;samba$dir>.Resources.sharepass.<P> 
<IMG SRC="images/menu7"><P>
<H4><A NAME="shareswind">3.3.2 Shares Variables Window</H4><P>
Double click on a Share in the Shares window to see the Share Variables Window.<P>
<IMG SRC="images/sharevars"><P>
<TABLE BORDER=2>
<tr ><td VALIGN=TOP><B>Comment</B><td>This is a comment that might say something useful about this share.
<tr><td VALIGN=TOP><B>Path</B><td>This is the path which is being shared. It can be any directory (or image file)
on any filing systems (i.e. ADFS, SCSI, CDFS, NFS, IDEFS etc). You can drop a directory on the Path string as well as type it in.
<tr><td VALIGN=TOP><B>Print command</B><td>When a client prints something a file is copied across by the Samba protocol.
This command is used to print the file. An alternative command might be:<P>
<PRE>
copy %s printer: f~c~v
</PRE>
<tr><td VALIGN=TOP><B>Read Only</B><td>Makes a share read only.
<tr><td VALIGN=TOP><B>Guest OK</B><td>If this parameter is set for a share, then no password is required to connect to the share.
<tr><td VALIGN=TOP><B>Printable</B><td>Turns a share into a printer share. 
<tr><td VALIGN=TOP><B>Delete Readonly</B><td>This parameter allows readonly files to be deleted. This is not normal DOS semantics, but is allowed by UNIX.
<tr><td VALIGN=TOP><B>Set Filetype</B><td>When a file is created by a client on this share the file's filetype is set appropriately for the file's extension.
<tr><td VALIGN=TOP><B>Append Filetype</B><td>When a client is looking at directories on this share the files' filtypes are appended as an appropriate extension to the file name.
<tr><td VALIGN=TOP><B>Strip Extension</B><td>When a file is created by a client on this share the file's extension is stripped off.
<tr><td VALIGN=TOP><B>Detect DOSDisc</B><td>Detects whether this share contains DOSDiscs or is itself a DOSDisc. If a DOSDisc is detected the above three flags are overriden appropriately to force more suitable behaviour for a DOSDisc. (The filetype of the created file is set to DOS or the appropriate filetype for the file. File extensions are not stripped and filetypes are not appended on a directory search.)
<tr><td VALIGN=TOP><B>Expand Archive</B><td>If this is set and you have !ArcFs or !SparkFs loaded archives appear as directories on the client, otherwise archives apppear as a zip file on the client. Note if you do not have !ArcFs or !SparkFs loaded then archives appear as zip files on the client regardless of this flag. 
<tr><td VALIGN=TOP><B>Detect Extension</B><td>With this set the filetype is not appended as an extension if it looks like there is already an extension on the file. Consider the files fred/a and fred/j with filetype jpeg. With this set the file fred/a filetype jpeg is served as fred/a to the client and fred/j is served as fred/j. If this is not set the file fred/a is server as fred/a/jpg and fred/j is served as fred/jpg (not fred/j/jpg).
<tr><td VALIGN=TOP><B>Hex File Types</B><td>Forces SmbServer to export all files with the filetype appended as a hex number. e.g. File fred with filetype jpeg is servered as fred,c85 instead of fred.jpg. Really only useful if you want to back up a RiscOs share via !smbserver to a Windows (or Unix) machine and read back with !LanMan98. Unpredictable things will happen if you try to save files to the share from Windows when this flag is set. Use with care! Overrides Detect !LanMan98 and Append Filetype.
</td></tr></table>
<P>
Clicking <B>OK</B> makes the changes take effect. !smbserver checks the tha path is valid before accepting the changes. Clicking <B>Cancel</B> forgets the current changes.<P>
<H4><A NAME="editother">3.3.3 Editing Other Variables</A></H4><P>
This is recommend for advanced users only. If you wish to edit other variables find the variable you want in &lt;samba$dir>.resources.params and set the FALSE to TRUE. The next time you run !smbserver the variable will magically appear in the appropriate window. Note that if you edit variables other than those already shown in the configuration windows then you might get unexpected results since it is very probable that setting those variables has not been tested yet!<P>
See <A HREF="smbconf.htm">smb/conf man page</A>for descriptions of parameters not listed on this page.<P>
<P> 
<H3><A NAME="conf">3.4 Command Line Options</H3><P>
To run without an icon on the icon bar use the command line option -nobarion. To run with the icon on thr right of the icon bar use -rightbaricon. e.g. In !smbserver.!run
<table cellpadding="0" cellspacing="0" border="0" bgcolor=#ddffdd width=100%>
<tr>
<td valign="top">
<PRE>
*run &lt;samba$Dir>.!RunImage -nobaricon %*0
</PRE> 
</td>
</tr>
</table>
<P> 
<HR>
<A HREF="samba_02.htm"><IMG SRC="images/left.gif" ALIGH=LEFT BORDER=0></A> <A HREF="SAMBA.htm"><IMG SRC="images/cont.jpg" ALIGH=CENTRE BORDER=0></A> <A HREF="samba_04.htm" ALIGN=right><IMG SRC="images/right.gif"  ALIGN=RIGHT BORDER=0></A>  
<P>
<I>RISCOS Samba Server</I>
</BODY>
</HTML>
