OpenHAB still starts after uninstall

Hello,
i’ve a openHAB 2.5.1 installed on a Raspberry PI 3B using Raspbian and had openhab installed using the apt-get approach. Yesterday due to a fail of mine i’ve tried to update using openhabian-conf and realised that it seems to have a second instance installed. It was obvious because instead of my configuration from the /etc/openhab2/-folder it used some other config.

I now wanted to clean my machine and have removed all openhab2-packages installed using
apt-get purge openhab* and apt-get remove openhab2

After that i’ve checked then the folders are erased:
/usr/share/openhab2
/etc/openhab2

Now my problem: When i restart my machine there is still a java-instance running on port 8080 which shows me a openHab2 instance with the demo-data from a clean-install.
If i search for all processes from java which have relation to openhab
ps -ef | grep "openhab i get the following output:

9001      1105   951  1 14:38 ?        00:00:06 /usr/lib/jvm/default-jvm/bin/java -Dopenhab.home=/openhab -Dopenhab.conf=/openhab/conf -Dopenhab.runtime=/openhab/runtime -Dopenhab.userdata=/openhab/userdata -Dopenhab.logdir=/openhab/userdata/logs -Dfelix.cm.dir=/openhab/userdata/config -Djava.library.path=/openhab/userdata/tmp/lib -Djetty.host=0.0.0.0 -Djetty.http.compliance=RFC2616 -Dorg.ops4j.pax.web.listening.addresses=0.0.0.0 -Dorg.osgi.service.http.port=8080 -Dorg.osgi.service.http.port.secure=8443 -Djava.awt.headless=true -Duser.timezone=Europe/Berlin -Djava.endorsed.dirs=/usr/lib/jvm/default-jvm/jre/lib/endorsed:/usr/lib/jvm/default-jvm/lib/endorsed:/openhab/runtime/lib/endorsed -Djava.ext.dirs=/usr/lib/jvm/default-jvm/jre/lib/ext:/usr/lib/jvm/default-jvm/lib/ext:/openhab/runtime/lib/ext -Dkaraf.instances=/openhab/userdata/tmp/instances -Dkaraf.home=/openhab/runtime -Dkaraf.base=/openhab/userdata -Dkaraf.data=/openhab/userdata -Dkaraf.etc=/openhab/userdata/etc -Dkaraf.log=/openhab/userdata/logs -Dkaraf.restart.jvm.supported=true -Djava.io.tmpdir=/openhab/userdata/tmp -Djava.util.logging.config.file=/openhab/userdata/etc/java.util.logging.properties -Dkaraf.startLocalConsole=false -Dkaraf.startRemoteShell=true -classpath /openhab/runtime/lib/boot/org.apache.karaf.diagnostic.boot-4.2.7.jar:/openhab/runtime/lib/boot/org.apache.karaf.jaas.boot-4.2.7.jar:/openhab/runtime/lib/boot/org.apache.karaf.main-4.2.7.jar:/openhab/runtime/lib/boot/org.apache.karaf.specs.activator-4.2.7.jar:/openhab/runtime/lib/boot/osgi.core-6.0.0.jar org.apache.karaf.main.Main
9001      1106   953 29 14:38 ?        00:02:10 /usr/lib/jvm/default-jvm/bin/java -Dopenhab.home=/openhab -Dopenhab.conf=/openhab/conf -Dopenhab.runtime=/openhab/runtime -Dopenhab.userdata=/openhab/userdata -Dopenhab.logdir=/openhab/userdata/logs -Dfelix.cm.dir=/openhab/userdata/config -Djava.library.path=/openhab/userdata/tmp/lib -Djetty.host=0.0.0.0 -Djetty.http.compliance=RFC2616 -Dorg.ops4j.pax.web.listening.addresses=0.0.0.0 -Dorg.osgi.service.http.port=8080 -Dorg.osgi.service.http.port.secure=8443 -Djava.awt.headless=true -Duser.timezone=Europe/Berlin -Djava.endorsed.dirs=/usr/lib/jvm/default-jvm/jre/lib/endorsed:/usr/lib/jvm/default-jvm/lib/endorsed:/openhab/runtime/lib/endorsed -Djava.ext.dirs=/usr/lib/jvm/default-jvm/jre/lib/ext:/usr/lib/jvm/default-jvm/lib/ext:/openhab/runtime/lib/ext -Dkaraf.instances=/openhab/userdata/tmp/instances -Dkaraf.home=/openhab/runtime -Dkaraf.base=/openhab/userdata -Dkaraf.data=/openhab/userdata -Dkaraf.etc=/openhab/userdata/etc -Dkaraf.log=/openhab/userdata/logs -Dkaraf.restart.jvm.supported=true -Djava.io.tmpdir=/openhab/userdata/tmp -Djava.util.logging.config.file=/openhab/userdata/etc/java.util.logging.properties -Dkaraf.startLocalConsole=false -Dkaraf.startRemoteShell=true -classpath /openhab/runtime/lib/boot/org.apache.karaf.diagnostic.boot-4.2.7.jar:/openhab/runtime/lib/boot/org.apache.karaf.jaas.boot-4.2.7.jar:/openhab/runtime/lib/boot/org.apache.karaf.main-4.2.7.jar:/openhab/runtime/lib/boot/org.apache.karaf.specs.activator-4.2.7.jar:/openhab/runtime/lib/boot/osgi.core-6.0.0.jar org.apache.karaf.main.Main
9001      1846  1790  2 14:42 ?        00:00:06 /usr/lib/jvm/default-jvm/bin/java -Dopenhab.home=/openhab -Dopenhab.conf=/openhab/conf -Dopenhab.runtime=/openhab/runtime -Dopenhab.userdata=/openhab/userdata -Dopenhab.logdir=/openhab/userdata/logs -Dfelix.cm.dir=/openhab/userdata/config -Djava.library.path=/openhab/userdata/tmp/lib -Djetty.host=0.0.0.0 -Djetty.http.compliance=RFC2616 -Dorg.ops4j.pax.web.listening.addresses=0.0.0.0 -Dorg.osgi.service.http.port=8080 -Dorg.osgi.service.http.port.secure=8443 -Djava.awt.headless=true -Duser.timezone=Europe/Berlin -Djava.endorsed.dirs=/usr/lib/jvm/default-jvm/jre/lib/endorsed:/usr/lib/jvm/default-jvm/lib/endorsed:/openhab/runtime/lib/endorsed -Djava.ext.dirs=/usr/lib/jvm/default-jvm/jre/lib/ext:/usr/lib/jvm/default-jvm/lib/ext:/openhab/runtime/lib/ext -Dkaraf.instances=/openhab/userdata/tmp/instances -Dkaraf.home=/openhab/runtime -Dkaraf.base=/openhab/userdata -Dkaraf.data=/openhab/userdata -Dkaraf.etc=/openhab/userdata/etc -Dkaraf.log=/openhab/userdata/logs -Dkaraf.restart.jvm.supported=true -Djava.io.tmpdir=/openhab/userdata/tmp -Djava.util.logging.config.file=/openhab/userdata/etc/java.util.logging.properties -Dkaraf.startLocalConsole=false -Dkaraf.startRemoteShell=true -classpath /openhab/runtime/lib/boot/org.apache.karaf.diagnostic.boot-4.2.7.jar:/openhab/runtime/lib/boot/org.apache.karaf.jaas.boot-4.2.7.jar:/openhab/runtime/lib/boot/org.apache.karaf.main-4.2.7.jar:/openhab/runtime/lib/boot/org.apache.karaf.specs.activator-4.2.7.jar:/openhab/runtime/lib/boot/osgi.core-6.0.0.jar org.apache.karaf.main.Main

