Search Postgresql Archives
Re: Dump Database
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
pgsql-general-owner@xxxxxxxxxxxxxx wrote on 17/03/2014
12:50:20:
> From: José Pedro Santos <zpsantos1@xxxxxxxxxxx>
> To: Postgres Ajuda <pgsql-general@xxxxxxxxxxxxxx>,
> Date: 17/03/2014 12:56
> Subject: Dump Database
> Sent by: pgsql-general-owner@xxxxxxxxxxxxxx
>
> Dear all,
>
> I'm trying to dump my database using the following command after I
> enter as su postgres:
>
> pg_dump - U postgres mydb -f mydb.sql
>
> ... but I'm always having the following message:
>
> pg_dump [archiver] Could not open output file "mydb.sql"
: Permission denied
>
> I try to use the same statement using su.. but I didn't manage. Can
> someone give me a help?
>
> I'm using Ubuntu 12.04 LTS and Postgres 9.1.
>
> Kind Regards,
> José Santos
The assumption here is that you're in a directory
where you do not have permissions.
try:
# cd
# pg_dump -f mydb.sql -U postgres mydb
It also appears that you have a space between "-"
and "U", make sure that it appears: "-U".
Cheers
=============================================
Romax Technology Limited
A limited company registered in England and Wales.
Registered office:
Rutherford House
Nottingham Science and Technology Park
Nottingham
NG7 2PZ
England
Registration Number: 2345696
VAT Number: 526 246 746
Telephone numbers:
+44 (0)115 951 88 00 (main)
For other office locations see:
http://www.romaxtech.com/Contact
=================================
===============
E-mail: info@xxxxxxxxxxxxx
Website: www.romaxtech.com
=================================
================
Confidentiality Statement
This transmission is for the addressee only and contains information that
is confidential and privileged.
Unless you are the named addressee, or authorised to receive it on behalf
of the addressee
you may not copy or use it, or disclose it to anyone else.
If you have received this transmission in error please delete from your
system and contact the sender. Thank you for your cooperation.
=================================================
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]
[Postgresql Jobs]
[Postgresql Admin]
[Postgresql Performance]
[Linux Clusters]
[PHP Home]
[PHP on Windows]
[Kernel Newbies]
[PHP Classes]
[PHP Books]
[PHP Databases]
[Postgresql & PHP]
[Yosemite]