Hot answers tagged

6

14.04 shipped with PostgreSQL 9.3, so that's what you're going to get if you use Ubuntu's repositories. If you want PostgreSQL 9.4 or newer releases you need to add a 3rd party package repository, like the official PostgreSQL repositories from http://apt.postgresql.org/ . See the instructions there for details. (You should also probably read ...


4

You have to use Service Names to connect to Pluggable Databases in 12c. It's just one of those things that can trip you up, I guess! SQL Plus connecting OK probably threw you.


4

Though I have serious doubts in your description, let's first clean up some misconceptions. Oracle is what is called a Relational Database Management System or RDBMS (the company developing it is called Oracle For short, too). It is used – who would have guessed it – to store and retrieve data based on its relations. It requires an operating system to run. ...


3

The reason is the different versions installed in the two environments. The option for DEFAULT CURRENT_TIMESTAMP for datetime columns was added in 5.6 version (specifically in 5.6.5). See the doumentation about the DATE, DATETIME, and TIMESTAMP Types: The TIMESTAMP and (as of MySQL 5.6.5) DATETIME data types offer automatic initialization and updating ...


2

Do you just want to use a certificate on the server which the clients use to authenticate the server? (This is the normal mode of operation). The server then authenticates the clients using password challenges just as if ssl were not being used. Or do you want to use client certificates to authenticate the clients to the server as well as the server to ...


2

A (possibly obvious) additional step is become the postgres user, otherwise you may get errors about roles not existing. sudo su - postgres psql -l or psql postgres=> \l


2

Files below /usr/share/postgresql/ are supposed to be data files that are not meant to be edited. They are not live configuration files. The FHS spec at https://wiki.debian.org/FilesystemHierarchyStandard defines /usr as: /usr/ Secondary hierarchy for shareable, read-only data (formerly from UNIX source repository, now from UNIX system resources) ...


2

We had 2 problems: 1) We had one mysql query that used three joins. Turns out this function was crashing Mysql. We rewrote this query to use 4 mysql queries without joins and that solved that problem. (Bit of a hot-fix, we will probably rewrite the function so it is possible to cache it). 2) We were experiencing around 99.9 % I/O wait when we only used 10% ...


2

