[systemd-devel] Reduce loading time (size) of init program (systemd)
Dear systemd folks, In his talk *Linux kernel fastboot on the way* at this years Linux Plumbers Conference [1][2], Feng Tang (CCed) has the notes below on the slide for userspace/systemd. > • Systemd is ~1.5MB - the loading time for emmc is 100ms> • Can we use a > small lightweight “init” program, which starts > target programs in parallel and readahead to preload libraries > and executables? Are you already aware of these issues? If yes, have you ideas or suggestions how to solve this? Maybe something to discuss at this weeks All System Go! 2019. Kind regards, Paul [1]: https://linuxplumbersconf.org/event/4/contributions/281/ [2]: https://linuxplumbersconf.org/event/4/contributions/281/attachments/216/617/LPC_2019_kernel_fastboot_on_the_way.pdf smime.p7s Description: S/MIME Cryptographic Signature ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] Unload disabled units
> You should check to see if anything is actually still referencing these > units. Try `systemd-analyze dump` and see if any "ReferencedBy" entries > appear for these units. It seems that they are referencing each other: -> Unit belleshop@0.58.service: [...] ReferencedBy: belleshop@0.58.socket (destination-implicit) […] -> Unit belleshop@0.58.socket: [...] ReferencedBy: belleshop@0.58.service (destination-file) […] ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] Unload disabled units
> Normally units should be unloaded immediately if they are stopped > and didn't fail. What systemd version are you using? (One possibility > to consider is that the glob matches *files*, and you are simply loading > the units at the time the systemctl query is made. Use 'belleshop@*' > instead.) I still have the same problem with ‘belleshop@‘. ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
[systemd-devel] networkd - how to (partially) manage OpenVPN interfaces?
Hi, when I run an OpenVPN interface, OpenVPN manages the interface itself: It handles creation, destruction and assignment of the IP address. The IP address can be controlled by the remote site, so the OpenVPN daemon is kind of the only thing that can configured the Interface. I would, however, like systemd-resolved to ask DNS servers that are reachable over the VPN for certain domains, such as ka51.zugschlus.de. Dumping a tun0.network containing: [Match] Name=tun0 [Network] Domains=~ka51.zugschlus.de DNS=2a01:238:4071:3281::35:100 DNS=2a01:238:4071:328e::35:100 DHCP=no IPv6AcceptRA=no into /e/s/n doesn't work since that clears up the IP addresses that OpenVPN has correctly assigned. Can I have the advantages of systemd-resolved on an Interface that is not fully managed by systemd-networkd? Greetings Marc -- - Marc Haber | "I don't trust Computers. They | Mailadresse im Header Leimen, Germany| lose things."Winona Ryder | Fon: *49 6224 1600402 Nordisch by Nature | How to make an American Quilt | Fax: *49 6224 1600421 ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] Unload disabled units
On Sun, 15 Sep 2019, Daniel Duong wrote: > Hi, > > I have a 2 template units: 1 for a service and 1 for a socket. Each > instance is a version of my web application. > > After a successful deploy, I stop and disable the old version and I > enable the new one: > systemctl start belleshop@0.2.socket > # Test that everything is fine > systemctl enable belleshop@0.2.socket > systemctl stop belleshop@0.1.socket > systemctl stop belleshop@0.1.service > systemctl disable belleshop@0.1.socket > > I've done that for a few versions now, and it seemed to work OK. There > is a little problem though. The old versions are still loaded: > > $ systemctl --no-legend --all list-units belleshop@* > belleshop@0.110.service loaded active running Belleshop server > belleshop@0.34.service loaded inactive deadBelleshop server > belleshop@0.36.service loaded inactive deadBelleshop server > belleshop@0.37.service loaded inactive deadBelleshop server > [...] > belleshop@0.110.socket loaded active running Belleshop socket > belleshop@0.34.socket loaded inactive deadBelleshop socket > belleshop@0.36.socket loaded inactive deadBelleshop socket > belleshop@0.37.socket loaded inactive deadBelleshop socket > [...] > > Is there any way I can unload these old versions? You should check to see if anything is actually still referencing these units. Try `systemd-analyze dump` and see if any "ReferencedBy" entries appear for these units. ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] Unload disabled units
On Mon, 16 Sep 2019, Reindl Harald wrote: > Am 16.09.19 um 09:36 schrieb Zbigniew Jędrzejewski-Szmek: > > Normally units should be unloaded immediately if they are stopped > > and didn't fail. What systemd version are you using? > > the better question is which one are you using because this behavior > below exists for many years and it's good given that you normally want > the journald output > > [root@srv-rhsoft:~]$ systemctl status vnc > ● vnc.service - VNC Server >Loaded: loaded (/etc/systemd/system/vnc.service; disabled; vendor > preset: disabled) >Active: inactive (dead) > > Sep 16 11:15:24 srv-rhsoft.rhsoft.net systemd[1]: Started VNC Server. > Sep 16 11:15:28 srv-rhsoft.rhsoft.net systemd[1]: Stopping VNC Server... > Sep 16 11:15:28 srv-rhsoft.rhsoft.net systemd[1]: vnc.service: Succeeded. > Sep 16 11:15:28 srv-rhsoft.rhsoft.net systemd[1]: Stopped VNC Server. > > [root@srv-rhsoft:~]$ rpm -q systemd > systemd-241-12.git1e19bcd.fc30.x86_64 This unit probably is being unloaded when you're not looking at it. Using `systemctl status` on it will force it to be loaded (possibly only temporarily). The unit does not need to remain loaded to be able to view its journal logs.___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] Unload disabled units
Am 16.09.19 um 09:36 schrieb Zbigniew Jędrzejewski-Szmek: > Normally units should be unloaded immediately if they are stopped > and didn't fail. What systemd version are you using? the better question is which one are you using because this behavior below exists for many years and it's good given that you normally want the journald output [root@srv-rhsoft:~]$ systemctl status vnc ● vnc.service - VNC Server Loaded: loaded (/etc/systemd/system/vnc.service; disabled; vendor preset: disabled) Active: inactive (dead) Sep 16 11:15:24 srv-rhsoft.rhsoft.net systemd[1]: Started VNC Server. Sep 16 11:15:28 srv-rhsoft.rhsoft.net systemd[1]: Stopping VNC Server... Sep 16 11:15:28 srv-rhsoft.rhsoft.net systemd[1]: vnc.service: Succeeded. Sep 16 11:15:28 srv-rhsoft.rhsoft.net systemd[1]: Stopped VNC Server. [root@srv-rhsoft:~]$ rpm -q systemd systemd-241-12.git1e19bcd.fc30.x86_64 ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] Unload disabled units
On Sun, Sep 15, 2019 at 03:12:22AM +, Daniel Duong wrote: > Hi, > > I have a 2 template units: 1 for a service and 1 for a socket. Each > instance is a version of my web application. > > After a successful deploy, I stop and disable the old version and I > enable the new one: > systemctl start belleshop@0.2.socket > # Test that everything is fine > systemctl enable belleshop@0.2.socket > systemctl stop belleshop@0.1.socket > systemctl stop belleshop@0.1.service > systemctl disable belleshop@0.1.socket > > I've done that for a few versions now, and it seemed to work OK. There > is a little problem though. The old versions are still loaded: > > $ systemctl --no-legend --all list-units belleshop@* > belleshop@0.110.service loaded active running Belleshop server > belleshop@0.34.service loaded inactive deadBelleshop server > belleshop@0.36.service loaded inactive deadBelleshop server > belleshop@0.37.service loaded inactive deadBelleshop server > [...] > belleshop@0.110.socket loaded active running Belleshop socket > belleshop@0.34.socket loaded inactive deadBelleshop socket > belleshop@0.36.socket loaded inactive deadBelleshop socket > belleshop@0.37.socket loaded inactive deadBelleshop socket > [...] > > Is there any way I can unload these old versions? Normally units should be unloaded immediately if they are stopped and didn't fail. What systemd version are you using? (One possibility to consider is that the glob matches *files*, and you are simply loading the units at the time the systemctl query is made. Use 'belleshop@*' instead.) Zbyszek ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel