Rpi Softwares

= Dynamic DNS =

The objective is to access Raspberry Pi from Internet using Dynamic DNS service. Most of the ISPs in India (& other third world countries) provide Dynamic IP address due to shortage of IP addresses.

Using this tutorial you will be able to access your device(or any other Linux machine) through Internet. You will have a registered unique sub-domain name which will be pointing to the current IP address assigned to the device.


 * Requirements:
 * Raspberry Pi(or any other Linux machine; for windows machine you need to download a different client)
 * ISP which provides Dynamic IP address.
 * DDClient,inadyn, etc or any other free Dynamic DNS Client.
 * Need to register at FreeDNS (free)


 * Note:
 * If you ISP provides a static IP, then you can directly access device using IP address or can use any DNS service(e.g: FreeDNS) for mapping IP to domain name. there is no need of installing client in Raspberry Pi.
 * If your ISP provides a private IP address (e.g. 10.103.85.131), then following this tutorial will not help.


 * Configuration:

http://freedns.afraid.org/dynamic/update.php?[xxxxxxxxxxxxxxxxxxxxxx] sudo apt-get install ddclient sudo nano /etc/ddclient.conf
 * Log on to SignUp page and register for a new unique sub-domain name (e.g: network.info.tm).
 * Open Dynamic DNS page. Copy the large alpha-numeric key in "Direct URL" link. e.g:
 * Install & Configure DDClient

daemon=3600 use=if, if=eth0                       ##comment out this line & use below line if Interface is not having Public IP directly assigned #use=web, web=checkip.dyndns.com/, web-skip='IP Address' server=freedns.afraid.org protocol=freedns login=xxxxxxxx password=xxxxxxxx xxxxxxxx.com                             ##replace with your domain name

sudo service ddclient restart

= WiringPi =

Source

Installation: git clone git://git.drogon.net/wiringPi cd wiringPi git pull origin ./build

Verify: gpio -v gpio readall

= Tonido =

Installation:

sudo mkdir /usr/local/tonido cd /usr/local/tonido sudo wget http://patch.codelathe.com/tonido/live/installer/armv6l-rpi/tonido.tar.gz sudo tar-zxvf tonido.tar.gz ./tonido.sh start

Audio Playback for FLAC, M4A etc:

cd /usr/local/tonido sudo apt-get install ffmpeg sudo ln -s /usr/bin/ffmpeg ffmpeg.exe sudo ln -s /usr/bin/ffmpeg ffmpegv.exe

Auto Start at Bootup:

sudo wget --output-document=tonido http://www.tonido.com/support/download/attachments/9109990/tonido?version=2&modificationDate=1412274854000&api=v2 sudo cp tonido /etc/init.d/ sudo chmod +x /etc/init.d/tonido sudo update-rc.d tonido defaults

= Transmission =

Please follow Automount USB Drive for mounting USB during bootup else Transmission will give error for temp files not found.

Installation: sudo apt-get install transmission-daemon sudo /etc/init.d/transmission-daemon stop sudo nano /etc/transmission-daemon/settings.json

Change “rpc-authentication-required” to false

"rpc-password": "password", "rpc-username": "username", "rpc-whitelist-enabled": false, "download-dir": "/mnt/USBDrive", "download-queue-size": 5, "incomplete-dir": "/mnt/USBDrive", "incomplete-dir-enabled": true, "seed-queue-size": 10, "watch-dir": "/mnt/USBDrive", "watch-dir-enabled": true, "umask": 2,

sudo nano /etc/init.d/transmission-daemon Change the USER=transmission-daemon to USER=root sudo service transmission-daemon reload

Transmission will be available at following link now: http://192.168.1.6:9091/transmission/web/

OSMC
sudo systemctl stop transmission sudo nano /home/osmc/.config/transmission-daemon/settings.json sudo systemctl start transmission

= Deluge =

Source: [howtogeek.com]

Installation: sudo apt-get install deluged sudo apt-get install python-mako sudo apt-get install deluge-web

Run deluge-web once deluge-web

Configure Web(to change port if required): sudo pkill deluge-web nano ~/.config/deluge/web.conf

Auto Start at boot up: sudo nano /etc/default/deluge-daemon
 * 1) Configuration for /etc/init.d/deluge-daemon

DELUGED_USER="pi"            # !!!CHANGE THIS!!!!
 * 1) The init.d script will only run if this variable non-empty.

RUN_AT_STARTUP="YES"
 * 1) Should we run at startup?

Change the user if required: DELUGED_USER="pi" # !!!CHANGE THIS!!!!

sudo chmod 755 /etc/default/deluge-daemon

