KeexyBox's forum
installation on raspberry pi i386 - Printable Version

+- KeexyBox's forum (https://forum.keexybox.org)
+-- Forum: Installation (https://forum.keexybox.org/Forum-Installation--7)
+--- Forum: Installation (https://forum.keexybox.org/Forum-Installation)
+--- Thread: installation on raspberry pi i386 (/Thread-installation-on-raspberry-pi-i386)



installation on raspberry pi i386 - corkball - 02-14-2021

Hopefully this will help somebody.  I had an old mini-pc, but no ARM-based pi device, so I recompiled for i386, and it SEEMS to work for the most part, although it was a giant pain.  Lack of a unified structure presents a lot of potential support issues, although I suppose it might give a nerd tons of opportunity for code customization.

I don't THINK I will use keexybox, even though it is a great idea, because it lacks more robust support for iptables like control over NAT, and I would also like to be able to enable and disable my filtering (for example: block child X until child X completes his homework, then unblock *roblox.com).  But otherwise, the interface is totally sweet.


--------------------------------------------
KEEXYBOX 20.10.2 install notes on i386 linux VM in VirtualBox 6.1:
----------------------------------------------------------

1) install i386 raspbios https://downloads.raspberrypi.org/rpd_x86/images/ - at the time I used
a recent version rpd_x86-2020-02-14.  Download and install ISO in virtualbox 6.1

2) make some OS changes:
a) disable IPv6 (https://www.techrepublic.com/article/how-to-disable-ipv6-on-linux/)
you can disable in /etc/sysctl.conf:
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
net.ipv6.conf.lo.disable_ipv6 = 1
b) screen resolution, allow SSH
c) pi defaults to user 'pi', password is whatever you set, and you can 'sudo su' to root

3) in this version of the OS, PHP7.3 will install.  That is fine, but it creates issues for 2
packages, php-mcrypt (obsolete), and php-tcpdf (obsolete, but has backport)
a) to install php-tcpdf, edit /etc/apt/sources.list.  Add a source:
deb http://ftp.debian.org/debian/ buster-backports main
  then install the package:
apt install php-tcpdf
b) to install mcrypt, this is a bit harder, since there is no backport.
1. apt-get install php-dev libmcrypt-dev php-pear
2. pecl channel-update pecl.php.net
3. pecl install channel://pecl.php.net/mcrypt-1.0.2
4. edit /etc/php/7.3/cli/php.ini and add line 'extension=mcrypt.so'.
5. 'php -m | grep mcrypt' should return 'mcrypt'
6. ok, now, we need to tell keexybox to ignore the missing mcrypt package:
7. in install package (do this later, we havent created this yet), go in to
/keexybox-20.10.2/util/required_packages.conf and comment out
'php-mcrypt'

keexybox is for pi devices which use ARM architecture, not i386, so you cant use default packages. 
you must follow manual build process to create i386 binaries:
https://wiki.keexybox.org/doku.php/manual_installation

random problems I encountered:
---------------------------------------------------------
had to modify apache2.conf to keep apache from crashing:
Mutex posixsem

locked myself out, had to reset admin password (there seems to be a lack of documented support for CLI administration):
/opt/keexybox/keexyapp/bin/cake users UpdateAdminPassword <password>

booting hung with 'you are in emergency mode' - i screwed up my cdrom mount.  comment that line /dev/sr0
out of /etc/fstab


RE: installation on raspberry pi i386 - vit - 05-03-2021

Hello corkball, thanks for the tips, after several hours of trying install on Rapsbery OS x86, running on old vaio laptop, I managed to remove almost all errors, except PHP PAM.so, and after the installation he is unable to start the services, I did what you explained about disabling ipv6, there is something what do you think i can do? Here is the print and log:

[ ok ] Starting mysql (via systemctl): mysql.service.

[ ok ] Starting apache2 (via systemctl): apache2.service.

Starting keexybox services:

