Build E.F.A from scratch.

Questions and answers about how to do stuff
Post Reply
User avatar
darky83
Site Admin
Posts: 530
Joined: 30 Sep 2012 11:03
Location: eFa
Contact:

Build E.F.A from scratch.

Post by darky83 » 20 Oct 2012 19:18

If you want to use E.F.A on direct hardware instead of a VM you will need to build E.F.A from a build script.
A bit of Linux (Debian) knowledge is required to get this working.

Currently there is no bootstrap script available so you will need to install Debian 6.0.x (x86) your self with the following settings during installation:
  • Create the root user with password: password
  • Create the user: efaadmin
  • password for user efaadmin: password
  • Disk setup (the use of LVM is recommended, below settings are guidelines but are not required a single / could work.):
  • - minimum 6GB /
  • - minimum 1GB /tmp (set noexec & nosetuid)
  • (if you don't want a separate /tmp partition you need to comment the two DPkg: lines in the build script)
  • - minimum 12GB /var
  • - minimum 20GB /var/spool
  • Software installation: SSH Server & Standard system utilities
After the OS is installed and is booted login as root.
Now download and execute the build script:

Code: Select all

wget http://www.efa-project.org/build/0.3/build.sh
chmod 700 build.sh
./build.sh
During the installation you will be asked to configure mysql answer these as followed:
  • Configure MySQL (1): yes
  • Configure MySQL (2): yes
The system will automatically reboot and is ready for configuration (the configure script will automatically be launched when you login as root the first time).

Good luck!
Version eFa 4.0.0 RC3 now available in testing repo. Come join us in advancing eFa!

Mach3
Posts: 10
Joined: 16 Oct 2012 07:58

Re: Build E.F.A from scratch.

Post by Mach3 » 08 Nov 2012 22:34

Pretty much everything barring Baruwa installed on the Raspberry Pi

levon
Posts: 1
Joined: 27 Nov 2012 23:17

Re: Build E.F.A from scratch.

Post by levon » 27 Nov 2012 23:19

I followed these instructions and I get the following errors...

web page
Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, [no address given] and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.
Apache/2.2.16 (Debian) Server at 192.168.10.121 Port 80

apache2/baruwa-error.log
[Wed Nov 28 01:14:54 2012] [error] [client 192.168.10.213] DatabaseError: (1146, "Table 'baruwa.django_session' doesn't exist")
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] mod_wsgi (pid=632): Exception occurred processing WSGI script '/usr/share/pyshared/baruwa/baruwa.wsgi'.
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] Traceback (most recent call last):
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/core/handlers/wsgi.py", line 245, in __call__
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] response = middleware_method(request, response)
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/contrib/sessions/middleware.py", line 36, in process_response
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] request.session.save()
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/contrib/sessions/backends/db.py", line 56, in save
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] session_key = self.session_key,
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/contrib/sessions/backends/base.py", line 152, in _get_session_key
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] self._session_key = self._get_new_session_key()
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/contrib/sessions/backends/base.py", line 144, in _get_new_session_key
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] if not self.exists(session_key):
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/contrib/sessions/backends/db.py", line 29, in exists
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] Session.objects.get(session_key=session_key)
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/db/models/manager.py", line 132, in get
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] return self.get_query_set().get(*args, **kwargs)
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/db/models/query.py", line 336, in get
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] num = len(clone)
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/db/models/query.py", line 81, in __len__
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] self._result_cache = list(self.iterator())
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/db/models/query.py", line 269, in iterator
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] for row in compiler.results_iter():
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/db/models/sql/compiler.py", line 672, in results_iter
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] for rows in self.execute_sql(MULTI):
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/db/models/sql/compiler.py", line 727, in execute_sql
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] cursor.execute(sql, params)
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/django/db/backends/mysql/base.py", line 86, in execute
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] return self.cursor.execute(query, args)
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/MySQLdb/cursors.py", line 166, in execute
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] self.errorhandler(self, exc, value)
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] File "/usr/lib/pymodules/python2.6/MySQLdb/connections.py", line 35, in defaulterrorhandler
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] raise errorclass, errorvalue
[Wed Nov 28 01:15:14 2012] [error] [client 192.168.10.213] DatabaseError: (1146, "Table 'baruwa.django_session' doesn't exist")

User avatar
darky83
Site Admin
Posts: 530
Joined: 30 Sep 2012 11:03
Location: eFa
Contact:

Re: Build E.F.A from scratch.

Post by darky83 » 28 Nov 2012 07:57

It seems that the database or tables do not exist in mysql for baruwa.

This will most likely be because you did not use the password 'password or made a typo in one of the usernames or passwords.
Version eFa 4.0.0 RC3 now available in testing repo. Come join us in advancing eFa!

Mach3
Posts: 10
Joined: 16 Oct 2012 07:58

Re: Build E.F.A from scratch.

Post by Mach3 » 05 Dec 2012 16:08

darky83 wrote:This will most likely be because you did not use the password 'password or made a typo in one of the usernames or passwords.
I can confirm this as I made the same mistake.

rhostager
Posts: 2
Joined: 29 Jan 2013 01:40

Re: Build E.F.A from scratch.

Post by rhostager » 29 Jan 2013 01:44

Do you recommend the amd64 or i386 version of Debian or does it not matter?

Thanks

Rob

User avatar
darky83
Site Admin
Posts: 530
Joined: 30 Sep 2012 11:03
Location: eFa
Contact:

Re: Build E.F.A from scratch.

Post by darky83 » 29 Jan 2013 09:20

Hi Rob,

Currently all is build on x86, never tested on amd64.

Good point I will add this to the howto.

d.
Version eFa 4.0.0 RC3 now available in testing repo. Come join us in advancing eFa!

ge2000
Posts: 28
Joined: 23 Jan 2013 19:27

Re: Build E.F.A from scratch.

Post by ge2000 » 29 Jan 2013 12:51

I recently installed EFA with SQLgrey and webmin on debian 6.0.6 amd64.

Beside two minor problems (no relation to platform) with exec permissions of a script and an apache2 config everything installs and runs fine.

So no problems on 64bit systems :)

--Ge

ge2000
Posts: 28
Joined: 23 Jan 2013 19:27

Re: Build E.F.A from scratch.

Post by ge2000 » 24 May 2013 08:03

In addition to my previous post I can add that I have succesfully installed EFA on Ubuntu 12.04.2 LTS (64Bit).

Problems I had where:
- the install script tries to install (mysql)versions that are not in the Ubuntu repo
- rabbitmq had to be reconfigured as mentioned in other posts
- baruwa user/password had to be corrected afterwards
- Apache2, WSGIScriptAlias location corrected in config
- apparmor had to be modified to enable clamav scanning

So despite these minor issues everything works fine now.

Post Reply