Discussion:
[Ltsp-discuss] Ubuntu 16.04 fat client does not power off
Juan Antonio Martinez
2017-02-24 12:01:10 UTC
Permalink
Hi all:
I have a 200+ PC's students lab with Ubuntu 16.04-64bit gnome-based
LTSP fat clients. (local swap, nfs mounted home, ldap ids/gids )

Everything works fine... but cannot properly poweroff PC's, either
by gnome session poweroff button, or by mean of "sudo /bin/poweroff",
or even pressing physical power button at PC

When initiating poweroff process user session goes out, gdm exits,
switch to console and initiate poweroff display sequence... and freezes

I've checked almost every combination of acpi=xxxx pxe grub options; of
course PC bios have apm enabled

Also, tried to "systectl enable poweroff.target" in systemd (¿why it's
disabled in LTSP fat client? ), check for proper nbd-client disconnect
disabled in shutdown, re-check that network interface does not execute
ifdown...

More tips: sudo /usr/lib/klibc/bin/poweroff works, but no idea on how
to include in systemd chain, or even if it's a good idea

So at this moment, the only way to propperly poweroff the fat clients
lab is... by unplugging power supply cable ( or press & hold 10 seconds
power button )


Any hint?
Thanks in advance
Juan Antonio
richard kweskin
2017-02-24 14:09:49 UTC
Permalink
Post by Juan Antonio Martinez
I have a 200+ PC's students lab with Ubuntu 16.04-64bit gnome-based
LTSP fat clients. (local swap, nfs mounted home, ldap ids/gids )
Everything works fine... but cannot properly poweroff PC's, either
by gnome session poweroff button, or by mean of "sudo /bin/poweroff",
or even pressing physical power button at PC
When initiating poweroff process user session goes out, gdm exits,
switch to console and initiate poweroff display sequence... and freezes
I've checked almost every combination of acpi=xxxx pxe grub options; of
course PC bios have apm enabled
Also, tried to "systectl enable poweroff.target" in systemd (¿why it's
disabled in LTSP fat client? ), check for proper nbd-client
disconnect
disabled in shutdown, re-check that network interface does not
execute
ifdown...
More tips: sudo /usr/lib/klibc/bin/poweroff works, but no idea on how
to include in systemd chain, or even if it's a good idea
So at this moment, the only way to propperly poweroff the fat clients
lab is... by unplugging power supply cable ( or press & hold 10 seconds
power button )
Any hint?
Thanks in advance
Juan Antonio
Hi Juan

Do all 200+ clients have the same hardware and the same problem? Let's
see what kernel video driver is in use here.

If you want to see the kernel video driver use the command

lspci -knn | grep -A2 VGA

in a terminal and display the results here on the list.

Also, do you have epoptes installed on the server?

Richard
Juan Antonio Martinez
2017-02-27 07:38:26 UTC
Permalink
(Answering to all)

- Yes: poweroff -fp works

- Miscelaneous clients:
* Dell Optiplex 745/520/525
* HP Compaq 6000/6300/8000

- Every clients use native intel video driver

- Seems that there is an issue with rc.local service: sometimes
shutdown screen shows a message: "A stop job is running for
/etc/rc.local" looping forever (no timeout)

Why is rc.local trying to be executed at shutdown? how can i avoid it?
Post by richard kweskin
Post by Juan Antonio Martinez
I have a 200+ PC's students lab with Ubuntu 16.04-64bit gnome-based
LTSP fat clients. (local swap, nfs mounted home, ldap ids/gids )
Everything works fine... but cannot properly poweroff PC's, either
by gnome session poweroff button, or by mean of "sudo
/bin/poweroff",
or even pressing physical power button at PC
When initiating poweroff process user session goes out, gdm exits,
switch to console and initiate poweroff display sequence... and 
freezes
I've checked almost every combination of acpi=xxxx pxe grub
options; 
of
course PC bios have apm enabled
Also, tried to "systectl enable poweroff.target" in systemd  (¿why 
it's
disabled in LTSP fat client? ), check for proper nbd-client 
disconnect
disabled in shutdown, re-check that network interface does not 
execute
ifdown...
More tips: sudo /usr/lib/klibc/bin/poweroff works, but no idea on how
to include in systemd chain, or even if it's a good idea
So at this moment, the only way to propperly poweroff the fat clients
lab is... by unplugging power supply cable ( or press & hold 10 
seconds
power button )
Any hint?
Thanks in advance
Juan Antonio
Hi Juan
Do all 200+ clients have the same hardware and the same problem?
Let's 
see what kernel video driver is in use here.
If you want to see the kernel video driver use the command
     lspci -knn | grep -A2 VGA
