First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 144640
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Television related Applications in Gentoo's Portage <media-tv@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Richard Freeman <rich0@gentoo.org>
Add CC:
CC:
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 144640 depends on: Show dependency tree
Show dependency graph
Bug 144640 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)







View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2006-08-21 06:46 0000
The mythbackend init.d script sets HOME, but does not export it.  If HOME is
not exported when calling /etc/init.d/mythbackend, the service will not start.

As a result, mythbackend cannot be started by monit (daemon-monitoring
application) - monit exports only a very minimal environment when calling init
scripts.

Fix is just to add "export" to the start of the line HOME=/etc/mythtv .

------- Comment #1 From Doug Goldstein 2006-09-29 07:48:35 0000 -------
This is still a WORKSFORME. Unless you provide some more details and info
behind this.

------- Comment #2 From Richard Freeman 2006-09-29 08:09:17 0000 -------
(In reply to comment #1)
> This is still a WORKSFORME. Unless you provide some more details and info
> behind this.
> 

Still?  Hadn't seen any previous bugs on this - I figured this was a new issue.

Simple way to reproduce (run as root):

/etc/init.d/mythbackend stop
unset HOME
/etc/init.d/mythbackend start

mythbackend will fail to start.

Sure, running interactively people won't be unsetting home, but if monit or
another automated package tries to run the init.d script without having a HOME
exported it will not work.  It doesn't matter what HOME is set to since the
init.d script changes it - it just has to be already exported for it to work.

If a variable is in the environment then changing it in bash changes it in the
environment.  If the variable is not already exported then setting it makes it
a bash variable and not an environment variable.

In any case, I don't see any harm arising from making the export explicit.

------- Comment #3 From Doug Goldstein 2006-10-05 19:41:51 0000 -------
Fixed.

First Last Prev Next    No search results available      Search page      Enter new bug