Re: [Samba] nmbd Hogging CPU on Mac OSX (10.5.4)

2008-08-24 Thread James Peach
2008/8/21 Mark Jackson <[EMAIL PROTECTED]>:
> Hi All,
>
> Firstly, I know this is a MacOS X issue and not sure if you guys can help,
> but I'm really hoping you can since I don't appear to be getting any joy
> elsewhere.
>
> Running OSX 10.5.4 and recently (last week) nmbd is hogging the CPU. I know
> this is a part of the Samba server on OSX, hence the post to this mail-list.
>
> When I disconnect from the network, nmbd goes away and doesn't hog the CPU.
> Reconnect, within a minute it comes back. Happens on both Wired and Wireless
> connections. I don't have filesharing enabled within OSX.
>
> Checked the logs in /var/logs/samba/log.nmbd and the last entries are below.
>
> My Mac is on my corporate network which is 99% Windows, if that matters...?
>
> Any thoughts or comments appreciated as this is getting quite frustrating
> now.
>
> Thanks,
> Mark
>
> [2008/08/21 09:09:28, 0, pid=118]
> /SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
>  tdb(/private/var/samba/gencache.tdb): tdb_rec_read bad magic 0xd9fee666 at
> offset=2592
> [2008/08/21 09:09:33, 0, pid=118]
> /SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
>  tdb(/private/var/samba/gencache.tdb): tdb_rec_read bad magic 0xd9fee666 at
> offset=2592
> [2008/08/21 09:09:33, 0, pid=118]
> /SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
>  tdb(/private/var/samba/gencache.tdb): tdb_rec_read bad magic 0xd9fee666 at
> offset=2592
> [2008/08/21 09:09:33, 0, pid=118]
> /SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
>  tdb(/private/var/samba/gencache.tdb): tdb_rec_read bad magic 0xd9fee666 at
> offset=2592
> [2008/08/21 09:09:34, 0, pid=118]
> /SourceCache/samba/samba-187.4/samba/source/nmbd/nmbd_browsesync.c:find_domain_master_name_query_fail(351)
>  find_domain_master_name_query_fail:
>  Unable to find the Domain Master Browser name WORKGROUP<1b> for the
> workgroup WORKGROUP.
>  Unable to sync browse lists in this workgroup.
> [2008/08/21 09:09:34, 0, pid=118]
> /SourceCache/samba/samba-187.4/samba/source/nmbd/nmbd_browsesync.c:find_domain_master_name_query_fail(351)
>  find_domain_master_name_query_fail:
>  Unable to find the Domain Master Browser name WORKGROUP<1b> for the
> workgroup WORKGROUP.
>  Unable to sync browse lists in this workgroup.
> [2008/08/21 09:24:43, 0, pid=118]
> /SourceCache/samba/samba-187.4/samba/source/nmbd/nmbd_browsesync.c:find_domain_master_name_query_fail(351)
>  find_domain_master_name_query_fail:
>  Unable to find the Domain Master Browser name WORKGROUP<1b> for the
> workgroup WORKGROUP.
>  Unable to sync browse lists in this workgroup.
> [2008/08/21 09:24:43, 0, pid=118]
> /SourceCache/samba/samba-187.4/samba/source/nmbd/nmbd_browsesync.c:find_domain_master_name_query_fail(351)
>  find_domain_master_name_query_fail:
>  Unable to find the Domain Master Browser name WORKGROUP<1b> for the
> workgroup WORKGROUP.
>  Unable to sync browse lists in this workgroup.
> [2008/08/21 09:29:54, 0, pid=118]
> /SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
>  tdb(/private/var/samba/gencache.tdb): remove_from_freelist: not on list at
> off=8736
> [2008/08/21 09:29:54, 0, pid=118]
> /SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
>  tdb(/private/var/samba/gencache.tdb): tdb_free: left free failed at 8736

gencache.tdb is corrupt, delete /var/samba/gencache.tdb.

-- 
James Peach | [EMAIL PROTECTED]
-- 
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/listinfo/samba


Re: [Samba] nmbd Hogging CPU on Mac OSX (10.5.4)

2008-08-24 Thread Rune Tønnesen

Mark Jackson skrev:

Hi All,

Firstly, I know this is a MacOS X issue and not sure if you guys can help,
but I'm really hoping you can since I don't appear to be getting any joy
elsewhere.

Running OSX 10.5.4 and recently (last week) nmbd is hogging the CPU. I know
this is a part of the Samba server on OSX, hence the post to this mail-list.

