How to remove system notification "Completed" after execution of the script?

Here is the script:

my $timer1 = 11;
my $timer2 = 2;

my $parent = $$;
my $child = fork();

print "parent: ".$parent;
print "\nchild: ".$child;

if ( $$ == $parent ) {
 my $killchild = kill("TERM", $child);
 print "\nParent kill child\n";
 my $killparent = kill("TERM", $parent);
 print "\nChild kill power\n";

Here is the output when parameters timer1 > timer2:

[root@server user]# ./
parent: 3580
parent: 3580
child: 3581
Parent kill child

Here is the output when timer1 settings < timer2:

[root@server user]# ./
parent: 3587
parent: 3587
child: 0
Child kill power

How to remove system notification "Completed" from the output when timer1 < timer2?
September 19th 19 at 00:23
1 answer
September 19th 19 at 00:25
For example, to redirect STDERR of the script to /dev/null.
Perl, all this is irrelevant, the message generated by the shell, and to influence it from the app you can't.


P. S. the questions of the level of "why suddenly need to kill the parent from child?" will not ask :-)

Find more questions by tags LinuxPerl