Re: [systemd-devel] UMask attribute in service file
On 31/01/17, Oliver Graute wrote: > Hello list, > > some further background: > > In my system there are different services started by systemd 225 (all > with UMask=027). Sometimes files are created with 666 sometimes with > 640 as I wish. > > ls -la > -rw-r-1 oliver oliver75 Jan 11 17:30 > log_20170111_163024_2.log > -rw-rw-rw-1 oliver oliver75 Jan 11 17:30 > log_20170111_163024_3.log > -rw-rw-rw-1 oliver oliver75 Jan 11 17:36 > log_20170111_163610_1.log > -rw-r-1 oliver oliver75 Jan 31 13:38 > log_20170131_123842_1.log > -rw-r-1 oliver oliver75 Jan 31 13:57 > log_20170131_125738_2.log > > some clue whats going one here? the reason for this behavior was an umask(0) in a custom library some of my services used. After I removed this everything is fine. Best Regards, Oliver ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
[systemd-devel] UMask attribute in service file
Hello list, I'am using the UMask attribute in my service file to define my umask setting to 0027. In this service file I start a little c program which uses fopen() to open a file. the file permissions are rw-rw-rw (0666) instead of rw-r--- (0640) Is this a expected behavior? some further background: In my system there are different services started by systemd 225 (all with UMask=027). Sometimes files are created with 666 sometimes with 640 as I wish. ls -la -rw-r-1 oliver oliver75 Jan 11 17:30 log_20170111_163024_2.log -rw-rw-rw-1 oliver oliver75 Jan 11 17:30 log_20170111_163024_3.log -rw-rw-rw-1 oliver oliver75 Jan 11 17:36 log_20170111_163610_1.log -rw-r-1 oliver oliver75 Jan 31 13:38 log_20170131_123842_1.log -rw-r-1 oliver oliver75 Jan 31 13:57 log_20170131_125738_2.log some clue whats going one here? here my stub service definition: [Unit] Description=Start umask_test [Service] Type=simple PIDFile=/var/run/umasktest.pid WorkingDirectory=/home/oliver User=oliver Group=oliver UMask=0027 Environment= ExecStart=/home/oliver/umask_test Best Regards, Oliver ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
[systemd-devel] CPUQuota setting is not inherited from systemd slices
Hello, I try to limit my CPUQuota for my dnt5411software.slice. But the services in the slice do not inherit the CPUQuota=20% setting from the dnt5411software.slice file. They still consume more then 20% of the CPU. Some clue whats wrong or missconfigured here? I'am using systemd 225 systemd-cgls ├─dnt5411software.slice │ ├─startpingproxy.service │ │ └─699 /dnt/ibis/tools/pingproxy │ ├─startscm.service │ │ └─704 /dnt/ibis/scm │ ├─startstatusproxy.service │ │ └─712 /dnt/ibis/tools/statusproxy │ ├─startuartproxy.service │ │ └─700 /dnt/ibis/tools/uartproxy │ ├─startprocessproxy.service │ │ ├─706 /dnt/ibis/tools/processproxy │ │ ├─722 ./datamgr -scm │ │ ├─723 ./mobmgr -scm │ │ ├─724 ./ethmgr -scm │ │ ├─725 ./modman -scm │ │ ├─727 ./phpconnector -scm │ │ ├─728 ./mcmgr -scm │ │ ├─729 ./smsmgr -scm │ │ ├─730 ./sshmgr -scm │ │ └─731 ./ledmgr -scm │ └─starthalproxy.service │ └─708 /dnt/ibis/tools/halproxy cat /etc/systemd/system/dnt5411software.slice [Unit] Description=Slices Documentation=man:systemd.special(7) Wants=-.slice user.slice After=-.slice user.slice [Slice] CPUAccounting=true MemoryAccounting=true BlockIOAccounting=true #TasksAccounting=true #CPUShares=512 CPUQuota=20% systemctl show startprocessproxy.service | grep "CPUQuota" CPUQuotaPerSecUSec=infinity Best regards, Oliver ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel