Create new live disk from inside current live disk

Post your questions about Refracta here.

Create new live disk from inside current live disk

Postby Mister Monday » October 21st, 2018, 11:52 pm

I am running an LFA ("Linux for All", based on Ubuntu) distro live disk inside VMWare. The live disk has refracta tools installed by default. I would like to make some minor changes and then create a brand new live disk that I can run instead.

When I execute refractasnapshot it seems to run okay. It looks like it is examining every file, and eventually gets to a "All finished!" message. But when I check for the generated ISO file, it exists but is zero bytes.

What is going wrong? Since it is a live disk, I am not using the VMWare virtual disk for storage. But I have given the VM enough RAM I think. (8 GB)

Thanks.
Mister Monday
 
Posts: 18
Joined: October 21st, 2018, 11:43 pm

Re: Create new live disk from inside current live disk

Postby fsmithred » October 22nd, 2018, 10:59 am

Take a look at the error log (in /var/log/). Near the end, it probably tells you that you ran out of space.

If you want to create a snapshot from a running live system, you need to have some storage space to save the iso. You also need enough space for the work directory, which holds a copy of the file system. This could be physical disk space you share with the VM, a virtual disk, or a usb that's connected to the VM.

The normal location of the snaphot directory and work directory are in /home/. Edit /etc/refractasnapshot.conf to use a different location. (/media/usb for example, if that's where your storage space is mounted.)
fsmithred
 
Posts: 341
Joined: February 11th, 2011, 4:14 am

Re: Create new live disk from inside current live disk

Postby Mister Monday » October 23rd, 2018, 4:42 am

[s]Unfortunately, I seem to be unable to edit "refractasnapshot.conf", maybe because it is a live disk and not writable.[/s] edit: Never mind I just needed elevated privileges.

I am also unsure how to use refractainstall to install the LFA distro live disk to an empty hard drive. The tool requires me to setup the partitions manually, but I don't know exactly what types of partitions are needed.

Thanks anyway.
Mister Monday
 
Posts: 18
Joined: October 21st, 2018, 11:43 pm

Re: Create new live disk from inside current live disk

Postby Mister Monday » October 23rd, 2018, 5:38 am

I am trying again to use refractasnapshot. I have a 40GB empty hard drive mounted at "/media/newhd". I also gave 8GB RAM to the VM running the live disk. That should be enough space shouldn't it?

Here is my latest error log:

http://pastebin.com/5DFTLUcs

Code: Select all
ls: cannot access '/media/newhd/*.iso': No such file or directory

(yad:4625): GLib-CRITICAL **: 01:26:31.117: g_source_remove: assertion 'tag > 0' failed
rsync: write failed on "/home/work/myfs/rofs/var/lib/apt/lists/se.archive.ubuntu.com_ubuntu_dists_xenial_universe_binary-amd64_Packages": No space left on device (28)
rsync error: error in file IO (code 11) at receiver.c(393) [receiver=3.1.2]
sed: can't read /home/work/myfs/home/live/.config/geany/geany.conf: No such file or directory
sed: can't read /home/work/myfs/etc/ssh/sshd_config: No such file or directory
sed: can't read /home/work/myfs/etc/ssh/sshd_config: No such file or directory
sed: can't read /home/work/myfs/etc/ssh/sshd_config: No such file or directory
rm: cannot remove '/home/work/myfs/etc/NetworkManager/system-connections': Is a directory
1440+0 records in
1440+0 records out
1474560 bytes (1.5 MB, 1.4 MiB) copied, 0.00217231 s, 679 MB/s
cp: error writing 'boot/grub/x86_64-efi/ntfs.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/odc.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/offsetio.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/ohci.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/part_acorn.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/part_amiga.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/part_apple.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/part_bsd.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/part_dfly.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/part_dvh.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/part_gpt.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/partmap.lst': No space left on device
cp: error writing 'boot/grub/x86_64-efi/part_msdos.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/part_plan.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/part_sun.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/part_sunpc.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/parttool.lst': No space left on device
cp: error writing 'boot/grub/x86_64-efi/parttool.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/password.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/password_pbkdf2.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/pata.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/pbkdf2.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/pbkdf2_test.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/pcidump.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/play.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/png.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/priority_queue.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/probe.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/procfs.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/progress.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/raid5rec.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/raid6rec.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/random.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/read.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/reboot.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/regexp.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/reiserfs.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/relocator.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/romfs.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/scsi.mod': No space left on device
cp: error writing 'boot/grub/x86_64-efi/xorriso 1.4.8 : RockRidge filesystem manipulator, libburnia project.

Drive current: -outdev 'stdio:/media/newhd/lfa-64bit-lxde-efi-refracta-20181023_0131.iso'
Media current: stdio file, overwriteable
Media status : is blank
Media summary: 0 sessions, 0 data blocks, 0 data, 37.1g free
Added to ISO image: directory '/'='/home/work/iso'
xorriso : UPDATE : 37 files added in 1 seconds
xorriso : UPDATE : 37 files added in 1 seconds
xorriso : NOTE : Copying to System Area: 432 bytes from file '/usr/lib/ISOLINUX/isohdpfx.bin'
xorriso : FAILURE : Cannot find path '/boot/grub/efiboot.img' in loaded ISO image
xorriso : NOTE : -return_with SORRY 32 triggered by problem severity FAILURE
sha256sum: lfa-64bit-lxde-efi-refracta-20181023_0131.iso: No such file or directory

(yad:4762): GLib-CRITICAL **: 01:31:37.239: g_source_remove: assertion 'tag > 0' failed


[edit]

Never mind again. I simply forgot to set the work directory to something different in addition to the snapshot directory.

However, afterward the OS would not shutdown properly. Not sure why.
Mister Monday
 
Posts: 18
Joined: October 21st, 2018, 11:43 pm

Re: Create new live disk from inside current live disk

Postby fsmithred » October 23rd, 2018, 12:03 pm

40GB is more than enough space to install a system, boot that system, make whatever changes you want and then create a new snapshot iso. Then you wouldn't have to make the same changes every time you boot the live system.

You could install directly to the hard drive or you could use the hard drive to hold a virtual drive if you wanted to work in a VM.

When I make snapshots in a VM, I use a virtual disk that's around 12GB. That's enough to install the system, hold a copy of the system and a few snapshot isos. Maybe give it more space than that if it's a big installation. (>4GB)
fsmithred
 
Posts: 341
Joined: February 11th, 2011, 4:14 am

Re: Create new live disk from inside current live disk

Postby Mister Monday » October 23rd, 2018, 1:20 pm

I am also unsure how to use refractainstaller to install the LFA distro live disk to an empty hard drive. I created an extended partition containing two logical partitions. One is for the OS and one is for swap.

Refractinstaller seems to run okay, but I get two errors:

Code: Select all
Usage: grep [OPTION]... PATTERN [FILE]...
Try 'grep --help' for more information.
Usage: grep [OPTION]... PATTERN [FILE]...
Try 'grep --help' for more information.

(yad:4858): GLib-CRITICAL **: 05:05:47.757: g_source_remove: assertion 'tag > 0' failed
mke2fs 1.44.1 (24-Mar-2018)
usr/lib/x86_64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /usr/share/perl5/Debconf/FrontEnd/Gnome.pm line 151.)
debconf: falling back to frontend: Dialog

