[ale] what should I do when resizing ext4 partition
Jim Kinney
jim.kinney at gmail.com
Tue Jun 11 13:49:51 EDT 2013
I use LVM for all but /boot. So swap is a logical partition. That way I can
tune the size of it as required.
Additionally, for laptops, I can encrypt the entire PVM so swap is also
encrypted for situations where the laptop hibernates.
I have found that hibernations requires 1+X RAM for proper use. Not much
more than 1X but enough to fully write out all of RAM plus a tiny bit extra
used to tell the kernel to restore from swap. That will change if swap is
actually used for a long-running process. 1.2 - 1.5 X RAM seems fair. Hard
drives are cheaper than RAM anyway :-)
On Tue, Jun 11, 2013 at 10:57 AM, Ron Frazier (ALE) <
atllinuxenthinfo at techstarship.com> wrote:
> Hi guys,
>
> Thanks for these tips. With all the partition resizing and uuid changing,
> I didn't know how radical to get rebuilding the swap partition. The system
> is running now, but, if the need arises again, I'll probably try the
> commands you listed.
>
> I know it's been mentioned before to some extent, but could you (or
> anyone) comment on the virtues of using a swap partition versus using a
> swap file. Windows uses a swap file. Years ago I had Ubuntu running with
> a swap file using a procedure I found online. When I installed Mint
> recently, I set up a swap partition just because it's easier. These days,
> I generally set the swap space as 1X RAM on Linux and 2X RAM on Windows.
> If I have the money, I try to put 8 GB of RAM in right off the bat. That
> gives the system lots of breathing room. The one big advantage of a swap
> file, versus a swap partition, is that it's much easier to expand it later.
>
> Sincerely,
>
> Ron
>
>
>
> On 6/11/2013 10:01 AM, Chuck Payne wrote:
>
>> Ron,
>>
>> I would do as Derek said, just do a mkswap, I have done on systems
>> where I dropped the old swap and created a new one that was a bit
>> bigger.
>>
>> Just make do the following
>>
>> swapoff
>>
>> del or resize the old swap
>>
>> mkswap /dev/partition of the swap
>>
>> swapon
>>
>> Update fstab if you delete it and created a new one.
>>
>>
>>
>> On Tue, Jun 11, 2013 at 9:43 AM, Derek Atkins<warlord at mit.edu> wrote:
>>
>>
>>> "Ron Frazier (ALE)"<atllinuxenthinfo@**techstarship.com<atllinuxenthinfo at techstarship.com>>
>>> writes:
>>>
>>>
>>>
>>>> On the Linux side of the fence, the boot loader was indeed broken. I
>>>> used the Ubuntu boot repair disc which rebuilt grub for me. Mint then
>>>> booted fine, but the swap partition was not active according to system
>>>> monitor. I used gparted to delete and recreate the swap partition,
>>>> then rebooted. The swap was still not active. I looked at the
>>>> /etc/fstab file and found in the comments that you can use blkid to
>>>> read the UUID of each partition. I also found that the UUID was wrong
>>>> for both the / partition and the swap. I'm not sure how the system
>>>> booted in this case, but I'm not complaining. I changed the UUID for
>>>> both entries in the fstab file to the correct number for the / and
>>>> swap partitions respectively and rebooted again. This time, the swap
>>>> partition was working.
>>>>
>>>>
>>> Ah, most likely the was Acronis did it was to actually mkfs new
>>> filesystems on the new drive, which generated new UUIDs, instead of
>>> doing a 'dd' and then fs-resize. That would explain the UUID changes.
>>>
>>> As for the swap, depending on what acronis did you might just need to
>>> "mkswap" to re-initialize the swap partition. You shouldn't need to
>>> erase and recreate the partition..
>>>
>>> -derek
>>>
>>> --
>>> Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
>>> Member, MIT Student Information Processing Board (SIPB)
>>> URL: http://web.mit.edu/warlord/ PP-ASEL-IA N1NWH
>>> warlord at MIT.EDU PGP key available
>>>
>>>
>>>
>>
> --
>
> (PS - If you email me and don't get a quick response, you might want to
> call on the phone. I get about 300 emails per day from alternate energy
> mailing lists and such. I don't always see new email messages very
> quickly.)
>
> Ron Frazier
> 770-205-9422 (O) Leave a message.
> linuxdude AT techstarship.com
> Litecoin: LZzAJu9rZEWzALxDhAHnWLRvybVAVg**wTh3
> Bitcoin: 15s3aLVsxm8EuQvT8gUDw3RWqvuY9h**PGUU
>
> ______________________________**_________________
> Ale mailing list
> Ale at ale.org
> http://mail.ale.org/mailman/**listinfo/ale<http://mail.ale.org/mailman/listinfo/ale>
> See JOBS, ANNOUNCE and SCHOOLS lists at
> http://mail.ale.org/mailman/**listinfo<http://mail.ale.org/mailman/listinfo>
>
--
--
James P. Kinney III
*
*Every time you stop a school, you will have to build a jail. What you gain
at one end you lose at the other. It's like feeding a dog on his own tail.
It won't fatten the dog.
- Speech 11/23/1900 Mark Twain
*
http://electjimkinney.org
http://heretothereideas.blogspot.com/
*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.ale.org/pipermail/ale/attachments/20130611/c7012b4d/attachment.html>
More information about the Ale
mailing list