# ltsp, pxe question

## o5gmmob8

Hi guys,

I was wondering if it is possible to run LTSP on my gentoo box so that another client can connect to it.  At home, my box is behind a wireless router and the client connected to the same router via ethernet.  The router assigns the dhcp leases.  Now, at school, all dhcp requests get passed to a central server.  All machines online have a public IP address.

From my bit of reading, it looks like the LTSP server and the dhcp server must be the same machine.  Is it possible to tell the thin client to boot up to 192.168.0.xxx or something like that?  I would tend to doubt it since that option could be a security problem.

I also must note that, it is not possible for me to turn of the dhcp server in either server, or have it forward requests to my box.

Walter

----------

## memoi2001

Had the same problem, but I just deactivated one of the dhcp servers and sent all non-ltsp client to static addressing.., could you not connect you client and ltsp-server on a different network? say 192.168.0.x for "normal" ips and 192.168.1.x for ltsp?

although being connected to a router this could be a probleme it seems like your only choice.

----------

## o5gmmob8

Hi,

Thanks for your quick response.

I have NO control over the networks - at home, my dad may let me change some stuff, but it would be better if it requires no *special* configuration because he wouldn't want me playing around and causing any grief for others.  Also, at school, I would consider running ltsp on the server I manage, and that cannot have any networking changes.

I want to be able to use a cheap machine as a client, no hd, just a cd/floppy so file-sharing would be more centralized and all the machines have the same desktop, require little maintenance, etc.

I was curious if at bootup, I could enter an IP address for the ltsp server/tftp server address.  I thought RedHat's installer had that functionality so for this reason, I don't believe it would be much of a stretch unless the software doesn't have that support.  Depending on the code involved, I may have to take a look, as that would be neat.  Of course, the machine I am booting is too old for PXE boot, so I would be looking at a removable media image and coding in whatever language that uses.

Thanks,

Walter

----------

## memoi2001

I dont know about PXE, but an etherboot disk should allow you to point out IPs and stuff..

try rom-o-matic.net

----------

## o5gmmob8

Hi,

Thanks, I will try that out and see how it goes.

Walter

----------

## o5gmmob8

Hi,

I tried an etherboot image for my card, I verified the vendor and manufacturer ids with the image I downloaded.

I boot up to the floppy image and it tries to get a dhcp lease, but I have waited an hour and did not get one.  Also, the router logs did not show any activity for the wired network, indicating that no dhcp requests were sent.  I am using a belkin 10/100 MB nic:

0000:00:0e.0 Class 0200: 10ec:8139 (rev 10)

Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ (rev 10)

Also, I must point out, this is not an onboard ethernet card.  It has space for a rom chip, but there is no chip in there if that makes any difference.

From reading etherboot.org's site, I see that it should work, but I am going to make a new image enabling everything possible.

This makes me think that I need the dhcp server to be on the same machine as the ltsp server:

```

// Some general options

default-lease-time            21600;

max-lease-time                21600;

use-host-decl-names           on;

ddns-update-style             ad-hoc;

// Bootp options

allow booting;

allow bootp;

// Network Options

option subnet-mask            255.255.255.0;

option broadcast-address      192.168.0.255;

option routers                192.168.0.254;

option domain-name-servers    192.168.0.254;

option log-servers            192.168.0.254;

option domain-name            "yourdomain.com";

// LTSP Path Options

option root-path              "192.168.0.254:/opt/ltsp-4.1/i386";

filename                      "/lts/vmlinuz-2.4.26-ltsp-2";

// If your workstations have ISA NICs uncomment the following

// lines and alter the driver and IO

#option option-128 code 128 = string;

#option option-129 code 129 = text;

#option option-128 e4:45:74:68:00:00;

#option option-129 "NIC=ne IO=0x300";

shared-network WORKSTATIONS {

  subnet 192.168.0.0 netmask 255.255.255.0 {

    // Distribute dynamic IPs to the workstations

    range dynamic-bootp 192.168.0.1 192.168.0.16;

    // Workstation specific configuration for PXE booting

    #host ws001 {

    #  hardware ethernet     00:E0:06:E8:00:84;

    #  fixed-address         192.168.0.1;

    #}

  }

}

```

Walter

----------

## Arainach

DHCP is an essential part of LTSP.  You absolutely MUST have the DHCP server be the LTSP server for it to work.

----------

## o5gmmob8

Hi,

Must it be on the LTSP server, or can it be a simple home router?  Additionally, if that is the case, could I just modify the source and have a prompt for the ftp server IP address (I believe RedHat has that option)?

Walter

----------

## Arainach

Nope, it MUST be part of the LTSP server.  LTSP sends the kernel image through TFTP when the client connects to the LTSP server for an IP address.

----------

## o5gmmob8

Hi,

Can I then run a dhcp server that only listens for certain dhcp requests that wouldn't affect the rest of the network?  If I did that, would the requests get passed from the router 192.168.0.1 to all clients on the network?  And, at school my local machine would be on a different subnet, so I doubt the server would be able to receive such dhcp requests.

Guess I probably should buy a laptop...

Walter

----------

## memoi2001

you could try putting a second network card in your server and plugging it into the same hub, on a different subnet, then set both dchp server to either ignore or acccept the MAC address of your client..

