Raspbian Stretch

They all seem to play happily with each other, but it would probably make more sense to use the default-mysql-server and default-mysql-client packages.
I can see that they are both available in the Stretch sources list, but if you can confirm successful/trouble-free installation with them Paul, then sure, let’s update the build guide.

Paul

Using this package list

sudo apt-get install -y apache2 default-mysql-server default-mysql-client php7.0 libapache2-mod-php7.0 php7.0-mysql php7.0-gd php7.0-opcache php7.0-curl php7.0-dev php7.0-mcrypt php7.0-common php-pear redis-server git-core make

I ended up with the mysql packages

pb66@test2:~$ sudo dpkg -l | grep mysql
ii  dbconfig-mysql                2.0.8                          all          dbconfig-common MySQL/MariaDB support
ii  default-mysql-client          1.0.2                          all          MySQL database client binaries (metapackage)
ii  default-mysql-server          1.0.2                          all          MySQL database server binaries and system database setup (metapackage)
ii  mysql-common                  5.8+1.0.2                      all          MySQL database common files, e.g. /etc/mysql/my.cnf
ii  php-mysql                     1:7.0+49                       all          MySQL module for PHP [default]
ii  php7.0-mysql                  7.0.19-1                       amd64        MySQL module for PHP
pb66@test2:~$ sudo dpkg -l | grep mariadb
ii  mariadb-client-10.1           10.1.26-0+deb9u1               amd64        MariaDB database client binaries
ii  mariadb-client-core-10.1      10.1.26-0+deb9u1               amd64        MariaDB database core client binaries
ii  mariadb-common                10.1.26-0+deb9u1               all          MariaDB common metapackage
ii  mariadb-server-10.1           10.1.26-0+deb9u1               amd64        MariaDB database server binaries
ii  mariadb-server-core-10.1      10.1.26-0+deb9u1               amd64        MariaDB database core server files

and yes so far it been a totally successful/trouble-free installation but the server isn’t fully operational yet.

I’m basically experimenting and writing myself a revised build guide with a couple of automated install scripts, once I have perfected the scripts and practiced the backup/restore routine I will wipe the VM and fully re-install from fresh again.

That was my thinking originally, but actually as I see little real benefit to using that method over defining mariadb-server and maridb-client specifically as we still need to maintain separate package lists for Jessie and Stretch because there is no universal way of selecting php5 or php7 packages. I’m now thinking we should just define mariadb with php7 in Stretch and mysql with php5 in Jessie, but I’m fine with either way for now.

Note, I have added make to the package list, IMO it should actually be a dependency of php-pear deb package because I couldn’t install phpredis without installing make on vanilla Debian9 (Stretch), although it isn’t Raspbian the install is pretty much the same so I would recommend adding it, it won’t do any harm if it’s already in Raspian Stretch, much like the git-core package. I’ve also removed ntp from this package list as it is not needed for emoncms, it should be in the read-only OS section.

Out of interest, using the existing build guide;

sudo apt-get install -y apache2 mariadb-server mysql-client php7.0 libapache2-mod-php7.0 php7.0-mysql php7.0-gd php7.0-opcache php7.0-curl php-pear php7.0-dev php7.0-mcrypt php7.0-common redis-server php-redis git-core build-essential ufw ntp

I got practically the same! (I installed mine a few weeks ago now & my version was armhf)

pi@raspberrypi:~ $ sudo dpkg -l | grep mysql
ii  dbconfig-mysql                        2.0.8                                all          dbconfig-common MySQL/MariaDB support
ii  libdbd-mysql-perl                     4.041-2                              armhf        Perl5 database interface to the MariaDB/MySQL database
ii  mysql-common                          5.8+1.0.2                            all          MySQL database common files, e.g. /etc/mysql/my.cnf
ii  php-mysql                             1:7.0+49                             all          MySQL module for PHP [default]
ii  php7.0-mysql                          7.0.19-1                             armhf        MySQL module for PHP
pi@raspberrypi:~ $ sudo dpkg -l | grep mariadb
ii  libmariadbclient18:armhf              10.1.23-9+deb9u1                     armhf        MariaDB database client library
ii  mariadb-client-10.1                   10.1.23-9+deb9u1                     armhf        MariaDB database client binaries
ii  mariadb-client-core-10.1              10.1.23-9+deb9u1                     armhf        MariaDB database core client binaries
ii  mariadb-common                        10.1.23-9+deb9u1                     all          MariaDB common metapackage
ii  mariadb-server                        10.1.23-9+deb9u1                     all          MariaDB database server (metapackage depending on the latest version)
ii  mariadb-server-10.1                   10.1.23-9+deb9u1                     armhf        MariaDB database server binaries
ii  mariadb-server-core-10.1              10.1.23-9+deb9u1                     armhf        MariaDB database core server files

So long story short, it doesn’t much matter what you ask for you get what your given!

I used default-mysql-client, you used mysql-client and one would hope when mariadb-client is used, all result in mariadb-client-10.1 being installed.

Odd how I didn’t get mariadb-server however you did specifically ask for it.

I assume libmariadbclient18:armhf is an additional package required for armhf, likewise for libdbd-mysql-perl unless you installed it seperately.

Ha ha! appears so.

No, Just like the above, they wanted me to have them!!

Hi Paul, followed the link and got a 404. Is the script around somewhere?

Hi Brian - The link was probably lost when the “stretch” page became the default “readme”

OK thanks. Did you create a script to install Emoncms?

Hi Brian, yes that fork was merged into emoncms, and then deleted. I’ll remove the link.

Paul

Are you referring to a script to install emoncms?

I was replying to the question which you asked me;

It’s Paul - @pb66 who was looking at a script.

Paul

Ah yes, sorry, wrong Paul :slight_smile:

I did create a script that I have used succesfully, however it is really quite specialized for my own use at the moment (and very untidy).

The vhosts presents a bit of an obstacle for making this fit for public release, plus there are significant differences to the established norm which I need to document or at least have time to explain/defend which I currently do not. I will have to make further decisions on how to make it more “universal”.

I am also (when I can) working on an auto-update script which will be able to be used standalone or triggered from within emoncms like the current emonpi updater. The end goal is that if any part of emoncms is not up to date the new versions will be listed on the admin page and an “update now” button revealed.

The updater and installer are linked only in that I’m considering auto installing modules and their location/symlinking is important to get right to work for both cases.

1 Like

12 posts were split to a new topic: Updating system libraries used by emoncms