Re: [OT] a mysql question
On Oct 24, 2006, at 6:52 PM, jan gestre wrote: On 10/25/06, Jonathan Horne [EMAIL PROTECTED] wrote: i do know how to import a .sql database dump, i was just wondering if i can do it via a restore job from netbackup. any opinions i can get, are greatly appreciated. to backup a mysql database: $ mysqldump -u user -p --opt databasename database.bak.sql to restore a database from the backup: $ mysql -u user -p database database.bak.sql just make sure user has privileges to do the necessary commands, if not you can use the root user of mysql. you can also use a gui tool like phpmyadmin for managing mysql. Just an extra detail. Be sure that you not only do a mysqldump for your application databases but also dump the mysql database so you don't lose any internal permission records you've created. You or your apps will have likely created records in that database necessary for when you attempt to actually use your restored application databases. The resulting dump will need to be edited before you try to recover since your setup of mysql on the restored server will automatically create the structures. The dump file will duplicate the creation (not good). Get around that by deleting everything in that dump file except the INSERT statements for records you've created. They will usually be somewhat obvious, e.g., you may have an entry for daemon if a webserver cgi application has been granted access to some database. The records you will be interested in backing up are from the database mysql and the table called user. These must be restored after you restore the application databases in most cases since they refer to the existence of the application database. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
[OT] a mysql question
typical OT thread apologies, but the truth *really* is that this is the best and most intelligent list i read. so... i use veritas netbackup 5.1 to backup my bsd machines, and i would like to restore some mysql databases onto another machine. is restoring any mysql database, as simple as reloading the database directories in /var/db/mysql? do i need to create the blank database first, then do it? i do know how to import a .sql database dump, i was just wondering if i can do it via a restore job from netbackup. any opinions i can get, are greatly appreciated. thanks, jonathan ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: [OT] a mysql question
typical OT thread apologies, but the truth *really* is that this is the best and most intelligent list i read. so... You're really going to get better answers from the mysql lists... really. :) i use veritas netbackup 5.1 to backup my bsd machines, and i would like to restore some mysql databases onto another machine. is restoring any mysql database, as simple as reloading the database directories in /var/db/mysql? do i need to create the blank database first, then do it? maybe. maybe not. depends on the engine's used. http://dev.mysql.com/doc/refman/5.0/en/backup.html http://jeremy.zawodny.com/mysql/mysql-backup-and-recovery.html -philip ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: [OT] a mysql question
On 10/25/06, Jonathan Horne [EMAIL PROTECTED] wrote: typical OT thread apologies, but the truth *really* is that this is the best and most intelligent list i read. so... i use veritas netbackup 5.1 to backup my bsd machines, and i would like to restore some mysql databases onto another machine. is restoring any mysql database, as simple as reloading the database directories in /var/db/mysql? do i need to create the blank database first, then do it? i do know how to import a .sql database dump, i was just wondering if i can do it via a restore job from netbackup. any opinions i can get, are greatly appreciated. i'm not a mysql guru but backing up and restoring a mysql database is just like riding a bike, it's that easy :D to backup a mysql database: $ mysqldump -u user -p --opt databasename database.bak.sql to restore a database from the backup: $ mysql -u user -p database database.bak.sql just make sure user has privileges to do the necessary commands, if not you can use the root user of mysql. you can also use a gui tool like phpmyadmin for managing mysql. cheers ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: PHP for MySQL question
Forwarding to the list. A quick google make's me think aclocal is part of automake and I actually found several versions on my system. Check your system and if one is not installed that could be the problem. I would have thought it would have been installed as a dependency by something along the way. automake-1.4.6_2 automake-1.5_2,1 automake-1.9.6 Automake1.5 was the problem, I found it in the ports section and things seem to be working well. Can't imagine why it just didn't install as a dependency though. Ooh well, it's all installing now and looks good. Much thanks. Glad to have helped, I'm curious why the missing dependency though. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
PHP for MySQL question
Hi all, I've been a member a few days, this is my first post. I'm trying to install mysql support for PHP on my FreeBSD6.0 box, but when I try to install the port /databases/php5-mysql, this is what I get: --- === php5-mysql-5.1.2_1 depends on executable: phpize - found === php5-mysql-5.1.2_1 depends on file: /usr/local/bin/autoconf259 - found === php5-mysql-5.1.2_1 depends on shared library: mysqlclient.15 - found === PHPizing for php5-mysql-5.1.2_1 Configuring for: PHP Api Version: 20031224 Zend Module Api No: 20041030 Zend Extension Api No: 220040412 *** Error code 1 Stop in /usr/ports/databases/php5-mysql. And that's all she wrote. I already have php and mysql installed, any and all help is appreciated. Thanks, John Cruz [EMAIL PROTECTED] -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: PHP for MySQL question
Sorry, the make install file.txt didn't copy everything. Here's the output copied from putty --- taurus# cd /usr/ports/databases/php5-mysql taurus# make install === php5-mysql-5.1.2_1 depends on executable: phpize - found === php5-mysql-5.1.2_1 depends on file: /usr/local/bin/autoconf259 - found === php5-mysql-5.1.2_1 depends on shared library: mysqlclient.15 - found === PHPizing for php5-mysql-5.1.2_1 Configuring for: PHP Api Version: 20031224 Zend Module Api No: 20041030 Zend Extension Api No: 220040412 aclocal15: not found *** Error code 1 Stop in /usr/ports/databases/php5-mysql. - John Cruz wrote: Hi all, I've been a member a few days, this is my first post. I'm trying to install mysql support for PHP on my FreeBSD6.0 box, but when I try to install the port /databases/php5-mysql, this is what I get: --- === php5-mysql-5.1.2_1 depends on executable: phpize - found === php5-mysql-5.1.2_1 depends on file: /usr/local/bin/autoconf259 - found === php5-mysql-5.1.2_1 depends on shared library: mysqlclient.15 - found === PHPizing for php5-mysql-5.1.2_1 Configuring for: PHP Api Version: 20031224 Zend Module Api No: 20041030 Zend Extension Api No: 220040412 *** Error code 1 Stop in /usr/ports/databases/php5-mysql. And that's all she wrote. I already have php and mysql installed, any and all help is appreciated. Thanks, John Cruz [EMAIL PROTECTED] -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: PHP for MySQL question
Sorry, the make install file.txt didn't copy everything. Here's the output copied from putty --- taurus# cd /usr/ports/databases/php5-mysql taurus# make install === php5-mysql-5.1.2_1 depends on executable: phpize - found === php5-mysql-5.1.2_1 depends on file: /usr/local/bin/autoconf259 - found === php5-mysql-5.1.2_1 depends on shared library: mysqlclient.15 - found === PHPizing for php5-mysql-5.1.2_1 Configuring for: PHP Api Version: 20031224 Zend Module Api No: 20041030 Zend Extension Api No: 220040412 aclocal15: not found *** Error code 1 Stop in /usr/ports/databases/php5-mysql. Install the meta-port lang/php5-extensions and it will install the php5 modules. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: PHP for MySQL question
Robert Uzzi wrote: Install the meta-port lang/php5-extensions and it will install the php5 modules. I tried that, it still gives me the same thing about the aclocal15 not being found. It doesn't stop with the mysql part of php either, there's other stuff earlier in the php extentions list it stops on as well. -john -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: PHP for MySQL question
I tried that, it still gives me the same thing about the aclocal15 not being found. It doesn't stop with the mysql part of php either, there's other stuff earlier in the php extentions list it stops on as well. -john I'm not seeing the problem here or on another system but a quick scan of my system finds the following. If you don't have them that could be the problem. Now to figure out why? /usr/local/bin/aclocal15 /usr/local/share/aclocal15 A quick google make's me think aclocal is part of automake and I actually found several versions on my system. Check your system and if one is not installed that could be the problem. I would have thought it would have been installed as a dependency by something along the way. automake-1.4.6_2 automake-1.5_2,1 automake-1.9.6 ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Mysql question (sorry if wrong Maililning List)
Hello all. I've got into some problem... I've been running one of mysql databases for almost a year.. and now met some problems.. I have working mysql database.. it has lots of fields (columns) and now.. when I trie to add autoid column.. it puts value 1 everywhere.. i did it auto incremental + primary key.. didn't help Tried also to export to .CSV and import from it... same thing.. everywhere value goes equal to 1... any ideas on how to fix that ? Thx -- Best regards,Hugle ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
MySQL question...
Hi all, I've finished installing MySQL on FreeBSD-4.5 RELEASE, now I've to add the users to control their databases, but I'm confused...where they will write their databases or do I have to create each one, I'm running as mysql user, they will have access to /mysql sub-dir ??? Can I create a sub-dir for each user with full access to it and no access to anymore one ??? I've read the manual (Adding New Users) but it's a little confused, thanks... ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: MySQL question...
On Sunday 30 November 2003 17:36, Xpression wrote: Hi all, I've finished installing MySQL on FreeBSD-4.5 RELEASE, now I've to add the users to control their databases, but I'm confused... Right. Because this is not a FreeBSD issue but a MySQL issue. MySQL users have nothing to do with the local users for the operating system. You only need the 'mysql' user, which is created by the port, and read: http://www.mysql.com/doc/en/Privileges.html All databases will go under /var/db/mysql and the quick and dirty answer is: mysql -e GRANT ALL ON $dbname.* TO '$dbuser'@'localhost' IDENTIFIED BY '$userpasswd' -- Melvyn === FreeBSD sarevok.webteckies.org 5.2-BETA FreeBSD 5.2-BETA #1: Sat Nov 29 00:15:33 CET 2003 [EMAIL PROTECTED]:/usr/obj/usr/src/sys/ SAREVOK_NOFW_DBG i386 === pgp0.pgp Description: signature
RE: MySQL question...
-Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Melvyn Sopacua Sent: Monday, 1 December 2003 3:54 AM To: FreeBSD-questions Cc: Xpression Subject: Re: MySQL question... snip All databases will go under /var/db/mysql and the quick and dirty answer is: mysql -e GRANT ALL ON $dbname.* TO '$dbuser'@'localhost' IDENTIFIED BY '$userpasswd' -- Melvyn Something I've wondered is why the default location for the MySQL databasi is /var/db/mysql? Yes /var/db seems to make sense, but most /var filesystems would be fairly small. Is it generally common practice to create a symbolic link to somewhere on, say, /usr to store the databasi? Dave ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: MySQL question...
On Sunday 30 November 2003 22:57, DG wrote: -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Melvyn Sopacua Sent: Monday, 1 December 2003 3:54 AM To: FreeBSD-questions Cc: Xpression Subject: Re: MySQL question... snip All databases will go under /var/db/mysql and the quick and dirty answer is: mysql -e GRANT ALL ON $dbname.* TO '$dbuser'@'localhost' IDENTIFIED BY '$userpasswd' -- Melvyn Something I've wondered is why the default location for the MySQL databasi is /var/db/mysql? Yes /var/db seems to make sense, but most /var filesystems would be fairly small. By tradition /var is for 'variable data'. By tradition, /var has been used for mail and news and as such do not require large partitions unless you run binary newsgroups. Therefore most /var partitions are small. However - I agree that the chosen default is not up-to-par with the use of MySQL, especially since you would take smaller fragment size for a /var partition if you have a busy mail- or newsserver and that certainly won't benefit MySQL. Is it generally common practice to create a symbolic link to somewhere on, say, /usr to store the databasi? If you know beforehand that you're going to run a mysql database with large databases (or use innodb which will never shrink!), than it's wise to create a large partition /var/db/mysql on boot. Otherwise you can set the DB_DIR variable during installation of MySQL to f.e.: /usr/local/var/mysql which is not unheard of. On my workstation I use /usr/db/mysql, but on my workstation I also have a 15G /usr partition. Whichever you choose, it's best to choose a DB_DIR ending in /mysql, so you can always decide to add another disk and mount that as $DB_DIR. By the way: don't underestimate the size of the binary logs, especially with large inserts. -- Melvyn === FreeBSD sarevok.webteckies.org 5.2-BETA FreeBSD 5.2-BETA #1: Sat Nov 29 00:15:33 CET 2003 [EMAIL PROTECTED]:/usr/obj/usr/src/sys/ SAREVOK_NOFW_DBG i386 === pgp0.pgp Description: signature
MySQL question...
Hi list, I've installed mysql-4.0.16.tar.gz on a FreeBSD-4.5 server, at least it compile, then I edit and copy the my-medium.cnf file to /etc/my.cnf location...when I reboot MySQL doesn't start...anyone running it ??? Or I have to do some steps to make running it ??? ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: MySQL question...
On Fri, 28 Nov 2003 10:42:40 -0500 Xpression [EMAIL PROTECTED] wrote: |O|Hi list, I've installed mysql-4.0.16.tar.gz on a |O|FreeBSD-4.5 server, at least it compile, then I edit and |O|copy the my-medium.cnf file to /etc/my.cnf location...when I |O|reboot MySQL doesn't start...anyone running it ??? Or I have |O|to do some steps to make running it ??? You have to create a file in your /usr/local/etc/rc.d directory that will start (and stop) mysql. It needs to be 'chmod 755' (you could probably use chmod 700) And, it would likely contain something like this: = snip start== #!/bin/sh case $1 in start) if [ -x /usr/local/bin/safe_mysqld ]; then /usr/local/bin/safe_mysqld --user=mysql /dev/null echo -n ' mysqld' fi ;; stop) /usr/bin/killall mysqld /dev/null 21 echo -n ' mysqld' ;; *) echo echo Usage: `basename $0` { start | stop } echo exit 64 ;; esac end snippet ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
MySQL question...
Hi list, I'm trying to install MySQL-4.0.16 on my FreeBSD-4.5 Server and always give me ERROR, anyone running it can help me ??? ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: php-mysql question
+++ David Banning [19/07/02 18:25 -0400]: Still stuck - I am getting this error no database selected when I try to connect to mysql with phpmyadmin or with my separate custom php appication. (1) Can you log in with just plain old 'mysql'? Then check your config in your phpmyadmin config file to use the same connection method you use with the mysql command. I have deleted /usr/local/etc/php.ini so it should be running on the default parameters. Presently I am running; mod_php4-4.2.1_2 mysql-client-3.23.51 p5-Mysql-modules-1.2216 (do I need this?) mysql-server-3.23.51 on FreeBSD 4.5S Anyone got any ideas? To Unsubscribe: send mail to [EMAIL PROTECTED] with unsubscribe freebsd-questions in the body of the message To Unsubscribe: send mail to [EMAIL PROTECTED] with unsubscribe freebsd-questions in the body of the message
php-mysql question
I just attempted to install php-templates. That seemed to install a newer version of mod-php4 from the ports. It seems that apache, ssl, php and mysql all work, but I cannot access mysql through php anymore. How does php know where to find the database structure of mysql? I have never had a php.ini, as I just went by the defaults. I wonder whether the defaults have changed in newer releases? To Unsubscribe: send mail to [EMAIL PROTECTED] with unsubscribe freebsd-questions in the body of the message