From: | trafdev <trafdev(at)mail(dot)ru> |
---|---|
To: | "Christofer C(dot) Bell" <christofer(dot)c(dot)bell(at)gmail(dot)com> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: pg_dump fundenental question |
Date: | 2016-07-05 22:21:06 |
Message-ID: | 25a37d95-a304-8a8c-c873-c6f683d53ceb@mail.ru |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
"less" is much better for opening huge text files in *nix for reading.
On 07/05/16 15:13, Christofer C. Bell wrote:
> On Tue, Jul 5, 2016 at 3:17 PM, Paul Linehan <linehanp(at)tcd(dot)ie
> <mailto:linehanp(at)tcd(dot)ie>> wrote:
>
> > a good point, but I would prefer NOT to open a 324GB backup file in a text
> > editor. I can however cat/less/head/tail the file in Linux.
>
> Use vi (or flavour thereof) - it doesn't load the entire file in
> order to
> read the contents of lines 1 - 100 (say).
>
>
> What Paul says is very true, but if you are doing this, do be cognizant
> of where your fingers are. If you press any key that will put vi into
> edit mode, it will then make a copy of the file for backup purposes.
> Your 324GB file will become 648GB of disk usage and you'll have to wait
> while the backup copy is written out to disk. It will not load the
> whole file into memory (ever) nor will it make a copy of the file as
> long as you stay in command mode.
>
> If you want to use vi or equivalent for viewing the file without any
> danger of accidentally putting the editor into edit mode (and thus
> triggering the backup copy), you may want to invoke vi as "view(1)".
> This opens vi read-only and you'll be able to use vi style hotkeys for
> navigation.
>
>
> Paul...
>
>
> Chris
>
> "If you wish to make an apple pie from scratch, you must first invent
> the Universe." -- Carl Sagan
>
>
From | Date | Subject | |
---|---|---|---|
Next Message | David G. Johnston | 2016-07-05 22:28:25 | Re: Possible to create canonicalized range type without being superuser? |
Previous Message | Christofer C. Bell | 2016-07-05 22:13:40 | Re: pg_dump fundenental question |