Current default time zone: 'US/Eastern'
Local time is now:      Tue Oct 23 05:05:43 EDT 2018.
Universal Time is now:  Tue Oct 23 09:05:43 UTC 2018.

debconf: unable to initialize frontend: Gnome
debconf: (Can't locate Gtk3.pm in @INC (you may need to install the Gtk3 module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/x86_64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /usr/share/perl5/Debconf/FrontEnd/Gnome.pm line 151.)
debconf: falling back to frontend: Dialog
Generating locales (this might take a while)...
  en_US.UTF-8... done
Generation complete.

 @@@ Cleaning up...

Code: Select all
Usage: grep [OPTION]... PATTERN [FILE]...
Try 'grep --help' for more information.
Usage: grep [OPTION]... PATTERN [FILE]...
Try 'grep --help' for more information.

(yad:4858): GLib-CRITICAL **: 05:05:47.757: g_source_remove: assertion 'tag > 0' failed
mke2fs 1.44.1 (24-Mar-2018)

(yad:4966): GLib-CRITICAL **: 05:14:32.012: g_source_remove: assertion 'tag > 0' failed
262144+0 records in
262144+0 records out
268435456 bytes (268 MB, 256 MiB) copied, 1.64743 s, 163 MB/s
mkswap: /target/swapfile: insecure permissions 0644, 0600 suggested.
sed: can't read /target/etc/ssh/sshd_config: No such file or directory
sed: can't read /target/etc/ssh/sshd_config: No such file or directory
grub-install: error: /usr/lib/grub/i386-pc/modinfo.sh doesn't exist. Please specify --target or --directory.
tc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/x86_64-linux-gnu/perl5/5.26 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /usr/share/perl5/Debconf/FrontEnd/Gnome.pm line 151.)
debconf: falling back to frontend: Dialog
Generating locales (this might take a while)...
  en_US.UTF-8... done
Generation complete.

 @@@ Cleaning up...


 Installing GRUB boot loader...


I am unable to boot the machine too. Could you take a look at the LFA distro?

http://lfa.exton.net/?page_id=11

It comes with refractainstaller and refractasnapshot already installed.
Mister Monday
 
Posts: 18
Joined: October 21st, 2018, 11:43 pm

Re: Create new live disk from inside current live disk

Postby fsmithred » October 23rd, 2018, 2:24 pm

You can generally ignore the gtk and yad errors. The sed errrors about missing files are completely safe. The debconf error just says that it can't run the graphical frontend, so it's falling back to the ncurses frontend (what you'd use in a terminal.) The only significant error is the grub-install.

Still downloading, but I found this on their sourceforge site, in the instructions:
2. Replace grub-efi-amd64 with grub-pc. I.e. run the command sudo apt install grub-pc

I think the problem is that the wrong grub is installed, and the grub-pc package is not available in the iso for the installer to find.

Download done. My suspicions are confirmed. Install grub-pc in the live session before you do the installation. When grub asks you where to put the bootloader, do not choose a drive, and let it finish without installing a bootloader. Then run refractainstaller, and that will ask you to where to put the bootloader, and then it will put the bootloader in the right place (the place that's appropriate for the installed system rather than for the live system.)
fsmithred
 
Posts: 341
Joined: February 11th, 2011, 4:14 am

Re: Create new live disk from inside current live disk

Postby Mister Monday » October 23rd, 2018, 10:52 pm

How do you recommend I create the partitions? (Just to be sure...)
Mister Monday
 
Posts: 18
Joined: October 21st, 2018, 11:43 pm

Re: Create new live disk from inside current live disk

Postby fsmithred » October 24th, 2018, 11:49 am

I usually use gparted to partition a drive. You can either do that before you run the installer or run the installer first, and it will ask if you want to run gparted.
fsmithred
 
Posts: 341
Joined: February 11th, 2011, 4:14 am

Re: Create new live disk from inside current live disk

Postby Mister Monday » October 24th, 2018, 11:18 pm

No, I mean what type of partitions do you create, and how many?
Mister Monday
 
Posts: 18
Joined: October 21st, 2018, 11:43 pm

Next

Return to Refracta

Who is online

Users browsing this forum: No registered users and 1 guest

cron

x