If you install from apt-get you will be able to use apt-get upgrade option later and other apt-get build in options (available from Ubuntu). Furthermore apt-get installs binaries and manages their versions. You just install and nothing more. Installing from source gives you the ability to do a more detailed installation. (You can customize the build and ...


2

If the PostgreSQL version and architecture is the same on the target so they're binary compatible: Set up streaming replication with WAL archive fallback, so the new host replicates from the old one. Enable hot_standby mode so you can connect to the new host read-only. Test. Then when you're ready to cut over, stop the old server and pg_ctl promote the new ...


2

There is actually nothing really wrong here, at least not based on what you have included in the question. Go back to this point: ubuntu-user@ubuntu-vm:~$ mongo MongoDB shell version: 3.0.1 connecting to: test Server has startup warnings: 2015-03-27T12:37:30.430+0100 I CONTROL [initandlisten] 2015-03-27T12:37:30.430+0100 I CONTROL [initandlisten] ** ...


2

Since your error is: Failed to restart mongod.service: Unit mongod.service failed to load: No such file or directory. This is pretty much saying that your startup path is not in the expected location or else the Ubuntu install has led to problems. See: http://docs.mongodb.org/manual/tutorial/manage-mongodb-processes/ EDIT: Updated with link to what ...


1

Here you are a few steps: Install postgreSQL 9.x from packages; Configure ubuntugis repository from here; Add the following lines to /etc/apt/source.list with your ubuntu version: deb http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu YOUR_UBUNTU_VERSION_HERE main deb-src http://ppa.launchpad.net/ubuntugis/ubuntugis-unstable/ubuntu ...


1

I think Rick James is on the right track, the many 30k table handles are jamming memory. In MySQL 5.5, InnoDB uses the system tablespace, which places all table data in a single OS file. This means that individual internal table data allocation, as well as handle management, happens inside MySQL (which is to say, completely in RAM as you have no swap ...


1

It doesn't look like MongoDB provides a repo for Saucy: http://repo.mongodb.org/apt/ubuntu/dists/ So if you installed via Ubuntu-provided repository you have a few options: Remove the RPM and install via binaries Upgrade to Trusty Wait for Ubuntu to update its repo.


1

As noted in the install page, the MongoDB distribution is comprised of several packages: mongodb-org: This package is a metapackage that will automatically install the four component packages listed below. mongodb-org-server: This package contains the mongod daemon and associated configuration and init scripts. mongodb-org-mongos: This package contains the ...


1

I have addressed this once before : MySQL database drop insanely slow My suggestion in that post was this SET unique_checks = 0; SET foreign_key_checks = 0; SET GLOBAL innodb_stats_on_metadata = 0; DROP DATABASE db_madeintouch; SET GLOBAL innodb_stats_on_metadata = 1; SET foreign_key_checks = 1; SET unique_checks = 1; If all your data uses InnoDB, this ...


1

Not an elegant solution but after installing the package using apt-get (which fails creating the cluster but installs PostgreSQL), I switched to the postgres user and created the database using initdb. Then back to root, I created the cluster using the pg_createcluster command. This moved the configurations to /etc/postgres/9.4/main and set it all up.


1

If you want to recover by filetype, please note the following structure in MySql database file system: A MySQL table is the combination of three files: The FRM file is the table definition. The MYD file is where the actual data is stored. The MYI file is where the indexes created on the table are stored. Source: [1] ...


1

Reason: Is it the same version of Mongo on both servers? Record Padding : http://docs.mongodb.org/v2.4/core/record-padding/ No Padding Allocation Strategy Changed in version 3.0.0. For collections whose workloads do not change the document sizes, such as workloads that consist of insert-only operations or update operations that do not increase document ...


1

You have to configure the following two files pg_hba.conf host all all 0.0.0.0/0 md5 postgresql.conf listen_addresses='*' Make sure to restart postgres service after changing the files. You have to check if the port 5432 is open: http://www.yougetsignal.com/tools/open-ports/ If it's not then add a rule to your iptables: iptables -A INPUT -s 0/0 -p ...


1

This is the same issue as described here (for MySQL): High CPU usage from MySQL with no queries at all running sudo date -s now Caused by leap second and a bug in the kernel.


1

Ok so a bit of egg on my face - I was overlooking the fact that my shiny new /etc/mongod.conf.yml contained processManagement.fork: true. Setting this to false allows start-stop-daemon to capture the appropriate PID.


1

Cannot allocate memory means you have not enough ram. check the memory requirements in the oralce guide


1

I did the following. I wrote a script (testfile) as below and it worked. The big difference AFAICS is that with my script I export my variables before trying to use them. BTW, I wouldn't call it $USER - I'd go with $MY_USER - there's already a Linux system variable called $USER. I also didn't have these lines #!/usr/bin/env bash # ... I just chmod'ed the ...


1

In pg_hba.conf You should set # TYPE DATABASE USER ADDRESS METHOD local all all trust Authentication method should be TRUST, that will allow You to enter postgres without password and set it for postgres user. Below you see how to change password ;) ALTER USER postgres ...


1

You need to use sudo service to start MongoDB as a service, check the documentation for further details: sudo service mongod --auth --port 27017 --dbpath /var/lib/mongodb


1

Reproducing the situation : mc1 collection already created on shard0000 before sharding mc2 collection already created on shard0001 before sharding Create a test-shard: $ mongo --nodb mongo> config={d0:{smallfiles:"",noprealloc:"",nopreallocj : ""}, d1 : {smallfiles : "", noprealloc : "", nopreallocj : "" }}; mongo> cluster = new ...


1

From here: Case insensitive table names It says: So, the final recommendation is to leave the lower_case_table_names variable unaltered (i.e. its default value), which is 0 on Linux-based systems and 2 on Windows and write table names to a lettercase that suits you best (both at creation as well as at query time). If you are moving from Windows to Linux, ...


1

There is a confirmed bug on Launchpad that affects PostgreSQL on Ubuntu 14.04: Bug #1334714 - User postgres can't write to /var/lib/postgresql: (Reported on 2014-06-26, Status: Confirmed) https://bugs.launchpad.net/ubuntu/+source/postgresql-common/+bug/1334714 Bug Description Unable to write to history log. Seems to be the same problem as bug ...



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