Previous Next Table of Contents

3. Common client questions

3.1 Are any Macintosh clients for Samba

In Rob Newberry's words (rob@eats.com, Sun, 4 Dec 1994):

The answer is "No." Samba speaks SMB, the protocol used for Microsoft networks. The Macintosh has ALWAYS spoken Appletalk. Even with Microsoft "services for Macintosh", it has been a matter of making the server speak Appletalk. It is the same for Novell Netware and the Macintosh, although I believe Novell has (VERY LATE) released an extension for the Mac to let it speak IPX.

In future Apple System Software, you may see support for other protocols, such as SMB -- Applet is working on a new networking architecture that will --> -- make it easier to support additional protocols. But it's not here yet.

Now, the nice part is that if you want your Unix machine to speak Appletalk, there are several options. "Netatalk" and "CAP" are free, and available on the net. There are also several commercial options, such as "PacerShare" and "Helios" (I think). In any case, you'll have to look around for a server, not anything for the Mac.

Depending on you OS, some of these may not help you. I am currently coordinating the effort to get CAP working with Native Ethertalk under Linux, but we're not done yet.

3.2 "Session request failed (131,130)" error

The following answer is provided by John E. Miller:

I'll assume that you're able to ping back and forth between the machines by IP address and name, and that you're using some security model where you're confident that you've got user IDs and passwords right. The logging options (-d3 or greater) can help a lot with that. DNS and WINS configuration can also impact connectivity as well.

Now, on to 'scope id's. Somewhere in your Win95 TCP/IP network configuration (I'm too much of an NT bigot to know where it's located in the Win95 setup, but I'll have to learn someday since I teach for a Microsoft Solution Provider Authorized Tech Education Center - what an acronym...) Note: It's under Control Panel | Network | TCP/IP | WINS Configuration there's a little text entry field called something like 'Scope ID'.

This field essentially creates 'invisible' sub-workgroups on the same wire. Boxes can only see other boxes whose Scope IDs are set to the exact same value - it's sometimes used by OEMs to configure their boxes to browse only other boxes from the same vendor and, in most environments, this field should be left blank. If you, in fact, have something in this box that EXACT value (case-sensitive!) needs to be provided to smbclient and nmbd as the -i (lowercase) parameter. So, if your Scope ID is configured as the string 'SomeStr' in Win95 then you'd have to use smbclient -iSomeStr otherparms in connecting to it.

3.3 How do I synchronise my PC's clock with my Samba server?

To syncronize your PC's clock with your Samba server:

* Copy timesync.pif to your windows directory * timesync.pif can be found at: http://samba.canberra.edu.au/pub/samba/binaries/miscellaneous/timesync.pif * Add timesync.pif to your 'Start Up' group/folder * Open the properties dialog box for the program/icon * Make sure the 'Run Minimized' option is set in program 'Properties' * Change the command line section that reads \\sambahost to reflect the name of your server. * Close the properties dialog box by choosing 'OK'

Each time you start your computer (or login for Win95) your PC will synchronize it's clock with your Samba server.

3.4 Problems with WinDD, NTrigue, WinCenterPro etc

All of the above programs are applications that sit on an NT box and allow multiple users to access the NT GUI applications from remote workstations (often over X).

What has this got to do with Samba? The problem comes when these users use filemanager to mount shares from a Samba server. The most common symptom is that the first user to connect get correct file permissions and has a nice day, but subsequent connections get logged in as the same user as the first person to login. They find that they cannot access files in their own home directory, but that they can access files in the first users home directory (maybe not such a nice day after all?)

Why does this happen? The above products all share a common heritage (and code base I believe). They all open just a single TCP based SMB connection to the Samba server, and requests from all users are piped over this connection. This is unfortunate, but not fatal.

It means that if you run your Samba server in share level security (the default) then things will definately break as described above. The share level SMB security model has no provision for multiple user IDs on the one SMB connection. See security_level.txt in the docs for more info on share/user/server level security.

If you run in user or server level security then you have a chance, but only if you have a recent version of Samba (at least 1.9.15p6). In older versions bugs in Samba meant you still would have had problems.

If you have a trapdoor uid system in your OS then it will never work properly. Samba needs to be able to switch uids on the connection and it can't if your OS has a trapdoor uid system. You'll know this because Samba will note it in your logs.

Also note that you should not use the magic "homes" share name with products like these, as otherwise all users will end up with the same home directory. Use \\server\username instead.

3.5 Problem with printers under NT

This info from Stefan Hergeth hergeth@f7axp1.informatik.fh-muenchen.de may be useful:

A network-printer (with ethernetcard) is connected to the NT-Clients via our UNIX-Fileserver (SAMBA-Server), like the configuration told by Matthew Harrell harrell@leech.nrl.navy.mil (see WinNT.txt)

1.) If a user has choosen this printer as the default printer in his NT-Session and this printer is not connected to the network (e.g. switched off) than this user has a problem with the SAMBA- connection of his filesystems. It's very slow.

