Opened 3 years ago

# Migration of Zentrack to Trac

Reported by: Owned by: anonymous anybody normal Request-a-Hack minor 1.2

Zentrack is an old bug tracker system. Is there a way to successfully import tickets from Zentrack to Trac?

### comment:1 Changed 3 years ago by Ryan J Ollos

Description: modified (diff) Migration of Zentrack to Track → Migration of Zentrack to Trac

### comment:2 follow-up:  4 Changed 3 years ago by Ryan J Ollos

Will take a look this week. Which version of Zentrack are you running?

version 2.6.4

### comment:4 in reply to:  2 ; follow-up:  5 Changed 3 years ago by anonymous

Will take a look this week. Which version of Zentrack are you running?

any news?

### comment:5 in reply to:  4 Changed 3 years ago by Ryan J Ollos

Will take a look this week. Which version of Zentrack are you running?

any news?

You could ask on the MailingList. Not sure when I'll get to it.

### comment:6 Changed 3 years ago by Peter Suter

I know nothing about of Zentrack.

zentrack_2.6.4.zip contains a file install\build_postgres.sql, which contains a CREATE TABLE ZENTRACK_TICKETS statement (and others). Presumably this should be (partially) mapped to Trac's ticket table. Naively I would assume this mapping:

ZENTRACK_TICKETS table Trac ticket table
id id
title summary
priority priority
status status
description description
otime time
ctime changetime
bin_id -
type_id type
user_id owner
system_id -
creator_id reporter
tested -
approved -
relations -
project_id -
est_hours -
start_date -
wkd_hours -

Would that suffice? Or what other data would be the most important to migrate?

Maybe the best approach would be adapting bugzilla2trac.py or one of the other ...2trac.py scripts there? (I know almost nothing about those.)

### comment:7 Changed 3 years ago by Peter Suter

What database backend are you using (PostgreSQL, Oracle, MySQL, MS SQL Server)?

### comment:8 follow-up:  9 Changed 3 years ago by anonymous

The backend is MySQL. The most important data is the ticket themselves (The ticket information (body, number, headline) and the comments on it). 2nd important is the files attached to the ticket. If I'm not mistaken Zentrack saves the files in the database itself.

The rest (users/departments/bins) is not important. I just want to import the core of the system so I can move to Track.

The new database that I'm about to use in Track will be what ever you recommand. I'm fluent in PostgreSQL and MySQL. So they are my first choice.

### comment:9 in reply to:  8 Changed 3 years ago by Peter Suter

The ticket information (body, number, headline)

I assume you mean "description, id, summary".

By comments you mean "Log Entry Comments"? (I guess those are in stored in the table ZENTRACK_LOGS.entry.)

2nd important is the files attached to the ticket. If I'm not mistaken Zentrack saves the files in the database itself.

It looks like the attachments are registered in the table ZENTRACK_ATTACHMENTS, but the actual files are stored in /home/zen/zentrack_2/includes/attachments.

### comment:10 Changed 3 years ago by anonymous

That sounds correct.

### comment:11 Changed 3 years ago by Peter Suter

zentrack2trac.py is an untested, very stripped-down version of bugzilla2trac.py, modified to import from MySQL ZenTrack ticket description, id, summary, log entry comments and attachments.

Are you at all familiar with Python?

### comment:12 Changed 3 years ago by anonymous

I am familiar with Python. This is why I prefer Track upon the alternatives. I will inspect the script and report if successed.

My I ask why on the manual: https://trac.edgewall.org/wiki/TracInstall

you recommend using MySQLdb a package which was not updated since 2013 and most likely is EOL? Will https://github.com/PyMySQL/PyMySQL be OK as well with this script?

### Modify Ticket

Change Properties