FS#61566 - [fakeroot]makepkg and/or fakeroot issue, faked 100% cpu load, strange permissions on pkg/
Attached to Project:
Arch Linux
Opened by whoami (whoami) - Tuesday, 29 January 2019, 09:59 GMT
Last edited by Toolybird (Toolybird) - Monday, 02 January 2023, 00:36 GMT
Opened by whoami (whoami) - Tuesday, 29 January 2019, 09:59 GMT
Last edited by Toolybird (Toolybird) - Monday, 02 January 2023, 00:36 GMT
|
Details
Description:
After last update I tried to build yay and i2pd and getting same behaviour. Look on pkg directory permissions. software building fine, but can't pack it to archive. on step fakeroot environment I getting faked process 100% cpu load I tried -lts kernel, but the same as -hardened, too I tried reinstall base-devel, not helps. ==> Entering fakeroot environment... ^C/usr/bin/fakeroot: line 1: kill: (10532) - No such process $ l total 368 drwxr-xr-x 8 user user 4096 Jan 28 11:10 .git -rw-r--r-- 1 user user 35 Jan 28 11:10 .gitignore d--x--x--x 2 user user 4096 Jan 29 09:05 pkg -rw-r--r-- 1 user user 674 Jan 28 11:10 PKGBUILD drwxr-xr-x 3 user user 4096 Jan 29 09:05 src -rw-r--r-- 1 user user 463 Jan 28 11:10 .SRCINFO -rw-r--r-- 1 user user 351515 Jan 28 11:10 yay-9.1.0.tar.gz Additional info: $ uname -a Linux scw-6ef8ee 4.20.4.a-1-hardened #1 SMP PREEMPT Fri Jan 25 01:24:51 CET 2019 x86_64 GNU/Linux Steps to reproduce: git clone https://aur.archlinux.org/yay.git cd yay makepkg -si |
This task depends upon
Closed by Toolybird (Toolybird)
Monday, 02 January 2023, 00:36 GMT
Reason for closing: Not a bug
Additional comments about closing: See comments. Issue only arises when systemd standard config is modified.
Monday, 02 January 2023, 00:36 GMT
Reason for closing: Not a bug
Additional comments about closing: See comments. Issue only arises when systemd standard config is modified.
^Cfakeroot internal error #43: Identifier removed
semop(2): encountered an error: Invalid argument
/usr/bin/fakeroot: line 1: kill: (10634) - No such process
/usr/bin/fakeroot: line 1: kill: (10634) - No such process
.--. Pacman v5.1.2 - libalpm v11.0.2
...
close(52100911) = -1 EBADF (Bad file descriptor)
close(52100912) = -1 EBADF (Bad file descriptor)
close(52100913) = -1 EBADF (Bad file descriptor)
close(52100914) = -1 EBADF (Bad file descriptor)
close(52100915) = -1 EBADF (Bad file descriptor)
close(52100916) = -1 EBADF (Bad file descriptor)
...
previous update:
[2019-01-14 07:09] [ALPM] upgraded ncurses (6.1-4 -> 6.1-6)
[2019-01-14 07:09] [ALPM] upgraded readline (7.0.005-1 -> 8.0.0-1)
[2019-01-14 07:09] [ALPM] upgraded bash (4.4.023-1 -> 5.0.0-1)
[2019-01-14 07:09] [ALPM] upgraded libxml2 (2.9.8-6 -> 2.9.8-8)
[2019-01-14 07:09] [ALPM] upgraded gdbm (1.18.1-1 -> 1.18.1-2)
[2019-01-14 07:09] [ALPM] upgraded libutil-linux (2.33.1-1 -> 2.33.1-2)
[2019-01-14 07:10] [ALPM] upgraded python (3.7.2-1 -> 3.7.2-3)
[2019-01-14 07:10] [ALPM] upgraded bind-tools (9.13.5-2 -> 9.13.5-3)
[2019-01-14 07:10] [ALPM] upgraded libsystemd (240.0-3 -> 240.34-2)
[2019-01-14 07:10] [ALPM] upgraded device-mapper (2.02.183-1 -> 2.02.183-2)
[2019-01-14 07:10] [ALPM] upgraded gawk (4.2.1-1 -> 4.2.1-2)
[2019-01-14 07:10] [ALPM] upgraded gnutls (3.6.5-1 -> 3.6.5-2)
[2019-01-14 07:10] [ALPM] upgraded sqlite (3.26.0-1 -> 3.26.0-2)
[2019-01-14 07:10] [ALPM] upgraded pcre (8.42-1 -> 8.42-2)
[2019-01-14 07:10] [ALPM] upgraded gnupg (2.2.12-1 -> 2.2.12-2)
[2019-01-14 07:10] [ALPM] upgraded guile (2.2.4-1 -> 2.2.4-2)
[2019-01-14 07:10] [ALPM] upgraded inetutils (1.9.4-6 -> 1.9.4-7)
[2019-01-14 07:10] [ALPM] upgraded libedit (20180525_3.1-1 -> 20181209_3.1-1)
[2019-01-14 07:10] [ALPM] upgraded pcre2 (10.32-1 -> 10.32-2)
[2019-01-14 07:10] [ALPM] upgraded util-linux (2.33.1-1 -> 2.33.1-2)
[2019-01-14 07:10] [ALPM] upgraded systemd (240.0-3 -> 240.34-2)
[2019-01-14 07:10] [ALPM] upgraded linux-hardened (4.19.13.a-1 -> 4.19.15.a-1)
[2019-01-14 07:10] [ALPM] upgraded linux-hardened-headers (4.19.13.a-1 -> 4.19.15.a-1)
[2019-01-14 07:10] [ALPM] upgraded lvm2 (2.02.183-1 -> 2.02.183-2)
[2019-01-14 07:10] [ALPM] upgraded postgresql-libs (11.1-2 -> 11.1-3)
[2019-01-14 07:10] [ALPM] upgraded postgresql (11.1-2 -> 11.1-3)
[2019-01-14 07:10] [ALPM] upgraded python2 (2.7.15-2 -> 2.7.15-4)
[2019-01-14 07:10] [ALPM] upgraded systemd-sysvcompat (240.0-3 -> 240.34-2)
[2019-01-14 07:10] [ALPM] upgraded xfsprogs (4.19.0-1 -> 4.19.0-2)
Set the date in your mirror and do a -Syyuu.
whoami, Could you post the output from "sudo pacman -Qkk | grep warning"?
Have you done any other hardening steps on this system?
OK. double checked, 2019/01/08 - works, 2019/01/09 - not works after reboot
List all pkgs changed 2019/01/09 on this system:
core/iana-etc 20180913-1 20181219-1 0.01 MiB 0.36 MiB
core/iproute2 4.19.0-1 4.20.0-1 0.02 MiB 0.80 MiB
core/libsystemd 239.370-1 240.0-3 0.13 MiB 0.38 MiB
core/libutil-linux 2.33-2 2.33-3 0.01 MiB 0.36 MiB
extra/libxslt 1.1.32+3+g32c88216-1 1.1.33-1 0.01 MiB 0.35 MiB
core/man-db 2.8.4-1 2.8.5-1 0.16 MiB 0.95 MiB
core/systemd 239.370-1 240.0-3 1.43 MiB 4.48 MiB
core/systemd-sysvcompat 239.370-1 240.0-3 0.02 MiB 0.01 MiB
core/util-linux 2.33-2 2.33-3 0.33 MiB 2.03 MiB
$ sudo pacman -Qkk | grep warning
[sudo] password for user:
warning: filesystem: /etc/hosts (Permissions mismatch)
warning: filesystem: /root (Permissions mismatch)
warning: grub: /etc/default/grub (Permissions mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.alias (Modification time mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.alias (Size mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.alias.bin (Modification time mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.alias.bin (Size mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.builtin.bin (Modification time mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.dep (Modification time mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.dep (Size mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.dep.bin (Modification time mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.dep.bin (Size mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.devname (Modification time mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.softdep (Modification time mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.symbols (Modification time mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.symbols (Size mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.symbols.bin (Modification time mismatch)
warning: linux-hardened: /usr/lib/modules/4.19.13.a-1-hardened/modules.symbols.bin (Size mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.alias (Modification time mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.alias (Size mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.alias.bin (Modification time mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.alias.bin (Size mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.builtin.bin (Modification time mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.dep (Modification time mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.dep (Size mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.dep.bin (Modification time mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.dep.bin (Size mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.devname (Modification time mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.softdep (Modification time mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.symbols (Modification time mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.symbols (Size mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.symbols.bin (Modification time mismatch)
warning: linux-lts: /usr/lib/modules/4.19.13-1-lts/modules.symbols.bin (Size mismatch)
warning: mkinitcpio: /etc/mkinitcpio.conf (Permissions mismatch)
warning: nginx: /var/lib/nginx/proxy (UID mismatch)
warning: openssh: /etc/ssh/sshd_config (Permissions mismatch)
warning: pacman: /var/cache/pacman/pkg (No such file or directory)
warning: pinentry: /usr/bin/pinentry (File type mismatch)
warning: sudo: /etc/sudoers.d (Permissions mismatch)
$ diff -u /etc/systemd/system.conf /etc/systemd/system.conf.pacnew
--- /etc/systemd/system.conf 2019-01-30 02:15:28.560000000 +0000
+++ /etc/systemd/system.conf.pacnew 2019-01-08 00:40:51.000000000 +0000
@@ -23,9 +23,9 @@
#CrashReboot=no
#CtrlAltDelBurstAction=reboot-force
#CPUAffinity=1 2
-#JoinControllers=cpu,cpuacct net_cls,net_prio
#RuntimeWatchdogSec=0
#ShutdownWatchdogSec=10min
+#WatchdogDevice=
#CapabilityBoundingSet=
#NoNewPrivileges=no
#SystemCallArchitectures=
@@ -52,9 +52,7 @@
#DefaultLimitSTACK=
#DefaultLimitCORE=
#DefaultLimitRSS=
-#DefaultLimitNOFILE=
-#DefaultLimitNOFILE=1000000
-DefaultLimitNOFILE=infinity
+#DefaultLimitNOFILE=1024:524288
#DefaultLimitAS=
#DefaultLimitNPROC=
#DefaultLimitMEMLOCK=
@@ -64,5 +62,3 @@
#DefaultLimitNICE=
#DefaultLimitRTPRIO=
#DefaultLimitRTTIME=
-#IPAddressAllow=
-#IPAddressDeny=
In faked.c from fakeroot, line 1490, getdtablesize returns a large value (1,073,741,816) due to the infinity setting.
faked loops, calling close on every possible file descriptor from 0 to 1073741816
Breakpoint 2, main (argc=<optimized out>, argv=0x7020a00e55c0) at faked.c:1500
1500 close(fl);
(gdb) info locals
fl = 36574955
num_fds = 1073741816
Eventually, it should carry on, but it takes a long time to get to 1073741816.
I'll report this to fakeroot upstream.
if(!foreground){
/* literally copied from the linux klogd code, go to background */
if ((pid=fork()) == 0){
int fl;
int num_fds = getdtablesize();
fflush(stdout);
/* This is the child closing its file descriptors. */
for (fl= 0; fl <= num_fds; ++fl)
#ifdef FAKEROOT_FAKENET
if (fl != sd)
#endif /* FAKEROOT_FAKENET */
close(fl);
whoami, did you have this set to infinity for a particular reason?
Allan, what are your thoughts on this?