Samba damn slow

This is a discussion on Samba damn slow within the Linux Networking forums, part of the Linux Forums category; Rasta99 <rasta99@libero.it> wrote: > I have 3 pc, 2 winxp and 1 fedora1, all with nic ...


Go Back   Usenet Forums > Linux Forums > Linux Networking

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 06-10-2004
Cameron Kerr
 
Posts: n/a
Default Re: Samba damn slow

Rasta99 <rasta99@libero.it> wrote:

> I have 3 pc, 2 winxp and 1 fedora1, all with nic 10/100 and all connected to
> a switch 10/100.
> Samba is ok and the lan is working but tranfers between the linux box and
> each others 2 win are damn slow, it takes 7 min. for a 10 Mb file. What
> could be the problem?


Are you _sure_ it's Samba, and not the network itself? How fast can you
transfer data using other means, such as FTP (which isn't ideal, but
you've only got 1 linux machine, which limits your testing tools)

You're not using Cat3 rated cable, are you?

You haven't forced any auto-negotiation settings, such as forcing half or
full duplex?

What does `mii-tool -v' tell you about your internal interface, as root?

What does `ifconfig' tell you about the (internal) interface on your
linux box? In particular, I want to see the error counters, so don't
discard them.

--
Cameron Kerr
cameron.kerr@paradise.net.nz : http://nzgeeks.org/cameron/
Empowered by Perl!
Reply With Quote
  #2 (permalink)  
Old 06-10-2004
Rasta99
 
Posts: n/a
Default Samba damn slow

I have 3 pc, 2 winxp and 1 fedora1, all with nic 10/100 and all connected to
a switch 10/100.
Samba is ok and the lan is working but tranfers between the linux box and
each others 2 win are damn slow, it takes 7 min. for a 10 Mb file. What
could be the problem?

This is my simple smb.conf:

[global]

workgroup = work
server string = Samba
smb passwd file = /etc/samba/smbpasswrd
map to guest = bad user

printing = cups
printcap name = /etc/printcap
load printers = yes

log file = /var/log/samba/%m.log
max log size = 50
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
username map = /etc/samba/smbusers
dns proxy = no

[homes]

comment = Home Directories
browseable = yes
writeable = yes

[printers]

comment = Stamp
path = /var/spool/samba
browseable = yes
guest ok = yes
guest ok = yes
printable = yes

[tmp]

comment = Temporary file space
path = /tmp
writeable = yes
guest ok = yes

[archive]

comment = Archive
path = /archive
writeable = yes
guest ok = yes


Reply With Quote
  #3 (permalink)  
Old 06-11-2004
CJT
 
Posts: n/a
Default Re: Samba damn slow

Rasta99 wrote:

> I have 3 pc, 2 winxp and 1 fedora1, all with nic 10/100 and all connected to
> a switch 10/100.
> Samba is ok and the lan is working but tranfers between the linux box and
> each others 2 win are damn slow, it takes 7 min. for a 10 Mb file. What
> could be the problem?
>
> This is my simple smb.conf:
>
> [global]
>
> workgroup = work
> server string = Samba
> smb passwd file = /etc/samba/smbpasswrd
> map to guest = bad user
>
> printing = cups
> printcap name = /etc/printcap
> load printers = yes
>
> log file = /var/log/samba/%m.log
> max log size = 50
> socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
> username map = /etc/samba/smbusers
> dns proxy = no
>
> [homes]
>
> comment = Home Directories
> browseable = yes
> writeable = yes
>
> [printers]
>
> comment = Stamp
> path = /var/spool/samba
> browseable = yes
> guest ok = yes
> guest ok = yes
> printable = yes
>
> [tmp]
>
> comment = Temporary file space
> path = /tmp
> writeable = yes
> guest ok = yes
>
> [archive]
>
> comment = Archive
> path = /archive
> writeable = yes
> guest ok = yes
>
>


Are you sure it's Samba? Can you FTP at a more reasonable speed?

--
The e-mail address in our reply-to line is reversed in an attempt to
minimize spam. Our true address is of the form che...@prodigy.net.
Reply With Quote
  #4 (permalink)  
Old 06-11-2004
Rasta99
 
Posts: n/a
Default Re: Samba damn slow

> Are you _sure_ it's Samba, and not the network itself? How fast can you
> transfer data using other means, such as FTP (which isn't ideal,



I tried with a prog in win (blazeftp) but when but the linux one refuses the
connection, do i have to setup something on it or start any service? I
suppose there is no need to tell i'm a linux newbie :)

> you've only got 1 linux machine, which limits your testing tools)


I could install another fedora in dual boot on 1 of the win pc if this could
help.

> You're not using Cat3 rated cable, are you?


Yes, i'm using a STP cat5 freq 200 mhz cable that should be ok, maybe
between the 2 win pc tranfers are ok at 100 mbps so i think it's not a cable
problem.

> You haven't forced any auto-negotiation settings, such as forcing half or
> full duplex?


In win the nic speed is set to AUTO CONFIG, it's surely at 100 but i don't
know if half or full duplex.
In linux i did nothing, i don't know how to configure the nic, it's all like
fedora has done during the install, simply tried some ping and seen that it
works.

> What does `mii-tool -v' tell you about your internal interface, as root?


I did this after a transfer of a 4 mb file between 1 win pc and the linux
one

[root@pc root]# mii-tool -v
eth0: negotiated 100baseTx-FD, link ok
product info: vendor 00:00:00, model 0 rev 0
basic mode: autonegotiation enabled
basic status: autonegotiation complete, link ok
capabilities: 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD
advertising: 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD
link partner: 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD flow-control

> What does `ifconfig' tell you about the (internal) interface on your
> linux box? In particular, I want to see the error counters, so don't
> discard them.


[root@pc root]# ifconfig
eth0 Link encap:Ethernet HWaddr 00:08:A1:56:7E:C8
inet addr:192.168.100.110 Bcast:192.168.100.255
Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:9599 errors:1371 dropped:0 overruns:0 frame:0
TX packets:10195 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:7669166 (7.3 Mb) TX bytes:1528860 (1.4 Mb)
Interrupt:11 Base address:0xf000

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:3338 errors:0 dropped:0 overruns:0 frame:0
TX packets:3338 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:2441740 (2.3 Mb) TX bytes:2441740 (2.3 Mb)


Reply With Quote
  #5 (permalink)  
Old 06-11-2004
Cameron Kerr
 
Posts: n/a
Default Re: Samba damn slow

Rasta99 <rasta99@libero.it> wrote:

>> How fast can you transfer data using other means, such as FTP (which
>> isn't ideal,

>
> I tried with a prog in win (blazeftp) but when but the linux one
> refuses the connection, do i have to setup something on it or start
> any service? I suppose there is no need to tell i'm a linux newbie :)


You need to install and enable an FTP server (temporarily, you should
remove it after the experiment is completed)

>> you've only got 1 linux machine, which limits your testing tools)

>
> I could install another fedora in dual boot on 1 of the win pc if this
> could help.


More linux will definately help, but I recommend having a copy of
Knoppix on hand. I've even remastered my own version, with some very
interesting little network utilities on it.

> [root@pc root]# ifconfig
> eth0 Link encap:Ethernet HWaddr 00:08:A1:56:7E:C8


> RX packets:9599 errors:1371 dropped:0 overruns:0 frame:0


The `errors' counters here is worrying. If you do a file transfer in one
window, run the following command and tell me if you see this counter
increasing as the file is transfered. The errors are also the reason as
to why it's going so slowly, because the dropped packets will cause
the sending and recieving TCP to slow to a crawl as they timeout and
need to retransmit.

watch -n 1 /sbin/ifconfig eth0

If it does, then you can try to either

1) Connect to the switch using a different cable.

2) Connect to a different machine using a crossover cable.

3) Connect to the switch using a different network card.

--
Cameron Kerr
cameron.kerr@paradise.net.nz : http://nzgeeks.org/cameron/
Empowered by Perl!
Reply With Quote
  #6 (permalink)  
Old 06-11-2004
Rasta99
 
Posts: n/a
Default Re: Samba damn slow

This is really weird...
Found the problem, it was the cable.
You could not belive me but i tried a UTP cable and it works great, 0 error.
This is the cable i used with win and i had to change it when i upgraded the
lan to 100 mbps because win dind't want to work at that speed with that
cable and i took one STP cat5. Now with linux it's the opposite, don't work
with STP cat5 and work with a UTP, maybe it's the nic (is a Averynet with a
RTL8139 chip) but now is all ok.
Thanks a lot Cameron for your help.


Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 07:00 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0