PXE Booting SLES 12 SP1 install

Notice: Page may contain affiliate links for which we may earn a small commission through services like Amazon Affiliates or Skimlinks.

macrules34

Active Member
Mar 18, 2016
407
28
28
40
I have my server setup for PXE boot and then in the menu select "linux" to install the OS. How ever when I enter linux and hit enter I get an error "Could not find kernel image: linux". I have googled and tried a few things but nothing has worked so far.
 

marcoi

Well-Known Member
Apr 6, 2013
1,533
289
83
Gotha Florida
im going from memory and havent touched PXE in a while. But i recall needing DNS server or switch showing the PXE parameter that tells where the ftp server where the iso image lives. or something to that nature. Have you checked that both parts are working before trying the install?
 

marcoi

Well-Known Member
Apr 6, 2013
1,533
289
83
Gotha Florida
only suggestion i can provide, is recheck you followed the guide to the letter. IE you may have forgot a step or fat fingered something.
Then do basic testing of the pxe server.
Does it have an IP?
Can you ping the server you are trying to image?
is the firewall off or port open for ftp?
are the config files pointing to right iso?
etc.
 

macrules34

Active Member
Mar 18, 2016
407
28
28
40
Does it have an IP? Yes.
Can you ping the server you are trying to image? Yes.
is the firewall off or port open for ftp? Yes.
are the config files pointing to right iso? Yes.
 
Last edited:

macrules34

Active Member
Mar 18, 2016
407
28
28
40
When I try to connect to the tftp server I get:
'Timeout occurred Connection request failed." Client is a windows 7 machine, server is a Sles linux machine.
 
Last edited:

BLinux

cat lover server enthusiast
Jul 7, 2016
2,672
1,081
113
artofserver.com
I have my server setup for PXE boot and then in the menu select "linux" to install the OS. How ever when I enter linux and hit enter I get an error "Could not find kernel image: linux". I have googled and tried a few things but nothing has worked so far.
you need to setup your DHCP server to do the PXE boot. that's how it's going to know where to find the boot loader.

with ISC DHCP, this is a sample config from my DHCP/PXE setup:

Code:
    pool {
        allow members of "virtual-machine-class-1";
        allow members of "virtual-machine-class-2";
        allow members of "virtual-machine-class-3";
        allow members of "real-machine-class-1";
        allow members of "real-machine-class-2";
        allow members of "real-machine-class-3";
        allow members of "real-machine-class-4";
        allow members of "real-machine-class-5";
        allow members of "real-machine-class-6";
        allow members of "real-machine-class-7";
        deny known-clients;
        range dynamic-bootp 192.168.0.112 192.168.0.126;
        next-server    pxeboot.domain.org;  # name of TFTP server
        filename    "pxelinux.0";    # name of bootloader program
}
i setup groups of machines that are allowed to PXE boot, while others are not. machines that are members of these groups can PXE boot, and get pointed to "next-server", and "filename" which is the boot loader (this is done over TFTP) You can then configure the boot loader to load any other kernel image.

as an example, here's my pxelinux setup default menu:

Code:
prompt 1
timeout 0
display pxelinux.cfg/boot.msg
F1 pxelinux.cfg/boot.msg
F2 pxelinux.cfg/f2-centos7-i.msg
F3 pxelinux.cfg/f3-centos7-k.msg
F4 pxelinux.cfg/f4-rhel7-i.msg
F5 pxelinux.cfg/f5-rhel7-k.msg
F6 pxelinux.cfg/f6-centos6-i.msg
F7 pxelinux.cfg/f7-centos6-k.msg
F8 pxelinux.cfg/f8-rhel6-i.msg
F9 pxelinux.cfg/f9-rhel6-k.msg
F10 pxelinux.cfg/f10-fedora-i.msg
F11 pxelinux.cfg/f11-special.msg
INCLUDE pxelinux.cfg/f2-centos7-i.cfg
INCLUDE pxelinux.cfg/f3-centos7-k.cfg
INCLUDE pxelinux.cfg/f4-rhel7-i.cfg
INCLUDE pxelinux.cfg/f5-rhel7-k.cfg
INCLUDE pxelinux.cfg/f6-centos6-i.cfg
INCLUDE pxelinux.cfg/f7-centos6-k.cfg
INCLUDE pxelinux.cfg/f8-rhel6-i.cfg
INCLUDE pxelinux.cfg/f9-rhel6-k.cfg
INCLUDE pxelinux.cfg/f10-fedora-i.cfg
INCLUDE pxelinux.cfg/f11-special.cfg
it points to a bunch of other config files that have specific settings for various OSes, kickstart profiles, or manual installs. The "-i" are interactive installs, while the "-k" are my kickstart profiles.

