Bug 334845 - kdm.log size 155MB with multiple "Invalid entry (missing ..."
Summary: kdm.log size 155MB with multiple "Invalid entry (missing ..."
Status: RESOLVED WORKSFORME
Alias: None
Product: kdelibs
Classification: Frameworks and Libraries
Component: kdecore (show other bugs)
Version: Git
Platform: Kubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: kdelibs bugs
URL:
Keywords:
: 216627 314759 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-05-15 22:26 UTC by pbea
Modified: 2024-05-04 19:56 UTC (History)
10 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description pbea 2014-05-15 22:26:08 UTC
Hello . . .

I am unable to locate a version number for kdm (KDE SC 4.13.1?), If you tell me where to find itI will send it.

My /var/log/kdm.log file is expanding at a astronomical amount. Now it is 155MG in size. I clean it every night. I am sure this is not normal.

The log starts with
********************************************************************************
Note that your system uses syslog. All of kdm's internally generated messages
(i.e., not from libraries and external programs/scripts it uses) go to the
daemon.* syslog facility; check your syslog configuration to find out to which
file(s) it is logged. PAM logs messages related to authentication to authpriv.*.
********************************************************************************


X.Org X Server 1.15.1
Release Date: 2014-04-13
X Protocol Version 11, Revision 0
Build Operating System: Linux 3.2.0-37-generic i686 Ubuntu
Current Operating System: Linux TheMacHine 3.13.0-26-generic #48-Ubuntu SMP Wed May 7 23:30:46 UTC 2014 i686
Kernel command line: BOOT_IMAGE=/boot/vmlinuz-3.13.0-26-generic root=UUID=6d200d2a-e740-4428-bc31-aa6beae5cff6 ro quiet splash vt.handoff=7
Build Date: 16 April 2014  01:40:08PM
xorg-server 2:1.15.1-0ubuntu2 (For technical support please see http://www.ubuntu.com/support) 
Current version of pixman: 0.30.2
	Before reporting problems, check http://wiki.x.org
	to make sure that you have the latest version.
Markers: (--) probed, (**) from config file, (==) default setting,
	(++) from command line, (!!) notice, (II) informational,
	(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
(==) Log file: "/var/log/Xorg.0.log", Time: Thu May 15 09:25:35 2014
(==) Using system config directory "/usr/share/X11/xorg.conf.d"
Initializing built-in extension Generic Event Extension
Initializing built-in extension SHAPE
Initializing built-in extension MIT-SHM
Initializing built-in extension XInputExtension
Initializing built-in extension XTEST
Initializing built-in extension BIG-REQUESTS
Initializing built-in extension SYNC
Initializing built-in extension XKEYBOARD
Initializing built-in extension XC-MISC
Initializing built-in extension SECURITY
Initializing built-in extension XINERAMA
Initializing built-in extension XFIXES
Initializing built-in extension RENDER
Initializing built-in extension RANDR
Initializing built-in extension COMPOSITE
Initializing built-in extension DAMAGE
Initializing built-in extension MIT-SCREEN-SAVER
Initializing built-in extension DOUBLE-BUFFER
Initializing built-in extension RECORD
Initializing built-in extension DPMS
Initializing built-in extension Present
Initializing built-in extension DRI3
Initializing built-in extension X-Resource
Initializing built-in extension XVideo
Initializing built-in extension XVideo-MotionCompensation
Initializing built-in extension SELinux
Initializing built-in extension XFree86-VidModeExtension
Initializing built-in extension XFree86-DGA
Initializing built-in extension XFree86-DRI
Initializing built-in extension DRI2
Loading extension GLX
(II) [KMS] Kernel modesetting enabled.
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 1: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 2: " "Invalid escape sequence "\¿"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 2: " "Invalid escape sequence "\G"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 3: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 4: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 5: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 7: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 8: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 9: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 10: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 11: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 12: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 14: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 15: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 16: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 17: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 18: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 19: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 20: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 21: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 22: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 23: " "Invalid escape sequence "\Ã"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 24: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 25: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 26: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 27: " "Invalid escape sequence "\"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 27: " "Invalid escape sequence "\y"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 28: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 29: " "Invalid escape sequence "\à"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 29: " "Invalid escape sequence "\ÿ"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 29: " "Invalid escape sequence "\"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 29: " "Invalid escape sequence "\¸"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 29: " "Invalid escape sequence "\<"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 29: " "Invalid escape sequence "\¶"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 29: " "Invalid escape sequence "\Ý"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 29: " "Invalid escape sequence "\ó"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 30: " Invalid entry (missing '=') 
an ends with
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91561: " "Invalid escape sequence "\m"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91562: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91563: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91564: " "Invalid escape sequence "\¸"." 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91565: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91566: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91567: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91568: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91569: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91570: " Invalid entry (missing ']') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91571: " Invalid entry (missing '=') 
"KConfigIni: In file /boot/initrd.img-3.13.0-26-generic, line 91572: " Invalid entry (missing '=') 
klauncher(1645) kdemain: No DBUS session-bus found. Check if you have started the DBUS server. 
kdeinit4: Communication error with launcher. Exiting!
kdmgreet(1470)/kdecore (K*TimeZone*): KSystemTimeZones: ktimezoned initialize() D-Bus call failed:  "Not connected to D-Bus server" 

kdmgreet(1470)/kdecore (K*TimeZone*): No time zone information obtained from ktimezoned 
QInotifyFileSystemWatcherEngine::addPaths: inotify_add_watch failed: No such file or directory
QFileSystemWatcher: failed to add paths: /tmp/0496585532/.config/ibus/bus
Bus::open: Can not get ibus-daemon's address. 
IBusInputContext::createInputContext: no connection to ibus-daemon 


Reproducible: Always

Steps to Reproduce:
1. turn on the machine
2.
3.
Actual Results:  
It just happens. . .

Expected Results:  
When I delete the kd.log file whe it gets too large, it just starts over again.

The kdm.log file should be in kilobytes not megabytes.
Comment 1 Christoph Feck 2014-05-16 12:50:37 UTC
Does this also happen with a freshly created user account? KDM should not try to parse files in /boot/, but that could happen with a faulty configuration.
Comment 2 pbea 2014-05-16 18:34:04 UTC
Thank You for the reply

This bug maybe a symptom of other things or not!

I created a new user and logged out and then back in again but opening the new user gave me an apparent frozen machine. The background wallpaper is visible. The mouse moves but absolutely nothing else works. Ctrl-Alt-Del has no effect. A power down is the only solution.

I reinstalled KDM - same result. I ran sudo dpkg-reconfigure kdm - same result.

The bottom line is any different user causes the machine to lockup.

Any suggestions?
Comment 3 FBrown 2014-06-10 12:13:26 UTC
Had this due to kdm symlinks to  the latest kernel initrd.img and vmlinuz from /boot/ existing in the root / directory, and kdm not seeming to like that in a similar way to this bug?

https://bugs.kde.org/show_bug.cgi?id=314759
Comment 4 Serhiy Zahoriya 2014-10-17 13:08:46 UTC
Yes, it's definitely the same bug. Confirming for Kubuntu with kdm 4.11.11-0ubuntu0.1. And it was like that for months now.
Comment 5 FBrown 2014-10-17 13:22:57 UTC
Well, I've since given up and switched to lightdm as I was fed up with huge waits for kdm to load and having to regularly clean out many GB size kdm.log files from /var/log/ due to the huge error lists this caused in those logs.

Maybe 4.11.12  fixed it? Not tested to be honest.
Comment 6 Oliver Winker 2014-10-17 18:51:54 UTC
Just for info, here a possible solution: 
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=747665
Comment 7 Christoph Feck 2014-10-18 01:47:54 UTC
Does that mean it is a distribution bug? I have never seen this on openSUSE, btw.
Comment 8 Oliver Winker 2014-10-18 08:54:52 UTC
Depends on the point of view ... . 

In my case I suspect it was triggered by a (bad) operation of locale.purge, that deleted some locale-files, that should not.

However the resulting behavior of the kde-runtime is maybe also discussable, like searching config files in "/" or reading binary files as config files. 

I think it could/should behave be a bit safer, even in a damaged, mis-configured, unspecified system environment (I know that's always easy to say, after something has happened ... so just my five cents ;). It was not easy to debug, however!)
Comment 9 Christoph Feck 2014-10-25 17:18:32 UTC
*** Bug 314759 has been marked as a duplicate of this bug. ***
Comment 10 Michael Pyne 2015-08-30 23:25:20 UTC
I've run into this off and on for years on Gentoo, with kdm ending up trying to read /bin/busybox (symlinked from /linuxrc) as a config file. I hadn't known about kde4-config trick, which reproduced the bug for me too, including this backtrace:

(gdb) bt
#0  0x00007ffff6b19d80 in __write_nocancel () from /lib64/libc.so.6
#1  0x00007ffff6ab339f in _IO_new_file_write () from /lib64/libc.so.6
#2  0x00007ffff6ab2a63 in new_do_write () from /lib64/libc.so.6
#3  0x00007ffff6ab399e in __GI__IO_file_xsputn () from /lib64/libc.so.6
#4  0x00007ffff6a8ac52 in buffered_vfprintf () from /lib64/libc.so.6
#5  0x00007ffff6a8578e in vfprintf () from /lib64/libc.so.6
#6  0x00007ffff6b3422a in __fprintf_chk () from /lib64/libc.so.6
#7  0x00007ffff787cdb1 in qt_message_output(QtMsgType, char const*) ()
   from /usr/lib64/qt4/libQtCore.so.4
#8  0x00007ffff7bb2ba4 in KConfigIniBackend::printableToString(KConfigIniBackend::BufferFragment*, QFile const&, int) () from /usr/lib64/libkdecore.so.5
#9  0x00007ffff7bb30e9 in KConfigIniBackend::parseConfig(QByteArray const&, KEntryMap&, QFlags<KConfigBackend::ParseOption>, bool) () from /usr/lib64/libkdecore.so.5
#10 0x00007ffff7bb43e4 in KConfigIniBackend::parseConfig(QByteArray const&, KEntryMap&, QFlags<KConfigBackend::ParseOption>) () from /usr/lib64/libkdecore.so.5
#11 0x00007ffff7b9da1a in KConfigPrivate::parseConfigFiles() () from /usr/lib64/libkdecore.so.5
#12 0x00007ffff7b9df59 in KConfig::KConfig(QString const&, QFlags<KConfig::OpenFlag>, char const*) ()
   from /usr/lib64/libkdecore.so.5
#13 0x00007ffff7cbba0f in KCurrencyCodePrivate::loadCurrency(QFileInfo const&, QString const&) ()
   from /usr/lib64/libkdecore.so.5
#14 0x00007ffff7cbc623 in KCurrencyCodePrivate::KCurrencyCodePrivate(QString const&, QString const&)
    () from /usr/lib64/libkdecore.so.5
#15 0x00007ffff7cbc68c in KCurrencyCode::KCurrencyCode(QString const&, QString const&) ()
   from /usr/lib64/libkdecore.so.5
#16 0x00007ffff7cbc6e7 in KCurrencyCode::isValid(QString const&, QFlags<KCurrencyCode::CurrencyStatus>) () from /usr/lib64/libkdecore.so.5
#17 0x00007ffff7cc9004 in KLocalePrivate::initCurrency() () from /usr/lib64/libkdecore.so.5
#18 0x00007ffff7cd692b in KLocalePrivate::initFormat() () from /usr/lib64/libkdecore.so.5
#19 0x00007ffff7cd45a4 in KLocalePrivate::init(QString const&, QString const&, QString const&, KSharedPtr<KSharedConfig>, KConfig*) () from /usr/lib64/libkdecore.so.5
#20 0x00007ffff7d1a4bc in KLocaleUnixPrivate::KLocaleUnixPrivate(KLocale*, QString const&, KSharedPtr<KSharedConfig>) () from /usr/lib64/libkdecore.so.5
---Type <return> to continue, or q <return> to quit---
#21 0x00007ffff7cc5fbd in KLocale::KLocale(QString const&, KSharedPtr<KSharedConfig>) ()
   from /usr/lib64/libkdecore.so.5
#22 0x00007ffff7c47783 in KGlobal::locale() () from /usr/lib64/libkdecore.so.5
#23 0x00007ffff7cdffd1 in KLocalizedString::toString() const () from /usr/lib64/libkdecore.so.5
#24 0x00007ffff7c3ffb3 in KCmdLineArgsStatic::findOption(QByteArray const&, QByteArray const&, int&, bool, bool&) () from /usr/lib64/libkdecore.so.5
#25 0x00007ffff7c436c0 in KCmdLineArgsStatic::parseAllArgs() () from /usr/lib64/libkdecore.so.5
#26 0x00007ffff7c4428a in KCmdLineArgs::parsedArgs(QByteArray const&) ()
   from /usr/lib64/libkdecore.so.5
#27 0x0000000000402af2 in main ()

I'm not exactly sure what's going on here, my working guess was that we tried to open a currency code desktop entry (in share/locale/currency) that didn't exist, but that doesn't explain how we end up reading symlinked and completely un-related files. Even still, the following patch (against KDE4 kdelibs) seems to avert further issues for me:

    diff --git a/kdecore/localization/kcurrencycode.cpp b/kdecore/localization/kcurrencycode.cpp
    index c406014..dd1c0c9 100644
    --- a/kdecore/localization/kcurrencycode.cpp
    +++ b/kdecore/localization/kcurrencycode.cpp
    @@ -107,6 +107,10 @@ KCurrencyCodePrivate::~KCurrencyCodePrivate()
     
     void KCurrencyCodePrivate::loadCurrency( const QFileInfo &currencyCodeFile, const QString &language )
     {
    +    if ( !currencyCodeFile.exists() ) {
    +        return;
    +    }
    +
         KConfig cgFile( currencyCodeFile.absoluteFilePath() );
     
         // If language is empty, means to stick with the global default, which is the default for any new KConfig

Maybe failing to load a currency code causes a chain of events that leads to searching within the current working directory for other potential config files? (E.g. the file being read is "linuxrc" in my case -- a possible config file). I'm not sure myself, but if this patch works I'll likely commit to KDE4 and see about forward porting.
Comment 11 Michael Pyne 2015-08-30 23:26:42 UTC
This isn't a KDM bug, kdm is just the innocent victim here.
Comment 12 Michael Pyne 2015-08-30 23:26:53 UTC
*** Bug 216627 has been marked as a duplicate of this bug. ***
Comment 13 Christoph Cullmann 2024-05-04 19:56:29 UTC
I don't think this stiff applies to KF 5 or 6.