How to query solr server from php in Drupal 8
I managed to fix the problems with SolrClient install: https://stackoverflow.com/questions/41052999/php-warning-unable-to-load-dynamic-library-usr-lib64-php-modules-solr-so-und%C2%A0

This is how I can now query the solr server from php (right out of php SolrClient manual):

$options = array
(
    'hostname' =&gt; 'localhost',
    'port'     =&gt; '8983',
    'path'     =&gt; 'solr/sbn01'
);

$client = new SolrClient($options);

$query = new SolrQuery();

$query-&gt;setQuery('*file/10*');

$query-&gt;setStart(0);

$query-&gt;setRows(50);

$query-&gt;addField('id');
$query-&gt;addField('its_fid');
$query-&gt;addField('ss_uri');

$query_response = $client-&gt;query($query);

$response = $query_response-&gt;getResponse();

print_r($response);