in a terminal and display the results here on the list.
Also, do you have epoptes installed on the server?
Richard
-------------------------------------------------------------------
-----------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_____________________________________________________________________
      https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
For additional LTSP help,   try #ltsp channel on irc.freenode.net
richard kweskin
2017-02-27 10:42:26 UTC
Permalink
Post by Juan Antonio Martinez
Post by Juan Antonio Martinez
Post by Juan Antonio Martinez
I have a 200+ PC's students lab with Ubuntu 16.04-64bit
gnome-based
Post by Juan Antonio Martinez
LTSP fat clients. (local swap, nfs mounted home, ldap ids/gids )
Everything works fine... but cannot properly poweroff PC's, either
by gnome session poweroff button, or by mean of "sudo
/bin/poweroff",
or even pressing physical power button at PC
When initiating poweroff process user session goes out, gdm exits,
switch to console and initiate poweroff display sequence... and 
freezes
I've checked almost every combination of acpi=xxxx pxe grub
options; 
of
course PC bios have apm enabled
Also, tried to "systectl enable poweroff.target" in
systemd  (¿why 
Post by Juan Antonio Martinez
it's
disabled in LTSP fat client? ), check for proper nbd-client 
disconnect
disabled in shutdown, re-check that network interface does not 
execute
ifdown...
More tips: sudo /usr/lib/klibc/bin/poweroff works, but no idea on how
to include in systemd chain, or even if it's a good idea
So at this moment, the only way to propperly poweroff the fat clients
lab is... by unplugging power supply cable ( or press & hold 10 
seconds
power button )
Any hint?
Thanks in advance
Juan Antonio
Hi Juan
Do all 200+ clients have the same hardware and the same problem?
Let's 
see what kernel video driver is in use here.
If you want to see the kernel video driver use the command
     lspci -knn | grep -A2 VGA
in a terminal and display the results here on the list.
Also, do you have epoptes installed on the server?
Richard
(Answering to all)
- Yes: poweroff -fp works
* Dell Optiplex 745/520/525
* HP Compaq 6000/6300/8000
- Every clients use native intel video driver
- Seems that there is an issue with rc.local service: sometimes
shutdown screen shows a message: "A stop job is running for
/etc/rc.local" looping forever (no timeout)
Why is rc.local trying to be executed at shutdown? how can i avoid it?
show the list the contents of /etc/rc.local; the command is

cat /etc/rc.local

Richard
Juan Antonio Martinez
2017-02-27 11:38:23 UTC
Permalink
-----------------

El lun, 27-02-2017 a las 12:42 +0200, richard kweskin escribió:
............
Post by richard kweskin
Why is rc.local trying to be executed at shutdown? how can i avoid 
it?> 
show the list the contents of /etc/rc.local; the command is
 
      cat /etc/rc.local
 
Richard
....................
Here comes contents of /etc/rc.local

Note: we tried to made as little as posible mods into ltsp images from
standard one, so did our local modifications by mean of calling several
scripts from rc.local.
This worked fine in 14.04 fat clients, but fails for poweroff on 16.04
-----------------------------------
bash# cat /opt/ltsp/amd64_1604_fat/etc/rc.local
#!/bin/bash
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#

[ "Z$1" = "Zstop" ] && exit 0

# Nos aseguramos de que los puntos de montaje existen
mkdir -p /opt /home
mkdir -p /usr/local/local /mnt/arqo /mnt/vnx

# durante el arranque de ltsp se configura el /etc/hosts, anyadiendo
# la entrada "server" que idica el servidor nbd. 
# el fstab esta preparado para pedir montajes a server:/path_to_mount

#  montamos las entradas NFS del fstab
mount /usr/local/local
mount /mnt/arqo
mount /mnt/vnx
# Call remote rc.local if found
[ -x /usr/local/local/etc/rc.local ] && /usr/local/local/etc/rc.local

