Get help, report and discuss bugs.
-
pitcritter
- Posts: 28
- Joined: 20 Jun 2014, 00:56
Post
by pitcritter » 11 Jul 2014, 00:20
Here's the log. What am I missing?
INFO 2014-07-10 19:36:06 Executing post-process-script nzbToMedia/DeleteSamples.py for The.Wire.S01E02.Th
e.Detail.HDRip.x264-NoNe
INFO 2014-07-10 19:36:06 DeleteSamples: env: can't execute 'python2': No such file or directory
ERROR 2014-07-10 19:36:06 Post-process-script nzbToMedia/DeleteSamples.py for The.Wire.S01E02.The.Detail.HDRip.x264-NoNe failed (terminated with unknown status)
INFO 2014-07-10 19:36:06 Executing post-process-script nzbToMedia/nzbToMedia.py for The.Wire.S01E02.The.Detail.HDRip.x264-NoNe
INFO 2014-07-10 19:36:06 nzbToMedia: env: can't execute 'python2': No such file or directory
ERROR 2014-07-10 19:36:06 Post-process-script nzbToMedia/nzbToMedia.py for The.Wire.S01E02.The.Detail.HDRip.x264-NoNe failed (terminated with unknown status)
INFO 2014-07-10 19:36:06 Executing post-process-script EMail.py for The.Wire.S01E02.The.Detail.HDRip.x264-NoNe
DETAIL 2014-07-10 19:36:07 EMail: Script successfully started
DETAIL 2014-07-10 19:36:07 EMail: Sending E-Mail
INFO 2014-07-10 19:36:09 Post-process-script EMail.py for The.Wire.S01E02.The.Detail.HDRip.x264-NoNe successful
INFO 2014-07-10 19:36:09 Executing post-process-script Logger.py for The.Wire.S01E02.The.Detail.HDRip.x264-NoNe
It looks like the first line in the scripts :
#!/usr/bin/env python2
has an issue, but it's beyond my extremely limited skillset.
I did look at EMail.py, which worked fine and the first line there is:
#!/usr/bin/env python
Is it as simple as changing python2 to python?
-
pitcritter
- Posts: 28
- Joined: 20 Jun 2014, 00:56
Post
by pitcritter » 11 Jul 2014, 02:29
OK, I might be getting somewhere.
I re-read the installation instructions and found this:
Sym-Link Python binaries.
Since many systems now include python3 as default, these scripts call /usr/bin/env python2 You system should have python2 existing in the path as a sym-link to python2.7 binary. If not, you will need to create a sym-link to this.
Find out where your python2.7 is which python2.7.
Create a sym-link python2 in the path (probably the same directory as your python2.7 and python executables.)
ln -sf /usr/bin/python2.7 /usr/bin/python2
I found python2.7 in /ffp/bin/
but when I run
ln -sf /ffp/bin/python2.7 /usr/bin/python2
I get:
ln: failed to create symbolic link '/usr/bin/python2': Read-only file system
Any help from here?
-
hugbug
- Developer & Admin
- Posts: 7645
- Joined: 09 Sep 2008, 11:58
- Location: Germany
Post
by hugbug » 11 Jul 2014, 07:16
The easiest is to change the hashbang line to:
The disadvantage of this method is that you need to change every pp-script. That's why it's better to configure the system to work for all scripts. System command "env" looks for executable passed as parameter (in your case it's "python") in the system search path which is set by environment variable "PATH". You can check how this variable is set by executing command
You'll get a list of paths where env looks for "python2". You can put the symlink in any of this directories. You can even put it into the directory where nzbget binary is located, then you should change the variable "PATH" to include this directory. This should be made before starting nzbget. Usually there is a start script for nzbget, that'll be the place to put the command which extends variable PATH:
Code: Select all
export PATH=$PATH:/path/to/python2
#starting nzbget
/path/to/nzbget -c /path/to/nzbget.conf
-
pitcritter
- Posts: 28
- Joined: 20 Jun 2014, 00:56
Post
by pitcritter » 11 Jul 2014, 12:46
hugbug wrote: Usually there is a start script for nzbget,
I use the version of nzbGet that comes as a built in package with my NSA325.
Therefore, the script which starts SB runs after nzbget has already started.
I'd love to modify the script to run nzbget instead of sab, but that is definitely beyond my abilities.
The built-in version is 11. I know that 12 is available, but Zyxel has not yet updated their packages to include it.
It looks like changing the hashbang may be the only decent solution for me, but that would mean that git updates would not work.
-
hugbug
- Developer & Admin
- Posts: 7645
- Joined: 09 Sep 2008, 11:58
- Location: Germany
Post
by hugbug » 11 Jul 2014, 13:25
Read this again:
System command "env" looks for executable passed as parameter (in your case it's "python") in the system search path which is set by environment variable "PATH". You can check how this variable is set by executing command
You'll get a list of paths where env looks for "python2". You can put the symlink in any of this directories.
If you check the PATH (from terminal) you'll probably find a directory that is not read only. Then put the symlink there.
-
pitcritter
- Posts: 28
- Joined: 20 Jun 2014, 00:56
Post
by pitcritter » 11 Jul 2014, 19:59
export PATH came back empty.
I ended up changing the hashbang. We'll see how that works.
I only use DeleteSamples.py and nzbToMedia.py, so it wasn't a big deal.
-
hugbug
- Developer & Admin
- Posts: 7645
- Joined: 09 Sep 2008, 11:58
- Location: Germany
Post
by hugbug » 11 Jul 2014, 20:13
pitcritter wrote:export PATH came back empty.
My mistake. Correct is:
-
pitcritter
- Posts: 28
- Joined: 20 Jun 2014, 00:56
Post
by pitcritter » 11 Jul 2014, 20:23
Even more entertaining...
root@NSA325:~# export $PATH
-sh: export: `/ffp/sbin:/usr/sbin:/sbin:/ffp/bin:/usr/bin:/bin': not a valid identifier
-
hugbug
- Developer & Admin
- Posts: 7645
- Joined: 09 Sep 2008, 11:58
- Location: Germany
Post
by hugbug » 11 Jul 2014, 20:25
I guess
would be better
But you've got the search path printed anyway. Can you write in any of these directories?
-
pitcritter
- Posts: 28
- Joined: 20 Jun 2014, 00:56
Post
by pitcritter » 11 Jul 2014, 20:37
I can write to /ffp/bin (maybe others too).
I created test.test with nano. It saved no problem. Then I tried what I assume the next step is:
root@NSA325:/ffp/bin# ln -sf /ffp/bin/python2.7 /usr/bin/python2
The system responds (again):
ln: failed to create symbolic link '/usr/bin/python2': Read-only file system
Is there an issue with my ln command?
Who is online
Users browsing this forum: No registered users and 41 guests