Operating System Setup

The current version of Maxscape is build on Ubuntu and runs on Debian as well. Most of the tools required or helpful with Maxscape are part of the standard installation. Anyway, to setup the operating system for Maxscape, especially to make the platform components from their sources, you need to install the following tools:

apt-get -y install analog aptitude autoconf bison cmake curl cvs Expat \
ffmpeg g++ git iptables libaio-dev libav-tools libexpat1-dev libjpeg62-dev \
libncurses5-dev libpng12-dev libtool libxpm-dev libxvidcore4 libfaac0 \
locate lynx man-db net-tools nmap rcconf rpm tcsh vim whois zlib1g-dev \
libexpat1-dev

Unix shell commands and development tools

There is no special requirement on the development tools to use. I prefer a Gnome terminal and Vim to work with Perl sources, and the Maxscape web surfaces to work with the content database and the Internet for information, Services and software. The framework uses the following Unix shell commands and development tools:

bash
- GNU Bourne-Again SHell
tcsh
- C shell with file name completion and command line editing
vim
- Vi IMproved, a programmer's text editor
grep
- Print lines that match patterns
find
- Search for files in a directory hierarchy
locate
- list files in databases that match a pattern
diff
- compare files line by line
make
- GNU make utility to maintain groups of programs
gcc
- GNU project C and C++ compiler
ld
- The GNU linker
ldconfig
- Configure dynamic linker run-time bindings
cvs
- Concurrent Versions System
git
- The stupid content tracker
rpm
- RPM Package Manager
ifconfig
- Configure a network interface
ip
- Show/manipulate routing, network devices, interfaces and tunnels
ssh
- OpenSSH remote login client and server
...
-

Unix OS Users

To manage and operate the Maxscape server you need the following Unix users.

maxscape  - Maxscape management and development
su - User with root privileges to start/stop the server
maxrun - User under which the HTTP server is running
maxdaemon  - Maxdaemon HTTPD server
mysql  - Database user

Use the related commands to add the OS users or simply cut-and-paste the following entries to your '/etc/passwd' and '/etc/group' files:

# file: /etc/passwd
...
maxscape:x:8000:8000::/maxscape/var/home/maxscape:/bin/bash
su:x:0:8000::/maxscape/var/home/su:/bin/bash
maxrun:x:8001:8001::/dev/null:/bin/false
maxdaemon:x:8002:8002::/opt/maxdaemon/1.0.0/home:/bin/bash
mysql:x:8100:8100::/maxscape/var/home/mysql:/bin/sh
...
# file: /etc/group
...
maxscape:x:8000:maxdaemon,maxrun
maxrun:x:8001:maxscape,maxdaemon
maxdaemon:x:8002:maxscape,maxrun
mysql:x:8100:mysql,maxscape
...

Log into these accounts from your personal account using the 'su' command. Forget about sudo with Maxscape it is just to verbose and remember nothing is bullet proofed.

/home/<Username>: su - su         # start/stop scripts
/home/<Username>: su - maxscape   # development

Host, IP and Network Configuration

The run-time system depends on the configuration of the Ethernet device. It can be configured to listen to IP addresses or name-based virtual hosts with full qualified domain names (FQDN). Eighter the virtual hosts have to be configured by an Internet service provider or it can be configured locally for development and test purposes. In both cases a 'hostname --fqdn' and 'domainname' should yield real FQDNs, e.g.:

# Define the domain name locally, e.g.:
> vi /etc/rc.local
...
/bin/domainname local.net
...
> hostname --all-fqdns
maxscape.local.net
> domainname
local.net
> hostnamectl hostname
maxscape

To set up a the host, domain name and IP address locally, do something like:

> su - su
vi /maxscape/etc/init.d/maxscape
...
MAXSCAPE_MAXDAEMON_HOST_IP=192.168.0.1
# MAXSCAPE_MAXDAEMON_HOST_IP=192.168.0.2
export MAXSCAPE_MAXDAEMON_HOST_IP
...

> vi /etc/hosts # add IP and hostnames
# 192.168.0.2     maxdaemon.local.net
# # 192.168.0.2     webserver.local.net
# 192.168.0.2     maxscape.local.net
# 192.168.0.2     sound-basement.local.net
# 192.168.0.2     profile-community.local.net
# 192.168.0.2     strinx.local.net

192.168.0.1     maxdaemon.local.net
# 192.168.0.1     webserver.local.net
192.168.0.1     maxscape.local.net
192.168.0.1     sound-basement.local.net
192.168.0.1     profile-community.local.net
192.168.0.1     strinx.local.net

# IP temporary configuration
> ifconfig eth0 192.168.0.1 netmask 255.255.255.0 up
> ifconfig eth0:1 192.168.0.2 netmask 255.255.255.0 up # second Ethernet device

# IP permanent configuration
> vi /etc/network/interfaces
  iface eth0 inet static
  address 192.168.0.1
  netmask 255.255.255.0

  # Maybe add a second interface:
  iface eth0:1 inet static
  address 192.168.0.2
  netmask 255.255.255.0
  auto eth0 eth0:1

# Then restart the ethernet interface:
> /sbin/ifdown eth0
> /sbin/ifup eth0

# Show ethernet configuration
> ifconfig
eth0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
        inet 192.168.0.1  netmask 255.255.255.0  broadcast 192.168.0.255
        ether 00:63:8c:93:47:2b  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

eth0:1: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        inet 192.168.0.2  netmask 255.255.255.0  broadcast 192.168.0.255
        ether 00:63:8c:93:47:2b  txqueuelen 1000  (Ethernet)

Firewall Setup

To block nasty socket attacts, enable ENABLE_WATCH_CLIENT_REQUEST and NETWORK_WATCH. See the Maxscape Control Daemon for more information. See also '/etc/sysctl.conf' to tweak the firewall setup.

Next ∙ Previous ∙ Top ∙ Join ∙ Contact © Maxscape