#required to tell init that everything was ok
exit 0
----------------------------

Contents of /usr/local/local/etc/rc.local

--------------------------
#!/bin/bash
BASERC=/usr/local/local/etc/rc.lab.d/

[ -d ${BASERC} ] || exit 0
[ "Z$1" = "Zstop" ] && exit 0

# create a temporary directory to store logs
TMPDIR="/tmp/logs_arranque"
mkdir -p ${TMPDIR}
chown root.root ${TMPDIR}
chmod 700 ${TMPDIR}
# some scripts change current umask, so preserve it
MASK=`umask`
LOG="$TMPDIR/rc.local.log"

# detect machine type
CLIENT_TYPE="HP"
/usr/sbin/dmidecode --type 0x0001 | grep -q Dell && CLIENT_TYPE="DELL"
/usr/sbin/dmidecode --type 0x0001 | grep -q VMware &&
CLIENT_TYPE="VMWARE"
/usr/sbin/dmidecode --type 0x0001 | grep -q Hewlett-Packard &&
CLIENT_TYPE="HP"
/usr/sbin/dmidecode --type 0x0001 | grep -q VirtualBox &&
CLIENT_TYPE="VBOX"
export CLIENT_TYPE

# detect Ubuntu version
LSB_RELEASE=`lsb_release -r | awk '{ print $2; }'`

for script in `ls -1 ${BASERC}/[0-9][0-9]-*`; do
        [ -x ${script} ] || continue;
        umask ${MASK}
        echo -e "\n\n\nEjecutando source $script (`date`)" | tee -a
$LOG
        . ${script} | tee -a $LOG
done

umask ${MASK}
# make sure that this script exits
exit 0
-----------------------------

So this script calls in turn our personalization scripts:
- set up language and keyboard
- prepare local hard disk to assure a clean client lab startup
- install additional packages
- fix ldap and pam_mount information
...
[***@maestro labdit_local-1604]# ls -l etc/rc.lab.d/
total 72
-rwxr-xr-x 1 root root  268 sep 14 09:56 00-hostname
-rwxr-xr-x 1 root root   76 ago 24  2016 00-loadkeys
-rwxr-xr-x 1 root root  179 dic  7 12:15 01-disable_gpe08
-rwxr-xr-x 1 root root 3075 feb 16 15:20 06-setup_home
-rwxr-xr-x 1 root root  498 oct 19 10:58 10-disk_format
-rwxr-xr-x 1 root root  970 ago 24  2016 25-aptget_install
-rwxr-xr-x 1 root root 1604 nov  3 10:42 30-configure_etc
-rwxr-xr-x 1 root root  727 ene 25 12:10 35-configure_menus
-rwxr-xr-x 1 root root 1780 ago 24  2016 40-acceso_remoto
-rwxr-xr-x 1 root root 2870 feb 23 11:30 50-mount_optfs
-rwxr-xr-x 1 root root  946 ene 26 09:33 60-configure_apps
-rwxr-xr-x 1 root root  697 feb 15 10:48 60-configure_desktop
-rwxr-xr-x 1 root root 2501 ene 16 10:50 60-configure_vnx
-rwxr-xr-x 1 root root  639 feb  9 09:22 60-startsop_daemons
-rwxr-xr-x 1 root root  669 nov 16 09:27 65-ntpdate
-rwxr-xr-x 1 root root 5407 feb 16 15:20 XX-disk_format
-rw-r--r-- 1 root root 1440 feb 15 11:03 XX-profiled_desktop_sh

