Gnome wont start if date is incorrect.

Bug #23426 reported by Pont
Affects Status Importance Assigned to Milestone
gnome-session (Ubuntu)
Fix Released
Ubuntu Desktop Bugs

Bug Description


 - If the date set is behind what i suspect is the gnome release date gnome
won't start.
 - Brown background will appear but gnome-panel will not start (even when
started through failsafe term)
 - If gnome-panel is started through failsafe term it will freeze.

To Reproduce:

  - Set date to 'Jan 04' then attempt to start gnome.

Revision history for this message
Pont (paul-esson) wrote :

Changed Priority to 4 and Severity to trival because it is not a problem that
stops users from using there computers (if they are aware of fix).

Revision history for this message
Matt Zimmerman (mdz) wrote :

Hmm, we've seen some other bugs with similar symptoms (background displays, but
the full desktop never loads). Perhaps they share the same cause...

Revision history for this message
Daniel Holbach (dholbach) wrote :

Just fyi: has a (possible)
bonobo crasher for an incorrectly set date.

Revision history for this message
Daniel Holbach (dholbach) wrote :

*** Bug 23378 has been marked as a duplicate of this bug. ***

Revision history for this message
sam tygier (samtygier) wrote :

Still happens in breezy.

after a power outage my system clock was reset to jan 1904 (this is where mac
clocks go back to when reset or when the pram battery runs out(when a machine is
about 5 years old))

the system makes it to the log in screen, then i did user name and pass word,
enter, and it hung on a brown screen

killall gnome-session on crtl-alt-f1 kills the session and gets you back to gdm

gnome failsafe does not load either

xfce and openbox load ok. from them one can start most gnome apps, except
nautilus and gnome-panel. these give no hint that the date is the problem

just a warning somewhere would be enough to help people, other wise it is very
hard to notice the date is wrong.

is this just a powerpc bug? do other machines ever get their clocks reset?

Revision history for this message
Daniel Holbach (dholbach) wrote :

gnome-session is more likely to be the culprit that gnome-common.

Revision history for this message
Pont (paul-esson) wrote :