When I disconnect from the network, nmbd goes away and doesn't hog the CPU.
Reconnect, within a minute it comes back. Happens on both Wired and Wireless
connections. I don't have filesharing enabled within OSX.

Checked the logs in /var/logs/samba/log.nmbd and the last entries are below.

My Mac is on my corporate network which is 99% Windows, if that matters...?

Any thoughts or comments appreciated as this is getting quite frustrating
now.

Thanks,
Mark

[2008/08/21 09:09:28, 0, pid=118]
/SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
  tdb(/private/var/samba/gencache.tdb): tdb_rec_read bad magic 0xd9fee666 at
offset=2592
[2008/08/21 09:09:33, 0, pid=118]
/SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
  tdb(/private/var/samba/gencache.tdb): tdb_rec_read bad magic 0xd9fee666 at
offset=2592
[2008/08/21 09:09:33, 0, pid=118]
/SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
  tdb(/private/var/samba/gencache.tdb): tdb_rec_read bad magic 0xd9fee666 at
offset=2592
[2008/08/21 09:09:33, 0, pid=118]
/SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
  tdb(/private/var/samba/gencache.tdb): tdb_rec_read bad magic 0xd9fee666 at
offset=2592
[2008/08/21 09:09:34, 0, pid=118]
/SourceCache/samba/samba-187.4/samba/source/nmbd/nmbd_browsesync.c:find_domain_master_name_query_fail(351)
  find_domain_master_name_query_fail:
  Unable to find the Domain Master Browser name WORKGROUP<1b> for the
workgroup WORKGROUP.
  Unable to sync browse lists in this workgroup.
[2008/08/21 09:09:34, 0, pid=118]
/SourceCache/samba/samba-187.4/samba/source/nmbd/nmbd_browsesync.c:find_domain_master_name_query_fail(351)
  find_domain_master_name_query_fail:
  Unable to find the Domain Master Browser name WORKGROUP<1b> for the
workgroup WORKGROUP.
  Unable to sync browse lists in this workgroup.
[2008/08/21 09:24:43, 0, pid=118]
/SourceCache/samba/samba-187.4/samba/source/nmbd/nmbd_browsesync.c:find_domain_master_name_query_fail(351)
  find_domain_master_name_query_fail:
  Unable to find the Domain Master Browser name WORKGROUP<1b> for the
workgroup WORKGROUP.
  Unable to sync browse lists in this workgroup.
[2008/08/21 09:24:43, 0, pid=118]
/SourceCache/samba/samba-187.4/samba/source/nmbd/nmbd_browsesync.c:find_domain_master_name_query_fail(351)
  find_domain_master_name_query_fail:
  Unable to find the Domain Master Browser name WORKGROUP<1b> for the
workgroup WORKGROUP.
  Unable to sync browse lists in this workgroup.
[2008/08/21 09:29:54, 0, pid=118]
/SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
  tdb(/private/var/samba/gencache.tdb): remove_from_freelist: not on list at
off=8736
[2008/08/21 09:29:54, 0, pid=118]
/SourceCache/samba/samba-187.4/samba/source/lib/util_tdb.c:tdb_log(662)
  tdb(/private/var/samba/gencache.tdb): tdb_free: left free failed at 8736
[2008/08/21 09:39:29, 0]
/SourceCache/samba/samba-187.4/samba/source/nmbd/nmbd.c:main(695)
  Netbios nameserver version 3.0.25b-apple started.
  Copyright Andrew Tridgell and the Samba Team 1992-2007
[2008/08/21 09:51:34, 0]
/SourceCache/samba/samba-187.4/samba/source/nmbd/nmbd.c:main(695)
  Netbios nameserver version 3.0.25b-apple started.
  Copyright Andrew Tridgell and the Samba Team 1992-2007
  

It looks like a problem with nameresolution
It says it can't find the browsemaster for workgroup WORKGROUP
Is your mac os x box member of windows domain?

please take a look at 
http://oreilly.com/catalog/samba/chapter/book/ch07_03.html


Cheers Rune


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


[Samba] Re: ldapsearch and getent passd/group with nss winbind differs

2008-08-24 Thread Andreas Ladanyi

There is one "UNIX attribute" tab and one "Members Of" tab.
During some tests we discover the following facts
=
In "UNIX attribute" tab:

winbind is only interested in the UID field ->
in ldap tree the attribute "uidnumber".
If you're talking SFU, it doesn't use uidnumber.  It uses attribute 
msSFU30UidNumber and displays UID on the Unix Attributes tab.
I don't have a Windows 2003 R2 for comparison.  Are you really using SFU 
(Services For Unix 3.0) or do you have the newer 2003 R2?