btw, I've managed to set a dhcp server on another machine than the ltsp server this way, but it was two years ago, ltsp may have changed a bit since..

----------

## o5gmmob8

Hi,

I think I understand what you are saying, but the computers are not connected to hubs unfortunately.  At home, the computer would be connected to a router and at school, there are different subnets for different locations.  For example, the computer in my room would be on one of the dorm subnets 128.2.aaa (something.res.cmu.edu) and my server 128.2.68.xxx (something.hss.cmu.edu).

I got the idea that I could specify the server like someone said, but that doesn't appear to be the case.

I would like to have this flexibility so that administering a small group of computers would be simple and they would need very little power.  Looks like another project for me, or maybe a request to etherboot.org.

Walter

----------

## memoi2001

128.2.68.x, that's a public IP address.. dhcp on that would go straight to the net..

you'll have to set static address in you bootrom for this situation, and set the routers to redirect the packets to you server, thus setting all tftp port redirections and such..

are there any sys-admins for the dorm network, you should speak to them about it.

good luck

----------

## Arainach

 *walterw wrote:*   

> Hi,
> 
> Can I then run a dhcp server that only listens for certain dhcp requests that wouldn't affect the rest of the network?  If I did that, would the requests get passed from the router 192.168.0.1 to all clients on the network?  And, at school my local machine would be on a different subnet, so I doubt the server would be able to receive such dhcp requests.
> 
> Guess I probably should buy a laptop...
> ...

 You could have two DHCP servers IF each one only accepted requests from certain MAC addresses.  Neither one could be serving to everywhere, and you'd have to upgrade the dhcpd.conf file every time you added another computer.  That way all the terminals would connect to the LTSP server and all the other computers would connect to the regular server.

----------

## o5gmmob8

Hi guys,

I still am unclear.  I understand that I can have it filtered by MAC, that is exactly how the school does it.

So I can hardcode the server IP address into the bootrom?

I am looking at GRUB's wiki, and could I possibly use that?  Tell it to get a dhcp lease, then point it to the tftp server?

Walter

----------

## memoi2001

the rom-o-matic allows you to use static addresses for an ltsp boot, you could then set the tftp server address and not worry about the dhcp, seeing as it's not obligatory..

the site offers a pretty cool auto-rom-maker thing

http://www.rom-o-matic.net/5.2.6/

----------

## memoi2001

 *Arainach wrote:*   

> Nope, it MUST be part of the LTSP server.  LTSP sends the kernel image through TFTP when the client connects to the LTSP server for an IP address.

 

This isn't actually true, the DHCP server "should" be on the same box as the LTSP server but only for practical reasons, the only problem with it not being on the same box is that most ltsp servers activate dhcp and you end up with two of them..

----------

## o5gmmob8

Hi,

How do you staticly configure the server address?

it shows tftp://path_to_file

Should I do 192.168.0.150//path_to_file

Walter

----------

## Arainach

 *memoi2001 wrote:*   

>  *Arainach wrote:*   Nope, it MUST be part of the LTSP server.  LTSP sends the kernel image through TFTP when the client connects to the LTSP server for an IP address. 
> 
> This isn't actually true, the DHCP server "should" be on the same box as the LTSP server but only for practical reasons, the only problem with it not being on the same box is that most ltsp servers activate dhcp and you end up with two of them..

 If you want to use PXE booting, the DHCP server MUST be the LTSP server.

 *Quote:*   

> http://wiki.ltsp.org/twiki/bin/view/Ltsp/PXE
> 
>  Booting with pxelinux.0
> 
> dhcp request
> ...

 

----------

## memoi2001

 *walterw wrote:*   

> Hi,
> 
> How do you staticly configure the server address?
> 
> it shows tftp://path_to_file
> ...

 

tftp://<IPADDRESS>:/<PATH TO KERNEL>

----------

## o5gmmob8

Hi,

I cannot use pxe to boot, so I must use either:

etherboot

grub (nb, bootp)

I have tried hardcoding the server's IP address in the file field:

```

tftp://192.168.0.150/tftpboot/lts/vmlinuz-2.4.26-ltsp-2

```

But my client is still searching for a bootp server.  I also should point out that running nmap on my machine:

```

PORT    STATE SERVICE

111/tcp open  rpcbind

631/tcp open  ipp

716/tcp open  unknown

```

in.tftp, xinetd, and nfs are started (nfs reported an error, but bootp server should still work).

I just saw your post, I will try adding a colon,:, to see if that helps.

Thanks,

WalterLast edited by o5gmmob8 on Sat Jan 22, 2005 8:12 pm; edited 1 time in total

----------

## memoi2001

sorry 'bout that, yes for PXE it has to be on the same..

etherboot another thing altogether

----------

## o5gmmob8

Hi again,

No luck, I cannot get a dhcp lease, it will just sit there trying and trying, but never gets a dhcp lease.  Unless something radical happens, I will have to wait to try it down at the school where the dhcp server may be more advanced and pick it up.

Walter

----------

## memoi2001

if your setting the tftp server address you should set the etherboot thing from dhcp to bootp..

static addresses mean you no longer need dhcp..

----------

## o5gmmob8

Will give that a go, looks like it is still searching...

Walter

----------

