Announcement

Collapse
No announcement yet.

KDM service will not start after update locales [SOLVED]

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    KDM service will not start after update locales [SOLVED]

    Hi, this is my first post and I have to congratulate the nice work being done here.
    Kubuntu is a really nice option and totally free. I came from Suse and got tired from their policies and narrow options.
    Anyways, yesterday Adept reported new packages available for upgrade and I've committed them with no problem at all.
    Today, my kdm did not start for any reason. So here is my post, I hope it could help somebody here...

    In a closer look, I saw the error bellow when I tried to run it manually
    sed: -e expression #1, char 32: unterminated `s' command

    Despite the crypted message, I found the error on file /etc/init.d/kdm at line

    Code:
    $USESYSTEMLOCALE && sed -i "s|^#\?Language=.*|Language=`grep -re "LANG=" /etc/default/locale | awk 'BEGIN { FS = "[\\"|.]" } { print $2 }'`|" $KDMCFG
    The file also reports on a comment placed before that code:
    # we get the system default locale if USESYSTEMLOCALE is set to true

    All right, so seems the line is not critical. That way, I comment it out (I placed a # before the code line) and kdm is working again.
    As a record, I'm using
    Kubuntu 8.04
    kdebase-bin 4:3.5.9-0ubuntu7.2 (what is this? kde 3 or 4? if 3, why is that versioning for? so confusing...)
    kdm 4:3.5.9-0ubuntu7.2


    and this is my last aptitude log
    Aptitude 0.4.9: log report
    Wed, Jun 18 2008 21:17:18 -0300

    IMPORTANT: this log only lists intended actions; actions which fail due to
    dpkg problems may not be completed.

    Will install 28 packages, and remove 0 packages.
    496kB of disk space will be freed
    ================================================== =============================
    [UPGRADE] firefox 3.0~rc1+nobinonly-0ubuntu0.8.04.1 -> 3.0+nobinonly-0ubuntu0.8.04.1
    [UPGRADE] firefox-3.0 3.0~rc1+nobinonly-0ubuntu0.8.04.1 -> 3.0+nobinonly-0ubuntu0.8.04.1
    [UPGRADE] hal-info 20080317+git20080318-1ubuntu4 -> 20080508+git20080601-0ubuntu0.8.04
    [UPGRADE] language-pack-pt 1:8.04+20080527.1 -> 1:8.04+20080527.2
    [UPGRADE] language-pack-pt-base 1:8.04+20080527.1 -> 1:8.04+20080527.2
    [UPGRADE] openoffice.org-base-core 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-calc 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-common 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-core 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-draw 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-help-en-gb 1:2.4.0-3ubuntu1 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-help-en-us 1:2.4.0-3ubuntu1 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-help-pt 1:2.4.0-3ubuntu1 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-help-pt-br 1:2.4.0-3ubuntu1 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-impress 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-kde 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-l10n-common 1:2.4.0-3ubuntu1 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-l10n-en-gb 1:2.4.0-3ubuntu1 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-l10n-en-za 1:2.4.0-3ubuntu1 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-l10n-pt 1:2.4.0-3ubuntu1 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-l10n-pt-br 1:2.4.0-3ubuntu1 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-style-crystal 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-style-human 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openoffice.org-writer 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] openssl-blacklist 0.3.3+0.4-0ubuntu0.8.04.1 -> 0.3.3+0.4-0ubuntu0.8.04.3
    [UPGRADE] python-uno 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] ttf-opensymbol 1:2.4.0-3ubuntu6 -> 1:2.4.1-1ubuntu1
    [UPGRADE] xulrunner-1.9 1.9~rc1+nobinonly-0ubuntu1~8.04.2 -> 1.9+nobinonly-0ubuntu0.8.04.1
    ================================================== =============================

    Log complete.


    Perhaps there is some relation between the upgrade and the behavior seen before.
    If someone is interested and wants further details, please fell free to ask.
    See ya

    #2
    Re: KDM service will not start after upgrade some packages

    if u get no fix - i suggest removing kdm and installing gdm. I myself think kdm sucks compared to gdm.
    Wanna know more about Me and My computer then click here

    Comment


      #3
      Re: KDM service will not start after update locales [SOLVED]

      Hi nowshining, you're right - that's a good choice too.
      I did a standard Kubuntu installation, so kdm came automatically.
      To tell you the truth, I've never had trouble with kdm. Suse uses it, but seems Suse has more experience handling kdm and locales than Ubuntu/Kubuntu.

      Anyways, I found the trouble and it is not related to the upgrade I've done previously.
      What happen is I installed a new locale to test my developing projects. That way, my /etc/default/locale was initially just
      LANG="en_US.UTF-8"

      And nowadays is
      #LANG="en_US.UTF-8"
      LANG="pt_BR.UTF-8"


      Yes, I'm Brazilian
      So, that change breaks /etc/init.d/kdm because the script is not expecting two lines matching "LANG=" -> what a shame...

      Question: Is it written anywhere that /etc/default/locale must have only one "LANG=" inside or it cannot be commented out?

      That way, the code I posted before has to be change. I'll give you two options
      $USESYSTEMLOCALE && sed -i "s|^#\?Language=.*|Language=`grep -re "LANG=" /etc/default/locale | grep -v "^#" | awk 'BEGIN { FS = "[\\"|.]" } { print $2 }'`|" $KDMCFG

      or my favorite
      $USESYSTEMLOCALE && sed -i "s|^#\?Language=.*|Language=`grep -re "LANG=" /etc/default/locale | awk 'BEGIN { FS = "[\\"|.]" } /^[^#]/ { print $2 }'`|" $KDMCFG

      Modifications are bold-ed. Sorry because I cannot bold something inside [ code ] tags, that's why I change the convention presented on the first post.

      Well, that's it. I hope it helps. Bye

      Comment

      Working...
      X