PHP Warning:  PHP Startup: Unable to load dynamic library 'pam.so' (tried: /usr/lib/php/20180731/pam.so (/usr/lib/php/20180731/pam.so: cannot open shared object file: No such file or directory), /usr/lib/php/20180731/pam.so.so (/usr/lib/php/20180731/pam.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0

Keexybox dhcp start... FAILED

Keexybox hostapd start... FAILED

Keexybox bind start... FAILED

Keexybox tor start... FAILED

Keexybox rules start... OK

PHP Warning:  PHP Startup: Unable to load dynamic library 'pam.so' (tried: /usr/lib/php/20180731/pam.so (/usr/lib/php/20180731/pam.so: cannot open shared object file: No such file or directory), /usr/lib/php/20180731/pam.so.so (/usr/lib/php/20180731/pam.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0



---- Deleting keexybox backup ----


Deleting /opt/keexybox/scripts_old... Deleting /opt/keexybox/keexyapp_old...

(05-03-2021, 03:16 AM)i check the logs, something about a ld-linux-armhf.so.3 that isnt there...architeture conflit i think... the guy on  the link above bypass it, i try but no luck here...2021-05-03 01:49:50 - /usr/bin/sudo /opt/keexybox/keexyapp/src/Shell/scripts/init_bind start Wrote: 2021-05-03 01:49:50 - Starting domain name keexybox services... bind9
2021-05-03 01:49:50 - /lib/ld-linux-armhf.so.3: No such file or directory
2021-05-03 01:49:50 - /lib/ld-linux-armhf.so.3: No such file or directory
2021-05-03 01:49:50 - /lib/ld-linux-armhf.so.3: No such file or directory



https://unix.stackexchange.com/questions/553743/correct-way-to-add-lib-ld-linux-so-3-in-debian

(05-03-2021, 03:16 AM)vit Wrote: Hello corkball, thanks for the tips, after several hours of trying install on Rapsbery OS x86, running on old vaio laptop, I managed to remove almost all errors, except PHP PAM.so, and after the installation he is unable to start the services, I did what you explained about disabling ipv6, there is something what do you think i can do? Here is the print and log:

[ ok ] Starting mysql (via systemctl): mysql.service.

[ ok ] Starting apache2 (via systemctl): apache2.service.

Starting keexybox services:

PHP Warning:  PHP Startup: Unable to load dynamic library 'pam.so' (tried: /usr/lib/php/20180731/pam.so (/usr/lib/php/20180731/pam.so: cannot open shared object file: No such file or directory), /usr/lib/php/20180731/pam.so.so (/usr/lib/php/20180731/pam.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0

Keexybox dhcp start... FAILED

Keexybox hostapd start... FAILED

Keexybox bind start... FAILED

Keexybox tor start... FAILED

Keexybox rules start... OK

PHP Warning:  PHP Startup: Unable to load dynamic library 'pam.so' (tried: /usr/lib/php/20180731/pam.so (/usr/lib/php/20180731/pam.so: cannot open shared object file: No such file or directory), /usr/lib/php/20180731/pam.so.so (/usr/lib/php/20180731/pam.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0



---- Deleting keexybox backup ----


Deleting /opt/keexybox/scripts_old... Deleting /opt/keexybox/keexyapp_old...

(05-03-2021, 03:16 AM)i check the logs, something about a ld-linux-armhf.so.3 that isnt there...architeture conflit i think... the guy on  the link above bypass it, i try but no luck here...2021-05-03 01:49:50 - /usr/bin/sudo /opt/keexybox/keexyapp/src/Shell/scripts/init_bind start Wrote: 2021-05-03 01:49:50 - Starting domain name keexybox services... bind9
2021-05-03 01:49:50 - /lib/ld-linux-armhf.so.3: No such file or directory
2021-05-03 01:49:50 - /lib/ld-linux-armhf.so.3: No such file or directory
2021-05-03 01:49:50 - /lib/ld-linux-armhf.so.3: No such file or directory



https://unix.stackexchange.com/questions/553743/correct-way-to-add-lib-ld-linux-so-3-in-debian



RE: installation on raspberry pi i386 - vit - 05-03-2021

maybe this  can help, but i dont know how ;(

https://www.bootc.net/archives/2012/05/26/how-to-build-a-cross-compiler-for-your-raspberry-pi/


RE: installation on raspberry pi i386 - benoit - 05-03-2021

You can try to compile/install KeexyBox on Debian 10 x86 instead of raspiOS x86

https://wiki.keexybox.org/doku.php/manual_installation


RE: installation on raspberry pi i386 - vit - 05-03-2021

(05-03-2021, 05:40 AM)benoit Wrote: You can try to compile/install KeexyBox on Debian 10 x86 instead of raspiOS x86

https://wiki.keexybox.org/doku.php/manual_installation

Thanks a lot benoit!!

After typing all these commands, correcting an error when compiling BIND, I finally managed to run it, there was only one detail in the execution of this script below:


root@p1:/opt/keexybox/keexyapp/src/Shell/scripts# ./pre-startup-keexybox.sh
chmod: não foi possível acessar '/opt/keexybox/bind/etc/zones': No file or directory

I comment the line ( #chmod go+w ${KEEXYBOX_HOME}/bind/etc/zones ) in "pre-startup-keexybox.sh" and run it again.

Looks like its working now!!!

But... I can startup the rules service, any tips?