As ltsp-update-image is a long-time consuming process, the idea is let
ltsp image as clean as possible, and don't create a new image unless we
really need to do it, but just change configuration
Post by richard kweskin
Post by Juan Antonio Martinez
I have a 200+ PC's students lab with Ubuntu 16.04-64bit 
gnome-based
LTSP fat clients. (local swap, nfs mounted home, ldap ids/gids )
Everything works fine... but cannot properly poweroff PC's, either
by gnome session poweroff button, or by mean of "sudo
/bin/poweroff",
or even pressing physical power button at PC
When initiating poweroff process user session goes out, gdm exits,
switch to console and initiate poweroff display sequence... and 
freezes
I've checked almost every combination of acpi=xxxx pxe grub
options; 
of
course PC bios have apm enabled
Also, tried to "systectl enable poweroff.target" in 
systemd  (¿why 
it's
disabled in LTSP fat client? ), check for proper nbd-client 
disconnect
disabled in shutdown, re-check that network interface does not 
execute
ifdown...
More tips: sudo /usr/lib/klibc/bin/poweroff works, but no idea
on
how
to include in systemd chain, or even if it's a good idea
So at this moment, the only way to propperly poweroff the fat clients
lab is... by unplugging power supply cable ( or press & hold 10 
seconds
power button )
Any hint?
Thanks in advance
Juan Antonio
Hi Juan
Do all 200+ clients have the same hardware and the same problem?
Let's 
see what kernel video driver is in use here.
If you want to see the kernel video driver use the command
     lspci -knn | grep -A2 VGA
in a terminal and display the results here on the list.
Also, do you have epoptes installed on the server?
Richard
(Answering to all)
- Yes: poweroff -fp works
  * Dell Optiplex 745/520/525
  * HP Compaq 6000/6300/8000
- Every clients use native intel video driver
- Seems that there is an issue with rc.local service: sometimes
shutdown screen shows a message: "A stop job is running for
/etc/rc.local" looping forever (no timeout)
Why is rc.local trying to be executed at shutdown? how can i avoid 
it?
show the list the contents of /etc/rc.local; the command is
      cat /etc/rc.local
Richard
-------------------------------------------------------------------
-----------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_____________________________________________________________________
      https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
For additional LTSP help,   try #ltsp channel on irc.freenode.net
richard kweskin
2017-02-28 01:19:23 UTC
Permalink
Post by Juan Antonio Martinez
Post by Juan Antonio Martinez
Post by Juan Antonio Martinez
I have a 200+ PC's students lab with Ubuntu 16.04-64bit 
gnome-based
LTSP fat clients. (local swap, nfs mounted home, ldap ids/gids )
Everything works fine... but cannot properly poweroff PC's, either
by gnome session poweroff button, or by mean of "sudo
/bin/poweroff",
or even pressing physical power button at PC
When initiating poweroff process user session goes out, gdm exits,
switch to console and initiate poweroff display sequence... and 
freezes
I've checked almost every combination of acpi=xxxx pxe grub
options; 
of
course PC bios have apm enabled
Also, tried to "systectl enable poweroff.target" in 
systemd  (¿why 
it's
disabled in LTSP fat client? ), check for proper nbd-client 
disconnect
disabled in shutdown, re-check that network interface does
not 
Post by Juan Antonio Martinez
Post by Juan Antonio Martinez
execute
ifdown...
More tips: sudo /usr/lib/klibc/bin/poweroff works, but no idea
on
how
to include in systemd chain, or even if it's a good idea
So at this moment, the only way to propperly poweroff the fat clients
lab is... by unplugging power supply cable ( or press & hold 10 
seconds
power button )
Any hint?
Thanks in advance
Juan Antonio
Hi Juan
Do all 200+ clients have the same hardware and the same problem?
Let's 
see what kernel video driver is in use here.
If you want to see the kernel video driver use the command
     lspci -knn | grep -A2 VGA
in a terminal and display the results here on the list.
Also, do you have epoptes installed on the server?
Richard
(Answering to all)
- Yes: poweroff -fp works
  * Dell Optiplex 745/520/525
  * HP Compaq 6000/6300/8000
- Every clients use native intel video driver
- Seems that there is an issue with rc.local service: sometimes
shutdown screen shows a message: "A stop job is running for
/etc/rc.local" looping forever (no timeout)
Why is rc.local trying to be executed at shutdown? how can i
avoid 
Post by Juan Antonio Martinez
it?
show the list the contents of /etc/rc.local; the command is
      cat /etc/rc.local
