14.4 LTS 64Bit Desktop Installation Guide by Robert Oswald

Ubuntu 14.4 LTS 64Bit Desktop Installation Guide [email protected] 14.4 LTS 64Bit Desktop Installation Guide by Robert Oswald Last Cha...
0 downloads 2 Views 197KB Size
Ubuntu 14.4 LTS 64Bit Desktop Installation Guide

[email protected]

14.4 LTS 64Bit Desktop Installation Guide by Robert Oswald

Last Change: 17.03.2016

Page 1/10

Ubuntu 14.4 LTS 64Bit Desktop Installation Guide

[email protected]

Table of Contents 1 Install Ubuntu 14.4 LTS 64Bit Desktop...........................................................................................3 1.1 Boot Live System From Ubuntu 14.4 LTS Install Medium......................................................3 1.2 Launch Ubuntu Installer...........................................................................................................3 2 Install Additional Software...............................................................................................................3 2.1 Ubuntu Repository Software....................................................................................................3 2.2 Other Software..........................................................................................................................5 2.2.1 LibreOffice........................................................................................................................5 2.2.2 Geary & Shotwell..............................................................................................................5 2.2.3 CherryTree........................................................................................................................5 2.2.4 Kodi...................................................................................................................................5 3 Tips & Tricks....................................................................................................................................5 3.1 Create Swap Space via Swap File.............................................................................................5 3.2 Manual User at Login...............................................................................................................6 3.3 Boot Screen Resolution............................................................................................................6 3.4 Active Directory Domain Membership.....................................................................................6 3.4.1 Installation.........................................................................................................................6 3.4.2 Configure winbind /etc/samba/smb.conf..........................................................................6 3.4.3 Join the Active Directory Domain....................................................................................7 3.4.4 /etc/nsswitch.conf..............................................................................................................7 3.4.5 /etc/pam.d/common-session..............................................................................................7 3.5 Power Saving............................................................................................................................7 3.5.1 Thinkfan............................................................................................................................7 3.5.1.1 Installation................................................................................................................... ................................................................................................................................................7 3.5.1.2 Configure thinkpad_acpi...........................................................................................7 3.5.1.3 Automatic Start..........................................................................................................8 3.5.1.4 Start Thinkfan.............................................................................................................. ................................................................................................................................................8 3.5.2 Various Power Saving Settings.........................................................................................8 3.5.3 NVIDIA Power Saving Settings.......................................................................................8 3.6 Clean Up Boot Filesystem........................................................................................................8 3.7 Play CSS encrypted DVDs.......................................................................................................8 3.8 VI .tiny......................................................................................................................................9 3.9 Online Results in Dash.............................................................................................................9 3.10 Change Bluetooth Device Name.............................................................................................9 3.11 Watch DVB-T with VLC........................................................................................................9 3.12 LTS Enablement Stacks..........................................................................................................9 4 Full System Backup..........................................................................................................................9 4.1 Introduction...............................................................................................................................9 4.2 Open LUKS Encrypted Filesystem.........................................................................................10 4.3 Backup....................................................................................................................................10 4.3.1 Master Boot Record (MBR)............................................................................................10 4.3.2 Filesystems......................................................................................................................10 4.4 Restore....................................................................................................................................10 4.4.1 Master Boot Record (MBR)............................................................................................10 4.4.2 Filesystems......................................................................................................................10

Last Change: 17.03.2016

Page 2/10

Ubuntu 14.4 LTS 64Bit Desktop Installation Guide

[email protected]

1 Install Ubuntu 14.4 LTS 64Bit Desktop 1.1 ● ●

1.2 ● ● ●

● ● ● ● ●

Boot Live System From Ubuntu 14.4 LTS Install Medium System Settings→ Text Entry → Add Input source "German (eliminate dead keys)" Select German keyboard layout with the upper panel tray icon

Launch Ubuntu Installer Choose your language and press “Continue” If your computer complies the requirements press “Continue” Suggested disk partitioning ○ sda1 = 1 GB → /boot ○ sda2 = encrypted remain ○ swap space will be created later via swap file Press “Install Now” Select your time zone and “Continue” Choose your keyboard layout (German-eliminate dead keys) Enter name, username, password and computer name Continue

2 Install Additional Software 2.1

Ubuntu Repository Software

This script installs a compilation of profitably software like multimedia codecs, applications etc. : APTGET="apt-get -y install" check_inst() { if [ $? != 0 ]; then echo "something was going wrong!?" exit fi } $APTGET openssh-server check_inst $APTGET ubuntu-restricted-extras check_inst $APTGET icedtea-plugin check_inst $APTGET putty check_inst $APTGET xul-ext-lightning check_inst Last Change: 17.03.2016

#Codecs: mp3, wmv, flash etc.

Page 3/10

Ubuntu 14.4 LTS 64Bit Desktop Installation Guide

[email protected]

