17 Aug 2014

Disclaimer: this was posted 21-11-2014, but it was written around 17-08-2014.

This post details the update from my server "broek" from Ubuntu 12.04.1 to 14.04.1 (both LTS). Broek is now running 12.04.1 and 14.04 (the new LTS) has been available for half a year so I will try to update to that.

The initial steps:

  • upgrade webmin to newest version
  • update packages
  • updated owncloud to 7.0.1 (from 6) - had to force and upgrade database through web interface
  • updating to 14.04.1 lts: sudo do-release-upgrade

I get this warning (as always):

This session appears to be running under ssh. It is not recommended
to perform a upgrade over ssh currently because in case of failure it
is harder to recover.

If you continue, an additional ssh daemon will be started at port
Do you want to continue?

To make recovery in case of failure easier, an additional sshd will
be started on port '1022'. If anything goes wrong with the running
ssh you can still connect to the additional one.

If you run a firewall, you may need to temporarily open this port. As
this is potentially dangerous it's not done automatically. You can
open the port with e.g.:
'iptables -I INPUT -p tcp --dport 1022 -j ACCEPT'
  • Now I find that the disk is too full. The partition /boot is 100% full:
Not enough free disk space

The upgrade has aborted. The upgrade needs a total of 55.6 M free
space on disk '/boot'. Please free at least an additional 55.6 M of
disk space on '/boot'. Empty your trash and remove temporary packages
of former installations using 'sudo apt-get clean'.

I manually clean up the /boot and retry the do-release-upgrade. I get warnings about config files that are modified in the update:

  • /etc/sysctl.conf was changed - keep current
  • /etc/samba/smb.conf - keep current
  • /etc/ppp/pptpd-options - keep current
  • /etc/pptpd.conf - keep current
  • /etc/apache2/ports.conf - keep current
  • /etc/rsyslog.conf - keep current

It restarts but I can't SSH in. When I turn on the monitor it turns out it hangs because no keyboard is plugged in (the old keyboard that was plugged in apparently died). When connecting a working keyboard it continues normally after pressing F1.

Deleted Ubuntu One NFS share through webmin. When booting saw that is was still mounted. Ubuntu One has been discontinued by now.


I tried to create an extra Owncloud account and notice that Owncloud can't be reached. Actually no Apache sites can't be reached. This is probably because of the Apache configuration change that expects all resources in /var/www/html instead of /var/www that was done in Ubuntu 14.04.

Moving everything from /var/www to /var/www/html works, but I get when accessing Owncloud I'm greeted with the message:

[14] SQLSTATE[HY000] [14] unable to open database file

I figured I would modify the file /var/www/html/owncloud/config/config.php. There is an entry datadirectory and I changed the path here also to /var/www/html/owncloud/data. Now Owncloud works again!

  • tested VPN: it works!
  • tested external owncloud access (subdir of main domain): it works.

External Subdomains

Tested external subdomains (virtualhosts): they don't work, probably because of the move to /var/www/html. When running sudo a2ensite subdomain.mdworld.nl (subdomain is a placeholder for one of the actual subdomains) I get:

ERROR: Site subdomain.mdworld.nl does not exist!

This seems to be because in this version of Apache the configurations in /etc/apache2/sites-available (e.g. subdomain.mdworld.nl) need to end in .conf. So I renamed it to subdomain.mdworld.nl.conf and ran:

sudo a2ensite subdomain.mdworld.nl # (without .conf!) 
sudo service apache2 restart

Now it works again.

boot partition

/boot was 228MB and it gets full pretty fast. I considered making it about 1.5GB, but apparently it should not be necessary to resize the /boot partition. Since at least 2013 Ubuntu should clean up old kernels automatically and otherwise the policy should be to run apt-get autoremove manually. It actually seems cleaner already, I now have 141MB available on /boot.


When logged in as admin under admin settings I get this warning:

Security Warning

Your data directory and your files are probably accessible from the internet. The .htaccess file is not working. We strongly suggest that you configure your webserver in a way that the data directory is no longer accessible or you move the data directory outside the webserver document root.

There is a .htaccess file in /var/www/html/owncloud/data, but it seems all my .htaccess files are being ignored. I configured them in /etc/apache2/httpd.conf. This no longer exists. I now have Apache 2.4.7 and apparently it's now necessary to modify /etc/apache2/sites-available/000-default.conf. In this conf I add:

<Directory "/var/www/html/owncloud">
AllowOverride All

This works!

Then I couldn't access owncloud from "semi local" network (between modem and router) because the ip was not in trusted domains. Added the ip to /var/www/html/owncloud/config/config.php and it worked without restarting any services.

Now I notice that on my desktop, in the Owncloud client there is an error. It seemed to work before but now it says: csync failed to access webdav

Client version is now 1.6.2 but server 7. I thought this was the problem, but these are apparently the newest versions. Reinstalling is adviced, but I decide to investigate further. When I access https://localhost/owncloud/remote.php/webdav/public it has some kind of error.

Looking at the code for Client.php you can see it throws those exceptions when curl throws an error.

The manual installation page states that curl is an optional dependency, not required, so I disabled it in php.ini (comment out the line that says extension=php_curl.dll), restarted IIS and it got rid of the error on the Admin page and also fixed my sync clients.

I forgot to change the paths to the public and protected subsites (which were moved to /var/www/html) in the admin settings. This seems to work now.

To do

  • When logged in through SSH, I sometimes get the message: no talloc stackframe at ../source3/param/loadparm.c:4864, leaking memory
  • When running a2ensite I get: perl: warning: Setting locale failed.
  • I might want to re-enable third party sources in the sources.list