Richard
....................
Here comes contents of /etc/rc.local
Note: we tried to made as little as posible mods into ltsp images from
standard one, so did our local modifications by mean of calling several
scripts from rc.local.
This worked fine in 14.04 fat clients, but fails for poweroff on 16.04
-----------------------------------
bash# cat /opt/ltsp/amd64_1604_fat/etc/rc.local
#!/bin/bash
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
[ "Z$1" = "Zstop" ] && exit 0
# Nos aseguramos de que los puntos de montaje existen
mkdir -p /opt /home
mkdir -p /usr/local/local /mnt/arqo /mnt/vnx
# durante el arranque de ltsp se configura el /etc/hosts, anyadiendo
# la entrada "server" que idica el servidor nbd.
# el fstab esta preparado para pedir montajes a server:/path_to_mount
# montamos las entradas NFS del fstab
mount /usr/local/local
mount /mnt/arqo
mount /mnt/vnx
# Call remote rc.local if found
[ -x /usr/local/local/etc/rc.local ] && /usr/local/local/etc/rc.local
#required to tell init that everything was ok
exit 0
----------------------------
Contents of /usr/local/local/etc/rc.local
--------------------------
#!/bin/bash
BASERC=/usr/local/local/etc/rc.lab.d/
[ -d ${BASERC} ] || exit 0
[ "Z$1" = "Zstop" ] && exit 0
# create a temporary directory to store logs
TMPDIR="/tmp/logs_arranque"
mkdir -p ${TMPDIR}
chown root.root ${TMPDIR}
chmod 700 ${TMPDIR}
# some scripts change current umask, so preserve it
MASK=`umask`
LOG="$TMPDIR/rc.local.log"
# detect machine type
CLIENT_TYPE="HP"
/usr/sbin/dmidecode --type 0x0001 | grep -q Dell &&
CLIENT_TYPE="DELL"
/usr/sbin/dmidecode --type 0x0001 | grep -q VMware &&
CLIENT_TYPE="VMWARE"
/usr/sbin/dmidecode --type 0x0001 | grep -q Hewlett-Packard &&
CLIENT_TYPE="HP"
/usr/sbin/dmidecode --type 0x0001 | grep -q VirtualBox &&
CLIENT_TYPE="VBOX"
export CLIENT_TYPE
# detect Ubuntu version
LSB_RELEASE=`lsb_release -r | awk '{ print $2; }'`
for script in `ls -1 ${BASERC}/[0-9][0-9]-*`; do
[ -x ${script} ] || continue;
umask ${MASK}
echo -e "\n\n\nEjecutando source $script (`date`)" | tee -a
$LOG
. ${script} | tee -a $LOG
done
umask ${MASK}
# make sure that this script exits
exit 0
-----------------------------
- set up language and keyboard
- prepare local hard disk to assure a clean client lab startup
- install additional packages
- fix ldap and pam_mount information
...
total 72
-rwxr-xr-x 1 root root 268 sep 14 09:56 00-hostname
-rwxr-xr-x 1 root root 76 ago 24 2016 00-loadkeys
-rwxr-xr-x 1 root root 179 dic 7 12:15 01-disable_gpe08
-rwxr-xr-x 1 root root 3075 feb 16 15:20 06-setup_home
-rwxr-xr-x 1 root root 498 oct 19 10:58 10-disk_format
-rwxr-xr-x 1 root root 970 ago 24 2016 25-aptget_install
-rwxr-xr-x 1 root root 1604 nov 3 10:42 30-configure_etc
-rwxr-xr-x 1 root root 727 ene 25 12:10 35-configure_menus
-rwxr-xr-x 1 root root 1780 ago 24 2016 40-acceso_remoto
-rwxr-xr-x 1 root root 2870 feb 23 11:30 50-mount_optfs
-rwxr-xr-x 1 root root 946 ene 26 09:33 60-configure_apps
-rwxr-xr-x 1 root root 697 feb 15 10:48 60-configure_desktop
-rwxr-xr-x 1 root root 2501 ene 16 10:50 60-configure_vnx
-rwxr-xr-x 1 root root 639 feb 9 09:22 60-startsop_daemons
-rwxr-xr-x 1 root root 669 nov 16 09:27 65-ntpdate
-rwxr-xr-x 1 root root 5407 feb 16 15:20 XX-disk_format
-rw-r--r-- 1 root root 1440 feb 15 11:03 XX-profiled_desktop_sh
As ltsp-update-image is a long-time consuming process, the idea is let
ltsp image as clean as possible, and don't create a new image unless we
really need to do it, but just change configuration
I am out of my depth with this. I can only say that if a process is
stopped out of turn, leaving another process hanging, that would prevent
the clean shutdown from working in the speedy way we want. Now that
everyone here can see the file hopefully someone who understands it will
step forward to help. I apologize for not being more helpful.

