Author Topic: 1 Running Install + 2 Live on HD  (Read 816 times)

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8590
  • Aurum nostrum non est aurum vulgi.
1 Running Install + 2 Live on HD
« on: February 10, 2012, 07:57:34 AM »
My turn ...

Quote
Recently, I have remastered a build environment based on Minime 2012.02 (and an updated Test4) and use those as LiveHD so after a build and copying the SRPM and RPM to my local repo on a USB HD and reboot, the build environment would be "clean" again.

You haven't mentioned it, so ......  are you using 'persistence' in this live environment so that you can take a break from a session and return to it retaining "changes"?
When that packaging work is completed then delete the "changes" and return to the 'clean' boot for the next session ........  or is it that the changes made during a session do not ALL get saved during 'persistence'?

Only me wondering how you are doing things is all ....  :D

Code: [Select]
Use aliases to become more productive:
'cetc'   -->    cd /etc/
archie@arevalo.ph ~ > df -T
Filesystem    Type    Size  Used Avail Use% Mounted on
/dev/sda5     ext4     25G  8.0G   16G  34% /
/dev/sda6     ext4     83G  1.5G   82G   2% /home
/dev/sdb1     ext3    459G  164G  272G  38% /media/PCLinuxOS
archie@arevalo.ph ~ > ll /pcliveos/
total 2950712
drwxr-xr-x 2 root root       4096 Feb  7 16:48 32pack-isolinux/
-rwxrwxr-x 1 root root 1396363264 Feb  7 16:48 32pack.sqfs*
drwxr-xr-x 2 root root       4096 Feb  8 20:07 64pack-isolinux/
-rw-r--r-- 1 root root 1625149440 Feb  8 20:07 64pack.sqfs
archie@arevalo.ph ~ > su
Password:
Use aliases to become more productive:
root@arevalo.ph archie > cat /boot/grub/menu.lst
timeout 1
color black/cyan yellow/cyan
gfxmenu (hd0,4)/boot/gfxmenu
default 0

title PCLinuxOS 64
kernel (hd0,4)/boot/vmlinuz BOOT_IMAGE=linux root=UUID=569d187d-c0f8-4618-aab9-93c07fcc60fd  quiet nokmsboot acpi=on resume=UUID=24c04e2b-474d-4cbb-84f2-67a47d8a3bad splash=silent vga=788
initrd (hd0,4)/boot/initrd.img

title PCLinuxOS 32-bit Packaging Environment
kernel (hd0,4)/pcliveos/32pack-isolinux/vmlinuz livecd=/pcliveos/32pack fromusb root=LABEL=/pcLiveos quiet fstab=rw,noauto acpi=on resume=LABEL=/pcliveos splash=silent vga=788
initrd (hd0,4)/pcliveos/32pack-isolinux/initrd.gz

title PCLinuxOS 64-bit Packaging Environment
kernel (hd0,4)/pcliveos/64pack-isolinux/vmlinuz livecd=/pcliveos/64pack fromusb root=LABEL=/pcLiveos quiet fstab=rw,noauto acpi=on resume=LABEL=/pcliveos splash=silent vga=788
initrd (hd0,4)/pcliveos/64pack-isolinux/initrd.gz
root@arevalo.ph archie >

So comes persistent ... and questions. How would I be able to separate the changes_dev=LABEL=/pcliveos for 32 and 64?

Is it possible to write the changes on another partition like for example on a subfolder on my "not-live" /home folder?

Another thing I'd like to address is the space allocation. When I boot on a Live environment, I would only have 1GiB to use. I don't think the live session uses the remaining hard disk space because I would still have about 16GiB. It might have something to do with RAM which my machine only has 2GiB. Any ideas on how I can get around to increasing the space allocation on the live sessions?

Peace and much respect,
Archie
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Online Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10667
  • MLUs Forever!
Re: 1 Running Install + 2 Live on HD
« Reply #1 on: February 10, 2012, 05:00:31 PM »
Quote
So comes persistent ... and questions. How would I be able to separate the changes_dev=LABEL=/pcliveos for 32 and 64?

When installing to the LiveUSB include the 'Persistent' boot option.
It uses the UUID and not Label.
Because you use different names for 32 & 64 bit when installing, the changes will also be saved separately.

Quote
Is it possible to write the changes on another partition like for example on a subfolder on my "not-live" /home folder?

Yes .......  edit the menu.lst file on the USB device to point the changes_dev elsewhere.

Quote
Another thing I'd like to address is the space allocation. When I boot on a Live environment, I would only have 1GiB to use.

