Sergey Tyshchenko | 25 Aug 17:27 2015

[sysvinit-devel] For you

for you


Hello, My name is Sergey, I propose you cooperation. We are a creative company in the development and creation of unique products for decoration - to design buildings IDENTIKA.PRO. We''re specialized on decoration of shops, petrol station, cafe, fast food restaurants, and retail franchises.
We are interested at long-term cooperation with you. We propose a good environment to work with partners.
Examples of our work http :
I propose You to become our partner in your area.
Let us know about your decision




Sergey Tyshchenko
Viber: +380505566965 | WhatsApp: +380505566965
Skype: t.sergey.m
s.tyshchenko <at> |
03040 | Golosiivskyi Ave. 70 | office 502 | Kiev

Richard Tollerton | 31 Jul 23:21 2015

[sysvinit-devel] [PATCH] Make bootlogd aware of ttyPS* console devices present on Xilinx ZYNQ processors.

Signed-off-by: Richard Tollerton <rich.tollerton <at>>
 src/bootlogd.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/bootlogd.c b/src/bootlogd.c
index 4f820a8..dce1631 100644
--- a/src/bootlogd.c
+++ b/src/bootlogd.c
 <at>  <at>  -85,6 +85,7  <at>  <at>  struct consdev {
 	{ "ttyB",	"/dev/ttyB%s",		NULL		},
 	{ "ttySC",	"/dev/ttySC%s",		"/dev/ttsc/%s"	},
 	{ "ttyS",	"/dev/ttyS%s",		"/dev/tts/%s"	},
+	{ "ttyPS",	"/dev/ttyPS%s",		NULL		},
 	{ "tty",	"/dev/tty%s",		"/dev/vc/%s"	},
 	{ "hvc",	"/dev/hvc%s",		"/dev/hvc/%s"	},
 	{ NULL,		NULL,			NULL		},
 <at>  <at>  -94,7 +95,7  <at>  <at>  struct consdev {
  *	Devices to try as console if not found on kernel command line.
  *	Tried from left to right (as opposed to kernel cmdline).
-char *defcons[] = { "tty0", "hvc0", "ttyS0", "ttySC0", "ttyB0", NULL };
+char *defcons[] = { "tty0", "hvc0", "ttyS0", "ttyPS0", "ttySC0", "ttyB0", NULL };

  *	Catch signals.


sysvinit-devel | 5 Jul 21:35 2015

[sysvinit-devel] We've Iimited access to your PayPaI account 05/07/2015 09:35:44

Important Notice


Some information on your accοunt appears to be missing or incorrect.
Please confirm your information promptly so that you can continue to enjoy all the benefits of your ΡayΡal accοunt. .
If you don't confirm your information, we'll limit what you can do with your ΡayΡal accοunt.

Here's a link to all the legal details
  • Click here
  • If you face problems with the button above, please copy and paste the line to your browser .
Thank you for being a ΡayΡal custοmer.

Yours sincerely,
Please do not reply to this email, We are unable to respond to inquiries sent to this address. For immediate answers to your questions, visit our Help Center by clicking "Help" located on any ΡayΡal page or email.

Copyright © 1999-2015 ΡayΡal. All rights reserved. ΡayΡal (Europe) S.à r.l. et Cie, S.C.A., Société en Commandite par Actions. Registered office: 22-24 Boulevard Royal, L-2449, Luxembourg, R.C.S. Luxembourg B 118 349.

05/07/2015 09:35:44

Arshad, Farrukh | 23 Feb 11:18 2015

[sysvinit-devel] killall5 does not wak up after sleep 5


I have created a custom embedded linux distribution for ARM platform using Yocto project. My sysv
utilities version is 2.88. The problem I am facing is when I restart my system and /etc/init.d/sendsigs
script is called, it does not woke up after a sleep of 5 seconds hence unable to send KILL -9 signal and the
system hangs in the sleep. I have checked it with the strace sleep 5 and again it is stuck in the nanosleep
system call. The problem does not seems to have any issue with sysv but it looks like scheduler does not wake
up the script process. I will appreciate any help or pointers about where should I look to fix the issue.

Farrukh Arshad.

Marc Smith | 20 Jan 18:16 2015

[sysvinit-devel] bootlogd Tab Question


I noticed an issue with bootlogd where lines beginning with a tab character are not written to the log file. In bootlogd.c I'm looking at lines 389 through 393... this snippet:

case '\t':
    line.pos += (line.pos / 8 + 1) * 8;
    if (line.pos >= (int)sizeof(line.buf))
        line.pos = sizeof(line.buf) - 1;

So when the character is a tab, we're advancing line.pos and we start writing the output to line.buf after this, but the problem is when we write the buffer to the file (fprintf() in line 412) we get nothing printed to the file since line.buf + 0 .. 7 is \0.

I don't understand the intention of this block of code, but I assume its so we don't print a tab character to the log file. Perhaps instead just print spaces (8 or 4 or X) to the file in-place of tabs?

I looked at the latest bootlogd.c from trunk ( and compared it to the version I'm using (2.88dsf) and it appears it would function the same. The line numbers I referenced above are taken from the trunk version.

Any help would be greatly appreciated.


Ben Shelton | 28 Jul 18:02 2014

[sysvinit-devel] [PATCH] bootlogd: Allow console writes to ttyPS*


The patch below enables bootlogd to make console writes to /dev/ttyPS*,
the default naming convention for xilinx-zynq UARTs.  It was originally
written by Richard Tollerton (copied).



Index: sysvinit/trunk/src/bootlogd.c
--- sysvinit/trunk/src/bootlogd.c	(revision 200)
+++ sysvinit/trunk/src/bootlogd.c	(working copy)
 <at>  <at>  -85,6 +85,7  <at>  <at> 
 	{ "ttyB",	"/dev/ttyB%s",		NULL		},
 	{ "ttySC",	"/dev/ttySC%s",		"/dev/ttsc/%s"	},
 	{ "ttyS",	"/dev/ttyS%s",		"/dev/tts/%s"	},
+	{ "ttyPS",	"/dev/ttyPS%s",		NULL		},
 	{ "tty",	"/dev/tty%s",		"/dev/vc/%s"	},
 	{ "hvc",	"/dev/hvc%s",		"/dev/hvc/%s"	},
 	{ NULL,		NULL,			NULL		},
 <at>  <at>  -94,7 +95,7  <at>  <at> 
  *	Devices to try as console if not found on kernel command line.
  *	Tried from left to right (as opposed to kernel cmdline).
-char *defcons[] = { "tty0", "hvc0", "ttyS0", "ttySC0", "ttyB0", NULL };
+char *defcons[] = { "tty0", "hvc0", "ttyS0", "ttyPS0", "ttySC0", "ttyB0", NULL };

  *	Catch signals.

Askar Safin | 28 Jun 23:06 2014

[sysvinit-devel] [PATCH] Sending processes configured via /etc/inittab the KILL signal

Hi, please apply this patch. It makes a message less confusing. I. e. now we understand that init doesn't
kill all processes, but instead kill mentioned in inittab ones. This patch is taken from "Linux From
Scratch" ( ).

Askar Safin
Moscow, Russia
Moscow State University, , Faculty of Mechanics and Mathematics, Department of
Mathematical Logic and Theory of Algorithms

diff -Naur sysvinit-2.88dsf.orig/src/init.c sysvinit-2.88dsf/src/init.c
--- sysvinit-2.88dsf.orig/src/init.c	2010-04-13 04:48:54.000000000 -0500
+++ sysvinit-2.88dsf/src/init.c	2013-12-12 16:17:34.292881603 -0600
 <at>  <at>  -1498,14 +1498,14  <at>  <at> 
 		case 0: /* Send TERM signal */
 			if (talk)
-					"Sending processes the TERM signal");
+					"Sending processes configured via /etc/inittab the TERM signal");
 			kill(-(ch->pid), SIGTERM);
 			foundOne = 1;
 		case 1: /* Send KILL signal and collect status */
 			if (talk)
-					"Sending processes the KILL signal");
+					"Sending processes configured via /etc/inittab the KILL signal");
 			kill(-(ch->pid), SIGKILL);
