Blog related to Asterisk PBX solutions.

TrixBox on Alix using VirtualBox

I’ve found some tutorials describing how to install Trixbox on CF for Alix board (http://www.pcengines.ch/) using VMware server 1.0.x. Whenever I try to install it on physical CF my Windows XP does not recognized it as a “physicaldrive” and I can make my VMware working on Ubuntu using my karnel. Finally I decided to use other virtualization on Linux.

I installed the VirtualBox (http://www.virtualbox.org/wiki/Linux_Downloads) which worked very nice on my Ubuntu. Also download ISO image of TrixBox 2.6.x.x (http://fonality.com/trixbox/downloads)

Create a new VM:

New -> Name: trixbox_alix ;  Operating System: Linux ; Version: Linux 2.6 > Base Memory Size: 256MB > Boot Hard Disc -checked ; Create new hard Disk > Storage Type: Dynamically expending storage -checked > Location: [patch_where_you_want_to_keep_the_image_] ; Size: [depends_of_CF_card] 8GB [make_it_smaller_then_CF_-1GB]

VM settings:

Settings > System: Boot Order: CD/DVD-checked Hard Disk-checked > Storage: [in_IDE_controller_choose_the_location_of_trixbox_iso] > Audio: unchecked >  Network: [add_no._of_LANinterfaces_on_alix] ; Attached to: Bridged Adapter > Ports: add 2 USB and Serial Port

Now start the virtual machine and do the installation process. After installation go once more to setting and you have to unchecked the CD/DVD from Boot Order.

Then start the machine once more and let it finish the first boot. At the end of booting you will get the current IP address of your PBX.

Make the ssh to this machine and apply following changes:

edit /etc/grub.conf
Comment out these 2 lines by putting a # at the beginning of the line:
#splashimage=(hd0,0)/grub/splash.xpm.gz
#hiddenmenu
Add these 2 lines:
serial —unit=0 —speed=9600 —word=8 —parity=no —stop=1
terminal —timeout=10 serial console
And add this to the end of each line that begins with “kernel”:
console=tty0 console=ttyS0,9600n8
(This tells Grub to direct console output to both the standard ttys (the ones you get with a keyboard and monitor) as well as the serial port (ttySx).)

Add this to the bottom of /etc/inittab:
S0:12345:respawn:/sbin/agetty ttyS0 9600 linux
(the “S0? is just a unique identifier; no two entries in inittab can start with the same thing. 12345 means all run levels (they correspond to /etc/rc2.d, rc3.d, etc) and respawn will ensure that it will accept another login after you log out.)

If you want to allow root to login over the console (versus logging in as a normal user and su-ing), add “ttyS0? to the bottom of /etc/securetty:
echo ttyS0 » /etc/securetty

edit /etc/sysconfig/init and change
BOOTUP=color
to
BOOTUP=serial
to prevent the graphical startup from blowing up your terminal.

If you have kudzu running (use chkconfig or look in /etc/rc3.d to see if it runs during boot):
edit /etc/sysconfig/kudzu
set SAFE=yes

OK so now you have to shutdown the machine and convert the virtualbox file system format to RAW. Go to location where you stored the image of your Trixbox and do the following command:

VBoxManage internalcommands converttoraw trixbox_alix.vdi trixbox_alix.img

After the conversion you have a RAW file which you can put on you CF card with the dd command. Plug you CF to your adapter and connect to PC. Find as which driver it is mounted and umount it and then copy the image:

dd if=trixbox_alix.img of=/dev/sdc

That’s all, take out the card, put in your Alix and wait around 3min and it will be ready to use.

My trixbox image for 8GB card can be downloaded from here:

http://min.us/miQ3uRoDs (437.5MB)

1 year ago on February 8th, 2011 at 2:56 am | Permalink