Building a Linux distribution is a dream for each free open source software. This is a very difficult thing. People who can do a Linux distribution are also a phoenix roller. They can do a Linux distribution. Extremely glorious things. However, it is advocated to play its own potential, advocating yourself to practice the spirit of the spirit of the world, will not deliberately dress up all the things that everyone expensive from the world, he will continue to reform its own development Mechanism, let everyone gradually participate in their own development, which also promotes its own development. In short, now, doing a Linux distribution is not difficult things. I do a Linux distribution base problem I want to be a Linux distribution, you should first consider the question: 1 Why do you want a Linux distribution? 2 Is going to make changes from the other Linux distribution? 3 Do What is the key and difficulty of your own Linux distribution? 4 Select which existing Linux release starts your work. Let's see the first question first, why do you want a Linux distribution? There are a lot of answers to this question, more common one is what I want to do, there is no reason, certain To say, I borrowed a fashionable words: Just for fun !, this is a good reason. Then an important reason is: I need a Linux distribution version that meets my own special needs, such as: I I am learning Perl programming, I need a small, keep up with my Perl compile system, other things can be, then I need to make a Linux distribution that supports USB launch, only basic system plus editor plus Perl, I You can carry it with you, as long as you have a computer, I can start my study at any time. As for why I want to be a Linux distribution, the reason is very simple: I am a teacher! I think it is a teacher who meets the law, based on education related software. The Linux distribution is necessary, then specific, I am a geographic teacher, now the new curriculum standard is advised to learn about GIS knowledge, whether it is a compulsory module or an elective module. I don't want to us Geographic educators talk about GIS education, such as Arcinfo and MapInfo, as if they are uncomfortable, even domestic academic research institutions are not willing to buy, they can pick it everywhere. In the world of free open source software There is an extremely rich 3s (GIS, GPS, RS) geographic software. For GIS software, there are hundreds of hundreds of hundreds of more, famous, such as Grass QGIS, etc., although these free software is more than Commercial software, but sufficient to meet the general GIS teaching of basic GIS basic concepts. And these software also have some of their own advantages and strengths. Taking into account our current school computer is running Window, I just want To make your own, in the form of CD, it is a satisfactory Linux release with GIS software, performance and running speed. (Note: Similar systems have multiple people, including UNESCO FREEDUC of the text organization contains QGIS,
However, there is no support for Chinese) I have to be a Linux distribution, the third reason is that it is the name, some people do a release to make money and profit, which does not conflict with free software and GPL copyright. RedHat has brought new fantasies to many young people, and we also expect themselves to be able to be the next generation of Bill Gates. Some people have done their own releases just free download, the people used He is more and more happy, he only harvested his own name and praise for his own technology. In short, there are many reasons to build a company's Linux distribution, especially the majority of teachers working in the first line of education! 2 How to start doing your own Linux distribution and then we have to solve the second question, I do a Linux distribution is based on zero or in the LINUX distribution of others, and use your own willingness. Modify? In fact, what we said is relatively than the beginning. Which zero you start? Is it from yourself? Start with your own, configure an existing Linux kernel? I think we are impossible From the real zero, it is absolutely impossible to work with a person. We should start your own work on the basis of the work of the former people. In order to make your own Linux release, this is this The inheritance of the former person can be divided into such a situation: a is only based on the existing Linux kernel and other source code to do its own Linux distribution, which is based on LFS (Linux from scratch) to make its own Linux distribution. Because LFS is based on the source code, build its own Linux distribution from zero, so this method is used to make your own distribution to make the producer deeply understand the relationship between various software in Linux, in-depth understanding Some of the running mechanisms within Linux. But this way is long, the difficulty is relatively large, suitable for people who like planing roots. LFS-based Linux distribution seems to be a personal play, rarely works. This is based on the existing other Linux distributions. This is the case in the existing famous Linux release, picking your own Linux distribution and tailoring, adding, processing, and Then make your own Linux distribution. This way is simple and fast, suitable for the general user or is eager to make a finished product. The Linux distribution version produced in this way is like the number of sands of the river. Whether there will be one or two OS overlord that become the next generation, it is difficult to say. In order to quickly and easily achieve the purpose of making your own Linux distribution, we choose to transform on the existing Linux distribution to build your own release. So, which release should we use as our starting point? Before answering this question, let's solve the third problem. 3 Do a key and difficulty of doing your own Linux distribution? Do you have a key and difficult to do your own Linux distribution? At the beginning, entry may feel that it is difficult to launch a Linux system, which is not. The key I want to customize a Linux distribution is to solve the relationship between the various packages in the release. The free open source software uses the former source code, but also opens its own source code for the future generation, so free open source software always uses a variety of different software packs, this aspect gives great convenience, On the other hand, the relationship between the respective packages is complicated, and the integration of the software is often brought about by catastrophic consequences. For example, you plan to install software A, B and C in your release, while A operation requires the operation of B1 and B2 and C1, the operation needs to depend on B1 and B2, and C1 in order to install Software A, B, C, you must install A1, A2, A3, B1, B2, C1, after installation, found that the operation of A1 should use the library A11 and A12, C1 to run the library C11, waiting for you The force of Nine Bull Erhu found the source code of A11, A12 and C11 to compile, after installation, and found that A12 and C11 conflict with each other! You cry! So, I think it is the key to doing your own Linux distribution to correctly solve the dependencies between various packages.
4 Which existing Linux release begins to start your own work So which existing Linux release starts your own work? I think this will be a radish and vegetables, you can choose FC, you can also choose Slackware, but from the narrative above, it is obvious that I tend to choose Debian to develop customized issues. I think Debian's largest strength is its advanced, unique package management method, throughout the world's hard work and selfless work, well solved the dependence, conflict between all free open source software, etc. Relationship, enabling Debian support to install software in a manner in all operating systems, and also brings great convenience to DEBIAN development customized issues. Of course, some people may say that freebsd's software package is also very convenient and powerful, why not choose FreeBSD? This is because FreeBSD does not comply with GPL copyright, and its own FreeBSD license does not allow freeBSD-based distribution, so we only hope to see. Now I plan to customize my distribution based on Debian development, can you have a easier development? Considering my actual development needs, I only need to develop a demo system for teaching, I'd better make a LiveCD, which is the Linux custom system running on the CD, I intend to develop my knowledge based on the Knoppix or Morphix system. Custom system. Knoppix is a famous LiveCD system based on Debian developed. It has used some unique technologies that make it easier to develop over it, while Morphix is a modular LiveCD based on Knoppix development, from it Name, Morphix means deformation linux, it is born for custom personalization Linux! It advances the simpleness of custom Linux system and advances! But people still don't satisfy, some people are still developing transaster, develop TROM, etc., their goal is: under a graphical interface, point a few mice, the new custom release is produced! Don't come how long this day is going! This is an exciting news or a horrible news? At least I feel very nervous, I have to write this article soon, cars this article before the software, otherwise, just click on the mouse to create your own release, who is still coming What about my article? Debian -> Knoppix-> Morphix, based on the custom development of these three releases is more and more easy, but in my actual use, Morphix and easier TROM tools are often errors, while Knoppix development It is very stable, so I decided to develop a Chinese version of the GIS distribution based on Knoppix. Two specific development processes. The following is my specific development process, of course, written on the basis of the predecessor, but according to my own understanding, and make some changes in the new Knoppix version. The article is completely written on a Windows machine, so there are some details on a detail. 1 Prepare: I want to prepare for the first step is to look at whether your computer is so powerful! It is best to Memory, two g exchange partitions, ten g above hard drive! Of course, 256M memory 1G exchange partition can work, slower.
The hard disk space is as big as possible, I started to customize the big hand when I started, and I didn't get enough space for 8G hard drive! Of course, the process I write below is to carefully use the hard disk space, delete and uninstall the space, and there should be 3-4G hard disk empty. Then you have to install the relevant software of the CLOOP. Introducing CLOOP I want to be the biggest feature of Knoppix, I am using the debian system, then: # apt-get install cloop-utils is OK. Then then get the latest version of Knoppix, the current latest version is 3.7, but it seems that it is not officially announced, we use the 3.6 version, then assume that I have downloaded Knoppix36.iso. I don't influence the custom work behind it, I will not be busy. Then establish a work directory, I created a / wen directory in the working directory, which established two subdirectors of OLD and New, obviously the former is the original content of Knoppix36.iso, and the latter will store it after I have been transformed. Content. 2 Start custom transformation. First to mount Knoppix36.iso, this roll-up image file: #mount -o looppix36.iso / mnt / cdrom obviously I downloaded Knoppix in the root directory and I mount it in / mnt / Under CDROM, these two parameters can be modified according to the actual situation. Now you can go to / mnt / cdrom to see what is something in Knoppix, there is a boot directory, obviously this is also related, you have to modify the startup screen, etc., you will be able to modify this. We will not pay attention to it now. There is also a knoppix directory, which have some files below, one of which Knoppix files have reached nearly 700M! This is the main body we have to modify! Let's copy all the contents under / mnt / cdrom to / Wen / New, because we need to modify only Knoppix file, wait for us to delete, but now use: #CD / mnt / cdrom # Cp -r * / wen / new / # umount / mnt / cdrom You can now delete the Knoppix36.iso file to save the hard disk space. Below we have to operate on / wen / new / knoppix / knoppix file, this file is 700m, or uses CLOOP compression, so we must first decompressed: #CD / wen / new / knoppix / # extract_compressed_fs knoplepix> TMP. ISO will decompress the result in TMP.ISO in the root directory.
Note that this decompression process is extremely long. I usually boil water, soaked in instant noodles, eat slowly, clean the desktop, is it completed? NO! Early! Let's go out, wait for you to consume almost, unzip it, look at the root directory, scare you, tmp.iso is nearly 2G! Now you must delete files / wen / new / knoppix / knoppix Because we have to transform TMP.iso to generate new Knoppix files, remember! Mount TMP.iso and copy all content to / wen / old / knoppix, you should be quite familiar with: #mount -o loop -t iso9660 /tmp.iso / mnt / cdrom # mkdir / wen / old / knoppix #CD / MNT / CDROM # cp -r * / wen / old / knoppix #umount / mnt / cdrom In order to save the hard disk, you can now delete /tmp.iso. Then I will enter the specific transformation work phase, which is mainly using chroot commands and the installation of the APT-GET, uninstalling software, and what you need to pay attention to: In order to use the network, you need to hang in the Chroot environment. To load Proc, you should also pay attention to the CHROOT environment to correctly parse domain names. I am solved this after this problem, open a console window, execute: #cp /etc/apt/sources.list /wen/old/knoppix/etc/apt/sources.list#cp /etc/resolv.conf / The premise of this to Wen / Old / knoppix / etc / resolv.conf is that your network is smooth before you don't have Chroot. There is also a solution is that I will first ping the APT source in my own Sources.List table to get IP, directly written to the Sources.list file after Chroot to save DNS resolution. #Chroot / Wen / Old / Knoppix / $ Mount -t Proc / Proc Proc Now you enter the old Knoppix3.6, you can use it as a normal debian system to treat us using common commands To transform the old system: $ APT-GET Remove OpenOffice.org $ APT-GET Remove KDE-I18N- {ES, DE, FR, IT, NL} (first delete a few big packages I don't used, you can Save 300-400M space. You can use the command dpkg-query -l to view which packages installed, then delete according to your own will) $ APT-GET Install Grass $ Apt-Get Install QGIS (installed two I need Software) Simple renovation work, now you can quit: $ APT-GET CLEAN (Delete a newly downloaded package, lest in the new release) $ updatedb (Update Software Database) Update-Menus $ umount proc (remember!) Use Ctrl-D to exit the Chroot environment, and finally we have to do two things: First, recover the rebuilt / Wen / Old / Knoppix to Knoppix files And write / wen / new / knoppix, and the other is / wen / new / make a disc image file. Both steps use the makeisofs command, and if there is nothing in the system, you should install themselves.