Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hi all,
i'm writing a simple init program only for study purpose. Now, how can i fastly test it? I tried to use systemd container but even if I replace the init symlink making it point to my init program, it is ignored, starts systemd anyway.
What is the best and fastest way to do that?
Regards
Are you writing an init script to start a service under initd, runit, s6, or systemd? Or are you writing an init service to start the system services REPLACING systemd, init.d, runit, or s6? This is unclear form your statement of the question, and critical to answering it.
There are a couple of dozen distributions out there that do not use SystemD. Seek one out and use it to create a virtual machine or full guest container. Then you can play with the system init features all you want without having systemd start behind your back. No matter what the answer to the question I asked, this is far safer than trying things in your native install.
Thanks all for the answers.
I know that i can put all in a virtual machine but that means that i have to transfer the compiled code from host to guest.
Or I should to develop it directly in virtual machine. That means that for each modification (even a simple printf), I'll have to make a reboot machine passing init on the command line as parameter.
This solution doesn't looks like fast imo.
For this reason I wanted to understand if a lightweight container offered by systemd can help me.
A probably solution could be this
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.