Archive:FreePBX Distribution

Revision as of 22:31, 6 March 2016 by Sam (talk | contribs) (Sam moved page Asterisk VoIP Server to AsteriskNOW!: Complete system change)

AsteriskNOW! is a fully fledged VoIP server allowing complete customisation to your needs and works with most setups. It is an appliance, with a complete Linux setup and web manager to allow easy administration.

On the server, we have implemented AsteriskNOW! 6.12.65-26 distribution and Asterisk 13.x series. This is the latest version of Asterisk and is a LTS release so will be supported well into the future with fixes (slated to be supported until 2018). This is a complete distribution and so needs to be installed on a machine. We will be using Linux tools to install the distribution as a virtual machine.

Preparing the host machine

Enable Intel VT-d extensions

With this method we need Intel VT-d extensions enabled so we can add the physical network card to the virtual machine

  1. Enable Intel VT-d in the system BIOS. It may be called Intel Virtaulization Extensions or something similar. We must enabled both Intel VT-x and Intel VT-d. Intel VT-d is a later version of Intel VT-x and allows physical hardware to be taken over and used by a virtual machine and there other memory and performance enhancements also. Intel VT-d may only be available if you have a recent machine.
  2. The extensions need to be enabled in the system kernel on the host machine as by default they are not enabled. Boot the machine, login and open YaST. Type your root password if needed.
  3. Under 'System', open 'Boot Loader'
  4. Change to the 'Kernel Parameters' tab
  5. After the last option on 'Optional Kernel Command Line Parameter', add intel_iommu=on.
  6. Click 'Accept'
  7. Reboot the machine

Install Virtual Machine components

  1. Login and open YaST. Type your root password if needed.
  2. Under 'Virtualization', click 'Install Hypervisor and Tools'
  3. Under 'KVM Hypervisor', tick both 'KVM server' and 'KVM tools'
  4. Click 'Accept'. The components will install.
  5. When finished, reboot the machine as kernel components will have been changed.

Preparing the Virtual Machine

KVM Connection

  1. On the Kickstart Menu, type 'virt'. When displayed, open 'Virtual Machine Manager'
  2. Type in the root password if needed.
  3. First we need to create the connection. Click the 'File' menu then click '+ Add Connection'
  4. Make sure 'QEMU/KVM' is selected. No other options are needed. Then click 'Connect'
  5. You should now see 'QEMU/KVM' in the list with nothing underneath.

Adding the virtual machine

  1. To make a virtual machine, click the 'File' menu then clock 'New virtual machine'.
  2. As we will be installing AsteriskNOW! from a DVD image we downloaded, under 'Choose how you would like to install the operating system', select 'Local install media (ISO image or CDROM)'. In the 'Architecture' dropdown, make sure 'x86_64' is selected. Then click '> Forward'.
  3. Under 'Locate your install media', select 'Use ISO image' then click 'Browse'
  4. Click 'Browse Local'. Goto your Downloads directory and select the AsteriskNOW! image, the click 'Open'.
  5. Make sure the image is still selected in the list and click 'Choose Volume'.
  6. As this is a customised version of Linux, we cannot use the automatic detection to find the operating system. Unselect 'Automatically detect operating system based on install media' (will have 'OS type: unknown' and 'Version: unknown' underneath).
  7. In OS type, select 'Linux'. In Version, select 'CentOS 6.5'. Then click 'Forward'.
  8. Under 'Choose Memory and CPU settings', in 'Memory (RAM)', add '2048 MiB'. Under 'CPUs', make sure it says '1'. Then click 'Forward'.
  9. Make sure 'Enable storage for this virtual machine' is selected. Under 'Create a disk image for the virtual machine' add '20.0 GiB'. Then click 'Forward'.
  10. Under 'Name', type 'AsteriskNOW' (don't add the exclamation point - this causes problems later!)
  11. Under the 'Network Selection' dropdown, select any 'Host Device xxxxx: macvtap'. This doesn't matter which one is selected, but one must be selected to get the machine started. Press 'Finish'.
  12. If all is well, you should see a quick progress bar and then the machine will start, booting from the DVD image.
  13. At this point, select the Power dropdown menu from the top and select 'Force off'. You will see a warning, press 'Yes' to stop the machine. You will now see 'Guest not running'.

Configuring the machine

  1. Press the 'i' button at the top to switch from display to settings
  2. Under 'CPUs', check under 'Configuration' that the Model is 'Haswell-noTSX'.
  3. Click 'NIC :xx:xx:xx'. Click 'Remove' at the bottom to remove the network emulation and click 'Yes' to agree. We will be adding the separate physical network card next.
  4. Click '+ Add Hardware'. Click 'PCI Host Device'. You will need to find in the list the network card you want the guest to use and then click 'Finish'. It will be added down the side as 'PCI xxxx:xx:xx.x'.
  5. We won't be needing a sound card. Click 'Sound: ich6' and then 'Remove'. Click 'Yes' to agree.
  6. Goto 'IDE CDROM 1' and click 'Connect' if it is there. If not skip to the next step. Locate the AsteriskNOW image and click 'Choose Volume'.
  7. Goto 'Boot Options'. Make sure that the CD-ROM drive is at the top of the list.
  8. Once done, the machine is configured and ready to go. Click 'Apply' if it isn't greyed out. Press the screen icon next to the 'i' button at the top and then click the play button to start the machine up.

Installing AsteriskNOW! on the virtual machine

  1. On the host machine, download the latest 64-bit DVD image of AsteriskNOW! (http://www.asterisk.org/downloads/asterisknow}
  2. Attached the DVD images to a free optical drive on the virtual machine.
  3. Change the boot order so that the optical drive is at the top of the boot list.
  4. Start the virtual machine.
  5. When the boot menu appears, Under 'FreePBX 6.12.65 with Asterisk 13 - EXPERIMENTAL!' header, select 'Full Install -- No RAID'.
    • Disregard the experimental header. When this version was released, Asterisk 13 was new and considered experimental. Once updated, Asterisk 13 is pretty mature and not considered experimental anymore.
    • There is no need to choose RAID if using a virtual machine unless you are using a virtual machine or have an exotic setup to make the hard drives on 2 different physical hard drives.
  6. Once the system is booted, you will be presented with options to configure your network
    • Make sure 'Enable IPv4 support' and 'Dynamic IP configuration (DHCP)' are both selected.
    • Unselect 'Enable IPv6 support'
    • Hit 'OK'
  7. On the next option, select the correct time zone
    • As this virtual machine is installed on a Linux host, select 'System clock uses UTC'
    • Select Europe/London (tip: press 'E' on the keyboard to jump down to 'E' on the list.)
    • Hit 'OK'
  8. On the next option, type in a password to use for the system.
  9. After you hit 'OK', the system will start to install. This may take a long while. The installer may look as though it has frozen at certain points. However it is important to be patient as a few of the packages take a long time to install.
  10. When the install is finished, the machine will reboot. When it comes up with the boot menu, this will be the installation discs boot menu.
    • 'Force Off' the virtual machine. This is safe as the machine is not fully running yet.
    • From the boot order, remove the optical drive and make sure the hard drive is placed to the top.
    • Start the virtual machine again.
  11. On first boot, it will start downloading updates for FreePBX. This may take a while.
  12. Once finished, it will leave you at the command prompt. Type 'root' for the username and the password you selected during install for password.
  13. That's it, AsteriskNOW! is installed!