sudo wget -O /etc/init.d/deluge-daemon http://cdn3.howtogeek.com/wp-content/uploads/gg/up/sshot5151aa042ad11.txt sudo chmod 755 /etc/init.d/deluge-daemon sudo update-rc.d deluge-daemon defaults

Now reboot the Pi & open the WebUI to see if everything is running fine: http:/192.168.1.6:8112

= Amule = Installation: sudo apt-get install amule-daemon sudo apt-get install amule-utils-gui

Copy the md5 of the password: echo -n "password" | md5sum

Run amuled once amuled

Edit the Config file: nano ~/.aMule/amule.conf

TempDir=/media/aman32/Temp IncomingDir=/media/aman32/Incoming

AcceptExternalConnections=1 ECPassword = md5 value of On Password ECPort = 4712

Below [WebServer]: Enabled=1 Password= md5 value of On Password Port=4711

Create Addresses file: nano addresses.dat http://www.emule.com/server.met

Auto Start: sudo nano /etc/default/amule-daemon AMULED_USER = "pi"

Reboot: sudo reboot

= FTP Server =

sudo apt-get install vsftpd sudo nano /etc/vsftpd.conf

uncomment the following options: local_enable=YES write_enable=YES

In case of errors replace the contents of conf file with below contents:

listen=YES local_enable=YES write_enable=YES local_umask=022 dirmessage_enable=YES use_localtime=YES xferlog_enable=YES secure_chroot_dir=/var/run/vsftpd/empty pam_service_name=vsftpd rsa_cert_file=/etc/ssl/private/vsftpd.pem max_per_ip=0                                //By default connection limit is set to 50, you can remove this limitation by setting it to 0

Restart the Service sudo service vsftpd restart

Now you should be able to login with any local user credentails.

Use Filezille to upload files & verify: tail /var/log/vsftpd.log

= TFTP Server =

sudo apt-get install tftpd-hpa

tftpd-hpa look for ipv6 and wont start without it. Add -4 or –ipv4 between the quotes on the TFTP_OPTIONS line in the file

sudo nano /etc/default/tftpd-hpa

TFTP_USERNAME=”tftp” TFTP_DIRECTORY=”/srv/tftp” TFTP_ADDRESS=”0.0.0.0:69″ TFTP_OPTIONS=”–secure”

sudo chmod -R 777 /srv/tftp sudo service tftpd-hpa restart sudo service –status-all

= JDownloader =

Source: steven-england.info


 * If you are in a SSH connection, change into a desktop session based terminal before starting JDownloader.
 * JDownloader needs features of an active LXDE environment, it won’t work as a headless service.

mkdir ~/jdownloader2 cd jdownloader2

wget http://installer.jdownloader.org/JDownloader.jar java -jar /home/pi/jdownloader2/JDownloader.jar

nano /home/pi/jdownloader2/startjd2.sh
 * Create startup script

java -jar /home/pi/jdownloader2/JDownloader.jar
 * 1) !/bin/sh

Make it executable: chmod 755 /home/pi/jdownloader2/startjd2.sh

nano ~/.config/lxsession/LXDE-pi/autostart Paste this line into the file: @/home/pi/jdownloader2/startjd2.sh
 * Autostart

sudo apt-get install lxshortcut                     ## Install lxshortcut if it is not already installed by default lxshortcut -o /home/pi/Desktop/JDownloader.desktop
 * If you want a desktop icon:

nano JDownloader.desktop Add below line to the file: Categories=Utility Move the file to applications folder: cp JDownloader.desktop ~/.local/share/applications/
 * To create a Menu item:

= Tor = Install Tor: sudo apt-get install tor

Edit torrc file: sudo nano /etc/tor/torrc SocksPort 9050 SocksPort 192.168.1.35:9050 SocksPolicy accept 127.0.0.1/32 SocksPolicy accept 192.168.1.0/24 SocksPolicy reject * Log notice file /var/log/tor/notices.log RunAsDaemon 1

Create log file: sudo touch /var/log/tor/notices.log sudo chmod 666 /var/log/tor/notices.log

Enable Autostart: sudo update-rc.d tor enable

Reboot & Verify Installation netstat -an | grep 9050 ps -aux | grep tor

Jdownloader with Tor Proxy
Goto Connection Manager, add a proxy for: Socks5 Proxy -> 127.0.0.1 -> 9050 -> Whitelist -> rapidshare.*(domain names)

= Node-Red =

Source: nodered.org