I use 2003 R2 and did install the "Unix plugin" for AD schemata 
extension from Windows component setup.


The other attributes from "UNIX attribute" tab are written to ldap 
tree, but not used by winbind on linux side.

For example we set the following parameter in smb.conf:
winbind nss info = sfu
Of course we could define our own template bash/home with the 
"template home" and "template shell" parameter, but its better the 
"sfu" will work, so we would configure this parameter by the tab.
Winbind only uses this parameter when it creates a Unix account.  Which 
shouldn't happen for your AD domain members if your AD is mapped correctly.


winbind uses this parameter only if "it" creates a unix account ? In 
case if i create a unix account with "adduser" on terminal ?


The mapping seems to be correctly if i have a look at "getent passwd + 
getent group"


The "primary Group" is written to the ldap tree but not used by 
winbind on the unix side.


I meant the "primary Group" text field from:

"UNIX attribute" tab

seems to be NOT used by winbind.



The "primary group" which you can set:

by clicking the button "primary group" in "Members Of" tab

IS USED by winbind perfectly.


Iam sorry if my explanation wasnt clear at my last posting.



# net ads testjoin
Join is OK

# wbinfo -i forest\\jdoe
FOREST\jdoe:*:525:100:John Doe:/home/jdoe:/bin/bash
# getent passwd|grep jdoe
FOREST\jdoe:*:525:100:John Doe:/home/jdoe:/bin/bash

# getent group|grep 100
FOREST\domain users:x:100:

You can set the value msSFU30Gecos and winbind will report it, otherwise 
"Display Name" is used.



In "Members Of" tab:

In this tab you can choose a group from a list and there is a button 
you could set a Unix primary group by klicking. This will be read by 
winbind only. But this have no force to the primary group ID on the 
"UNIX attribute" tab.


What do you say ? Did we configure something wrong ? Is this the 
normal function ?

I needed to use the "idmap config" values:
   idmap domains = FOREST
   idmap config FOREST:readonly = yes
   idmap config FOREST:backend = ad
   idmap config FOREST:range = 0 - 2
   idmap config FOREST:schema_mode = sfu

   idmap alloc backend = tdb
   idmap alloc config:range = 5-50999

and of course in nsswitch.conf:
passwd: compat winbind
group:  compat winbind

some people like to use "files" instead of "compat", but that's about 
NIS semantics and doesn't matter to winbind.



 winbind separator = /
 winbind enum users = yes
 winbind enum groups = yes
 winbind cache time = 60
 idmap backend = ad
 idmap uid = 6000-27000
 idmap gid = 600-7000
 template shell = /bin/bash
 template homedir = /home/%U
 winbind use default domain = yes
 winbind refresh tickets = yes
 allow trusted domains = yes
 winbind nss info =  sfu  template

My nsswitch.conf is like yours.

We want to use the "compat" mode because we hope we could exclude some 
users for login. This isnt possible to winbind ?!


Alternatively i know pam_require. Do you know an opportunity to do this 
task ?


Is there a part of documentation where the ldap attributes are shown 
which are used by winbind ? Or do i have to look up this at source code :-)



Thanks a lot for your posting,

Andy





Regards, Doug



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


Re: [Samba] Re: ldapsearch and getent passd/group with nss winbind differs

2008-08-24 Thread Doug VanLeuven

Andreas Ladanyi wrote:

Hay Jerry,

Gerald (Jerry) Carter schrieb:

Andreas Ladanyi wrote:


Ok ! Could it be true this behavior is different between
"security=domain" and "security=ads" ?

Because we had to put the user to the group:
- first on windows side in ActiveFirectory
- second on unix site in AD in the tab "Members of"

so winbind 3.0.24 client recognise the group membership on unix side 
in "security=domain" mode.


Now we changed to Samba 3.0.31 with security=ads mode and the 
behavior is a bit different.


You lost me here.  Maybe due to the fact that I accustomed
to the Windows 2003 R2 Unix Attribute tab.  The only member
of tab I see is to control the Windows group memberships.

The reason of my message is a litte confusion:
In general you are right ;-)

Good thing too, because he's one of the primary samba developers =-O


There is one "UNIX attribute" tab and one "Members Of" tab.
During some tests we discover the following facts
=
In "UNIX attribute" tab:

winbind is only interested in the UID field ->
in ldap tree the attribute "uidnumber".
If you're talking SFU, it doesn't use uidnumber.  It uses attribute 
msSFU30UidNumber and displays UID on the Unix Attributes tab.
I don't have a Windows 2003 R2 for comparison.  Are you really using SFU 
(Services For Unix 3.0) or do you have the newer 2003 R2?
The other attributes from "UNIX attribute" tab are written to ldap 
tree, but not used by winbind on linux side.

