User Tools

Site Tools


procedures:osticket

This is an old revision of the document!


OsTicket Install

This part is for installing the v1.10 of the osTicket software which is the one that is live at the moment of the writing of this Wiki.

System update and installing the dependecies

sudo apt update && sudo apt upgrade -y
sudo apt install -y lsb-release ca-certificates apt-transport-https software-properties-common gnupg2 curl wget unzip net-tools

1. Add the php 5.6 repository

Since it is an old version and is no longer distributed we will have to installit through a repository.

Add the key of the repository and update the packages list

curl -sSL https://packages.sury.org/php/README.txt | sudo bash -x
sudo apt update

2. Install apache, MariaDB and Php

Apche and MariaDB

sudo apt install -y apache2 mariadb-server

Php5.6 and necessary extension

sudo apt install -y php5.6 php5.6-cli php5.6-mysql php5.6-fpm php5.6-xml php5.6-mbstring php5.6-gd php5.6-imap php5.6-json php5.6-apcu php5.6-intl php5.6-mcrypt libapache2-mod-php5.6

Enable the Php module in Apache

sudo a2enmod php5.6
sudo systemctl restart apache2

3. Configure the database

For this installation we will use a dump of a already existing database.

Access MySQL

sudo mysql -u root -p

Create the user and database

CREATE DATABASE osticket_db;
CREATE USER 'osticket_user'@'localhost' IDENTIFIED BY 'password_of_ur_choice';
GRANT ALL PRIVILEGES ON osticket_db.* TO 'osticket_user'@'localhost';
FLUSH PRIVILEGES;
EXIT;

Now we can import the dump.sql into the databse we just created (if you don't have a dump skip this).

mysql -u osticket_user -p osticket_db < /path/to/dump.sql

4. osTicket files

Dowload the .zip

wget https://github.com/osTicket/osTicket/releases/download/v1.10/osTicket-v1.10.zip
unzip osTicket-v1.10.zip -d osticket
sudo mv osticket/upload /var/www/html/osticket

5. Manual configuration

Rename the config file

sudo mv /var/www/html/osticket/include/ost-sampleconfig.php /var/www/html/osticket/include/ost-config.php

Edit the file (only if you have the sql dump)

sudo vim /var/www/html/osticket/include/ost-config.php
define('DBTYPE','mysql');
define('DBHOST','localhost');
define('DBNAME','osticket_db');
define('DBUSER','osticket_user');
define('DBPASS','password_of_ur_choice');
define('TABLE_PREFIX','ost_');
define('OSTINSTALLED',TRUE);
define('SECRET_SALT','uKVB7ZnvozppfEOzuyWVVZlZX81thj6p'); (put this exact string to uncrypt the tickets)
define('ADMIN_EMAIL','ur_email@example.com');

6. Cleaning up and permissions

Set Apache propriety

sudo chown -R www-data:www-data /var/www/html/osticket/

Set config file to only read

sudo chmod 0644 /var/www/html/osticket/include/ost-config.php

Remove setup fodler (ONLY IF YOU HAD THE SQL DUMP)

sudo rm -rf /var/www/html/osticket/setup/

Go on the site

Search on a browser the URL/osticket and if you had the sql dump everything should be operative. If this was the first install follow the instruction the osTicket wizard tells you.

OsTicket Update

This section is for the OsTicket and Php update (only for OsTicket version older than the 1.6). The first thing to do is to on the admin pannel and disable the service.

1. Php

Install the new version and extension

sudo apt update
sudo apt install -y php8.4 php8.4-cli php8.4-mysql php8.4-fpm php8.4-xml php8.4-mbstring php8.4-gd php8.4-intl php8.4-apcu php8.4-bcmath libapache2-mod-php8.4

Activate the new version

sudo a2dismod php5.6
sudo a2enmod php8.4
sudo systemctl restart apache2

2. OsTikcet

Install the files

cd /tmp
wget https://github.com/osTicket/osTicket/releases/download/v1.18.4/osTicket-v1.18.4.zip

(ofc check if the link is the right version)

Change the files

Unzip the files

unzip osTicket-v1.18.4.zip -d osticket_new

Save a config copy

cp /var/www/html/osticket/include/ost-config.php /tmp/ost-config.bak

Overwrite the files in the osticket folder

sudo cp -r /tmp/osticket_new/upload/* /var/www/html/osticket/

Put the old config file

sudo cp /tmp/ost-config.bak /var/www/html/osticket/include/ost-config.php

Reset the Apache permission

sudo chown -R www-data:www-data /var/www/html/osticket/

3. Update on the site

Now you will have to access the admin pannel and there will be a voice that says to start the update. Do it.

4. Cleaning up and permissions

Remove the setup folder

Do this only after a few minutes the end of the update on the platform

sudo rm -rf /var/www/html/osticket/setup/

Make sure the config file is only readble

sudo chmod 0644 /var/www/html/osticket/include/ost-config.php
procedures/osticket.1783070872.txt.gz · Last modified: by mattia.stalio

Except where otherwise noted, content on this wiki is licensed under the following license: Public Domain
Public Domain Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki