Disable Shotwell on Fedora + Gnome

Tags:

Found the answer to this conundrum with a little help from the Ubuntu forum but this answer works in Fedora with Gnome, too. Here's my remix of their answer:

To enable or disable automount open a terminal and type dconf-editor followed by the [Enter] key.

Browse to org.gnome.desktop.media-handling. A quick way to do this is to press Ctrl+F (for Find) and then type automount.

The automount key controls whether to automatically mount media. If set to true, then Nautilus will automatically mount media such as user-visible hard disks and removable media on start-up and media insertion. You probably want this on.

There is another key org.gnome.desktop.media-handling.automount-never. By checking this, you will disable Shotwell, and everything else, from running when devices are automounted. So check this to turn Shotwell off.

Recovering eth0 on Debian after VM clone

Tags:

After cloning a working Debian virtual machine, the new system would not bring up its Ethernet interface. This is because I checked VirtualBox's dialog, "Reset MAC address for network card" and got a new hardware Ethernet address.

Trying "ifup eth0" didn't work. I did an "ip addr" and saw that the only configured interface was now called eth1.

This is simple to solve. Edit the file /etc/udev/rules.d/70-persistent-net.rules and move the new MAC address (like "00-0F-35-01..." and so on) from the eth1 line back to eth0, erasing the previous address in the eth0 line. Then delete the remainder of the eth1 line, save, and reboot.

You should now have your eth0 back.

Perl Catalyst on a base Debian system

Tags:

This turns out to be amazingly easy, at least with Debian 7.3.

First, instead of MySQL, I followed instructions at the MariaDB site: Setting Up MariaDB Repositories. Then:

$ sudo apt-get install libcatalyst-modules-perl

which installed over 200 modules, but what do you know:

$ catalyst.pl Foo

creates a Foo Catalyst application under the current directory. Everything *Just Works. *Thanks to Debian and the folks who bring you Catalyst.

Further reading:

UPDATE (April 2014): Catalyst seems a bit heavy for most of my needs. I'm exploring mojolicious.

The VI and EMACS Rosetta Stone

Tags:

An updated version of the VI and Emacs Rosetta stone is now available in PDF form. The original HTML is here.

vi-thumb

Setting up VOIP on a DigitalOcean VPS

Tags:

The best way to get started with VoIP (Voice over Internet Protocol) is to set up a sandbox Asterisk server on a public IP address. To begin you can use your Gmail/Google Voice account for outgoing calls, and then attach your Asterisk to a full SIP connection for incoming and outging calls. For this I'm using a VPS (virtual private server) from Digital Ocean, running Ubuntu 13.10.

For complete control, we can download, compile, and install the latest version of Asterisk directly from the source (here). Generally we'll put this on more-or-less a standalone system, so let's to download and unpack into /usr/src:

cd /usr/src
wget http://downloads.asterisk.org/pub/telephony/asterisk/asterisk 11-current.tar.gz
tar xfz asterisk-11-current.tar.gz
cd asterisk-11.6.0

(The last will change according to your version.)

Before continuing, install required packages:

# apt-get install make libncurses-dev libxml2-dev sqlite3 libsqlite3-dev
# apt-get install libiksemel-dev  (for gtalk, jingle below)
# apt-get install libssl-dev  (for chan_sip)
# apt-get install subversion (for the mp3 addon)

Now, run the configure program to check dependencies.

./configure

Now, select the options and make sure we will have the required channel drivers, sip and gtalk:

make menuselect

Make sure that chan_sip, chan_gtalk and chan_jingle are available and selected. These are marked as "deprecated" but still work.

 **************************************************
 Asterisk Module and Build Option Selection
 **************************************************
      Press 'h' for help.

      Add-ons (See README-addons.txt)
      Applications
      Bridging Modules
      Call Detail Recording
      Channel Event Logging
--->  Channel Drivers
      Codec Translators
      Format Interpreters
      Dialplan Functions
      PBX Modules
      Resource Modules
      Test Modules
      Compiler Flags
      Voicemail Build Options
      Utilities
      AGI Samples
      Module Embedding
      Core Sound Packages
      Music On Hold File Packages
      Extras Sound Packages

The final step is to compile everything:

make
make install
make samples

Now the fun part -- configure the sip.conf and extensions.conf files in your working Asterisk system: these are found in /etc/asterisk. To get an Asterisk command-line, use the shell command asterisk -r:

# asterisk -r
Asterisk 11.6.0, Copyright (C) 1999 - 2013 Digium, Inc. and others.
Created by Mark Spencer <markster@digium.com>
Asterisk comes with ABSOLUTELY NO WARRANTY; type 'core show warranty' for details.
This is free software, with components licensed under the GNU General Public
License version 2 and other licenses; you are welcome to redistribute it under
certain conditions. Type 'core show license' for details.
=========================================================================
Connected to Asterisk 11.6.0 currently running on server (pid = 57157)
www2*CLI>

An excellent place to start is the Asterisk Wiki, under "Beginning Asterisk."