(In reply to comment #6)
> gnome-session is more likely to be the culprit that gnome-common.

When this failed on me I initially run failsafe-term and attempted to run gnome
in the way discribed on nat friedman's blog
( This also didn't work for
me with gnome-panel freezing up when started.

Note. All the people experianeing this problem seem to be mac users with system
clocks that have reset to 1904

I can't quite remember but I think my system clock may have also been on 1904,
this is before the linux Epoch (00:00:00 UTC, January 1, 1970) and the problem
perhaps could relate to that ?

Could the solution be to provide users with a message "Your system clock is set
to $date please enter your root password to change time and date"

Revision history for this message
sam tygier (samtygier) wrote :

i have been avoiding low level programming for a while, but i imagine this could
be due to gnome holding dates as unsinged numbers. prehaps making these signed
would allow gnome to boot with any date.

the question is 'should gnome boot if the date is set to before 1970?' one could
argue that it is a bug that gnome won't work in this date range, but as it will
never be run in that date range does it matter? is there a legitimate reason
that someone would want their clock set to < 1970?

if this an easy fix it may as well be done, if not then a warning would be good.

can anyone confirm on x86?

Revision history for this message
Mtrettenbach (mtrettenbach) wrote :

I posted 17201 before learning that the problem was in my inattention to my iBook's 1904 date
rather than in the CD. I can't get Windows 2000 to set my PIII/667 back to 1904, only back to
1980. But I can report that Ubuntu 5.10 live for i386 happily deals with my setting the clock
back to 1980 in W2k, and nonetheless goes all the way to a fully functioning Gnome desktop.

Revision history for this message
Sebastian Dröge (slomo) wrote :

I can confirm this... starting GNOME with the clock set to 1904 is impossible.

nautilus, gnome-settings-daemon and gnome-panel show an error dialog saying that they can't register with bonobo and that's it. some months ago there were no error dialogs but nothing happened at all

Changed in gnome-session:
status: Unconfirmed → Confirmed
Revision history for this message
Sebastian Dröge (slomo) wrote :

This is on an ibook g4 too btw

Revision history for this message
indypende (indypende-deactivatedaccount) wrote :

I can't access the gnome session in ubuntu (Ubuntu Dapper PPC on powerbook G4) for a bonobo-activation-server fail! I discover that this problem is generated by the time and date that are before the date and time of last reboot/shutdown. This appear when i boot the PB without a network connection. I googled a little beat and find that a problem affect the /etc/init.d/ and clock commands. I try resolving and i see that on /dev there's not a rtc "file" needed to sync the clock.

All i made to solve is:
create the /dev/rtc lynking /dev/.static/dev/rtc
# sudo ln -s /dev/.static/dev/rtc /dev/rtc
with a network connection sync the clock
# sudo /etc/init.d/ restart
and then
#sudo clock

This temporary solve until i unplug the battery of PB. No one can help me?

Revision history for this message
Sebastien Bacher (seb128) wrote :

indypende, you should open a different bug for the issue different packages may have different maintainers and it's better to use the right place and talk to the right people to get something fixed

Revision history for this message
indypende (indypende-deactivatedaccount) wrote :

Sebastien Bacher, is the same problem, read the starter of the bug. i've the same situation.

Revision history for this message
Sebastien Bacher (seb128) wrote :

your problem is the clock changing, the bug is not about that but about how GNOME being bugged then

Revision history for this message
Pont (paul-esson) wrote :

For me some of the latest updates for Dapper seem to have fixed this for me and I now have the issues described in Bug #38845.

I had this same issue in the 5.04 days.

Can anyone else confirm that gnome is now starting as described in #38845 and not just displaying brown ?

Revision history for this message
LittleBuddha (arnkell2) wrote :

I have a Wallstreet G3 Powerbook with a dead PRAM and my symptomps are the same as in Bug #38845.

Could this not be fixed by setting some kind of date redefinition in the init file for GDM that runs at startup. Something like, if date< 1970 then set date to something after 1970.

Just my two noob cents.

Revision history for this message
sam tygier (samtygier) wrote :

i have spoken by email to the developer of hwclock.

he said he will change Hwclock in the next release to recognize a negative result from mktime() as invalid, so it will recognize a pre-1970 value of the hardware clock as an error.

a quicker solution would be putting something in /etc/init.d/ to detect pre 1970 dates.

Revision history for this message
sam tygier (samtygier) wrote :

i spotted this in the gnome-session 2.19.2-0ubunut1 change log

 "Warn the user if the clock is totally wrong and let him launch a
 config tool"

i'll test it when i get a chance

Revision history for this message
Sebastien Bacher (seb128) wrote :
Download full text (3.5 KiB)

This upload fixes the bug:

 gnome-session (2.19.2-0ubuntu1) gutsy; urgency=low
   * New upstream version:
     Session Manager
     - Use g_usleep() instead of usleep()
     - Don't hardcode start of assistive technologies software
     - Fix splash screen in RTL environments
     - Improve splash screen on old displays
     - Make it possible to use a shaped window for the splash screen
     - Display the name of the started application in splash screen even if
       there's no icon
     - Don't use deprecated functions
     - Don't hardcode esound for the sound daemon
     - Make the fade on logout faster
     - Plug leaks
     - Warn the user if he logs in as root
     - Warn the user if the clock is totally wrong and let him launch a
       config tool
     - Change strings about saving the session to be more user-friendly
     - Remove workaround that chrooted esd to / (fixed in esd)
     - Make it possible to save a session with multiple clients that are the
       same program
     - Use the new socket path for GDM
     Session Properties Dialog
     - Use Add/Remove instead of New/Delete for handling startup programs
     - Show the comments in the startup programs list (Ubuntu: #102362)
     - Change strings about saving the session to be more user-friendly
     - Make it possible to sort the program lists by clicking on the headers
     - Create a non-localized version of the Comment field in .desktop files
       if necessary
     - Remove xrdb check
     - Build fixes
     - Require glib 2.12.0
     - Add --with-time-utility configure flag to set the executable that is
       used to configure the time of the computer
     - Don't require libgnome-desktop anymore
     - Add support for beryl in gnome-wm
   * Sync with Debian
   * Renamed some patches to use .patch instead of .diff
   * debian/
     - Build-Depends on sharutils
     - don't Build-Depends on sng
     - don't Recommends desktop-base
     - gnome-session Depends on gnome-power-manager
     - maintainer is the Ubuntu Desktop Team
     - Suggests gnome-user-guide | gnome2-user-guide
   * debian/gconf-defaults:
     - don't set the default from it, ubuntu-artwork does that now
   * debian/gnome-session.install:
     - don't install the debian splash
   * debian/gnome-wm:
     - dropped, use and patch the upstream version instead
   * debian/patches/02_no_warning_crash.patch:
     - don't crash on warning, users expect stability
   * debian/patches/03_powermanagement.patch:
     - powermanagement features.
   * debian/patches/09_splash_hide.patch:
     - fix some issue with splashscreen staying on screen when not needed.
   * debian/patches/10_update_notifier:
     - added update-notifier to the list of known applications
       (closes ubuntu #9316)
   * debian/patches/11_session_dialog.patch:
     - new session dialog by Manu Cornet <email address hidden>
   * debian/patches/19_gnome-wm-tweaking.patch:
     - set the current wm to gconf and get the default one from gconf
     - use the x-terminal-emulator instead of xterm for gnome-wm
   * debian/patches/20_dont_fade_on_ltsp_cl...


Changed in gnome-session:
status: Confirmed → Fix Released
Changed in gnome-session:
assignee: dholbach → desktop-bugs
Revision history for this message
Mark Purcell (msp) wrote :

This is a common problem on powerpc ibook's once the NVRAM battery goes flat.

Apparently this has been discussed with upstream:


This patch is a hack, but you get the idea:

--- 2009-05-16 14:26:54.000000000 +1000
+++ 2009-05-16 14:23:11.000000000 +1000
@@ -38,6 +38,12 @@
     . /lib/lsb/init-functions
     verbose_log_action_msg() { [ "$VERBOSE" = no ] || log_action_msg "$@"; }

+ if `hwclock | grep -q 1904`; then
+ log_warning_msg "NVRAM Battery Clock flat (date 1904)"
+ log_action_msg "Setting hwclock date to 2009-5-16"
+ hwclock --set --date 2009-5-16
+ fi
     [ "$GMT" = "-u" ] && UTC="yes"
     case "$UTC" in
        no|"") GMT="--localtime"

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.