Page tree
Skip to end of metadata
Go to start of metadata

This howto was written for installation of Ubuntu 18.04 on a Dell XPS 15 9570 laptop. They may well work on other laptops.

1 Preliminary steps on Windows prior to installing Ubuntu

  1. Install the latest BIOS onto your laptop under Windows

  2. Install any chipset drivers that are available on the Dell web site onto your machine

  3. Find and record your Windows 10 license key, you will need this if you want to run Windows 10 in a VM in Virtualbox in Ubuntu
    At the WIndows command line run

    wmic path SoftwareLicensingService get OA3xOriginalProductKey
  4. Find and record the type of Windows 10 license you have, at the Windows command line run

    slmgr -dli

2. Create a bootable USB

To do this on Ubuntu, follow these instructions: Create a bootable USB stick with Ubuntu 18.04.

3. Preparation for Dual Boot

This step is optional.

If you want to keep the pre-installed windows on your computer (and install Ubuntu on an other partition), you'll need to create a partition for it. To create the empty partition in Windows:

  • Boot into Windows and start the application called "Create and format hard disk partitions"
  • Right click on the biggest partition and shrink it to 100-500GB
  • Create a new partition in the freshly created space

The Ubuntu partition resizer function may also be used to resize the Windows partition but it has not been tested here.

If you want to change between Ubuntu and Windows later, you'll need to reset the following BIOS options to their original values:

  • AHCI mode
  • Disable Windows Boot Manager

4. BIOS Settings

Power up PC and press F2 to enter the BIOS

  • Enable SATA mode so that Ubuntu can see your hard disk

Go to System Configuration->SATA Operation

Select AHCI mode

  • Disable Windows Boot Manager

Go to General->Boot sequence

Disable Windows Boot Manager

  • Configure Thunderbolt. If you don't do this, the dock integration for USB can be flaky

Go to System Configuration->Thunderbolt Adapter Configuration

Check "Enable Thunderbolt Boot Support" and "Enable Thunderbolt (and PCIe behind TBT) Pre-Boot Modules

Disable Disable Thunderbolt security (Set to no security)

Press Apply followed by Exit

5. Install Ubuntu

5.1 Boot off Ubuntu Install USB stick

  1. Insert boot USB drive into computer
  2. Boot Dell PC and press F12 to access BIOS
  3. Select second "UEFI" partition 2 entry + The laptop will boot off Ubuntu setup disk
  4. Click on "Install Ubuntu 18.04.1 LTS" desktop icon
  5. Follow installation instructions and select options as appropriate and as you like them

5.2 Wireless Network Settings

Use the following settings for connecting to an enterprise wireless network:

5.3 Third Party Software and Secure Boot

  • Check "Install third-party software...." check box
  • Check "Install third-party drivers....."
  • Check "Configure Secure boot"
  • Select "Configure Secure Boot"

Enter a password here, this password is used during secure boot to confirm that the drivers you have installed are verified. You will be asked for this password the next time you boot but it seems to be a one time thing.

5.4 Disk Encryption

In Europe, You MUST set up disk encryption to comply with European GDPR and other security requirements.