The problem now is, i don’t know where the instance in sinstalled and also /openhab/ on root does not exists. May you help me?

Best regards
Walter

What does

dpkg -l "openhab*"

show ?

Running

sudo lsof |grep -i openhab

should show a list of prozesses that are open and belong to user openhab as well as files that have openhab in their name or path. The list might be (very) long but can give an indication where the files are located.

Hey thanks for your reply.
dpkg -l "openhab*
shows
dpkg-query: no packagesfoudn matching openhab*

For
sudo lsof | grep -i “openhab” i get

...
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
lsof: no pwd entry for UID 9001
fileinsta 1106 1909             9001  mem       REG      179,2              137248 /openhab/userdata/cache/org.eclipse.osgi/242/0/bundleFile (stat: No such file or directory)
fileinsta 1106 1909             9001  mem       REG      179,2              128430 /openhab/userdata/cache/org.eclipse.osgi/198/0/bundleFile (stat: No such file or directory)
fileinsta 1106 1909             9001  mem       REG      179,2              128332 /openhab/userdata/cache/org.eclipse.osgi/101/0/bundleFile (stat: No such file or directory)
fileinsta 1106 1909             9001  mem       REG      179,2              128276 /openhab/userdata^C

But as said there is no /openhab/ folder when i try to cd it and the
no pwd entry for UID 9001 occures like thousands of times.

Best regards
Walter

Are you sure that you rebooted the host after OH was deinstalled ? It looks like UID 9001 belongs to a running process but the username was deleted from the passwd file ( due to deinstallation of a package ).

Could you check this one:

sudo lsof -l |grep -i openhab

it should not do a uid translation to username which failed and created the other error messages because the user was deleted from the passwd file.

Yes I’ve shutdown it yesterday and rebooted today i also had the power-cord off for at least a few hours. The

sudo lsof -l |grep -i openhab

Also says that the files are located in /openhab but there is not such a folder

Found the solution working for me here: