Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [init]

init is the first actual process (PID 1) spawned during the boot sequence of a UNIX system. Some systems may rely on alternative solutions such as systemd or Upstart (Ubuntu).

2
votes
1answer
32 views

Does Linux sends `SIGCHLD` to `init` when it inherits orphaned zombie processes?

Does Linux sends SIGCHLD to init (PID 1 process) when it inherits orphaned zombie processes (processes that have not been reaped by its original parent)?
0
votes
0answers
25 views

How to reload users daemons as superuser?

I'm writing an installation script that should do the following just after package installation: systemctl --user daemon-reload systemctl --user start ${@}" The problem is that the installation is ...
1
vote
1answer
72 views

Splash in PID =1

I have just started learning about process in Linux. I have come around this command called - ps -ef (which will shows all the process running ) I get output like this UID PID PPID LWP ...
0
votes
0answers
15 views

init:wait for root not found

For Ubuntu 16.04, the init script does not exceute the function mountroot, nor does it drop down to the shell. What could be the reason for that? Also, I've updated the menuentry for GRUB , as follows:...
0
votes
0answers
12 views

Is there a command named 'run_scripts' in open SUSE for the init daemon?

For a particular init daemon, I've come across a command 'run_scripts' and a directory specified after the 'run_scripts' for the initialization of those daemons. What is it, and why is it used in such ...
0
votes
1answer
39 views

is there a proper way to shut down from single user mode

I've found a lot of inconsistent documentation on single user mode. I don't need to use it often, but I get curious, and I remember not being to use shut down commands in single user mode and ...
2
votes
1answer
83 views

/etc/inittab respawn already running process, Debian9

I added an antry in /etc/inittab to respawn a binary. The entry is like: id:2:respawn:/path-to-my-bin I then execute init q and the process is started by inittab. If I kill the process, it's ...
0
votes
0answers
104 views

Unable to change from graphical target to other systemd targets in Ubuntu

I am currently a newer user of terminal in Ubuntu. I was trying to demonstrate some features of targets in systemd. Each time that I do systemctl enable or systemctl isolate , I enter my credentials, ...
0
votes
0answers
46 views

linux kernel auto load driver module

I want to know how linux kernel know which module must load on startup ? i know some modules must defined in /etc/modules . but what happened if i change physical hardware ? for example ...
1
vote
1answer
40 views

Process ownership automatically changes to init process on GCP Ubuntu 18.04LTS

We recently moved our development infrastructure from our own old machines running Ubuntu 12.04 to Google Cloud instances running Ubuntu 18.04. Developers usually start some screens and run django ...
0
votes
2answers
297 views

Why should parent process wait (to terminate) until all of its child process terminates?

I know there is no enforcement for the parent process to wait until all its child process terminates. However it's a convention followed. Furthermore, I know that if parent process terminates before ...
-3
votes
2answers
82 views

Is there a daemon which is not a server? [closed]

It seems that a server is not necessarily running as a daemon, e.g. X server. If I am not correct, please let me know. Is a daemon necessarily a server? Is there a daemon which is not a server? I ...
0
votes
1answer
125 views

Why is there a `systemd` process owned by each user that is logged in?

In my ps output: root 1 0.0 0.0 225552 5316 ? Ss /lib/systemd/systemd --system --deserialize 19 message+ 572 0.0 0.0 51564 3076 ? Ss /usr/bin/dbus-daemon --system --address=...
0
votes
3answers
45 views

Is telinit run as a daemon?

In sysvinit, telinit is a symlink to init. init is run as a daemon. Is telinit run as a daemon? I don't have sysvinit installed on my Lubuntu. For comparison, systemctl plays similar role to ...
-2
votes
1answer
74 views

In sysvinit, do `telinit` and `init` run in the same process?

In https://manpages.debian.org/stretch/sysvinit-core/init.8.en.html /sbin/telinit is linked to /sbin/init. It takes a one-character argument and signals init to perform the appropriate action. ...
-1
votes
1answer
34 views

On OSes with SysvInit, are `reboot` and `halt` symlinks to some executables?

On OSes with Systemd, reboot and halt are symlinks to systemctl. On OSes with SysvInit, what are reboot and halt symlinks to? Is it telinit? Or are they themselves executable files, not symlinks? ...
4
votes
3answers
1k views

What is the difference between “init” and “service manager”?

From When the operating system shuts down, how does a service manager know that it should sends SIGTERM and SIGKILL to its services? systemd IS BOTH the init and service manager What is the ...
-3
votes
1answer
247 views

How does Linux operating system shut down? [closed]

Gilles wrote an excellent reply about how Linux kernel shuts down at https://unix.stackexchange.com/a/122667/674 I was wondering how Linux OS shuts down (in cases of both systemvinit and systemd)? I ...
0
votes
1answer
554 views

Status of sysstat.service showing active(exited)

When I see status of sysstat is see the following, ● sysstat.service - Resets System Activity Logs Loaded: loaded (/usr/lib/systemd/system/sysstat.service; enabled; vendor preset: enabled) Active: ...
0
votes
1answer
49 views

kernel sysfs doesn't recognize storage kobjects [closed]

I am using ubuntu kernel 4.xx with corresponding ubuntu initrd.img, and it works. But, I want to use a custom initramfs inspired by lfs (linux from scratch) initramfs. The kernel extracts, and runs ...
3
votes
2answers
2k views

How can I make an executable run as a service?

On Ubuntu 18.04, I can start or stop some service by sudo service cron start/stop I can list some services by service --status-all The output matches the files under /etc/init.d/. I heard there ...
1
vote
1answer
406 views

Failed to execute /init (error -13), can't run '/etc/init.d/rcS': No such file or directory

Last night I broke my Arch. Now, when trying to boot, it says: [0.595364] Failed to execute /init (error -13) : can't log to /dev/tty5 starting pid 131, tty '': '/etc/init.d/rcS' : can't log to /dev/...
3
votes
2answers
563 views

Remove busybox from buildroot

As part of Linux hardening we want to remove busybox from filesystem created with buildroot. But I am not sure if system can boot without it. I am quite sure that there are init files that depends ...
1
vote
2answers
35 views

some process are started through init even i am using systemd

When I do ll /proc/1/exe I get lrwxrwxrwx. 1 root root 0 Oct 16 11:28 /proc/1/exe -> /usr/lib/systemd/systemd Which means i am running systemd daemon not init. But when I list ll /etc/init....
2
votes
1answer
150 views

What are runlevels and how they work

I have not a clear understanding of runlevels and how they work. I know runlevels are a digit indicating which processes should be started by init. Pratically speaking: at startup init sees this ...
1
vote
0answers
97 views

Linux Mint won't boot after issues saving .tex file

I've been having some problems booting into Linux Mint 18.2. It started when I woke the computer from sleep and tried to continue editing a .tex file I was working on. I got some errors which ...
0
votes
1answer
47 views

Background initialization with runit

I recently switched my init system on my ARM box running Linux 2.6 from sysvinit to runit with great success. However, I'm trying to fine-tune the initialization routine. I'd like to have something ...
0
votes
0answers
154 views

How do I stop trackpad driver via xinput disable

If I enter the xinput list command into a terminal I get the following output. Virtual core pointer id=2 Virtual core XTEST pointer id=4 Synaptics TM3096-006 id=11 SynPS/2 ...
1
vote
1answer
35 views

Setting up VM login instead of Local login [closed]

I had a question earlier, it is tied into this, that one was looking for the proper procedure, this one is looking how to implement. If you need a backstory refer to My first question I have a local ...
0
votes
1answer
86 views

what dependency-based linux init systems suitable for embedded systems?

Currently, I run Linux on an arm board using Sysvinit, but the network drivers of my board are not the best which causes the network service to stall the boot for a while, I also have problems with ...
3
votes
1answer
195 views

Targets and Unit files on Boot System

I have been going through all the docs and examples regarding the targets (referred to as runlevel) for the past few days but I am still confused with the topic. Can anyone explained me the ...
0
votes
1answer
33 views

Portable way to run a simple script at startup

I'm trying to run a script at startup as root. (Just sets up a root-owned directory in /tmp). Currently, I'm using this script to set up the boot hook and it appears to get the job done: #!/bin/sh -...
0
votes
0answers
35 views

What happens when a process in SysV boot fails?

If using SysV what will happen if a process fails during the init ? For example assume that the processes in the figure will be executed sequentially. So first networking, then dbus-1,... Now my ...
6
votes
2answers
367 views

Where is fsck run?

