Score:0

Debian 11, multiple Solr versions running on different ports, lsof says that Solr9 is accessible only from localhost.localdomain

sd flag

I have a Debian 9 server that is running Solr 7.3. I have upgraded to Debian 11, Solr is still fine.

Now I'm trying to install Solr 9 alongside Solr 7.3, to have both versions running in the same time. I followed the official guide.

bash ./install_solr_service.sh solr-9.0.0.tgz -i /opt -d /var/solr9 -u solr -s solr9 -p 8984

the installation seems to work fine systemctl status solr9.service says

● solr9.service - LSB: Controls Apache Solr as a Service
     Loaded: loaded (/etc/init.d/solr9; generated)
     Active: active (exited) since Mon 2022-11-14 12:43:13 UTC; 4min 47s ago
       Docs: man:systemd-sysv-generator(8)
    Process: 6781 ExecStart=/etc/init.d/solr9 start (code=exited, status=0/SUCCESS)

Nov 14 12:43:07 xxx systemd[1]: Starting LSB: Controls Apache Solr as a Service...
Nov 14 12:43:13 xxx solr9[6835]: Started Solr server on port 8984 (pid=6830). Happy searching!
Nov 14 12:43:13 xxx systemd[1]: Started LSB: Controls Apache Solr as a Service.

but I can't reach Solr9 panel from the browser.

I have checked iptables --list and settings for port 8983 (where is running Solr 7.3) are the same of port 8984 (where is running Solr 9).

lsof -i | grep 8983 says

java    5622        solr   37u  IPv6 117480      0t0  TCP *:8983 (LISTEN)

but lsof -i | grep 8984 says

java    6830        solr  136u  IPv6 134506      0t0  TCP localhost.localdomain:8984 
Score:0
sd flag

I think I have found the solution, it has nothing to do with running multiple versions of solr, I was having the identical issue on a fresh Debian install.

so the solution is:

open the configuration file /etc/default/solr.in.sh (in my case it's /etc/default/solr9.in.sh)

append this line

SOLR_JETTY_HOST="0.0.0.0"

restart the service systemctl restart solr.service (in my case it's systemctl restart solr9.service)

now finally lsof -i | grep 8984 says the port it's open

java    1952        solr  136u  IPv6  29073      0t0  TCP *:8984 (LISTEN)

and finally I can access Solr Admin UI from the browser.

All credits to: https://tecadmin.net/configuring-apache-solr-to-accessible-on-public-ip/

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.