Here's one example of that:

Code:
#
# CentOS 7
#
label C-7-x86_64
  kernel pxelinux.cfg/iso/centos-7-x86_64/images/pxeboot/vmlinuz
  append initrd=pxelinux.cfg/iso/centos-7-x86_64/images/pxeboot/initrd.img repo=http://server.domain.com/distros/centos-7-x86_64/ noipv6 ip=dhcp ramdisk_size=9216
label C-7-x86_64-rescue
  kernel pxelinux.cfg/iso/centos-7-x86_64/images/pxeboot/vmlinuz
  append initrd=pxelinux.cfg/iso/centos-7-x86_64/images/pxeboot/initrd.img repo=http://server.domain.com/distros/centos-7-x86_64/ noipv6 ip=dhcp ramdisk_size=9216 text rescue
here, i'm pointing it to the kernel and initrd over TFTP as before, and i'm giving it a repo via HTTP (so you need webserver setup too), but you can use other protocols as well.

Anyway TL;DR is you need to setup your DHCP, TFTP, and pxelinux to PXE boot and point to a kernel image (and you might need to setup web server or NFS too).
 
Last edited:

BLinux

cat lover server enthusiast
Jul 7, 2016
2,672
1,081
113
artofserver.com
BTW, when you type in "linux", is that at the pxelinux boot loader? If so, can you show your config for the "linux" label? For example, see the 3rd code section in my previous post, the "label C-7-x86_64" is my label to boot CentOS 7 64bit installer. So, I type "C-7-x86_64" instead and the settings under that "label" are what gets used for the boot parameters.
 

macrules34

Active Member
Mar 18, 2016
407
28
28
40
Looks like I solved the issue. I had the wrong "label" in the default file. So when the screen (messages file) came up they didn't match, once I changed that in the default file it booted. Thanks guys!!!:)
 

macrules34

Active Member
Mar 18, 2016
407
28
28
40
Does anyone know if I can run 4 installs from one repository or do I need 4 different repository's?
 

macrules34

Active Member
Mar 18, 2016
407
28
28
40
Know that I have the SLES 12 install working I want to also be able to install Ubuntu from the same server. So I copied over the vmlinuz file to my /srv/tftpboot/bios/x86 but it still boots into suse linux and freezes. How do I install Ubuntu via PXE using the same server?
 

macrules34

Active Member
Mar 18, 2016
407
28
28
40
I've gotten it to boot to what looks like the Ubuntu single user mode, the prompt is (initramfs)?
 

BLinux

cat lover server enthusiast
Jul 7, 2016
2,672
1,081
113
artofserver.com
it's a bit hard to help you without configuration details. it would help if you posted your pxelinux configuration. i don't know about Ubuntu install process, but usually you have to provide a bootable kernel, an initramfs that kickstarts the install process and a location for packages. you need to figure out what those should be for Ubuntu and make sure you're providing those parameters to the PXE boot process.
 

macrules34

Active Member
Mar 18, 2016
407
28
28
40
Here is a copy of the pxelinux.cfg/default file:

default harddisk
# hard disk
label harddisk
localboot -2
#install
label linux
kernel linux
append initrd=initrd showopts install=ftp://<ipaddress of server>/suse12sp1/CD1/
label ubuntu
kernel pxelinux.cfg/ubuntu1804/vmlinuz
append initrd=pxelinux.cfg/ubuntu1804/initrd.gz showopts install=ftp://<ipaddress of server>/ubuntu1804/iso/
display message
#uigfxboot bootlogo message
implicit0
prompt1
timeout600
 

macrules34

Active Member
Mar 18, 2016
407
28
28
40
Anybody? This is my first PXE server so let me know what files to post for you to diagnose the issue.
 

BLinux

cat lover server enthusiast
Jul 7, 2016
2,672
1,081
113
artofserver.com
@macrules34 I think it's not a config problem on your end, but a Ubuntu installer problem. Apparently their PXE booting has been broken for months:

Bug #1754828 “Ubuntu 18.04 LTS fails to PXE boot” : Bugs : ubiquity package : Ubuntu

Bug #1755863 “netbooting the bionic live CD over NFS goes straig...” : Bugs : casper package : Ubuntu

Bug #1754777 “bionic casper nfsboot not reaching desktop env, fa...” : Bugs : casper package : Ubuntu

In those bug reports, there is mention of a workaround to use systemd to mask off some services that might allow it to work. I'm no Ubuntu expert, so take that for what it is worth. All I did was a google search on the issue you had..
 

macrules34

Active Member
Mar 18, 2016
407
28
28
40
Okay thanks. I did do some googling myself, but came up with nothing that would have pointed me in Ubuntu PXE boot bugs.