View Single Post
  #192  
Old 06.03.2015, 22:40
zoddel zoddel is offline
Super Loader
 
Join Date: Mar 2015
Posts: 25
Default

Install JDownloader 2 on your NAS (in 10 little steps)
1. Create a Download-Folder where JDownloader should download to
2. Create a JDownloader-User at ur NAS for JDownloader and allow r/w for your Download-Folder
3. Create a Home-Folder for the User or let your NAS manage it
4. Download JDownloader.jar (http://installer.jdownloader.org/JDownloader.jar ) and copy to "/volume1/@appstore/jdownloader/" (shell command cp)
5. Change Directory (shell command cd) to "/volume1/@appstore/jdownloader/" and install JDownloader (java -jar JDownloader.jar) -> at the end of the installation it will ask for your my.jdownloader.org login (if not start ur JDownloader the first time with the parameter "-norestart", it will ask for them after first start)
6. Set your JDownloader-User as owner of "/volume1/@appstore/jdownloader/" (chown -R JDownloader: /volume1/@appstore/jdownloader)
7.0 Edit the file "/etc/passwd" with vi (shell command vi /etc/passwd) -> google "vi Editor Commands" so you know how to use it
7.1 If your NAS dont manage the Home-Folder set it for your JDownloader-User
7.2 Change "/sbin/nologin" to "/bin/sh" for your JDownloader-User
8. Create a file called "S99jdownloader.sh" at ur NAS and insert the following Script
Code:
#!/bin/sh 
# 
# Startup script for jdownloader2 
# 
# Stop myself if running 
# 
start() { 
nohup su -c "/volume1/@appstore/JavaManager/Java/bin/java -Djava.awt.headless=true -jar /volume1/@appstore/jdownloader/JDownloader.jar &" JDownloader
} 
# 
stop() { 
PIDFILE=/volume1/@appstore/jdownloader/JDownloader.pid
[ -f ${PIDFILE} ] && kill `cat ${PIDFILE}`  
} 
# 
case "$1" in 
start) 
start 
;; 
stop) 
stop 
;; 
restart) 
stop 
sleep 30
start 
;; 
*) 
echo "Usage: $0 (start|stop|restart)" 
exit 1 
;; 
esac 
# End
9. Copy "S99jdownloader.sh" to "/usr/local/etc/rc.d/"
10. Restart your NAS. JDownloader should start now automatically

Thx alot to Jiaz who was a very big help answering my questions so i was able to figure out how to install JDownloader 2 on my NAS !

ToDos:
- JDownloader shows an Update in WebUI. When i click on "update and restart" JDownloader restarts, but it still tells me that there is an update . . .
After restarting the NAS the update is done, i will have an eye on that behaviour =)
(DONE: NO PROBLEM, new update, 1 press at web-ui, update done =))

Last edited by zoddel; 09.03.2015 at 21:58.
Reply With Quote