Home Pauline's Pages Howto Articles Uniquely NZ Small Firms Search
Height Padding
Diary of a Homepage
Part 24 (January 2013 ->)

Part 1 (February - June 1996) || Part 2 (June - September 1996) || Part 3 (October 1996 - March 1997) || Part 4 (April 1997 - December 1997) || Part 5 (January 1998 - December 1998) || Part 6 (January - December 1999) || Part 7 (January 2000 - December 2001) || Part 8 (January 2002 - June 2003) || Part 9 (June 2003 - August 2003) || Part 10 (August 2003 - April 2007) || Part 11 (May 2007 - September 2007) || Part 12 (October 2007 -December 2007) || Part 13 (January 2008 - August 2008) || Part 14 (September 2008 -> June 2009) || Part 15 (July 2009 -> August 2009) || Part 16 (September 2009 -> December 2009) || Part 17  (January 2010 -> October 2010 ) || Part 18 (November 2010 - December 2010) || Part 19 (January 2011 - September 2011) || Part 20 (October 2011 - March 2012) || Part 21 (April 2012 - July 2012) || Part 22 (August - September 2012 ) || Part 23 (October 2012 - December 2012) || Part 24 (January 2013 - December 2013) || Part 25 (January 2014 - December 2014 || Part 26 (January 2015 - December 2015 || Part 27 (January 2016 - October 2016) || Part 28 (November 2016 -> ) || Back to the home page

24th January 2013

Basic PDF Editing under Linux - PDF-Shuffler and PDFTK

We recently received a large PDF scan of a document which unfortunately had a number of pages missed out and some duplicates. Rather than ask for it all to be redone I had a look to see what the current state of PDF tools was for Linux.

PDF-Shuffler. I found a tool which was ideal for this task in PDF-Shuffler which is in the Ubuntu repositories. PDF-Shuffler is, to quote, "a small application which allows one to merge or split pdf documents and rotate, crop and rearrange their pages using an interactive and intuitive graphical interface". Ichecked and used it to Input and Append PDFs, drag the individual pages into the correct order, delete pages and rotate them before saving them which is exactly what I needed and is perfect for tidying up after scanning a document with a modern scanner with pdf output

pdftk (PDF Toolkit) is a command-line tool which enables you to edit pdf files. pdftk is not only freely available on Linux but also on MS Windows and MacOS X. It can be installed in Ubuntu Linux by using the Synaptic Package Manager or your distributions Software Centre. If you're just doing something really easy like clipping pages out or reordering pages, pdftk is great although it's a command line tool.

For example, to remove page 4 of an 8 page pdf (example.pdf), use the following:
Code:

pdftk example.pdf cat 1-3 5-end output new_pdf_file.pdf

To combine pdf's first_file.pdf and second_file.pdf into first_and_second_file.pdf, so the following:
Code:

pdftk first.pdf second.pdf cat output first_and_second.pdf

pdftk overall is more powerful although much less convenient than PDF-Shuffle as one can see from the specification of pdftk from Linux Synaptic Package Manager. If PDF is electronic paper, then pdftk is an electronic stapler-remover, hole-punch, binder, secret-decoder-ring, and X-Ray-glasses. Pdftk is a simple tool for doing everyday things with PDF documents. Keep one in the top drawer of your desktop and use it to:

- Merge PDF documents
- Split PDF pages into a new document
- Decrypt input as necessary (password required)
- Encrypt output as desired
- Fill PDF Forms with FDF Data and/or Flatten Forms
- Apply a Background Watermark
- Report PDF on metrics, including metadata and bookmarks
- Update PDF Metadata
- Attach Files to PDF Pages or the PDF Document
- Unpack PDF Attachments
- Burst a PDF document into single pages
- Uncompress and re-compress page streams
- Repair corrupted PDF (where possible)

Also see http://xmodulo.com/2012/06/how-to-edit-pdf-file-for-free.html

May 1st 2013

Missing toolbar in Wammu in Ubuntu 12.04 - solution when using Cinnamon

This is caused by the Global Application Menu used in Unity conflicting with Wammu, in particular with appmenu-gtk. I am running Cinnamon so it is possible to remove the Global Menu feature completely using synaptic and searching for appmenu and removing appmenu-gtk appmenu-gtk3 and appmenu-qt or, in a terminal.

sudo apt-get purge appmenu-gtk appmenu-gtk3 appmenu-qt

If you are running Unity try just removing appmenu-gtk

May 14th 2013

Vodafone (Huawei) R205 Mobile WiFi (MiFi)

This is the perfect device for accessing the internet on the move and has all the advantages of a USB Broadband USB Dongle but without needing a physical connection so it can be placed wherever the signal is best as it connects via WiFi. In addition it can serve up to 5 computers, smart phones and tablets simultaneously. It is controlled via a web interface so it is almost totally independent of the operating system in use. It contains a full router and firewall and, although not publicised, it can be used to network your computers just as with a normal wifi router. You can send and receive TXTs via the web interface. You can also access storage on an optional miniSSD card via the web interface - ineligant but possible. There is a small display panel on the device which displays not only the network, signal strength and connection type (GPRS EDGE or 3g) and battery status but also the cummulative data used, the number of devices connected by Wifi and the number of unread TXTs. It comes with a USB charging lead and mains adapter

I bought mine in NZ for $99 (£55) with 2 Gbytes data with a three month lifetime. NZ Vodafone products are normally unlocked so I could change to a Vodafone UK SIM on my return which I have set up on a Text and Web Prepay tariff giving 300 TXTs and 500mbytes lasting for a month after every £10 topup. I also checked it works with an O2 SIM - use on O2 needed configuration of the APN (payandgo.o2.co.uk), number (*99#) username (payandgo) and password (password) whilst Vodafone SIMs seem to autoconfigure the R205 and do not need the Custom settings.

If you need custom settings for a non Vodafone SIM then the APN etc are set by loging in (default password is admin) which gives an increased numer of screens. It can then be reached by Mobile Wifi -> Mobile Broadband -> Mobile Broadband Connection Settings and selecting Custom under Account Type . The APN is esential and the number should be *99# The DNS settings should be blank. The Security is usually PAP and the user and password are usually not checked. For Vodafone I use web web and O2 payandgo password. Automatic connection is fine if you use the R205 plugged in for power - if you want to conserve power you can manually connect an disconnect on the entry page (with or without the password) although it has clever power saving modes.

I have checked its use as as a router to network machines and have found no limitations compaired to a normal wifi router. I have mounted file systems using ssh and syncronised using Unison as well as normal networking through the file manager.

25th May 2013

Mint 15 Olivia Release candidate with Cinnamon 1.8

I have been running Mint 15 as a LiveUSB with persistence which gives me 4 gbytes available for extras in the root and the home folders which is plenty to try out various essential features, load updates and programs etc. Overall it is much better than the Ubuntu 12.04 with Cinnamon 1.8 system I am running and is much faster in producing menus and has an overall quick feel despite being on a USB stick. One of the first areas I looked at was bluetooth as I need it to transfer music to my boat hifi when on the move and to communicate with my phones for internet access. In doing so I have identified a serious problem in one area which is very important to me which is using my mobile phone(s) to give internet access via a bluetooth connection. My phones are on pay as you go Text and Web tariffs which provide me with 500 mbytes and 300 txts a month when I top them by £10 which is accessible for use on the computer if I use their built in bluetooth modems. This was therefore one of the first areas I investigated. The recent versions of ubuntu have had very easy access to bluetooth including creation of connections which appear in the network manager. Unfortunately this mechanism has a bug which locks Ubuntu 13.04 systems using the Linux 3.8.0 3.8.1 and 3.8.2 kernels to panic and lock the machine up. This also true for Mint which is derived from Ubuntu. I have there decided to include a long section detailing the problem and an alternative method of connection based on the Gnome-PPP program which I have been using extensively for 7 years - how time passes! The following is largely based round the write-up in Ubuntu Linux on the Move and will be used to update it in due course.

Bluetooth with Mint 15 Olivia, Cinnamon 1.8 and Ubuntu 13.04

I use Bluetooth to connect to two main classes of devices - phones to give mobile internet access using the data allowances available with many phone tarriffs, and, more recently, to connect to an bluetooth audio receiver (BTR006) to allow me to play music through the hifi system at home and on the boat without trailing cables. I have previously written about various ways of connecting to phones such as the Sony Ericsson T610, typical of older phones, The XDA Pro and Palm Treo typical of Windows Mobile Phones and more recently the Blackberry Bold 9700. The latest Bluetooth software should make connection of most devices very easy and, in theory, you can make a dial up connection to Bluetooth enable phones which is intergrated into the network manager in a few clicks of the mouse. In practice it often turns out to be more difficult than that and the best or only way to make a dial up internet connection is still to use an old piece of software called Gnome-PPP.

Bluetooth Basics and Pairing under the Cinnamon Desktop

Bluetooth is an excellent way to send contacts and files between machines and also allows the modem in one device to be used by another. Before you can do this the various devices must be 'paired' - this means that you set up a 'PIN' on both to give a secure communication without anybody else being able to hijack the connection which is important when one is a computer or mobile phone. The other security feature is that once paired you stop your devices being 'discovered' by other peoples machines which are searching for devices with Bluetooth (BT) turned on. This all sounds a bit complex and it does take a little while the first time.

When a Bluetooth dongle is inserted or a built in Bluetooth device is turned on a Bluetooth icon appears in the panel or system tray in most systems - in Cinnamon this is an applet which is normally installed by default but it if it does not appear you may need to add the Bluetooth Applet.

The first activity is to pair the Phone or Mobile Device to the computer. The way Bluetooth is paired varies a little between devices but in general it is initiated from the computer end but the device often has to be placed into the correct mode first. In the case of the Blackberry it is 'Listen' for a device to find me, on other devices it may be called 'Discoverable' and normally the mode is timed out after 2 minutes if pairing does not take place.

Using a BTR006 BlueTooth audio Receiver

Let us take a typical example of an audio device - an audio device does not need very high security so typically they have a preset PIN which is often 0000 but need to be made receptive to pairing for a short time. In the case of the BTR006 which is an audio input device to connect to hifi etc through a 3.5mm jack there is a single button and led to control it. Holding the button for 3-5 seconds turns it on. Holding for 10 seconds puts it into a special pairing mode where it is discoverable and it responds with a PIN of 0000 for 2 minutes. Pairing is now very simple - clicking on the Bluetooth Applet gives a menu which includes Set up a New Device which takes one to a Wizard where the second screen searches for and displays all unpaired devices and you highlight the BTR006 and on the PIN options one selects fixed and 0000 and continue and that is all that is needed. From now on the device will automatically be connected when the computer and BTR006 are turned on and within range. You will see a double blue flash every 5 seconds on the BTR006 in that case rather than the single flashes when it is just turned on and it will show up as an alternative audio device which you can select instead of the audio output or built in speakers.

Making a Dial Up connection on a Bluetooth Enabled Phone

1. Pairing a phone to the computer

In this case the pairing is more complicated as better security is required than offered by a fixed PIN and this has to be entered on both the computer and the phone. Again it is most easily initiated from the computer end and the wizard offers an automatic setting which generates a 6 figure random PIN. The phone end first has to be switched into 'discoverable mode' (this will vary from phone to phone) and then you will get a screen on the phone where you enter the PIN which is generated on the computer.

At this point the wizard will confirm the phone has been paired and offer a box you can tick to make a dial up connection - ticking this will enter a further series of screens where the phone will be checked and you provide information on the mobile operator to allow the connection to be set up ( and ultimately be available in network manager) or you can enter the name of the connection and the APN to manually complete the set up. Once made the connection settings can not be edited or deleted so if you get them wrong you have to unpair the phone and start again or make an additional manual set up with a different name. This set up method providing entries into the network manager worked well with my T610 with earlier versions of Ubuntu <13.04) but there is a catastrophic bug at present (May 2013) which kills the machine when you disconnect so we are back to Gnome-PPP until it is cured.

PPP Bug in Kernel 3.8.0 used in Ubuntu 13.04 Raring and Mint 15 Olivia

There is currently a serious bug affecting Ubuntu 13.04 and hence Mint 15 reported as "Kernel Panic in 3.8.0, 3.8.1 & 3.8.2 when diconnecting from network manager, using ppp0 to connect to net" on launchpad. This causes a kernel panic and a complete lockup of the machine which can only be cleared by a hardware reset (hold power button down until machine restarts) when one disconnects a bluetooth mobile phone connection to the internet. The connection MUST be disconnected at the phone end to avoid this.

2. Finding the Bluetooth address and Dial Up networking Channel in your phone

Once you have Paired the phone and the computer you need to find out several pieces of information to enable you to set up the connection to the modem in the phone so you can set up a configuration file which is used by the system to set up what looks like a local serial device and can be used by other programs to connect to the phone. You can scan the Bluetooth connections looking for Dial Up Network (DUN) connections (modems) in the phones by typing the following strings in a terminal, in this example both my T610 phone and the XDA have been paired and are with range.

hcitool scan
sdptool search DUN

which gives an output like this for with both my T610 Phone and O2 XDA Exec paired and turned on:

pcurtis@satellite:~$ hcitool scan
Scanning ...
00:12:37:C6:81:31 XDA
00:0E:07:2C:E8:82 T610
pcurtis@satellite:~$ sdptool search DUN
Inquiring ...
Searching for DUN on 00:12:37:C6:81:31 ...
Service Name: Dial-up Networking
Service RecHandle: 0x10003
Service Class ID List:
"Dialup Networking" (0x1103)
Protocol Descriptor List:
"L2CAP" (0x0100)
"RFCOMM" (0x0003)
Channel: 4
Language Base Attr List:
code_ISO639: 0x656e
encoding: 0x6a
base_offset: 0x100
Profile Descriptor List:
"Dialup Networking" (0x1103)
Version: 0x0100
Searching for DUN on 00:0E:07:2C:E8:82 ...
Service Name: Dial-up Networking
Service RecHandle: 0x10000
Service Class ID List:
"Dialup Networking" (0x1103)
"Generic Networking" (0x1201)
Protocol Descriptor List:
"L2CAP" (0x0100)
"RFCOMM" (0x0003)
Channel: 1
Profile Descriptor List:
"Dialup Networking" (0x1103)
Version: 0x0100

pcurtis@satellite:~$

3. Creating the Bluetooth Phone Dial-Up Network Devices via the /etc/bluetooth/rfcomm.conf file

We now have to create a system (script) file which is used to create the serial devices that appear in /dev which can then be used via Modem connection programs such as Gnome-PPP to make a serial bluetooth connection to the modems built into the phones. The important pieces of information in this file are the addresses of the bluetooth devices and the channel numbers for the DUN connections. The bind command tells the system to create the devices automatically when the sytem starts and the script file is run as part of the bluetooth initilisation.

It is safest to make a copy then edit the existing 'default' example /etc/bluetooth/rfcomm.conf file. You will need to have root priviledges to edit the file so in a terminal do:

gksudo gedit /etc/bluetooth/rfcomm.conf

The following is the contents of my file which contains the configuration information for all my phones namely a T610, an o2 XDA Exec, a Palm Treo and the Blackberry Bold 9700.

# RFCOMM configuration file /etc/bluetooth/rfcomm.conf

rfcomm0 {
bind yes;
# Bluetooth address of T610
device 00:0E:07:2C:E8:82 ;
# RFCOMM channel for the T610
channel 1;
# Description of the connection
comment "T610 Dial-up Networking via Bluetooth";
}

rfcomm1 {
bind yes;
# Bluetooth address of XDA
device 00:12:D2:8E:A1:08 ;
# RFCOMM channel for the XDA
channel 4;
# Description of the connection
comment "XDA Dial-up Networking via Bluetooth";
}

rfcomm2 {
bind yes;
# Bluetooth address of Treo
device 00:12:D1:B2:CC:9B ;
# RFCOMM channel for the Treo
channel 3;
# Description of the connection
comment "Treo Dial-up Networking via Bluetooth";
}

rfcomm3 {
bind yes;
# Bluetooth address of Blackberry
device F4:0B:93:FC:33:D0 ;
# RFCOMM channel for the Blackberry
channel 1;
# Description of the connection
comment "Blackberry Dial-up Networking via Bluetooth";
}

Remember when testing that whenever you change a configuration file such as the above which you are going to use you must reboot the machine or restart the relevant sub-system which runs the script file, in this case by:

sudo service bluetooth restart

The end result of this stage is that we have created a number of extra serial devices that appear in /dev which can be used via Modem connection programs such as Gnome-PPP to make a serial bluetooth connection to the modems built into the phones. The commands are a superset of the commands sent to old fashioned serial modems for telephone dial up going back 20 years or more. Gnome-PPP was created for such modems but is still perfectly able to handle the latest phones although it will need a little setting up.

4. Setting the permissions to allow users modem access to the Internet.

Many of the modem related activities need administrative privileges. When you install Ubuntu or its derivatives such as Mint, the first user is automatically added to the admin group, allowing that user to make changes as the super user (root) by typing in their password and a number of other important groups - groups are the mechanism used to provide/limit the privileges of users. Not all versions automatically provide the privileges to use modems or connect to the internet via a modem even to the first user and it is best to check. If you have several users on the machine it is useful to know how to give them the ability to use sudo as well as the modem related privileges. This can be done using the Users and Groups which is within System Settings - type groups into the search dialog in the Menu in Cinnamon or the Dash in Ubuntu Unity.

First click Advanced Settings and unlock with your password and highlight your user name and click on the User Privileges Tab check the box that says "Administer the System " which adds you to the admin group and also tick 'Connect to Internet using a Modem' which adds you to the dip group and 'Use Modems' which adds you to the dialout group. These changes do not come into effect immediately and you need to restart or logout and back in as the same user.

However under Mint the settings via Users has been castrated and you can no longer set up or change individual Groups so it is back to the terminal. You can check the groups you are in (and get some other useful information), in a terminal, by typing:

id

The output from id on my system which works with gnome-PPP looks like:

pcurtis@vortex-ubuntu:~$ id
uid=1000(pcurtis) gid=1000(pcurtis) groups=4(adm),20(dialout),21(fax),24(cdrom),
25(floppy), 26(tape),29(audio),30(dip),44(video),46(plugdev), 104(fuse),
105(lpadmin),112(netdev),119(admin),122(sambashare),1000(pcurtis)
pcurtis@vortex-ubuntu:~$

The following two commands will add YOURUSERNAME to the dip and dialup groups which are required to use gnome-PPP:

sudo adduser $LOGNAME dip
sudo adduser $LOGNAME dialout

$LOGNAME is replaced by the name you used to login. If you need other users to have access you will need to replace it with their username and repeat - make sure the usernames are correct, otherwise you will create them! Remember to restart to activate these changes and check again with id

An alternative is to use "Users and Groups" in Settings which is now available in Cinnamon 2.0 (Mint 16). If you can not find it you can also install gnome-system-tools by running in a terminl:

sudo apt-get install gnome-system-tools

and restart the system then either run it from the menus, or in a terminal with:

users-admin

Note this does not need sudo

5. Changes required in /etc/ppp/options to prevent the connection timing out.

Some other options need to be set for many mobile network connections to prevent them timing out with some operators. These are not possible via the GUI interface and I change them in the the 'master' pppd (I think that stands for ppp daemon) set up file which is /etc/ppp/options so the changes apply to all users. We can look at the current options which are set by:

sudo egrep -v '#|^ *$' /etc/ppp/options

It is desirable to make a backup before editing the /etc/ppp/options file so to make a copy and open a terminal:

sudo cp /etc/ppp/options /etc/ppp/options_bak
sudo gedit /etc/ppp/options

I have made three changes to the file. The first two are essential for most GPRS connections and disable the sending and checking of the echo response sent to check the connection is alive - this is a hang over from modems using a telephone line to identify disconnection but the echo is not implemented by most mobile service providers and the default result is that 4 echo response requests are sent at 30 second intervals and after the 4th failure to receive a response the connection is broken. If you are disconnected after 2 minutes that is the cause. The new values of 0 inhibit the sending and checking:

lcp-echo-failure 0
lcp-echo-interval 0

The third change is essential for the Vodafone PCMCIA Connect Card but does not impact other mobile connections so I do it routinely. It involves disabling negotiation of Van Jacobson style IP header compression by un-commenting

-vj

6. Installing Gnome-PPP - additional steps in Mint 14 upwards

GnomePPP is not installed by default but it is present within the default installation of Linux Mint. Your Linux Mint system comes with a local repository which is disabled by default. You can enable it by using the "Software Sources" tool from the menu. This repository contains GnomePPP as well as a collection of drivers. You can then search for and install using the Synaptic Package Manager or the Software Center.

7. Change permissions on two files ( /etc/ppp/pap-secrets and /etc/ppp/chap-secrets )

If you want to save the username and password in gnome-ppp they are saved in /etc/ppp/pap-secrets and etc/ppp/chap-secrets and you need to give read and write access to them from group dip - if you do not then you will get an warning message in the connection log. In most cases this does not matter as the username and password are not actually used or checked by most mobile internet providers - they know who you are from the SIM which is already registered before you can access data. Even so it is best to set these permissions. I use a root file browser which is started in a terminal in Ubuntu by:

gksudo nautilus

or in Mint/Cinnamon by

gksudo nemo

You then navigate to folder /etc/ppp and right click on pap-secrets -> Properties -> Permissions tab then select dip from the drop down menu for Group and and then select read and write under Access. Repeat for chap-secrets. The annoying warning messages should now disappear.

In Mint/Cinnamon you do not have to use a terminal as you can navigate to the folder and on the right click menu is the option to Open as Root - another step forwards in Cinnamon over Unity!

A third alternative which is good if you are happy with using the termal is to do:

sudo chgrp -v dip /etc/ppp/*ap-secrets && sudo chmod -v 770 /etc/ppp/*ap-secrets

8. Gather information on GPRS/3G access for your Mobile Telephone and tariff

GPRS, EDGE and 3G access on a mobile phone does not involve use of a normal telephone number but uses a special code in place of the number to access internal 'registers' in the phone which contain information on the connection such as the APN (Access Point Node), login name, password and possibly an IP and a DNS address. Each phone will be slightly different but in general they will contain a set of registers sufficient to hold the configuration settings for about 8 connections (sometimes described as accounts or profiles in the manufacturers literature). Each of these will have a CID (connection ID) associated which identifies which one is to be used.   A special code is sent to the phone instead of the usual access number.  The number used is *99***X# where X is the single digit CID number referred to above. The default connection (CID 1) is almost always used and can also be accessed by *99#. 

The usual way to set up a phone used as a modem is for the APN to be loaded using a modem initialisation string before the connection is initiated. There are also other  options which can be set up for a GPRS/EDGE/3G PPP protocol connection (the usual standard).

9. Configuring Gnome-PPP

Gnome-PPP has the ability to send a number of modem inititialisation strings before 'dialing' the connection. It can also set up various protocols and useful options, for example, waiting for a dialing tone before dialling and setting up automatic or manual DNS (Domain Name Servers). The main configuration of Gnome-PPP is done by a GUI interface and is all fairly obvious especially if you are making a simple land-line Dial-Up connection. The only thing missing with gnome-ppp is help. It uses its own configuration file $HOME/.wvdial.conf which it is reported can have additions despite the warnings not to modify by hand. 

Coming on to mobile phones you need to set up the APN via an initialisation string option on the second tab of the Setup Screen, and then use a special code in place of the phone number. Using Vodafone UK PrePay on the T610 as an example the Initialisation string 2 is set to load the APN into the the default CID 1:

Init 3 AT+CGDCONT=1,"IP","pp.vodafone.co.uk"

and the phone code used is

*99#

For other providers replace the pp.vodafone.co.uk with their APN (eg Vodafone UK Contract is internet, Guernsey Wave is pepper and Vodafone NZ is www.vodafone.net.nz)

In general the username and passwords are not checked but for most phones something needs to be present - check with your provider. I use web and web with vodafone. There are more details on my Global Communications and Computing page

My typical settings on the Setup screens for gnome-ppp are:

Summary of setting up to use a Bluetooth Modem in a Phone using Gnome-PPP with check list.

The whole process I have described above looks very complex but I have been following my instructions above on every machine I have over six years. It probably takes about 15-30 minutes the first time. The main steps are:

  1. Pair the computer and phone - uses Bluetooth entry in System Settings directly or via the icon in the panel.
  2. Get details of the Bluetooth device (Address and Channel number for Modem) - uses two terminal commands.
  3. Create or edit a file /etc/bluetooth/rfcomm.conf which the system uses to create the devices to access the modems by bluetooth ( /dev/rfcomm0 etc ) using above Addresses and Channel Numbers found above. Editing as root needed of two lines for each phone.
  4. Give yourself as user the permissions to use modems and access the internet via a modem ie you need to add yourself to dip and dialout groups. Two terminal commands in Mint or using a GUI in Ubuntu.
  5. Change a system file ( /etc/ppp/options ) in three places to prevent timeouts after 2 minutes on Mobile phone connections and remove header compression. Edit as root.
  6. Install Gnome-PPP - needs an extra repository enabling in Mint.
  7. Change permissions on two files ( /etc/ppp/pap-secrets and /etc/ppp/chap-secrets ) so they are writable by the DIP group - not essential in most cases but prevents a warning in the log file. Easiest way is to run nautilus or nemo as root.
  8. Gather information on GPRS/3G access for your Mobile Telephone and tariff - you must have the APN and sometimes a username and password is also required.
  9. Configure Gnome-PPP in a GUI with three subsettings screens.

I hope the above shows it is not an impossible task and the skills needed which are a basic understanding of linux, its file system, the terminal and use of sudo to work on system files.

28th May 2013

Enhanced Network Speed Applet for Cinnamon

This is one of the most important Applets for me as it enables me to monitor my Internet Connection when mobile and see how much data I am using and if there is any unexpected activity as well as finding out the speed of the connections. It however had one shortfall for me in that it only monitors connections which have been made by the Cinnamon Network Manager. It generates the list of connections in the right click popup menu from those known to the Network Manager which is fine for most people using modern hardware. Unfortunately some of the latest hardware lacks drivers which network Manager recognises such as USB mobile Broadband Dongles. At present one can not make bluetooth connections to mobile phones through the Network Manager under Ubuntu 13.04 Raring or Cinnamon 15 Olivia as there is a serious bug known bug in the Linux Kernel they use (3.8.0) which leads to a Kernel Panic when you disconnect and the only way out seems to be to hold the power button down with loss of all data you are working on.

Under these circumstances there is still a role for using software such as Gnome-PPP to make connections for Bluetooth Modems and USB Mobile Broadband dongles and using the manufacturers connection software and a need to the Network Speed Applet to be able to monitor, in particular, ppp0 connections (Point to Point Protocol).

I therefore lookied at the code of the Applet and identified the areas that need to be changed to allow one to monitor the ppp0 interface even when the connection has been made independently of the Network Manager. This involved changing the checks to make sure that saved interfaces were connected when the Applet is started to ignore the ppp0 interface where it is likely to be connected and disconnected on demand and to add a new menu item to be able to monitor it regardless of how it was connected.

The changed sections of the file follow:

let lastUsedInterface = this.settings.lastUsedInterface;
// Following line has an extra condition for ppp0
if(this.isInterfaceAvailable(lastUsedInterface) || lastUsedInterface == "ppp0") {
this.setMonitoredInterface(lastUsedInterface);
}

buildContextMenu: function() {
this._applet_context_menu.removeAll();
this._applet_context_menu.addMenuItem(new PopupMenu.PopupMenuItem("Select a network manager interface to be monitored:", { reactive: false }));

let interfaces = this.getInterfaces();
if(interfaces!=null) {
for(let i=0; i<interfaces.length; i++) {
let name = interfaces[i].get_iface();
let menuitem = new PopupMenu.PopupMenuItem(name);
menuitem.connect('activate', Lang.bind(this, function() {
this.settings.lastUsedInterface = name;
this.saveSettings();
this.setMonitoredInterface(name);
}));
this._applet_context_menu.addMenuItem(menuitem);
}
}
// Extra Code for ppp0 starts
this._applet_context_menu.addMenuItem(new PopupMenu.PopupSeparatorMenuItem());
this._applet_context_menu.addMenuItem(new PopupMenu.PopupMenuItem("Select an independent interface to be monitored:", { reactive: false }));
let name = "ppp0";
let menuitem = new PopupMenu.PopupMenuItem(name);
menuitem.connect('activate', Lang.bind(this, function() {
this.settings.lastUsedInterface = name;
this.saveSettings();
this.setMonitoredInterface(name);
}));
this._applet_context_menu.addMenuItem(menuitem)
// Extra Code for ppp0 ends

this._applet_context_menu.addMenuItem(new PopupMenu.PopupSeparatorMenuItem());
let menuitem = new PopupMenu.PopupMenuItem("Settings");
menuitem.connect('activate', Lang.bind(this, this.openSettings));
this._applet_context_menu.addMenuItem(menuitem);
},

Unfortunately the tabbed indentation has been lost in the above but the insertions should be clear.

The resulting menu looks like this:

You can see the expected ethernet (eth0) and wireless lan (wlano) connections. The other connections handled by the Network Manager are USB mobile broadband dongle (ttyUSB0) and two bluetooth connections to modems in mobile phones FB:0B:93:FC:33:D0 and 00:0E:07:2C:E8:82 which can not currently be used in Linux Kernel 3.8.0 based systems. The new section has ppp0 primarily for use with modem conections made using Gnome-PPP but other connections could be added. This test was using Cinnamon 1.8.2 over Ubuntu 12.04 with a modified Minty theme. The Bluetooth and Gnome-PPP (two screens) icons can be seen in the panel.

My original plan was to contribute these changes to adreadec, the writer of this essential piece of software but on 22nd May he stated he was discontinuing the project and that any developer who wants to fork it and continue development was welcome! I do not have the skills to do more than fiddle in the margins and I hope that when he realises how respected and essential his contribution is he will relent, otherwise I hope that it will be taken on by the Cinnamon team as a core Applet or one of the team personally.

31st May 2013

Stage 2 Enhancements to Network Speed Monitor Applet

Having completed the minimum changes required, as described above, to allow the NSM (Network Speed Monitor) Applet to be used with PPP (Point to Point Protocol) connections which are used for almost all landline and mobile telephone network connections including Mobile Internet USB dongles and connections via Bluetooth to the modems within many modern mobile phones. The only exceptions are intermediate devices such as MiFi units where the Mobile internet connection is part of a Wifi router so several machines can connect wifi to a single Mobile Broadband connection and some phones can also be 'tethered' via WiFi to share their Mobile Broadband connection.

The original NSM was designed to monitor what I would describe as static connections - where an ethernet or Wifi connect was made automaticaly when the machine was turned on. NSM remembered the previous connection and checked when it started that it was Active. This does not work with most 'mobile' connections which are made as required then disconnected if only to avoid excessive use of data. The original NSM only considered connections made through the network manager. It could see a connection to a supported USB Mobile Internet dongle which the network manager reported as, for example, ttyUSB0 which is the serial USB port device over which control takes place and information is passed to the computer but could not monitor the data itself which was handled by the pppd (Point to Point Protocol Demon) and the ppp0 interface. This is not a fault of NSM but an inconsistency in the Network Manager reporting. One also has to be able to handle connections which have been made independently of the Network Manager. Vodafone have quite sophisticated device and connection management software which also handles txts through the dongles and I almost always use a separate program to connect to modems within phones via Bluetooth.

I tried to keep as much as possible to the 'feel' of the original NSM and my stage 2 enhancements add additional information to the right click menu whilst retaining the basic behavior of the left click and hover modes as well as an identical numerical display in the applet on the toolbar. The right click menu now has an idicator showing active interfaces under the control of the network manager and the selected interface which is being monitored. The one problem with this implementation is that the right click menu is designed to be static and to be built once. It cannot be rebult whilst open so it has to be refreshed in some way. I initially set it up so it is refreshed by a left click on the applet.

 

June 17th 2013

The Network Usage Monitor with Alerts

This is a tool for efficient use of 'Mobile Internet' using primarily the 2G, 3G and ultimately 4G mobile telephone networks but also Wifi Hotspots and other sources where there are data limits applied. It makes use of some of the techniques and code from the excellent Network Speed Monitor (NSM) project by adreadec who, on 22nd May 2013, announced he was discontinuing the project and that any developer who wanted to fork it and continue development was welcome. The major difference is that the NSM was designed to continuously display the speed of 'fixed' conections (ethernet and wifi) whilst the new applet is extended to deal with 'mobile' connections using mobile internet dongles and bluetooth connections too phones and the Point to Point Protocol (ppp) and the primary purpose is to monitor data usage on a variety of timescales. The main text has been transfered to More Spices for Cinnamon - Applet Development.

September 9th 2013

Using GIT to manage Applet Development

All the early development of my initial two applets was done without using a Software Version Control System although a large number of snapshots were taken for major version changes. Most of the Cinnamon development is done using GIT and I had made some use of it to follow the development and try out various modifications by pulling their commits from the various development forks and the master branch of Cinnamon and Muffin. This is the opposite way round to what is required for ones own developments which might conceivably be forked and enhancements offered by other developers.

To be continued

September 21st 2013

Generic Android 4.2.2 Network Media Player

I have just bought a Generic Android 4.2.2 Network Media Player with Dual Core Processor, HDMI output, 4 USB sockets and a simple Remote from 7Dayshop.com . This allows me to plug in a 640 Gbyte USB 3.5 inch drive which has all my music, all my pictures including 'print files' from the last 10 years and most of my old videos transferred from VHS tapes and some 200 Video8 tapes from my camcorders up to 2000 when I went digital. For under £45 this is an exception bit of kit, especially with an external mouse and preferably keyboard and plugs straight into a HDMI input on a monitor or TV. It has its out sound output but my HDMI monitor has a headphone output which seems to give less interference and better sound.

This was my first experience with Android and it is like going back to the dark ages prior to Windows 95 but it does allow me to do most of what I wanted. The simplicity of the Apps available was a real surprise when Android is used extensively on Tablets and even high level phones have far more computing power than my netbook. The biggest problem in this application is however that Android severely restricts the use of external storage by Applications and it is only available write only to applications so, for example, one sets up an application which is capable of lossless rotating of old images which are on their sides but then one finds it can only work on the very limited internal memory so one is faced with using the internal file manager to copy ones folder of pictures to the internal storage (4 Gbytes but only a part is available) viewing and rotating then copying back onto the hard drive. The App I have been using sorts the pictures on file creation time rather than the Exif data and spposedly has the ability to change the accessed dates to match the Exif data (camera shooting time) but can not write them to the hard drive unless one copies them to and from the local memory in the file manager - duh. I found a simple command line program which does it on my Linux machines in a couple of minutes so it is quicker to move the hard drive and do the whole 32 Gbytes than mess around for even a couple of folders. You can run several programs at a time so I can set some music playing then start the Pictures displaying but changing the volume even with the remote stops the slide show.

Android obviously handles email in phones and tablets but again it is a trip down memory lane. Few email apps will even display html mail and it seems only two (which are not free) can write html mail. I suspect most people are driven to web mail. On the good side contacts do get automatically synchronised if you have gmail account which is almost manditory to even download your apps from 'Google Play', the source of 'approved' apps, even the name is a give away to the level of sophistication Google offers in Android. I have set up Inomail on the box which is not bad and handles html mail (even writes it if you pay £3.00) and the integrates and synchronises gmail contacts. The system does not properly synchronise calendars (google not box problem I believe so it may get fixed) so I have to use the web version of google contacts at present on the box but it is looking more like a simplistic but workable set up.

I have not got network file sharing working so far. I have installed Samba Filesharing but there there seems to be a fundamental problem as Android seems to block ports below 1000 so SSh and other filesharing requires non standard ports on unrooted machines.

Apps currently in use:

Apps tried are likely to be uninstalled

To be investigated:

 

 

 

September 24 2013

Thunderbird Address Book Slow Auto-complete and 'phantom addresses'

When you start to fill in the recipient or other address fields Thunderbird starts to fill it in for you from your address books. This can be very slow if you have a number of large address books and you get many repeated entries to the extent that it appears to stall for up to ten seconds after the first letter is typed. The other problem is that one gets any mistakes also coming back again and again. In the default set up every email address you use is copied to the Collected Addresses Book and that is a good place to look for and delete such addresses. Sometime one seems to have old addresses which do not show in the searches of any of the address books and I eventually found that they auto-complete checks the secondary email addresses whilst the searches are limited to the primary address - not the most logical arrangement but you can usually find these phantom addresses by noting the name from the auto-complete and then looking in the address books for that.

The speed is more of a problem if you have a number of backup address books like I have but I have found that the MoreFunctionsForAddressBook add-on lets you specify which address books to use, on an account by account basis for the auto-complete lookup. In Thunderbird -> Edit -> Account Settings -> Composition and Addressing Tab -> Address books for auto-complete and Click Edit or, in the compose window, for the current identity, from Tools --> Addresses auto complete. In both cases you get to a list with tick boxes of the address books to use. MoreFunctionsForAddressBook is a brilliant add-on which I have always had installed for the last 5 or 6 years and it transforms the functionality of Thunderbird's address books and seems to be compatible with most synchronising software including gContactSync (for google contacts) provided you limit the extra fields which may not get transferred.

5th November 3013

New Laptop on Order - Chillblast Defiant 13" Laptop with Haswell/Optimus Architecture, Core i7 Processor and Nvidia GTX 765M graphics.

The Chillblast Defiant was desighned for gaming so has exactly the sort of specification for Full HD Video editting. It has a vastly powerful Core i7 4700MQ 2.4 Ghz (3.2 on Turbo) quad-core (8 thread) processor, 8GB of 1600MHz DDR3 memory and a NVIDIA’s GeForce GTX 765M. It has Optimus technology so when I am using the machine for something less demanding than Video processing, the GeForce switches off and the Intel HD4600 takes over, saving considerable power. It has a 13.3” screen with a Full-HD 1920 x 1080 non-reflective display.

A 1000GB hybrid SSD / HDD gives lightning fast response rates and plenty of space for Video editting in a single device, A mSATA SSD slot is available to provide even faster dedicated storage for the OS if desired. 8GB of RAM comes as standard, expandable to 16GB.

The Defiant measures 330mm x 227mm x 329mm and weighs 2.1 kg including the battery and has up to 5 hours battery life. The MSI Wind has 5.5 hours on its power bulge 9 cell battery and weighs 1.4 kgs for a 10 inch 1024 x 600 screen. It should be a huge improvement.

Full Specification:
Core Logic: Mobile Intel® HM87 Express Chipset
Display: 13.3” (33.78cm) FHD (1920x1080) 16:9 panel, 2.8mm
Memory: 8GB 1600MHz DDR3 Memory (Expandable memory up to 16GB)
NVIDIA® Optimus Technology: GPU switchable between iGPU and dGPU
NVIDIA® Geforce GTX 765M (N14E-GE) - 2GB GDDR5 Video RAM
Storage: 1000GB Seagate Momentus XT Hybrid SSD/HDD
UK layout Keyboard
Built in touch pad with multi-gesture and scrolling function
SOUND BLASTER Cinema Surround Sound
1 x USB 2.0 port
3 x USB 3.0 ports(1x powered USB port, AC/DC)
1 x HDMI output port (with HDCP)
1 x external VGA port
1 x Headphone jack
1 x Microphone jack
1 x RJ-45 LAN port
1 x DC-in jack
6-in-1 Push-Push Card reader (MMC / RSMMC SD / Mini SD / SDHC / SDXC)
802.11N Wireless
Built in 10/100/1000Mb Base-TX Ethernet LAN
2M HD video camera
Full Range AC adapter, AC in 100~240V, 50~60Hz, DC output 19.5V, 6.15A, 120W
Removable 6 cells Smart Lithium-Ion battery pack, 62.16WH
Battery life : 300 minutes (UMA mode with 62.16WH battery)
Kensington® Lock
330 (W) x 227 (D) x 31.9 (H) mm
2.1kg, including 62.16WH battery
Motherboard with heat sinks removed - source unknown
Motherboard with easy access to all memory and all drive and peripheral slots
Heatpipe removed to show CPU and GPU

Using Optimus under Linux

Nvidia Optimus is an computer graphics hardware power/performance optimisation technology created by Nvidia which, depending on the resource load generated by client software applications, will transparently and seamlessly switch between two graphics adapters within a computer system in order to provide either maximum performance or minimum power draw from the system's graphics rendering hardware. With Optimus you can choose when to use the more powerful and battery consuming Nvidia graphics card or to use the integrated power saving Intel or ATI graphics. This allows you to improve your battery life while also giving you access to more powerful graphics when needed.

A project called Bumblebee enables Nvidia Optimus enabled laptops to work in a Linux systems. The latest versions provide some automatic power management so the Nvidia Graphics card is turned off when the machine is started to save power and heat generation and is only turned on for programs which require it. As I understand it a program which requires the graphics processor is specifically started in that mode by the user through Bumblebee and the Graphics card can be automatically turned off when it is exited.

Bumblebee is included in the very latest Ubuntu but most users will need to install it through a PPA, likewise it is recommended to use the latest Nvidia stable drivers again accessed through a PPA. It only works on 64 bit Linux kernels at present which may give problems with Windows programs run under Wine. A certain amount of configuration involving editing files will probably be required.

Useful Links

  1. Nvidia Optimus on Linux - this is probably the best article I have found so far and the only one that mentions the need to add users to the bubblebee group (Maybe not needed on latest versions??)
  2. Installing Ubuntu on a Pre-Installed Windows 8 (64-bit) System (UEFI Supported) - A lot of useful information and cautions with the most detailed explanations of what to do and how to recover from problems.
  3. Functioning Nvidia Optimus in Mint13/14/15 - Has references to laptop-mode-tools for additional power saving.
  4. Linux Mint 15 on Optimus - Bumblebee works NVIDIA/Intel - This is what I will initially be using so a good start.
  5. Installing Ubuntu in EFI mode - Useful information about partitioning disk
  6. Ubuntu Wiki Bumblebee Instalation Instructions
  7. bbswitch - contains warnings about some cards where a turn off can result in a situation where the BIOS has to be reset 'blind' so need to note key sequence! Used as part of Bumblebee.
  8. Bumblebee Configurator GUI and https://launchpad.net/bumblebee-config-gui - A front end for Bumblebee configuration files and installation of Bumblebee found through Webupd8, would be great if this works but early days.
  9. Fix Bumblebee libturbojpeg.so Issue In Ubuntu 13.10 Saucy Salamander - Hopefully will be sorted by PPA update. Bumblebee is already in Saucy repositories.
  10. Hybrid Graphics Linux team - not a lot of use here so far
  11. Webupd8 has a number of useful articles on Optimus and Bumblebee as well as just forcing the Nvidea card into use see http://www.webupd8.org/2013/10/8-things-to-do-after-installing-ubuntu.html on Optimus, http://www.webupd8.org/2013/04/bumblebee-321-released-with-ubuntu-1304.html - drivers, http://www.webupd8.org/2012/11/primus-better-performance-and-less.html , http://www.webupd8.org/2012/08/get-hdmi-working-with-nvidia-optimus-on.html
    http://www.webupd8.org/2013/10/fix-bumblebee-libturbojpegso-issue-in.html
    then search the site for lots more!
  12. Windows 8: How to Create a New Hard Drive Partition or http://www.partition-tool.com/resource/windows-8-partition-manager/windows-8-disk-management.htm and two examples of information on partitioning under Windows 8 - it is best to shrink partitions to allow space for a dual boot under Windows then you can do what you want with the free space in Linux with problems under Windows. Remember to check the disk first.
  13. How to install 32 Bit Wine on 64 Bit Ubuntu? - I will need to have a 64 bit system and Wine is basically for 32 bit Windows programs so various libraries and Multiarch may be needed or other configuration - a starting point.
  14. Skype on 64 bit Ubuntu - covers Multiarch use for 32 bit programs on 64 bit Ubuntu - implies mutiarch is a requirement for Skype
  15. Intel Performance With Ubuntu Linux vs. Windows 8.1 and Ubuntu Linux Gaming Performance Mostly On Par With Windows 8.1 - this are some of many Phoronix reviews which are Linux oriented and are a very valuable resource. Also has useful forums and technical info - http://phoronix.com/forums/showthread.php?83974-Intel-Driver-Gains-Virtual-Remote-Output-Support
  16. Windows partitioning information http://technet.microsoft.com/en-us/library/hh824839.aspx and http://msdn.microsoft.com/en-us/windows/hardware/gg463525.aspx#X-201104111922504 Barely useful background
  17. Overclocking Using Nvidia Settings http://www.question-defense.com/2009/10/22/overclock-your-nvidia-graphics-card-in-linux - for information - not tested
  18. Speed Test Site with frame rate read out

So What do we Learn from the above links

Conclusion - upgrade my AMD 64 Athlon x2 machine from Ubuntu 12.04 LTS 32 bit to Ubuntu Saucy 13.10 64 bit and check for problems with Wine (Picasa, Dreamweaver, Irfanview), Adobe Acrobat, Googleearth and Skype. See below for actions needed and results.

 

Experiences Upgrading from 32 bit Ubuntu 12.04 to 64 bit Ubuntu 13.10 Saucy Salamander (both with Cinnamon Desktop)and then to Mint 17 Qiada

This is not entirely to do with the Defiant, however I do need to ensure that everything I need is available under 64 bit Ubuntu Saucy and the experience will save a lot of time when the Chillblast Defiant comes. This section will be moved to another page.

The upgrade did not go as quickly and smoothly as I had hoped but came good in the end. I followed the procedure in Backing up a Home Directory prior to a Distribution Update with a major difference that I made enough free space on one of the drives to allow me to install into a new partition leaving the old system in place. As I expected this gave me the ability to boot into three systems, Ubuntu 12.04 32 bit, Ubuntu 13.10 64 bit and Windows Vista. I initially tried to make space on the Vista partition by deleting 40 Gbytes of old files but try to squeeze down the partition in Vista only allowed me to free 3 Gbytes even after a defragmentation taking nearly three hours.

WARNING - partition when disk is fairly empty and little used on Windows machines. Partitioning outside of Windows is likely to give you a reinstallation job

The end result was an allocation of 30 Gbytes to / (root), 80 Gbytes to /home (home folders), 4 gbytes swap, 320 Gbytes to a ntfs partition for video and shared with Windows and an HP Vista recover partition left over from when the machine was delivered. Another hard drive has a partition for by DATA partition and the Windows partition.

The other problem I had was that no LiveUSBs (made with UNetBootIn) would boot on this machine although it was fine on other machines - reason unknown. I burnt a DVD which worked fine but did not allow full testing as there was no persistence and memory alone was insufficient to load any extra programs like Wine. This forced me into an early install. LiveUSBs for Mint 17 worked fine.

Multiarch, what is it and must I use it?

Multiarch is an approach to running programs compiled for one computer architecture on another, particular i386 between amd64 (amd64 also covers Windows 64 bit which followed the AMD instruction set). Most packages provided in Ubuntu repositories are available for both 32-bit (identified as "i386") and 64-bit ("amd64") and your computer only needs the packages for its architecture, but there are some programs that are only available for the "other" architecture, such as Wine, Skype and some browser plug-ins. When Multiarch is working, in theory, you no longer have to concern yourself with the details of how it supports different computer architectures; just install the programs you like.

There is a downside to multiarch, if you install 32-bit programs on a 64-bit system, then lots of extra library packages need to be installed for 32-bit support (denoted by "(i386)" in the package name) in addition to their native 64-bit versions. Multi-arch is handles all that and should also remove the need for ia32-libs, a huge package of 32 bit libraries to enable 32 bit programs to function in a 64 bit linux before multiarch - it is now depreciated.

Under Mint 17 it is already set up and I could just load 32 bit programs and all the extra library packages need to be installed for 32-bit support were just installed as dependencies. You can check as below.

I enabled multiarch by

sudo dpkg --add-architecture i386
sudo apt-get update

You can check the architecture and if you have extra architectures by:

dpkg --print-architecture
dpkg --print-foreign-architectures

You can remove the i386 support by:

sudo dpkg --remove-architecture i386

Wine (Wine Is Not a Emulator)

Wine is essential for me to run a few legacy Windows programs that I make a lot of use of.

I wasted a lot of time with Wine after I had installed it as I thought it was not working as it would not load an existing program (Irfanview 3.95) but eventually I found it loaded everything else including a newer version of IrfanView and would also run everything in the the existing ~/.wine folder. I am therefore not sure if any of the steps I took were actually required to run Wine as my initial test was flawed. I am however pretty sure that Multiarch is a requirement for running some of my programs which are only in 32 bit form namely Skype, Adobe Acrobat and possibly Wine.

You can confirm the version in use like this:

$ file `which wine`
/usr/bin/wine: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.24, BuildID[sha1]=0x7a9c379d822f62db3a92bd536147c6c88d981ab4, stripped

and I get essentially the same on both the 32 and the 64 bit system.

I also followed the advice to do the following to carry out the initial configuration:

export WINEARCH=win32
winecfg

I do not think the latter was doing anything afterwards as the Environment variable was only in effect for that session.

Skype: In contrast Skype installed without problems with Multiarch in use and active for i386 - I just had to adjust the microphone which was turned off after the upgrade.

Picasa: I am running 3.5 currently under Wine on one machine and the link shows how to run 3.9 including x64 - http://mdalacu.blogspot.co.uk/2013/04/ubuntu-1304-and-picasa-39.html (not tried). There also info on Webupd8 if you search. With Wine 1.6 under Mint 17 it just worked.

Adobe Acrobat: The Classic PDF reader is available in Canonical Partners repository for Ubuntu 13.04 Raring and earlier. At the moment the repository is not ready for Ubuntu 13.10 and is only 32 bit so see http://ubuntuhandbook.org/index.php/2013/09/ubuntu-13-10-quick-tip-install-adobe-reader/

My Installation procedure was

Click to download the the DEB for Adobe Reader to the Desktop

For a 64-bit system do:

sudo dpkg -i --force-architecture ~/Desktop/AdbeRdr9.5.5-1_i386linux_enu.deb; sudo apt-get -f install

Gave some error messages but the dependency correction (apt-get -f install) worked to sort them out.

On Mint 17 I just ran the package and it picked up all the 32 bit library packages as dependencies and worked without anything extra.

Googleearth on Saucy 64 bit (which lacks ia32-libs) and Mint 16 Petra 32 bit

Google have never supported Googleearth very well on Linux. Google Earth is available for GNU/Linux from their web site, but is non- free software and also does not integrate well into an Ubuntu/Debian based system. There is a utility in the Ubuntu Repositories which should make it possible to build your own personal Debian package of Google Earth. The packaging itself is Free Software, but the Google Earth program is governed by the copyright holder (Google), so you may be limited as to what you can do with the resulting package (i.e. no redistribution for commercial use, etc). The built in installer was also broken in Ubuntu 13.10 Saucy so the Debian one was needed. This was probably one of the results of the switch from ia32-libs, a huge package of 32 bit libraries to enable 32 bit programs to function in a 64 bit linux to instead use Multiarch, which is intended to be a replacement with the advantage that only required packages are brought in. However not everything has been sorted before ia32-libs was withdrawn. I therefore spent a lot of time when I was testing out 64 bit systems which I exploited when it came to using Googleearth on the Defiant and other machines. The version of Googleearth that I finally got working is not the most recent but perfectly adequate.I never fully understood what I was doing butif you want there is [ More ]

Encrypted DVD playback:

The Medibuntu repository which contained many codecs and other proprietor programs no longer exists and while most packages in the archive are now in the Ubuntu repositories, the controversial livdvdcss which is still required for playing encrypted DVDs has to be installed by a script. The workaround, which includes the other codecs previously from Medibuntu is

sudo apt-get install libdvdread4 libavformat-extra-53 libavcodec-extra-53 ubuntu-restricted-extras
sudo /usr/share/doc/libdvdread4/install-css.sh

I am updating my installation scripts to include the changes resulting from Medibuntu.

Latest Kernel Upgrades (Not implemented): http://linuxg.net/how-to-install-kernel-3-11-5-on-ubuntu-linux-mint-debian-elementary-os-and-pear-os/

Things that might have given trouble but worked as expected or better:

Other Changes of importance between Ubuntu 12.04 and 13.10

USB Drive mount points: There is one change which has a major impact on the way I work and will mean I have to eventually upgrade all the 12.04 machines. I use USB drives as the Netbooks have very little spare disk space and move them from machine to machine and run on their data. The mount points in 12.04 were changed in 12.10 and higher from /media/DRIVE_NAME to /media/CurrentUserName/DRIVE_NAME so one can not simple move between machines and carry on work as their 'profiles' need data from different places on different systems. The same problems apply when I have a multiboot system sharing the same /home. I am working on some workarounds but this seems to have been a Kernel change and not easily user configurable.

See:http://askubuntu.com/questions/214646/how-to-configure-the-default-automount-location http://askubuntu.com/questions/204302/how-do-i-change-the-automount-point?rq=1 http://biocrystallography.blogspot.co.uk/2013/09/udev2-mount-to-media.html

My solution to change USB Drive auto-mount point back to /media

I am using a udev feature in Ubuntu 13.04 and higher (needs udisks version 2.0.91 or higher).

Create and edit a new file /etc/udev/rules.d/99-udisks2.rules

sudo gedit /etc/udev/rules.d/99-udisks2.rules

and cut and paste into the file

ENV{ID_FS_USAGE}=="filesystem", ENV{UDISKS_FILESYSTEM_SHARED}="1"

then activate the new udev rule by restarting or by

sudo udevadm control --reload

When the drives are now unplugged and plugged back in they will mount at /media/USB_DRIVE_NAME

Comparison of 32 and 64 bit performance

Ubuntu have always recommended running the 32 bit system, certainly for systems of 2 Gbytes memory or under as the additional memory requirements cancel out any gains from the richer instruction set and faster processing.

I have done a quick and dirty check on my AMD Athlon 64 dual processor 5000+ with 2 Gbytes of Memory which is on the boundary. Speed in rendering videos (which is a good processor benchmark) was only 5% faster, almost within the measurement noise. Memory use was up 40% on average with quite a wide variation (28% Firefox with many tabs on startup and 54% Thunderbird with many accounts on startup). This is in line with Tests by Phoronix on Ubuntu 13.10 amd64 and i32 where Video and Audio processing showed ~15% gain and only FFTs showed a lot more, in most cases it was a very marginal or none existent gain.

I also use the benchmarks at the end of the System Information program - install hardinfo to access it.

Benchmarks AMD Athlone 5000+ i32 Mint 16 AMD Athlone 5000+ x64 Mint 17 Defiant i32 Defiant x64 LiveUSB
CPU Blowfish 8.39 7.36 (lower is better) 1.77 1.72
CPU CryptoHash 125.2 163.43 (higher is better) 624 691 (higher better)
CPU Fibonacci 2.93 3.55 (lower is better) 1.38 1.30
CPU N-Queens 16.09 15.12 (lower is better) 0.48 0.47
FPU FFT 6.75 7.80 (lower is better) 0.69 0.74

GXLSpheres 1920x1080

N/A

11 fps (both quite variable)
18 Mpixels/sec (1680x1050)

116 fps
230 Mpixels/sec
119 fps
237 Mpixels/sec

It is interesting to see how little change there is between 32 and 64 bit linux - 10% max and sometimes the 32 is actually faster on both machines. The change in Kernel 11.1 - 13 and drivers nVidia-219 - nVidia-331 also makes small differences between Mint 16 and 17, generally in favour of Mint 17 but not enough to account for the differences on the AMD Athlone machine.

29th October 2013

Information on the Chillblast Defiant

Chillblast are being very helpful and I now know that the Defiant is based on the Clevo WS230ST chassis and I have been able to download a 'generic' manual from the Clevo web site which answers some of my questions on the BIOS. More importantly it has enable me to widen my search to other machines using the same chassis and I have come on a very useful thread namely the Sager NP7330 Linux Guide/Review which indicates that some people are succesfully running a machine based on the same chassis under Linux. There is also a lot of information in these threads http://forum.notebookreview.com/sager-clevo-reviews-owners-lounges/715556-official-clevo-w230st-sager-np7330-owners-lounge.html and a very full review here http://forum.notebookreview.com/sager-clevo-reviews-owners-lounges/725922-htwingnuts-sager-np7330-clevo-w230st-review.html . There are other firms using the chasis (in the USA) but nothing like the coverage as the Sagar.

Things To Do before installing Linux assuming dual boot approach.

This is not going to be very different to the approach in The Road to Freedom except that Backup will not be so important as it will be a largely empty machine however Virus checkers and firewall ought to be installed even if Windows 8.1 is supposed to have its own built in. So the plan is:

Chillblast Defiant Setup Information

Access Bios Setup and Boot Options

To enter Setup, turn on the computer and press F2 (give the system a few seconds to enter Setup; the F2 on screen will be highlighted to illustrate that the system is processing the request) during the POST (or press F7 for boot options). If you get a “Keyboard Error”, (usually because you pressed F2 too quickly) just press F2 again.

To see the boot options press F7.

Incorrect settings can cause your system to malfunction. To correct mistakes, return to Setup and restore the Previous Values with <F2>, or Optimized Defaults with <F3> Practice this 'blind' as some Optimus and NVidia setup errors can leave a blank screen on some machines until the BIOS is reset to Optimised Defaults! I would rather not find that out the hard way

Tests using LiveUSB and LiveDVD (must be 64 bit for UEFI boot)

I downloaded the iso of Ubuntu 13.10 Saucy Salamander 64 Bit (AMD) version and used UNetBootIn under Linux to create a LiveUSB with Persitence as well as burning a standard LiveDVD . UNetBootIn runs under Windows and Linux to create the Live disks. Neither this or the equivalent Mint Olivia would boot on the Defiant either from LiveUSB or DVD using F7. The DVD needed time to spin up and be recognised so I found entering and then leaving the BIOS setup (F2) gave time for it to show up on the next F7 in the Boot menu as the machine was not powered down that way.

To cut a long story short both Mint 15 Olivia and Ubuntu 13.04 were happy to boot in x64 and i32 forms. I did a lot with Mint Olivia x64 in Persistent LiveUSB form including installing updated Nvidia Drivers from the ???? PPA (version 319.49) and then Bumblebee (version 3.21) from the PPA and got some very impressive results with glxspheres which ran about three times faster on the nVidia 765m than on the internal Intel 4400 which was still much faster than anything I have. I also got the GPU temperature sensor etc working using nvidea-settings both as the full GUI application and in the terminal ready for an applet.

It is now time to format the hard drive

Installing Bublebee

In contrast installing the x64 bit systems from the LiveUSB went very badly and none of them would boot to completion. However I found that the 32 bit Mint 15 installed and booted with no problems and after a lot of time try to get an x64 installed I found that contrary to all the guides that Bumblebee seems to work fine with a i32 system and the glxspheres runs at the same speeds as on the x64.

Bumblebee provides support for NVIDIA Optimus laptops. Using Bumblebee, you can use your NVIDIA card for rendering graphics which will be displayed using the Intel card. Bumblebee is officially supported by Ubuntu in 13.10 Saucy or newer. However, all releases are supported by the Bumblebee Project community from Ubuntu version 12.04 up to 13.10. The following follows https://wiki.ubuntu.com/Bumblebee

Remember to enable the Universe and Multiverse repositories (for bumblebee and nvidia packages respectively).

As we are using Mint 15 Olivia which is based on Ubuntu 13.04 we do not have the latest nVidia drivers available so we need to install them from a PPA before we go any further. If you have already installed nVidia drivers inadvertently they should be removed before proceeding.

Now add the PPA

sudo add-apt-repository ppa:ubuntu-x-swat/x-updates
sudo apt-get update
sudo apt-get install nvidia-drivers-319 nvidia-settings-319

It is now time to install bumblebee, you can add primus if you want as well

sudo add-apt-repository ppa:bumblebee/stable
sudo apt-get update
sudo apt-get install bumblebee bumblebee-nvidia linux-headers-generic

Reboot (unusual - because hardware involved)

Bumblee should now have turned off the Graphics card to save a lot of power. To run your application with the discrete NVIDIA card run in the terminal:

$ optirun [options] <application> [application-parameters]

ie to run firefox to look at Catchup

optirun firefox

It should turn off when the program is closed

For a list of options for optirun run:

$ optirun --help

Normally you do not use optirun for your window manager, installations or other non graphic heavy demanding programs. The optirun command is mainly used for graphic demanding programs or for games. In the long term one will edit/create new .desktop files for programs using the NVidia driver. There is an alternative to optirun - primus which is less developed but may offer advantages to optirun.

You can check that everything is working by

optirun -b none nvidia-settings -c :8

This runs the nVidia settings program. The use of optirun is required to turn on the card before running nVidia Settings - the other options flags are only needed with nVidia settings. nvidia-settings should not work fully without optirun if the card is disbled which is the case.

The final check is to run glxspheres with and without using optirun and see how it speeds up. It is installed in one of the dependencies of bumblebee. Also try the 'aquarium' test at http://webglsamples.googlecode.com/hg/aquarium/aquarium.html

Checking Power Saving is operational (bbswitch)

The primary goals of the Bumblebee project include smart power management of the dGPU when it's not in use. This uses either bbswitch (a module) or vga_switcheroo (kernel module, experimental) to do this in Bumblebee. Since Bumblebee 3.0, this feature is enabled by default, using bbswitch. This allow automatic power management, without any additional configuration needs. To find the status:

sudo cat /proc/acpi/bbswitchreturns
0000:01:00.0 ON
ABOVE DOES NOT WORK with 3.21 where bbswitch is integrated and kernels below 3.11.0

There are some commands you can use for test and extra information at bbswitch

I resorted to power consumption and GPU temperature as an indicator. The battery life of 2 hours 40 was a little less than I expected with no opirun programs but it did drop convincingly to 40 minutes when glxsheres was run. So it is possible that programs are being switched by optimus but the card is not being disabled fully when not in use. This is corrected in kernels after 3.11.0

Monitoring Nvidia GPU temperature

References:

  1. https://wiki.archlinux.org/index.php/NVIDIA#GUI:_nvidia-settings -for ArchLinux but a lot of information which is common
  2. http://manpages.ubuntu.com/manpages/quantal/en/man1/alt-nvidia-current-settings.1.html - the manual page - nothing specific on GPU temp
  3. www.question-defense.com/2010/03/22/gpu-linux-shell-temp-get-nvidia-gpu-temperatures-via-linux-cli - useful
It seems there are at least three ways to monitor the temperature of an nVidia GPU from the terminal from the above but none worked without modification

nvidia-settings -q gpucoretemp -t

nvidia-smi -a | grep Gpu

vclock -T

Firstly it is necessary to use a modified string when bumblebee is in use as the GPU would otherwise be off and not respondand and with bumblebee 3.21 See http://www.webupd8.org/2013/04/bumblebee-321-released-with-ubuntu-1304.htm there are some additional options namely: "-b none " to disable injection of any render offloading bridge (primus or VirtualGL). So to invoke Use this to invoke nvidia-settings we use

optirun -b none nvidia-settings -c :8

and to just get the core temperatures in the terminal (or within a script) we do

optirun -b none nvidia-settings -q GPUCoreTemp -t -c :8

This works with Bumblebee 3.21 giving two temperature readings which allways seem to be the same. Note the capitals now in GPUCoreTemp

optirun -b none nvidia-settings -q all -c :8

The above gives all the sensors with information so you can pick out what you want and showed me that the temperatures need capitalising

Cinnamon Users - nVidia monitoring applets

It should be easy to build one of the terminal strings above into an applet to give a continuous display and there is already one cinnamon applet which displays a lot of information including temperature when clicked.

Also see http://cinnamon-spices.linuxmint.com/applets/view/111 which uses nvidia-settings for the information and provides a very comprehensive output. This would need modification as above with bumblebee but it looks easy to modify the javascript file and it is well written and commented. I have put an image here as an advert for the applet and Cinnamon.

I will replace it with one showing my card in the Defiant when I have modified it for optimus, which should be a simple search and replace on one file in ones home folder structure!

Other monitoring programs - lm-sensors

lm-sensors is used by some of the monitoring applets. It needs to be set up initially by running a setup in the terminal. You have options to let it investigate many options and there are preferred yes/no options for each - you should keep on to the safe side and not scan those that are not recommended and certainly NOT the graphics chip ones at the end, not only because nvidia-settings provides the information but also they have been reported to occasionally cause problems and the cause is unknown. It is however believed to be safe for monitoring CPU temperatures.

Overclocking Using Nvidia Settings


Setting up the new machine for real

You will recall the disk was set up with a separate partition for the home folder(s) /home. The intial user was set to a temporary user when the install was done so that the entire home folder from my previous machine could be transfered in. The proceedure is simple to carry out once one has understood the principles. It is exactly the same as making a backup into a compressed repository saving all the associated file information, in particular the owner, group and associated permissions. Obviously programs have to be closed at the time and there is one temporary area which has to be excluded - this is all covered in Fun with Ubuntu - Backing up a Home Directory prior to a Distribution Update so I will not go into at length here.

Having opened the new/old user I found that I had to change a number of the settings as it was previously on an Ubuntu/Cinnamon rather than a Mint/Cinnamon environment so many of theme components were missing. I also had to turn the Touchpad on using an external mouse as the hardware was different! That said everything was back to normal and ready to load the missing programs within an hour. I set a timer and it is three minutes past a day as I write and the script loading the programs is running on the other machine.

Ran tests on rendering Video with kdenlive - the bottom line test. On existing desktop my standard 5 min 12 sec takes 28 minutes with two cores in use and H264 720i video. On the Defiant it takes 7 min 30 with 2 cores and 4 minutes with all 8 cores allocated - faster than real time although it does get the fans going! On the netbook it was taking 100 minutes with both cores.

At this point the Desktop is virtually back to normal but some essential proprietory programs are missing such as Truecrypt and I am yet to check out ssh and set up unison

 

Skype

Skype has two problems on the Defiant under Mint 15.

Skype Audio

The first is that the audio is terrible as Skype (which is now owned by Microsoft) has not been updated to take account of the recent versions of pulse audio. There is a fix which works but needs better integration. It needs an environment variable to be set when skype is called.

Test it by doing it like the following in a terminal window:

env PULSE_LATENCY_MSEC=30 skype %U

Try increasing the number if the crackling does not stop - I found 90 worked well.

You also can try putting this in the desktop file that links to and starts up Skype or using the menu editor in Mint.

Either locate a skype.desktop file and open it with a text editor.

Find the line that reads Exec=skype %U and modify it to the following (exactly as written):

Exec=env PULSE_LATENCY_MSEC=30 skype %U

Save the file. Remove your old shortcut in the menu and replace it with the new one. You may need to reboot, dependent upon your Linux distribution.

Or edit directly using the Menu editor.

I have an unresolved issue in starting in the startup applications into the system tray.

Skype Video

I am unable to see any video in skype. This is not a webcam problem, as the remote user can see me fine. I can't see their video, or mine, only 2 solid green rectangles. Web searches show the green screen problem is well known and the standard fixes do not seem to work on the Haswell in the Defiant so far. Videos from the camera show up correctly in the Cheese appliction if installed using Synaptic.

See, for example, How to make Webcam compatible with Skype. This problem in various forms seems to have been around since 2008. It is usually to do with the video 4 linux libraries (V4L) used by skype. By default the current library is V4L2, to make your webcam work with Skype when you have this problem, requires the preloading of V4L to make it compatible or V4L2 conversion. You may have to search for the location of the 'conversion' files as they change with distribution. Even when I found them the solution did not work for me.

Video playback and monitoring in editors

The green screen also occurs in Kdenlive, Openshot and VLC with their standard configurations but not in the Mint Videos player or Cheese (the webcam application) .

Videos: This is the preinstalled player in Mint 15 and is actually the Totem player. This does not have the Green Screen problem as far as I can tell.

VLC: Version 2.08 offers Video driver option and leaving the Accelerated box ticked and the output set to OpenGL GLX video output (XCB) works well. I have not explored all the options.

Kdenlive: This seems to be a driver problem and Settings -> Configure kdenlive -> Playback lists 10 options of Video driver to use as well as an OpenGL tick box. Chosing XVideo and ticking the OpenGL box works fine and gives a smooth preview even without optirun. I have not explored all the other options.

Openshot: does not have any options so currently does not work on the Defiant under Mint 15.

HDMI Output

I have only tested without Optirun and using Displays under settings. Setting the LCD to the same resolution as my Goldstar 23" DVI enabled monitor (1680 x 1050) through a convertor cable enabled mirror use and I could also choose either by switching the other monitor off in the panel. Using a dual monitor set up may be possible but I have not tried it.

Defiant Wifi and Bluetooth

This uses the Intel Centrino Advanced-N 6235 802.11a/g/n, dual stream 2x2, dual-band WiFi + Bluetooth 4.0 PCIe half mini card. See http://www.intel.com/content/dam/www/public/us/en/documents/product-briefs/centrino-advanced-n-wimax-6235-brief.pdf for more details. I understand from Chillblast that it works much better with WPA than WEP which I still have on a router for old XP machines and hardware. It seems fine close round the house with WEP but this is probably the excuse to change. The card has both hardware and software switching of radio but the hardware mode does not seem to be implemented.

Implementing an Aeroplane Mode in Defiant

The Defiant has an indicator light for Aeroplane mode and it can be switched on by Fn F11 under Windows and this turns off all transmitters (Bluetooth and Wifi). It is implemented by a Windows Driver. This does not seem to be a hardware switch but only in software and the light seems just to be an indicator which is unrelated to the hardware. If one sets Aeroplane Mode using Fn F11 in Windows and turns the machine off the indicator is still on when you reboot into Linux (Mint 15) but the Wifi can be turned on and off as usual and works with the light still lit. This is not ideal as there is a real risk that a linux user might not realise and there is a finite, if small, risk that aircraft or hospital systems could be affected. The light does not have any obvious control other than in a dual boot system via windows.

In Mint 15 the Network Manager -> Settings has a Aeroplane Mode switch (in software) which switches both Wireless and Bluetooth off.

It may be desirable to have a more accessible way of doing this and/or a check and display as an applet.

Suitable commands are rfkill which needs sudo to actively control wifi and bluetooth but not for status and nmcli which is a command-line tool for controlling NetworkManager and getting its status. Do man rfkill and man nmcli for mor information and try:

rfkill list

Work in progress

Card Reader - Realtek

This is not recognised or supported in the kernel - a bug report has been raised for kernel 3.8. https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1201321 This bug was fixed in the package linux - 3.8.0-29.42

This is solved in the 3.11 kernel used in Mint 16 where it is correctly recognised and uses the rtsx_pci driver and an updated kernel is available for Mint 15 Olivia but it is on the list as having known problems and not recommended. I installed it anyway and it does solve the problem, however I wanted the full choice available for booting in to and the ability to save the choice. First lets look at how to restore the full list by:

sudo gedit /etc/grub.d/10_linux

At the end of the file you will find:

if [ "$list" ] && ! $in_submenu; then
echo "submenu \"Previous Linux versions\" {"
in_submenu=:
fi
done

if $in_submenu; then
echo "}"

add the "#" character in front of some lines to comment them out so they look like this:

if [ "$list" ] && ! $in_submenu; then
#echo "submenu \"Previous Linux versions\" {"
in_submenu=:
fi
done

#if $in_submenu; then
#echo "}"
#fi

Then run update grub to apply the changes.

sudo update-grub

Now we need to edit another file to make the last kernel run the default.

gksudo gedit /etc/default/grub

shows /etc/default/grub the start of which typically contains:

# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
# info -f grub -n 'Simple configuration'

GRUB_DEFAULT=saved
GRUB_SAVEDEFAULT=true
#GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""

#...................

GRUB_DEFAULT=0 will boot the first menu item and so on. GRUB_DEFAULT="saved" will boot the same entry as last time.
GRUB_SAVEDEFAULT=true ensures the last used kernel is saved
GRUB_TIMEOUT=5 will display for 5 seconds

After making any changes you must run in a Terminal:

sudo update-grub

to save the changes into the file actually used during booting

This means that the system will now show all the previous kernels as options and boot into the one last used (including Windows) after a pause to make changes which is reduced to 5 seconds.

Howto Avoid Booting into Windows Recovery

You will notice that there are two Windows entries shown - always use the first. Many recent computers, in particular, laptops and netbooks as many computer manufacturers no longer supply the Microsoft CD/DVD for Windows but instead have a hidden partition which has a disk image to restore the machine to exactly the state you bought it. Unfortunately this is not hidden to Ubuntu and it is given as an alternative operating system in the Grub start up menu. It is not always obvious which is which so it is possible for the unwary to boot into the Restore Disk which is not good news and you are only a key stroke away from deleting everything. Chillblast do supply the disks but still have a recovery partition so are at risk. I will not cover how to remove that from the menu as it covered in Fun with Ubuntu - Customising The Grub 2 Boot Loader Menu

Fn and Function Keys (Blue markings on keyboard)

The function keys (F1 - F12 etc.) act as hot keys when pressed while the Fn key is held down.

Function Keys & Visual Indicators Action in Windows Comments
Fn + ~ Play/Pause (in Audio/Video Programs)

Does not work
Almost all programs
have their own hot key

Fn + 1 Fan Control Toggle
between Automatic Fan Control
and Full Power
As expected
Fn + F1 Touchpad Toggle As expected
Fn + F2 Turn LCD Backlight Off
Press a key to or use Touchpad to turn on
As expected
Fn + F3 Mute Toggle As expected
Fn + F4 Sleep Toggle As expected
Fn +F5/F6 Volume Decrease/Increase As expected
Fn + F7 Display Toggle

Does Nothing
Use Displays in Settings Manager

Fn +F8/F9 Brightness Decrease/Increase

Decreases but does not Increase
Use Brightness Applet
before screen becomes invisible!

Fn + F10

PC Camera Power Toggle
Only indicator is on Camera
(If camera in use)

As expected
Fn + F11 Airplane Mode Toggle
Indicator Light

Does Nothing
Indicator does not change
from last setting in Windows
Alternative Needed

Fn + F12 Toggle Keyboard Illumination
and Adjust Brightness Level
As expected
Fn + Num Lock Provides Numeric Keypad -
Indicator Light
As expected
Fn + Scr Lock Scroll Lock

Does Nothing
Rarely used except as toggle
for KVM switches

21 November 2013

Mint 16 Petra LiveCD boot error solved

I cound not get the new Mint 16 Petra Release Candidate LiveUSB to load - it failed with a message about a divide erro on the screen which seemed to relate to the open source video driver nouveau for the nVidia card. On googling I found another user with a Nvidia Optimux Geforce GTX 765M and Intel Haswell i7 also crashes in the same way aand he found that booting in recovery mode allowed a boot to a software rendered fallback mode and he could then install bumblebee and nvidia drivers to get a working system.

I found the same proceedure worked for me and I installed the nVidia drivers version 319.22 and bumblebee and could run nVidia Settings and other programs with optirun on the LiveUSB stick with a Gbyte of persistent memory. It did not however get round the basic problem of the drivers used during the boot process and the recovery mode boot was still required. As time has gone on more and more of the basic setting up is being done during in GRUB during the boot process, necessitated by the diversity of screens etc which have to be dealt with at an early stage. Although I was now running with the Intel Drivers for the onboard graphics and the nVidia proprietory drivers for Optimus the built in drivers were still being accessed during booting. There are a number of rather poorly documented control mechanisms of the boot process by GRUB, the boot loader - strictly it is now GRUB2. These are implemented in the control 'script' and it is possible to edit these during the boot process on a one off basis. The proceedure is:

Interupt the boot process during the countdown period by moving up and down and enter the edit mode by the Tab key (or as described on the screen if you are not using Mint).

An editor will open up that will allow you to temporarily change the grub options for the next boot, in Mint this allows access to a single line where additional options can be added or the existing options modified.

The best way that I have found to disable the nouveau driver during booting is by just adding nouveau.modeset=0 before the --persistent at the end of the line.

Enter now immediately takes you into the boot process

The changes made to the grub entry only disable the nouveau driver for the current session. To permanently disable nouveau you can edit the /etc/default/grub file and add nouveau.modeset=0 to the GRUB_CMDLINE_LINUX line and then run sudo update-grub. This does not however work on a LiveUSB as you are not able to update grub so you have to edit the line every time.

Tests of Mint 16 Petra RC on LiveUSB

To follow

ACPI Handle bug

https://bugzilla.kernel.org/show_bug.cgi?id=60829

Brightness Keys

There is a bug reported in the kernel https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1218547

The core of the issue is that there are two interfaces present that are trying to control brightness. If one boots with a kernel boot parameter of "" this disables acpi_video0 interface leaving intel_backlight.

The acpi_backlight=vendor can be added by editing the boot sequence during a boot to test and if works it can be included by editing the grub start up scripts in a permanent way - see above for more details

This shows /etc/default/grub the start of which typically contains these modifications by me:

# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
# info -f grub -n 'Simple configuration'

GRUB_DEFAULT=saved
GRUB_SAVEDEFAULT=true
#GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="acpi_backlight=vendor quiet splash"
GRUB_CMDLINE_LINUX=""

#...................

Remember to do a sudo update-grub after the editing

Power Saving Figures with Discrete GPU Off

I have found a procedure which has enabled me to test the power saving by turning the GPU off. At present I have only run it on a LiveUSB but with a 64 bit system it changes the idle (30% brightness and nothing at all pruning except the Power statistics screen and a terminal to load the module ito the kernel and do the switch. The results are that an idle of 23 watts drops to 16 watts - a saving of 7 watts giving a battery life of nearly 4 hours rather than the 2 hours 40m I get at present which is worth having.

Stop Press the kernel fix is present in the Release Candidate of Mint 16 Petra and the battery life in Petra on a LiveUSB is just over 4 hours.

GPU off and no programs running other than the terminal and this monitor with fudge in Mint 15

You can see the increase as I run the program to switch theGPU on at 6 minutes in and increase to 23 watts from 16 watts

The predicted time of operation with the GPU off and no programs running other than the terminal and this monitor - compare to 2 hours 45 mins which is the case with the GPU on and Optimus enabled.

How to get a low power mode with the nVidia GTX 765M powered off on Mint 15.

Currently Bumblee is switching GPUs correctly but the switching off of the discrete GPU when not in use is not taking place correctly. This is carried out by bbswitch and it seems that mixed information is being provided by the Optimus hardware on a number of machines and a number of hacks are in place but it really needs to be fixed in the Kernel which is chosing the wrong dmi handler interface in this case. It may be fixed properly in kernel 3.12 which is not due for a while so in the meantime I have been looking for some quick fixes to at least allow the power consumption to be lowered even if the discrete GPU is not available in that mode. As can be seen the gains are useful.

The starting point is in http://linux-hybrid-graphics.blogspot.co.uk/2010/07/using-acpicall-module-to-switch-onoff.html which is what I used to get the plots above. This adds a special module to the kernel (it has to be added every time you reboot in the most basic set up and certainly after every new kernel is added). It was an intermediate development in 2010 on the way to bbswitch but does allow a search to find the correct handle to use. I would recommend only adding to a single kernel just in case something goes wrong. The interface is by a file which you write the call to and the response is written back - the response only seems to stay for a very short time. I have also found it needs have the permissions set so it is writeable without using sudo. It should be possible to set up a script run by a launcher to disable the graphics processor. One should also have script to replace optirun to ensure it is on before it is used like bbswitch. I hope bbswitch is fixed soon - it is supposed to be in kernel 3.12 but that could be a while. I am not going to give anything more than the link and the two codes as it has risks and if you do not understand from the link should should not do it! I have only used it so far on a liveUSB but will report further including add the module permanently to the kernel.

There are several warnings on the web site and from others and it is recommended to turn back on before suspending.

Outstanding Issues

Major:

Getting Optimus/bbswitch to turn off the power to the nVidia graphics card when not in use.

Stop Press - Optimus/bbswitch works fully in Mint 16 'Petra'

The latest kernel 3.11.0 which is used by Mint 16 Petra has the bug fixed which prevented the Discrete nVidia GST765M card being switched off. This is only available in Release Candidate at this time but I have checked on a LiveUSB and it all works and the idle power is under 16 watts with a high brightness of 70% or 14 watts with 30% (fine for indoors) with keyboard backlight off and a battery time of over 4 hours. Assuming this version can be loaded then the power problems may be solved.

Minor:

Better handling of Aircraft Mode - now handled by keyboard shortcut Super + F11 as Fn key used does not act as a 'modifier' in Mint. It opens the Network Settings screen which has the Aircraft mode switch. Same done with Display switch where Super+F7 opens the Display Settings screen.

The card reader is only consistently available if a card is present during booting after which cards can be used as normal and survive suspension

Install under Mint 16 Petra to extra partition

First one ust create a LiveUSB by downloading the latest iso file to a machine, it does not need to be the target machine or even running Linux and then create the bootable LiveUSB using a program such as UnetBootIn. I always use Unetbootin and it runs under Linux or Windows. It is in the Ubuntu/Mint repositories so it can be installed using the Synaptic Package Manager or the Software Manager. One still needs to make a change to the boot parameters to disable the nouveau drivers which will never be used. This has to repeated every time with the LiveUSB but can be made permanent as soon as Petra is installed. This change in Grub is described above.

Install Log using Synaptic


bumblebee (3.2.1-3)
bumblebee-nvidia (3.2.1-3)
nvidia-319-updates (319.60-0ubuntu1)
nvidia-settings-319-updates (319.60-0ubuntu1)
primus (0~20130601-1)
gir1.2-gtop-2.0 (2.28.4-3)
libc-dev-bin (2.17-93ubuntu4)
libvdpau1 (0.7-1)
bbswitch-dkms (0.7-2)
libc6-dev (2.17-93ubuntu4)
python-xkit (0.5.0ubuntu1)
screen-resolution-extra (0.15ubuntu1)
primus-libs (0~20130601-1)
socat (1.7.1.3-1.5ubuntu1)

Thoughts on GPU Monitor Applet - BAND (Bumblebee and nVidia Display) Applet

The existing GPU Temperature Applet has some undesirable features even when modified to use with a Haswell Optimus Dual GPU set up. The problem seems to be that the GPU is being frequently switcched on and off causing additional GPU power consumption and also uses quite a lotof CPU. Some of this has been reported and after the Applet has been removed it does not completely stop until there is a Cinnamon restart. I do not want to have to modify the whole applet so I am looking at a quick fix by checking if the GPU is turned on by the bbswitch function of Bumblebee and if it is off just putting GPU OFF in the temperature display. I expect this to save 1 - 2 Watts which will be significant. The seems to be a suitable file reading command in the JavaScript to get the information by something like:

let bbswitchStatus = GLib.file_get_contents("/proc/acpi/bbswitch");

The Bumblebee And NVidia Display (Band) Applet is a relatively simple applet I wrote for my new Chillblast Defiant laptop which has an Core i7 Haswell architecture and Optimus technology to switch between the integrated Intel 4600 graphics and discrete nVidia GTX 765M graphics. The switching is done by use of Bumblebee. This Applet allows one to monitor whether the power consuming discrete graphics is on and display the GPU temperature, but only when it is enabled. Monitoring the temperature requires the graphics processor to be turned on every time it is measured - some applets do this all the time and that uses a significant extra amount of power.

The right click context menu gives the ability to easily run the nVidia Settings program without use of the terminal and also the System Monitor and Power Statistics, all useful for monitoring Bumblebee and power consumption which is paramount when using a laptop on batteries.

The standard left click menu provides a configurable list of programs which one can run using the discrete nVidia graphics through Bumblebee - this otherwise requires them to be called through optirun in a terminal or via a modified launcher. This list is configured using the standard applet configuration mechanism available from Cinnamon 1.8 (Cinnamon 2.0 required for this to be on the right click menu). One can also configure the update rate of the applet in settings.

The applet requires at least Cinnamon 1.8 and 2.0 is desirable to access the configuration from within the applet. Bumblebee and the nVidia graphics packages obviously need to be installed but no other packages are needed. Installation is standard and the folder bumblebee@pdcurtis is extracted from the zip file to ~/.local/share/cinnamon/applets and then added to the panel.

Kdenlive Mint 16 Petra

I found it told be that libx264 was missing. It actually needed libx264-dev as well .

Bluetooth Mobile Phone Tethering not working on the Defiant.
A General Mint 16 Petra and Ubuntu 13.10 issue.

Bluetooth was one of the last issues to address on the Defiant and I have some slightly mixed results on what I have tried. The bluetooth Applet is new in Cinnamon 16 in that it is now in the Cinnamon Settings but closely based on what went before with gnome-control-center. It works fine for pairing my two phones and a bluetooth audio receiver which enable me to pass audio to the hifi on the boat or house without wires. The Audio receiver then works fine as expected.

However I make major use of bluetooth to access modems in my older phones and use the spare data allowances for internet access in the UK. I have covered this at length in Adding Spices to Ubuntu - Bluetooth and Connecting to the Internet via Bluetooth modems in phones but unfortunately this does not work seem to work under Mint 16 Petra. Eventually I went back to the Mint 15 Olivia and it works fine on the Defiant both using the inbuilt mechanisms through the network manager and also through gnome-ppp which is my usual way as there has been a problem starting at kernel 3.8 with the inbuilt mechanism. Neither way works under Petra and this seems to be a real bug but one not reported and I have filed a bug report at https://github.com/linuxmint/cinnamon-bluetooth/issues/5. This is not a problem with the Defiant but one which I believe affects every machine running Petra and probably Ubuntu Saucy. I suspect few people 'tether' using bluetooth these days although I know at least one sailor who has hauled his phone up the mast to get a good data connection at sea.

I have more recently checked tethering using an Ubuntu 13.10 Saucy LiveUSB and it is present there as far as I can tell so it is an issue of Gnome or Ubuntu rather than specific to any modifications in Mint16 Petra.

I have also done some more investigation and it looks as if the changes which have been made mean that the Bluetooth connections which are made automatically are not being completed before gnome-ppp or the network manager are attempting to use them. If one watches the bluetooth settings screen one can see that it takes a couple of seconds for the connection to be made after gnome-ppp starts to connect by which time it has produced the error messages. A way round this is to start a bluetooth connection manually and then run gnome-ppp. I used a higher value for the rfcomm device (/dev/rfcomm) than had been set up in /etc/bluetooth/rfcomm.conf

The connection can be started in my case by

sudo rfcomm connect /dev/rfcomm5 00:0E:07:2C:E8:82 1

You will have to use your own bluetooth device address and channel for DUN connections found by:

hcitool scan
sdptool search DUN

The connection can be broken by ^C in the terminal window, or if you have closed it by:

sudo rfcomm release /dev/rfcomm5
If you look in the file manager you can see the device being created and removed.

http://comments.gmane.org/gmane.linux.bluez.kernel/42303 seems to refer to a similar problem on Arch Linux with BlueZ 5.13 and has a suggested patch.

This is all an inconvenience and I still believe nothing to do with the Defiant - I just want to remember what I did somewhere!

NUMA thoughts

I have been requested to enhance NUMA to automatically select the interface to monitor. This has consequences when one is using PPP interfaces which generally the Network Manager does not know about.

 

Part 1 (February - June 1996) || Part 2 (June - September 1996) || Part 3 (October 1996 - March 1997) || Part 4 (April 1997 - December 1997) || Part 5 (January 1998 - December 1998) || Part 6 (January - December 1999) || Part 7 (January 2000 - December 2001) || Part 8 (January 2002 - June 2003) || Part 9 (June 2003 - August 2003) || Part 10 (August 2003 - April 2007) || Part 11 (May 2007 - September 2007) || Part 12 (October 2007 -December 2007) || Part 13 (January 2008 - August 2008) || Part 14 (September 2008 -> June 2009) || Part 15 (July 2009 -> August 2009) || Part 16 (September 2009 -> December 2009) || Part 17  (January 2010 -> October 2010 ) || Part 18 (November 2010 -> December 2010) || Part 19 (January 2011 - September 2011) || Part 20 (October 2011 - March 2012) || Part 21 (April 2012 - July 2012) || Part 22 (August - September 2012 ) || Part 23 (October 2012 - December 2012) || Part 24 (January 2013 - December 2013) || Part 25 (January 2014 - December 2014 || Part 26 (January 2015 - December 2015 || Part 27 (January 2016 - October 2016) || Part 28 (November 2016 -> ) || Back to the home page

Home Pauline's Pages Howto Articles Uniquely NZ Small Firms Search
Height Padding

Copyright © Peter and Pauline Curtis
Most recent significant revision: 6 th, December 2013

Valid HTML 4.01