Skip to content

Instantly share code, notes, and snippets.

@anderZubi
Last active March 8, 2024 06:29
Show Gist options
  • Star 11 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save anderZubi/2612fab1abcdb4f2a9f7 to your computer and use it in GitHub Desktop.
Save anderZubi/2612fab1abcdb4f2a9f7 to your computer and use it in GitHub Desktop.
Script to install Transmission BitTorrent client in WD MyCloud NAS
#!/bin/bash
echo Backing up your sources.list...
cp /etc/apt/sources.list /etc/apt/sources.list.bak
echo Adding the sid repo to sources.list...
echo deb http://ftp.us.debian.org/debian/ sid main >> /etc/apt/sources.list
echo Updating the sid packages list...
apt-get update
echo Installing Transmission... - If asked to continue the installation, type Y and hit enter
apt-get -y install transmission-cli transmission-common transmission-daemon
echo Stopping Transmission so you can edit the settings.json file...
/etc/init.d/transmission-daemon stop
echo Setting Transmission to run as ROOT...
sed -i 's/USER=debian-transmission/USER=root /g' /etc/init.d/transmission-daemon
echo Disabling the dashboard login...
sed -i 's/"rpc-authentication-required": true,/"rpc-authentication-required": false,/g' /etc/transmission-daemon/settings.json
echo Disabling the RPC whitelist so you can access the Transmission GUI...
sed -i 's/"rpc-whitelist-enabled": true,/"rpc-whitelist-enabled": false,/g' /etc/transmission-daemon/settings.json
echo Moving back your original sources.list...
mv -f /etc/apt/sources.list.bak /etc/apt/sources.list
# OPTIONAL but recommended for those wishing to have access to the actual .torrent files easily from the DataVolume
echo Creating a folder called torrents in your Public folder...
rmdir /var/lib/transmission-daemon/info/torrents
ln -s /DataVolume/shares/Public/torrents /var/lib/transmission-daemon/info/torrents
########
echo Starting Transmission...
/etc/init.d/transmission-daemon start
echo -e "Transmission is installed and running\n"
echo For login to the Transmission GUI use
echo your mycloud IP or network name:9091
echo -e "For example: wdmycloud:9091\n"
echo Click the wrench icon on the bottom left to set location for downloads
echo In the Download To box enter /DataVolume/shares/Public/Transmission or any share on your MyCloud
@juliord
Copy link

juliord commented Sep 6, 2014

Hello,

I have a WD My Cloud 2T and I am trying to have Transmission Client installed, so I can download torrents remotely.

I tried to install it by using the script you posted and everything goes fine until close to the end. When it tries to load the daemon, it give the error: "transmission-daemon: error while loading shared libraries: libminiupnpc.so.10: ELF lead command alignment not page-aligned".

Do you have any idea on how I can solve it?

Thanks in advance,
Júlio

@Kriedi
Copy link

Kriedi commented Sep 25, 2014

Has anybody had any success using this script with MyCloud firmware version 4?

@leninkumark
Copy link

Nope. I got the same error as juliord.
Even I am looking for a reliable code to install transmission in WD 4TB NAS.
Found few sources in WD community. But none of them work

@tapio80
Copy link

tapio80 commented Oct 29, 2020

Should this work with MyCloud firmware version 5?

@umaryaqoob
Copy link

@tapio80, Any luck with getting Transmission for OS5? The official website states that its supported for this latest release but its unavailable on the official apps page

@tapio80
Copy link

tapio80 commented Oct 29, 2020

I have not yet try out this script for OS 5.
Official website states that it is coming later on to official apps.
Maybe at next firmware update. Same kind of message has been on WD's Community forum.

@umaryaqoob
Copy link

It was darn easy torrenting using this app. Wouldn't have updated to os5 if i knew wd info is crap

@BenquYamato
Copy link

this is nice bullshit, OS5 give nothing special and now on my WDEX2Ultra i lost all repos eg MC, transmission, all packages from https://wdcommunity.com/ doesn't work also :( any help with install this stuff on OS 5? please help ! sad WD My Cloud EX2 Ultra user ...

@jcisio
Copy link

jcisio commented Nov 16, 2020

I saw the update, I waited a few weeks so that it becomes stable, then... I did the upgrade. I should have done a research before. I just naively believe what they say that data and app would be reserved.

Lost 200 torrents. However, I saw a backup in /mnt/HD/HD_a2/.systemfile/OS3_Apps_Backup/Nas_Prog/Transmission FYI.

Edit: But still the new version is not suitable for my: it tightly coupled with the WD web UI, no remote possible. Edit settings.json to fix that (RPC by default listen on 127.0.0.1).

@plodd5
Copy link

plodd5 commented Nov 22, 2020

I saw the update, I waited a few weeks so that it becomes stable, then... I did the upgrade. I should have done a research before. I just naively believe what they say that data and app would be reserved.

Lost 200 torrents. However, I saw a backup in /mnt/HD/HD_a2/.systemfile/OS3_Apps_Backup/Nas_Prog/Transmission FYI.

Edit: But still the new version is not suitable for my: it tightly coupled with the WD web UI, no remote possible. Edit settings.json to fix that (RPC by default listen on 127.0.0.1).

Could you be more specific ? I have the same issue. What did you modify in settings.json ?

@umaryaqoob
Copy link

umaryaqoob commented Nov 22, 2020

Ssh to your device, use winscp its easier. Edit settings.json, set bindrcp ip to 0.0.0.0

@umaryaqoob
Copy link

To retain the changes turnoff transmission before edit and then re-enable it. This way the changes to settings will persist across reboots

@plodd5
Copy link

plodd5 commented Nov 23, 2020

Thanks for the quick answer. I edited settings.json but it seems that I still need to connect via WD web UI first to have access to transmission interface. I cannot connect directly to it anymore.

@jcisio
Copy link

jcisio commented Nov 23, 2020

Thanks for the quick answer. I edited settings.json but it seems that I still need to connect via WD web UI first to have access to transmission interface. I cannot connect directly to it anymore.

There are a few things to change.

  • Change rpc-bind-address to "0.0.0.0" so that it no longer listen only to 127.0.0.1 and we don't need the reverse proxy of the NAS
  • Change rpc-port to 9091 (I don't know why WD used 9092, I change back to 9091 which is the default one)
  • You can also change rpc-url back to /transmission/ which is the default value
  • Change rpc-whitelist to "192.168.1.*" to allow all host in that network to access to the web UI

I didn't make a backup before my modification (my bad!). I don't remember correctly all of them. But I think they are (please add a comment to confirm).

@plodd5
Copy link

plodd5 commented Nov 23, 2020

Wouhou thanks a lot it works !!!!

@Mohabmw
Copy link

Mohabmw commented May 24, 2021

On OS 5 you can install Transmission manually.
Transmission 1.15 tested and working. Download from
https://fox-exe.ru/WDMyCloud/WDMyCloud-Gen2/Apps-OS5/

@resetter
Copy link

Can we confirm this script works properly on a 1st Gen MyCloud (firmware v04.05.00-342)?
Have read reports of bricking and Im wary of trying it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment