Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - robwoodward75

Pages: [1] 2 3 4
1
Developers / Re: Transmission torrent on LinuxMCE
« on: October 21, 2013, 04:17:09 pm »
Ahr!!  OK, cheers Mike, Thanks for the info.  I'll keep doing the manual re-set thing until I feel brave enough to update to 12.04 then!!  That  probably also explains why others were having problems, and J had to fix it, if I'd written and tested the initial package install on 10.04, and it's rolling out on 12.04!!

Rob.

2
Developers / Re: Transmission torrent on LinuxMCE
« on: October 21, 2013, 01:50:35 pm »
Hi J,

I've had a couple of updates now on the Web admin, and each one wipes out all of my transmission work?!  Should this not be part of the install now, or, have I missed the point?!!!  I was expecting at some point the transmission stuff to stop disappearing, or, is this only available in the Alpha / Beta testing of the new release?

Sorry mate, don't want to bug you about it too much, I know you're busy on more than just this "Nice to have"!!

3
Users / Re: problems with medibuntu?
« on: October 15, 2013, 03:11:02 pm »
Hi J,

I've been having the same for some time,  Just happened to run apt-get, and decided to do something about it when I found this post!!  I found this thread on Ubuntu Forums, which is talking about DNS issues.  I'll see about having a go at setting them, and report back!!

http://ubuntuforums.org/archive/index.php/t-1475399.html

4
Developers / Re: Transmission torrent on LinuxMCE
« on: September 26, 2013, 09:50:12 am »
I'll check these lines for proper syntax.  As I've indicated, I haven't done an install test on the package yet.

J.

I ran the following lines (substituting transmission user with test user) on my installation, all of which executed OK, so I believe the syntax on those lines are correct?!
Code: [Select]
mysql -e "GRANT SELECT, INSERT, UPDATE, DELETE ON transmission_links.* TO 'test'@'localhost' IDENTIFIED BY '';"
mysql -e "GRANT SELECT, INSERT, UPDATE, DELETE ON transmission_links.* TO 'test'@'127.0.0.1' IDENTIFIED BY '';"
mysql -e "GRANT SELECT, INSERT, UPDATE, DELETE ON transmission_links.* TO 'test'@'192.168.80.*' IDENTIFIED BY '';"

Could we do with someone on 10.04 testing it too, see if the issues are related only to 12.04, or if it's a generic issue?!

Thank you so much for doing the initial leg work!

You're welcome, but it was as much for myself as anyone else!!!  Save's me a lot of bother when upgrading to 12.04 when it's stable!!!  Just need to convince you LinuxMCE Gods of other tweaks I've made now to save me doing anything at all after the upgrade!!!!

Rob.

5
Developers / Re: Transmission torrent on LinuxMCE
« on: September 25, 2013, 12:17:08 pm »
Hi gbutters,

I'm still on 10.04, and haven't got any way of testing and developing for 12.04 at the moment, can anyone else help with what this error is, as I don't know what's changed between the two releases.

"Can't find any matching row in the user table" sounds like a MySQL error, but the first user based MySQL query in the post install script Jason has posted is on line 45, not line 1?!
Code: [Select]
mysql -e "GRANT SELECT, INSERT, UPDATE, DELETE ON transmission_links.* TO 'transmission'@'localhost' IDENTIFIED BY '';"
That aside, a quick google turned up that it is to do with the user table and privileges bit, which means the following lines may give issues:
Code: [Select]
mysql -e "GRANT SELECT, INSERT, UPDATE, DELETE ON transmission_links.* TO 'transmission'@'localhost' IDENTIFIED BY '';"
mysql -e "GRANT SELECT, INSERT, UPDATE, DELETE ON transmission_links.* TO 'transmission'@'127.0.0.1' IDENTIFIED BY '';"
mysql -e "GRANT SELECT, INSERT, UPDATE, DELETE ON transmission_links.* TO 'transmission'@'192.168.80.*' IDENTIFIED BY '';"

