Ubuntu 13.04 'Raring Ringtail' installation and reference
July 2013Just put this on an old box, finally got it working after 3 installs. Didn't seem to like some old Nvidia card I have or the machine's on-board video adapter. Once I've tested this and maybe resized my main computers HD and tried it on that, want to get it on a compatible laptop.
Overall impression is that it's a very useable and clean OS, more than capable of running everthing I need - and also a valid alternative to Windows 8. This aside, it's worth adding that to get up and running with all the apps/services and connections you will need is fast and simple. As with anything you can delve deeper into the Linux platform and learn more about its complexities as an ongoing process later.
It's worth mentioning that it is possible to break the OS and require a fix a Linux newbie will find very difficult to sort out. For this reason it would be recommended to use the system sensibly, and common things to be careful with would include:
- Switching to propriety hardware drivers that might not work
- An installation procedure freezing or failing in some way half way through
- Messing up the system settings in something like Compizconfig app
- Installing any old package that might not be best for the version of Ubuntu
Also the default file manager is too basic, it really needs a tree view on the left and the layout has far too much empty space between items.
So here is a log and reference for this project - since there can be varying ways of doing these different tasks, I've tried to include only sources which worked first time and got the job done as simply as possible.
In the sections below I either list the steps or the title will be a link to a page by someone else, denoted by » after the section title.
Document navigation
InstallingOS/Platform overview
First things to do after installing
Software to install
Reference for common tasks
Web server systems and utils
Securing Ubuntu on a network
Backup implementation
Other recommended software
Useful links
My requirements
- Wireless and Ethernet LAN connectivity
- Apache, PHP, MySQL, with PHPMyAdmin and some sort of config tool
- Development grade text editor
- Image editing + detects my camera drive etc
- Samba and VNC connectivity to Windows
- Google Earth app
- Low risk of data loss/backup of files and databases etc
Installing
Making a bootable USB flash drive to install Ubuntu (using Windows) »
Faster than making and using a r/w DVD, this is the way to go. (This util will rename your USB stick volume label as PENDRIVE for some reason)
Faster than making and using a r/w DVD, this is the way to go. (This util will rename your USB stick volume label as PENDRIVE for some reason)
Installing to dual-boot with Windows
Choose try Ubuntu first to see if it runs and is ok with your video driver and so on.
- In Windows, make some free un-partitioned space on a drive. In my case I only had a single internal HDD with Windows and all my data on it. Choose Shrink Volume in Computer Management - Disk Management and make the adjustment to suit.
- Boot with the USB drive attached, choose the option to select boot device from the BIOS screen
- (Ubuntu install loads) Select language & select Install Ubuntu
- Check download updates & install 3rd party software
- Installation Type window - choose to Install Ubuntu alongside other OS (this will detect and use the free HDD space automatically).
- Set timezone
- Set keyboard type
- Username, computername and user password, etc ... followed by OS install till reboot
Video driver workaround for cards that fail during install
- Press the spacebar as soon as the picture of the keyboard/human appears
- Choose your language
- Select "Try Ubuntu without any changes" or install, whatever you are trying
- Press F6
- Select “nomodeset”
- Press Escape
- Type: " i915.modeset=0 xforcevesa" at the end of the command line parameter text
OS/Platform overview
The Ubuntu desktop explained »
- The desktop UI is the "Unity desktop"
- The menu on the left is "the Launcher"
- The top left icon on the Launcher is "the Dash" - used for finding apps etc. Installed something, not yet locked to the Launcher, use this to find and run it
- The top right system tray icons are the "Indicator Menus"
- Application windows integrate their menus into the indicator menu bar at the top of the screen
Some terms explained
- GRUB : GRand Unified Bootloader. Handles booting to multiple operating systems on the machine
- Packages : Applications, modules or libraries and so on
- Dependencies : packages required by another package to function, such as libraries
- Repositories : servers that contains a list of packages, drivers, codecs and libraries. It is up to the package developer to get the package into a repository so people can get it from these. A package manager like Synaptic or Ubuntu Software Center is used to access them.
- sudo : command-line to execute a command as the superuser or another user, used alot to install apps in terminal
- apt-get : command-line for handling packages, as opposed to using Synaptic Package Manager GUI
- dpkg : command-line package manager for Debian Linux which is used to install/manage individual Debain packages (.deb files)
- Debain : a Linux distribution on which Ubuntu is based, when downloading some apps for Ubuntu you will be downloading the Debain file. Although, most web sites will mention which one to get for Ubuntu.
- Wine : allows running of Windows apps on Linux, Mac, FreeBSD, and Solaris. www.winehq.org
Keyboard shortcuts »
- CTRL+ALT+T - console
- Super (what they call the 'windows'/'start' key) - show Dash
- ALT+TAB - switch between running apps
- ALT+F4 - close window
- CTRL+(X,C,V) - Cut, Copy, Paste
- CTRL+A - select all
First things to do after installing
Install updates
Run Software Updater from the Dash:
or open a terminal and type:
A reboot will be required after this to apply the system updates.
or open a terminal and type:
sudo apt-get update && sudo apt-get upgrade
A reboot will be required after this to apply the system updates.
Install Synaptic Package Manager
Install from Ubuntu Software Center, found in the Launcher
Make the Launcher icons smaller
32 is fine as the setting, which is the minimum
Install the Unity Tweak Tool
Install from Ubuntu Software Center, or from Synaptic Package Manager, or in terminal use:
sudo add-apt-repository ppa:freyja-dev/unity-tweak-tool-daily sudo apt-get update && sudo apt-get install unity-tweak-tool
Install Compiz Config Settings Manager (CCSM)
A system tweak tool. Enter the following in terminal to install it.
Warning, altering some things in here can apparently break your desktop, use only to change settings for a required purpose.
Warning, altering some things in here can apparently break your desktop, use only to change settings for a required purpose.
sudo apt-get install compizconfig-settings-manager
Enable workspaces
Launcher - System Settings - Appearance - Behaviour - Enable workspaces
Remove unwanted icons from the Launcher, and add apps to it
To remove an icon, right click and click Unlock from Launcher
To add an icon, run the app and right click it's icon on the Launcher. Click Lock to Launcher
To add an icon, run the app and right click it's icon on the Launcher. Click Lock to Launcher
Turn off "online search results" and "record activity" in Unity Dash
Speeds up using the Dash:
Launcher - System Settings - Privacy - Search Results - include online search results - off
Still in the Privacy window, set Record Activity to off as well
Launcher - System Settings - Privacy - Search Results - include online search results - off
Still in the Privacy window, set Record Activity to off as well
Add day and date to the Indicator Menus
Click the time on the Indicator menu to bring up a shortcut menu ...
Disable animation and fading if you want to improve speed of UI
Launcher - Dash - run "CompizConfig Settings Manager". Effects category, untick Animations and Fading Windows
Software to install
Use Synaptic Package Manager to install:
FileZilla - FTP client GIMP - image editor gnome-nettool - "network tools" in dash - simple IP audit tool Wine - to run Windows apps Google earth - download the .deb file from Google, double click to open in Ubuntu software center to install
FileZilla - FTP client GIMP - image editor gnome-nettool - "network tools" in dash - simple IP audit tool Wine - to run Windows apps Google earth - download the .deb file from Google, double click to open in Ubuntu software center to install
Install Notepad++ Windows app under Wine
- Download Notepad++, save in Downloads in home directory
- Run the installer
- To use: run the file ~/.wine/drive_c/Program Files/Notepad++/notepad++.exe, it will automatically load under Wine.
Install Samba and share folders for Windows network clients
pending
Install Real VNC, remote desktop app
After reboots, seems need to run Dash - "VNC Server (User-Mode)" to be able to connect. Still need to figure out how to start it automatically.
Install a development text editor - Geany
Tastes will vary greatly here, but to get a simple editor with passable features up and running quickly, Geany is
a good choice. Basic features that are required for me are: Remembers open files and shows whats open in a list
for fast switching of source files. Highlighting of code, shows line numbers.
To install: Synaptic - add Geany and install it. Run it and add to Launcher etc.
To install: Synaptic - add Geany and install it. Run it and add to Launcher etc.
Reference for common tasks
How to install .deb packages
These are Debian packages, useable by Ubuntu. Can double click them in Files, which will load it with Ubuntu Software Center, where it
can then be installed.
Or you can use the following terminal command:
Or you can use the following terminal command:
sudo dpkg -i package.deb
Take a screen shot with a menu open
PRTSCN doesn't seem to like taking a screen shot when a menu is active, but there is a better way anyway which can also capture
the mouse pointer if wanted.
Use the screenshot app, included with the OS: Launcher - Dash - "screenshot". Put a delay in of say 10s. Click take screen shot then open your menu and wait. The same save window when pressing PRTSCN will appear to allow you to save the file.
Use the screenshot app, included with the OS: Launcher - Dash - "screenshot". Put a delay in of say 10s. Click take screen shot then open your menu and wait. The same save window when pressing PRTSCN will appear to allow you to save the file.
View running processes and system resources
The equivalent of Windows Task Manager
Launcher - Dash - "system monitor"
Manage drives: mount, partition, format etc
Launcher - Dash - "disks". Use this one, comes with the OS and gets the job done.
Customise the GRUB boot loader menu
Not looked much at this yet, but looks like "GRUB Customizer" is what to go with.
Web server systems and utils
The aim of this section is to get a fully functional development web server system on the Ubuntu localhost.
Install and configure Apache, MySQL & PHP »
The above link is to install Lamp server - acronym for Linux, Apache HTTP Server, MySQL, and PHP, Perl or Python
This method should work fine first time. After completing the steps, browse to http://localhost to see the default Apache 2 index file which says "It works!"
The default www root folder is /var/www
Assuming will test MySQL install success by looking at it in Webmin or PHPMyAdmin ..
The above link is to install Lamp server - acronym for Linux, Apache HTTP Server, MySQL, and PHP, Perl or Python
This method should work fine first time. After completing the steps, browse to http://localhost to see the default Apache 2 index file which says "It works!"
The default www root folder is /var/www
Assuming will test MySQL install success by looking at it in Webmin or PHPMyAdmin ..
Install PHPMyAdmin for sorting out MySQL server dbs
At the prompt during this install, choose Apache 2 server by pressing spacebar to put a check in the box. This worked fine, may be more to do after this to further configure and secure it tho, but should now be possible to connect to http://localhost/phpmyadmin/ to manage MySQL databases on the local machine.
sudo apt-get install phpmyadmin
At the prompt during this install, choose Apache 2 server by pressing spacebar to put a check in the box. This worked fine, may be more to do after this to further configure and secure it tho, but should now be possible to connect to http://localhost/phpmyadmin/ to manage MySQL databases on the local machine.
Install Webmin »
Webmin is a web based system wide administration tool. Can configure Apache and MySQL too.
Once installed browse to https://localhost:10000 to use.
Webmin is a web based system wide administration tool. Can configure Apache and MySQL too.
Once installed browse to https://localhost:10000 to use.
Install MySQL workbench
This is to complement PHPMyAdmin in managing databases.
Download the .deb file from mysql.com and run in Ubuntu software center to install
Download the .deb file from mysql.com and run in Ubuntu software center to install
Make a link to the www folder
If not already done, make a link in your home folder pointing to the Apache web root:
ln -s /var/www ~/www
Turn on error reporting for PHP
and open /etc/php5/apache2/php.ini
change the line: display_errors = Off to On
There are probably other issues here regarding setting Apache into development or production mode or something, but this is what I did to just sort it out.
To restart the web server, use:
sudo gedit
and open /etc/php5/apache2/php.ini
change the line: display_errors = Off to On
There are probably other issues here regarding setting Apache into development or production mode or something, but this is what I did to just sort it out.
To restart the web server, use:
sudo /etc/init.d/apache2 restart
Other recommended software
Shutter
Powerful tool for capturing screenshots
Pinta For simple adjustments, its an alternative to GIMP which can be really annoying at times.
SMPlayer Media player for Ubuntu. Run the following 2 lines in terminal if can't play DVDs:
RawTherapee Digital photo processing application
Darktable Darktable is a good alternative to Adobe's Lightroom application
Device manager app? Not really necessary, but would be usefull.
A better file explorer? Want one with a tree view on the left like Windows Explorer.
Pinta For simple adjustments, its an alternative to GIMP which can be really annoying at times.
SMPlayer Media player for Ubuntu. Run the following 2 lines in terminal if can't play DVDs:
sudo apt-get install libdvdread4 sudo /usr/share/doc/libdvdread4/install-css.sh
RawTherapee Digital photo processing application
Darktable Darktable is a good alternative to Adobe's Lightroom application
Device manager app? Not really necessary, but would be usefull.
A better file explorer? Want one with a tree view on the left like Windows Explorer.
Securing Ubuntu on a network
Firewall
This section deals with setting up Ubuntu's built-in iptables using a basic GUI to improve its security on a network.
In this case I'm using nmap a free open source network exploration and security auditing utility. Only relevant lines from the results are shown below.
To see if a particular port is open, as an example mysql/tcp (3306), use:
From the above, the result is 3306/tcp is not open, so in its current configuration this port is not an issue.
Configure the firewall For my purposes, will configure this as follows:
Add new rule - Advanced - Allow - In - TCP - from 192.168.0.0/24, to 192.168.0.212, for example. This will allow all computers on the local subnet to connect to any network service you have running on the Ubuntu computer.
Another scan after the firewall is up After the firewall is up, a scan from a computer on the local network shows only what has been permitted:
How to see connections to your computer There are many apps and command line utilities for this. A useful GUI one is Net Activity Viewer - netactview (download the .deb file and run it to install in a package manager).
Here is shown an active vnc session, a samba connection and a connection to the local apache web server:
Securing what is accessible The other part of network security relates to configuring what you allow in a secure fashion. For example configuring apache and samba correctly, a good password for VNC etc.
Public wireless Use these wisely, for example don't login to important web services from a public network, since it's possible to capture and decode web logins from the wireless medium. It would be recommended for example in a coffee shop to just research and browse and work on local files etc, not to upload data to a private FTP server or something like that.
Useful links Ubuntu help, firewall
Ubuntu help, Gufw
Ubuntu security
Ubuntu basic security
CERT Guide to Home Network Security
- Ubuntu's firewall is off by default after installation
- The kernel includes the netfilter subsystem to handle IP traffic
- Netfilter uses iptables for acceptance, manipulation or rejection of IP packets
- iptables is the database of IP firewall rules
- Configure iptables using UFW (Uncomplicated Firewall), terminal command-line utility
- or use Gufw, the graphical front end
- To install Gufw, use Synaptic and enter gufw
- System Settings, Firewall Configuration to use it to configure your firewall
In this case I'm using nmap a free open source network exploration and security auditing utility. Only relevant lines from the results are shown below.
nmap -sS -sU -T4 -A -v ubuntu3 PORT STATE SERVICE VERSION 80/tcp open http Apache httpd 2.2.22 ((Ubuntu)) 139/tcp open netbios-ssn Samba smbd 3.X (workgroup: WORKGROUP) 445/tcp open netbios-ssn Samba smbd 3.X (workgroup: WORKGROUP) 10000/tcp open http MiniServ 1.630 (Webmin httpd) 2/udp open|filtered compressnet 68/udp open|filtered dhcpc 137/udp open netbios-ns Microsoft Windows XP netbios-ssn 138/udp open|filtered netbios-dgm 139/udp open|filtered netbios-ssn 520/udp open|filtered route 772/udp open|filtered cycleserv2 1048/udp open|filtered neod2 5353/udp open mdns DNS-based service discovery | dns-service-discovery: | 9/tcp workstation | Address=192.168.0.233 fe80:0:0:0:208:c7ff:feb2:76f3 | 22/tcp udisks-ssh |_ Address=192.168.0.233 fe80:0:0:0:208:c7ff:feb2:76f3 10000/udp open webmin (https on TCP THMPB1:10000) 17338/udp open|filtered unknown 18832/udp open|filtered unknown 29810/udp open|filtered unknown 31195/udp open|filtered unknown 42508/udp open|filtered candp 44185/udp open|filtered unknown 58631/udp open|filtered unknown
To see if a particular port is open, as an example mysql/tcp (3306), use:
nmap -A hostname -p 3306 PORT STATE SERVICE VERSION 3306/tcp closed mysql
From the above, the result is 3306/tcp is not open, so in its current configuration this port is not an issue.
Configure the firewall For my purposes, will configure this as follows:
- Outoing allow all
- Incoming, deny, except:
- http from anywhere (80/tcp)
- samba from my subnet ('service samba')
- webmin from particular host (10000/tcp)
- vnc from particular host (5900/tcp)
- Click unlock, and enter password so you can configure it
- Switch firewall to On
- Incoming: deny
- Outgoing: allow
- Begin adding rules:
- (http) Preconfigured - Allow - In - Service - http - Add
- (samba) Advanced - Allow - In - TCP - from 192.160.0.0/24 - to 192.168.0.212 - 135,139,445 - Add
- (samba) Advanced - Allow - In - UDP - from 192.160.0.0/24 - to 192.168.0.212 - 137,138 - Add
- (webmin) Advanced - Allow - In - TCP - from 192.168.0.100 0 to 192.168.0.212 - 10000 - Add
- (vnc) Advanced - Allow - In - TCP - from 192.168.0.100 0 to 192.168.0.212 - 5900 - Add
Add new rule - Advanced - Allow - In - TCP - from 192.168.0.0/24, to 192.168.0.212, for example. This will allow all computers on the local subnet to connect to any network service you have running on the Ubuntu computer.
Another scan after the firewall is up After the firewall is up, a scan from a computer on the local network shows only what has been permitted:
Scanning ubuntu3 (192.168.0.212) [1000 ports] Discovered open port 80/tcp on 192.168.0.212 Discovered open port 5900/tcp on 192.168.0.212 Discovered open port 445/tcp on 192.168.0.212 Discovered open port 139/tcp on 192.168.0.212 Discovered open port 10000/tcp on 192.168.0.212 Discovered open port 137/udp on 192.168.0.212
How to see connections to your computer There are many apps and command line utilities for this. A useful GUI one is Net Activity Viewer - netactview (download the .deb file and run it to install in a package manager).
Here is shown an active vnc session, a samba connection and a connection to the local apache web server:
Securing what is accessible The other part of network security relates to configuring what you allow in a secure fashion. For example configuring apache and samba correctly, a good password for VNC etc.
Public wireless Use these wisely, for example don't login to important web services from a public network, since it's possible to capture and decode web logins from the wireless medium. It would be recommended for example in a coffee shop to just research and browse and work on local files etc, not to upload data to a private FTP server or something like that.
Useful links Ubuntu help, firewall
Ubuntu help, Gufw
Ubuntu security
Ubuntu basic security
CERT Guide to Home Network Security
Backup implementation
Snyaptic - install sbackup. Add the paths to backup on the local machine and check the parameters etc
This backs up files to .tar archives. When the backup is complete, I personally duplicate the backup file to multiple removeable drives, USB flash drive etc.
Make a link to the backup folder:
This backs up files to .tar archives. When the backup is complete, I personally duplicate the backup file to multiple removeable drives, USB flash drive etc.
Make a link to the backup folder:
ln -s ~/.local/share/sbackup/backups ~