OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Moderator: crythias

Post Reply
Thomymaster
Znuny newbie
Posts: 76
Joined: 26 Sep 2016, 10:50
Znuny Version: 5.0.12
Company: MPImF Heidelberg

OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Post by Thomymaster »

Hi

OTRS: 5.0.27

In my OTRS installation, the customer data comes from ldap (see the following snippet from the Config.pm, credentials have been altered):
---
$Self->{CustomerUser1} = {
Name => 'LDAP Data Source',
Module => 'Kernel::System::CustomerUser::LDAP',
Params => {
Host => 'ldap://ldap3.abc.de',
BaseDN => 'ou=people,dc=abc,dc=de',
SSCOPE => 'sub',
UserDN => 'uid=svotrs,ou=people,dc=abc,dc=de',
UserPw => 'abc',
},
# customer unique id
CustomerKey => 'uid',
# customer #
CustomerID => 'mailPrimaryAddress',
# the LDAP attributes which can be used to search for an agent when creating a new ticket
CustomerUserSearchFields => ['givenname', 'sn', 'mailPrimaryAddress'],
# the LDAP attributes which are displayed once the user has been selected as "to" for a new ticket
CustomerUserListFields => ['cn', 'mailPrimaryAddress'],
CustomerUserSearchPrefix => '',
CustomerUserSearchSuffix => '*',
CustomerUserSearchListLimit => 400,
# the LDAP attribute which the postmaster searches to identify the current user
CustomerUserPostMasterSearchFields => ['mailPrimaryAddress'],
# the LDAP attributes which are used for user first and last name inside the UI
CustomerUserNameFields => ['givenname', 'sn'],
# show not own tickets in customer panel, CompanyTickets
CustomerUserExcludePrimaryCustomerID => 0,
# add an ldap filter for valid users (expert setting)
# CustomerUserValidFilter => '(!(description=locked))',
# administrator can't change customer preferences
AdminSetPreferences => 0,
# # cache time to live in sec. - cache any database queries
# CacheTTL => 0,
Map => [
# note: Login, Email and CustomerID are mandatory!
# var, frontend, storage, shown (1=always,2=lite), required, storage-type, http-link, readonly, http-link-target, link class(es)
# [ 'UserTitle', 'Title', 'title', 1, 0, 'var', '', 0 ],
[ 'UserFirstname', 'Firstname', 'givenname', 1, 1, 'var', '', 1 ],
[ 'UserLastname', 'Lastname', 'sn', 1, 1, 'var', '', 1 ],
[ 'UserLogin', 'Username', 'uid', 1, 1, 'var', '', 1 ],
[ 'UserEmail', 'Email', 'mailPrimaryAddress', 1, 1, 'var', '', 1 ],
[ 'UserCustomerID', 'CustomerID', 'mailPrimaryAddress', 0, 1, 'var', '', 1 ],
# [ 'UserCustomerIDs', 'CustomerIDs', 'second_customer_ids', 1, 0, 'var', '', 0 ],
# [ 'UserPhone', 'Phone', 'telephonenumber', 1, 0, 'var', '', 0 ],
# [ 'UserAddress', 'Address', 'postaladdress', 1, 0, 'var', '', 0 ],
#[ 'UserComment', 'Department ID', 'gidNumber', 1, 1, 'var', '', 0 ],
[ 'LDAPDepartmentName', 'Department Name', 'gidNumber', 0, 1, 'dynamic_field', '', 1 ],

],
};

The 'CustomerID' value comes from the users primary email address.
A user recently changed that and created a new ticket.

When i look at "Admin -> Customer User" and search for the user, the email address and the CustomerID updated successfully.
But in the ticket (as well as in the ticket overview/status view, where i have a column for CustomerID) the old value is still shown.

What am i doing wrong here? I though it should auto-update and at last update when the value is changed and a new ticket is created.


Best,
Thomas
OTRS 5.0.12 on Ubuntu 14.04 LTS
OTRS 5.0.27 on Ubuntu 16.04 LTS
root
Administrator
Posts: 3968
Joined: 18 Dec 2007, 12:23
Znuny Version: Znuny and Znuny LTS
Real Name: Roy Kaldung
Company: Znuny
Contact:

Re: OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Post by root »

Hi,

There is no update on the ticket. The customer_id and customer_user_id are only references. Changing these values in your datasource also means you have to find a way to update existing tickets if needed.
How should OTRS detect that Config.pm was changed and the field were changed? At least the names of the old attributes are not saved anywhere.

- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO

Use a test system - always.

Do you need professional services? Check out https://www.znuny.com/

Do you want to contribute or want to know where it goes ?
Thomymaster
Znuny newbie
Posts: 76
Joined: 26 Sep 2016, 10:50
Znuny Version: 5.0.12
Company: MPImF Heidelberg

Re: OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Post by Thomymaster »

Hi

There was nothing changed in the Config.pm

The value (primary mail address) on the datasource just changed.
OTRS 5.0.12 on Ubuntu 14.04 LTS
OTRS 5.0.27 on Ubuntu 16.04 LTS
root
Administrator
Posts: 3968
Joined: 18 Dec 2007, 12:23
Znuny Version: Znuny and Znuny LTS
Real Name: Roy Kaldung
Company: Znuny
Contact:

Re: OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Post by root »

Thomymaster wrote: 31 Jan 2020, 09:41 Hi

There was nothing changed in the Config.pm

The value (primary mail address) on the datasource just changed.
HI,

Got it. But it's nearly the same.How should OTRS know that values on the LDAP server changed and existing ticket needs to be updated?
If only one user change is affected you can use the GenericAgent to update existing tickets.

- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO

Use a test system - always.

Do you need professional services? Check out https://www.znuny.com/

Do you want to contribute or want to know where it goes ?
Thomymaster
Znuny newbie
Posts: 76
Joined: 26 Sep 2016, 10:50
Znuny Version: 5.0.12
Company: MPImF Heidelberg

Re: OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Post by Thomymaster »

Hi

Its not about updating existing tickets. Like i wrote in the initial post a new ticket has been created after the value has been changed.
OTRS 5.0.12 on Ubuntu 14.04 LTS
OTRS 5.0.27 on Ubuntu 16.04 LTS
root
Administrator
Posts: 3968
Joined: 18 Dec 2007, 12:23
Znuny Version: Znuny and Znuny LTS
Real Name: Roy Kaldung
Company: Znuny
Contact:

Re: OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Post by root »

Hi,

Maybe it's a cachng issue. Did you cleared the cache?

- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO

Use a test system - always.

Do you need professional services? Check out https://www.znuny.com/

Do you want to contribute or want to know where it goes ?
Thomymaster
Znuny newbie
Posts: 76
Joined: 26 Sep 2016, 10:50
Znuny Version: 5.0.12
Company: MPImF Heidelberg

Re: OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Post by Thomymaster »

How? And how do i disable caching?
OTRS 5.0.12 on Ubuntu 14.04 LTS
OTRS 5.0.27 on Ubuntu 16.04 LTS
root
Administrator
Posts: 3968
Joined: 18 Dec 2007, 12:23
Znuny Version: Znuny and Znuny LTS
Real Name: Roy Kaldung
Company: Znuny
Contact:

Re: OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Post by root »

Thomymaster wrote: 31 Jan 2020, 14:43 How? And how do i disable caching?
Via command line as otrs user:

Code: Select all

$HOME/bin/otrs.Console.pl Maint::Cache::Delete
- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO

Use a test system - always.

Do you need professional services? Check out https://www.znuny.com/

Do you want to contribute or want to know where it goes ?
Thomymaster
Znuny newbie
Posts: 76
Joined: 26 Sep 2016, 10:50
Znuny Version: 5.0.12
Company: MPImF Heidelberg

Re: OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Post by Thomymaster »

Hi

This doesn't work, the customerID is still not updated.
OTRS 5.0.12 on Ubuntu 14.04 LTS
OTRS 5.0.27 on Ubuntu 16.04 LTS
bangert
Znuny newbie
Posts: 3
Joined: 23 Feb 2024, 11:21
Znuny Version: 7.0.15
Real Name: René Bangert

Re: OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Post by bangert »

any news or fixes ?
root
Administrator
Posts: 3968
Joined: 18 Dec 2007, 12:23
Znuny Version: Znuny and Znuny LTS
Real Name: Roy Kaldung
Company: Znuny
Contact:

Re: OTRS 5.0.27 CustomerID not updating (values from LDAP) in ticket view and overview

Post by root »

bangert wrote: 29 Feb 2024, 23:40 any news or fixes ?
Hi,

Do you have the same issue with Znuny 7 as someone 4 years ago with OTSR 5.0? I doubt that, please open a new topic with an error description.

- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO

Use a test system - always.

Do you need professional services? Check out https://www.znuny.com/

Do you want to contribute or want to know where it goes ?
Post Reply