Re: [Samba] Slow Directory listing for large number of files

2004-04-19 Thread Michael Carmack
Matthew Enger wrote:

I have a samba server which has a directory with 11764 files. (The
program stores information about jobs and each job has 3 files, nothing
I can do about it).
When I do a listing of that directory using smbclient, it takes 15+
seconds to complete, same thing on Windows XP.
I have tried Samba 2.2.7a and 3.0.2 which both have the same issue. Log
is from 3.0.2. Running Fedora Core 1 and ext3 file system.
How fast do you get a listing when directly on the server? Most 
filesystems become really slow once you get more than a couple thousand 
files in them.

If listings are slow on the server, the only thing you can do is divide 
up the files into subdirectories or switch to something like reiserfs 
that can handle large directories.

I don't know if anything can help XP though. I once had a directory with 
~25,000 files on a samba server, and XP would just hang when trying to 
list it.

m.

--
To unsubscribe from this list go to the following URL and read the
instructions:  http://lists.samba.org/mailman/listinfo/samba


Re: [Samba] Incorrect permissions on mount despite correct options

2004-04-18 Thread Michael Carmack
Tim Starr wrote:
The problem was 
that it was/is being mounted under the following permissions:

[EMAIL PROTECTED]:~/mount$ ls -l
total 0
drwxr-xr-x1 501  dialout 0 Apr  7 20:39 Audio
drwxrwxr-x1 501  dialout 0 Apr  9 01:29 Desktop
Now I have no user 501 on my system and no dialout group either. Odd. 
With Linux kernel 2.6.x and 2.4.25+, CIFS Unix extensions are in effect, 
allowing you to view and manipulate Unix-y things like symlinks and 
suid/sgid files using Samba.

This also has the effect that the Unix UIDs and GIDs from the server get 
passed to the client.

If you look on the server, you'll see that 501 is the numeric ID for 
the user that actually owns the file. And though you may not be aware of 
it, you *should* have a group called dialout on the Linux machine. 
(Look at /etc/group to confirm.) You'll notice that the numeric ID for 
the dialout group on your Linux machine maps to the numeric ID for the 
file's group on the server.

[In case you were wondering what the point of this is, these changes 
make Samba play nicer with Unix machines. It makes it possible to 
replace something like NFS with Samba.]

In the 2.4 series (as of 2.4.25), the Unix extensions are an optional 
configuration of the Linux kernel (i.e. you enable or disable this when 
building the kernel). I haven't looked at 2.6 yet, but I suspect it's 
also optional there. I don't know whether you can turn this behavior off 
or on after the kernel is built (using a mount option or a /proc setting 
or something), as I just started using it myself.

FWIW, I've encountered a couple pitfalls myself. I think maybe there are 
still some issues to work out, so if Samba was previously doing 
everything you needed it to and you don't need the Unixy features, you 
might want to use a kernel that has these entensions disabled.

(Just a slight caution: I haven't spent a lot of time using Samba, so I 
may be a little off with some of the things I just said. If so, 
hopefully the experts will set the record straight.)

m.

--
To unsubscribe from this list go to the following URL and read the
instructions:  http://lists.samba.org/mailman/listinfo/samba


Re: [Samba] Case-sensitivity problems with smbmount on linux

2004-04-17 Thread Michael Carmack
Can anyone else confirm this problem so I know I'm not crazy? I've tried 
many different configuration options, but cannot get this working.

In case my first post was too verbose, here's a quick way to see the 
problem.

1. Have 3 machines: Samba server, XP client, Linux client.
2. Mount shares (smbmount on Linux, map network drive on XP)
3. Create a file called test on the server.
4. Using the Linux cilent, do mv test Test (this fails).
5. Using the XP shell, do move test Test (this works).
Bug? Feature? Misconfiguration? At this point I'd be happy with an 
RTFM reply, but which M? I've searched google and the mailing lists 
for hours, and cannot find a solution. Might not be typing in the right 
keywords though...

Michael Carmack wrote:
[This seems like it should be a FAQ, but I searched for quite some time 
without finding anything.]

Mounting a samba share using smbmount under linux leads to problems when 
dealing with filenames that differ in case only. These problems do not 
affect WinXP mounting the same share, so it looks like a client issue.

The server is running Samba 3.0.1 on linux, kernel 2.4.20. The relevant 
part of smb.conf looks like:

  case sensitive = yes
  preserve case = yes
  short preserve case = yes
On the server I create two files, test and TEST, as follows:

[EMAIL PROTECTED] echo test  test
[EMAIL PROTECTED] echo TEST  TEST
Running some commands from the linux client, after mounting with 
smbmount/3.0.1 (kernel 2.4.25):

[EMAIL PROTECTED] ls
TEST  test
[EMAIL PROTECTED] cat TEST
test
[EMAIL PROTECTED] cat test
test
[EMAIL PROTECTED] mv test Test
mv: overwrite `Test'? n
It appears 'cat' can only see the lowercase file. Same for when you try 
to move the file. Instead of renaming, it thinks you want to overwrite 
the existing file. Other file utilities are affected in similar ways.

I believe the server is properly configured, since under WinXP the 
behavior is as one would expect:

  dir
. TEST
. test
  type TEST
TEST
  type test
test
  move test Test
...
  dir
. TEST
. Test
I find this odd, because I would expect the Linux client to be at least 
as capable as the WinXP client in handling the case differences (if 
anything I'd expect the XP machine to be the one with the problems).

Have I overlooked something?

Thanks,
Michael Carmack
[EMAIL PROTECTED]

--
To unsubscribe from this list go to the following URL and read the
instructions:  http://lists.samba.org/mailman/listinfo/samba


[Samba] Case-sensitivity problems with smbmount on linux

2004-04-12 Thread Michael Carmack
[This seems like it should be a FAQ, but I searched for quite some time 
without finding anything.]

Mounting a samba share using smbmount under linux leads to problems when 
dealing with filenames that differ in case only. These problems do not 
affect WinXP mounting the same share, so it looks like a client issue.

The server is running Samba 3.0.1 on linux, kernel 2.4.20. The relevant 
part of smb.conf looks like:

  case sensitive = yes
  preserve case = yes
  short preserve case = yes
On the server I create two files, test and TEST, as follows:

[EMAIL PROTECTED] echo test  test
[EMAIL PROTECTED] echo TEST  TEST
Running some commands from the linux client, after mounting with 
smbmount/3.0.1 (kernel 2.4.25):

[EMAIL PROTECTED] ls
TEST  test
[EMAIL PROTECTED] cat TEST
test
[EMAIL PROTECTED] cat test
test
[EMAIL PROTECTED] mv test Test
mv: overwrite `Test'? n
It appears 'cat' can only see the lowercase file. Same for when you try 
to move the file. Instead of renaming, it thinks you want to overwrite 
the existing file. Other file utilities are affected in similar ways.

I believe the server is properly configured, since under WinXP the 
behavior is as one would expect:

 dir
. TEST
. test
 type TEST
TEST
 type test
test
 move test Test
...
 dir
. TEST
. Test
I find this odd, because I would expect the Linux client to be at least 
as capable as the WinXP client in handling the case differences (if 
anything I'd expect the XP machine to be the one with the problems).

Have I overlooked something?

Thanks,
Michael Carmack
[EMAIL PROTECTED]
--
To unsubscribe from this list go to the following URL and read the
instructions:  http://lists.samba.org/mailman/listinfo/samba