السبت، 7 ديسمبر 2013

برنامج لعمل نسخة احتياطية من توزيعة اللينكس المثبته

الصورة التي تم إنشاؤها باستخدام Relinux يمكن تحت أي ظرف من الظروف أن تكون أكبر من 4 غيغابايت، والذي هو السبب في أنك سوف تحتاج إلى استبعاد المجلد الرئيسي وكذلك المجلدات الأخرى المحتملة كبيرة جدا لتشمل. علاوة على ذلك، في وقت كتابة هذا المقال Relinux متوافق فقط مع GRUB2، يحتاج إلى عرض X11 ويثبت metacity.

شرح التنصيب
قم بتحميل نسخة البرنامج من هذا الرابط

https://launchpad.net/relinux


يحتوي ملف الأرشيف مجلدين ودليل التركيب، ويجب دمج المجلدين مع الخ الأصلي والمجلدات البيرة. تغيير في الدليل الذي تفكيك المجلدين ل، في بلدي على سبيل المثال هو / الوطن / ctest / مجلد التحميل:

cd /home/ctest/Downloads
Now copy the downloaded folders to the original ones:
sudo cp -R usr /
sudo cp -R etc /

لانشاء توزيعة خاصة بك علي سي دي او ديفيدي  يجب تثبيت البرنامج علي النظام الحالي وذلك من خلال فتح Synaptic Package Manager
ثم ابحث عن الحزم التي ترغب فى تثبيتها ثم اختار الحزمة التي تريد تثبيتها ثم حدد اختيار تركيب .



و اذا احتجت الي تثبيت حزم اخري يمكنك فعل ذلك 
ويتوقف ذلك علي احتياجك

 

 بعد اختيار الحزم التي ترغب فى تثبيتها اضغط علي تطبيق او apply 
 

 



 وبعد تنزيل الحزم و تثبيتها :




 




4 Use Relinux

Relinux uses a config file for every command which you better edit before you use the program for the first time. Leave the original config as backup and create a new one in a specified location (I'll do it in my personal folder):
cd /home/ctest
cp /etc/relinux/relinux.conf ./relinux.conf
Next direct Relinux to the new configuration file:
sed -i 's:EXCLUDES="\(.*\)":EXCLUDES="\1 '`readlink -f ./relinux.conf`'":g' ./relinux.conf
It is highly recommended to have a look at all the options in the config file and adjust them to your liking. If you do not exclude enough files to bring the squashed file system to a maximum of 4 GB, Relinux will not create an image out of it. Additionally there are other helpful options like the choice of a boot splash screen or the naming of the actual image.
Relinux' actual control is only possible through the command line. It generally has the same options as Remastersys at the moment except for the lack of an explicit backup command, which however can be accomplished by not excluding the home folder:
  • sudo relinux clean [configfile] - Cleans the working directory of unimportant process stuff
  • sudo relinux fullclean [configfile] - Cleans the working directory completely, including the .iso image, the checksum and all other files
  • sudo relinux squashfs [configfile] - Creates the squashed file system to build the iso-image out of. This is the necessary step to take before actually creating an iso-image. This can also be used to retroactively add files to the file system before creating the images
  • sudo relinux onlyiso [configfile] - Creates the actual iso-image which can be used in a virtual machine or burned on a CD to boot your custom system from (before choosing this option a file system must have been created using squashfs)
  • sudo relinux iso [configfile] - Creates the squashed file system and the .iso image in one command
Since you most likely want to use the image you create for burning it on a DVD you should pay attention to the summed size of software and files you add to it.
Every file created with Relinux will be placed in its temporary directory, which by default is /home/relinux. That counts for filesystems as well as for images (e.g. custom.iso by default). Be sure you move your image to some other place since this temporary folder will be emptied on the use of fullclean

5 Add Files to a Non-Backup Filesystem Without home-folder

If you have a home folder that is to large to put it on a DVD but still have files that need to be on the image, there are two ways you can put them on it; one has to be dealt with before you create the file system and one that can also be done after it has been created.

5.1 /etc/Skel Folder

To add files to your non-backup image before you create the file system, just put them into the /etc/Skel folder to let the files appear in your home folder on the image afterwards. The /etc/Skel folder is responsible for populating the home folder on every installation and every adding of a new user.

5.2 Squashfs-tools

Squashfs-tools is package that allows you to build and uncompress but also to add files to squashed filesystems, which are also used to build the filesystem on Remastersys and Relinux. They can be used to append files to already created filesystems. Install them by entering the following into a terminal:
sudo apt-get install squashfs-tools
The squashfs-tools offer two commands to use, one to create filesystems or add files to existing and one to uncompress them. The first one is
mksquashfs
and its basic structure is the command followed by one or more source files or folders and the path to the squashed file (e.g. mksquashfs /home/ctest/Desktop/bla /home/ctest/Desktop/ultimate.squashfs). The last folder in the path of the source file will be the root of the squash filesystem unless you specify otherwise with an option, meaning it will not be directly displayed itself. The same command is also used to append files to existing squash filesystems, which is what we basically want. To do so, just pick the existing filesystem as the filesystem to create and the files to append in the input files' path. Unfortunately, it is not possible to merge the two filesystems, which is why we circumvent this problem by creating a folder called extrafiles (could be any name) in any folder and choose this upper folder as the one to add to the system (it will become the root folder and the folder inside, the one we want, will be displayed along the files in the filesystem's root folder).  Add the files you want on your DVD to the extrafiles folder. Following would be a possible way to add files to the filesystem:
mksquashfs /home/ctest/Desktop/bla /home/remastersys/remastersys/ISOTMP/casper/filesystem.squashfs
In this example the folder bla is the one containing the extrafiles folder. See the man page for further switches and options.
To uncompress a squash filesystem, use following command:
unsquashfs
The most common way to use this command should be combined with the destination switch. Make sure to choose an unexisting directory as destination since it will give you an error otherwise.
unsquashfs -d /home/ctest/Desktop/unexistingdirectory /home/remastersys/remastersys/ISOTMP/casper/filesystem.squashfs













ليست هناك تعليقات:

إرسال تعليق