Quantcast
Channel: StudioSysAdmins Message Board
Viewing all articles
Browse latest Browse all 3749

Windows 7 - linux samba performance

$
0
0
Windows 7 - linux samba performance
posted by Michal Krupa on March 25, 2014, 10:37 a.m.

Hi. I've bumped a serious issue with windows 7 and samba sharing performance. I'm using this samba share to keep all my plugins and python modules.

Unfortunately I'm right now facing the problem, that all the modules are loading muuuuch slower than from the local hard drive. Whe accessing the same modules from linux they're loading only slightly slower then from the local hard drive.

I've made a smal test in python:

 

 

########################################################

import datetime
import time
import os

def fopen_raport(test_path, calls):
    times = []
    result = ""
    
    for i in range(calls):
        times.append( datetime.datetime.now() )
        f = open(test_path, "r")
        f.close()
    
    result += "Tested location: {0}\n".format( test_path)
    result +=  "Number of operation: {0}\n".format( calls)
    result +=  "First call time: {0}\n".format(str(times[0]))
    result +=  "Last call time: {0}\n".format(str(times[-1]))

    return result


locations = ["PATH_TO_ANY_EXISTING_FILE_ON_LOCAL_OR_SAMBA_SHARE"]

for location in locations:
    print fopen_raport(location, 2000)

 

####################################################

 

It opens the file for reading 2000 times and measures the time of .

For me the results were:

windows - local file ("C:\test.txt") about .1s

linux - local file ("/tmp/test.txt") about .01s

windows - samba share ("\\server\share\test.txt") about 10s (!!!)

linux - samba share ("\\server\share\test.txt") about 1s

 

Has anyone faced similiar problem with windows 7 access to samba shares?

Thread Tags:
  samba, linux, windows 

0 Responses   0 Plus One's   0 Comments  
 

Hi. I've bumped a serious issue with windows 7 and samba sharing performance. I'm using this samba share to keep all my plugins and python modules.

Unfortunately I'm right now facing the problem, that all the modules are loading muuuuch slower than from the local hard drive. Whe accessing the same modules from linux they're loading only slightly slower then from the local hard drive.

I've made a smal test in python:

 

 

########################################################

import datetime
import time
import os

def fopen_raport(test_path, calls):
    times = []
    result = ""
    
    for i in range(calls):
        times.append( datetime.datetime.now() )
        f = open(test_path, "r")
        f.close()
    
    result += "Tested location: {0}\n".format( test_path)
    result +=  "Number of operation: {0}\n".format( calls)
    result +=  "First call time: {0}\n".format(str(times[0]))
    result +=  "Last call time: {0}\n".format(str(times[-1]))

    return result


locations = ["PATH_TO_ANY_EXISTING_FILE_ON_LOCAL_OR_SAMBA_SHARE"]

for location in locations:
    print fopen_raport(location, 2000)

 

####################################################

 

It opens the file for reading 2000 times and measures the time of .

For me the results were:

windows - local file ("C:\test.txt") about .1s

linux - local file ("/tmp/test.txt") about .01s

windows - samba share ("\\server\share\test.txt") about 10s (!!!)

linux - samba share ("\\server\share\test.txt") about 1s

 

Has anyone faced similiar problem with windows 7 access to samba shares?


Viewing all articles
Browse latest Browse all 3749

Trending Articles