Tag Info

Hot answers tagged

8

One of the silent killers of MySQL Connections is the MySQL Packet. Even the I/O Thread of MySQL Replication can be victimized by this. According to the MySQL Documentation You can also get these errors if you send a query to the server that is incorrect or too large. If mysqld receives a packet that is too large or out of order, it assumes that something ...


5

Learn and use an ETL tool You'll save yourself a lot of time and pain if you use ETL tools like Pentaho Kettle or Talend Studio to automate the data transfer and merging. They'll happily connect to the Pg instance and the Oracle instance and do the required copying and merging using quite flexible strategies. They can consume CSV dumps too. Use CSV dumps ...


5

This should do it for you: mysqldump -h... -u... -p... -n -d -t --routines --triggers --all-databases > MySQLStoredProc.sql -n, --no-create-db Suppress the CREATE DATABASE ... IF EXISTS statement that normally is output for each dumped database if --all-databases or --databases is given. -d, --no-data ...


4

The postgres database is just the default database that is created during initdb. It has no special meaning. If you created a different one where all your data is kept and you never created tables in the postgres database, then there is no need to dump it. I don't know what pg_upgradecluster is. The default tool to upgrade the data directory (apart from ...


4

Regarding the password, you have two choices: An environment variable named PGPASSWORD: http://www.postgresql.org/docs/current/static/libpq-envars.html A configuration file containing the password: http://www.postgresql.org/docs/current/static/libpq-pgpass.html I don't understand why you need to run the pg_dump remotely? You can run pg_dump on any ...


3

From the CREATE ROLE documentation: Note that roles are defined at the database cluster level, and so are valid in all databases in the cluster. Since pg_dump dumps a single database, you can't extract roles with that utility. The pg_dumpall --roles-only command you proposed will do the work - however you may need to filter its output so that only ...


3

dezso was right, the PGPASSWORD environment variable is present when executing Tomcat from a single shell, but not when it's started as a service. The solution is to put the value in the process environment: ProcessBuilder builder = new ProcessBuilder( "C:/postgres9/bin/pg_dump.exe", "-U", "myuser", "-h" , "localhost", "mydb"); ...


3

Recently I had a similar problem … Here goes all the required steps with comments … ! [On Source] ============================================================================ 1) Checks on Source a. Run (on solaris prompt) On source machine Execute: uname -a In my case the output was: SunOS clusterz1 5.10 Generic_142900-03 ...


3

version, OS, tool are helping things to help you solve this. I guess OS is Windows. version 9i. export full. If this is the case: connect to the server, set ORACLE_HOME=/where/is/oracle/home/ set PATH=%ORACLE_HOME%/bin;%PATH% set ORACLE_SID=ORCL -> or your ORACLE_SID name imp file=x.dmp logfile=imp_x.log full=y imp help=y gives some clues about the ...


3

Ok ! Let me describe how this issue was solved: 1) There was definitely a corruption issue caused by a problem with vmware tools on solaris 10. When the network interface had high transfer/load operations (sample: copy of a 2 GB DB ....), it just stoped working, in the middle of the operation. To put the interface working again, I had to ...


3

If you are using the old imp method the users and tablespaces must be created first. This includes grants, database links and any advanced queues you may be using. A sample script could look like this in Windows imp a_DBA_user/apassword LOG =C:\dump\logs\import.log file =user01.dmp fromuser=user_name touser=user_name The newer datapump method works ...


3

I dumped my stored procedures with the following C:\>mysqldump -u... -p... -n -d --routines --triggers --all-databases > Z:\stuff.sql Here is one the procedures with the DROP PROCEDURE included: -- -- Dumping routines for database 'lovesh' -- /*!50003 DROP PROCEDURE IF EXISTS `LoadMyData` */; /*!50003 SET @saved_cs_client = ...


2

How long does this run before timing out? First step would bet to check the wait_timeout and interactive_timeout settings to make sure they're large enough for your import: SHOW VARIABLES LIKE '%_timeout'; SET SESSION wait_timeout=28800; The default is 8 hours (28800), so that's potentially not the issue. Other indications of this issue can be found here. ...


2

You cannot just "open" a database backup. You have to restore the database. For this, you first need to install PostgreSQL. The latest version should be capable of taking backups from older versions, too. But older version may have problems with newer features in the backup. So your version should be at least as recent as the source. How you install ...


2

As @a_horse_with_no_name says, it's a file created with the original export utility, i.e an exp command rather than expdp. You'll need to import it with the matching original import utility, using the imp command.


2

Those who have not had success with the other suggestions might consider taking a look at the BigDump PHP staggered MySQL dump importer script. It's a workaround for importing large database dumps into MySQL. I have used it successfully to import a large MySQL dump into my local development environment (I am using MAMP in this case).


2

It may not be the "correct" thing to do, but it might work (get 'er done, right?): Try breaking your large dump into multiple files and running them one at a time in sequence. My approach would be to break it in half and test. Then break each half in half, re-test, and so on. I'm somewhat curious if the amount of RAM you've got on your box could have ...


2

I'll answer this at a high level for you. The two backup methods work at different levels. An RMAN backup is a physical backup and a Data Pump backup is a logical backup. A database dump using expdp is a 1-time export of one or more database schemas. It backs up DDL (table structures, views, synonyms, stored procedures, packages, etc), plus data. An RMAN ...


2

You should really increase max_locks_per_transaction. As specified in http://www.postgresql.org/docs/9.0/static/runtime-config-locks.html , changing this parameter may require to also change the System V shared memory. You have to increase that value also. In OS X this can be done as explained in ...


2

I am not aware of any tools to do exactly what you are asking right now. I want to suggest a few options you might have overlooked however that may meet your needs. Database Cloning If your database is not being used 24/7 you can clone it for test cases. This would be done using during times when the db is not in use: createdb -U postgres new_dbname -T ...


1

There is no built-in way to do so with mysqldump. However, all is not lost, you should be able to get away with it using sed. Let's say your routine is a function, which is called split_token. The following code: mysqldump --all-databases ... | sed "/DROP FUNCTION IF EXISTS \`split_token\`/,/^DELIMITER ;$/d" will disregard the lines starting with DROP ...


1

Use the mysqlbinlog utility mysqlbinlog --help gives the following: -j, --start-position=# Start reading the binlog at position N. Applies to the first binlog passed on the command line. --stop-position=# Stop reading the binlog at position N. Applies to the last binlog passed on the command line. ...


1

Following on from chat in "The Heap"... Visio can reverse engineer a database. However, I assume thus needs to read metadata or system tables to get everything (keys, DRI, datatypes the works). This old MSDN article may help "Migrating Btrieve Applications to MS SQL Server 7.0" too


1

Data Administration tool > export data > text choose table(s) >next output file - remove .txt extension choose all fields/records radio buttons >ok Field delimiter, remove the " - field should be empty Field separator, remove comma, enter the pipe, click OK. Output will be created in the start in directory


1

For the records, I finally managed to load my dump into Acquia Dev Desktop after renaming the file to .sql and specifying/using exactly the same database name as the original database name. I don't know what caused the original issue or what solved it, since I don't believe the database name should be an issue at all.


1

There are two ways: string and hexadecimal notation, e.g.: 'abc\' as string will be like this -> 'abc\\', all special characters are escaped 'abc\' as hexadecimal will be like this -> 0x6162635C, you can test it using HEX function - SELECT HEX('abc\\'); You can choose one of those methods. Also, try to play with --hex-blob option and check results.


1

Your only hope in this scenario is to have the PROCESS privilege. The SUPER privilege allows you to kill processes. Naturally, you don't want that. On the other hand, the PROCESS privilege allows you to see the processlist. According to the MySQL Documentation on the PROCESS Privilege The PROCESS privilege pertains to display of information about the ...


1

Just reading the header you put in the question shows something interesting. In fact, the question shows three things: MySQL dump 10.13 Distrib 5.1.34, for apple-darwin9.5.0 (i386) indicates you used mysqldump from apple-darwin9.5.0 (i386) binaries Server version 5.0.51a-24+lenny2 shows the version of mysql you used mysqldump to dump from. You wanted to ...



Only top voted, non community-wiki answers of a minimum length are eligible