Advanced search  

News:

cpg1.5.46 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter recently discovered vulnerabilities. It is important that all users who run version cpg1.5.44 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: deleting old tables  (Read 1815 times)

0 Members and 1 Guest are viewing this topic.

electronico

  • Coppermine newbie
  • Offline Offline
  • Posts: 14
deleting old tables
« on: January 27, 2015, 06:10:52 AM »

I have several old tables in 'coppermine' database.
Code: [Select]
cpg132_albums
cpg132_banned
cpg132_bridge
cpg132_categories
cpg132_comments
cpg132_config
cpg132_dict
cpg132_ecards
cpg132_exif
cpg132_favpics
cpg132_filetypes
cpg132_hit_stats
cpg132_pictures
cpg132_plugins
cpg132_sessions
cpg132_temp_data
cpg132_usergroups
cpg132_users
cpg132_vote_stats
cpg132_votes
cpg14x_albums
cpg14x_banned
cpg14x_bridge
cpg14x_categories
cpg14x_categorymap
cpg14x_comments
cpg14x_config
cpg14x_dict
cpg14x_ecards
cpg14x_exif
cpg14x_favpics
cpg14x_filetypes
cpg14x_hit_stats
cpg14x_languages
cpg14x_mod_online
cpg14x_pictures
cpg14x_plugins
cpg14x_sessions
cpg14x_temp_messages
cpg14x_usergroups
cpg14x_users
cpg14x_vote_stats
cpg14x_votes
cpg15x_albums
cpg15x_banned
cpg15x_bridge
cpg15x_categories
cpg15x_categorymap
cpg15x_comments
cpg15x_config
cpg15x_dict
cpg15x_ecards
cpg15x_exif
cpg15x_favpics
cpg15x_filetypes
cpg15x_hit_stats
cpg15x_languages
cpg15x_pictures
cpg15x_plugins
cpg15x_sessions
cpg15x_temp_messages
cpg15x_usergroups
cpg15x_users
cpg15x_vote_stats
cpg15x_votes
Can I safely delete cpg132_* and cpg14x_* ones (after a MySQL backup of course) ?
Nicolas
Logged

electronico

  • Coppermine newbie
  • Offline Offline
  • Posts: 14
Re: deleting old tables
« Reply #1 on: January 27, 2015, 06:20:31 AM »

It seems that cpg132_* can be deleted, but not cpg14x_* ones.
Nicolas
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15277
Re: deleting old tables
« Reply #2 on: January 27, 2015, 04:27:38 PM »

That really depends on your setup. If you use the same database for three different galleries with different table prefixes, you shouldn't delete anything. From your question I assume that you've only one gallery. So I wonder why there are three different table prefixes. I assume you installed the gallery each time instead of upgrading it? Usually there's no need to delete old tables, as there aren't any. Have a look at include/config.inc.php to know which table prefix is used for your gallery. If you're certain that the other tables aren't used, you can safely delete them. Keep in mind that the table prefix is just a string, so a gallery running cpg1.5.x could also use the tables with the prefix "cpg132_".
Logged

electronico

  • Coppermine newbie
  • Offline Offline
  • Posts: 14
Re: deleting old tables
« Reply #3 on: January 28, 2015, 01:55:36 AM »

You're right, I only have one gallery.
And I should have done mistakes in the past years, re-installing instead of upgrading.
The database prefix in config.inc.php is well :
Code: [Select]
// MySQL TABLE NAMES PREFIX
$CONFIG['TABLE_PREFIX'] =                'cpg14x_';
So, to clarify tables in database, can I SAFELY :
- delete the cpg15x_* tables
- rename cpg14x_* tables to cpg15x_*
- set in config.inc.php
Code: [Select]
$CONFIG['TABLE_PREFIX'] =                'cpg15x_';?
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15277
Re: deleting old tables
« Reply #4 on: January 28, 2015, 03:17:55 PM »

You can delete all tables that start not with "cpg14x_". You don't need to rename the tables and change the table prefix in the config. It's recommended to leave it as is (e.g. my personal gallery has a table prefix of "cpg130_", as there's no need to update it).
Logged
Pages: [1]   Go Up
 

Page created in 0.068 seconds with 21 queries.