Strona główna / Społeczność / Blog / Diskless computer using ReadyNAS and Gargoyle using PXE and iSCSI

Diskless computer using ReadyNAS and Gargoyle using PXE and iSCSI

Test iSCSI

The LUN is created on ReadyNAS (192.168.1.28) in group CentOS-PXE, target iqn.1994-11.com.netgear:nas:08303042:centos-pxe.

All commands are run from my laptop (T530), but it can be any Linux:

We are interested in the second one:

Now we can list disks:

as you can see, the new volume is linked as /dev/sdd usualy it will be sda or sdb.

Now we can "unmount" as it won't be needed.

Configure network install

You will need: tftp, dhcp and ftp server and CentOS installation ISO file. Unpack ISO content to ftp server to some (CentOS7-1908-minimal in my case) directory.

Add entry in /data/tftpboot/pxelinux.cfg/default file:

You have to create networkboot/CentOS7-1908 directory in your tftp root directory. In my (ReadtNAS) case /data/tftpboot/, so full path is /data/tftpboot/networkboot/CentOS7-1908.

Files vmlinux and initrd.img are from ISO from isolinux directory. Because my ftp root is /data/pub/ I typed:

Now you should be able to run CentOS installation from network.

Installation

Boot computer from network (PXE BOOT) choose Install CentOS 7 1908 from pxe menu.

Run standard installator. As Installation destination add disk in Specialized & Network Disks. In Add iSCSI Target... enter 192.168.1.28 as Target IP Address and click Start discovery. Choose desired node (if you have more than one you should know what do do) and click Log in and (after a while) OK.

Now you should have some drive (sda, sdb or similar) - select it and click Done. Probably there will be Error checking storage configuration message - click Full disk summary and boot loader ... and unselect your disk as a boot device by clicking Do not install boot loader. Click Done.

Now be sure the name of your network card. In my case it is enp0s3.

You can add more installation repositories, but it is not necessary now.

Click Begin installation. It will take a while - in the meantime you can set root password.

When installation is complete switch to console (Ctrl-Alt-F2) and copy vmlinuz and initramfs files to your tftp server:

and place this two files in tftp directory:

as you can see I use the same directory as in network install, but it is no necessary.

Now it is time to final PXE configuration on tftp server prepare entry similar to:

You can check "magic numbers" on freshly installed system by:

Now you can click Reboot.

After some time you have network booted system.

Configure iPXE

Instead of PXE I should be possible to use iPXE. For now I can only boot iPXE - then I return to PXE because it works.

Download binary (on ReadyNAS - TFTP server) and move to tftp directory:

Not to have to flash network card ROM I use PXE chainloading. Change (on Gargoyle - DHCP server):

It should be more convenient way to upgrade kernel in future.

For now, in menu.ipxe I've entry:

Sources:

Diskless iSCSI boot with PXE HOWTO

How to chainload ipxe using dnsmasq?

Centos 7 Diskless Environment – PXE booting OpenStack compute nodes from iSCSI SAN

Komentarze

Log in or create a user account to comment.

Ten kto umie pisze kod, ten kto nie umie pisze książki..., albo blog.

Pon Wt Śr Czw Pt So N
            1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30