You are not logged in.

#1 2011-11-29 22:49:18

Donki
Member
Registered: 2008-09-01
Posts: 6

File system on a file - Torrent Daemon

Wow... It's been a while...

I want to run a torrent service out of a Samba share. It's going to be designed for 3 or so people using it at the same time. Here is my idea for the design:

Connect to the samba share and there is a directory called "Add Torrents Here" or something similar. People will drop torrents there, and rtorrent will start its magic. When the torrent is done, it will move the file(s) to another folder called "Finished Torrents". I want to have a quota for the torrent share, so I've decided that creating a FS on a file would be my best choice. I've decided on this plan of attack for several reasons: I don't have any free partitions on my HDDs. A pre-allocated FS on a file will reduce fragmentation, and it will only allow me to fill up my HDD with so many torrents before people need to delete/move them elsewhere.

Has anyone done something similar to this? If so, please add more in-depth pros/cons.

Where would one place this "torrent.fs" file? Namely, where in the FHS would this fall under, just to make sure I'm sticking to convention?

Example:

[root@server /]# dd bs=1G count=15 if=/dev/zero of=torrent.fs
(Finishes up)
[root@server /]# mkfs.xfs torrent.fs
[root@server /]# mount torrent.fs /srv/torrents

Offline

#2 2011-12-08 14:24:34

rwd
Member
Registered: 2009-02-08
Posts: 671

Re: File system on a file - Torrent Daemon

Donki wrote:

I don't have any free partitions on my HDDs

Can't you create more logical partitions, or use lvm? For going the file-as-blockdevice route I think you need to mount with "mount -o loop torrent.fs /srv/torrents" .

Last edited by rwd (2011-12-08 14:25:07)

Offline

#3 2011-12-08 16:00:20

djgera
Developer
From: Buenos Aires - Argentina
Registered: 2008-12-24
Posts: 723
Website

Re: File system on a file - Torrent Daemon

if you are using ext4 or xfs replace dd with:

fallocate -l 15G

see fallocate(1) for more info.

@rwd: -o loop is not needed since long time ago.

Offline

Board footer

Powered by FluxBB