Dark Templar | 27 Jun 21:36 2014

[sysvinit-devel] SysVinit: support unmounting root


In order to unmount root and properly shutdown lvm/encrypted devices/etc
I've written update for sysvinit. It allows to exec into another
application. It can be used to create new root filesystem in memory in
that application, switch to this new root, and then unmount old root and
shutdown underlying devices.

I've found similar feature request in the bugzilla:
There is even a similar patch attached.

I'm attaching my patch for sysvinit-2.88 and archive with diff for
inittab and test scripts. On test setup I put those scripts into
/usr/local/sbin/. The scripts mostly use static busybox, and right
before shutdown/reboot it invokes shell for debugging purposes. It does
not shut down any lvm/encrypted device/etc, but it's not so much to
write from here. In case of failing to exec into another process init
goes to next record in the inittab, that's why I don't remove plain
poweroff/reboot records. I think in that case it's better to shutdown at
least that way compared to panicking.

I'd like to have this patch merged into sysvinit. I've used gentoo linux
as a test platform for this feature.
Attachment (sysvinit-exec.patch): text/x-patch, 4654 bytes
Attachment (sysvinit-data.tar.bz2): application/x-bzip, 1277 bytes
Petter Reinholdtsen | 17 Apr 21:06 2014

[sysvinit-devel] Rename insserv options --dryrun and --showall?


