sorry for being unclear.
with this config:
Code:
# LightDM - light Display Manager
#
# The display manager service manages the X servers running on the
# system, providing login and auto-login services
#
# based on gdm upstart script
description "LightDM Display Manager"
author "Robert Ancell <[email protected]>"
start on ((filesystem
and runlevel [!06]
and started dbus
and plymouth-ready
and (starting network-interface
or starting network-manager
or starting networking)
)
or runlevel PREVLEVEL=S)
stop on runlevel [016]
emits login-session-start
emits desktop-session-start
emits desktop-shutdown
script
if [ -n "$UPSTART_EVENTS" ]
then
# Check kernel command-line for inhibitors, unless we are being called
# manually
for ARG in $(cat /proc/cmdline); do
if [ "$ARG" = "text" ]; then
plymouth quit || :
stop
exit 0
fi
done
[ ! -f /etc/X11/default-display-manager -o "$(cat /etc/X11/default-display-manager 2>/dev/null)" = "/usr/bin/lightdm" -o "$(cat /etc/X11/default-display-manager 2>/dev/null)" = "/usr/sbin/lightdm" ] || { stop; exit 0; }
if [ "$RUNLEVEL" = S -o "$RUNLEVEL" = 1 ]
then
# Single-user mode
plymouth quit || :
exit 0
fi
fi
exec lightdm
end script
post-start script
sleep 5
clear > /dev/tty7
end script
post-stop script
clear > /dev/tty7
sleep 1
if [ "$UPSTART_STOP_EVENTS" = runlevel ]; then
initctl emit desktop-shutdown
fi
end script
I also end upo at the login terminal and XBMC or the Graphical UI is not started.
Which logs would you need?
Revert back to the original file and add
Code:
start on ((filesystem
and runlevel [!06]
and started dbus
and net-device-up IFACE!=lo)
or runlevel PREVLEVEL=S)
instead
should I also rermove the line:
and plymouth-ready
?
No, just add this "and net-device" thingy at the right position.
That seems to have done the trick thank you very much!
I attempted to make the fixes described here, but the only thing that worked consistently was to add sleep statements in lightdm.conf. Changing the "start on" section did not fix my problem (mysql connection fails, logging off and back on fixes it).
Is there any way to troubleshoot the "start on" section not waiting for the network, as expected?
Nobody knows what you have added.
Provide your conf and also the output of ifconfig after the system is fully up.
I deserved that. Too much time in IT, I forget what it is like to be a user
The device has a static IP lease in my router, and will always be 192.168.2.51. It is gigabit ethernet, not wi-fi.
What I have learned:
- If I uncomment the sleep statement in the script section, all is well
- If I exit XBMC and log back in, all is well
- Another system with similar hardware in another room does not exhibit this behavior
Code:
# LightDM - light Display Manager
#
# The display manager service manages the X servers running on the
# system, providing login and auto-login services
#
# based on gdm upstart script
description "LightDM Display Manager"
author "Robert Ancell <[email protected]>"
start on ((filesystem
and runlevel [!06]
and started dbus
and plymouth-ready
and (starting network-interface
or starting network-manager
or starting networking)
)
or runlevel PREVLEVEL=S)
stop on runlevel [016]
emits login-session-start
emits desktop-session-start
emits desktop-shutdown
script
# sleep 10
if [ -n "$UPSTART_EVENTS" ]
then
# Check kernel command-line for inhibitors, unless we are being called
# manually
for ARG in $(cat /proc/cmdline); do
if [ "$ARG" = "text" ]; then
plymouth quit || :
stop
exit 0
fi
done
[ ! -f /etc/X11/default-display-manager -o "$(cat /etc/X11/default-display-manager 2>/dev/null)" = "/usr/bin/lightdm" -o "$(cat /etc/X11/default-display-manager 2>/dev/null)" = "/usr/sbin/lightdm" ] || { stop; exit 0; }
if [ "$RUNLEVEL" = S -o "$RUNLEVEL" = 1 ]
then
# Single-user mode
plymouth quit || :
exit 0
fi
fi
exec lightdm
end script
post-start script
sleep 5
clear > /dev/tty7
end script
post-stop script
clear > /dev/tty7
sleep 1
if [ "$UPSTART_STOP_EVENTS" = runlevel ]; then
initctl emit desktop-shutdown
fi
end script
Code:
eth0 Link encap:Ethernet HWaddr d0:50:99:1d:04:d6
inet addr:192.168.2.51 Bcast:192.168.2.255 Mask:255.255.255.0
inet6 addr: fe80::d250:99ff:fe1d:4d6/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:359 errors:0 dropped:0 overruns:0 frame:0
TX packets:307 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:34362 (34.3 KB) TX bytes:44249 (44.2 KB)
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:65536 Metric:1
RX packets:106 errors:0 dropped:0 overruns:0 frame:0
TX packets:106 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:8115 (8.1 KB) TX bytes:8115 (8.1 KB)
Fritsch already posted the answer in post #17
I originally tried the fix in message #17, but booted straight to a console. Double checking the .conf file, it looks like I had a typo. All is well, thanks!
Here is the file that works for me, for anyone suspecting typos:
Code:
# LightDM - light Display Manager
#
# The display manager service manages the X servers running on the
# system, providing login and auto-login services
#
# based on gdm upstart script
description "LightDM Display Manager"
author "Robert Ancell <[email protected]>"
start on ((filesystem
and runlevel [!06]
and started dbus
and plymouth-ready
and net-device-up IFACE!=lo)
or runlevel PREVLEVEL=S)
stop on runlevel [016]
emits login-session-start
emits desktop-session-start
emits desktop-shutdown
script
# sleep 10
if [ -n "$UPSTART_EVENTS" ]
then
# Check kernel command-line for inhibitors, unless we are being called
# manually
for ARG in $(cat /proc/cmdline); do
if [ "$ARG" = "text" ]; then
plymouth quit || :
stop
exit 0
fi
done
[ ! -f /etc/X11/default-display-manager -o "$(cat /etc/X11/default-display-manager 2>/dev/null)" = "/usr/bin/lightdm" -o "$(cat /etc/X11/default-display-manager 2>/dev/null)" = "/usr/sbin/lightdm" ] || { stop; exit 0; }
if [ "$RUNLEVEL" = S -o "$RUNLEVEL" = 1 ]
then
# Single-user mode
plymouth quit || :
exit 0
fi
fi
exec lightdm
end script
post-start script
sleep 5
clear > /dev/tty7
end script
post-stop script
clear > /dev/tty7
sleep 1
if [ "$UPSTART_STOP_EVENTS" = runlevel ]; then
initctl emit desktop-shutdown
fi
end script
Good - then let's now drink some beer and wait for the network card.
Not really sure that works. As the original problem here is, that the network device is not up at all. So it's not possible to send anything over the non existing connection.
That should be handled, wake-on-acecss will start out with waiting for network (if more than one adapter will even wait for the correct one, not just first available)
After that, a ping is done and for a 24/7 server nothing more is needed and an early return follows
(2014-10-24, 09:16)t4_ravenbird Wrote: [ -> ]That should be handled, wake-on-acecss will start out with waiting for network (if more than one adapter will even wait for the correct one, not just first available)
After that, a ping is done and for a 24/7 server nothing more is needed and an early return follows
I confirm it works that way. I'm using mysql database and before using wake-on-access I had to use a scrit to wait for the network to be up, as mentionned here before. Since using wake-on-access, it is handled directly by this fonction (cf wakeonlan.xml:
http://kodi.wiki/view/Wake_on_lan)