LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 10-09-2009, 02:34 PM   #1
chicken76
Member
 
Registered: Mar 2009
Distribution: Slackware
Posts: 74

Rep: Reputation: 1
Slackware 13.0 PXE installation


I'm trying to install Slackware 13.0 on a machine without an optical drive.
I've setup the dhcp server on another system (a Slack 12.2) as described in the README_PXE.TXT file using all the files from the 13.0 installation media (including pxelinux.0)
The machine I'm trying to install to receives an ip address via dhcp, requests the pxelinux.0 file but never gets it. I can see this:
Code:
Oct  9 19:10:47 server in.tftpd[4210]: RRQ from 192.168.30.140 filename /slackware-13.0/pxelinux.0
in /var/log/messages on the server running the tftp server. So I'm assuming it's a problem with in.tftpd.
The only step I didn't follow exactly as instructed in README_PXE.TXT, was the way I ran the tftp server. I dread using inetd, so i started the tftp server like this:
Code:
$ in.tftpd -l -v -s /path_to_pxe_files
Do you see any reason why this shouldn't work?
All the files are world-readable, by the way.
Path is correct. Checked it by using a wrong one and getting
Code:
Oct  9 18:29:41 server in.tftpd[3977]: sending NAK (1, File not found) to 192.168.30.140
I've already excluded the machine trying to boot from the network; tried several very different PC-s. Also, on the tftp server i ran this:
Code:
$ tftp localhost
tftp> get /slackware-13.0/pxelinux.0   (nada, zip, zero)
tftp> get /slackware-13.0/pxelinux.1
Error code 1: File not found
So, what's wrong with running in.tftpd as a daemon?
 
Old 10-09-2009, 04:03 PM   #2
astrogeek
Senior Member
 
Registered: Oct 2008
Distribution: Slackware: 12.1, 13.1, 14.1, 64-14.1, -current, FreeBSD-10
Posts: 1,915

Rep: Reputation: 694Reputation: 694Reputation: 694Reputation: 694Reputation: 694Reputation: 694
You may be asking for the wrong path...

I use PXE for most of my installs now, but always run the inetd daemon, but have had no such troubles.

Just taking a guess, from the man page:

Code:
       -s     Change root directory on startup.  This means the remote host does not need  to  pass  along  the
              directory  as  part  of  the  transfer,  and may add security.  When -s is specified, exactly one
              directory should be specified on the command line.  The use of this  option  is  recommended  for
              security  as  well  as compatibility with some boot ROMs which cannot be easily made to include a
              directory name in its request.
When you start in.tftpd
Code:
$ in.tftpd -l -v -s /path_to_pxe_files
...you are giving a root directory (?)

But when you request a file you are giving a path from '/', which tftp interprets as...

Code:
/path_to_pxe_files/slackware-13.0/pxelinux.0
See if that helps.
 
Old 10-13-2009, 08:32 AM   #3
chicken76
Member
 
Registered: Mar 2009
Distribution: Slackware
Posts: 74

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by astrogeek View Post
I use PXE for most of my installs now, but always run the inetd daemon, but have had no such troubles.
Have you ever tried to stop inetd and start in.tftpd manually, just to test it's still working?


Quote:
When you start in.tftpd
Code:
$ in.tftpd -l -v -s /path_to_pxe_files
...you are giving a root directory (?)

But when you request a file you are giving a path from '/', which tftp interprets as...

Code:
/path_to_pxe_files/slackware-13.0/pxelinux.0
See if that helps.
The full path of pxelinux.0 on my machine is this: /pxe/slackware-13.0/pxelinux.0
Code:
root@machine:/slackware-13.0# ls -l
total 13468
-r--r--r-- 1 root root      793 2007-06-06 00:00 f2.txt
-r--r--r-- 1 root root 13736217 2009-08-25 10:09 initrd.img
dr-xr-xr-x 5 root root     4096 2009-08-18 22:17 kernels
-r--r--r-- 1 root root      758 2009-07-28 19:32 message.txt
-r--r--r-- 1 ftp  ftp     13936 2009-10-13 16:08 pxelinux.0
dr-xr-xr-x 2 root root     4096 2009-10-09 18:45 pxelinux.cfg
The actual command I use to start the tftp server is:
Code:
in.tftpd -l -v -s /pxe
Here's the relevant section of dhcpd.conf:
Code:
  if substring (option vendor-class-identifier, 0, 9) = "PXEClient" {
      filename "/slackware-13.0/pxelinux.0";
  }
I don't think it's a path problem.
 
Old 10-13-2009, 10:19 AM   #4
nl1at
LQ Newbie
 
Registered: Mar 2004
Location: Uitgeest Netherlands
Posts: 26

Rep: Reputation: 15
I use the dnsmasq method.
I find it much easier and works like a charm.
 
Old 10-13-2009, 01:59 PM   #5
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 5,270

Rep: Reputation: Disabled
Try adding "-r blksize" to your in.tftpd commandline.
Alternatively, use dnsmasq to run a dhcp/dns/tftp server all at once.

Eric
 
Old 10-20-2009, 10:50 AM   #6
chicken76
Member
 
Registered: Mar 2009
Distribution: Slackware
Posts: 74

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by Alien Bob View Post
Try adding "-r blksize" to your in.tftpd commandline.
Alternatively, use dnsmasq to run a dhcp/dns/tftp server all at once.

Eric
Tried "-r blksize" and it had no effect.

Is it possible to run both bind and dnsmasq on the same machine?
I would like to continue using bind for dns (I'm not running it only as a cache) and use dnsmasq for tftp only. Can dnsmasq be configured to act only as a tftp server?
 
Old 10-20-2009, 11:19 AM   #7
chicken76
Member
 
Registered: Mar 2009
Distribution: Slackware
Posts: 74

Original Poster
Rep: Reputation: 1
On second thought, even if I set up dnsmasq to run on another server, is there a way to tell dhcpd to pass to the client machine that the tftp server is running at another ip? I haven't found this option in dhcpd, but it seems to exist in dnsmasq.
 
Old 10-20-2009, 03:34 PM   #8
cendryon
Member
 
Registered: Aug 2005
Location: France
Distribution: Slackware64 current
Posts: 78

Rep: Reputation: 27
You set up the TFTP server in /etc/dhcpd.conf with next-server and the TFTP server IP address :

Code:
  # Allow bootp requests for this group:
  allow bootp;

  # Point to the TFTP server (required parameter!):
  next-server 192.168.0.25;
 
Old 11-02-2009, 05:42 AM   #9
chicken76
Member
 
Registered: Mar 2009
Distribution: Slackware
Posts: 74

Original Poster
Rep: Reputation: 1
Tried another tftp server and got the same behavior, which led me to the conclusion that in.tftpd was not the culprit. After some thorough reviewing of what was running on the machine and some hair pulling, managed to identify a SNAT rule in the firewall that was changing the source address for packets going to that particular subnet that I overlooked.
Fixed it and in.tftpd works as well as any other tftp server even when started manually.
Sorry to bother you with nonsense, (I'm doing a lot on that machine and it's easy to overlook things)
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
PXE installation problem - can only select A series packages for installation Nylex Slackware 4 08-19-2010 02:15 PM
Fedora Installation by PXE nodopro Linux - Newbie 3 04-20-2009 06:54 PM
pxe installation rohit_67066 Linux - Networking 2 01-11-2008 04:00 AM
Error while PXE installation linux4begin Linux - General 0 10-16-2007 04:13 AM
PXE installation fails mrok Linux - Networking 8 12-15-2006 05:26 AM


All times are GMT -5. The time now is 08:03 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration