From: Sergey Vlasov <vsu@altlinux.ru>
To: community@lists.altlinux.org
Subject: Re: [Comm] длина имени файла в локали utf8 (ext3)
Date: Sun, 18 Mar 2007 23:33:30 +0300
Message-ID: <20070318203330.GB3937@procyon.home> (raw)
In-Reply-To: <op.tpeguohnglg102@post.cnt.ru>
[-- Attachment #1: Type: text/plain, Size: 1501 bytes --]
On Sun, Mar 18, 2007 at 10:38:38PM +0300, Владимир Гусев wrote:
> Сейчас занимаюсь переконвертацией из pdf в djvu с промежуточным
> конвертированием в ps. Файлы ps получаются здоровенные, так если размер
> такого файла превышает 2.1 гб, высвечивается след. сообщение:
>
> [vova@vova pdf]$ pdf2ps Astronomiya_s_binoklem_1903.pdf
> Astronomiya_s_binoklem_1903.ps
> Превышен лимит размера файла
>
> при этом:
>
> [vova@vova pdf]$ ls -h -s
> итого 2,6G
> [..]
> 78M Astronomiya_s_binoklem_1903.pdf
> 2,1G Astronomiya_s_binoklem_1903.ps
> ^^^^^
>
> Немного оффтоп, но касается ограничений ext3.. И как это обходить?
Это ограничение не ext3, а pdf2ps (точнее, gs, который фактически
выполняет всю работу). 32-разрядные программы не могут работать с
файлами больше 2 ГБ без принятия специальных мер (например, один из
вариантов - собирать с опцией -D_FILE_OFFSET_BITS=64, но при этом
программа должна быть написана с учётом того, что позиция в файле
может быть 64-разрядным числом, не помещающимся в переменную типа int
или long - т.е., нельзя просто добавить эту опцию без проверки кода на
правильное использование нужных типов).
Можно попробовать такой вариант:
pdf2ps file.pdf - >file.ps
В этом случае файл будет открывать shell, что позволит обойти
проблему (флаг O_LARGEFILE устанавливается в момент открытия). Если
по каким-то причинам такой вариант тоже не сработает, можно добавить
промежуточный pipe:
pdf2ps file.pdf - | cat >file.ps
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
next prev parent reply other threads:[~2007-03-18 20:33 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-18 16:03 Andrei Lomov
2007-03-18 16:15 ` [Comm] длина имени файла в локали utf8 (ext3) [JT] Andrei Lomov
2007-03-18 21:30 ` Alexey Rusakov
2007-03-19 8:25 ` Andrei Lomov
2007-03-18 17:29 ` [Comm] длина имени файла в локали utf8 (ext3) Vyatcheslav Perevalov
2007-03-18 19:38 ` Владимир Гусев
2007-03-18 20:33 ` Sergey Vlasov [this message]
2007-03-18 21:30 ` Владимир Гусев
2007-03-18 21:40 ` [Comm] Работа с файлами > 2 гб [was: длина имени файла в локали utf8 (ext3)] Владимир Гусев
2007-03-19 8:15 ` [Comm] длина имени файла в локали utf8 (ext3) Андрей Черепанов
2007-03-19 15:27 ` Андрей Черепанов
2007-03-19 16:45 ` Andrei Lomov
2007-03-19 16:46 ` Mikhail Gusarov
2007-03-19 16:49 ` Andrei Lomov
2007-03-19 16:57 ` Andrei Lomov
2007-03-19 16:57 ` Mikhail Gusarov
2007-03-19 16:47 ` Andrei Lomov
2007-03-19 15:51 ` [Comm] длина имени файла в локали utf8 (ext3)[JT] Andrei Lomov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070318203330.GB3937@procyon.home \
--to=vsu@altlinux.ru \
--cc=community@lists.altlinux.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
ALT Linux Community general discussions
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/community/0 community/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 community community/ http://lore.altlinux.org/community \
mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com
public-inbox-index community
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.community
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git