[Samba] HELP! running 3.0.23c-2 on fedora core 6 strange slow speed problem

2007-05-09 Thread Bill Fung

Hi

i have experience deploying samba for several sites. Recently, i encounter a 
very strange problem. The site has been running samba and
sendmail on a server since nov 2006 and everything is fine. At mid Apr 2007, i 
add a new network interface eth1 for some reason:

BEFORE CHANGE
=

 INTERNET
 ^
 |
||
| ADSL MODEM |
||
 ^
 |
||
|   ROUTER1  |
|| 192.168.1.1
 ^
 |
||---
|   SWITCH   |--- XP CLIENTS (192.168.1.0/255.255.255.0)
||---
 ^
 |
|| eth0:192.168.1.2
|   SAMBA|
||


AFTER CHANGE
=

 INTERNET
 ^
 |
||
| ADSL MODEM |
||
 ^
 |
||
|   ROUTER1  |
|| 192.168.1.1
 ^
 |
|| eth1:192.168.1.2
|   SAMBA|
|| eth0:192.168.2.2
 |
 v
||---
|   SWITCH   |--- XP CLIENTS (192.168.2.0/255.255.255.0)
||---
 |
 v
|| 192.168.2.1
|   ROUTER2  |
||
 |
 v
||
| ADSL MODEM |
||
 |
 v
 INTERNET (VPN to remote site 192.168.0.0/255.255.255.0)

Simply speaking, samba/vpn traffic will go thru eth0 and email/other traffic 
will go thru eth0.
After the change, i encounter that the following strange situation:

1) copying files from XP clients to samba server is OK (no speed change, copy a 
16mb file in less than 3 seconds)

2) copying files from samba share to XP clients is sometimes normal and 
somestimes very slow (copy a 16mb files take about 3 minutes), strange
enough, when in the progress of copying a large file (200mb), the traffic could 
be speed up by copying a smaller file (16mb) at the same time. In
this case, the 16mb file will be copied at normal speed (3second), and you 
could observe the progress indicator of the 200mb file is speed up
during the copying of 16mb file. The progress indicator of the 200mb file will 
slow down again after copying the 16mb file.

Below is the routing table:
Kernel IP routing table
Destination Gateway Genmask Flags Metric RefUse Iface
192.168.2.0 0.0.0.0 255.255.255.0   U 0  0   0 eth0 
192.168.1.0 0.0.0.0 255.255.255.0   U 0  0   0 eth1 
192.168.0.0 192.168.2.1 255.255.255.0   UG0  0   0 eth0 
169.254.0.0 0.0.0.0 255.255.0.0 U 0  0   0 eth1 
0.0.0.0 192.168.1.1 0.0.0.0 UG0  0   0 eth1


I add a specific route to remote site 192.168.0.0/255.255.255.0 thru vpn by 
/sbin/route add -net 192.168.0.0/24 gw 192.168.2.1 dev eth0

Here is what i try:
1) uninstall samba and install again, start newly install samba again with 
default config with minimal changes. problem persist!
2) replace switch with another new switch, problem persist!!
3) i start a ftp service on the samba server and verify the network speed is 
normal, implying that network card/switch has no problem

I guess the problem may be caused by:
1) routing problem
2) samba multiple interface problem
3) samba ip change from 192.168.1.2 to 192.168.2.2

For 2), I have man smb.conf and add the following to my smb.conf:
interfaces = 192.168.2.0/24
But problem still persist.

For 3), anyone have any hints on that? changing ip of samba server will cause 
problem??

Any help will be highly appreciated. Thanks a lot in advanced.



--
Regards,
Bill

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


Re: [Samba] HELP! running 3.0.23c-2 on fedora core 6 strange slow speed problem

2007-05-09 Thread Bill Fung

Hi,

I remove the new added network interface eth1 yesterday and problem persist:

LATEST CHANGE
=

INTERNET
^
|
||
| ADSL MODEM |
||
^
|
||
|   ROUTER1  |
|| 192.168.2.254
^
|
|  ||
|  |   SAMBA|
|  || eth0:192.168.2.2
| /
|/
||---
|   SWITCH   |--- XP CLIENTS (192.168.2.0/255.255.255.0)
||---
|
v
|| 192.168.2.1
|   ROUTER2  |
||
|
v
||
| ADSL MODEM |
||
|
v
INTERNET (VPN to remote site 192.168.0.0/255.255.255.0)

