To share the files between computers around in a home network ( lan ) is somehow cumbersome most of the time. The wireless routers even with 802.11N capability that have the claims of 300Mbit. Anyway, if one has shares around the home network, the big files like ISO files or movie files are problematic to copy around the network.
Problem: Moving big files ( copying or replacing them ) taking too much time in local home network ,and also, it is very error prone. While you are coping the files, it will take too much time and a fair amount of times, it will fail and needs to be restarted.
Possible Solution:: Use a download manager. I could not find a suitable software to apply this solution. Only possible candidate is the “UltraCopier” for Ubuntu. However, it is a broken software at least for > 16.04
Possible Solution:: Use torrent network for copying files as a resistant way of implementing file copying with resume,restart..etc.
High Level Steps
- Install a torrent client for all the computers in local network.
- Create torrent files for the files to be copied.
- Create a tracker service
- Share the torrent file to destination
- Use the torrent client of the destination to download the file with torrent
Install a torrent client for all the computers in local network
In Ubuntu, “Transmission” is the default torrent software. It is well adequate.
apt install transmission
Create a Tracker Service
Tracker service required to announce torrent files to other computers.
- Install the “libowfat” library that opentracker depends.
git clone https://github.com/gebi/libowfat.git cd libowfat/ make && make install
- Install the opentracker
git clone git://erdgeist.org/opentracker
Edit the Makefile of the opentracker::
CC?=gcc # Linux flavour PREFIX?=/opt/diet LIBOWFAT_HEADERS=$(PREFIX)/include LIBOWFAT_LIBRARY=$(PREFIX)/lib BINDIR?=$(PREFIX)/bin
Install the opentracker
make && make install cd /opt/diet && mkdir conf cp opentracker.conf.sample /opt/diet/conf/opentracker.conf
Lets create the systemd scripts for the service.
vi /lib/systemd/system/opentracker.service :Create the content as below [Unit] Description=OpenTracker After=network.target [Service] User=pi Group=pi Type=Simple ExecStart=/opt/diet/bin/opentracker -f /opt/diet/conf/opentracker.conf ExecReload=/bin/kill -HUP $MAINPID WorkingDirectory=/opt/diet/ [Install] WantedBy=multi-user.target
Start the opentracker
systemctl enable opentracker.service systemctl start opentracker.service
Create Torrent File & Download from clients
Create the torrent file:: Open the Transmission –>Under File tab –> New
Source File :: The file that you want to share within network
Trackers:: Copy the opentracker server’s IP in the Trackers section.
Tracker Address:: http://<your opentracker server’s IP address>:<opentracker port number>/announce
Now, the torrent file is in Desktop as “<your file name>.torrent” And you can share the torrent file with other computers in the local network to download.Don’t forget the share the file from the computer that has the file with torrent client as seeding.