1GB of what? .......  I think you may mean your available memory? The space for saving files and/or changes is determined by the space on the partition the change_dev is pointed at.

Quote
I don't think the live session uses the remaining hard disk space because I would still have about 16GiB. It might have something to do with RAM which my machine only has 2GiB. Any ideas on how I can get around to increasing the space allocation on the live sessions?

Yes it uses the drive space left after the install ......  less any files you may have added afterwards, either by saving files or saving changes.

All live sessions are limited by RAM ........  you could arrange to make some Swap space available (and mounted) which might help with the lack of RAM (if that is a problem). I would wonder if it is an actual problem ......  but having Swap space available and checking (top) if the session uses it would sort out that question.

regards.
MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8590
  • Aurum nostrum non est aurum vulgi.
Re: 1 Running Install + 2 Live on HD
« Reply #2 on: February 10, 2012, 07:52:15 PM »
Code: [Select]
archie@arevalo.ph ~ > cat /etc/fstab
# Entry for /dev/sda5 :
UUID=569d187d-c0f8-4618-aab9-93c07fcc60fd / ext4 defaults 1 1
# Entry for /dev/sda6 :
UUID=935585fa-8d39-428f-b7c8-f6d7f75e8adb /home ext4 defaults,user_xattr 1 2
none /proc proc defaults 0 0
# Entry for /dev/sda1 :
UUID=24c04e2b-474d-4cbb-84f2-67a47d8a3bad swap swap defaults 0 0
none /dev/pts devpts defaults 0 0

I am making changes to my /boot/grub/menu.lst. Please take a look and see if the changes I did are acceptable.

Code: [Select]
title PCLinuxOS 32-bit Packaging Environment
kernel (hd0,4)/pcliveos/32pack-isolinux/vmlinuz livecd=/pcliveos/32pack fromusb root=LABEL=/pcLiveos quiet fstab=rw,noauto acpi=on resume=LABEL=/pcliveos splash=silent vga=788 changes_dev=UUID=935585fa-8d39-428f-b7c8-f6d7f75e8adb
initrd (hd0,4)/pcliveos/32pack-isolinux/initrd.gz

title PCLinuxOS 64-bit Packaging Environment
kernel (hd0,4)/pcliveos/64pack-isolinux/vmlinuz livecd=/pcliveos/64pack fromusb root=LABEL=/pcLiveos quiet fstab=rw,noauto acpi=on resume=LABEL=/pcliveos splash=silent vga=788 changes_dev=UUID=935585fa-8d39-428f-b7c8-f6d7f75e8adb
initrd (hd0,4)/pcliveos/64pack-isolinux/initrd.gz

Quote
Another thing I'd like to address is the space allocation. When I boot on a Live environment, I would only have 1GiB to use.

1GB of what? .......  I think you may mean your available memory? The space for saving files and/or changes is determined by the space on the partition the change_dev is pointed at.

Not available memory. When I open Dolphin, I set it to read remaining disk space at the status bar.

[quote
I don't think the live session uses the remaining hard disk space because I would still have about 16GiB. It might have something to do with RAM which my machine only has 2GiB. Any ideas on how I can get around to increasing the space allocation on the live sessions?

Yes it uses the drive space left after the install ......  less any files you may have added afterwards, either by saving files or saving changes.[/quote]

I don't understand this bit. Clearly, I still have 16GiB of space on my / partition so shouldn't the live session also be using that?

Quote
All live sessions are limited by RAM ........  you could arrange to make some Swap space available (and mounted) which might help with the lack of RAM (if that is a problem). I would wonder if it is an actual problem ......  but having Swap space available and checking (top) if the session uses it would sort out that question.

Oh, it is a problem! I tried to build gimp-2.6.12 and I ran out of space. The session wouldn't budge. Tried REISUB, nada. Hard reboot.

And how can I arrange to make some RAM space available. I use very low SWAP, 2GiB)

Thanks for the input and help, Just18. I really appreciate it.

Peace and much respect,
Archie
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8590
  • Aurum nostrum non est aurum vulgi.
Re: 1 Running Install + 2 Live on HD
« Reply #3 on: February 10, 2012, 08:58:46 PM »
UPDAYE:

I went ahead and made the changes to /boot/grub/menu.lst. I made a couple of changes:

  • adjusted the screen resolution to 1280x800 from the default 1024x768
  • installed knsapshot so I can take a screenshot of dolphin

The change in screen resolution did not stick but KSnapshot was still installed. I checked the location I assigned changes to be written.



I am guessing that since my live session is a remaster and isn't an install, this could explain why I still have to go to the process of selecting a keyboard layout and why the screen resolution adjustment did not stick.

As for the hard disk space available on the live session:



Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Online Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10667
  • MLUs Forever!
Re: 1 Running Install + 2 Live on HD
« Reply #4 on: February 11, 2012, 05:16:15 AM »
Quote
Quote
Yes it uses the drive space left after the install ......  less any files you may have added afterwards, either by saving files or saving changes.

I don't understand this bit. Clearly, I still have 16GiB of space on my / partition so shouldn't the live session also be using that?

No, you have 16GB space on the partition, but that is not your  /   when running live.

Live systems use a virtual disk/ram disk, which is why you can load the live OS into RAM using the Copy2RAM option, and run it without any drive being present, or run it from a CD etc.
I think this is where the confusion is coming in.
The output of your 'df' command shows your   /   as a 1GB ram disk.
Issue a 'mount' command to see it a bit more clearly ...
Code: [Select]
mount
/dev/root on / type rootfs (rw)

I would have to check, but the size of the RAM disk is defined in one of the mylivecd config files IIRC. Whether it is feasible or not to make changes there for your purposes I am unsure as I never tried it.

As you have shown, the changes can be written to any suitable location.

Quote
title PCLinuxOS 32-bit Packaging Environment
kernel (hd0,4)/pcliveos/32pack-isolinux/vmlinuz livecd=/pcliveos/32pack fromusb root=LABEL=/pcLiveos quiet fstab=rw,noauto acpi=on resume=LABEL=/pcliveos splash=silent vga=788 changes_dev=UUID=935585fa-8d39-428f-b7c8-f6d7f75e8adb
initrd (hd0,4)/pcliveos/32pack-isolinux/initrd.gz

The above boot stanza does not appear to be one generated by the LiveUSB Creator, which does not use 'LABEL' but instead uses UUID. The latest also includes the 'quiet' boot option. That is just a comment, nothing more  ;)

It would appear that because of the default limitation of the size of the ram disk being used as  /  that this scheme may not be the most suitable for your purposes.

Have you tried mounting a Swap partition while running live .....  maybe a Swap from one of the internal HDDs? Use the command

#swapon /dev/sdXY  (in my case swapon /dev/sda8 mounts the swap partition)

That should effectively give you more memory available when running live and might only come into use when packaging a large app.

Again I have to say this is something I have not had cause to investigate.


Regarding the questions that require answering when booting ....  I seem to recall a discussion on that ....  posted in the forum. .....  memory problems again ....  :(

I dunno if I have addressed all you asked .....  but if not please post again  ;)

Some of your questions could be better answered by others also, so maybe they will drop by.

regards
MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT

Offline Archie

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 8590
  • Aurum nostrum non est aurum vulgi.
Re: 1 Running Install + 2 Live on HD
« Reply #5 on: February 11, 2012, 06:13:21 AM »
You have done more than enough for my enquiries, Just18. Thank you.

As for my /boot/grub/menu.lst stanzas, I had to write them up myself. I copied the livecd contents that were not deleted when I ran mylivecd from the command line ... I am still old-fashioned.  ;)

Quote
It would appear that because of the default limitation of the size of the ram disk being used as  /  that this scheme may not be the most suitable for your purposes.

For small to medium-sized apps, it is OK so far. The last package I built was spacefm and it pulled in over 300MiB of devels and libraries. After build, I still had approximately 200mb of space left.

I will try swapon next time I am on a live session and report back.

I can't really have something that isn't there, can I? So I'll just have to make do with what I got ... and be glad for it.

Peace and much respect,
Archie
Since 2006 | LiCo 401868 | Bare Metal | What is necessary is never unwise. --Sarek, 2258.42


Online Just17

  • PCLinuxOS Tester
  • Super Villain
  • *******
  • Posts: 10667
  • MLUs Forever!
Re: 1 Running Install + 2 Live on HD
« Reply #6 on: February 11, 2012, 06:21:10 AM »
Quote
I will try swapon next time I am on a live session and report back

manually mounting a Swap partition in the live session does provide swap space to it.

based on what you said above this should be sufficient for the odd occasion (apparently) that you run low on ram.
MLUs rule the roost!

Linux XPS 3.4.38-pclos1.bfs  64 bit
Intel Core2 Quad CPU Q9450 @ 2.66GHz
4 GB RAM
MCP51 High Def Audio
GeForce GTX 550 Ti
PHILIPS  ‎DVD+-RW DVD8701
‎Logitech ‎BT Mini-Receiver
Afatech DTT