$APTGET wireshark check_inst $APTGET zenmap check_inst $APTGET gufw #firewall GUI check_inst $APTGET ding check_inst $APTGET traceroute check_inst $APTGET audacity check_inst $APTGET avidemux check_inst $APTGET faac gpac check_inst $APTGET project-x check_inst $APTGET dosbox check_inst $APTGET inkscape check_inst $APTGET blender check_inst $APTGET openshot check_inst $APTGET isomaster check_inst $APTGET devede check_inst $APTGET gimp check_inst $APTGET luminance-hdr check_inst $APTGET asunder #CD ripper check_inst $APTGET dvdbackup #DVD ripper check_inst $APTGET transcode check_inst $APTGET vlc check_inst $APTGET freemind check_inst $APTGET pyrenamer check_inst $APTGET keepnote check_inst $APTGET unison unison-gtk Last Change: 17.03.2016

Page 4/10

Ubuntu 14.4 LTS 64Bit Desktop Installation Guide

[email protected]

check_inst $APTGET geary check_inst $APTGET keepassx check_inst $APTGET mp3val check_inst $APTGET vlan check_inst $APTGET handbrake check_inst

2.2 • •

2.2.1

Other Software VirtualBox Mixxx

LibreOffice

To get the latest version add the LibreOffice PPA. add-apt-repository ppa:libreoffice/ppa apt-get update apt-get dist-upgrade

2.2.2

Geary & Shotwell

To get the latest version add the yorba PPA. add-apt-repository ppa:yorba/ppa apt-get update apt-get remove shotwell-common apt-get upgrade

2.2.3

CherryTree

To get the latest version add the PPA. add-apt-repository ppa:giuspen/ppa apt-get update apt-get install cherrytree

2.2.4

Kodi

To get the latest version add the PPA. add-apt-repository ppa:team-xbmc/ppa apt-get update apt-get install kodi kodi-pvr-vdr-vnsi

3 Tips & Tricks 3.1

Create Swap Space via Swap File

Create 2 GB swap file. Last Change: 17.03.2016

Page 5/10

Ubuntu 14.4 LTS 64Bit Desktop Installation Guide

[email protected]

dd if=/dev/zero of=/swapfile bs=1024k count=2048 Set up a Linux swap area. mkswap /swapfile Setup correct file permissions for security reasons. chown root:root /swapfile chmod 600 /swapfile Activate /swapfile swap space immediately. swapon /swapfile Add the following line to /etc/fstab. /swapfile swap swap defaults

3.2

0

0

Manual User at Login

If you like the opportunity to enter a username manually at login add the following file: /etc/lightdm/lightdm.conf [SeatDefaults] greeter-show-manual-login=true

3.3

Boot Screen Resolution

If the boot resolution does not fit your screen resolution you can change it in /etc/default/grub by adding the line: GRUB_GFXPAYLOAD_LINUX=1680x1050x32. (xx) Afterwards you need to run update-grub to generate a new /boot/grub/grub.cfg.

3.4 3.4.1

Active Directory Domain Membership Installation

First of all install the necessary packages. apt-get install winbind libnss-winbind libpam-winbind

3.4.2

Configure winbind /etc/samba/smb.conf

Backup the original file and replace it with the following content. [global] workgroup = MYDOMAIN netbios name = ERWIN000 server string = %h with Samba %v realm = MYDOMAIN.DE Last Change: 17.03.2016

Page 6/10

Ubuntu 14.4 LTS 64Bit Desktop Installation Guide

[email protected]

allow trusted domains = no idmap config * : range = 50000-59999 idmap config MYDOMAIN : default = yes idmap config MYDOMAIN : backend = rid idmap config MYDOMAIN : read_only = yes idmap config MYDOMAIN : range = 50000-59999 winbind use default domain = yes winbind enum users = yes winbind enum groups = yes winbind offline logon = yes winbind refresh tickets = yes winbind cache time = 1 template shell = /bin/bash security = ADS local master = no encrypt passwords = true

3.4.3

Join the Active Directory Domain

net ads join -U

3.4.4

/etc/nsswitch.conf

passwd: group:

3.4.5

compat winbind compat winbind

/etc/pam.d/common-session

... pam_unix.so session required

3.5

pam_mkhomedir.so

umask=0077

Power Saving

To increase the running time when on battery power some power saving options are useful and may help to extend the battery running time significantly.

3.5.1

Thinkfan

Thinkfan is a simple software to regulate the fanspeed on Thinkpad Laptops. Further detailed information are provided on http://thinkpad-wiki.org/Thinkfan. 3.5.1.1

Installation

apt-get install thinkfan

3.5.1.2

Configure thinkpad_acpi

Create a file /etc/modprobe.d/thinkfan.conf with the following line. options thinkpad_acpi fan_control=1

Reload the thinkpad_acpi kernel module. modprobe -r thinkpad_acpi modprobe thinkpad_acpi

Last Change: 17.03.2016

Page 7/10

Ubuntu 14.4 LTS 64Bit Desktop Installation Guide 3.5.1.3

[email protected]

Automatic Start

/etc/default/thinkfan: START=yes

3.5.1.4

