Re: thin clients does not get the hostname from dhcp server
Alkis Georgopoulos <[email protected]>
| Newsgroups | gmane.linux.terminal-server.general |
|---|---|
| Message-ID | <[email protected]> |
Hi, this is probably due to defaulting to
IPAPPEND 3
now, instead of the previous
IPAPPEND 2.
It helps a lot of our users (e.g. proxyDHCP users),
but hurts a few of our users like you (real DHCP and names from DHCP
instead of lts.conf).
Try changing it in /var/lib/tftpboot/ltsp/amd64/pxelinux.cfg/default,
and see if I guessed correctly.
Alkis
Στις 24/1/19 12:11 μ.μ., ο Jan Hubený έγραψε:
> Hi,
>
> short summary:
> On Ubuntu 18.04 we have installed last ltsp version from greek school
> ppa. We encounter problem that the thin clients does not use the
> hostname which is send to the client via dhcp reply from the dhcp server
> and after that they generate the default hostname (e.g. ltsp203). I
> suppose that the problem is somewhere in the client setup, because I
> verify that the dhcp server sends the hostname info (see the verbose
> description).
>
> verbose description:
> The ltsp server is Ubuntu 18.04. We use the chrooted setup.
> ltsp-info output:
> server information:
> No LSB modules are available.
> Distributor ID: Ubuntu
> Description: Ubuntu 18.04.1 LTS
> Release: 18.04
> Codename: bionic
>
> server packages:
> un ldm <žádná>
> ii ldm-server 2:2.18.06-1+t201810250641~u
> un ltsp-client <žádná>
> rc ltsp-client-core 5.5.10-1build1
> ii ltsp-docs 1.2-1
> ii ltsp-server 5.18.04+t201809080524~ubunt
> ii ltsp-server-standalone 5.18.04+t201809080524~ubunt
> un ltsp-utils <žádná>
> ii ltspfs 1.5-2+t201807160629~ubuntu1
> un ltspfsd <žádná>
>
> packages in chroot: /opt/ltsp/amd64
> ii ldm 2:2.18.06-1+t201810250641~u
> un ldm-themes <žádná>
> ii ldm-ubuntu-theme 2:2.0.47
> un ldm-ubuntu-themes <žádná>
> ii ltsp-client 5.18.04+t201809080524~ubunt
> ii ltsp-client-core 5.18.04+t201809080524~ubunt
> ii ltspfsd 1.5-2+t201807160629~ubuntu1
> ii ltspfsd-core 1.5-2+t201807160629~ubuntu1
>
> found: /opt/ltsp/amd64/etc/lts.conf
>
> found: /var/lib/tftpboot/ltsp/amd64/lts.conf
>
> found image: /opt/ltsp/images/amd64.img
>
>
> The dhcp server is CentOS 7.0 fully updated. DHCP server version:
> rpm -qa | grep dhcp
> dhcp-common-4.2.5-68.el7.centos.1.x86_64
> dhcp-4.2.5-68.el7.centos.1.x86_64
> dhcp-libs-4.2.5-68.el7.centos.1.x86_64
>
>
> When I tracked the dhcp communication between thin client and the server
> with tcpdump I get following output on the dhcp server
> root@core ~ # tcpdump -i ens192 -vvv -s 1500 '(port 67 or port 68)'
> 10:38:25.653222 IP (tos 0x0, ttl 19, id 36755, offset 0, flags [none],
> proto UDP (17), length 576)
> 172.25.0.1.bootps > 172.25.32.8.bootps: [udp sum ok] BOOTP/DHCP,
> Request from 00:50:56:91:30:05, length 548, hops 1, xid 0x57913005, secs
> 4, Flags [Broadcast] (0x8000)
> Gateway-IP 172.25.0.1
> Client-Ethernet-Address 00:50:56:91:30:05
> Vendor-rfc1048 Extensions
> Magic Cookie 0x63825363
> DHCP-Message Option 53, length 1: Discover
> Parameter-Request Option 55, length 24:
> Subnet-Mask, Time-Zone, Default-Gateway, IEN-Name-Server
> Domain-Name-Server, RL, Hostname, BS
> Domain-Name, SS, RP, EP
> Vendor-Option, Server-ID, Vendor-Class, BF
> Option 128, Option 129, Option 130, Option 131
> Option 132, Option 133, Option 134, Option 135
> MSZ Option 57, length 2: 1260
> GUID Option 97, length 17:
> 0.66.17.79.26.92.228.24.68.206.237.229.149.90.201.87.212
> ARCH Option 93, length 2: 0
> NDI Option 94, length 3: 1.2.1
> Vendor-Class Option 60, length 32:
> "PXEClient:Arch:00000:UNDI:002001"
> END Option 255, length 0
> PAD Option 0, length 0, occurs 212
> 10:38:25.653543 IP (tos 0x0, ttl 64, id 27528, offset 0, flags [DF],
> proto UDP (17), length 375)
> 172.25.32.8.bootps > 172.25.0.1.bootps: [bad udp cksum 0x79b0 ->
> 0x095a!] BOOTP/DHCP, Reply, length 347, hops 1, xid 0x57913005, secs 4,
> Flags [Broadcast] (0x8000)
> Your-IP 172.25.8.254
> Server-IP 172.25.32.53
> Gateway-IP 172.25.0.1
> Client-Ethernet-Address 00:50:56:91:30:05
> Vendor-rfc1048 Extensions
> Magic Cookie 0x63825363
> DHCP-Message Option 53, length 1: Offer
> Server-ID Option 54, length 4: 172.25.32.8
> Lease-Time Option 51, length 4: 21600
> Subnet-Mask Option 1, length 4: 255.255.240.0
> Default-Gateway Option 3, length 4: 172.25.0.1
> Domain-Name-Server Option 6, length 4: 172.25.32.8
> * Hostname Option 12, length 8: "tctest64"*
> Domain-Name Option 15, length 7: "soma.cz"
> RP Option 17, length 28: "172.25.32.53:/opt/ltsp/amd64"
> BF Option 67, length 22: "/ltsp/amd64/pxelinux.0"
> END Option 255, length 0
> 10:38:25.834087 IP (tos 0x0, ttl 254, id 28636, offset 0, flags [none],
> proto UDP (17), length 336)
> 172.25.128.1.bootps > 172.25.32.8.bootps: [udp sum ok] BOOTP/DHCP,
> Request from 7c:1e:b3:00:86:c4, length 308, hops 1, xid 0xabcd0771,
> Flags [none] (0x0000)
> Gateway-IP 172.25.128.1
> Client-Ethernet-Address 7c:1e:b3:00:86:c4
> Vendor-rfc1048 Extensions
> Magic Cookie 0x63825363
> DHCP-Message Option 53, length 1: Discover
> MSZ Option 57, length 2: 1500
> Parameter-Request Option 55, length 4:
> Subnet-Mask, Default-Gateway, BR, Domain-Name-Server
> END Option 255, length 0
> PAD Option 0, length 0, occurs 54
> 10:38:27.740723 IP (tos 0x0, ttl 19, id 1, offset 0, flags [none], proto
> UDP (17), length 576)
> 172.25.0.1.bootps > 172.25.32.8.bootps: [udp sum ok] BOOTP/DHCP,
> Request from 00:50:56:91:30:05, length 548, hops 1, xid 0x57913005, secs
> 4, Flags [Broadcast] (0x8000)
> Gateway-IP 172.25.0.1
> Client-Ethernet-Address 00:50:56:91:30:05
> Vendor-rfc1048 Extensions
> Magic Cookie 0x63825363
> DHCP-Message Option 53, length 1: Request
> Requested-IP Option 50, length 4: 172.25.8.254
> Parameter-Request Option 55, length 24:
> Subnet-Mask, Time-Zone, Default-Gateway, IEN-Name-Server
> Domain-Name-Server, RL, Hostname, BS
> Domain-Name, SS, RP, EP
> Vendor-Option, Server-ID, Vendor-Class, BF
> Option 128, Option 129, Option 130, Option 131
> Option 132, Option 133, Option 134, Option 135
> MSZ Option 57, length 2: 1260
> Server-ID Option 54, length 4: 172.25.32.8
> GUID Option 97, length 17:
> 0.66.17.79.26.92.228.24.68.206.237.229.149.90.201.87.212
> ARCH Option 93, length 2: 0
> NDI Option 94, length 3: 1.2.1
> Vendor-Class Option 60, length 32:
> "PXEClient:Arch:00000:UNDI:002001"
> END Option 255, length 0
> PAD Option 0, length 0, occurs 200
> 10:38:27.740999 IP (tos 0x0, ttl 64, id 28651, offset 0, flags [DF],
> proto UDP (17), length 375)
> 172.25.32.8.bootps > 172.25.0.1.bootps: [bad udp cksum 0x79b0 ->
> 0x065a!] BOOTP/DHCP, Reply, length 347, hops 1, xid 0x57913005, secs 4,
> Flags [Broadcast] (0x8000)
> Your-IP 172.25.8.254
> Server-IP 172.25.32.53
> Gateway-IP 172.25.0.1
> Client-Ethernet-Address 00:50:56:91:30:05
> Vendor-rfc1048 Extensions
> Magic Cookie 0x63825363
> DHCP-Message Option 53, length 1: ACK
> Server-ID Option 54, length 4: 172.25.32.8
> Lease-Time Option 51, length 4: 21600
> Subnet-Mask Option 1, length 4: 255.255.240.0
> Default-Gateway Option 3, length 4: 172.25.0.1
> Domain-Name-Server Option 6, length 4: 172.25.32.8
> * Hostname Option 12, length 8: "tctest64"*
> Domain-Name Option 15, length 7: "soma.cz"
> RP Option 17, length 28: "172.25.32.53:/opt/ltsp/amd64"
> BF Option 67, length 22: "/ltsp/amd64/pxelinux.0"
> END Option 255, length 0
>
> However, when I log into the booted client, then there is the default
> name (ltsp2302). I try to find the code which sets the hostname in the
> ltsp-client file tree. I found that the hostname is set with files
> /usr/share//ltsp/init-ltsp.d/02-initramfs-env and 09-hostname
> In the file 02-initramfs-env I have found that the net info is get by
> the code
>
> 02-initramfs-env:
> for netfile in /run/ltsp/net-*.conf /run/net-*.conf ; do
> if [ -f "$netfile" ]; then
> . "$netfile"
> fi
> done
>
> Therefore on the booted client I check the content of mentioned files:
> root@ltsp2302:~# ls /run/ltsp/net*conf /run/net-*.conf
> ls: cannot access '/run/ltsp/net*conf': No such file or directory
> /run/net-ens160.conf
> root@ltsp2302:~# cat /run/net-ens160.conf
> DEVICE='ens160'
> IPV4ADDR='172.25.8.254'
> IPV4BROADCAST=''
> IPV4NETMASK='255.255.240.0'
> IPV4GATEWAY='172.25.0.1'
> IPV4DNS0=''
> IPV4DNS1=''
> HOSTNAME=''
> DNSDOMAIN=''
> NISDOMAIN=''
> ROOTSERVER='172.25.32.53'
> ROOTPATH='/opt/ltsp/amd64'
> filename=''
> DNS_SERVER=''
> SEARCH_DOMAIN=''
> NTPSVR=''
> TIMESVR=''
> TIMEZONE=''
> SWAPSVR=''
>
> The HOSTNAME is not set in this file.
>
> Can anybody tell me what is wrong or what to test further?
>
>
> Have a nice day,
>
> Honza
>
>
> ------------------------------------------------------------------------
>
> ***D I S C L A I M E R ***
>
> ------------------------------------------------------------------------
>
> /_Personal data protection according to Regulation (EU) 2016/679 of the
> European Parliament and of the Council of 27 April 2016 on the
> protection of natural persons with regard to the processing of personal
> data and on the free movement of such data (General Data Protection
> Regulation) _/
>
> l communication with this e-mail address (especially by sending e-mails
> and replies) you hereby agree with processing of yours personal data
> especially in the scope of data contained in email and it`s attachments.
> Data subject has the following rights: (i) to withdraw consent with
> personal data processing , (ii) to ask SOMA company for information
> which personal data are being processed, (iii) to ask for explanation
> regarding processed personal data, (iv) to ask for access to personal
> data and right of rectification of inaccurate personal data, (v) to
> demand erasure of personal data, (iv) in case of doubts regarding
> compliance with GDPR regulation right to raise objections in front of
> SOMA company, court or the Office for personal data protection.
>
> The SOMA company processes especially personal data of SOMA company`s
> business partners. The SOMA company hereby politely asks it`s business
> partners to not to send to SOMA company by e-mails or by any other means
> personal data of any third persons (for instance business partners`
> employees, participants of agreements, contracts or other legal
> relationships etc.), these personal data will not be processed by SOMA
> company and will be immediately erased. If you are not a business
> partner of SOMA company and you are sending to SOMA company any personal
> data in any kind of form (for instance by e-mail, data mailbox or by
> letter etc.) you hereby agree with processing of your personal data in
> the scope of personal data sent by you and you have right described in
> point (i) to (vi) hereof.
>
> The SOMA company is processing personal data especially due to the
> following purposes: (a) processing is necessary for the performance of a
> contract to which the data subject is party or in order to take steps at
> the request of the data subject prior to entering into a contract, or
> (b) processing is necessary for compliance with a legal obligation to
> which the controller is subject, or (c) processing is necessary in order
> to protect the vital interests of the data subject or of another natural
> person; or (d) processing is necessary for the purposes of the
> legitimate interests pursued by the controller or by a third party.
>
> Data subject is obliged to announce the SOMA company any changes of
> personal data of the data subject.
>
> /_Confidentiality _/
>
> The information contained in this e-mail is confidential and is intended
> solely for the use of subject to whom it is addressed and others
> authorized to receive it. The text or attachments may contain
> confidential information, privileged information or information
> considered by the law firm as the trade secret. If you are not the
> intended recipient you are hereby notified that any disclosure, copying,
> distribution or taking any action in reliance on the contents of this
> information is strictly prohibited and may be unlawful. The law firm is
> neither liable for the contents, nor for the proper, complete and timely
> transmission of the information contained in this communication. By
> usage of e-mail communication the recipient of this e-mail agree this
> kind of communication with law firm and his potential risk and agree
> with unsecured communication. For avoidance of any doubt law firm pays
> attention to the fact that this e-mail including its attachments could
> not be in any case con sidered as offer for conclusion of agreement
> pursuant to § 1731 of act no 89/2012 Coll. as amended, neither
> confirmation letter pursuant to the § 1757 of act no 89/2012 Coll. as
> amended.
>
> /Our full GDPR policy may be found *here
> <http://www.soma-eng.com/en/gdpr>* /
>
> /Překlad výše uvedeného textu (Ochrana osobních údajů dle nařízení
> Evropského parlamentu a Rady EU a Důvěrnost informací) naleznete *zde
> <http://www.soma-eng.com/cs/disclaimer>* /
>
>
>
>
> _____________________________________________________________________
> Ltsp-discuss mailing list. To un-subscribe, or change prefs, goto:
> https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
> For additional LTSP help, try #ltsp channel on irc.freenode.net
>
_____________________________________________________________________
Ltsp-discuss mailing list. To un-subscribe, or change prefs, goto:
https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
For additional LTSP help, try #ltsp channel on irc.freenode.net