Richard
Juan Antonio Martinez
2017-02-28 09:08:23 UTC
Permalink
Finally I found it:

A daemon started in rc.local was not launched with "&" at the end of
their command line. As result rc.local did not finish execution... so
systemd couldn't continue at poweroff procedure

Just run command in background and problem solved

Thanks for your time
Juan Antonio
Post by richard kweskin
-----------------
............
Post by richard kweskin
Why is rc.local trying to be executed at shutdown? how can i avoid 
it?> 
show the list the contents of /etc/rc.local; the command is
 
      cat /etc/rc.local
 
Richard
....................
Here comes contents of /etc/rc.local
Note: we tried to made as little as posible mods into ltsp images from
standard one, so did our local modifications by mean of calling several
 scripts from rc.local.
This worked fine in 14.04 fat clients, but fails for poweroff on 16.04
-----------------------------------
bash# cat /opt/ltsp/amd64_1604_fat/etc/rc.local
#!/bin/bash
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
[ "Z$1" = "Zstop" ] && exit 0
# Nos aseguramos de que los puntos de montaje existen
mkdir -p /opt /home
mkdir -p /usr/local/local /mnt/arqo /mnt/vnx
# durante el arranque de ltsp se configura el /etc/hosts, anyadiendo
# la entrada "server" que idica el servidor nbd. 
# el fstab esta preparado para pedir montajes a server:/path_to_mount
#  montamos las entradas NFS del fstab
mount /usr/local/local
mount /mnt/arqo
mount /mnt/vnx
# Call remote rc.local if found
[ -x /usr/local/local/etc/rc.local ] && /usr/local/local/etc/rc.local
#required to tell init that everything was ok
exit 0
----------------------------
Contents of /usr/local/local/etc/rc.local
--------------------------
#!/bin/bash
BASERC=/usr/local/local/etc/rc.lab.d/
[ -d ${BASERC} ] || exit 0
[ "Z$1" = "Zstop" ] && exit 0
# create a temporary directory to store logs
TMPDIR="/tmp/logs_arranque"
mkdir -p ${TMPDIR}
chown root.root ${TMPDIR}
chmod 700 ${TMPDIR}
# some scripts change current umask, so preserve it
MASK=`umask`
LOG="$TMPDIR/rc.local.log"
# detect machine type
CLIENT_TYPE="HP"
/usr/sbin/dmidecode --type 0x0001 | grep -q Dell &&
CLIENT_TYPE="DELL"
/usr/sbin/dmidecode --type 0x0001 | grep -q VMware &&
CLIENT_TYPE="VMWARE"
/usr/sbin/dmidecode --type 0x0001 | grep -q Hewlett-Packard &&
CLIENT_TYPE="HP"
/usr/sbin/dmidecode --type 0x0001 | grep -q VirtualBox &&
CLIENT_TYPE="VBOX"
export CLIENT_TYPE
# detect Ubuntu version
LSB_RELEASE=`lsb_release -r | awk '{ print $2; }'`
for script in `ls -1 ${BASERC}/[0-9][0-9]-*`; do
        [ -x ${script} ] || continue;
        umask ${MASK}
        echo -e "\n\n\nEjecutando source $script (`date`)" | tee -a
$LOG
        . ${script} | tee -a $LOG
