Keyturns's picture

I downloaded the "TurnKey Revision Control version (13.0)" to have a git server. This image was created on Oct 28th 2013 and runs git version 1.7.10.4. The most recent git version as of Feb 2015 is 2.3.0, so the TKL VM git version is a bit out of date now and I'd like to update it.

How do I update my git version to 2.3.0?
Will an "apt-get install git" command do an update?
Will a new TKL Revision Control VM come out with updated git and OS parts?

Forum: 
Tags: 
Jeremy Davis's picture

The Debian (and a very common Linux) way is to favour stability at the expense of "latest and greatest". Security is covered by backporting security fixes to the 'frozen' version that is included... In TurnKey these security patches are auto installed.

On a Windows system users get used to having to constantly update software to avoid security issues. Usually new versions have new features (which are usually good) but also often have new bugs too and/or can conflict with other software. Often they will have newer dependencies as well so the operating system often gets bloated (and less secure with more attack vectors) with multiple versions of the same frameworks and libraries. But Debian (specifically; but often Linux in general) does things very differently. I must admit that when I first made the jump to Debian I missed the excitement of having new stuff to check out - but it was soon replaced with the joy of just being able to get my work done...

Whilst the down side with Debian is that sometimes the software is a little old; the upside is that it is rock solid stable and really low maintenance. It is a well thought out and executed system. Unless you have a really good reason why you need a newer version of git (e.g. some feature you really need that is only in newer versions) or you are just really bored and want to play with your system then I would leave it be...

Specific answers to your questions:

How do I update my git version to 2.3.0?
There are a number of different ways, none of them particularly easy and all of them will require that for ever after you will need to maintain it manually to keep it secure. That will most likely require you to upgrade to each new version as it is released (assuming that it contains security issues).

If you do have a good reason to upgrade git version and 1.9 is new enough then v1.9.1 is in backports. There are still downsides to that but it is probably your best/easiest option.

Will an "apt-get install git" command do an update?
Sort of... It will update to the latest version in the repos. However the latest version in the repos will only be an incremental update (the official version of the software will be the same). And as usually these updates are security related chances are that it is already installed.

Will a new TKL Revision Control VM come out with updated git and OS parts?
Yes. But the next TurnKey release will be 13.1 which will be a maintenance release. It will be the same base OS (Debian Wheezy) and will include the same version of git. It will have all the security updates preinstalled though so it won't have to download a ton of stuff on first boot (or the first night it's left running if you don't allow the firstboot scripts to install security updates).
Then sometime after the next stable version of Debian is released (which will be Jessie - still currently in testing) we will release v14.0 (based on Jessie). It will include newer versions of everything including git. Although possibly to your disappoint it will likely include git v2.1.4. Jessie is currently frozen pending release; meaning that it is in it's final testing stages and versions aren't allowed to be updated unless there are showstopper type bugs.

Any idea on how to update GIT version from 2.1.4 on this appliance ?

Thanks

Paul


Jeremy Davis's picture

The way that Debian works is that the versions are frozen for the life of the release (security issues and selected bug are fixed via back ported patches). That is essentially what "stable" means in context to Debian. Basically the APIs/commanline switches/command output remain stable for the life of your OS.

So if you want a newer version, you are recommended to upgrade. You can either do that via migrating your data to a new server, e.g. via TKLBAM. Or you can do an "in place" Debian style upgrade (TurnKey is Debian under the hood after all, so as a general rule, Debian instructions should mostly apply). Both options have their pros and cons, and both may require manual interventions and adjustments along the way. Special note re the Debian in place option, please make sure that you have a "clone" or "snapshot" style backup of the whole server (or if running locally, a copy of the original ISO and a tested TKLBAM backup) as once you start, there is no backing out and no rollback functionality...

Unfortunately, we don't have any real documentation to cover either of those scenarios, although the TKLBAM route is somewhat covered in an old doc page. That page explicitly covers migrating TO v14.x (not from v14.x) but the theory is still the same, just that the specific software related notes don't apply.

FWIW moving to v15.x (based on Debian Stretch) will give you git v2.11.0 - I also note that stretch backports has v2.20.1 although I wouldn't neccessarily recommend installing from stretch-backports at this late stage (unless you really need to). Buster (what our upcoming v16.x will be based on) also has v2.20.1. You could in theory also do a Debian "in place" upgrade to Buster, but please note that none of our packages are yet uploaded for Buster, so I'm uncertain of what results you might get (although it should work I imagine)...

I have been trying the migration route as couldn't get the in place upgrade to work for Debian 8 to 9.

Created a new backup on turnkey hub of the v14 machine which has bitbucket installed.

Created a new virtual machine with postgres v15 appliance.
Then attempted a restore. In webmin control panel very confusing you hit backup or restore and you do not get any progress or confirmation dialog so hard to know what is going on.

I ran  tklbam-restore and this restored the files but I got this error

database: root                                                                                                                              
pg_restore: [archiver] unsupported version (1.13) in file header                                                                            
database: bitbucket                                                                                                                         
pg_restore: [archiver] unsupported version (1.13) in file header 

In webmin if I go to the postgres server panel I do not have my bitbucket database.

Is that correct or do I need to manually create the database before I do the restore?

Thanks

Paul

 


 


Solve the problem by updating the v15 postgres appliance via apt-get update and it upgrade. This updated the version of the database I ran the restore again and it worked okay.


Jeremy Davis's picture

Great to hear that you got it to work! Good thinking on updating PostgreSQL.

I wonder what was going on there? It must have been a bug in PostgreSQL which they've since resolved... Thanks on posting the fix you discovered. I'll file that away as I'm sure that someone else will benefit from that info.

Good stuff. :)

Add new comment