WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Transmission  (Read 5290 times)

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #15 on: June 08, 2011, 01:58:54 AM »
Thank you once again Rich, this is now working perfectly.
it's loading all my scripts.

when I reboot it doesn't remember the root password I set. is there something im missing?

when I boot into tinycore I use the command "sudo passwd root" - is there a way for tinycore to remember the password I set?

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #16 on: June 08, 2011, 02:07:10 AM »

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #17 on: June 08, 2011, 03:14:53 AM »
oh oh, I got a problem.

looks like my auto login scripts arent working.

I noticed for a brief moment before tinycore loaded there was a CIFS error.

when the system loaded I noticed my script
"sudo mount -t cifs //192.168.0.10/media/BitTorrent /mnt/BitTorrent -o noperm,user=admin,pass=*****" didnt activate because it's not visible when I type mount"
however it works if I type it manually after the system has booted. something about the /opt/bootlocal.sh isnt doing this properly.
&
"sudo transmission-daemon -f" activated because when I type 'ps -a' I can see it there, but I cannot access the web ui. however if I kill that process and type "sudo transmission-daemon -f" after the system has booted it works.

it's as if both these commands wont work in the bootlocal.sh, but will work when the system has already booted - Rich got any ideas?

Offline tinypoodle

  • Hero Member
  • *****
  • Posts: 3857
Re: Transmission
« Reply #18 on: June 08, 2011, 04:01:27 AM »
/opt/bootlocal.sh is running as root (so avoid sudo).
"Software gets slower faster than hardware gets faster." Niklaus Wirth - A Plea for Lean Software (1995)

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #19 on: June 08, 2011, 06:54:33 AM »
removed everything from /opt/bootlocal.sh so that I can work out what is going on.
I have removed sudo and used the following commands

"/bin/mkdir /mnt/BitTorrent"
"/bin/mount -t cifs //192.168.0.10/media/BitTorrent /mnt/BitTorrent -o noperm,user=admin,pass=*****"
I read somewhere on the forum to try /bin/command, and for someone it worked, unfortunately if I can't get a simple mount to work in bootlocal.sh then I need to find another way.

both lines work when I type it in manually
mkdir works on boot
mount does not work on boot

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 10221
Re: Transmission
« Reply #20 on: June 08, 2011, 06:54:52 AM »
Likely your network is not yet up at that point. Add a sleep before those commands, or perhaps a ping loop.
The only barriers that can stop you are the ones you create yourself.

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #21 on: June 08, 2011, 06:55:27 AM »
I have also tried adding the commands to /opt/bootsync.sh (no difference)

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #22 on: June 08, 2011, 07:07:29 AM »
aha. you are correct.
I took a screenshot of the messages before it loaded tc and this is what I get.

mount error(101): Network is unreachable

I will try a sleep command.

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #23 on: June 08, 2011, 07:18:12 AM »
excellent, I added a sleep 10 at the start of /opt/bootlocal.sh

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #24 on: June 08, 2011, 07:55:45 AM »
ok, now that the mkdir and mount commands are working on /opt/bootlocal.sh
I need to get transmission-daemon working the same way.

when I put the command "transmission-daemon" into the /opt/bootlocal.sh it loads it because I can see it when I use the command ps -a
however this is the message I get when I try to access it via web


403: Forbidden

Unauthorized IP Address.

Either disable the IP address whitelist or add your address to it.

If you're editing settings.json, see the 'rpc-whitelist' and 'rpc-whitelist-enabled' entries.

If you're still using ACLs, use a whitelist instead. See the transmission-daemon manpage for details.


to fix this, I manually type "sudo kill ####" and then "transmission-daemon" this obviously defeats the purpose, however I do this so I know that the command is 100% working. what am I missing here?

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #25 on: June 08, 2011, 07:57:16 AM »
and yes, whitelist is false - it's a simple restarting of the daemon that fixes it, maybe if there was a way to start and stop and start again in the /opt/bootlocal.sh

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #26 on: June 09, 2011, 01:34:23 AM »
bump.

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 12077
Re: Transmission
« Reply #27 on: June 09, 2011, 02:36:48 AM »
What does "transmission-daemon --help" show?

The reason I ask is that some daemons can be stopped by a command line switch - i.e. "-k" for kill. If this were the case then you could start, stop and re-start the daemon from bootlocal.sh

Another option would be to delete /var/run/transmission-daemon/*pid, if such a file exists, which would have the effect of killing the daemon.

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #28 on: June 09, 2011, 04:36:46 PM »
Thanks Juanito

I will try this when I get home. I would like to think that I'm not the only one trying to start transmission from bootlocal.sh and having these issues.

Offline skeletonpass

  • WikiUser
  • *
  • Posts: 19
Re: Transmission
« Reply #29 on: June 10, 2011, 11:24:44 PM »
No luck, there is no option to kill transmission-daemon other than finding out what the process number is... hmm.. maybe if we made a script to find the number and kill it so it can reload. (this is all presuming that the daemon can run before the os completely boots.

I'm experienced in writing batch scripts in windows but I do not know how to convert this to linux.

on a windows box I can do this.
for /f "skip=3 tokens=1,2" %a in ('tasklist /FI "IMAGENAME eq transmission.exe"') do (tskill %a && start transmission.exe)

so far on a linux box I can do this.
ps -a | grep transmission-daemon