Only trouble is, I've no idea which one!!  You could try running each of these lines as root in a terminal to see which ones fails?! 

Have you got your Core set to static:192.168.80.1?  Just thinking aloud, if this is a test box, and I've unfortunately hard-coded in 192.168.80.*, then there's an opportunity to improve the script by grabbing the internal address from the machine and inserting that instead of assuming no-one will change it?!  Not sure this would cause a fail in the user grants however?!!

Sorry I can't be of more help?!

6
Developers / Re: Transmission torrent on LinuxMCE
« on: September 19, 2013, 11:16:34 am »
Hi Jason,

Sounds like you've done the work to include the transmission pages into the LinuxMCE, if only my "Add Software" section worked, I could add the "official" version in!!  (my "Add Software" is completely empty, so haven't been able to add anything from there since I built the damn thing!!)

Thanks for all your support and advice, I'll leave you in peace for a while before looking at the next steps for transmission integration!!  Though perhaps of making it separate transmission daemons per user?! (Modifying the user page to allow admin to permit / deny transmission daemons for each user)  So each user could only see their own downloads, and link whatever they wanted to wherever they wanted!!!!  I'll see how people get on with this first though!

Also had some thoughts on how to make the initial index.php of LinuxMCE's admin site a little easier to add new sections in, instead of keep adding lines like:

Code: [Select]
        case 'transmission-daemon':
                $output = new Template($dbADO);
                $output->setTemplateFileType('large');
                include_once('operations/others/transmissionDaemon.php');
                transmissionDaemon($output,$dbADO,$transmissionADO);
        break;

And having to get that put in through svn.  Put that section of code into the pluto_main database in a new field, and simply recall the contents of it if the menu selection is correct?!  Would make index.php a fair bit shorter too!!!  As above however, I'll leave you in peace for a while before trying to tackle anything like this!!

Cheers,
Rob.

7
Developers / Re: Transmission torrent on LinuxMCE
« on: September 02, 2013, 11:26:41 am »
Thanks Jason,

I've added a new revision of the installer to the ticket, on realising I'd forgotten to add the following lines:
Code: [Select]
a2enmod proxy
a2enmod proxy_http

Which would stop the https proxy redirect to internal http port 9091 from working properly.  May show up as an error on the Apache restart if you've tried already.  Sorry about that!

Rob.

8
Developers / Re: Transmission torrent on LinuxMCE
« on: August 30, 2013, 04:56:19 pm »
Hi Jason,

Stand down!!  Sanity and will-to-live has been restored!!  Asked a colleague of mine at work, Unix server guy, he managed to sort it out!!  Ticket is now updated with the package install script, which assumes the Web admin area is downloaded with an update from LinuxMCE, not part of the install.

There is also a final (....for the moment anyway!) update of the svn patch, and the settings script.

Let me know if the install script isn't quite what you expected / wanted!

9
Developers / Re: Transmission torrent on LinuxMCE
« on: August 29, 2013, 03:50:59 pm »
Hi J,

I have hit a brick wall on the install script, basically, I have reached the limit of my bash scripting knowledge / ability, and after spending the last day or so googling around to try to find out what I'm doing wrong, I'm still drawing a blank!  Any help would be very gratefully received!!

Here's the scenario!

This is the line I'm trying to push into the /etc/transmission-daemon/settings.json:
   "script-torrent-done-filename": "/usr/pluto/bin/transmission-settings.sh torrentComplete $TR_TORRENT_NAME",

using the following function (and public declared variable for the settings file location):
Code: [Select]
transmissionSettings="/etc/transmission-daemon/settings.json"

changeSetting()
{
        #create a back-up of the current settings file
        backup="_"`date '+%Y%m%d%k%M%S'`".bak"
        oldSetting=$(grep "\"$1\":" $transmissionSettings|awk -F\: '{print $2}'|sed -e 's|\,||g' -e 's|^ *||g' -e 's| *$||g')

        if [ `echo ${oldSetting:0:1}`=='"' ]
        then
                sed -i$backup 's|"'$1'": '$oldSetting',|"'$1'": "'$2'",|' $transmissionSettings
        else
                sed -i$backup 's|"'$1'": '$oldSetting',|"'$1'": '$2',|' $transmissionSettings
        fi

        echo $transmissionSettings$backup
}

