Re: Largest filesize under Linux

Поиск
Список
Период
Сортировка
От byron@cc.gatech.edu (Byron A Jeff)
Тема Re: Largest filesize under Linux
Дата
Msg-id b4lakr$pd3@cleon.cc.gatech.edu
обсуждение исходный текст
Ответ на Largest filesize under Linux  ("Partho Bhowmick" <pbhowmick@sbcglobal.net>)
Список pgsql-admin
In article <e4pba.794$yy2.89177201@newssvr13.news.prodigy.com>,
Partho Bhowmick <pbhowmick@sbcglobal.net> wrote:
-I am working on extending the functionality of PostgreSQL on Linux.
-I need to know what's the largest filesize for a single file that I can have
-under Linux?

The answer is definitive: it depends...

There are multiple layers that have file size restrictions (from bottom to top):

* The filesystem itself on the disk.
* The Virtual File System implementation in the kernel.
* The filesystem library interface.
* The application.

The max file size is the minimum of the allowable file sizes for each
component. Generally there are two available sizes:

* 2.1GB imposed by a +/- 31 bit file offset. Until recently the VFS, library,
  and applications imposed this limit.
* 9 million TB imposed by a +/- 63 bit file offset. Most recent distributions
  have all 4 elements implementing this filesize.

Here's a simple test. On a filesystem with more than 5GB available try the
following:

# dd if=/dev/zero of=testfilesize bs=1024K count=3000

This will attempt to create a 3GB file which exceeds the 2.1GB max imposed by
31 bit offsets. If the file creation is successful, you can pretty much
create a file of any size.

BAJ

В списке pgsql-admin по дате отправления:

Предыдущее
От: "Partho Bhowmick"
Дата:
Сообщение: Largest filesize under Linux
Следующее
От: Chris Mungall
Дата:
Сообщение: Using functions as filters in queries