Please do something about the database size
cosmin 269
From: -
From: -
As you have now launched version 2.1.16, I am now faced with the problem of the ever growing database, which would make it difficult to restore a backup if something went wrong with the upgrade. My SQL backup file is 326 MB, with just 4600 files in it, and a very small number of articles, and the database on the server is 191 MB because of the esselbach_ct_filesfiles table which is 141 MB in size already. My host won't allow uploading of files bigger than 50 MB. If it's this big now, imagine what it will be like if the number of records really starts growing.
Notice
This topic is archived. New comments cannot be posted and votes cannot be cast.Responses to this topic
1 Re: Please do something about the database size
cosmin
OP
269
From: -
From: -
1 Re: Please do something about the database size
Philipp
From: Austria
Administrator
1342From: Austria
Now for the file screenshots, you could just pull the URLs of the images from the PAD files, instead of storing them in the database.
The following small modification should do the trick:
1) Open /cadmin/files/addnewfile.php in an editor and find:
xml_set_element_handler( $xml, "padstart", "padend" );
xml_set_character_data_handler( $xml, "padparse" );
xml_parse( $xml, $data );
xml_parser_free( $xml );
$input_file_seo = $system -> doseo( $input_file_name );
Then add right after it the following code:
if( $input_file_screenshot )
{
$input_file_longdescription .= "\n\n".$input_file_screenshot."";
$input_file_screenshot = "";
}
2) Open /cadmin/files/adminprocessfilesqueue.php and find:
xml_set_element_handler( $xml, "padstart", "padend" );
xml_set_character_data_handler( $xml, "padparse" );
xml_parse( $xml, $data );
xml_parser_free( $xml );
Then add:
if( $input_file_screenshot )
{
$input_file_description .= "\n\n".$input_file_screenshot."";
$input_file_screenshot = "";
}
This should also fix the time out issue you had in the other thread after the image will be no longer imported to the database.
1 Re: Please do something about the database size
Philipp
From: Austria
Administrator
1342From: Austria
Not necessarily. You could implement a filesystem browser/uploader for news teasers (just like this forum has an "upload file" button). You may not even have to write anything from scratch, especially since you are already using jquery.
This is even more complicated. Adding file functionally to the script may be easier.
Now for the file screenshots, you could just pull the URLs of the images from the PAD files, instead of storing them in the database.
I think this is an easy modification. I will try to look into it tomorrow.
1 Re: Please do something about the database size
cosmin
OP
269
From: -
From: -
I will look into it, but this is going to be a larger modification.
It would be the same with file based attachments. You can add default teaser images with News => Add Teaser Image. The uploaded teaser images will be available in all stories.
Not necessarily. You could implement a filesystem browser/uploader for news teasers (just like this forum has an "upload file" button). You may not even have to write anything from scratch, especially since you are already using jquery.
http://freewebfilemanager.com/filemanager/demo/
http://archive.plugins.jquery.com/project/jquery_file_tree
http://www.jquery4u.com/plugins/10-jquery-file-manager-plugins/
Now for the file screenshots, you could just pull the URLs of the images from the PAD files, instead of storing them in the database. Shame about the PAD format not being updated for windows 8. Its development seems to be rather inactive, even though they were announcing "big changes" some time ago.
1 Re: Please do something about the database size
Philipp
From: Austria
Administrator
1342From: Austria
It is still not a good idea, for several reasons. First of all, I have very little content right now. If it starts growing, the database will grow exponentially. It's already unwieldy.
I will look into it, but this is going to be a larger modification.
I shouldn't have to resort to workarounds and spend so much time installing something new. You're also adding a lot of duplicate content. If I add five news about google and add the Google logo as an image for it, the same Google logo will be stored five times in the database.
It would be the same with file based attachments. You can add default teaser images with News => Add Teaser Image. The uploaded teaser images will be available in all stories.
1 Re: Please do something about the database size
cosmin
OP
269
From: -
From: -
It is still not a good idea, for several reasons. First of all, I have very little content right now. If it starts growing, the database will grow exponentially. It's already unwieldy. I shouldn't have to resort to workarounds and spend so much time installing something new. You're also adding a lot of duplicate content. If I add five news about google and add the Google logo as an image for it, the same Google logo will be stored five times in the database.
1 Re: Please do something about the database size
Philipp
From: Austria
Administrator
1342From: Austria
Sorry, make that just 3600 files. And please fix the edit timeout on the forum. It prevents editing a reply, because it is currently set at 0.
I changed it now to 30 minutes.
1 Re: Please do something about the database size
Philipp
From: Austria
Administrator
1342From: Austria
I assume you are using phpMyAdmin for backups?
There is a much better SQL backup tool suited for shared hosted webspaces:
http://www.mysqldumper.net/
There is a much better SQL backup tool suited for shared hosted webspaces:
http://www.mysqldumper.net/
1 Re: Please do something about the database size
cosmin
OP
269
From: -
From: -
Sorry, make that just 3600 files. And please fix the edit timeout on the forum. It prevents editing a reply, because it is currently set at 0.