System aktualizacji
Table of Content Zone | |||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||||
Aktualizacja systemu dLibraAktualizacja systemu dLibra w ogólności polega na skopiowaniu do katalogów Serwera i Aplikacji Czytelnika nowych wersji plików. W przypadku poważniejszych zmian konieczna może być też edycja niektórych plików konfiguracyjnych. Trzeba oczywiście wiedzieć które pliki zostały zmienione oraz gdzie je przekopiować. Aby uniknąć potencjalnych błędów związanych z błędnym kopiowaniem plików, zdecydowaliśmy w możliwie najszerszym zakresie zautomatyzować ten proces. W tym celu stworzony został Aktualizator systemu dLibra. Jest to niewielka aplikacja, która pozwala przyśpieszyć proces aktualizacji. W niniejszym dokumencie przedstawione zostaną ogólne zagadanienia związane z instalacją i działaniem Aktualizatora, oraz to jak wygląda aktualizacja przeprowadzana przy użyciu tego narzędzia. Proszę nie uruchamiać Aktualizatora zanim nie zapoznają się Państwo z poniższą dokumentacją. Instalacja AktualizatoraAby zainstalować Aktualizator systemu dLibra należy pobrać archiwum w wybranym formacie
Updating the dLibra SystemIn general, updating the dLibra system consists in copying newer file versions to the server and to the Reader Application. In the case of greater changes, it may be necessary to also edit some configuration files. Off course, the user must know which files have been changed and where they should be copied to. In order to avoid potential errors related to erroneous copying of files, we have decided to automate that process as much as possible. For that purpose, we have created the updater of the dLibra system. It is a small application which makes it possible to accelerate the update process. In this document, we discuss the general issues related to the installation and operation of the updater, and we explain how to do updates with the use of that tool. Please do not start up the updater before you have read the following documentation. Installing the UpdaterIn order to install the updater of the dLibra system, you have to download the archive, in the selected format: dlibra-jnlp-updater.zip lubor dlibra-jnlp-updater.tar.gz. Umieścić jego zawartość w dowolnie wybranej lokalizacji na komputerze na którym zainstalowana jest dLibra.The content of the archive should be placed in any location on the computer on which the dLibra system is installed. The updater is a Java application which makes use of the JNLP protocol. After the first start-up, all the required libraries will be downloaded to the drive, and for the following start-ups, only the possible changes (corrections) in the updater will be downloaded (not the whole application). After the unpacking (and before the first start-up), the updater directory should contain the following files Aktualizator jest aplikacją Javową wykorzystującą protokół JNLP. Przy pierwszym uruchomieniu, na dysk zostaną ściągnięte wszystkie wymagane biblioteki, każde kolejne uruchomienie spowoduje ściągnięcie już tylko ewentualnych zmian (poprawek) w Aktualizatorze, a nie całej aplikacji. Po rozpakowaniu (a przed pierwszym uruchomieniem) w katalogu Aktualizatora powinny znajdować się następujące pliki: jnlp-updater.bat jnlp-updater.sh Skrypty uruchamiające Aktualizator dla systemów Windows i Linux. W przypadku systemów Linuxowych należy pamiętać o wywołaniu poleceniaThe scripts which run the updater for Windows and Linux systems. In the case of Linux system, the chmod +x jnlp-updater.sh przed uruchomieniem skryptucommand should be called. netx.jarnetxjar NETX-LICENSE.TXT Minimalistyczna implementacja protokołu JNLP pozwalająca na wykorzystanie tego protokołu niezależnie od Java Web Start firmy Sun Microsystems.A minimalist implementation of the JNLP protocol which make it possible to use that protocol regardless of the Java Web Start framwork of the Sun Microsystems Inc. company. updater.properties Konfiguracja aktualizatora (por. rozdział "Przed aktualizacją"The updater configuration (see chater “Before Updating”). Przed aktualizacjąInformacje o nowych wydaniach systemu dLibra znajudją się tutaj. W chwili gdy nowa wersja jest publikowana w repozytorium aktualizacji (patrz "Repozytorium oprogramowania dLibra") jest również uaktualniany kanał RSS. Po opublikowaniu nowej wersji systemu dLibra możemy rozpocząć proces aktualizacji. W tym celu należy uzupełnić wartości parametrów w pliku updater.properties oraz założyć konto w repozytorium oprogramowania dLibra. Proszę pamiętać, że wszystkie ścieżki do plików/katalogów powinny być zapisane przy użyciu "/" niezależnie od używanego systemu operacyjnego. Plik updater.properties zawiera następujące parametry konfiguracyjne: general.serverHomeDirectory - katalog w którym zainstalowany jest serwer dLibry general.webappHomeDirectory - katalog w którym zainstalowana jest Aplikacja Czytelnika systemu dLibra. general.target Aktualizator może realizować dwa cele aktualizacji : server lub webapp. Tryb serwer uruchamia aktualizacje serwera (por. Aktualizacja Serwera) natomiast tryb webapp to aktualizacja Aplikacji Czytelnika (por. Aktualizacja Aplikacji Czytelnika). webdav.url - Adres do Repozytorium oprogramowania dLibra webdav.username i webdav.password - Nazwa użytkownika i hasło pozwalające na dostęp do repozytorium oprogramowania dLibra. Przed przeprowadzeniem właściwego procesu aktualizacji należy najpierw wykonać kopie zapasową obecnie zainstalowanej wersji systemu. Zaleca się aby w pierwszej kolejności przeprowadzić aktualizacje serwera dLibry, a następnie zakualizować Aplikację Czytelnika. System umożliwia aktualizację w ramach tej samej tzw. małej wersji, a także pomiędzy małymi wersjami. Na małą wersję składają się dwie pierwsze liczby numeru wersji. przykładowo małą wersją dla 6.1.0 jest 6.1. Aktualizacja w ramach małej wersji następuje automatycznie. Jeżeli chcemy zaktualizować system do innej małej wersji, np z 6.1 do 6.2, musimy przekazać do Aktualizatora parametr z żądaną wersją. Jeżeli dostępne są nowe wersje z samej oraz innej małej wersji to także musimy podać, którą wersję chcemy zainstalować. Before UpdatingFor information about new releases of the dLibra system, see here. When a new version is published in the update repository (see “The Repository of the dLibra Software”, the RSS channel is also updated. After the new version of the dLibra system has been published, the update process can begin. First, the person doing the update should enter parameter values in the updater.properties file and create an account in the repository of the dLibra software. Please remember that all paths to files/directories should be entered with the use of “/”, regardless of the operating system. The updater.properties file contains the following configuration parameters: general.serverHomeDirectory – a directory in which the dLibra server is installed; general.webappHomeDirectory – a directory in which the Reader Application of the dLibra system is installed; general.target The updater can serve two update-related purposes: server or webapp; the server mode starts up a server update (see “Updating the dLibra Server”) while the webapp mode means updating the Reader Application (see “Updating the Reader Application”); webdav.url – an address for the repository of the dLibra system; and webdav.username and webdav.password – the user name and the password which make it possible for the user who is doing an update to access the repository of the dLibra system. Before the actual update process, a backup of the currently installed version of the system should be done. It is recommended that the dLibra server be updated first, before the Reader Application. The system makes it possible to do an update within the framework of the same, ‘small’ version and between ‘small’ versions. The small version consists of the two first numbers of a version number, for example, for 6.1.0, the ‘small’ version is 6.1. An update within the framework of a ‘small’ version is done automatically. In order to update the system to another ‘small’ version, for example, from 6.1 to 6.2, a parameter with the required version must be passed on to the updater. If new versions of the same and of another ‘small’ version are available, the user must also indicate which version is to be installed. An update of a particular version of is enforced with the use of parameter updater.requestedVersion. For example, if we have version 6.1.0 and want to update the system to the 6.2.0 version, we enter the following code in the “updater.properties” file Do wymuszenia aktualizacji do określonej wersji służy parametr updater.requestedVersion. Przykładowo, jeżeli posiadamy wersję 6.1.0 i chcemy uaktualnić system do wersji 6.2.0, to w pliku updater.properties umieszczamy następujący wpis:
Należy pamiętać, aby po aktualizacji usunąć ten wpis z pliku. Please remember to delete that entry from the file after the update. The update process makes it possible to update any version to any other version, as long as there is such a possibility. In the case of an automatic update within the framework of one ‘small’ version, whenever the updater is called, an update to the latest version takes place. For example, when version 5.0.11 is installed, the updater has to be called once for the dLibra server to be updated to the newest version, for example, Proces aktualizacji pozwala na uaktualnienie pomiędzy dowolnymi wersjami, o ile oczywiście jest taka możliwość. W przypadku automatycznej aktualizacji w ramach tej samej małej wersji każdorazowe wywołanie Aktualizatora powoduje uaktualnienie do najnowszej wersji. Przykładowo: mając zainstalowaną wersję 6.0.11, po jednym wywołaniu Aktualizatora serwer dLibry zostanie uaktualniony do najnowszej wersji, np 6.0.24. Aktualizacja serwera dLibryUpdating the dLibra Server
Proces aktualizacji serwera dLibry przebiega następująco:
Po wywołaniu skryptu startowego rozpocznie się procesu aktualizacji. Jeżeli jest to pierwsze uruchomienie Aktualizator ściągnie najpierw "sam siebie", a następnie rozpocznie właściwy proces aktualizacji. Sam proces aktualizacji przebiega następująco: The server is updated in the following steps:
When the startup script has been called, the updating process will begin. If it is the first start-up, the updater will first download ‘itself’, and then it will begin the actual updating process. The updating process looks as follows:
Po zakończeniu działania Aktualizatora należy przejrzeć pliki, które zostały wskazane przez Aktualizator jako wymagające interwencji osoby przeprowadzającej aktualizacje. Gdy serwer został już uaktualniony do najnowszej wersji możemy przejść do Aktualizacji Aplikacji Czytelnika. Aktualizacja Aplikacji Czytelnika systemu dLibra Anchor | | czytelnik | czytelnik |
Anchor | ||||
---|---|---|---|---|
|
The update process of the Reader Application is similar to the update process of the dLibra server, described in the previous section.
- Do a backup of the currently installed version of the Reader Application.
- End the Tomcat server (if it has not been ended yet).
- In the updater.properties file set general.webappHomeDirectory and general.target to value webapp.
- Call the script which starts up the updater – it should be the appropriate script for the installed operating system.
The steps of the update process for the Reader Application are very similar to those for the server (some steps are omitted). After the server and Reader Application have been updated, the dLibra system can be started up.
Updating the Editor and Administrator Application
When the Reader Application has been updated, all installations of the Editor and Administrator Application will be updated during the next start-up.
Frequently Asked Questions
What should be done when the dLibra server runs on two machines?
If the dLibra server runs on several servers, the updater should be installed on each of them, and the update process should be repeated for every instance of the server. The same principle applies to a situation in which the Reader Application is not installed on the dLibra server but on a different machine.
updater.properties: optional parameters
server.checkRunning – if that parameter has value false (the default value is true), the updater will not check if the server is running. The false value may be helpful if we want to update copies of files of the Reader Application and of the server. In such a case, there is no need to switch off any of the elements of the dLibra system, and after the update process has finished, old files can be replaced with new ones.
delete.downloaded.patch – by default, the updater assumes the true value of that parameter. The updater downloads the update files from the repository of the dLibra software. With the default values, the updater deletes all the downloaded files just before it finishes its job. If we want to retain the downloaded update, value false should be set. Regardless of the value set for that parameter, that parameter will be cleared during the next start-up of the updater to which the updates are downloaded.
general.tempDirectoryPath – by default, the updater downloads files to the dLibraUpdater directory, which is created in a location indicated by the java.io.tmp system variable (it is a variable of a Java virtual machine). In the case of Linux systems, that directory usually corresponds to the value of the $TEMP variable. In order to modify the directory in which the updates are saved, the general.tempDirectoryPath key should be added to the updater.properties file, and the desired directory should be given as the value.