Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug
Bug#: 103024
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Java team <java@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: James Le Cuirot <chewi@aura-online.co.uk>
Add CC:
CC:
Remove selected CCs
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
conf.d_hsqldb.diff conf.d_hsqldb.diff patch Wiktor Wandachowicz 2005-11-06 03:42 0000 630 bytes Details | Diff
hsqldb-1.7.3.1-r1.ebuild.patch hsqldb-1.7.3.1-r1.ebuild.patch patch Wiktor Wandachowicz 2005-11-12 04:35 0000 610 bytes Details | Diff
Create a New Attachment (proposed patch, testcase, etc.) View All

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

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


Not eligible to see or edit group visibility for this bug.






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


Description:   Opened: 2005-08-18 17:58 0000
There is a line in /etc/conf.d/hsqldb that reads JAVA_EXECUTABLE=$(which java). 
This fails because java is not in root's path and the error appears every time 
depscan.sh runs. It should be JAVA_EXECUTABLE=$(java-config -J) though I'm not 
sure if the line is even needed at all since this env is not used in /etc/init.
d/hsqldb but neither are any of the other envs for that matter.

------- Comment #1 From Petteri Räty 2005-08-18 23:13:14 0000 -------
In here the problem is that /usr is not mounted when the depscan.sh is run. I
already told this problem to axxo so he is also aware of this. I suggested we
put /usr/bin/java in there with the new setup but for some reason he did not
like it. The other possibility is to evaluate to command later in
/etc/init.d/hsqldb.

------- Comment #2 From James Le Cuirot 2005-08-19 04:06:03 0000 -------
Oh sorry, what I said wasn't quite right was it? It was very late when I made 
this bug and I somehow totally managed to forget what the point of "which" was.
 :P

------- Comment #3 From Thomas Matthijs (RETIRED) 2005-09-11 05:14:04 0000 -------
fixed

------- Comment #4 From Wiktor Wandachowicz 2005-11-06 03:40:12 0000 -------
Hmmm. Even though this bug is marked RESOLVED FIXED, I still got the same
problem.

Yesterday I've emerged hsqldb-1.7.3.1-r1 and while starting it from root's
console via "/etc/init.d/hsqldb start" was okay, the server never came up after
doing "rc-update add hsqldb default" and reboot. Instead it only displayed:

 * Starting HSQL Database ...
Config file '/etc/conf.d/hsqldb' does not set one or more of following
variables
    JAVA_EXECUTABLE, HSQLDB_JAR_PATH, SERVER_HOME                          
[!!]

I've done a small investigation and came up with (probably) suboptimal
solution.
I modified the /etc/conf.d/hsqldb script in order to make sure that the correct
'java' executable is present in PATH environment variable.

However, I think this should be attacked in a different way (even though I have
a solution which works for me).

------- Comment #5 From Wiktor Wandachowicz 2005-11-06 03:42:56 0000 -------
Created an attachment (id=72276) [details]
conf.d_hsqldb.diff

A small and very Gentoo-specific addition to the /etc/conf.d/hsqldb
to make sure that 'java' executable is present in PATH variable.

------- Comment #6 From Petteri Räty 2005-11-11 14:17:56 0000 -------
Sir No: Are you using one of the latest baselayouts? Maybe this has something
to
do with the fact that it restricts the stuff that gets to the init script
environment.

------- Comment #7 From Wiktor Wandachowicz 2005-11-11 14:27:01 0000 -------
(In reply to comment #6)
> Sir No: Are you using one of the latest baselayouts? Maybe this has something
> to do with the fact that it restricts the stuff that gets to the init script
> environment.

I'm not sure. For me it's:

# equery list baselayout
[ Searching for package 'baselayout' in all categories among: ]
 * installed packages
[I--] [  ] sys-apps/baselayout-1.11.13-r1 (0)

and I run mostly x86 packages, unless I have no other choice.

------- Comment #8 From Petteri Räty 2005-11-11 14:49:21 0000 -------
Have you tried running env-update?

------- Comment #9 From Wiktor Wandachowicz 2005-11-12 04:30:54 0000 -------
Ok, let's forget about that. There is a simple workaround for everybody
interested:

In /etc/conf.d/hsqldb the line
JAVA_EXECUTABLE=$(which java 2>/dev/null)

should be changed to:
JAVA_EXECUTABLE=$(java-config --java 2>/dev/null)

Even better is to patch the original hsqldb-1.7.3.1-r1.ebuild to prevent
the problem completely. Patch follows.

------- Comment #10 From Wiktor Wandachowicz 2005-11-12 04:35:11 0000 -------
Created an attachment (id=72734) [details]
hsqldb-1.7.3.1-r1.ebuild.patch

A patch to change '$(which java)' to '$(java-config --java)' in the
hsqldb-1.7.3.1-r1.ebuild file.

BTW. $(which java) is wrong, because at the time the hsqldb service starts
the /usr directory might not be mounted. So, using $(java-config --java)
is the preferred way to get the full path to the 'java' executable.

Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug