Re: 5000 Folders in a directory

2016-02-19 Thread tomas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, Feb 18, 2016 at 07:05:03PM +0100, Jean-Baptiste Thomas wrote: > > *samueloph@teste:~/foo$ time ( for i in $(seq 0 ) ; do touch $i ; done > > )real0m10.245suser0m3.332ssys0m1.576s* > > Using shell built-in ">" to create 1

Re: 5000 Folders in a directory

2016-02-18 Thread Don Armstrong
On Thu, 18 Feb 2016, SamuelOPH wrote: > I'm not really sure how could I adapt your command to use '>' instead of > touch, but shouldn't '>' be faster if using 3 processes too? seq 0 | xargs touch; creates three processes, but only one process is doing the touching. % time dash -c 'for i in

Re: 5000 Folders in a directory

2016-02-18 Thread SamuelOPH
I'm not really sure how could I adapt your command to use '>' instead of touch, but shouldn't '>' be faster if using 3 processes too? I mean, comparing one single execution of touch with ">", ">" is faster. Thanks for the answer people, Tomas is right about the touch process. Samuel Henrique O.

Re: 5000 Folders in a directory

2016-02-18 Thread Jean-Baptiste Thomas
> *samueloph@teste:~/foo$ time ( for i in $(seq 0 ) ; do touch $i ; done > )real0m10.245suser0m3.332ssys0m1.576s* > Using shell built-in ">" to create 1 files: ​> > *samueloph@teste:~/foo$ time ( for i in $(seq 0 ) ; do > $i ; done > )real0m0.742suser0m0.064ssys

Re: 5000 Folders in a directory

2016-02-18 Thread Jonathan Dowland
On Wed, Feb 17, 2016 at 08:13:23PM +0100, Chris wrote: > Would it be better to use "real" subfolders with / as separator? I prefer to do so, not so much for when imapd is reading/writing to them, but for when I am poking about myself. "ls" etc. are going to be painful with that many sub-folders.

Re: 5000 Folders in a directory

2016-02-18 Thread tomas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, Feb 18, 2016 at 12:12:50PM -0200, SamuelOPH wrote: > Sorry about forgetting to reply to the list. No worries :-) > I don't understand why touch is the right thing, it doesn't create > directories either, just files. It creates empty files

Re: 5000 Folders in a directory

2016-02-18 Thread SamuelOPH
​​ ​Sorry about forgetting to reply to the list.​ I don't understand why touch is the right thing, it doesn't create directories either, just files. Care to explain why did you chose touch instead of ">"? ​ ​Using the external binary touch to create 1 files: ​ *samueloph@teste:~/foo$ time

Re: 5000 Folders in a directory

2016-02-18 Thread tomas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, Feb 18, 2016 at 06:54:33AM -0200, SamuelOPH wrote: > 2016-02-17 19:01 GMT-02:00 : > > > tomas@rasputin:~/foo$ time ( for i in $(seq 0 4999) ; do touch $i ; done ) > > > I know its offtopic, but please don't use touch when

Re: 5000 Folders in a directory

2016-02-18 Thread tomas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Wed, Feb 17, 2016 at 02:03:25PM -0800, David Christensen wrote: > On 02/17/2016 11:13 AM, Chris wrote: > >is it possible to save 5000 folders in the same directory (ext4 FS) > >without any performance issues? > > > &

Re: 5000 Folders in a directory

2016-02-17 Thread David Christensen
On 02/17/2016 11:13 AM, Chris wrote: is it possible to save 5000 folders in the same directory (ext4 FS) without any performance issues? It's a Maildir structure with a .-separator, e.g. /var/vmail/public/folder1 /var/vmail/public/folder1.subfolder1a /var/vmail/public/folder1.subfolder1b

Re: 5000 Folders in a directory

2016-02-17 Thread tomas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Wed, Feb 17, 2016 at 08:13:23PM +0100, Chris wrote: > Dear All, > > is it possible to save 5000 folders in the same directory (ext4 FS) > without any performance issues? I think ext3/ext4 should take that without problems. This is o

Re: 5000 Folders in a directory

2016-02-17 Thread rlharris
On Wed, February 17, 2016 1:13 pm, Chris wrote: > is it possible to save 5000 folders in the same directory (ext4 FS) > without any performance issues? > > It's a Maildir structure with a .-separator, e.g. > > /var/vmail/public/folder1 > /var/vmail/public/folder1.subfolder1