由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Linux版 - 24 processes reading one file
相关主题
还是webcam的问题问一下mmap怎么读的文件啊?
关于library preloadlinux怎么读入一个超过有超过1B integer的binary file? (转载)
为啥用mmap访问文件的效率高呢?possible to crash if I copy a file to multiple folders at the same time?
问一个跟 memory (process address space) 的有关的问题CPU温度很高 (转载)
Google go 还挺不错的ubuntu的oxygen-gtk crash问题还没解决...
glibc和kernel的兼容性问题求助本版牛人
请教个文件权限的问题help!分区问题
mmap question大家firefox升级到3.5了吗,听说速度快了不少
相关话题的讨论汇总
话题: file话题: 24话题: processes话题: 100mb话题: reading
进入Linux版参与讨论
1 (共1页)
b****o
发帖数: 387
1
I have a 12 physical core, 24 virtual cores.
If I start a job with 24 process reading the same file (small file 100MB),
will this be problematic? I found the cpus are basically 0.5% for loading;
I do not know why this was triggered.
a9
发帖数: 21638
2
IO永远是最慢的。

loading;

【在 b****o 的大作中提到】
: I have a 12 physical core, 24 virtual cores.
: If I start a job with 24 process reading the same file (small file 100MB),
: will this be problematic? I found the cpus are basically 0.5% for loading;
: I do not know why this was triggered.

n*****n
发帖数: 5277
3
this is not a cpu intensive problem
Q*********r
发帖数: 69
4
given the small file size, you could preload the file in cache (cat file > /
dev/null) before staring the job, and the job might actually run faster ...

loading;

【在 b****o 的大作中提到】
: I have a 12 physical core, 24 virtual cores.
: If I start a job with 24 process reading the same file (small file 100MB),
: will this be problematic? I found the cpus are basically 0.5% for loading;
: I do not know why this was triggered.

b****o
发帖数: 387
5
I actually used /run/shm, and the speed, however, did not change.
If I load one process to read the 100MB, it only takes seconds; if I invoke
24 process, it takes 10 mins.
Yes, I/O is the slowest one, but 80*100MB = 8GB is not too intensive. I
am not sure if /dev/null is helpful. Is it simply
cat $file > /dev/null; myjob
?
Q*********r
发帖数: 69
6
/dev/null is just for throwing away the prefetched data, cat does the
caching.
One possible reason that it runs slower with 24 processes is that all the
processes are causing out-of-order reads, which in turn would cause
unnecessary seeks, and seeks are slow ...

invoke

【在 b****o 的大作中提到】
: I actually used /run/shm, and the speed, however, did not change.
: If I load one process to read the 100MB, it only takes seconds; if I invoke
: 24 process, it takes 10 mins.
: Yes, I/O is the slowest one, but 80*100MB = 8GB is not too intensive. I
: am not sure if /dev/null is helpful. Is it simply
: cat $file > /dev/null; myjob
: ?

l*********s
发帖数: 5409
7
if it is cached, seeking should not be a concern.

【在 Q*********r 的大作中提到】
: /dev/null is just for throwing away the prefetched data, cat does the
: caching.
: One possible reason that it runs slower with 24 processes is that all the
: processes are causing out-of-order reads, which in turn would cause
: unnecessary seeks, and seeks are slow ...
:
: invoke

Q*********r
发帖数: 69
8
that is exactly why I suggested catting the file. was trying to explain what
might be happening without the prefetching ...

【在 l*********s 的大作中提到】
: if it is cached, seeking should not be a concern.
l*********s
发帖数: 5409
9
but lz already used shm, io does not seem to be the bottleneck.

what

【在 Q*********r 的大作中提到】
: that is exactly why I suggested catting the file. was trying to explain what
: might be happening without the prefetching ...

l*********s
发帖数: 5409
10
80 times? which does the number come from?

invoke

【在 b****o 的大作中提到】
: I actually used /run/shm, and the speed, however, did not change.
: If I load one process to read the 100MB, it only takes seconds; if I invoke
: 24 process, it takes 10 mins.
: Yes, I/O is the slowest one, but 80*100MB = 8GB is not too intensive. I
: am not sure if /dev/null is helpful. Is it simply
: cat $file > /dev/null; myjob
: ?

S*A
发帖数: 7142
11
try to mmap the 100M file in your 24 process and read
it using mmaped pointer. That way, there is no memcpy
from kernel to user space buffer.
10 minutes sounds too slow. What happen if you strace
one of the process? Where does it spend most of the time
on?
1 (共1页)
进入Linux版参与讨论
相关主题
大家firefox升级到3.5了吗,听说速度快了不少Google go 还挺不错的
Intel To Challenge Android With Moblin For Mobile Devicesglibc和kernel的兼容性问题
python descriptor 问题请教个文件权限的问题
关于signal handlermmap question
还是webcam的问题问一下mmap怎么读的文件啊?
关于library preloadlinux怎么读入一个超过有超过1B integer的binary file? (转载)
为啥用mmap访问文件的效率高呢?possible to crash if I copy a file to multiple folders at the same time?
问一个跟 memory (process address space) 的有关的问题CPU温度很高 (转载)
相关话题的讨论汇总
话题: file话题: 24话题: processes话题: 100mb话题: reading