Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #202111
| From | Stefan Monnier <monnier@iro.umontreal.ca> |
|---|---|
| Newsgroups | linux.debian.user |
| Subject | Re: Recommendation on partition sizes |
| Date | 2018-11-04 21:00 +0100 |
| Message-ID | <wQwIV-2NQ-1@gated-at.bofh.it> (permalink) |
| References | <wQhgR-2aK-3@gated-at.bofh.it> <wQhgR-2aK-1@gated-at.bofh.it> <wQiwh-2PA-3@gated-at.bofh.it> <wQsOZ-xe-9@gated-at.bofh.it> <wQtrH-Zf-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
>> I use LVM volumes for my swap space, which is yet another option, one
>> that can be grown and shrunk easily, online.
> You can resize a logical volume online, but AFAIK you cannot resize a swap
> area online (while in use) ;
Indeed, in the general case you'll need to do it like:
lvcreate --name tmpswap --size NNg <VG>
mkswap /dev/<VG>/tmpswap
swapon /dev/<VG>/tmpswap
swapoff /dev/<VG>/swap
lvresize --size +2g /dev/<VG>/swap
mkswap /dev/<VG>/swap
swapon /dev/<VG>/swap
swapoff /dev/<VG>/tmpswap
lvremove /dev/<VG>/tmpswap
but in my case, the need to resize was typically when hibernate failed
because the swap was not sized accordingly, so I could just do:
swapoff /dev/<VG>/swap
lvresize --size +2g /dev/<VG>/swap
mkswap /dev/<VG>/swap
swapon /dev/<VG>/swap
[ Sadly --resizefs doesn't work on a swap partition, AFAICT. ]
Stefan
Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Recommendation on partition sizes D&P Dimov <lddimov@yahoo.com> - 2018-11-04 04:30 +0100
Re: Recommendation on partition sizes Andy Smith <andy@strugglers.net> - 2018-11-04 05:50 +0100
Re: Recommendation on partition sizes Pascal Hambourg <pascal@plouf.fr.eu.org> - 2018-11-04 10:30 +0100
Re: Recommendation on partition sizes Andy Smith <andy@strugglers.net> - 2018-11-04 14:00 +0100
Re: Recommendation on partition sizes Pascal Hambourg <pascal@plouf.fr.eu.org> - 2018-11-04 14:40 +0100
Re: Recommendation on partition sizes Andy Smith <andy@strugglers.net> - 2018-11-04 14:50 +0100
Re: Recommendation on partition sizes Pascal Hambourg <pascal@plouf.fr.eu.org> - 2018-11-04 16:00 +0100
Re: Recommendation on partition sizes Rick Thomas <rbthomas@pobox.com> - 2018-11-05 09:20 +0100
Re: Recommendation on partition sizes Pascal Hambourg <pascal@plouf.fr.eu.org> - 2018-11-05 19:50 +0100
Re: Recommendation on partition sizes Stefan Monnier <monnier@iro.umontreal.ca> - 2018-11-04 16:50 +0100
Re: Recommendation on partition sizes Pascal Hambourg <pascal@plouf.fr.eu.org> - 2018-11-04 17:30 +0100
Re: Recommendation on partition sizes Stefan Monnier <monnier@iro.umontreal.ca> - 2018-11-04 21:00 +0100
Re: Recommendation on partition sizes Pascal Hambourg <pascal@plouf.fr.eu.org> - 2018-11-04 23:30 +0100
Re: Recommendation on partition sizes Stefan Monnier <monnier@iro.umontreal.ca> - 2018-11-05 00:20 +0100
Re: Recommendation on partition sizes Pascal Hambourg <pascal@plouf.fr.eu.org> - 2018-11-05 20:20 +0100
Re: Recommendation on partition sizes Curt <curty@free.fr> - 2018-11-05 09:40 +0100
Re: Recommendation on partition sizes Michael Stone <mstone@debian.org> - 2018-11-05 16:20 +0100
Re: Recommendation on partition sizes Stefan Monnier <monnier@iro.umontreal.ca> - 2018-11-06 15:10 +0100
Re: Recommendation on partition sizes Michael Stone <mstone@debian.org> - 2018-11-06 16:20 +0100
Re: Recommendation on partition sizes Michael Stone <mstone@debian.org> - 2018-11-04 17:40 +0100
Re: Recommendation on partition sizes David Christensen <dpchrist@holgerdanske.com> - 2018-11-04 08:40 +0100
Re: Recommendation on partition sizes Michael Stone <mstone@debian.org> - 2018-11-04 15:10 +0100
Re: Recommendation on partition sizes Pascal Hambourg <pascal@plouf.fr.eu.org> - 2018-11-04 10:30 +0100
csiph-web