Wednesday, December 19, 2012

Replace Unity desktop with Gnome 3 on ubuntu 12.10
1. Install the Ubuntu GNOME packages 
sudo apt-get install ubuntu-gnome-desktop ubuntu-gnome-default-settings
sudo dpkg-reconfigure gdm
sudo apt-get remove ubuntu-settings
2. Install missing GNOME 3 packages 
64 bit only
sudo apt-get install gnome-documents gnome-boxes
3. Upgrade GNOME Control Center, Nautilus, Totem 
and other GNOME 3 packages to version 3.6.x 
upgrade gnome control center 
sudo add-apt-repository ppa:gnome3-team/gnome3   
4. Remove overlay scrollbars 
sudo apt-get remove overlay-scrollbar* 

Monday, December 17, 2012

Asterisk on pi reconfiguration


Next steps after downloading the image

Instructions on how to write the downloaded image to your card can be found here:
The image is only utilizing 4GB of your card, even if you bought a bigger one. On a bigger card, you can make more space available to your root partition by running on the console of your booted RPi:
Select the option expand_rootfs. If you rather prefer to do this manually, one of the easiest ways is using GParted on Linux. Details can be found here:

1. Determine hostname / IP address

Once your RPi is booted, you need to know it’s hostname or IP address for ssh login or to open the web GUI. On Windows computers, you can just use the hostname raspbx to access your RPi.
SSH login:
ssh root@raspbx
Web GUI:
On Macintosh, use raspbx.local instead:
ssh root@raspbx.local
Web GUI:
In case this is not successful you can check your router’s DHCP client list, and search for the IP associated with the name raspbx.
If this is still not working out, you can always just connect an HDMI monitor and USB keyboard, log in to the console with user root, password raspberry, and run the command:

2. Basic configuration

After your RPi has booted successfully, log in either on the console or by ssh with user root and password raspberry. Follow these steps to complete the initial configuration:
Choose your timezone:
dpkg-reconfigure tzdata
Configure locale settings:
dpkg-reconfigure locales
Configure keyboard settings (not needed when working with ssh only):
dpkg-reconfigure keyboard-configuration

3. Email setup

Email delivery from your RPi is needed if you plan to have voicemails sent to users by email. Email already works in the default configuration using Exim4 as MTA. By default, Exim is configured to directly send mails to the recipient MX hosts. This is however discouraged, as many email providers classify emails coming from dynamic IP adresses as spam. To avoid this, you need to set a smarthost. Unless you have an open SMTP server on your network that can be used as smarthost without authentication, you will need to specify SMTP authentication credentials as well. It is basically possible to use almost any publicly available freemailer as smarthost with the RPi. Have username and password as well as SMTP hostname (sometimes also referred to as outgoing mail server) of the email account you are going to use ready. Run on the console:
dpkg-reconfigure exim4-config
On the first configuration page select “mail sent by smarthost; no local mail”. On the following pages just keep the default values by pressing enter, until you reach the page starting with “Please enter the IP address or the host name of a mail server…”. Here, enter the SMTP hostname of your email provider. Again, keep default values on the remaining pages.
Then, edit the file passwd.client by running:
nano /etc/exim4/passwd.client
Add your credentials at the bottom of this file in the following format:
In most cases, the SMTP hostname used in this file is identical to the hostname used as smarthost before. If email fails to work, specify the reverse lookup of your email provider’s SMTP host IP address here. For Google Mail, this is currently
Some email providers also require you to use sender addresses identical to one of the public email adresses of your account. In this case, edit:
nano /etc/email-addresses
On the bottom of this file add:
This configures the sender address of all outgoing mail to
Finally, to activate your configuration run:
You can test your email setup with this command:
A test email should reach your inbox shortly.

4. Initial Asterisk setup

Point your browser to the RPi’s hostname or IP address (http://raspbx).
The default login to FreePBX is:
user: admin
password: admin
For inital setup please follow this guide:
Most of the configuration steps presented here apply to the RPi as well. If you are going to use SIP technology, you absolutely need to follow section 5, “Configure Asterisk SIP Settings”. After filling the Asterisk SIP Settings page, you need to go back to the console and run:
amportal restart
This step is only required once after Asterisk SIP Settings have been configured for the first time. For all other configuration changes just use the red apply config button in the GUI.

dpkg cheat info

trying to do a reinstall of a package still means some dpkg work.

here is a cheat sheet.

dpkg command cheat sheet for Debian Linux

dpkg is package manager for Debian Linux which is use to install/manage individual packages. Here is quick cheat sheet you will find handy while using dpkg at shell prompt:
Syntax Description Example
dpkg -i {.deb package} Install the package dpkg -i zip_2.31-3_i386.deb
dpkg -i {.deb package} Upgrade package if it is installed else install a fresh copy of package dpkg -i zip_2.31-3_i386.deb
dpkg -R {Directory-name} Install all packages recursively from directory dpkg -R /tmp/downloads
dpkg -r {package} Remove/Delete an installed package except configuration files dpkg -r zip
dpkg -P {package} Remove/Delete everything including configuration files dpkg -P apache-perl
dpkg -l List all installed packages, along with package version and short description dpkg -l
dokg -l | less
dpkg -l '*apache*'
dpkg -l | grep -i 'sudo'
dpkg -l {package} List individual installed packages, along with package version and short description dpkg -l apache-perl
dpkg -L {package} Find out files are provided by the installed package i.e. list where files were installed dpkg -L apache-perl
dpkg -L perl
dpkg -c {.Deb package} List files provided (or owned) by the package i.e. List all files inside debian .deb package file, very useful to find where files would be installed dpkg -c dc_1.06-19_i386.deb
dpkg -S {/path/to/file} Find what package owns the file i.e. find out what package does file belong dpkg -S /bin/netstat
dpkg -S /sbin/ippool
dpkg -p {package} Display details about package package group, version, maintainer, Architecture, display depends packages, description etc dpkg -p lsof
dpkg -s {package} | grep Status Find out if Debian package is installed or not (status) dpkg -s lsof | grep Status
{package} - Replace with actual package name

Asterisk for raspberry PI

here is the home page for this effort.  Not simple, for sure


the ITU code for the US is 1 (as in the digit you dial for a country code).  for some reason one install attempt I made came up with 61 for Australia, and offered the code for Italy as well, both useless and wrong.

Linode library link

sample page is for setting up voip services server, and asterisk, but looks nice