Solved

Trouble migrating PostgreSQL on another server

Posted on 2014-03-11
2
400 Views
Last Modified: 2014-03-12
Hi,

So here’s my situation. Right now, we’re working on an End of life version of LedgerSMB (ver. 1.2.21) with PostgreSQL 8.4.11 which are stored in a very old server that is running on ubuntu 10.04.4. Unfortunately, this server is about to give up on life and leave us ( :( ). So what I’ve been trying to do is to migrate this server to a new one which is running on Debian Squeeze 6.0.7 i386. Moreover there’s something I’d like to add, the old ledgersmb server was configurated by someone else who is not contactable, so at the present time I have no idea where he stored all the file. I managed to find the configuration file of ledgersmb which were located in /var/local/ledgersmb and also the PostgreSQL files which were in /var/lib/postgresql. (Am i missing some files here ?)

One of the step I’ve done was to install the LedgerSMB 1.3.23 with the PostgreSQL 8.20. From that point, some people told me to copy the configuration file as well as the data file from the old LedgerSMB to the new one. They also told me to copy the file from the old database of PostgreSQL from /var/lib/postgresql and paste it on the new one. (If this is how it should be done, why did it failed ? Or was it a step I should have done with the same version of my old server ?)

I’ve also tried to do a backup of the older server (which the database name & user’s ownership that are unknown to me) with sudo pg_dumpall >  /directory/backup. However, everytime i’ve tried to run that command on root or any other users, I received this message : Permission denied. But there’s one user named postgres which i couldn’t find its password.

So the main point is that I’m trying to migrate the old database to a new one and I’d like to have some advices because I’m about to rip my hair off!

Thanks in advance,
D. Nguyen
0
Comment
Question by:asusxtian
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 22

Accepted Solution

by:
earth man2 earned 500 total points
ID: 39923342
as root you can change postgres account password.

sudo root
passwd postgres

then you can run dumpall
0
 

Author Comment

by:asusxtian
ID: 39923510
Thanks a lot! finally solved the backup issue!
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Many developers have database experience, but are new to PostgreSQL. It has some truly inspiring capabilities. I have several years' experience with Microsoft's SQL Server. When I began working with MySQL, I wanted a quick-reference to MySQL (htt…
By, Vadim Tkachenko. In this article we’ll look at ClickHouse on its one year anniversary.
Steps to create a PostgreSQL RDS instance in the Amazon cloud. We will cover some of the default settings and show how to connect to the instance once it is up and running.
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question