Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 5BE6E1337B52 for ; Fri, 1 Oct 2010 08:08:00 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 16619-01 for ; Fri, 1 Oct 2010 11:07:53 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-bw0-f46.google.com (mail-bw0-f46.google.com [209.85.214.46]) by mail.postgresql.org (Postfix) with ESMTP id 9CC131336DB6 for ; Fri, 1 Oct 2010 08:07:52 -0300 (ADT) Received: by bwz11 with SMTP id 11so2069514bwz.19 for ; Fri, 01 Oct 2010 04:07:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from :user-agent:mime-version:to:cc:subject:references:in-reply-to :content-type:content-transfer-encoding; bh=082MIE5BndF010zl1SiEKdQZamymXAo0x7ieLGRuotM=; b=jyI2VuOQgK7SkvDfzHMmMpq0tq7F4GxolMfjr+dsD8n7FtsIQV3DyhU7+2CGcCPmr3 r5m6d7lUHMzP6pkT8ZlQySkyuvZmqtOecfOd/dyP9QU49m5reoOSk8VP2yQEg6hBv/By 4vdGtZEP6AIjwHe07CczxBr15BTdeE9Y0ZRt0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; b=CZxSXky7QpcD4ejVHSD3HUIBm71OVUdIq/kpF/R5S8yr26Lj8Xu1lHIJsFm8Pf+6Ov 7ZPYTmI7xNrO2M367nu+/12G8wmjLbEDoBBsVRcLEotGr5gUddpJlKvSbiSlOznYIUb2 R9vwQ2ow9+pn9O8z8LgmQdvBf9IwWry6mmWOc= Received: by 10.204.64.78 with SMTP id d14mr3878459bki.63.1285931269697; Fri, 01 Oct 2010 04:07:49 -0700 (PDT) Received: from [127.0.0.1] (ip-94-42-66-74.ibd.gtsenergis.pl [94.42.66.74]) by mx.google.com with ESMTPS id g12sm845845bkb.2.2010.10.01.04.07.48 (version=SSLv3 cipher=RC4-MD5); Fri, 01 Oct 2010 04:07:49 -0700 (PDT) Message-ID: <4CA5C0F7.8040407@gmail.com> Date: Fri, 01 Oct 2010 13:07:35 +0200 From: Michal Glowacki User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; pl; rv:1.9.2.9) Gecko/20100915 Thunderbird/3.1.4 MIME-Version: 1.0 To: Guillaume Lelarge CC: Fujii Masao , pgsql-admin@postgresql.org Subject: Re: Hot standby server does not start References: <4CA2F025.3010508@gmail.com> <4CA2F5ED.3000209@gmail.com> <4CA2FF32.6070002@lelarge.info> In-Reply-To: <4CA2FF32.6070002@lelarge.info> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-10 required=5 tests=BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001 X-Spam-Level: X-Archive-Number: 201010/5 X-Sequence-Number: 35746 hi, it's fine now - the problem was WinRAR which reported that he can't access some files and I ignored that - big mistake :) Thanks for help - working fine now. Michal > Le 29/09/2010 10:16, Michal Glowacki a écrit : >> Fujii, I believe I should follow this (from documentation): >> >> ************************ >> >> The procedure for making a base backup is relatively simple: >> >> 1. >> >> Ensure that WAL archiving is enabled and working. >> >> 2. >> >> Connect to the database as a superuser, and issue the command >> >> SELECT pg_start_backup('label'); >> >> where label is any string you want to use to uniquely identify >> this backup operation. (One good practice is to use the full path >> where you intend to put the backup dump file.) |pg_start_backup| >> creates a /backup label/ file, called backup_label, in the cluster >> directory with information about your backup. >> >> It does not matter which database within the cluster you connect >> to to issue this command. You can ignore the result returned by >> the function; but if it reports an error, deal with that before >> proceeding. >> >> 3. >> >> Perform the backup, using any convenient file-system-backup tool >> such as tar or cpio. It is neither necessary nor desirable to stop >> normal operation of the database while you do this. >> >> 4. >> >> Again connect to the database as a superuser, and issue the command >> >> SELECT pg_stop_backup(); >> >> This should return successfully. >> >> 5. >> >> Once the WAL segment files used during the backup are archived as >> part of normal database activity, you are done. >> >> >> ********************************** >> >> BUT I have some questions: >> >> 1. I connect to database using psql and issue command SELECT >> pg_start_backup('my_backup'); The result (in less than second) is: >> >> pg_start_backup >> ----------------- >> 4/DA000020 >> (1 row) >> >> Is it correct it goes that fast? >> > Yes. > >> 2. Now I proceed to step 3 - perform the backup using file system >> backup. Could you assist me on this one? I should archive what?The >> '/data' folder (please note I use Windows)? Should I just compress it >> into rar file and transfer to standby server and overwrite it's '/data' >> folder? >> > Using rar on the data folder should work if you don't have tablespaces. > If you have some, add them to your data rar archive. > > And instead of overwriting the data folder on the slave, wipe out your > old data folder and recreate it by restoring your rar archive. > > BTW, pgAdmin backup and restore facilities use pg_dump/pg_restore. So > it's not really surprising that you get the same results :) > >