June 15, 201214 yr Looks to me that a default installation makes uTorrent download to /tmp as default. How can I change this? Will the internal interface within uTorrent relate directly to the local paths for my unRaid server? There is no option within uTorrent to specify path for temporary storage (as I've found). Will it be a problem to use this with a 2GB USB drive when downloading several torrens that can be more than 4GB in size each? Am I missing something? /M
June 15, 201214 yr if it downloads to /tmp then your USB drive wouldn't be the issue, it would be your ram filling up, and that could definitely cause problems!
June 15, 201214 yr A couple potential issues from looking at the PLG again: 1. The way you write the utconfig.conf, if you don't "search" for the appropriate line and replace it, either one of two things would happen(with the way you currently have it coded), it would either append the new config options to the end of the .conf(every time you enable the plugin) or it would overwrite the .conf, which would erase all your other settings. 2. You are still giving the user the option for a Data_dir but not passing it to anything, if you write that to the utconfig.conf, it would alleviate the problem that klunde noticed. You could ask for the data_dir, then write two different lines to the utconfig.conf, the DIR_ACTIVE and DIR_COMPLETED options. For both you could append to the variable... So, if I set the Data_dir as /mnt/cache/.apps/utserver, you could write: DIR_ACTIVE:"$Data_dir/temp/" DIR_COMPLETED:"$Data_dir/completed/" Default for all downloads is "/", which we wouldn't want for unraid, and if a unsuspecting or novice user installed the plug-in, they'd have a hell of a time trying to figure out why their server crashed every time they downloaded something, not to mention what they downloaded is lost when they reboot, I'll take a look at some of these changes as soon as I can, my son broke his arm yesterday and my daughter has a ear infection, so concentration isn't my strong suit right now!
June 16, 201214 yr Author Hi guys. I am sorry for the delay, I had some things to do at home... utserver.conf file is actually only needed to change the web access port from default 8080 which would interfere with UnMenu. utserver settings are kept in settings.dat in utserver installation directory. Default login information is admin with no password. After first run you need to create data directory manually and configure it from uTorrent web interface (if dirs don't exist, or utserver doesn't have read/write access to it, it will change it back to blank. Temp dir would be the one labaled "put your new downloads in:" Data dir is not yet implemented correctly, it will be in newer releases (dirs specified in utserver.conf as Influencer mentioned). I noticed there is new WebUI included in latest release of utserver. I don't like it very much (I cannot set labels for some reason). If anybody has the previous version of webui.zip, please PM me. I was thinking about including update feature in the plugin, but I haven't yet figure out how to implement it (how to check for latest version of the installation file on utorrent website). If anybody has an idea I'd appreciate it. Thanks.
June 17, 201214 yr To check for the latest version you could always do it the down and dirty way: wget http://www.utorrent.com/downloads/linux newver="$(cat linux | grep maindownloadtitle | awk -F'[()]' '{print $2}')" rm linux That currently prints "3.0 build 27079" You'd have to re-write parts of your plugin to make them dynamic, since right now your download links are all hardcoded. This would probably be hard to do until they release another version so you can see if their naming structure will stay the same. As it is now it'd be kind of a pain, since the file name is utorrent-server-3.0-ubuntu-10.10-27079.tar.gz, throwing the ubuntu in there seems kind of pointless as they don't have a build for any other distro, if they would have named it "utorrent-server-3.0-27079.tar.gz" it would be much simpler.
June 17, 201214 yr Author To check for the latest version you could always do it the down and dirty way: wget http://www.utorrent.com/downloads/linux newver="$(cat linux | grep maindownloadtitle | awk -F'[()]' '{print $2}')" rm linux That currently prints "3.0 build 27079" You'd have to re-write parts of your plugin to make them dynamic, since right now your download links are all hardcoded. This would probably be hard to do until they release another version so you can see if their naming structure will stay the same. As it is now it'd be kind of a pain, since the file name is utorrent-server-3.0-ubuntu-10.10-27079.tar.gz, throwing the ubuntu in there seems kind of pointless as they don't have a build for any other distro, if they would have named it "utorrent-server-3.0-27079.tar.gz" it would be much simpler.[/code] To get download link I could use: DOWNLOAD_URL="$(cat linux | grep client-stable-linux-ut | awk -F"['']" '{print $4}')" That could work. I could refactor the code to make download link dynamic. There is still one problem - first time I wrote the plugin it worked fine for me but wouldn't for LMon. He mentined a typo in the directory name "utorrent-server-3_0", which I had as "utorrent-server-3.0". Now I can see what was the problem - they have changed the file since I wrote a plugin, and added new WebUI, also changed the directory name. How can I get the directory name after extracting the tar.gz file?
June 17, 201214 yr I'll need you to elaborate more in what you want... What dir name are you trying to get? Sent from my HTC Vivid
June 17, 201214 yr Author Sorry for not being clear. I mean the directory name created when extracting .tar.gz file.
June 18, 201214 yr Sorry, I haven't had any time to work on this. When I got the plugin originally, the dynamic installer download had been commented out and the current version had been hardcoded in. But the directory for the cp command did not match the one created by the tar command, nor the the one used for the rm command two lines later. I took a go at trying to make it not rely on filenames at all. It's probably not that elegant or efficient but I think it works (I tried it all manually, I'm not able to fully test it out at the moment) # Check for latest version # Change to temp directory cd /tmp # Retrieve download page to file "page" wget -q -O page http://www.utorrent.com/downloads/complete?os=lin&track=stable # Extract download URL and store in $stable stable=($(grep -o http://[^[:space:]]*.tar.gz page | head -1)) # Remove temporary file rm page # Create temporary directory to download and extract files in mkdir /tmp/utinstall cd /tmp/utinstall # Download utserver and untar curl -s $stable | tar -xz # Get directory that files have been untared to and copy to $INSTALLDIR cp -R `find /tmp/utinstall -name utserver -printf %h`/* $INSTALLDIR chown -R $RUNAS:users "$INSTALLDIR" # Remove temporary files rm -R /tmp/utinstall
June 18, 201214 yr That looks like it'd work fine, and solves p4xels issue of finding the directory name
June 18, 201214 yr P4xel, I use the webui found here. I think it's a bit better than the default, but still not as good as the native windows interface. Importantly for me, it allows you to assign labels and use rss feeds.
June 18, 201214 yr Author Good job LMon. If you have some spare time, which I lack at the moment, could you also add and test data_dir variable to utserver.conf to avoid confusion for new users. #Temporary download location: DIR_ACTIVE:"$Data_dir/.temp/ #Move completed jobs to: DIR_COMPLETED:"$Data_dir/completed/ The reason I commented out dynamic download is that it wouldn't work most of the times (2 out fo 3) so I hardcoded the url. Meanwhile they have changed the dir name in .tar.gz file hence the errors you mentioned (that mush have been the moment they changed WebUI but the actual utserver version, build and download url remained unchanged). Thanks for WebUI link by the way. This is exactly what I was looking for. It looks like enhanced version of older original UI. The new one is a bug disappointment thou. EDIT: I updated the plugin already. Check the first post. Thanks for all suggestions. p4xel.
June 23, 201214 yr why is this install script copying my Pictures share to the app_cache install directory?
June 23, 201214 yr yep.. my paths are: /mnt/user/Pictures /mnt/user/app_cache/utserver why does that matter? or rather, why is it going to try and copy all 130GB before starting the app so i can disable or change such settings?
June 23, 201214 yr update: it's copying my entire unraid system tree. renamed "Pictures" to "Images" and restarted the process, went through and copied the system folders and began to copy my "Music" share. http://cl.ly/1H0r192s1e2r1O3K3g1H
June 23, 201214 yr Author it must be a glitch with this line # Get directory that files have been untared to and copy to $INSTALLDIR cp -R `find /tmp/utinstall -name utserver -printf %h`/* $INSTALLDIR What directories have you set up in settings page for utserver? EDIT: Strange... I tested it again on my box and everything seems to be fine. Show me what is in your /tmp/utinstall
June 23, 201214 yr update: it's copying my entire unraid system tree. renamed "Pictures" to "Images" and restarted the process, went through and copied the system folders and began to copy my "Music" share. http://cl.ly/1H0r192s1e2r1O3K3g1H Same happened to me, but recursively. There was my whole / in the utserver folder, one level below again and so on..
June 23, 201214 yr Author It appears to be more serious than I thought. I need to rewrite the installation part to be safer in case of unexpected behaviour.
June 23, 201214 yr it must be a glitch with this line # Get directory that files have been untared to and copy to $INSTALLDIR cp -R `find /tmp/utinstall -name utserver -printf %h`/* $INSTALLDIR What directories have you set up in settings page for utserver? EDIT: Strange... I tested it again on my box and everything seems to be fine. Show me what is in your /tmp/utinstall sorry - it wouldn't stop copying media so i blasted the plugin and restarted the server. i'll happily test again when you're ready.
June 25, 201214 yr installed new plugin, no longer attempts to copy everything in my array. I enable the plugin with my custom install directories and they are successfully created, but the utserver first-run download/install fails with the following error: http://cl.ly/2m3M2i0J2j1w2C1M0X1M
June 25, 201214 yr Author that error is invoced when script cannot locate extracted utserver. what are your custom dirs, show me contents of /tmp/utinstall and installation dir.
June 25, 201214 yr gotcha http://cl.ly/3U2m2o1e282j2C153I1Y /tmp/utinstall is empty. /mnt/user/app_cache/utserver just has "utserver.conf" file.
June 25, 201214 yr Author Looks like the script failed to download at all. What version unRaid are you using?
June 25, 201214 yr 5.0 rc3. I'm running the latest Sabnzbd and Subsonic plugins, and older version of Twonky all with the same /mnt/user/app_cache setup and no issues. I'm in the process of resetting permissions from Root to Nobody, will reboot the server and try again after that, just to be sure.
Archived
This topic is now archived and is closed to further replies.