Pleasanter Version Upgrade Procedure (Linux)
## Overview
The procedure for upgrading Pleasanter operated on a Linux-based OS is as follows.
## Notes
1. Do not overwrite the currently operational parameter file with the latest version. Newly added parameters in the latest version may be lost, causing Pleasanter to fail to start.
1. If you are using the Enterprise Edition and have extended columns, follow the "Enterprise Edition Upgraded Pleasanter Upgrade Procedure" provided in the "Support Contract Subscriber Content" for the upgrade.
1. Do not set the /l or /z parameters when running CodeDefiner.
## Prerequisites
1. Ensure that the user who will launch Pleasanter is registered. The **<user who launches Pleasanter>** mentioned in the procedures refers to this user.
1. If you are upgrading from Pleasanter 1.3 or earlier to Pleasanter 1.4 or later, you need to install [.NET8 installation](https://pleasanter.org/manual/install-dotnet).
## Procedure
The upgrade procedure is as follows:
1. Backup Database
1. Backup Parameter File
1. Prepare Pleasanter
1. Prepare Application
1. Reconfigure Parameters
1. Reconfigure Extensions
1. Place Pleasanter
1. Stop Pleasanter
1. Deploy Application
1. Run CodeDefiner
1. Confirm the Start of Pleasanter
## 1. Backup Database
Backup the database. **If you have upgraded to Enterprise Edition and extended columns, make sure to back them up.**
[Pleasanter User Manual - FAQ: Backup, Restore](https://pleasanter.org/manual?category=5580)
## 2. Backup Parameter File
1. Backup the parameter file. This backup will be used in step 3.2. If you set up the Parameter file according to the manual, it will be a json file under /web/pleasanter/Implem.Pleasanter/App_Data/Parameters/.
1. **This step is not required if you are not using extensions.** Back up the parameter file set by the extension. This backup will be used in step 3.3. If you set up the file according to the manual, the file will be in the following subfolder under /web/pleasanter/Implem.Pleasanter/App_Data/Parameters/.
|Subfolder name|Extension name|Notes|
|:---|:---|:---|
|CustomDefinitions|"「Extended Column」"|Folder created when adding column to dept, group, or user|
|ExtendedFields|"「Extended Field」"||
|ExtendedHtmls|"「Extended HTML」"||
|ExtendedNavigationMenus|"「Extended Navigation Menu」"||
|ExtendedScripts|"「Extended Script」"||
|ExtendedServerScripts|"「Extended Server Script」"||
|ExtendedSqls|"「Extended SQL」"||
|ExtendedStyles|"「Extended Style」"||
## 3. Prepare Pleasanter
### 1. Prepare Application
1. Download the latest version of Pleasanter from the [GitHub release notes](https://github.com/Implem/Implem.Pleasanter/releases).
1. Unzip the downloaded zip file.
### 2. Reconfigure Parameters
Reflect the currently configured contents in the parameter file of the latest version module prepared in step 3.1. Use a file comparison/merge tool such as [WinMerge](https://winmerge.org/) to compare the parameter file of the latest version module with the parameter file of the backup file obtained in step 2, and modify the parameter file of the latest version module.
**Please check that the TimezoneDefault in Service.json is the correct value. Please set the timezoneDefault to a valid timezone for the OS of the server where Pleasanter is installed. (For example, "Tokyo Standard Time" for Windows, or "Asia/Tokyo" for Linux).**
[FAQ: I want to know the parameter settings for languages and timezones supported by Pleasanter](https://pleasanter.org/ja/manual/faq-supported-language)
### 3. Reconfigure Extensions
**This step is not required if you are not using extensions.** Apply the current settings to the extension parameter files of the latest version modules prepared in step 3.1. Use a file comparison/merging tool such as [WinMerge](https://winmerge.org/) to compare the extension Parameter file of the latest version module with the extension Parameter file of the backup file obtained in step 2, and modify the extension Parameter file of the latest version module.
## 4. Place Pleasanter
### 1. Stop Pleasanter
Execute the following command to stop Pleasanter.
```
sudo systemctl stop pleasanter
```
### 2. Deploy Application
1. Place the "pleasanter" folder of the latest version module whose parameters were reconfigured in step 3.2in the "/web" directory on the server using a file transfer application such as [WinSCP](https://winscp.net/jp/).
*Just to be on the safe side, we recommend that you rename the existing /web/pleasanter/ to /web/pleasanter_bk/ or similar to back it up before placing the new version.
1. Execute the following command to change the ownership of the pleasanter directory to the predetermined user who will launch Pleasanter.
```
sudo chown -R <user who will launch Pleasanter> /web/pleasanter
```
## 5. Run CodeDefiner
Execute the following command to run CodeDifiner with the predetermined user who will launch Pleasanter.
```
cd /web/pleasanter/Implem.CodeDefiner
sudo -u <user who will launch Pleasanter> /usr/local/bin/dotnet Implem.CodeDefiner.dll _rds
```
## 6. Confirm the Start of Pleasanter
1. Execute the following command to start Pleasanter.
```
sudo systemctl start pleasanter
```
2. Open Pleasanter login screen in your browser, log in, and click "Help" - "Version" in the navigation menu to confirm that the version is correct.
