<!-- 
RSS generated by JIRA (8.20.10#820010-sha1:ace47f9899e9ee25d7157d59aa17ab06aee30d3d) at Wed Feb 07 19:55:46 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>OpenDaylight JIRA</title>
    <link>https://jira.opendaylight.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>8.20.10</version>
        <build-number>820010</build-number>
        <build-date>22-06-2022</build-date>
    </build-info>


<item>
            <title>[CONTROLLER-1525] Can&apos;t start karaf using symbolic link</title>
                <link>https://jira.opendaylight.org/browse/CONTROLLER-1525</link>
                <project id="10113" key="CONTROLLER">controller</project>
                    <description>&lt;p&gt;When using symbolic link, e.g. &lt;/p&gt;

&lt;p&gt;root@foo:/usr/bin# ls -ls karaf &lt;br/&gt;
   1 lrwxrwxrwx   1 root     root          27 Jun  2 15:42 karaf -&amp;gt; /opt/opendaylight/bin/karaf&lt;/p&gt;

&lt;p&gt;karaf fail to start because of wrong DIRNAME, as DIRNAME is based on $0 being the path of the executed file.&lt;br/&gt;
So in this case, DIRENAME=usr/bin, which doesn&apos;t work.&lt;/p&gt;

&lt;p&gt;Karaf script is setting multiple env variable to be able to start correctly, and all of those variables are based on the KARAF_HOME, that is tied to the DIRNAME.&lt;/p&gt;</description>
                <environment>&lt;p&gt;Operating System: All&lt;br/&gt;
Platform: All&lt;/p&gt;</environment>
        <key id="26079">CONTROLLER-1525</key>
            <summary>Can&apos;t start karaf using symbolic link</summary>
                <type id="10104" iconUrl="https://jira.opendaylight.org/secure/viewavatar?size=xsmall&amp;avatarId=10303&amp;avatarType=issuetype">Bug</type>
                                                <status id="5" iconUrl="https://jira.opendaylight.org/images/icons/statuses/resolved.png" description="A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.">Resolved</status>
                    <statusCategory id="3" key="done" colorName="green"/>
                                    <resolution id="10000">Done</resolution>
                                        <assignee username="-1">Unassigned</assignee>
                                    <reporter username="adetalhouet">Alexis de Talhou&#235;t</reporter>
                        <labels>
                    </labels>
                <created>Tue, 7 Jun 2016 23:08:34 +0000</created>
                <updated>Thu, 3 May 2018 14:50:11 +0000</updated>
                            <resolved>Mon, 1 Aug 2016 14:00:08 +0000</resolved>
                                    <version>Lithium</version>
                                                    <component>karaf</component>
                        <due></due>
                            <votes>0</votes>
                                    <watches>2</watches>
                                                                                                                <comments>
                            <comment id="51447" author="adetalhouet" created="Wed, 8 Jun 2016 13:15:07 +0000"  >&lt;p&gt;For Ubuntu (Linux vagrant 3.19.0-25-generic #26~14.04.1-Ubuntu SMP Fri Jul 24 21:16:20 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux)&lt;br/&gt;
this is the symbolic link&lt;br/&gt;
```vagrant@vagrant:~$ ls -l /usr/bin/karaf&lt;br/&gt;
lrwxrwxrwx 1 root root 60 Jun  8 13:08 /usr/bin/karaf -&amp;gt; /home/vagrant/distribution-karaf-0.3.4-Lithium-SR4/bin/karaf&lt;br/&gt;
```&lt;br/&gt;
When I use it, here is the result:&lt;br/&gt;
```vagrant@vagrant:~$ karaf&lt;br/&gt;
/usr/bin &amp;lt;&#8212; echo $DIRNAME&lt;br/&gt;
Error: Could not find or load main class org.apache.karaf.main.Main&lt;br/&gt;
```&lt;br/&gt;
When I use the target of the symbolic link&lt;br/&gt;
```vagrant@vagrant:~$ /home/vagrant/distribution-karaf-0.3.4-Lithium-SR4/bin/karaf&lt;br/&gt;
/home/vagrant/distribution-karaf-0.3.4-Lithium-SR4/bin &amp;lt;&#8212; echo $DIRNAME&lt;/p&gt;

&lt;p&gt;For OSX (Darwin inocybe.local 14.5.0 Darwin Kernel Version 14.5.0: Tue Sep  1 21:23:09 PDT 2015; root:xnu-2782.50.1~1/RELEASE_X86_64 x86_64)&lt;br/&gt;
this is the symbolic link&lt;br/&gt;
```adetalhouet@inocybe:~\&amp;gt; ls -l /usr/bin/karaf &lt;br/&gt;
lrwxr-xr-x  1 root  wheel    61B  8 Jun 09:01 /usr/bin/karaf@ -&amp;gt; /Users/adetalhouet/odl/unimgr/karaf/target/assembly/bin/karaf&lt;br/&gt;
```&lt;br/&gt;
When I use it, here is the result:&lt;br/&gt;
```adetalhouet@inocybe:~\&amp;gt; karaf&lt;br/&gt;
/usr/bin  &amp;lt;&#8212; echo $DIRNAME&lt;br/&gt;
Error: Could not find or load main class org.apache.karaf.main.Main&lt;br/&gt;
```&lt;br/&gt;
When I use the target of the symbolic link&lt;br/&gt;
```adetalhouet@inocybe:~\&amp;gt; /Users/adetalhouet/odl/unimgr/karaf/target/assembly/bin/karaf&lt;br/&gt;
/Users/adetalhouet/odl/unimgr/karaf/target/assembly/bin &amp;lt;&#8212; echo $DIRNAME&lt;/p&gt;</comment>
                            <comment id="51448" author="adetalhouet" created="Wed, 8 Jun 2016 13:28:57 +0000"  >&lt;p&gt;JIRA opened in Karaf project &lt;a href=&quot;https://issues.apache.org/jira/browse/KARAF-4564&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://issues.apache.org/jira/browse/KARAF-4564&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="51449" author="vorburger" created="Thu, 30 Jun 2016 09:46:57 +0000"  >&lt;p&gt;&lt;a href=&quot;https://issues.apache.org/jira/browse/KARAF-4599&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://issues.apache.org/jira/browse/KARAF-4599&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="51450" author="vorburger" created="Fri, 22 Jul 2016 15:04:19 +0000"  >&lt;p&gt;I&apos;ve just amended &lt;a href=&quot;https://git.opendaylight.org/gerrit/#/c/39982/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://git.opendaylight.org/gerrit/#/c/39982/&lt;/a&gt; with the solution proposed on &lt;a href=&quot;https://issues.apache.org/jira/browse/KARAF-4599&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://issues.apache.org/jira/browse/KARAF-4599&lt;/a&gt; (upstream is slow to react, so let&apos;s just apply this here, we&apos;ve anyway forked the Karaf scripts already, so we can continue to patch them).&lt;/p&gt;

&lt;p&gt;FTR: Alexis pointed out (on IRC) that his initial solution &lt;a href=&quot;https://git.opendaylight.org/gerrit/#/c/39982/2/karaf/opendaylight-karaf-resources/src/main/resources/bin/karaf&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://git.opendaylight.org/gerrit/#/c/39982/2/karaf/opendaylight-karaf-resources/src/main/resources/bin/karaf&lt;/a&gt; worked fine with both absolute and relative path.  But Karaf dev jbonofre then pointed out on &lt;a href=&quot;https://github.com/apache/karaf/pull/196&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://github.com/apache/karaf/pull/196&lt;/a&gt; that realpath as it&apos;s not available on most of Unix systems, so it was changed to readlink. That initially caused it to &quot;now only works when invoked from current directoy, no longer via absolute path&quot; (KARAF-4599).&lt;/p&gt;

&lt;p&gt;So with the latest patch set 10 in c/41305/ that&apos;s resolved too, so I think we&apos;ll have fixed this bug for good when &lt;a href=&quot;https://git.opendaylight.org/gerrit/#/c/39982/10/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://git.opendaylight.org/gerrit/#/c/39982/10/&lt;/a&gt; is merged.&lt;/p&gt;</comment>
                            <comment id="51451" author="adetalhouet" created="Mon, 1 Aug 2016 14:00:08 +0000"  >&lt;p&gt;beryllium --&amp;gt; &lt;a href=&quot;https://git.opendaylight.org/gerrit/#/c/42646/1&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://git.opendaylight.org/gerrit/#/c/42646/1&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                    <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                            <customfield id="customfield_11400" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                        <customfield id="customfield_10208" key="com.atlassian.jira.plugin.system.customfieldtypes:textfield">
                        <customfieldname>External issue ID</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>6027</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10201" key="com.atlassian.jira.plugin.system.customfieldtypes:url">
                        <customfieldname>External issue URL</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[https://bugs.opendaylight.org/show_bug.cgi?id=6027]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10000" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>0|i02r3z:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                </customfields>
    </item>
</channel>
</rss>