Advanced search  

News:

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

Pages: [1]   Go Down

Author Topic: Critical error while processing a database query  (Read 4788 times)

0 Members and 1 Guest are viewing this topic.

dt

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 29
Critical error while processing a database query
« on: March 12, 2004, 11:51:32 pm »

ok i have done a search but havnt found any thing that looked like mine
heres what it shows

and i cant create an ablum :(

Quote
Warning: Cannot modify header information - headers already sent by (output started at /home/www/rapid.50free.org/gallery/index.php:583) in /home/www/rapid.50free.org/gallery/themes/default/theme.php on line 777


Quote
Warning: Cannot modify header information - headers already sent by (output started at /home/www/rapid.50free.org/gallery/index.php:583) in /home/www/rapid.50free.org/gallery/include/functions.inc.php on line 51


There was an error while processing a database query

http://rapid.50free.org/gallery/index.php

 if this is in the worng place can a moderater please move this post
thanks[size=18][/size]

any help is appreciated
thanks
Logged

Casper

  • VIP
  • Coppermine addict
  • ***
  • Country: 00
  • Offline Offline
  • Gender: Male
  • Posts: 5231
Critical error while processing a database query
« Reply #1 on: March 13, 2004, 09:39:00 am »

Have you made any changes to your code, particularly the fuctions.inc.php or them.php?
Logged
It has been a long time now since I did my little bit here, and have done no coding or any other such stuff since. I'm back to being a noob here

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Critical error while processing a database query
« Reply #2 on: March 13, 2004, 12:39:36 pm »

if you haven't modified anything, your files may be corrupt. Get a fresh copy of the coppermine package, unzip it and overwrite all files in the include folder and at least index.php in the coppermine folder.

GauGau
Logged

dt

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 29
Critical error while processing a database query
« Reply #3 on: March 15, 2004, 12:41:03 am »

i have replaced the themes, include folder and index.php
and still no go :(

what will happen to all my stuff when i overwite all the files, will it get deleted?? like how many votes albums/categories etc???

is there any way to back up my stuff that i could use when i overwrite all the files??


and no i have no modified any code, but i did try the hardwired theme :?
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Critical error while processing a database query
« Reply #4 on: March 15, 2004, 01:06:40 am »

comments and votes aren't stored in files, but in the database - no harm done if you overwrite just files. For backup, see http://coppermine.sourceforge.net/faq.php?q=BackupDatabase#BackupDatabase

GauGau
Logged

dt

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 29
Critical error while processing a database query
« Reply #5 on: March 15, 2004, 04:13:25 am »

Quote from: "gaugau"
comments and votes aren't stored in files, but in the database - no harm done if you overwrite just files. For backup, see http://coppermine.sourceforge.net/faq.php?q=BackupDatabase#BackupDatabase

GauGau


ok i have selected all the tables and folloed the instructions
and i get a zip file called rapid_db[1].sql when i extract it i get a txt file
" rapid_db.sql.zip  " - (90kb file), what do i do with this next please.

do i install/overwrite the same version (cpg1.2.0final).

what do i do with the txt file rapid_db.sql.zip , which was backed up


sorry im a newbie :oops:

and thank you in advance
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Critical error while processing a database query
« Reply #6 on: March 15, 2004, 10:32:53 am »

you can open the sql file with any text editor (notepad will do) to see the mySQL dump. Just keep it in a save place if you want to just have a backup. Use the query field in phpMyAdmin and insert the contents of the sql file if you database breaks (that's how to restore).
Get a backup of all your files as well, and then overwrite all files on your server with the ones from a coppermine package (upgrade to cpg1.2.1 recommended). See the documentation that comes with the coppermine package for details/full instructions.

GauGau
Logged

dt

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 29
Critical error while processing a database query
« Reply #7 on: March 15, 2004, 11:38:42 pm »

my gallery is now screwed :cry: , i dunno what to do, i tried do it and i think i stuffed it up, dont know how to do ..... :?  :cry:
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Critical error while processing a database query
« Reply #8 on: March 16, 2004, 08:35:05 am »

the documentation says to backup before upgrading, so you'll just have to restore your backup. What exactly is your problem? The link your provided in your first posting shows error 500, which means: wrong server config, or corrupt files. Get a fresh copy of the coppermine package, and upload it again. Make sure to use the right ftp modes during upload.

GauGau
Logged

dt

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 29
Critical error while processing a database query
« Reply #9 on: March 16, 2004, 09:58:23 am »

im sorry. i thin my major problem is i dont know how to use the infomation  from rapid_db.sql.zip text file to put in the the php my admin progam which is built in to the 50free site
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Critical error while processing a database query
« Reply #10 on: March 16, 2004, 10:09:07 am »

how to restore a backup: this topic is usually covered in the documentation that comes with phpMyAdmin, but anyway: unzip the file you have, open the uncompressed file with a text editor, start phpMyAdmin, choose your database (if applicalbe), click on "SQL" in the navigation bar of phpMyAdmin, paste your dump back into the text box, click "Go". Note: if you have a large gallery, you'll have to paste smaller bits of the dump back into the query field of phpMyAdmin. If the tables already exist, you'll get an error saying so.

The fact that your page is brokne in the browser is not a result of a broken database though: like I said: it's an internal server error!

GauGau
Logged

dt

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 29
Critical error while processing a database query
« Reply #11 on: March 16, 2004, 11:32:06 am »

Quote
start phpMyAdmin, choose your database (if applicalbe), click on "SQL" in the navigation bar of phpMyAdmin, paste your dump back into the text box, click "Go


i can do that, ut all i get back is

Code: [Select]
Database rapid_db running on 50free.org
Error

SQL-query :  

CREATE TABLE `cpg11d_albums` (

`aid` int( 11 ) NOT NULL AUTO_INCREMENT ,
`title` varchar( 255 ) NOT NULL default '',
`description` text NOT NULL ,
`visibility` int( 11 ) NOT NULL default '0',
`uploads` enum( 'YES', 'NO' ) NOT NULL default 'NO',
`comments` enum( 'YES', 'NO' ) NOT NULL default 'YES',
`votes` enum( 'YES', 'NO' ) NOT NULL default 'YES',
`pos` int( 11 ) NOT NULL default '0',
`category` int( 11 ) NOT NULL default '0',
`pic_count` int( 11 ) NOT NULL default '0',
`thumb` int( 11 ) NOT NULL default '0',
`last_addition` datetime NOT NULL default '0000-00-00 00:00:00',
`stat_uptodate` enum( 'YES', 'NO' ) NOT NULL default 'NO',
PRIMARY KEY ( `aid` ) ,
KEY `alb_category` ( `category` )
) TYPE = MYISAM AUTO_INCREMENT = 15

MySQL said:

#1044 - Access denied for user: 'rapid_db@209.25.134.190' to database 'rapid_db'


Quote
Note: if you have a large gallery, you'll have to paste smaller bits of the dump back into the query field of phpMyAdmin. If the tables already exist, you'll get an error saying so.


 i dont understand how to do the above, theres too many fields to fill in :?

what shall i do with the sever part wait or get a new one??

ps hey gaugau i would like to thank you for being so helpful :wink:

much appreciated 8)
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Critical error while processing a database query
« Reply #12 on: March 16, 2004, 05:35:06 pm »

now this is news - access denied means it's a permission problem with the mySQL database. I suggest you check two files:
http://yourdomain.tld/coppermine_folder/include/config.inc.php
http://yourdomain.tld/phpMyAdmin_folder/config.php
Are the same data in both files used to access the database (username, database name, password). If yes, you should contact your webhost, since you seem to not have enough permissions - maybe they changed permissions without notifying you. If you're self-hosted, you'll at least know the server-admin (go to the bathroom and look in the mirror :wink: ).

GauGau
Logged

dt

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 29
Critical error while processing a database query
« Reply #13 on: March 16, 2004, 09:28:48 pm »

Quote from: "gaugau"

http://yourdomain.tld/coppermine_folder/include/config.inc.php

this one shows me
Code: [Select]
<?php
// Coppermine configuration file

// MySQL configuration
$CONFIG['dbserver'&#93; =                         "50free.org";
$CONFIG['dbuser'&#93; =                         "r_db";
$CONFIG['dbpass'&#93; =                         "XXXXXXXXXXXX";
$CONFIG['dbname'&#93; =                         "r_db";    

// MySQL TABLE NAMES PREFIX
$CONFIG['TABLE_PREFIX'&#93; =                "cpg11d_";
?>


but im not too sure how to check this one  :?
Quote
http://yourdomain.tld/phpMyAdmin_folder/config.php


cheers
Logged
Pages: [1]   Go Up
 

Page created in 0.024 seconds with 14 queries.