"A human being should be able to change a diaper, plan an invasion, butcher a hog, conn a ship, design a building, write a sonnet, balance accounts, build a wall, set a bone, comfort the dying, take orders, give orders, cooperate, act alone, solve equations, analyze a new problem, pitch manure, program a computer, cook a tasty meal, fight efficiently, die gallantly. Specialization is for insects." (Robert A. Heinlein)
Showing posts with label Ubuntu. Show all posts
Showing posts with label Ubuntu. Show all posts

Saturday, 7 July 2018

The joy of virtualization: Docker


I took a relative pause from experimenting with Raspberry Pi to report my first experiences with something completely different. One of the first things you realize while programming server-side is how your program is only one piece of a bigger puzzle. Your application usually runs inside a container, connects to a database, expose or consume services and so on ... Solving this puzzle means defining an installation procedure that becomes different and sometime more complex by changing or scaling the installation target.

Docker

Docker is an container platform that overcomes the installation problems by producing a ready-to-install standardized operating-system-level virtual machine, packed with everything your application needs to be run. Unlike other virtualization solutions a Docker image only contains what your application needs without having to install and run a full hardware simulation like, for example, in Virtual Box.

Installation

Docker is available in two versions a professional “enterprise” edition and a community one (Docker CE) free to download. Installing Docker CE on Ubuntu is just matter of adding Docker repository address
sudo apt-get update

sudo apt-get install apt-transport-https ca-certificates curl software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo apt-key fingerprint 0EBFCD88
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
Then installing it using the usual apt command
sudo apt-get updatesudo apt-get install docker-ce
Once the installation completed the current user, or any user who will use Docker, must be added to the “docker” group.
sudo adduser maxx docker
After logging out and in again Docker was ready for use and command
docker info
Correctly reported the empty environment initial state

First run

In order to test Docker is correctly installed and running a simple “hello-world” image is available. Just by calling the command:
docker run hello-world
Docker take care of downloading the image from its repository, installing and running it.

Another interesting image to start with is, as suggested in hello-world printout, the “ubuntu” image that installs and starts a console-only Ubuntu virtual machine with no effort.

Friday, 27 May 2016

Upgrading (the EEEPC) with low disk space


When, while installing Xubuntu, I decided EEEPC disk partitioning I based my decision on previous installation typical disk usage worrying mostly about “/home” and “/usr” partitions. I never would have thought about running out of space in the root “/” partition.
Then, the first time I tried to upgrade to latest Xubuntu distribution I got an error message about disk free space on partition being not enough to download distribution files (that usually take a little less than 1GB of disk space). Examining disk free space I discovered that very little free space was left on the root partition even if it was more then enough after my post-installation check.
Fortunately AskUbuntu came quickly at recover: here I quickly found a question asked from who had the same problem. To be precise the question was about problems with “/boot” partition low disk space bat I suppose it was because of a different partitioning schema, by the way solution worked for me.

Cleaning “apt-get” leftovers

As I learned from AskUbuntu question some of the “lost” disk space might be occupied by unused files or apt-get temporary files. So simply by executing the following commands …
sudo apt-get autoremove
sudo apt-get clean
some disk space can be set free.

Removing old Linux kernel images