triggered by the following command:
Code: [Select]
changeSetting "script-torrent-done-filename" "/usr/pluto/bin/transmission-settings.sh torrentComplete \$TR_TORRENT_NAME"
However..........
Everytime I run it, in the debug console I get the following output:
++ sed -i_20130829144312.bak 's|"script-torrent-done-filename": "",|"script-torrent-done-filename": "/usr/pluto/bin/transmission-settings.sh' torrentComplete '$TR_TORRENT_NAME",|' /etc/transmission-daemon/settings.json
sed: -e expression #1, char 110: unterminated `s' command


Notice the really annoying extra single quotes now appearing in the sed line, making bash think the sed instruction is over, before I've finished it!!!! >:(

Can anyone help me please?!?!?! This is literally the last line(s) in the installer, so is really frustrating me now!! >:( ???

10
Developers / Re: Transmission torrent on LinuxMCE
« on: August 28, 2013, 10:44:05 am »
Apologies all, been on holiday, and for some reason, no email notifications of your posts?!

I have updated the ticket with some new scripts and pages, including service management of transmission-daemon, the ability to change username and password, or disable login, and some way of connecting via SSL, which requires a mod to the Apache config (also on the ticket)

I'll try to go through the questions / statements you've added!!
Quote
Would you mind sharing your scripts?  I'd really appreciate it.  Feel free to add them to the ticket.
No problem, I added the following lines to the transmission-daemon settings.json, however, I use version 1.93, which does not support on complete scripts (I found this out later!) but reading the LinuxMCE Wiki, I believe it should work!!
Code: [Select]
   "script-torrent-done-enabled": true,
    "script-torrent-done-filename": "/usr/pluto/bin/MessageSend dcerouter -r 0 20 1 809 9 \"Transmission Torrent Download completed\n$TR_TORRENT_NAME\" 70 \"alert\" 182 \"30\" 251 \"??\"",

Quote
What is your level of transmission integration into lmce?
1.93 (The torrent site I use is quite strict on this, I had to roll it back from the updated one, apparently, they reckon higher versions give false stats?!  Not entirely sure myself, but it's a good site, and I don't want to be kicked off!!)

Quote
If you can fix up an install script that includes the edit to the config file then we can put a package together.
OK, I'll get to work on it now, I had posted a few comments on the ticket, but I guess here's better for chatting, the ticket is for updates and facts I guess!!

Thanks all for your interest!

UPDATE:
More humble apologies!  On reading the posts properly, realised you weren't actually talking to me on these!  Sorry Davegravy, hope I haven't stolen your thunder!

Further Update!:
For the install script, which I had previously created something at the beginning of this post, which includes the copying of the web pages from the location of the unpacked tar file, and the extra menu item addition in the  MCE database.  Excuse me for being a bit of a nube, but.... do I assume the copying of the web pages will be unnecessary, if it is incorperated, would I just need the apt-get install of transmission-daemon, the new database, /usr/pluto/bin script, settings.json changes and the update to apache and it's LinuxMCE-ssl update?

Sorry, I know you're busy with other stuff too, but I need some guidance to give you what you need to have a complete install.

11
Developers / Re: Transmission torrent on LinuxMCE
« on: August 02, 2013, 12:38:32 pm »
And that is why you're a LinuxMCE God, and I am but a mere mortal!!!

I will definitely need some help and guidance on setting that up, unless your statement was more of a offer to do, rather than an instruction to me?!!

Either way, I'm happy to do my part to include Transmission into LinuxMCE as hopefully a permanent feature, I make good use of it myself as it integrates well with Android, with the free Transmission Remote app allowing me to add, pause etc torrents from anywhere to be available when I get home (speed dependant obviously!).

I am aware that my pages are fairly selfish at the moment, written by me, for me!!  What I could do with is some fresh eyes, and other peoples perspectives on it to see how we can improve, add other features (i.e. I've put unrar in, but made no scope as yet for zip, tar etc etc)  Simply because, of the torrents I've downloaded, I've only come across rar files, mainly multi-part ones at that!!

I can see further scope myself when I have more time, i.e. to incorporate the /etc/transmission-daemon/settings.json file into the DB, and therefore a web page, and therefore controlling the settings as well as starting and stopping the service etc from there.

12
Developers / Re: Transmission torrent on LinuxMCE
« on: August 01, 2013, 05:01:27 pm »
All,

Ticket raised:
#1861

13
Developers / Re: Transmission torrent on LinuxMCE
« on: August 01, 2013, 01:23:23 pm »
Hi Davegravy,

Hope it doesn't end up to be disappointing then!  If you want to try it, with the previously posted transmission.patch, which should sort out the web stuff, and the attached transmission-settings.sh copied into /usr/pluto/bin/ and then finally, the following commands to set-up the database and add the transmission user:

Code: [Select]
DBName='transmission_links'

#Set up the database
mysql -e "CREATE DATABASE $DBName;"
mysql -e "CREATE TABLE Torrent_Links (Link_ID int NOT NULL AUTO_INCREMENT, Torrent_Location TEXT NOT NULL, Rar_File VARCHAR(250) NULL, Link_Location TEXT NOT NULL, Link_Name VARCHAR(100), Link_Type VARCHAR(10) NOT NULL, Link_Status VARCHAR(10) NULL, PRIMARY KEY (Link_ID));" $DBName

#Adding the user
mysql -e "CREATE USER 'transmission'@'localhost';"
mysql -e "CREATE USER 'transmission'@'127.0.0.1';"
mysql -e "GRANT SELECT, INSERT, UPDATE, DELETE ON transmission_links.* TO 'transmission'@'localhost';"
mysql -e "GRANT SELECT, INSERT, UPDATE, DELETE ON transmission_links.* TO 'transmission'@'127.0.0.1';"
mysql -e "FLUSH PRIVILEGES;"


#Add the new Menu Option
ParentID=`mysql -e "SELECT PK_PageSetup FROM PageSetup WHERE Description='Configuration';" pluto_main |tail -1`

if [ $ParentID -eq 0 ]
then
ParentID=174
fi

OrderNum=`mysql -e "SELECT MAX(OrderNum) + 10 FROM PageSetup WHERE FK_PageSetup_Parent=$ParentID;" pluto_main |tail -1`

#For Safety in case is doesn't correctly identify the outputs
if [ $OrderNum -eq 0 ]
then
OrderNum=999
fi

mysql -e "INSERT INTO PageSetup (FK_PageSetup_Parent, Website, OrderNum, Description, pageURL, showInTopMenu) VALUES ("$ParentID",1,"$OrderNum",'Transmission Daemon','index.php?section=transmission-daemon',1);"

Could do with one of the Guru's or Gods letting me know the preferred method for added these parts in?  Is it just on a track ticket, as I've done here, or is there another way?!

14
Developers / Re: Transmission torrent on LinuxMCE
« on: July 31, 2013, 02:35:00 pm »
Excellent, thank you, that's completed the patch for the web admin area (attached), but could you direct me to the correct place to get the /usr/pluto/bin scripts, as I have one to update that area too.

Also, how do I go about the database?  There's a new database added, which I do using the install script in the initial download, create the database, tables and a the new user to access this database?!

Sorry, lots of questions, and I've no idea how many people actually use this, or would even want it?!

Thanks.

15
Developers / Re: Transmission torrent on LinuxMCE
« on: July 31, 2013, 10:20:25 am »
I guess this is a lesson in read all the instructions before heading off inventing new things on the site then!

Right,

svn update:
Code: [Select]
At revision 27777
svn status:
Code: [Select]
?       lmce-admin/operations/others/transmissionEditLinks.php
?       lmce-admin/operations/others/transmissionValidatelinks.php
?       lmce-admin/operations/others/transmissionLink.php
?       lmce-admin/operations/others/transmissionDaemon.php
?       lmce-admin/operations/others/transmissionCreatelinks.php
?       lmce-admin/operations/others/transmissionCheckfilename.php
M       lmce-admin/include/config/database.inc.php
M       lmce-admin/include/config/globalconfig.inc.php
M       lmce-admin/index.php
?       lmce-admin/languages/en/transmissiondaemon.lang.php

svn diff:
Code: [Select]
Index: lmce-admin/include/config/database.inc.php
===================================================================
--- lmce-admin/include/config/database.inc.php  (revision 27777)
+++ lmce-admin/include/config/database.inc.php  (working copy)
@@ -26,6 +26,10 @@
   $securityADO = &ADONewConnection($dbPlutoSecurityType);
   $securityADO->NConnect($dbPlutoSecurityServer,urlencode($dbPlutoSecurityUser),urlencode($dbPlutoSecurityPass),urlencode($dbPlutoSecurityDatabase));

+       // TransmissionADO connection
+       $transmissionADO = &ADONewConnection($dbTransmissionType);
+       $transmissionADO->NConnect($dbTransmissionServer,urlencode($dbTransmissionUser),urlencode($dbTransmissionPass),urlencode($dbTransmissionDatabase));
+
   //for sqlite
   //$db = &ADONewConnection('sqlite');
   //$db->NConnect($GLOBALS['appRoot'].'sqlite.db'); # sqlite will create if does not exist
Index: lmce-admin/include/config/globalconfig.inc.php
===================================================================
--- lmce-admin/include/config/globalconfig.inc.php      (revision 27777)
+++ lmce-admin/include/config/globalconfig.inc.php      (working copy)
@@ -32,6 +32,13 @@
        $dbPlutoSecurityServer = $DB_HOST;
        $dbPlutoSecurityDatabase = "pluto_security";

+       // Transmission
+       $dbTransmissionType = "mysql";
+       $dbTransmissionUser = "transmission";
+       $dbTransmissionPass = "";
+       $dbTransmissionServer = $DB_HOST;
+       $dbTransmissionDatabase = "transmission_links";
+
 function LoadConfig($configFile,$configKey) {
        //LoadConfig()
        //Looks for the assigned value of $configKey within $configFile,
Index: lmce-admin/index.php
===================================================================
--- lmce-admin/index.php        (revision 27777)
+++ lmce-admin/index.php        (working copy)
@@ -1801,6 +1801,20 @@
            include_once('operations/deviceTemplate/commMethod.php');
            commMethod($output,$dbADO);
        break;
+       case 'transmission-daemon':
+               $output = new Template($dbADO);
+               $output->setTemplateFileType('large');
+           include_once('operations/others/transmissionDaemon.php');
+           transmissionDaemon($output,$dbADO,$transmissionADO);
+           //transmissionDaemon($output,$dbADO,"");
+       break;
+       case 'transmissionLink':
+               $output = new Template($dbADO);
+               $output->setTemplateFileType('small');
+           include_once('operations/others/transmissionLink.php');
+           transmissionLink($output,$dbADO,$transmissionADO);
+           //transmissionLink($output,$dbADO,"");
+       break;
        case 'upnpServer':
                $output = new Template($dbADO);
                $output->setTemplateFileType('large');


Which I'm a lot happier with, with the exception that I still don't understand how the new files are included, I can see all the mods to the existing files, but not the additional bits, despite svn status recognising they're in there?!

I've then copied the latest of each of the modified files back into my live web area, and all appears to be working OK.  So, of all the work done, the remaining new file, which is not in the web directory is:
/usr/pluto/bin/transmission-settings.sh

do I have to do a similar svn on that area?  if so, where is it, I did look last night, but couldn't find it easily!

Thanks again for all your help and guidance, with any luck I'll do this a bit better in future!!

Pages: [1] 2 3 4