Welcome to the nuBuilder forums!

Please register and login to view forums and other content only available to registered users.

How to install nuBuilder on Ubuntu 18.04

Questions related to installing, updating, setting up and configuring
Locked
bmullan
Posts: 6
Joined: Sat Oct 20, 2018 11:21 pm

How to install nuBuilder on Ubuntu 18.04

Unread post by bmullan »

Step-by-Step Install Guide for NuBuilder4 on Ubuntu 18.04

The following are 2 sets of instructions.
  • The First, is how to install NuBuilder4 on Ubuntu 18.04 Server/Desktop/VM.

    The Second is how to install NuBuilder4 in an LXD Container on an Ubuntu 18.04 LXD "host" (whether that
    host is a Server/Desktop/VM.)
The benefit of an LXD container is that you can easily copy/clone the "nubuilder" container or migrate the
container to another LXD "host" locally, remotely or on a Cloud server. If you use LXD with ZFS/BTRFS
(LXD will create & use a ZFS/BTRFS loop device if your file system isn't already ZFS/BTRFS) you can
also utilize snapshot/restore etc for your NuBuilder4 LXD installation.

NOTE: LXD also supports various file systems including CEPH, BTRFS, ZFS, LVM, and plain
directory-based EXF4 file systems. LXD also can create/manage other Distro's in
LXD containers including Fedora, CentOS, Debian, Alpine, Oracle, Suse etc.

Anyway, I put these together because I just couldn't find any real guide on either Youtube, the web, or
on the NuBuilder website with step-by-step instructions and had seen a lot of posts on the NuBuilder
Forum asking how to install it.

The answer's always seemed to just point to the minimally informational instructions in the "setup" section
of the Website which if you are experienced enough in all the basic components (apache2, mysql, PHP etc
you could probably figure out even the missing informational pieces quickly.

As I worked on this I kept finding more and more pieces of important information related to how to install
NuBuilder4 successfully that just were never collated into one place/document. So this is what I put
together. Note: I am now using Nubuilder4 in LXD containers running on local & remote (cloud servers). So
far things look like they are working as they are supposed to.

Brian

==================================================================================
==={ How to install in Ubuntu 18.04 Server/Desktop/VM }=====================================
==================================================================================


To install & use NuBuilder4 in Ubuntu 18.04 Server/VM/Desktop follow these instructions:

$ sudo apt install mysql-server apache2 php php-mysql unzip libapache2-mod-php php-mbstring -y

Make sure the mysql "root" password is set to use "passwords" and not "auth-socket".
You can do this by following Step 3 — (Optional) Adjusting User Authentication and Privileges

https://www.digitalocean.com/community/ ... untu-18-04

$ cd /var/www/html

$ sudo wget https://github.com/nuSoftware/nuBuilder ... master.zip

$ sudo unzip ./master.zip

Create an empty Database

$ sudo mv ./nuBuilder4-master/* .

$ sudo rm ./index.html

$ mysql -u root -p

mysql> CREATE DATABASE nubuilder4;
Query OK, 1 row affected (0.00 sec)

mysql> quit
Bye

Copy the nubuilder4.sql schema into that empty database

$ mysql -u root -p nubuilder4 < ./nubuilder4.sql

Add the mysql root password to the nuconfig.conf file

$ sudo nano nuconfig.php

Make sure to open Ports 80 & maybe 8080 for html access to the container

$ sudo ufw allow 80
$ sudo ufw allow 8080

To make sure that the nubuilder4 setup tab is present when logging in as "globeadmin"
you need to edit my.cnf and add some config statements

$ sudo nano /etc/alternatives/my.cnf

Then append/add...

[client]
port=3306
socket=/tmp/mysql.sock

[mysqld]
port=3306
socket=/tmp/mysql.sock
key_buffer_size=16M
max_allowed_packet=8M
sql-mode=NO_ENGINE_SUBSTITUTION

[mysqldump]
quick


============================================================================================
==={ To Install NuBuilder4 in an LXD container }=======================================================
============================================================================================


First in an Ubuntu Server/Desktop/VM .. create an LXD ubuntu container named "nubuilder"

$ lxc launch ubuntu:b nubuilder

Then access the "nubuilder" container which logs you in as root and leaves you at a Bash prompt:

$ lxc exec nuBuilder bash

Install required software for NuBuilder4:

# apt install mysql-server apache2 php php-mysql unzip libapache2-mod-php php-mbstring -y

From this point on everything is basically the same as the above instructions for installing NuBuilder4 in a
Server/Desktop/VM...

Make sure the mysql "root" password is set to use "passwords" and not "auth-socket".
You can do this by following Step 3 — (Optional) Adjusting User Authentication and Privileges

https://www.digitalocean.com/community/ ... untu-18-04

# cd /var/www/html

# wget https://github.com/nuSoftware/nuBuilder ... master.zip

# unzip ./master.zip

Create an empty Database

# mv ./nuBuilder4-master/* .

# rm ./index.html

# myql -u root -p

mysql> CREATE DATABASE nubuilder4;
Query OK, 1 row affected (0.00 sec)

mysql> quit
Bye

Copy the nubuilder4.sql schema into that empty database

# mysql -u root -p nubuilder4 < ./nubuilder4.sql

Add the mysql root password to the nuconfig.conf file

# nano nuconfig.php

Make sure to open Ports 80 & maybe 8080 for html access to the container

# ufw allow 80
# ufw allow 8080

To make sure that the nubuilder4 setup tab is present when logging in as "globeadmin"
you need to edit my.cnf and add some config statements

# nano /etc/alternatives/my.cnf

Then append/add...

[client]
port=3306
socket=/tmp/mysql.sock

[mysqld]
port=3306
socket=/tmp/mysql.sock
key_buffer_size=16M
max_allowed_packet=8M
sql-mode=NO_ENGINE_SUBSTITUTION

[mysqldump]
quick



==={ Reboot your Server/Desktop/VM/Container then Access/Use NuBuilder4 }====================================


Whether you installed NuBuilder4 in LXD or on a VM or a Desktop or a Server the setup should be complete so
now reboot the LXD container (or your VM, Server etc) to verify everything comes back up and you can now access NuBuilder4 !

shutdown -r now

then...
point your web browser to: http://<ip_of_machine or container>

and login as: globeadmin
password: nu
Last edited by bmullan on Thu Dec 13, 2018 11:22 am, edited 1 time in total.
admin
Site Admin
Posts: 2778
Joined: Mon Jun 15, 2009 2:23 am
nuBuilder Version: 4.5

Re: My Step-by-Step Install Guide for NuBuilder4 on Ubuntu 1

Unread post by admin »

Great work Brian!

Steven
Celson
Posts: 36
Joined: Wed Jan 27, 2016 12:35 pm
nuBuilder Version: 4.5
Location: Salvador, Bahia - Brazil

Re: My Step-by-Step Install Guide for NuBuilder4 on Ubuntu 1

Unread post by Celson »

When I try to follow the instructions for LXD container I get the error on image below:
Could you help me?
Captura de tela 2020-11-02 111009.png
Captura de tela 2020-11-02 111009.png (11.42 KiB) Viewed 6050 times
kev1n
nuBuilder Team
Posts: 3801
Joined: Sun Oct 14, 2018 6:43 pm
nuBuilder Version: 4.5
Has thanked: 2 times
Been thanked: 9 times
Contact:

Re: My Step-by-Step Install Guide for NuBuilder4 on Ubuntu 1

Unread post by kev1n »

Hi,

Is the php-mbstring package installed?

Also look here for an Installation Instruction:
https://andyblight.wordpress.com/2020/0 ... der-forte/
Now install the packages that are needed to to support nuBuilder: MySQL for the database, Apache2 for the web server and PHP for scripting. This is often referred to as a LAMP (Linux, Apache, MySQL, PHP) stack. At the prompt enter:

# apt update
# apt install -y mysql-server apache2 php php-mysql unzip libapache2-mod-php php-mbstring
Celson
Posts: 36
Joined: Wed Jan 27, 2016 12:35 pm
nuBuilder Version: 4.5
Location: Salvador, Bahia - Brazil

Re: My Step-by-Step Install Guide for NuBuilder4 on Ubuntu 1

Unread post by Celson »

It worked after i did the apt update before the apt install.
Thanks!
Captura de tela 2020-11-02 144005.png
Captura de tela 2020-11-02 144005.png (44.99 KiB) Viewed 6045 times
Locked