If free space gained from the previous operation isn't enough some more space can be obtained by removing old Linux kernel images. Every time Ubuntu upgrade to e new kernel release the old one is kept available in to be used to solve possible compatibility issues. Such feature is scarcely user and is of no use at all in the eve of a major distribution upgrade.
First the currently used Linux kernel must be identified the command …
uname -a
does the job, here is the current output
Linux eeepc900 4.4.0-21-generic #37-Ubuntu SMP Mon Apr 18 18:34:49 UTC 2016 i686 i686 i686 GNU/Linux
while the command …
dpkg -l 'linux-image*'
lists all Linux kernel images currently installed, here is a sample output:
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-==============-============-============-=================================
un linux-image <none> <none> (no description available)
un linux-image-3. <none> <none> (no description available)
rc linux-image-3. 3.19.0-15.15 i386 Linux kernel image for version 3.
rc linux-image-3. 3.19.0-28.30 i386 Linux kernel image for version 3.
rc linux-image-3. 3.19.0-33.38 i386 Linux kernel image for version 3.
rc linux-image-3. 3.19.0-43.49 i386 Linux kernel image for version 3.
ii linux-image-3. 3.19.0-56.62 i386 Linux kernel image for version 3.
ii linux-image-4. 4.2.0-34.39 i386 Linux kernel image for version 4.
ii linux-image-4. 4.4.0-21.37 i386 Linux kernel image for version 4.
rc linux-image-ex 3.19.0-15.15 i386 Linux kernel extra modules for ve
rc linux-image-ex 3.19.0-28.30 i386 Linux kernel extra modules for ve
rc linux-image-ex 3.19.0-33.38 i386 Linux kernel extra modules for ve
rc linux-image-ex 3.19.0-43.49 i386 Linux kernel extra modules for ve
ii linux-image-ex 3.19.0-56.62 i386 Linux kernel extra modules for ve
ii linux-image-ex 4.2.0-34.39 i386 Linux kernel extra modules for ve
ii linux-image-ex 4.4.0-21.37 i386 Linux kernel extra modules for ve
ii linux-image-ge 4.4.0.21.22 i386 Generic Linux kernel image
eventually older kernel images can be removed with an “apt-get” command like the following, changing of course the version number
sudo apt-get -y purge linux-image-x.yy.z-tt-generic linux-image-extra-x.yy.z-tt-generic linux-headers-x.yy.z-tt linux-headers-x.yy.z-tt-generic
If you look deeper in AskUbuntu answer you'll see that more complex scripts can be used to make the operation faster. I stopped here, I don't like automating too much when deleting things and, after all, this it's I problem I get into at most twice a year. So … I can do it manually

Monday, 28 March 2016

Test Drive: Ubuntu Mate 16.04 on the EEEPC


Here I am, again, doing some “test-drive” on the EEEPC 900 and some newly released Linux distribution. Even thought I found, with Xubuntu, a stable lightweight solution for my old netbook still I'm looking curiously to what other lightweight solutions have to offer. After reading about the soon to be released Ubuntu-Mate 16.04 and its new so called “Mutiny” desktop layout, I so decided to download and give it a try.

A quick look ...

After boot Ubuntu Mate 16.04 welcomes you with the usual reassuring old styled desktop. In addition a handy welcome application is started too.

Wednesday, 6 January 2016

Ubuntu 15.10: Some post installation fix


After upgrading my desktop computer to Ubuntu-Gnome 15.10 I went on with installing software packages I needed and it took me a while to notice there were problems in my network disk mounts. I had the configuration copied from the previously backed-up “fstab” configuration file. Everything was working fine before upgrading but in the new installation the system started with the configured Samba shares unavailable. Manually re-executing the mount sequence (with command “sudo mount -a”) solved the problem until next reboot.
I checked the system log and got the following error message:

Jan 3 11:15:05 veritons661 kernel: [ 20.826880] CIFS VFS: Error connecting to socket. Aborting operation.
Jan 3 11:15:05 veritons661 kernel: [ 20.827770] CIFS VFS: Error connecting to socket. Aborting operation.
Jan 3 11:15:05 veritons661 mount[680]: mount error(101): Network is unreachable
Jan 3 11:15:05 veritons661 mount[680]: Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)
Jan 3 11:15:05 veritons661 kernel: [ 20.828593] CIFS VFS: cifs_mount failed w/return code = -101
Jan 3 11:15:05 veritons661 systemd[1]: media-nas.mount: Mount process exited, code=exited status=32
Jan 3 11:15:05 veritons661 systemd[1]: Failed to mount /media/nas.
Jan 3 11:15:05 veritons661 systemd[1]: Dependency failed for Remote File Systems.
Jan 3 11:15:05 veritons661 systemd[1]: remote-fs.target: Job remote-fs.target/start failed with result 'dependency'.
Jan 3 11:15:05 veritons661 systemd[1]: media-nas.mount: Unit entered failed state.
Apparently, during the boot process, the system tried to mount network drives before the network was up and ready. I quickly discovered I wasn't alone with my problem, AskUbuntu pages offered some solutions. The first I tried, using the “_netdev” mount option in order to force the system to wait for the network to be ready, didn't work for me. The second solution has been configuring the network shares to be mounted only at the first access using “noauto” and “x-systemd.automount” mount options.
Here is how my “fstab” configuration looks like:

