"Error found when loading /etc/profile"

16,113

Solution 1

Same thing happened to my when upgrading Mate to 17.10.

I went to System -> Preferences -> Look and Feel -> Language Support.

I'd previously selected English (UK) as my menu/windows language so on first opening this up I was prompted to upgrade, which I did.

My intention, and what I went on to do, was to change the "keyboard input method system" from "XIM" to "None". Rebooted, and that seemed to clear the error message at login without any other ill effects - so far!

My logic... I don't have ibus on my machine and I didn't see the need for it if I don't need exotic fonts. My default display manager is lightdm, so that would trip the first condition in the 21_ibus.rc file, taking me to line 6, which seems to disable the IBUS_SYNC mode and force XIM. Again, not installing ibus, so can't use the ibus-deamon, therefore I can't have the XIM option - so I switched the keyboard option, as indicated above, and that seemed to work.

To do that on KDE open a terminal and type

 im-config -n none

Suspect it's a minor configuration issue, but would welcome learning if there's a more robust solution.

Solution 2

I had the same issue after upgrade to 17.10. Temporary work around by set the keyboard input method system to none in language support.

Solution 3

Bruni: I don't use KDE, nor fcitx, so can't directly check, but nearest thing I can find to help show you options I was referring to is here...

http://www.makeuseof.com/tag/write-language-linux/

...where you can see the "keyboard input method system" for GTK, and, what I assume is the equivalent "Configure input method" for KDE.

Again, I don't have ibus, so there's no point trying to start xim server from ibus deamon, which is why selecting "None" is a convenient fix for my requirements. If you have fcitx installed and you have fcitx set in your "Configure input method" and you're still tripping an ibus trap then there's a configuration problem somewhere down the /etc/profile.

Solution 4

You appear to be affected by this bug I would suggest that you subscribe to it so that you can be notified about progress. You should also click and answer the "Does this bug affect you?" question so that the developers can get an idea of the extent of the issue.

Share:
16,113

Related videos on Youtube

Bruni
Author by

Bruni

My about me is currently blank

Updated on September 18, 2022

Comments

  • Bruni
    Bruni almost 2 years

    The following problem persists even after upgrading from 17.10 to 18.04:

    After upgrading my Kubuntu 17.04 to 17.10 by running

    do-release-upgrade
    

    I get the following error message after each reboot.

    Error found when loading /etc/profile:\n\n/usr/share/im-    
    config/data/21_ibus.rc line 6: /usr/bin/ibus-daemon: No such     
    file or directory\n\nAs a result the session will not be configured correctly.   
    You should fix the problem as soon as feasible.  
    

    IMG:

    cat -n /usr/share/im-config/data/21_ibus.rc
    

    Line 6 reads:

    IBUS_ENABLE_SYNC_MODE=0 /usr/bin/ibus-daemon --daemonize --xim --address 'unix:tmpdir=/tmp/ibus'
    

    Unfortunately I don't know what this is. Indeed there is no file /usr/bin/ibus-daemon

    Also:

    bruni@Inspiron-5547:~$ sudo apt purge ibus
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    Package 'ibus' is not installed, so not removed
    0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
    

    How could I fix the problem as soon as feasible?

    why is there a /usr/share/im-config/data/21_ibus.rc used when ibus is not installed?

    EDIT I guess the culprit in my /etc/profile is the file /etc/profile.d/input-method-config.sh

    This reads:

    # /etc/profile.d/input-method-config.sh              
    #                                                    
    # This is a temporary measure which works around     
    # https://launchpad.net/bugs/1720250                 
    
    if [ -z "$XDG_CURRENT_DESKTOP" -o -n "$GTK_IM_MODULE" ]; then                                             
        return                                           
    fi                                                   
    
    . /etc/X11/Xsession.d/70im-config_launch             
    if [ "$IM_CONFIG_PHASE" = 1 ]; then                  
        export IM_CONFIG_PHASE=2                         
        . /usr/share/im-config/xinputrc.common           
        if [ -r "$IM_CONFIG_XINPUTRC_USR" ]; then        
            . $IM_CONFIG_XINPUTRC_USR                    
        elif [ -r "$IM_CONFIG_XINPUTRC_SYS" ]; then      
            . $IM_CONFIG_XINPUTRC_SYS                    
        fi                                               
        export XMODIFIERS                                
        export GTK_IM_MODULE                             
        export QT_IM_MODULE                              
        export QT4_IM_MODULE                             
        export CLUTTER_IM_MODULE                         
    fi                                    
    

    also:

    echo $XDG_CURRENT_DESKTOP                                                
    KDE                               
    

    and

    echo $GTK_IM_MODULE
    ibus
    

    I guess the problem is that $GTK_IM_MODULE returns ibus, even though ibus is not installed and not used.

    Installing ibus removes the problem described in the question at hand, but leads to the more severe problem described in this question, so I removed ibus again.

    • ravery
      ravery over 6 years
      17.10 uses a new desktop and wayland, A reboot will likely solve the issue
    • Bruni
      Bruni over 6 years
      @ravery I don't know if the new desktop should be relevant as I use Kubuntu (KDE), but I will reboot as soon as my backup is in place.
    • ravery
      ravery over 6 years
      KDE does not use wayland; however, the update still might have changed the profile.
    • Bruni
      Bruni over 6 years
      @ravery Reboot did not solve the problem.
    • Sergey Ponomarev
      Sergey Ponomarev over 5 years
      I got the same error after do-release-upgrade from 18.04 to 18.10
  • Bruni
    Bruni over 6 years
    I am not sure this is indeed the case. I am able to write in Greek, english and German (Αβγδςüäö) without any problems. Also this bug seems to be quite old whereas I have encountered the above message only after updating from 17.04 to 17.10.
  • Elder Geek
    Elder Geek over 6 years
    @Bruni I'm not certain either, it could be a regression, or not. However as the bug was never Assigned and I can't seem to find anything that states it was fixed, it seemed a logical response. Perhaps someone will come along and provide an answer that's more to your liking. Cheers! :-)
  • Bruni
    Bruni over 6 years
    Where is that setting in Kubuntu?
  • Bruni
    Bruni over 6 years
    Thank. I am aware of these settings. However, there is no option to select the backend.
  • Bruni
    Bruni over 5 years
    Hello and welcome to askubuntu. As already mentioned in the question, installing ibus was not an option for me, as this led to a much more severe problem.