Skip to content

Installing newer (0.90 dev) libsmbclient extension under Ubuntu 16.04 or CentOS 7

Ralf Becker edited this page Apr 16, 2018 · 3 revisions

PHP extension smbclient can be used to mount Samba/SMB shares into EGroupware's filemanager. Released version 0.8 form Ubuntu 16.04 or IUS is extrem slow, which is fixed in current development version 0.9-dev.

Updates on version 0.9 from php-smbclient:

  • RHEL/CentOS 7: IUS contains php7{0,1}u-pecl-smbclient for PHP 7.0 and 7.1
  • Debian testing contains php-smbclient 0.9 too now
  • Ubuntu 16.04 & Debian 9: php-smbclient 0.9 is available from EPL download repository

EPL installation instructions contain examples how to use Samba/SMB shared in EGroupware.

Ubuntu 16.04

    git clone https://github.com/eduardok/libsmbclient-php.git
    cd libsmbclient-php/
    apt-get install php7.0-dev libsmbclient-dev
    phpize
    ./configure
    make
    make install
    mv /etc/php/mods-available/smbclient.ini /etc/php/7.0/mods-available/
    cd /etc/php/7.0/mods-available/apache2
    ln -s /etc/php/7.0/mods-available/smbclient.ini 20-smbclient.ini
    service apache2 restart

RHEL/CentOS 7 with php70u from IUS repo

    yum groupinstall 'Development Tools'
    yum install git php70u-devel samba-devel
    git clone https://github.com/eduardok/libsmbclient-php.git
    cd libsmbclient-php/
    ./configure
    make
    make install
    vi /etc/php.d/99-smbclient.ini # extension=smclient.so
    service httpd restart
Clone this wiki locally