# creating a tftpboot server [solved]

## DaggyStyle

Greetings,

I have a x86_64 server and a arm64 board, I want to setup a ftfp server on the x86_64 server so I can use it to boot the arm64 board.

I've taken a look at this: https://wiki.gentoo.org/wiki/Diskless_nodes but I'm not sure what parts of it I need.

I have the arm64 board's kernel image compiled, what I need to setup so I can boot that kernel image?

Thanks.

----------

## bbgermany

Hi,

you need at least the dhcp server, the tftp server and the nfs server for the root filesystem. 

Then you can choose between pxeboot or etherboot. this is your choice.

greets, bb

----------

## P.Kosunen

Dnsmasq is quite easy choice for server side, DHCP/DNS/TFTP/PXE boot in same tool and easy to configure.

I think PXELINUX does not support ARM, so you need to load kernel image directly from TFTP root.

dnsmasq.conf:

```

dhcp-boot=vmlinuz-4.11.0-gentoo

enable-tftp

tftp-root=/var/ftpd

```

----------

## NeddySeagoon

DaggyStyle,

What will run on the arm board to fetch the kernel over tftp?

----------

## bbgermany

As far as i can see, it should be u-boot which needs to fetch the kernel via tftp.

greets, bb

----------

## DaggyStyle

as said below, the board uses u-boot so I want to fetch the kernel via tftp and boot from the root which on the board's card.

do I need dhcp server? I've already have one on my server.

----------

## P.Kosunen

 *DaggyStyle wrote:*   

> do I need dhcp server? I've already have one on my server.

 

https://wiki.gentoo.org/wiki/Diskless_nodes#Configuring_the_DHCP_server_2

You can use your existing DHCP server.

----------

## DaggyStyle

so I can use the Diskless_nodes tutorial minus the dhcp configure?

----------

## P.Kosunen

Yes i believe and also no PXELINUX part.

```
allow booting;

next-server "TFTP server ip";

filename "kernel filename";
```

Add these options to dhcpd.conf. Kernel goes to TFTP root directory, AFAIK kernel boot parameters need to be compiled in kernel.

----------

## DaggyStyle

but if I can use existing dhcp, why do I need to define dhcp.conf?

----------

## bbgermany

The dhcp server need to provide the information for the tftp boot file/server iirc. Otherwise your system will not start as well.

greets, bb

EDITH: maybe this can help you a bit more then the diskless howto: https://rechtzeit.wordpress.com/2013/01/16/tftp-boot-using-u-boot/

It looks like, you just need a working dhcp server for providing an ip and the tftp server. then fire up your system with u-boot and stop the autoboot process and continue with the howto  :Wink: 

----------

## DaggyStyle

got it to work but unfortunately, I'm getting an error. it seems that the tftpboot is working so this issue is solved.

to put it simple, I've installed tftp-hpa, modified the conf file, started it, posted the files in the folder and the rest was done via uboot.

----------

