From: Sergey Vlasov <vsu@altlinux.ru>
To: sisyphus@altlinux.ru
Subject: Re: [sisyphus] Swap and software RAID
Date: Fri, 5 Dec 2003 10:34:39 +0300
Message-ID: <20031205073439.GB1844@sirius.home> (raw)
In-Reply-To: <20031205090219.26f07c6a.bga-no-spam@kovgok.ru>
[-- Attachment #1: Type: text/plain, Size: 1852 bytes --]
On Fri, Dec 05, 2003 at 09:02:19AM +0300, Grigory Batalov wrote:
> Здравствуйте!
>
> Подскажите, как лучше расположить swap на дисках, предназначенных
> для software RAID? У меня есть следующие соображения:
>
> Имеются три SCSI hot-swap диска, корневой раздел - raid1,
> дополнительные - raid5.
>
> 1. Допустим, swap тоже raid1
>
> При сбое диска, или если я его сам вытащу, устройства md*
> будут помечаться как сбойные (F) только при обращении к ним.
> (Или можно указать принудительно?)
> Например:
>
> md0 : active raid1 sdc1[0](F) sda1[2] sdb1[1]
> 1052160 blocks [3/3] [_UU]
>
> После чего можно отключить сбойный раздел:
>
> raidhotremove /dev/md0 /dev/sdc1
>
> Удаление scsi-устройства из таблицы /proc/scsi/scsi, как я
> обнаружил, возможно лишь при неиспользовании его разделов
> одним из /dev/md*:
>
> echo "scsi remove-single-device 0 0 2 0" > /proc/scsi/scsi
>
> Однако, swap требуется не всегда. Cоответственно, чтобы
> удалить scsi-устройство, нужно ждать, пока
>
> - произойдёт обращение к swap на md
> - составная часть sdc1 пометится как сбойная (F)
> - я смогу её отключить с помощью raidhotremove
>
> Вопрос 1: сколько этого ждать или как ускорить?
Так есть же raidsetfaulty.
> Другой вариант: сделать swapoff /dev/md0 и raidstop /dev/md0,
> но тогда система некоторое время будет существовать без swap.
>
> Вопрос 2: что в этом случае произойдёт и насколько это опасно?
В зависимости от ситуации - например, может просто не хватить памяти
для swapoff.
> 2. Допустим, я не делал raid1, а сделал 3 раздела swap:
> /dev/sda1, /dev/sdb1, /dev/sdc1. Вытаскиваю /dev/sda.
>
> Вопрос 3: как скоро ядро поймет, что swap N1 недоступен,
> и пора попытаться сбросить данные на swap N2 или N3 ?
> Насколько это ожидание окажется критичным для процессов,
> требующих swap?
Никак не поймёт. Да и процессы попадают...
[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]
next prev parent reply other threads:[~2003-12-05 7:34 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-12-05 6:02 Grigory Batalov
2003-12-05 7:34 ` Sergey Vlasov [this message]
2003-12-05 8:50 ` Grigory Batalov
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=20031205073439.GB1844@sirius.home \
--to=vsu@altlinux.ru \
--cc=sisyphus@altlinux.ru \
/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 Sisyphus discussions
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/sisyphus/0 sisyphus/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 sisyphus sisyphus/ http://lore.altlinux.org/sisyphus \
sisyphus@altlinux.ru sisyphus@altlinux.org sisyphus@lists.altlinux.org sisyphus@lists.altlinux.ru sisyphus@lists.altlinux.com sisyphus@linuxteam.iplabs.ru sisyphus@list.linux-os.ru
public-inbox-index sisyphus
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.sisyphus
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git