WhereToStoreDownloadingFiles

From MLDonkey
Jump to: navigation, search

Depending on what you want, you should consider where you put your files.

Contents

Clean directory structure

If you want to keep your files ordered you may want to add an extra shared directory with subdirectories.

Example:

incoming/
~MyStuff/~Demos/
~MyStuff/~Wallpapers/
~MyStuff/~MyPictures/

you need to share this directory either with the command:

[[share]] 0 \"~MyStuff\"

Please also check that the \"default_sharing_strategy\" is set to \"all_files\" in downloads.ini to insure that the subdirectories are shared as well.

Alternatively you can edit downloads.ini and adding this to the shared_directories section between the ~[[]] brackets:

  {     dirname = \"~MyStuff\"
     networks = [[]]
     strategy = all_files
     priority = 0
};

You can then move the files into these subdirectories, issue a \"reshare\" command so mldonkey knows they moved.

This way you can keep order and the files will still be available to the network.

_/snard4321_


Speed priority

Download files directly to a fat32 partition

Reiserfs and ext3 don't really create 700MB files if you start a new download so if you download many files at the same time they get fragmented a lot. I could store my movies only with 4x to a CD because the HD was so fragmented with reiserfs that it was too slow for my faster CD-writer (48x)

_-- Since 2.02-10, MLdonkey allocates disk space by full chunks to lower fragmentation. /Pango_

Space priority

Download files to an ext3 partition

_e.g._ If you use mldonkey on a separate box (e.g. your router) with limited space available, you can start files w/o having the complete space available yet and transfer your completed files via network to your workstation / burning box to make room on your 'download box'.
On a 10MBit network the loss in speed doesn't matter.

Both Speed and Space

mount a bsd file system (ffs) wich is practically immune to fragmentation, if you have that option. a good idea is to use the softdep flag.

stats from my openbsd mldonkey disk:

bash# fsck -fv /dev/raid2a
start /dev/raid2a wait fsck_ffs -f /dev/rraid2a
...
'''''' Last Mounted on /export/site/incoming
...
63 files, 14840505 used, 1153407 free (39 frags, 144171 blocks, 0.0% fragmentation)


ps. if someone like to try mounting ffs on linux have a look at this thread: http://cwrulug.cwru.edu/archive/cwrulug/200002/0197.html and please report back. don't have linux myself, i'm afraid.

_-- Another option which is included in linux out of the box is to download to an XFS formatted partition. XFS is very fast, is included in recent kernels and provides a defragmentation tool called xfs_fsr which works online, so you don't have to umount the partition prior to defragmentation. You could start xfs_fsr by cron at morning time and the behaviour of xfs_fsr is quite cron friendly. Debian includes xfs_fsr in the xfsdump package. Of course this is not as elegant as ffs in respect to fragmentation, but it is a stable and well know fs on linux. /boligrafo_

idea:

use the file_completed_cmd option (a command that is called when a file is completely downloaded. Arguments are: <file_name on disk> <md4-hash> <size>), to launch a script that moves completed <file_name on disk> to another partition, such as a FAT32 partition. Just moving it should be enough to loose the fragmentation. anybody?

_Good idea, but having temp and incoming directories on separate filesystems should be enough. The only known drawback is that commiting will take some time, and MLdonkey will block until it's finished... /Pango_

_...which means you should \"./configure --enable-pthread=-pthread\" before compiling. See CompilationProblems for details._

_As far as I know that file copying is not threaded, did you check your information ?_

I used to simply run a cronjob that copied the files * from one folder to another. Worked fine and is simple.

One good idea, in case you have more than one hard disk, is to have the temp directory in one disk and the incoming (or anywhere else you move your completed files to) in the other one, that way the copy is much faster and (in my opinion) is better for the hard disk too.

See also:

Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox