What I’m looking for is to make a snapshot of my current live Manjaro Xfce system into a bootable .ISO that I can install on other machines using the Calamares installer and have all apps, settings and accounts on the new machine.
I have read the posts about the developer of eggs seeking for help to make it compatible with Manjaro.
MX Linux has a GUI app called Snapshot for this.
Has it not crossed your mind that cloning the disk will also achieve the end result? If you really must have an ISO file; the cloned image could be burned to a blank BD or DVD disk (whichever has sufficient space); or it could be kept on a removable USB disk for whenever it might be needed.
In this case there would be no installing – you would simply use (for example, CloneZilla) to restore the image to a new disk.
Perhaps you are overthinking what you need.
Here is a guide I created a while ago that shows how to clone disk to disk directly using CloneZilla.
You could save the disk to an image instead, simply by using different options in CloneZilla.
What I’m looking for is something simple in the likes of MX Linux Snapshot that
works great but for Manjaro.
This penguin-egss gives a lot of errors.
Can’t build the iso of my current system.
On MX it just works with no BS. I put the .ISO on my Ventoy pen and boots from it. And if I want to install on multiple PCs I can.
You did not specify that these other machines might have significantly different hardware.
Even so, the solution to that scenario can be as simple as installing both amd-ucode and intel-ucode before cloning.
If intending to use a drastically different dGPU, logic would dictate tending to that after cloning, in any case. I imagine Nvidia might be troublesome no matter the method used.
The end result could also be achieved by saving the content of /home to a USB, using the Manjaro Installer normally to install a new system, and restoring /home content when done.
A script could be created to reinstall your favourite packages. If you search the forum more than superficially, you will find tutorials and guides on how to do this.
In as far as I can tell, making a snapshot of your current system would be subject to the same limitations as would cloning to significantly different hardware; though those limitations are not insurmountable.
However, I can see how penguin-eggs might appeal to you:
There is a lot of information on the GitHub page, though it seems more like an extended overview than anything immediately useful. That said, it contains enough detail to begin formulating a strategy:
Is there a way to find out what this penguin-eggs installs in the system?
Like I said I follow the instructions and a ton of stuff gets installed and in the end instead of the ISO e get errors.
Those will be removed when you remove penguins-eggs but ONLY if they are not required by system
Recreating the running system is fairly easy - see my previous link to the mini guide for buildiso.
EDIT:
A turnkey solution is difficult to create as the selection and decision process (what to include and what to exclude) will vary across use cases.
I have created a mockup script to illustrate what could happen.
This is an untested mockup - not a turnkey solution - perhaps it works - perhaps not - it comes without any warranties of any kind.
The mock does not take into consideration any custom packages which may be build on the system - because doing so would imply building custom packages as part of the process.
#!/usr/bin/env bash
#
# This script is a mock written for the purpose of illustrating the process
# of converting a running system into an installable ISO
# using Manjaro Linux ISO tools.
#
# It is likely to contain errors - be mindful and observant
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the Affero GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
#
# @linux-aarhus - root.nix.dk
#
# don't run as root
# we elevate privileges using sudo
if [[ $EUID -eq 0 ]]; then
echo "No, cannot be running as root, bailing out!"
exit 1
fi
if ! [[ $(lsb_release -i) =~ 'ManjaroLinux' ]]; then
echo "This script is for Manjaro Linux... bailing out!"
exit 1
fi
ISO_PROFILES="cinnamon gnome i3 kde xfce"
ACTIVE_DESKTOP=$(echo $XDG_SESSION_DESKTOP | tr '[:upper:]' '[:lower:]')
if ! [[ "$ISO_PROFILES" =~ "$ACTIVE_DESKTOP" ]]; then
# DO NOT CONTINUE WITHOUT A DESKTOP
echo "No Desktop detected! Don't know where to begin."
exit 1
fi
CUSTOM_BUILD="/custom-root"
ISO_PROFILES_DIR="$CUSTOM_BUILD/iso-profiles"
USER_PROFILES="$ISO_PROFILES_DIR/$USER"
BUILD_PROFILE="$USER-$ACTIVE_DESKTOP"
DEPS="git base-devel manjaro-tools-iso-git"
echo "root : $CUSTOM_BUILD"
echo "iso-profiles : $ISO_PROFILES_DIR"
echo "custom profiles : $USER_PROFILES"
echo "build profile : $BUILD_PROFILE"
echo "dependencies : $DEPS"
# #########################################################
# clean up system for orphans prior to creating a native package list
echo ""
echo 'orphans=$(pacman -Qqtd)'
orphans=$(pacman -Qqtd)
if [[ -z orphans ]]; then
echo ""
echo 'sudo pacman -Rns $(pacman -Qqtd) --noconfirm'
sudo pacman -Rns $(pacman -Qqtd)
fi
# sync system if any tool is needed
echo ""
echo 'sudo pacman -S $DEPS --needed'
sudo pacman -S $DEPS --needed
# #########################################################
# BUILD FOLDER AND PERMISSIONS (EARLY CHECK - INHERIT PERMISSIONS)
echo ""
if ! [[ -d "$CUSTOM_BUILD" ]]; then
# Create primary folder
echo ""
echo 'sudo mkdir -p "$CUSTOM_BUILD"'
sudo mkdir -p "$CUSTOM_BUILD"
fi
if ! [[ -w "$CUSTOM_BUILD" ]]; then
# set permissions on primary folder
echo ""
echo 'sudo chown -R $USER:$USER "$CUSTOM_BUILD"'
sudo chown -R $USER:$USER "$CUSTOM_BUILD"
fi
# #########################################################
# check if profiles repo exist
echo ""
if ! [[ -d "$ISO_PROFILES_DIR/.git" ]]; then
# clone iso-profiles
echo ""
echo 'git clone https://gitlab.manjaro.org/profiles-and-settings/iso-profiles.git "$ISO_PROFILES_DIR"'
git clone https://gitlab.manjaro.org/profiles-and-settings/iso-profiles.git "$ISO_PROFILES_DIR"
fi
if ! [[ -d "$USER_PROFILES" ]]; then
# create custom profile folder
echo ""
echo 'mkdir -p "$USER_PROFILES"'
mkdir -p "$USER_PROFILES"
fi
# #########################################################
# copy the current active desktop to a custom profile
echo ""
if [[ $ACTIVE_DESKTOP == "i3" || $ACTIVE_DESKTOP == "cinnamon" ]]; then
# create a custom community profile
echo ""
echo 'cp -R "$ISO_PROFILES_DIR/community/$ACTIVE_DESKTOP" "$USER_PROFILES/$BUILD_PROFILE"'
cp -R "$ISO_PROFILES_DIR/community/$ACTIVE_DESKTOP" "$USER_PROFILES/$BUILD_PROFILE"
else
# create a custom manjaro profile
echo ""
echo 'cp -R "$ISO_PROFILES_DIR/manjaro/$ACTIVE_DESKTOP" "$USER_PROFILES/$BUILD_PROFILE"'
cp -R "$ISO_PROFILES_DIR/manjaro/$ACTIVE_DESKTOP" "$USER_PROFILES/$BUILD_PROFILE"
fi
# #########################################################
# generate package lists from current system
echo ""
echo "Generate package list"
echo 'pacman -Qqen > "$CUSTOM_BUILD/system-packages.txt"'
pacman -Qqen > "$CUSTOM_BUILD/system-packages.txt"
echo ""
echo 'mv "$USER_PROFILES/$BUILD_PROFILE/Packages-Desktop" "$USER_PROFILES/$BUILD_PROFILE/Packages-Desktop.org"'
mv "$USER_PROFILES/$BUILD_PROFILE/Packages-Desktop" "$USER_PROFILES/$BUILD_PROFILE/Packages-Desktop.org"
echo ""
echo 'comm -23 <(sort "$CUSTOM_BUILD/system-packages.txt") <(sort /rootfs-pkgs.txt) > "$USER_PROFILES/$BUILD_PROFILE/Packages-Desktop"'
comm -23 <(sort "$CUSTOM_BUILD/system-packages.txt") <(sort /rootfs-pkgs.txt) > "$USER_PROFILES/$BUILD_PROFILE/Packages-Desktop"
# #########################################################
# copy the current user's home folder as default for the base system
echo ""
echo 'mkdir -p "$USER_PROFILES/$BUILD_PROFILE/desktop-overlay/etc/skel"'
mkdir -p "$USER_PROFILES/$BUILD_PROFILE/desktop-overlay/etc/skel"
echo ""
echo 'cp -R /home/$USER/.* "$USER_PROFILES/$BUILD_PROFILE/desktop-overlay/etc/skel"'
cp -R /home/$USER/.* "$USER_PROFILES/$BUILD_PROFILE/desktop-overlay/etc/skel"
# #########################################################
# build the ISO
echo ""
mkdir -p /home/$USER/.config/manjaro-tools
echo "run_dir=$ISO_PROFILES_DIR" > /home/$USER/.config/manjaro-tools/iso-profiles.conf
KERNEL=$(mhwd-kernel -li | grep 'Currently running' | sed 's/.*(\(.*\))/\1/')
BRANCH=$(pacman-mirrors -G)
echo ""
echo 'buildiso -p "$BUILD_PROFILE" -b "$BRANCH" -k "$KERNEL" -t "$CUSTOM_BUILD"'
buildiso -p "$BUILD_PROFILE" -b "$BRANCH" -k "$KERNEL" -t "$CUSTOM_BUILD"