While starting dbus-daemon on a 32-bit linux host and it invokes fstat to load /etc/dbus-1/system.conf through NFS. If system.conf was created with a large indoe number on 64-bit host. The above fstat invoking failed. Here is the log of strace: ............ root@qemu3:~# df Filesystem 1K-blocks Used Available Use% Mounted on 10.0.2.2:/buildarea/raid0/hjia/wrlinux-x-master-1120/build-20151230-qemux86/export/dist 15623790592 8566374092 7057416500 55% / root@qemu3:~# cat /proc/cmdline console=ttyS0,115200 ip=dhcp root=/dev/nfs nfsroot=10.0.2.2:/buildarea/raid0/hjia/wrlinux-x-master-1120/build-20151230-qemux86/export/dist,nfsvers=3,port=3349,mountprog=21411,nfsprog=11411,udp,mountport=3348 rw clock=pit oprofile.timer=1 TCF=1 root@qemu3:~# ls -i /etc/dbus-1/system.conf 62318090305 /etc/dbus-1/system.conf root@qemu3:~# strace /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation |open("/etc/dbus-1/system.conf", O_RDONLY) = 4 |fstat64(4, {st_mode=S_IFREG|0644, st_size=3340, ...}) = 0 |close(4) = 0 |close(3) = 0 |write(2, "Failed to start message bus: Fai"..., 109Failed to start message bus: Failed to stat "/etc/dbus-1/system.conf": Value too large for defined data type |) = 109 |exit_group(1) = ? |+++ exited with 1 +++ ............
In this situation, we should support large-file for stat64. Add marco AC_SYS_LARGEFILE to do the detection at configure time. It can be disabled by configuring with the `--disable-largefile' option. Also file a bug and send patch to upstream: https://bugs.freedesktop.org/show_bug.cgi?id=93545 https://bugs.freedesktop.org/attachment.cgi?id=120747 //Hongxu
It refers: http://www.delorie.com/gnu/docs/autoconf/autoconf_67.html http://www.gnu.org/software/libc/manual/html_node/Feature-Test-Macros.html http://www.tcm.phy.cam.ac.uk/sw/inodes64.html //Hongxu
BTW, there's also bug 6803 which covers this at the distro level.
Merged into master: ... commit 3f4fb3936edbf42b6e94b71e0f243acd6c56b132 Author: Hongxu Jia <hongxu.jia@windriver.com> Date: Mon Jan 4 10:08:42 2016 +0800 dbus: support large-file for stat64 ... //Hongxu
Accepted by upstream: commit 96ffc2a07eb10c0265b654ade972c66e39f9fafb Author: Simon McVittie <simon.mcvittie@collabora.co.uk> Date: Mon Feb 8 17:25:38 2016 +0000 configure.ac: support large-file for stat64 dbus-daemon is not expected to open files with large *sizes*, but without large file support, calling [f]stat() on a file that happens to have a large inode number will fail with EOVERFLOW (see stat(2)). For example, files mounted from an NFS server might have large inode numbers. Bug: https://bugs.freedesktop.org/show_bug.cgi?id=93545 Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> [smcv: shorten and clarify commit message; move AC_SYS_LARGEFILE after AC_USE_SYSTEM_EXTENSIONS because nothing should compile C before that point] Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>