Upgrading existing installation: bash <(curl -sL https://raw.githubusercontent.com/node-red/linux-installers/master/deb/update-nodejs-and-nodered)

Start the application: node-red-start

Access the Web-UI: http://192.168.1.20:1880

Install Dashboard npm i node-red-dashboard

= Pyload =

Install Dependancies: sudo apt-get update sudo apt-get install python-support python-crypto python-pycurl tesseract-ocr tesseract-ocr-eng python-imaging python-qt4 -y

Download Package wget https://github.com/pyload/pyload/releases/download/v0.4.9/pyload_0.4.9_all.deb

Install Package: sudo dpkg -i pyload_0.4.9_all.deb sudo apt --fix-broken install

For downloading from storage sites with click-n-load install Rhino javascript engine: sudo apt-get install rhino -y

Add/Edit user pyLoadCore -u

Initial Config pyLoadCore -s

Test process: sudo pyLoadCore

Start process: /etc/init.d/pyload start

Enable Autostart: sudo update-rc.d pyload defaults

Access the GUI: http://192.168.1.20:8000

= Resilio Sync =

Source: resilio.com

Download the ARM Package from below URL: https://www.resilio.com/individuals/ https://download-cdn.resilio.com/stable/linux-arm/resilio-sync_arm.tar.gz

Extract the Binary file, make it executable & test: ./rslsync --webui.listen 0.0.0.0:8888

Enable autostart on reboot: sudo nano /etc/rc.local

Add below before "exit 0": /home/pi/rslsync --webui.listen 0.0.0.0:8888

Reboot sudo reboot

= AirDCPP on Rpi Zero W (Armv6) =

Install Tools: sudo apt-get install gcc g++ git cmake python pkg-config git npm

Install libraries: sudo apt install pkg-config libbz2-dev zlib1g-dev libssl-dev libstdc++6 libminiupnpc-dev libnatpmp-dev libtbb-dev libmaxminddb-dev libboost1.58-dev libboost-regex1.58 libboost-thread1.58 libboost-system1.58 libleveldb-dev libwebsocketpp-dev

Clone the Repository: git clone https://github.com/airdcpp-web/airdcpp-webclient.git cd airdcpp-webclient

Compile the binary: cmake. make -j1     # j1 for 1 CPU core in Rpi ZeroW

= EiskaltDC++ =

sudo apt-get install eiskaltdcpp eiskaltdcpp-daemon mkdir /home/pi/.config/eiskaltdc++/Logs touch /home/pi/.config/eiskaltdc++/Logs/daemon.log eiskaltdcpp-daemon -L 0.0.0.0 -d
 * Install Daemon:

cd ~ git clone https://github.com/eiskaltdcpp/eiskaltdcpp-web sudo mv eiskaltdcpp-web /usr/share/ cd /usr/share/eiskaltdcpp-web/
 * Install Simple WebUI:

sudo nano config.js "host" : "192.168.0.132",    # IP address of remote computer where eiskaltdcpp-daemon is launched

Install Apache Server sudo apt install apache2 cd /etc/apache2/conf-enabled/ cd sites-enabled/ nano 000-default.conf

Listen 80  DocumentRoot /usr/share/eiskaltdcpp-web/ 

sudo systemctl restart apache2

Test the WebUI: http://192.168.0.35/


 * Icecult WebUI:

Run the daemon once and kill it: eiskaltdcpp-daemon

Edit the Config File: nano ~/.config/eiskaltdc++/DCPlusPlus.xml

Edit Favorites file for auto connect: nano ~/.config/eiskaltdc++/Favorites.xml

Download the Icecult Files: git clone https://github.com/kraiz/icecult.git

Install Nginx Server: sudo apt install nginx

To serve the webinterface and proxy the jsonrpc interface and replace sudo nano /etc/nginx/site-enabled/default

With below config: server { root /home/pi/icecult/app; location /rpc { rewrite /rpc/(.*) /$1 break; proxy_http_version 1.1; proxy_pass http://127.0.0.1:3121; } }

Restart the Rpi: sudo reboot

Test the WebUI: http://192.168.0.35/

= Emulate Rpi with Docker =

Source: github.com

Install Docker: sudo apt install docker docker.io

Run the container: sudo docker run -it lukechilds/dockerpi

Boot a local Raspbian image: sudo docker run -it -v /home/aman/filesystem.img:/sdcard/filesystem.img lukechilds/dockerpi

Download a much slimmer VM only Docker container that doesn't contain the Raspbian filesystem image: sudo docker run -it -v /home/aman/filesystem.img:/sdcard/filesystem.img lukechilds/dockerpi:vm

Also add storage: sudo docker run -it -v /home/aman/filesystem.img:/sdcard/filesystem.img -v /tmp:/sdcard2 lukechilds/dockerpi:vm