In <URL: >,
there is a suggestion to rename insserv options --dryrun and --showall
to --dry-run and --show-all, to match other programs with such

I counted how many manual pages on my machine use --dryrun (1) and
--dry-run (17), so bringing insserv in line with the other tools seem
like a good idea.

I found no other --showall nor --show-all options, so it is less
relevant.  There are some starting with --show, and 34 starting with
--show-, so --show-all would be more in line with the rest, I guess.

The argument to change seem compelling to me, as it is a good thing to
have consistent options across all command line tools.  Any

I counted using commands similar to this:

 zgrep --  --dryrun /usr/share/man/man*/*|wc -l
 zgrep --  --dry-run /usr/share/man/man*/*|wc -l


Happy hacking
Petter Reinholdtsen

Petter Reinholdtsen | 10 Apr 09:42 2014

[sysvinit-devel] [patch] Get startpar building with clang

I've submitted startpar for review with Coverty, and it reported four
issues on <URL: >.  But the
project is not yet accepted, so I can not figure out which issues this
is.  So I had a look at building it with clang, and it found a few
issues with ignored return values and using a GCC extention.  The
following patch get rid of all warnings from Clang, but I am unsure if
this is the correct fix.  Any comments?

The timerdiff() change make sense to me, but simply continuing to ignore
exit values do not seem like a safe way forward.  But I did not take the
time to figure out why these exit values were ignored in the first
place.  Werner, do you remember?

Index: startpar.c
--- startpar.c	(revision 178)
+++ startpar.c	(working copy)
 <at>  <at>  -78,7 +78,11  <at>  <at> 
 # define attribute(attr)	__attribute__(attr)

-#define timerdiff(n,l) (extension({
(((n).tv_sec-(l).tv_sec)*1000)+(((n).tv_usec-(l).tv_usec)/1000); }))
+timerdiff(const struct timeval n,const struct timeval l)
+    return (((n).tv_sec-(l).tv_sec)*1000)+(((n).tv_usec-(l).tv_usec)/1000);

 typedef enum _boolean {false, true} boolean;
 extern char *optarg;
 <at>  <at>  -190,7 +194,7  <at>  <at> 
   int status;
   if (!splashpid)
-  TEMP_FAILURE_RETRY(waitpid(splashpid, &status, 0));
+  (void)TEMP_FAILURE_RETRY(waitpid(splashpid, &status, 0));

 void closeall(void)
 <at>  <at>  -258,7 +262,7  <at>  <at> 
   (void)signal(SIGTTIN, SIG_DFL);
   (void)signal(SIGTTOU, SIG_DFL);