I was reading through all the things that are run during bootup and have seen that after mounting the rootfs, /sbin/fsck.ext4 is run and after that systemd is run. I was wondering where or how fsck is ...
0
votes
1answer
144 views

What happens if you fork before switch_root?

So typically an initramfs /init script will end with something like exec switch_root /newroot /sbin/init effectively replacing itself with systemd or whatever floats your boat. But what would happen ...
1
vote
1answer
53 views

Using second init/systemd startup on different partition

We have the following setup: A read-only system partition from which the kernel is booted from. (Debian Jessie) A read-write partition which has additional software to be started as daemons. A simple ...
1
vote
2answers
903 views

How to determine a Linux distro is systemd or sysV init without installing or booting?

I noticed in somewhere that most of the Linux distro are based on Systemd instead of SysV init. So I just want to know without installing and booting. Is there any possible way to find distro based ...
1
vote
2answers
589 views

How should one invoke docker to take care of the PID 1 problem with zombie processes?

The phusion/baseimage boasts of taking care of the pid 1 problem with a light weight init process. How can one use the phusion/baseimage properly? I tried to invoke the image with the command ps aux ...
1
vote
1answer
376 views

Can't mount devtmpfs, can't run init [closed]

I'm trying to run a recent enough kernel (4.9) on an Inforce 6540 board, a single-board computer with a Qualcomm Snapdragon 805 (Also called APQ8084, a SoC with four Krait 450 Cores, ARMv7-A). The ...
0
votes
1answer
118 views

--test option is not available for /sbin/init

According to man init(1) it is a --test option should be available. In fact when I am trying to test it I got an error root@mst-sls:~# /sbin/init --test /sbin/init: unrecognized option '--test' ...
0
votes
1answer
226 views

When will S99 launch if it isn't in a normal form?

If I do a: echo "foobar" > /etc/init.d/foobar chmod 744 /etc/init.d/foobar ln -s /etc/init.d/foobar /etc/rc.d/rc3.d/S99foobar on a SLES 11, then when will the "foobar" command launch during boot?...
3
votes
1answer
4k views

How to pass arguments to a Linux kernel `init=` bootparam?

Update: I have succeeded in creating a very simple demo of using the init= bootparam to specify that a custom binary (written in golang and compiled) should be used in place of the standard init. The ...
0
votes
1answer
200 views

Opening raw UBI partition for writing on Linux if it's mounted and used by init

I need to update a raw UBI partition with a new UBIFS image from Linux userspace with superuser rights, however I'm getting EBUSY (Device or resource busy) error whenever I'm trying to open my ...
0
votes
1answer
209 views

runsv not redirecting standard error output, why?

According to the runsv man page: If the directory service/log exists, runsv creates a pipe, redirects service/run's and service/finish's standard output to the pipe, switches to the ...
0
votes
1answer
239 views

Understanding shutdown command in inittab

Looking in my /etc/inittab file I see the following entry: ca:12345:ctrlaltdel:/sbin/shutdown -t1 -a -r now What do the -t1 and -a options mean? They do not appear in the manual for the shutdown ...
-3
votes
1answer
63 views

Linux bash scripting [closed]

I have lot of questions about scripts. How to configure the script that 1 It automatically turns on when the computer is turned on? 2 I was possible start and close the script with console? 3 After ...
3
votes
0answers
936 views

Why does Linux Mint starts in runlevel 5 even though DEFAULT_RUNLEVEL is set to 2?

When studying about Linux runlevels I came across something I was unable to explain to myself while trying to change the DEFAULT_RUNLEVEL. When I boot Mint, it starts in runlevel 5, even though it ...
1
vote
0answers
443 views

LXC does not stop, Failed to connect to bus

I just created a new LXC with the following command: lxc-create -n ${NAME} -t download I choosed debian, stretch and amd64 as characteristics. I'm using the LXC in unprivileged mode with UID/GID ...
0
votes
1answer
278 views

Arch Linux - How could I decrypt and automount multiple encrypted drives during init?

I have two encrypted drives (one SSD for booting and a hard drive for storage) I need both to be unlocked and mounted before all of the runlevel programs/services. Else some of my services would freak ...
3
votes
1answer
15k views

sudo reboot -> Failed to talk to init daemon

On my Raspberry Pi runs jessie. After installing mosquitto I can not run sudo reboot anymore. This error appears: "Failed to talk to init daemon.". What could be the problem? I have already ...