# NAS
//192.168.0.110/sh_maxx /media/nas cifs noauto,x-systemd.automount,x-systemd.device-timeout=3,uid=maxx,credentials=/home/maxx/.smbcredentials,iocharset=utf8,sec=ntlm,file_mode=0777,dir_mode=0777 0 0
# Public
//192.168.0.110/public /media/public cifs noauto,x-systemd.automount,x-systemd.device-timeout=3,guest,uid=maxx,iocharset=utf8,file_mode=0777,dir_mode=0777 0 0
The network shares are now correctly mounted and there is no noticeable delay at first access. Only Nautilus seems to have been driven a little crazy about it since it shows drive icons doubled.

Thursday, 3 December 2015

Ubuntu 15.10 “Wily Werewolf” on Veriton S661 (full install)

After almost one year I managed, just in these days, to change my Internet provider and have back my land-line ADSL connection. First things first, I started with updating my home desktop computer (the Acer Veriton S661) I left mostly unattended during this period since my mobile Internet contract was barely enough for daily connectivity needs. Unfortunately it seems my computer has been left too much without upgrading and the update process halted signaling many “404” errors while accessing to different repository locations. May be I could find another solution to upgrade my system but, since I usually keep the “/home/” folder on a separate partition, I decided to go for a complete re-installation of latest Ubuntu-Gnome release.

The installation process

I proceeded with installing as usual, prepared a USB disk with Ubuntu's tool, booted from it and went on with installing. On order to maintain my separate home partition I selected the custom “Something else” installation type



Friday, 31 July 2015

Test Drive: Ubuntu Mate 15.04 on the EEEPC 900


Ubuntu Mate is a Ubuntu derivative distribution equipped with Mate desktop environment. Ubuntu Mate has been recently admitted among the official Ubuntu derivatives, I've been reading some very positive post about it so I decided for giving it a quick (live) look on the EEEPC even if I had already reinstalled my netbook computer with Xubuntu,

First impressions

After the usual process of preparing a USB disk an booting the netbook from it I've been welcomed from a very Gnome-2-looking interface.
The default interface provide the usual Applications, Places and System menus:

Thursday, 12 March 2015

Test Drive: Ubuntu-Gnome 15.04 (Beta 1) on the EEEPC 900

As my hardware is getting old I start living the usual “Upgrade season” with more anxiety than eagerness. The question “Will the computer still work with the new release” becomes every year more fundamental and eventually I enter in a sort of “No-news-good-news” spirit where shorter new features list are welcomed while every novelty is looked with suspicious.
So I downloaded the newly released Ubuntu-Gnome 15.04 (Vivid Vervet) in order to test it on my old netbook mostly to see if it would continue working properly after being upgraded.

The test

I booted the EEEPC from my USB disk and, after a quite short boot time, I've been taken to the usual “Install or Try it” welcome screen:

Sunday, 2 November 2014

Upgraded to Ubuntu 14.10 “Utopic Unicorn”


I took advantage of the first week-end just after Ubuntu release date to upgrade both my desktop (Veriton S661) and my netbook (EEEPC 900) computers. Everything went quite smooth this time, here is a brief report on how the upgrade activities went.

Before to start

Since 14.04 is a LTS release the upgrade to a “ordinary” release must be explicitly enabled in the “Software & Updates” configuration tool.
Also, remembering problems I had last time I updated, I temporarily disabled the screen-lock.

Sunday, 28 September 2014

Test drive: Ubuntu-Gnome 14.10 “Utopic Unicorn” on the EEEPC


Like every year the Ubuntu (second) upgrade season is coming. Like every year I'm taking e brief test of beta releases in order to have preview of novelties and, most important, possible problems. I downloaded so both the latest Ubuntu-Gnome ISO disk image (Utopic Unicorn Beta 1) and prepared a bootable SD card to test it on the EEEPC.

First impressions

The live disk with Ubuntu-Gnome booted in a reasonable time, welcoming the user with the usual flat-looking Gnome-Shell look
at a first view there are no big news (no news good news especially on old computers) but after a deeper look some interesting novelties appear.
First in the top-right menu a “location” option has been added:

Saturday, 3 May 2014

Upgraded to Ubuntu 14.04 … (one way or another)

Ubuntu spring update has arrived, this year coinciding with Easter. As soon I had time I proceeded with upgrading my two computers. The upgrade process has not been as smooth as I'd liked but at the end I managed to have both computer up-to-date.
 