-  TEMP_FAILURE_RETRY(dup2(2, 1));
+  (void)TEMP_FAILURE_RETRY(dup2(2, 1));
   execl("/sbin/splash", "splash", "-p", sbuf, "-t", tbuf, splashcfg, (char *)0);
 <at>  <at>  -472,13 +476,13  <at>  <at> 
   if (m && p->fd)
       sigset_t smask, omask;
-      TEMP_FAILURE_RETRY(close(1));
+      (void)TEMP_FAILURE_RETRY(close(1));
       if (open(m, O_RDWR) != 1)
-      TEMP_FAILURE_RETRY(dup2(1, 2));
+      (void)TEMP_FAILURE_RETRY(dup2(1, 2));
       sigaddset(&smask, SIGTTOU);
       sigprocmask(SIG_BLOCK, &smask, &omask);
 <at>  <at>  -492,7 +496,7  <at>  <at> 
-      TEMP_FAILURE_RETRY(dup2(2, 1));
+      (void)TEMP_FAILURE_RETRY(dup2(2, 1));

 <at>  <at>  -591,7 +595,7  <at>  <at> 
       (void)signal(SIGTTIN, SIG_DFL);
       (void)signal(SIGTTOU, SIG_DFL);

-      TEMP_FAILURE_RETRY(dup2(2, 1));
+      (void)TEMP_FAILURE_RETRY(dup2(2, 1));
       if (run_mode)
 <at>  <at>  -607,7 +611,7  <at>  <at> 

-   TEMP_FAILURE_RETRY(waitpid(pid, &r, 0));
+   (void)TEMP_FAILURE_RETRY(waitpid(pid, &r, 0));
    callsplash(spl, prg, arg);
    return WIFEXITED(r) ? WEXITSTATUS(r) : (WIFSIGNALED(r) ? 1 : 255);
 <at>  <at>  -734,8 +738,8  <at>  <at> 
 	  (void)signal(SIGTTIN, SIG_DFL);
 	  (void)signal(SIGTTOU, SIG_DFL);

-	  TEMP_FAILURE_RETRY(dup2(p->fd, 0));
-	  TEMP_FAILURE_RETRY(dup2(2, 1));
+	  (void)TEMP_FAILURE_RETRY(dup2(p->fd, 0));
+	  (void)TEMP_FAILURE_RETRY(dup2(2, 1));

 	  execlp(myname, myname, "-f", "--", p->name, NULL);


Happy hacking
Petter Reinholdtsen

Matias A. Fonzo | 27 Mar 22:21 2014

[sysvinit-devel] [DIFF]: Proposal for remove the options -f, -F of shutdown

Hi there,

According to the manpage of shutdown(8) a brief description says about 
the options -f, -F:

   The -f flag means `reboot fast'.  This only creates an advisory file 
/fastboot which can be tested by the system when it comes up again.  The 
boot rc file can test if  this  file
   is present, and decide not to run fsck(1) since the system has been 
shut down in the proper way.  After that, the boot process should remove 

   The  -F  flag means `force fsck'.  This only creates an advisory file 
/forcefsck which can be tested by the system when it comes up again.  
The boot rc file can test if this file
   is present, and decide to run fsck(1) with a special `force' flag so 
that even properly unmounted file systems get checked.  After that, the 
boot process should  remove  /forcefsck.

IMHO, this seems unsafe and unnecessary. Unsafe in the sense that 
`shutdown' -f or -F will try to create a file in / (or where it is 
defined, paths.h) -- the creation of the file can fail if the file 
system is in read-only mode; this can be done simply in the 
initialization script if the scripts checks the boot prompt line, to see 
if the user has passed: "fastboot", "forcefsck" via /proc/cmdline. This 
avoids the following: 1. Additional lines: remove the files (generally 
at the end) on the initialization script - 2. Code in shutdown. (I 
attach a diff just in case).