done
umask ${MASK}
# make sure that this script exits
exit 0
-----------------------------
- set up language and keyboard
- prepare local hard disk to assure a clean client lab startup
- install additional packages
- fix ldap and pam_mount information
...
total 72
-rwxr-xr-x 1 root root  268 sep 14 09:56 00-hostname
-rwxr-xr-x 1 root root   76 ago 24  2016 00-loadkeys
-rwxr-xr-x 1 root root  179 dic  7 12:15 01-disable_gpe08
-rwxr-xr-x 1 root root 3075 feb 16 15:20 06-setup_home
-rwxr-xr-x 1 root root  498 oct 19 10:58 10-disk_format
-rwxr-xr-x 1 root root  970 ago 24  2016 25-aptget_install
-rwxr-xr-x 1 root root 1604 nov  3 10:42 30-configure_etc
-rwxr-xr-x 1 root root  727 ene 25 12:10 35-configure_menus
-rwxr-xr-x 1 root root 1780 ago 24  2016 40-acceso_remoto
-rwxr-xr-x 1 root root 2870 feb 23 11:30 50-mount_optfs
-rwxr-xr-x 1 root root  946 ene 26 09:33 60-configure_apps
-rwxr-xr-x 1 root root  697 feb 15 10:48 60-configure_desktop
-rwxr-xr-x 1 root root 2501 ene 16 10:50 60-configure_vnx
-rwxr-xr-x 1 root root  639 feb  9 09:22 60-startsop_daemons
-rwxr-xr-x 1 root root  669 nov 16 09:27 65-ntpdate
-rwxr-xr-x 1 root root 5407 feb 16 15:20 XX-disk_format
-rw-r--r-- 1 root root 1440 feb 15 11:03 XX-profiled_desktop_sh
As ltsp-update-image is a long-time consuming process, the idea is let
ltsp image as clean as possible, and don't create a new image unless we
really need to do it, but just change configuration 
Post by richard kweskin
Post by Juan Antonio Martinez
I have a 200+ PC's students lab with Ubuntu 16.04-64bit 
gnome-based
LTSP fat clients. (local swap, nfs mounted home, ldap
ids/gids
)
Everything works fine... but cannot properly poweroff PC's, either
by gnome session poweroff button, or by mean of "sudo
/bin/poweroff",
or even pressing physical power button at PC
When initiating poweroff process user session goes out, gdm exits,
switch to console and initiate poweroff display sequence... and 
freezes
I've checked almost every combination of acpi=xxxx pxe grub
options; 
of
course PC bios have apm enabled
Also, tried to "systectl enable poweroff.target" in 
systemd  (¿why 
it's
disabled in LTSP fat client? ), check for proper nbd-client 
disconnect
disabled in shutdown, re-check that network interface does not 
execute
ifdown...
More tips: sudo /usr/lib/klibc/bin/poweroff works, but no idea
on
how
to include in systemd chain, or even if it's a good idea
So at this moment, the only way to propperly poweroff the fat clients
lab is... by unplugging power supply cable ( or press & hold 10 
seconds
power button )
Any hint?
Thanks in advance
Juan Antonio
Hi Juan
Do all 200+ clients have the same hardware and the same
problem?
Let's 
see what kernel video driver is in use here.
If you want to see the kernel video driver use the command
     lspci -knn | grep -A2 VGA
in a terminal and display the results here on the list.
Also, do you have epoptes installed on the server?
Richard
(Answering to all)
- Yes: poweroff -fp works
  * Dell Optiplex 745/520/525
  * HP Compaq 6000/6300/8000
- Every clients use native intel video driver
- Seems that there is an issue with rc.local service: sometimes
shutdown screen shows a message: "A stop job is running for
/etc/rc.local" looping forever (no timeout)
Why is rc.local trying to be executed at shutdown? how can i avoid 
it?
show the list the contents of /etc/rc.local; the command is
      cat /etc/rc.local
Richard
-------------------------------------------------------------------
-----------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___________________________________________________________________
__
      https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
For additional LTSP help,   try #ltsp channel on irc.freenode.net
Juan Antonio Martinez
2017-03-01 10:14:33 UTC
Permalink
Filled a bug to systemd team, but perhaps may be of interest for
ltsp/NBD guys:

Bug: launching nbd-client (and other daemons) in rc.local blocks
shutdown in Ubuntu 16.04
https://github.com/systemd/systemd/issues/5497

Alkis Georgopoulos
2017-02-24 15:44:56 UTC
Permalink
Post by Juan Antonio Martinez
Also, tried to "systectl enable poweroff.target" in systemd (¿why it's
disabled in LTSP fat client? ), check for proper nbd-client disconnect
disabled in shutdown, re-check that network interface does not execute
ifdown...
Does `sudo poweroff -fp` work?
If so, then yes it's an issue with the things you mention above ^ and it
needs to be troubleshooted in your specific setup, as it doesn't happen
for everyone.
Loading...