When I go to add a plugin to my install (all plugins show when I hit 'Add') nothing happens and it generates a DB Error #1054. All information I can think of is below. The plugin in question was download 07/22/2020:
LDAP Authentication and Lookup
Version: 0.6.3
Author: Jared Hancock

ERROR -

[INSERT INTO ost_plugin SET installed=NOW() , install_path='plugins/auth-ldap.phar', name='LDAP Authentication and Lookup', isphar=1, version='0.6.3']

Unknown column 'version' in 'field list'<br />
<br />
---- Backtrace ----<br />
#0 (root)/include/mysqli.php(200): osTicket->logDBError('DB Error #1054', '[INSERT INTO os...')<br />
#1 (root)/include/class.plugin.php(353): db_query('INSERT INTO ost...')<br />
#2 (root)/scp/plugins.php(51): PluginManager->install('plugins/auth-ld...')<br />
#3 {main}

https://linkprotect.cudasvc.com/url?a=https%3a%2f%2fhelpdesk.spectrumsi.com&c=E,1,Ipxh8jU9zbOWH3JKvaA0h5ZtdyUD7LpKDM46DB_42JtQcZ9sxDB1Jhba6ayqoRFb3OdK5y3-e-vl01IBD7X58nqU0ker7RLYuu8px42fnbsoXeCV44xaDJm9Rw,,&typo=1

Server OS
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
4.4.0-89-generic #112-Ubuntu SMP Mon Jul 31 19:38:41 UTC 2017
x86_64 x86_64 x86_64 GNU/Linux
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.5 LTS
Release: 16.04
Codename: xenial

osTicket Server Information
++++++++++++++++++++++++++++++++++++++++++++++++++++++++

osTicket Version v1.14.2 (cba6035) — Up to date
Web Server Software Apache/2.4.18 (Ubuntu)
MySQL Version 5.7.30
PHP Version 5.6.37-1+ubuntu16.04.1+deb.sury.org+1

PHP Extensions
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
gdlib + Used for image manipulation and PDF printing
imap + Used for email fetching
xml + XML API
xml-dom + Used for HTML email processing
json + Improves performance creating and processing JSON
mbstring + Highly recommended for non western european language content
phar + Highly recommended for plugins and language packs
intl ! Highly recommended for non western european language content
fileinfo + Used to detect file types for uploads
zip ! Used for ticket and task exporting
APCu + Improves overall performance
Zend Opcache + Improves overall performance

PHP Settings
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
cgi.fix_pathinfo ! "1" is recommended if AJAX is not working
date.timezone ! Setting default timezone is highly recommended

Database Information and Usage
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Schema osTicket (localhost)
Schema Signature 4bd47d94b10bd8a6bab35c119dadf41f
Space Used 241.53 MiB
Space for Attachments 198.08 MiB
Timezone CDT (Interpreted as America/Chicago)

I've asked the devs about this. My guess is that when PR5357 was added that someone forgot to have the upgrader add the column. You could try editing the table and adding a version column. [I would try adding it after isactive and before installed.]

version VARCHAR 10 allow null should work.

reference:
https://github.com/osTicket/osTicket/pull/5357

@slebeau-SSI

Essentially, we forgot to add it to the upgrader long ago. The version column was added to the installer circa v1.8.2 (ancient) but I don't see where we ever added it to the upgrade scripts. This means, anyone using an upgraded version from pre-v1.8.2 will not have that column. You can simply add it with the following query:

ALTER TABLE
    `ost_plugin`
ADD
    `version` varchar(64) DEFAULT NULL
AFTER
    `isactive`;

We will also, of course, add this to the Upgrade scripts so there will be no more issues moving forward with systems upgraded from pre-v1.8.2 versions.

Cheers.

Well, that was embarrassingly easy. Thank you that.

-Steve


"When I die, I want to go like
my Grandfather did. Quietly
in his sleep. Not screaming
like the passengers in his
car."
--unknown


Glad that we could help. I will mark this as resolved and close the thread.
Please feel free to start a new thread if you have another question.

ntozier changed the title to [resolved] Issues adding Plugins ver. 1.14.2.
Write a Reply...