Acer Veriton S661

I started the upgrade process on my desktop computer and, after answering the usual initial “agree” and “confirm”, I left the computer unattended for the long file download part of the upgrade process. When I returned the computer had the screen locked and I couldn't manage to unlock it anymore. After many attempts I decided for the most drastic solution: forcing the computer to restart. The result has been the most drastic too: the computer refused to boot.
I've been so forced to download a Ubuntu disk image and proceed with a full installation. The installation procedure recognized, fortunately, the incomplete Ubuntu set-up and offered a “Reinstall Ubuntu 14.04” option. Re-installation from disk proceeded flawlessly and eventually I got my system mostly restored apart from some custom system files which have been overwritten.
Must be said that, since, I'm not new to similar problems, I have my home folder mounted on a separate partition. So, even if I need to format the boot disk, I have no fear for my data.

EEEPC 900

After the experience of upgrading the desktop computer I disabled the screen-lock on the EEEPC before starting the upgrade application. The upgrade process proceeded without any problems.
The EEEPC works fine with the new Ubuntu-Gnome release but it shows some odd error message during boot I never noticed before:
Sometimes, just after GRUB menu, it gives a worrying message about a malformed file, in addition it shows this message later during the boot process.
[drm:i915_stolen_to_physical] *ERROR* conflict detected with stolen region: [0x7f800000 – 0x80000000]
I'll check soon on the 'net for possible causes of these problems but I could also decide for a fresh install of the whole system.

Saturday, 8 March 2014

Test Drive: Ubuntu-Gnome 14.04 “Trusty Tahr” on the EEEPC 900


It's almost one month before Ubuntu's spring update time. As soon as first alpha then beta releases are made available I take some time to have a look at them. Since the EEEPC is the oldest computer I actually use the first question I ask myself before every upgrade is: “Will the new release work fine on my old netbook?”. I so downloaded the latest (beta-1) available preview of Ubuntu Gnome edition and prepared my USB disk for a brief evaluation.

Yes, It works!

The short answer is: yes, it works. Ubuntu-Gnome booted in the usual featureless screen
Gnome Shell is as responsive as before, the new versions show some (welcome) differences in the application launcher where smaller icons and a different scroll-bar look are used

Thursday, 31 October 2013

Upgraded to Ubuntu 13.10 “Saucy Salamander”



This is just a short post to report about the upgrade of my two computers to the latest Ubuntu release. I upgraded just after the distribution release (Saturday 19) but various problems kept me from writing about it.


Wednesday, 9 October 2013

Test Drive: Ubuntu-Gnome 13.10 “Saucy Salamander” (Beta 2) on the EEEPC


After testing the latest Ubuntu release I proceeded my test session with Ubuntu-gnome edition. Ubuntu-gnome is the distribution I have installed on the (actually) oldest computer I have, the EEEPC 900. Trying a distribution without installing becomes so the “go/no-go” condition for when the official upgrade will be released. Even if Linux distributions are generally benevolent with older hardware you'll never be sure if and how your system will work without testing.

First impressions

As usual, I prepared a bootable USB disk with the Ubuntu's tool and a booted my EEEPC from it.
Ubuntu-gnome is provided with Gnome-Shell 3.8. The interface is quite similar with the version shipped with previous Ubuntu release.

Saturday, 28 September 2013

Test drive : Ubuntu 13.10 “Saucy Salamander” (Nightly Build)


The upgrade season is coming again. As I do twice a year I downloaded from Ubuntu download page the currently available version (not called beta anymore) of the October Ubuntu release. I prepared my USB disk in order to test the incoming release live on my computers.

On the EEEPC 900

After booting from the USB disk everything proceeded regularly until I arrived to the “Try or Install” screen. The top panel appears oddly expanded down to almost half screen.

Wednesday, 26 June 2013

Back to Ubuntu : installed Ubuntu Gnome 13.04 on the EEEPC


I've been using Mint 12 on the EEEPC since February 2012. it worked fine all this time but, what I really missed was the ability to upgrade the distribution to a new release without the need of a full installation. After the recent positive test I eventually decided to install on my net-book Ubuntu Gnome 13.04.

Installation

