Sebelumnya saya dijelaskan cara menginstal Ubuntu lewat jaringan dengan menggunakan CD instalasi netboot atau gambar USB. This tutorial takes it a step further and allows you to boot your machine from the network environment and select from a list of what you would like to install. Tutorial ini mengambil langkah lebih jauh dan memungkinkan Anda untuk boot komputer anda dari lingkungan jaringan dan memilih dari daftar apa yang Anda ingin menginstal. This comes to the same end result as the previous tutorial (an installed machine without having to burn a CD), but doesn't require the boot CD or USB image. Ini datang ke hasil akhir yang sama dengan tutorial sebelumnya (mesin dipasang tanpa harus membakar CD), tetapi tidak memerlukan CD boot atau gambar USB. This will take more work and should also be considered intermediate to advanced. Ini akan memakan lebih banyak pekerjaan dan juga harus dipertimbangkan pemula hingga mahir. Please read through the tutorial in its entirety before diving in, researching any aspects of the tutorial you're not familiar with prior to attempting these steps. Silahkan baca melalui tutorial secara keseluruhan sebelum diving di, meneliti segala aspek tutorial Anda tidak akrab dengan sebelum mencoba langkah-langkah ini.
Requirements Persyaratan
There are a few things that we'll need in order to set this up. Ada beberapa hal yang akan kami butuhkan untuk mengatur hal ini. These are outlined below: Ini adalah sebagai berikut:
- DHCP Server ( sudo aptitude install dhcp3-server ) DHCP Server (sudo apt-get install dhcp3-server )
- Ubuntu CD Image (alternate CD, not Desktop LiveCD) Ubuntu CD Image (CD alternatif, tidak Desktop LiveCD)
- TFTP Server ( sudo aptitude install tftpd ) TFTP Server (sudo apt-get install tftpd )
- Apache ( sudo aptitude install apache2 ) Apache (sudo apt-get install apache2 )
The way that these services will be used, as a quick overview, is that the DHCP server will listen for and assign IP addresses for machines on the local network. Cara bahwa layanan ini akan digunakan, sebagai gambaran singkat, adalah bahwa server DHCP akan mendengarkan dan memberikan alamat IP untuk mesin pada jaringan lokal. The TFTP server will hand a small kernel and ramdisk image to the client as it boots from the network environment and the contents of the Ubuntu CD will be used to install, being shared over the web via the Apache server. Server TFTP akan tangan kernel kecil dan citra ramdisk untuk klien sebagai boot dari lingkungan jaringan dan isi dari CD Ubuntu akan digunakan untuk menginstal, yang dibagi atas web melalui server Apache. This is, again, an extension of the previous tutorial on network-based installations, this simply removes the need for a CD or USB image to boot the machine. Ini, sekali lagi, merupakan kelanjutan dari tutorial sebelumnya pada instalasi berbasis jaringan, ini hanya menghilangkan kebutuhan untuk gambar CD atau USB untuk boot mesin.
DHCP Setup Setup DHCP
First of all we'll install the DHCP server to initially hand out the IP addresses and point to the network boot images: Pertama-tama kita akan menginstal server DHCP untuk awalnya membagikan alamat IP dan menunjuk ke gambar jaringan boot:
sudo aptitude install dhcp3-server Now that we have the DHCP server installed there are a few small changes we need to make to the core configuration. Sekarang bahwa kita memiliki server DHCP ada beberapa perubahan kecil kita perlu membuat ke konfigurasi inti. Full detail on DHCP configuration is outside of the scope of this tutorial, but this should give you enough to achieve the goal of this tutorial. detail Penuh pada konfigurasi DHCP adalah di luar cakupan tutorial ini, tetapi ini akan memberikan Anda cukup untuk mencapai tujuan dari tutorial ini.
We'll first edit the DHCP configuration file, normally found in /etc/dhcp.conf: Pertama-tama kita akan mengedit file konfigurasi DHCP, biasanya ditemukan di / dhcp.conf etc /:
sudo vim /etc/dhcp.conf We'll add two lines into this file outlining the address of the TFTP server (probably the same machine) and the path to the pxelinux.0 file we want to hand off to the client machines. Kami akan menambahkan dua baris file ini menguraikan alamat dari server TFTP (mungkin mesin yang sama) dan path ke file pxelinux.0 kita ingin tangan ke mesin klien.
next-server 192.168.0.254 (the IP address of your DHCP/TFTP server)
filename "/tftpboot/pxelinux.0"; filename "/ tftpboot/pxelinux.0";
After we have made these changes we need to restart the DHCP server. Setelah kita telah membuat perubahan ini kita perlu me-restart server DHCP. We can do this using the command: Kita dapat melakukannya dengan menggunakan perintah:
sudo /etc/init.d/dhcpd restart Apache Setup Setup apache
We need to export the contents of the CD over the web so that the network based installer can find them for use with deb. Kita perlu untuk mengekspor isi CD melalui web sehingga jaringan berbasis installer dapat menemukan mereka untuk digunakan dengan deb. For this we'll install apache. Untuk ini kita akan menginstal apache. The base configuration should be enough for what we need here. Konfigurasi dasar seharusnya cukup untuk apa yang kita butuhkan di sini. Further details on configuring Apache are outside of the scope of this tutorial. Rincian lebih lanjut pada Apache mengkonfigurasi berada di luar cakupan tutorial ini.
sudo aptitude install apache2 CD Image Contents Isi CD Image
We'll need to extract the contents of the CD onto the DHCP/TFTP server so that we can access the packages and the installer kernel. Kita akan perlu untuk mengekstrak isi CD ke server / DHCP TFTP sehingga kita dapat mengakses paket dan kernel installer. We can locally mount and copy the CD contents using these commands: Kita lokal dapat me-mount dan menyalin isi CD menggunakan perintah:
sudo mkdir /var/www/html/ubuntu7.10 (or, if you're going to export multiple versions select something more unique) sudo mount -o loop CD.iso /mnt
sudo cp -a /mnt/* /var/www/html/ubuntu.710 sudo cp-a mnt / / * / var/www/html/ubuntu.710
PXELinux Setup Pxelinux Setup
Now that the DHCP server knows where the tftp server is and the path to the file that it should direct clients to we need to configure the PXE end of things, which is what allows us to boot a kernel over the network or select from a list of kernels to boot over the network. Sekarang server DHCP tahu di mana server tftp ini dan path ke file tersebut yang harus mengarahkan klien untuk kita perlu mengkonfigurasi akhir PXE hal, yang adalah apa yang memungkinkan kita untuk boot kernel melalui jaringan atau pilih dari daftar kernel untuk boot melalui jaringan.
Relative to the location of the pxelinux.0 file we can make a directory for the distribution/version that we want to boot. Sehubungan dengan lokasi file pxelinux.0 kita bisa membuat sebuah direktori untuk distribusi / versi yang kita ingin boot. For example we might want to install Ubuntu 7.10 so we'd create a folder U7.10, or ubuntu7.10–something to specify what version and variant this will hold. Sebagai contoh, kita mungkin ingin menginstal Ubuntu 7.10 jadi kita akan membuat U7.10 folder, atau ubuntu7.10-sesuatu untuk menentukan apa yang versi dan varian ini akan terus.
sudo mkdir /tftboot/ubuntu7.10 We then need to copy the network-based installer kernel and initrd.gz into the newly created folder: Kami kemudian perlu menyalin kernel installer berbasis jaringan dan initrd.gz ke folder yang baru dibuat:
sudo cp /var/www/html/ubuntu7.10/install/netboot/ubuntu-installer/i386/{linux, initrd.gz} /tftboot/ubuntu7.10/ We now need to build the file that will list what is available and how to select it from a (optional) list. Kita sekarang perlu membangun file yang akan daftar apa yang tersedia dan bagaimana untuk memilih dari daftar (opsional).
pxelinux.cfg/default pxelinux.cfg / default
We'll now move into the /tftpboot/pxelinux.cfg directory and edit the file “default”. Kita sekarang akan pindah ke tftpboot / / direktori pxelinux.cfg dan mengedit file "default". If this file doesn't exist that is OK, we'll create one. Jika file ini tidak ada yang OK, kita akan membuat satu.
sudo vim /tftpboot/pxelinux.cfg/default We'll now make a list of the boot options that might be available on this network booting system: Kita sekarang akan membuat daftar pilihan boot yang mungkin tersedia pada jaringan sistem booting:
default 0
prompt 1 prompt 1
display msgs/boot.msg Pesan tampilan / boot.msg
# begin list of available boot options # Mulai daftar opsi boot yang tersedia
label ubuntu7.10 label ubuntu7.10
kernel ubuntu7.10/linux kernel ubuntu7.10/linux
append initrd=ubuntu7.10/initrd.gz append initrd = ubuntu7.10/initrd.gz
This file basically outlines that a list will be presented to the user booting over the network, which we'll create in the next step, and defines what will be loaded for each menu item. File ini pada dasarnya menjelaskan bahwa daftar akan disajikan kepada pengguna boot melalui jaringan, yang akan kita buat pada langkah berikutnya, dan menetapkan apa yang akan dimuat untuk setiap item menu.
pxelinux.cfg/msgs/boot.msg pxelinux.cfg / Pesan / boot.msg
We'll now create a file that will give a display of the different boot options available. Sekarang kita akan menciptakan sebuah file yang akan memberikan tampilan pilihan boot yang tersedia. Your setup may only have one option outlined for installation, others might have three, four, five–a dozen different versions and variations available to install. setup Anda hanya dapat memiliki satu pilihan diuraikan untuk instalasi, orang lain mungkin memiliki tiga, empat, lima versi yang berbeda-selusin dan variasi yang tersedia untuk menginstal. We'll create a list here outlining what is available and what option to enter to select the option. Kami akan membuat daftar di sini menguraikan apa yang tersedia dan apa opsi untuk masuk untuk memilih pilihan.
This file can be something as simple as: File ini dapat menjadi sesuatu yang sederhana seperti:
ubuntu7.10 - Select this to install Ubuntu 7.10
kubuntu7.10 - Select this to install Kubuntu 7.10 kubuntu7.10 - Pilih untuk menginstal Kubuntu 7,10
ubuntu7.04 - Select this to install Ubuntu 7.04 ubuntu7.04 - Pilih untuk menginstal Ubuntu 7.04
kubuntu7.04 - Select this to install Kubuntu 7.10 kubuntu7.04 - Pilih untuk menginstal Kubuntu 7,10
…etc. ... Dll Creating a list such as this after having repeated the above steps for each version and variant you want to make available and you should be ready to go. Membuat daftar seperti ini setelah mengulangi langkah di atas untuk setiap versi dan varian Anda ingin membuat tersedia dan Anda harus siap untuk pergi. One thing to note is that the boot option entered at the list prompt should match the label defined in the pxelinux.cfg/default file. Satu hal yang perlu diperhatikan adalah bahwa opsi boot masuk di daftar prompt harus sesuai dengan label yang ditentukan pada file / pxelinux.cfg default.
Starting The Installer Mulai Installer The
You should now be ready to install your machine by booting and instructing your machine to boot from the network. Anda sekarang harus siap untuk menginstal komputer Anda dengan boot dan memerintahkan mesin anda untuk boot dari jaringan. If you have trouble booting to either of those devices you might check your BIOS settings to see that one of them takes priority over the main hard drive. Jika Anda memiliki kesulitan booting ke salah satu dari mereka perangkat Anda mungkin cek pengaturan BIOS untuk melihat bahwa salah satu dari mereka mengambil prioritas di atas hard drive utama.
You'll be presented with a very basic menu when the netboot installer loads. Anda akan disajikan dengan menu yang sangat dasar ketika beban netboot installer tersebut.
To install only the base system type 'server', then ENTER.
For the default installation, press ENTER. Untuk instalasi default, tekan ENTER.
The default installation is suitable for most desktop or laptop systems. Instalasi standar adalah cocok untuk desktop yang paling atau sistem laptop.
Navigate through the installer as normal but watch for the step entitled: Navigasi melalui installer seperti biasa namun hati-hati langkah yang berjudul:
Choose a mirror of the Ubuntu archive At this step we will tell the installer to use a custom repository, in this case being the locally shared CD contents we set up previously. Pada langkah ini kita akan memberitahu installer menggunakan repositori kustom, dalam hal ini menjadi isi CD lokal bersama kami mendirikan sebelumnya.
Instead of selecting your country in this step go up to the first option listed: (pg-up to the top) Alih-alih memilih negara Anda dalam langkah ini pergi ke opsi pertama terdaftar: (pg-up ke atas)
enter information manually I don't think the option of entering custom information is very intuitive so I missed this the first few times through. Saya tidak berpikir pilihan untuk memasukkan informasi adat sangat intuitif sehingga saya merindukan ini beberapa kali lewat. Watch for this step. If you are given a prompt offering us.archive.ubuntu.com or CC.archive.ubuntu.com you've gone too far ! Perhatikan langkah ini. Jika anda diberi us.archive.ubuntu.com menawarkan prompt atau CC.archive.ubuntu.com Anda sudah terlalu jauh!
The next step will prompt you for the hostname or IP address of the server you will be installing from. Langkah berikutnya akan meminta Anda untuk hostname atau alamat IP dari server Anda akan menginstal dari. This is the IP address of the server you copied the CD contents and installed Apache to. Ini adalah alamat IP dari server Anda menyalin isi CD dan diinstal Apache untuk.
After the hostname or IP is entered the installer will prompt you for the path to the publicly shared contents. Setelah nama host atau IP yang dimasukkan installer akan meminta Anda untuk path ke publik isi bersama. If you closely followed these steps the default entry of /ubuntu/ should work. Jika Anda diikuti langkah-langkah ini entri default / ubuntu / harus bekerja. If you copied your CD contents into a folder other than /ubuntu/ you'll need to update this accordingly. Jika Anda menyalin isi CD ke folder selain / ubuntu / Anda harus update ini sesuai.
At this point navigate through the installer as normal and enjoy what should be faster installation speeds as network-based is usually faster than CD-based. Pada titik ini menavigasi melalui installer seperti biasa dan menikmati apa yang harus kecepatan instalasi cepat sebagai berbasis jaringan biasanya lebih cepat daripada berbasis CD.
As I mentioned before. Seperti yang saya sebutkan sebelumnya. This should be considered more technical in nature than many of my previous tutorials. Ini harus dianggap lebih teknis di alam daripada banyak tutorial saya sebelumnya. Best of luck, and enjoy network based booting and installation! Semoga sukses, dan menikmati jaringan berbasis boot dan instalasi!


Tidak ada komentar:
Posting Komentar