2.) If the printer is connected to the network everything works fine.

3.) When the smbd ist started with debug level 3, you can see that the NT spooling system try to connect to the printer many times. If the printer ist not connected to the network this request fails and the NT spooler is wasting a lot of time to connect to the printer service. This seems to be the reason for the slow network connection.

4.) Maybe it's possible to change this behaviour by setting different printer properties in the Print-Manager-Menu of NT, but i didn't try it yet.

3.6 Why are my file's timestamps off by an hour, or by a few hours?

This is from Paul Eggert eggert@twinsun.com.

Most likely it's a problem with your time zone settings.

Internally, Samba maintains time in traditional Unix format, namely, the number of seconds since 1970-01-01 00:00:00 Universal Time (or ``GMT''), not counting leap seconds.

On the server side, Samba uses the Unix TZ variable to convert internal timestamps to and from local time. So on the server side, there are two things to get right.

1. The Unix system clock must have the correct Universal time. Use the shell command "sh -c 'TZ=UTC0 date'" to check this.

2. The TZ environment variable must be set on the server before Samba is invoked. The details of this depend on the server OS, but typically you must edit a file whose name is /etc/TIMEZONE or /etc/default/init, or run the command `zic -l'.

3. TZ must have the correct value.

3a. If possible, use geographical time zone settings (e.g. TZ='America/Los_Angeles' or perhaps TZ=':US/Pacific'). These are supported by most popular Unix OSes, are easier to get right, and are more accurate for historical timestamps. If your operating system has out-of-date tables, you should be able to update them from the public domain time zone tables at URL:ftp://elsie.nci.nih.gov/pub/.

3b. If your system does not support geographical time zone settings, you must use a Posix-style TZ strings, e.g. TZ='PST8PDT,M4.1.0/2,M10.5.0/2' for US Pacific time. Posix TZ strings can take the following form (with optional items in brackets):

StdOffsetDst[Offset,Date/Time,Date/Time]

where:

`Std' is the standard time designation (e.g. `PST').

`Offset' is the number of hours behind UTC (e.g. `8'). Prepend a `-' if you are ahead of UTC, and append `:30' if you are at a half-hour offset. Omit all the remaining items if you do not use daylight-saving time.

`Dst' is the daylight-saving time designation (e.g. `PDT').

The optional second `Offset' is the number of hours that daylight-saving time is behind UTC. The default is 1 hour ahead of standard time.

`Date/Time,Date/Time' specify when daylight-saving time starts and ends. The format for a date is `Mm.n.d', which specifies the dth day (0 is Sunday) of the nth week of the mth month, where week 5 means the last such day in the month. The format for a time is hh:mm[:ss], using a 24-hour clock.

Other Posix string formats are allowed but you don't want to know about them.

On the client side, you must make sure that your client's clock and time zone is also set appropriately. [I don't know how to do this.] Samba traditionally has had many problems dealing with time zones, due to the bizarre ways that Microsoft network protocols handle time zones. A common symptom is for file timestamps to be off by an hour. To work around the problem, try disconnecting from your Samba server and then reconnecting to it; or upgrade your Samba server to 1.9.16alpha10 or later.

3.7 How do I set the printer driver name correctly?

Question: > On NT, I opened "Printer Manager" and "Connect to Printer". > Enter "\\ptdi270\ps1" in the box of printer. I got the > following error message: > > You do not have sufficient access to your machine > to connect to the selected printer, since a driver > needs to be installed locally.

Answer:

In the more recent versions of Samba you can now set the "printer driver" in smb.conf. This tells the client what driver to use. For example, I have:

printer driver = HP LaserJet 4L

and NT knows to use the right driver. You have to get this string exactly right.

To find the exact string to use, you need to get to the dialog box in your client where you select which printer driver to install. The correct strings for all the different printers are shown in a listbox in that dialog box.

You could also try setting the driver to NULL like this:

printer driver = NULL

this is effectively what older versions of Samba did, so if that worked for you then give it a go. If this does work then let me know and I'll make it the default. Currently the default is a 0 length string.


Previous Next Table of Contents