As usual the installation process begun by backing-up my home folder and preparing a bootable USB disk. I booted the EEEPC from the USB disk and started the installation program. The installation sequence was definitively the same I encountered while installing Ubuntu. Like then, the only interesting part has been the disk partitioning part. I use the 4GB SSD EEEPC disk as boot disk for windows (I like to play some old games every now and then) so I must be sure the installation goes all on the 16GB secondary SSD.
I selected the “Something else” custom partitioning option that brings to the partition editor.
Unfortunately the disk partitioning tool is bigger than the EEEPC 900 screen: here is the full window (I got it with the 'alt-print screen' screen-shot shortcut)

Thursday, 23 May 2013

Ubuntu 13.04 on Veriton S661 (Full Install)


It's time of major upgrades for my desktop computer: I just bought a graphics card and a bigger hard-drive. Knowing I was going to hardware-upgrade kept me from upgrading to Ubuntu 13.04 as soon as it's been made available. I was going soon to have to install it on the new drive.
To be precise I didn't exactly put the new drive on my desktop computer: I bought a new 1TB hard-drive I put on my NAS. It's the 500GB drive I previously used in the NAS the one I placed in the desktop.
So, after copying all the data to the new drive I booted from a USB drive and I begun to install.

Partitioning the disk

I've never been a many-partitions advocate but, with a 500GB disk, some partitioning is needed. I decided to partition the disk with GParted before starting the installation. I split the disk in two partitions of about a one-to-four ratio plus a little 5GB partition to be used as swap.
since I use my desktop computer mostly for home video and slide-shows editing the bigger partition will be destined to be mounted as /home folder.

Tuesday, 26 March 2013

Test drive: Ubuntu 13.04 Gnome beta (Live) on the EEEPC 900


I'm definitively a Gnome user. I started my Linux adventure with the good-old Gnome 2. I don't like so much version 3, but I switched to it once I realized it kept, at least in part, its flexibility thanks Gnome shell extensions. I'm actually using Gnome 3 on my desktop computer so, once I heard that Ubuntu was going to have an official Gnome derivative distribution, I started thinking of replacing the Linux Mint 12 installation on my EEEPC 900.

First impressions

The daily-build ISO image I downloaded was quite big (about 958 KB) so that I couldn't use my usual old 1GB USB disk. Not a big problem (I used a 4GB SD card) but I really hope they'll manage to keep the disk image size smaller in the definitive version. Once the SD card have been prepared I rebooted my EEEPC. Ubuntu Gnome boots on the usual featureless default Gnome 3 screen
The side-bar, in the activities screen, appears a little too crowded on the small EEEPC display. This, unlike Unity, means dealing with microscopic icons.

Friday, 22 March 2013

Test Drive: Ubuntu 13.04 “Raring Ringtail” Beta on the EEEPC


As usual, with the coming of Spring, also Ubuntu's upgrade season is coming. I so went on the 'net looking for a beta version to give a look at, just to know what to expect when the real upgrade will arrive.

No beta version?

I was a bit startled to learn that beta versions has been released only for derivative distributions while, under new distribution policies, main Ubuntu only goes through a “freeze” period of bug-fixing. I had so to download a “daily-built” version to make my bootable USB disk.

First impressions

Here is the new Ubuntu first screen-shot
apart from some slight graphic change there aren't many changes at a first glance, anyway the new Unity is still fluid and responsive even on my good-old EEEPC 900.

Friday, 26 October 2012

Test Drive: Ubuntu 12.10 “Quantal Quetzal” on the EEEPC


Ubuntu's upgrade season at last arrived. I must say I haven't paid a lot of attention, this time, to the new release (I even missed the beta release date) and to the endless discussions that usually follow any new version. By the way I downloaded Ubuntu and prepared my old 1GB flash drive in order to give it at least a look.

First impressions

The boot time seems good even with the increased disk image size (and my slow flash disk drive). Here is how the new release looks, just after the boot.

Wednesday, 24 October 2012

Upgrading to Ubuntu 12.10 “Quantal Quetzal” (on the Veriton S661)

The upgrade season arrived at last. As soon I got enough free time, last week-end, I started the upgrade process on my desktop computer.


Doing the upgrade


At first, since the installed version was a LTS one, I had to enable notification for any new versions in the “software sources” configuration.
after that the update manager activated the “Upgrade” button