On the "Installation Type" pane:

  • Select "Erase disk and install Ubuntu"
  • Select (Encrypt the new Ubuntu Installation for security"
  • Click "Install Now"

In "Choose a security key" enter a strong password.

This is your disk encryption password, ensure you remember it because you will be asked for it each time you boot the computer. The only way to reset it is to reinstall the computer.

5.5 Complete Ubuntu Installation

  • Complete the installation
  • Remove the USB key and reboot

6. Update Ubuntu Software

Once the computer boots, you can login. You should update the software on the computer to the latest version that is available on the software repository. You can use the "Software Updater" utility. To do this, select it by using the "Super-A" key and cliking on its icon. Alternatively use the commands below:

sudo apt update
sudo apt upgrade
sudo apt dist-upgrade
sudo apt autoremove

Bluetooth is ropey on all but the very latest firmware. Ensure that the linux firmware package is at version 1.173.2 or better with the command:

dpkg -l | grep linux-firmware

If not, make sure to take the firmware upgrade to at least version 1.173.2.

Reboot your computer.

7. Install BIOS Update on Ubuntu

At the time of writing, the latest BIOS version for Dell XPS 15 9570 laptops is 1.10.1. The latest BIOS updates are at the Dell support site.

You only need to do this if you forget to update the BIOS in Windows prior to installing Ubuntu or if you are updating the BIOS after installing Ubuntu.

Follow these instructions from Dell to install a BIOS update on a Linux laptop.

The laptop may very well boot a number of times if there are multiple BIOS updates in the BIOS update package.

7.1 Unbricking a laptop bricked by a BIOS update

Following this procedure has, on one occasion, resulted in a temporary bricking of a laptop.

If the BIOS update bricks your laptop, it reports progress of 100% on the BIOS update and freezes at that screen. If this happens, you cannot do anything with the laptop, even long-holding the power button does not work. The laptop fan runs very fast if this happens.

The only option to unbrick the laptop is to drain the laptop battery and let it shut down.

  • Disconnect the power from the laptop
  • Leave the laptop until it drains the battery and shuts down

Now charge the laptop for 10-15 minutes to get a small amount of power into the battery. At this point, pressing the Laptop power button will not power on the laptop.

  • Hold the power button for 45 seconds to a minute
  • Eventually the "Dell" welcome screen shows up

You may have to try holding the power button a few times to get the laptop back.

Now, complete installation of the BIOS updates:

  • Reboot the laptop
  • The remainder of the BIOS updates should now install

8. Configuring your Ubuntu Machine

8.1 Install Gnome Tweaks

Gnome Tweaks allows you to change font sizes and stand customize fonts, colours and other attributes of your desktop.

sudo apt install gnome-tweaks

Gnome Tweaks is now available under Super-A as the Tweaks application.

Font settings that work well are:

  • Window Title: 11
  • Regular: 9
  • Sans Regular: 9
  • Mono Regular: 11

8.2 Thunderbird email client

Thunderbird works well for corporate mail hosted on Microsoft Office 365 with normal authentication.

Office 365 hosted mail works fine with IMAP/SMTP configuration so use whatever email client you like. Here’s the Thunderbird settings, adapt them for your email client of choice:

To set up Calendar support in Thunderbird, use the command below to install the Thunderbird Lightning plugin

sudo apt install xul-ext-lightning

The Exchange EWS Provider allows you to synchronize your Thunderbird calendar with an Exchange server on Microsoft Office 365.

  1. Clone the Exchange EWS provider from github

    git clone https://github.com/ExchangeCalendar/exchangecalendar.git
  2. Check out the latest tagged version for the latest version of Thunderbird (currently v5.0.0-alpha3)

    git checkout tags/v5.0.0-alpha3
  3. Build the Thunderbird plugin

    make
  4. Install the plugin in Thunderbird

    1. Thunderbird->Add-ons->Add-ons

    2. Click Extensions in the left pane and then click on the drop down menu beside the "gear" icon

    3. Click "Install Add-on from File..."
    4. Browse to the directory where you built the Exchange EWS Provider plugin
    5. Select the exchangecalendar-v5.0.0-alpha3.xpi file

    6. Click the "Install" button on the warning dialogue

    7. Restart Thunderbird

8.3 Evolution email client

Evolution is a good choice for Office 365 accounts with secondary authentication. Thunderbird does not support secondary authentication.

Compared with Outlook, the support for mail in Evolution could be classed as about 7 out of 10, the support for corporate Calendar and Tasks in Evolution could be classed as 3 out of 10. Viewing calendar appointments and setting individual appointments works pretty well but for recurring meetings you probably should use Outlook on the web or running in a Windows VM.

Install the EWS (Exchange Web Service) version of Evolution

sudo apt install evolution-ews

Start Evolution and configure for your mail account

To add another account, use Edit→Preferences→Accounts→Add and the process is similar to above.

8.4 Install a certificate for secure mail

8.4.1 Generate a certificate

Use whatever mechanism your organization recommends for generating a certificate. Once the certificate has been generated and downloaded, it should be in a file with a name such as mycert.p12. You should also have received a password or passphrase for your certificate.

8.4.2  Installing your certificate in Evolution

  • Edit→Preferences
  • Click Certificates
    • Click Import
    • Enter the password of your certificate
  • Click Mail Accounts

You can now read and send encrypted mails.

8.4.3 Installing your certificate in Thunderbird

  • Preferences→Advanced
  • Click "Certificates" tag
  • Click "Manage Certificates"
  • Click "Your Certificates"
  • Click "Import..." and import your certificate

8.5 Application Shortcuts in Ubuntu

To create shortcuts in Ubuntu for apps see this howto.  Save the <whatever>.desktop file to ~/.local/share/applications for it to show up in Gnome as an application.

8.6 Spotify

Not critical for work but indulge me!

Download Spotify from the Spotify web site.

8.7 To get special characters like é and Ó

To get special characters on the keyboard, set a compose key. It allows you to get Irish Fadas, French graves/acutes and Swedish Umlauts etc, see this site.

  • Start Gnome tweaks (Super-A→Tweaks)
  • Keyboard & Mouse
  • Click Compose Key "Disabled"
  • Select the key you want to be your compose key

8.8 KeypassXC for Passwords

Unless you have a fabulous memory, KeepassXC, utility is very useful for managing passwords

sudo apt install keepassxc

The keepass2 application is now available under Super-A. Add your password entries.

On an entry on the Keepass2 list, CTRL_U opens the URL, CTRL_B copies the username for keepass2 for pasting, and CTRL_C copies the password for pasting.

8.9 The Zoom Conferencing System

To install Zoom

Zoom depends on the libxcb-xtest0 package, install that using the following command:

sudo apt install libxcb-xtest0

Now install Zoom

sudo dpkg -i <the zoom package>.deb

In Zoom, the location for selecting an input/output source (eg if you are using bluetooth headphones) is hidden on a popup window activated by clicking on the little inverted v icon to the right of the microphone icon.

8.10 Internet Bookmarks

  • Export your bookmarks on your old laptop
  • Import your bookmarks
  • uBlock Origin is a good ad blocker for Firefox, install it using the addons menu in Firefox

8.11 Dell Docking Station

You may need to unplug and plug back in the docking station to recognize the keyboard and mouse. You may be asked to authenticate them. See the BIOS settings above to get USB support working smoothly between the laptop and the docking station.

8.12 Other Applications

There are loads of software applications in the Ubuntu software "App manager". have a look in there for various things. A few that work well are:

  • WhatsDesk for WhatsApp
  • VLC (Video swiss knife)
  • Gimp (Photoshop killer)
  • Inkscape (Vector Gaphics editor)
  • Sublime Text Editor

8.13 Ubuntu/Gnome Keyboard Shortcuts

There are many shortcuts defined, see the Gnome cheatsheet for a complete list.

8.14 Google Chrome Apps

Google Chrome has a feature that allows Google Chrome "apps" to be installed in Gnome. Web "apps" such as Facebook and WhatsApp can be integrated into Ubuntu in this way, and, although they are running as Chrome web pages, they look like Ubuntu applications.

  • Download and install Google Chrome (In all fairness ye don’t need to be told how to do this)
  • Launch Chrome, Menu→More Tools→Extensions
  • Go to chrome://apps
  • Right Click on an app such as Google Drive and click "Create Shortcuts.."
  • Select the shortcuts you want and the "app" appears as an Ubuntu application

8.15 Startup Applications

You can define applications that are started when you login. Use the Startup applications utility (Available under Super-A) to define these.

8.16 Pidgin for Instant Messaging

Pidgin is a SIP client that has been adapted to work with Skype for Business. It works fine for chatting on Skype for Business and for one to one audio calls. Support for conference calls is claimed but has not been seen working yet in our environment.

You need a special prototype version of Pidgin (Pidgin Sipe) to work with Skype for Business. You must add the pidgin sipe repo to apt on your laptop and install pidgin as follows:

sudo add-apt-repository -y ppa:sipe-collab
sudo apt update
sudo apt install -y pidgin pidgin-sipe

Start Pidgin and add your account

  • Go to Accounts→Manage Accounts
  • Click Add...
    • Protocol: Office Communicator
    • Username: wile.e.coyote@acme-corporation-desert-deliveries.com
    • Password: <blah>
  • For accounts with Office 365 secondary authentication
    • Advanced Tab:
    • Authentication Scheme: NTLM
  • For accounts with normal Office 365 authentication
    • Advanced Tab:
    • Connection Type: Auto
    • User Agent: UCCAPI/15.0.4420.1017 OC/15.0.4420.1017
    • Authentication Scheme: TLS-DSK
  • Click "Add"

You should now be able to do IM and audio calls to/from Skype for Business

8.16.1 Set up a chat (IM) session to another user

You must know the SIP address of the other user. If the other user is a Skype for Business user, their SIP address will be sip:<email-address>

  • Go to Buddies→New Instant Message...
  • In the "Name:" field, enter "sip:road.runner@acme-corporation-desert-deliveries.com"

8.16.2 Enable one to one voice call to another user

In order to call other users, you must first set them up as a buddy

  • Go to Buddies→Add Buddy...
  • Select the appropriate account in the "Account" dropdown menu
  • Set the user name of your buddy as their email address in the "Buddy's username" field: "sip:road.runner@acme-corporation-desert-deliveries.com"

Your buddy is now on your buddy list in the Pidgin main window.

To make a call to your buddy, select their entry on the list and right click→Audio Call

8.17 System unresponsive / freezes after suspend/resume

There seems to sometimes be a weird issue with graphics drivers / USB drivers / power modes. After the laptop resumes from suspend it appears to freeze and or fail to respond to keyboard/mouse/touchpad. Even with the latest (June 2019)  BIOS, NVIDIA graphics drivers, Synaptics touchpad drivers, Linux kernel, xserver-xorg-*, etc. Fix at https://www.dell.com/community/Linux-General/XPS-15-9570-with-Ubuntu-18-04-1-not-resuming-after-suspend/m-p/6128710 appears to solve the issue.

8.18 Problems with Suspend/Resume

Suspend of laptop does not work on HP laptops once you connect an external display. Even if you disconnect the display and close the laptop lid after disconnecting, the laptop will not suspend. The steps outlined in this post seems to solve the issue.

9. Install Windows and MS Office in Virtualbox

You may need to install Windows in order to participate in Skype for Business conferences and to manage your Outlook calendar properly. You can use the license of the Windows software that came with the computer even if it is running in the VM.

9.1 Install Virtualbox

sudo apt install virtualbox
sudo apt-get install virtualbox-guest-utils virtualbox-guest-x11 virtualbox-guest-dkms

9.2 Download Windows

Download an ISO image of Windows that is licensed on your host (such as Windows 10 64 bit) from this Microsoft site.

9.3 Install Windows 10 in Virtualbox

9.3.1 Create a VM in Virtualbox for Windows 10

  • Start Virtualbox
  • Create a VM for Windows 10, click "New"
    • Name: Whatever
    • Type: Microsoft Windows
    • Version: WIndows 10 (64 Bit)
  • Click "Next" for the next few panes accepting all the default values

You now have created a VM for Windows 10.

9.3.2 Set the Windows ISO file on the VM

  • Select the VM you just created and right click selecting Settings
  • Select "Storage"
    • Under Controller SATA select the Optical disk "Empty" Entry
    • On the Attributes pane, click on the optical disc icon
    • Click Choose a virtual optical disk file and browse to the Windows 10 ISO you just downloaded
  • Select audio
    • Tick the "Enable Audio Input" check box
  • click OK

9.3.3 Install Windows 10

To get the Windows product key in Ubuntu, run the command:

sudo cat /sys/firmware/acpi/tables/MSDM

Start your VM and configure Windows

  • Select your language and on the next pane, click "Install Now"
  • When asked for a product key, enter it now
  • Accept the EULA click Next
  • When asked for the install type, click "Custom ...."
  • Select the 50 GB drive for installation and click Next

Windows now installs and the VM reboots. Following the VM reboot, carry on with the installation:

  • Set the keyboard/region/language and so on
  • When asked if install is for personal use or organzation, select "Personal Use"
  • When asked to sign into Microsoft, click "Offline Account" in the bottom left corner (It's hard to see!)
  • Click "No" on the next screen to not set up an online account
  • Create an account, set up a userid and password
  • Set your security questions and set the next options as you wish

Windows now sets up and installs. When the installation completes, check your Windows license is activated, at a Windows command prompt enter:

slmgr -dli

The result should say License Status: Licensed

9.3.4 Install Windows updates

  • In the control Panel, go to Settings→Check for updates
  • Install any updates that are available
  • reboot the VM

9.4 Install MS Office

Some Office 365 account allows you to download and install Microsoft Office. Others do not.

  • In a web browser, sign into Office365 with your Office 365 credentials at this site.
  • Click on the "Install Office" link on the right of the Office 365 home page to download the Office 365 installer
  • Make sure to select the 64 bit version of Office365
  • Run the installer to install Office365

9.5 Install Virtualbox Display Drivers

Virtualbox display drivers allow scaling of your Windows screen to work correctly. To install them:

  • Run your Windows 10 VM
  • Select Devices→Insert Guest Additions CD Image
  • Follow the instructions to download the Guest Additions CD, mount the CD on the VM and install the Windows 64 Bit enhancements on the VM
  • Install the enhancements and you will be able to resize the Windows VM window on the fly

9.6 Configure the VM sound for Headphones

There is a sound setting that improves the audio quality of headphones in Windows. This works well for USB headphones.

  • In the Windows VM, right click on the speaker icon (Bottom right corner)
  • Select Spatial Sound→ Windows Sonic for Headphones

9.7 Bluetooth Headset Sound Issues on Virtualbox

The headset settings for Bluetooth headsets on your Ubuntu laptop and on the Windows VM can get out of sync. Each time you use the VM, ensure the Ubuntu sound settings are the same as what they were when the VM was restarted in order not to have to restart the VM again. In other words, the VM does not follow live switching of Ubuntu sound devices. Do the following:

  • Set the sound settings on Ubuntu to the sound devices you wish to use
  • Start your Windows VM and then reboot the VM

Sound should then work properly.

10 Software Development Setup

  1. Install java 8

    sudo apt install openjdk-8-jdk

  2. Install git

    sudo apt install git
  3. Install maven

    sudo apt install maven
  4. Install meld,  meld is a graphical tool for doing git merges

    sudo apt install meld
  5. Configure your ~/.gitconfig so that git uses meld for merges. Edit the file and add the lines:

    [merge]
    tool = meld
  6. If you prefer to use nano (instead of vi) as your default git commit message editor, configure git to use nano with line length <120 (e.g. 72), soft word-wrapping and  line-numbers: 

    git config --global core.editor  "nano -l --fill=72"
    git config --global sequence.editor "nano"

Install Eclipse

This Howto has been verified to work with the following Eclipse versions:

  • Oxygen
  • Photon
  • 2019-06

11.1 Save your current settings

  • File→Export→Preferences
  • Click Next
  • Check "Export All"
  • Select export location
  • Transfer saved EclipseSettings.epf file to new machine

11.2 Download and Install Eclipse

  • • Download Eclipse from eclipse.org
  • Unzip the installer and run it
  • Install the Eclipse IDE for Java developers

11.3 Recommended Eclipse Plugins

11.3.1 Plugins from the Eclipse repositories

The following Eclipse plugins from the Eclipse repositories are recommended:

  • Javascript Development tools
  • Eclipse Web Developer Tools
  • Dynamic Languages Toolkit - ShellEd IDE (for bash scripting)

11.3.2 Plugins from the Eclipse Marketplace

The following Eclipse plugins from the Eclipse Marketplace are strongly recommended:

  • SonarLint
  • Eclipse Checkstyle plugin

The following Eclipse plugins from the Eclipse Marketplace are also useful:

  • JSON Editor Plugin
  • Yaml Editor
  • JAutoDoc

Install Lombok into Eclipse

  • Download the Lombok jar
  • Execute the jar by double clicking on it or giving the following command in a terminal

    java -jar lombok.jar
  • If your Eclipse installation does not appear on the list, browse to the install location of your Eclipse install
  • Click the "Install/Update" button
  • Lombok is now installed on your Eclipse installation, restart Eclipse
  • You may need to do a maven→update for the changes to be reflected in your error/warming messages
  • (NB: Many classes in the ONAP Policy Framework use Lombok to generate getters/setters etc, so will not compile in Eclipse without installing Lombok for Eclipse)