Start Thinkfan

service thinkfan start

3.5.2

Various Power Saving Settings

Add the following lines to /etc/rc.local to get them activated on system boot. These options maybe are available on non-Thinkpad laptop as well. #Switch off Wake-on-Lan ethtool -s eth0 wol d #Switch off bluetooth echo "disable" > /proc/acpi/ibm/bluetooth

3.5.3

NVIDIA Power Saving Settings

Add the following lines into the device section of /etc/X11/xorg.conf to get brightness control enabled (if it is not working by default), reduce graphic performance to minimum on battery power and set graphic performance to adaptive strategy on AC power. Option “RegistryDwords” “EnableBrightnessControl=1; PerfLevelSrc=0x2233; PowerMizerDefault=0x3”

Alternative with adaptive strategy on battery and AC power but maximum to medium level on battery. Option “RegistryDwords” “EnableBrightnessControl=1; PerfLevelSrc=0x3333; PowerMizerDefault=0x2”

3.6

Clean Up Boot Filesystem

As we kept the boot file system small when separating it from the encrypted partitions it tend to run out of enough free space after several kernel updates because the normal update process does not remove the previous kernel images. The following command removes all kernel versions except the actual running. Never remove the actual running kernel! sudo apt-get purge `dpkg -l | \ egrep 'linux-headers-3.13.0|linux-image-3.13.0' | grep -v \`uname -r | \ cut -b 1-8\` | awk -F\ '{ print $2 }'`

3.7

Play CSS encrypted DVDs

Install the necessary css library with the following command. sudo /usr/share/doc/libdvdread4/install-css.sh

Last Change: 17.03.2016

Page 8/10

Ubuntu 14.4 LTS 64Bit Desktop Installation Guide

3.8

[email protected]

VI .tiny

Enable cursor keys to navigate when using vi in insert mode. Edit /etc/vim/vimrc.tiny as shown below. set nocompatible

3.9

Online Results in Dash

Disable online results when searching in Dash in System Settings → Security & Privacy → Search.

3.10

Change Bluetooth Device Name

Change the name by editing the file /var/lib/bluetooth//config. ... name ubuntu-0 …

3.11

Watch DVB-T with VLC

It is supposed that w_scan and vlc is already installed on the computer. Otherwise they can easily be installed from the repository by the following command. sudo apt-get install w-scan vlc First scan for channels and generate a channels.conf file which is later used by vlc. It is suggested to place the file into a hidden folder named .vlc within your home directory. mkdir .vlc w_scan -c DE -X > .vlc/channels.conf Now launch vlc and open the channels.conf file (Media → Open File). After selecting it the TV and radio channels should be displayed ready to enjoy.

3.12

LTS Enablement Stacks

The Ubuntu LTS enablement stacks provide newer kernel and X support for existing LTS releases. These can be installed manually, or are automatically shipped if installing from newer point releases media. Install HWE kernel and X from 15.10 (Wily): sudo apt-get install --install-recommends linux-generic-lts-wily \ xserver-xorg-core-lts-wily xserver-xorg-lts-wily \ xserver-xorg-video-all-lts-wily xserver-xorg-input-all-lts-wily \ libwayland-egl1-mesa-lts-wily

4 Full System Backup 4.1

Introduction

A reliable way to backup and restore the encrypted hard drive is to boot from ”sysrescuecd” (http://www.sysresccd.org/) and use dd and fsrachiver. Last Change: 17.03.2016

Page 9/10

Ubuntu 14.4 LTS 64Bit Desktop Installation Guide

[email protected]

After the Live-System has started you can launch the graphical desktop by entering the command wizzard, but it´s only necessary if you like to use the graphical tool gparted to edit you partitions. Be careful with dd, it does what you say and doesn´t ask!

4.2

Open LUKS Encrypted Filesystem

cryptsetup luksOpen /dev/

4.3 4.3.1

Backup Master Boot Record (MBR)

Check out where the first partition beginns (fdisk -lu /dev/sda). Device Boot /dev/sda1 * /dev/sda2

Start 2048 2000896

End 2000895 1953523711

Blocks 999424 975761408

Id 83 83

System Linux Linux

Now we use dd to save the first blocks of our harddrive up to the beginning of the first partition. dd if=/dev/sda of=/to/backup/mbr.dd bs=512 count=2048

4.3.2

Filesystems

fsarchiver -v savefs /dev/sda1 /to/backup/sda1.fsa fsarchiver -v savefs /dev/mapper/rootvolume /to/backup/sda3.fsa

4.4 4.4.1

Restore Master Boot Record (MBR)

Use dd to save the first blocks of our harddrive up to the beginning of the first partition. dd if=/to/backup/mbr.dd if=/dev/sda

4.4.2

Filesystems

fsarchiver -v restfs /to/backup/sda1.fsa id=0,dest=/dev/sda1 fsarchiver -v restfs /to/backup/sda3.fsa id=0,dest=/dev/mapper/rootvolume

Last Change: 17.03.2016

Page 10/10