Well, Ubuntu Focal has Solr in its package repository, but it's a
decade old, so Ubuntu is one of the distro.s on which you need to do
the installation manually. That means you'll need to create a user to
run it, very like Gentoo which I use.
I called that user 'solr'. I unpacked the Solr v8 files in
/opt/solr-8, created /var/solr-8 to hold the configuration and cores,
created /etc/solr-8 to hold the
solr.in.sh and log4j2.xml, created
/var/log/solr-8 to hold the logs, and edited
solr.in.sh to set
LOG4J_PROPS, SOLR_PID_DIR, SOLR_HOME, and SOLR_LOGS_DIR
appropriately. I set the /var/lib/solr-8 directory and contents to be
owned by 'solr'. I created an initscript (Ubuntu will need a "system
unit" or some such) to start /opt/solr-8/bin/solr as user 'solr'
running in ${SOLR_HOME}, with SOLR_INCLUDE set to
'/etc/solr-8/
solr.in.sh' and passing options '-p 8983 -s
${SOLR_HOME}'. Much of this is what one does for any daemon that
isn't in the package manager.
At that point Solr should start and run, with no cores. I created a
directory ${SOLR_HOME}/ds7 and copied the DSpace 7 empty cores to
there, setting them owned by 'solr'. (You can put the cores directly
into ${SOLR_HOME} but I like to keep related cores organized this
way.)
With reference to the dspace-tech discussion linked above: I don't
know where Solr is getting that path '/dspace/solr/statistics'. We
would need to see how Solr is configured at that site. Assuming that
DSpace is installed at '/dspace', then '/dspace/solr/*' should have
been copied into ${SOLR_HOME} and the copies set owned by the user
that runs Solr. The copies in '/dspace' are just templates, and are
not referenced by DSpace or Solr in use.
Setting up dspace-angular follows the same pattern, with details as
needed by nodejs: create a user to run node; put the package's files
in some place that makes sense to you such as '/opt/dspace-v7-fe';
create a directory to hold the logs such as '/var/log/ds7'; write a
startup file appropriate to your OS, passing environment properties
and options as needed; set file ownership appropriately. Debian
(thus, presumably, Ubuntu) packages a fairly recent 'nodejs' so
installing that is simple. (Hmmm: Focal is still packaging node v10
which is pretty old. Raspbian Bullseye packages v14. I haven't got
an Impish instance to check. Gentoo packages v14.17.6 so that's what
I'm using.)