Now, all traffic all thru eth0, routing table as follow:
Kernel IP routing table
Destination Gateway Genmask Flags Metric RefUse 
Iface

192.168.2.0 0.0.0.0 255.255.255.0   U 0  00 eth0
169.254.0.0 0.0.0.0 255.255.0.0 U 0  00 eth0
0.0.0.0 192.168.2.254   0.0.0.0 UG0  00 eth0

Let me repeat the problem:
1) copying files from XP clients to samba server is OK (no speed change, 
copy a 16mb file in less than 3 seconds)
2) copying files from samba share to XP clients is sometimes normal and 
sometimes very slow (copy a 16mb files take about 3 minutes), strange 
enough, when in the progress of copying a large file (200mb), the 
traffic could be SPEED UP by copying a smaller file (16mb) at the same 
time. In this case, the 16mb file will be copied at normal speed 
(3second), and you could observe the progress indicator of the 200mb 
file is speed up during the copying of 16mb file. The progress indicator 
of the 200mb file will slow down again after copying the 16mb file.


I figure out:
1) not hardware problem - because ftp to samba server is fast and switch 
has been replaced

2) not routing now - because there is only 1 network card is installed now

I try yesterday:
1) change samba server ip from 192.168.2.2 to 192.168.1.2 (like before) 
and problem persist.

2) remark the vscan-clamav option and problem persist.

I will try to uninstall the samba and install again today to see if it 
helps... really strange problem. Anyone encounter before?

I forget to give the background:
samba-3.0.23c-2
kernel 2.6.20-1.2944.fc6
below is testparm result:
Load smb config files from /etc/samba/smb.conf
Processing section [homes]
Processing section [netlogon]
Processing section [publictemp]
Processing section [management]
Processing section [photo]
Processing section [account]
Processing section [alldata]
Loaded services file OK.
Server role: ROLE_DOMAIN_PDC
Press enter to see a dump of your service definitions

[global]
   unix charset = BIG5
   workgroup = GROUPX
   server string = File Server
   update encrypted = Yes
   passwd program = /usr/bin/passwd %u
   passwd chat = *New*UNIX*password* %n\n 
*ReType*new*UNIX*password* %n\n 
*passwd:*all*authentication*tokens*updated*successfully*

   passwd chat debug = Yes
   unix password sync = Yes
   log level = 3 passdb:5 auth:10 winbind:2
   log file = /var/log/samba/%m.log
   add user script = /usr/sbin/useradd %u
   delete user script = /usr/sbin/userdel %u
   add group script = /usr/sbin/groupadd %g
   delete group script = /usr/sbin/groupdel %g
   delete user from group script = /usr/sbin/deluser %u %g
   add machine script = /usr/sbin/adduser -n -g machines -c Machine 
-d /dev/null -s /bin/false %u

   logon script = user.bat
   logon path =
   logon home =
   domain logons = Yes
   os level = 99
   preferred master = Yes
   domain master = Yes
   dns proxy = No
   wins support = Yes
   hosts allow = 192.168.0., 192.168.1., 192.168.2., 192.168.3., 127.
   cups options = raw

[homes]
   comment = Home Directories
   path = /sambahome/%S
   valid users = %S
   read only = No
   create mask = 0755
   browseable = No
   vfs objects = vscan-clamav
   vscan-clamav:config-file = /etc/samba/vscan-clamav.conf

[netlogon]
   comment = Network Logon Service
   path = /sambahome/netlogon
   guest ok = Yes
   share modes = No
   vfs objects = vscan-clamav
   vscan-clamav:config-file = /etc/samba/vscan-clamav.conf

[publictemp]
   comment = Public Stuff
   path = /sambahome/public
   read only = No
   guest only = Yes
   guest ok = Yes
   vfs objects = vscan-clamav
   vscan-clamav:config-file = /etc/samba/vscan-clamav.conf


--
Regards,
Bill

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