ERROR: JETTY_HOME not set

6,515

Solution 1

This is a rather frustrating error with little help out there. I thought I'd post my solution here for someone who is looking to solve the same problem.

Anyway, the correct solution is to set JETTY_HOME in /etc/default/jetty like so:

 JETTY_HOME=/opt/jetty

Hope this helps someone.

Solution 2

Here's a pointer in the right direction: JETTY_HOME refers to an environment variable set with a value corresponding to the directory path where you have installed jetty.

https://stackoverflow.com/questions/2655641/set-environment-variable-in-ubuntu

Share:
6,515

Related videos on Youtube

uvijay
Author by

uvijay

Updated on September 18, 2022

Comments

  • uvijay
    uvijay almost 2 years

    I have tried installing Jetty server on my Ubuntu 12.04 following this steps. But when I start my server I get the following error,

    service jetty start ** ERROR: JETTY_HOME not set, you need to set it or install in a standard location

    • MadHatter
      MadHatter over 10 years
      Have you considered doing exactly that?
    • uvijay
      uvijay over 10 years
      Yes I tried doing the same by adding in /etc/environment but ended up with the same error. As far as I searched JETTY doesn't need the variable to be set explicitly and is set by Jetty's start mechanism. (start.jar)
    • Abdull
      Abdull over 10 years
  • uvijay
    uvijay over 10 years
    I am new to linux after years of using window and hence having some difficulties. I followed this tutorial to install Jetty link step by step and was getting the mentioned error. I did google and I did try setting the environment variable explicitly but wasnt working. Thanks.