For example we set the following parameter in smb.conf:
winbind nss info = sfu
Of course we could define our own template bash/home with the 
"template home" and "template shell" parameter, but its better the 
"sfu" will work, so we would configure this parameter by the tab.
Winbind only uses this parameter when it creates a Unix account.  Which 
shouldn't happen for your AD domain members if your AD is mapped correctly.


The "primary Group" is written to the ldap tree but not used by 
winbind on the unix side.

# net ads testjoin
Join is OK

# wbinfo -i forest\\jdoe
FOREST\jdoe:*:525:100:John Doe:/home/jdoe:/bin/bash
# getent passwd|grep jdoe
FOREST\jdoe:*:525:100:John Doe:/home/jdoe:/bin/bash

# getent group|grep 100
FOREST\domain users:x:100:

You can set the value msSFU30Gecos and winbind will report it, otherwise 
"Display Name" is used.



In "Members Of" tab:

In this tab you can choose a group from a list and there is a button 
you could set a Unix primary group by klicking. This will be read by 
winbind only. But this have no force to the primary group ID on the 
"UNIX attribute" tab.


What do you say ? Did we configure something wrong ? Is this the 
normal function ?

I needed to use the "idmap config" values:
   idmap domains = FOREST
   idmap config FOREST:readonly = yes
   idmap config FOREST:backend = ad
   idmap config FOREST:range = 0 - 2
   idmap config FOREST:schema_mode = sfu

   idmap alloc backend = tdb
   idmap alloc config:range = 5-50999

and of course in nsswitch.conf:
passwd: compat winbind
group:  compat winbind

some people like to use "files" instead of "compat", but that's about 
NIS semantics and doesn't matter to winbind.



Regards, Doug

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


[Samba] Performance problem when tagging mp3 files

2008-08-24 Thread Jörg Spilker

Hello you,

maybe you can help me with a performance problem i´ve when tagging mp3 
files from a windows vista system where the files are located on a samba 
share hosted by a suse linux 9.3.


these are my performance relevant settings.

# These settings are a suggestion for a local network. Cf. section
# 'socket options' in the man page of smb.conf and socket(7).
time server = yes
getwd cache = yes
level2 oplocks = yes
preserve case = yes
case sensitive = no
map archive = no
socket options = SO_KEEPALIVE IPTOS_LOWDELAY TCP_NODELAY

the performance when transferring large files is great in my opinion. 
I´ve hand stopped 72 seconds for transferring about 800MB to a share (in 
a 100MBit network).


But tagging mp3 files is incredibly slow. For example: If i just change 
the album tag of 10 mp3 files and save the result, saving lasts about 30 
seconds or more.


And my samba log (with log level 2) shows something like:

[2008/08/24 10:01:04, 2] smbd/open.c:open_file(352)
  js opened file mp3/Rock/U2/U218 Singles/U2 And Green Day - U218 
Singles - 17 - The Saints Are Coming.mp3 read=Yes write=No (numopen=1)

[2008/08/24 10:01:04, 2] smbd/close.c:close_normal_file(344)
  ftp closed file mp3/Rock/U2/U218 Singles/U2 And Green Day - U218 
Singles - 17 - The Saints Are Coming.mp3 (numopen=0)

[2008/08/24 10:01:04, 2] smbd/open.c:open_file(352)
  js opened file mp3/Rock/U2/U218 Singles/U2 And Green Day - U218 
Singles - 17 - The Saints Are Coming.mp3 read=Yes write=Yes (numopen=1)

[2008/08/24 10:01:07, 2] smbd/close.c:close_normal_file(344)
  ftp closed file mp3/Rock/U2/U218 Singles/U2 And Green Day - U218 
Singles - 17 - The Saints Are Coming.mp3 (numopen=0)

[2008/08/24 10:01:07, 2] smbd/open.c:open_file(352)
  js opened file mp3/Rock/U2/U218 Singles/U2 And Green Day - U218 
Singles - 17 - The Saints Are Coming.mp3 read=Yes write=No (numopen=1)


there is this strange 3 seconds delay on the write operation? I must say 
that the share has force user ftp and force group daemon and myself i 
logged on the windows system with the account "js".


Can i do anything against this problem?

Greetings, Jörg.
--
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/listinfo/samba


[Samba] restrict users from loggin in on more than one machine

2008-08-24 Thread Siju George
Hi,

I have a Samba 3 PDC
How do you restrict users from loggin in on more than one machine at
the same time?

Thanks

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