Bugzilla will be upgraded to version 5.0 on a still to be determined date in the near future. The original upgrade date has been delayed.
Bug 1988 - "network restart" doesn't work
"network restart" doesn't work
Product: Red Hat Raw Hide
Classification: Retired
Component: initscripts (Show other bugs)
i386 Linux
low Severity low
: ---
: ---
Assigned To: Bill Nottingham
Depends On:
  Show dependency treegraph
Reported: 1999-04-04 17:10 EDT by Jay Freeman
Modified: 2014-03-16 22:09 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 1999-04-06 12:25:26 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Jay Freeman 1999-04-04 17:10:31 EDT
[root(6)@ironclad init.d]# network restart
./network: ./network: No such file or directory
./network: ./network: No such file or directory

At first I assumed this was because it wasn't finding the
script when it did $0 because "." wasn't on the scripts path
(was on mine, but I did a printenv from inside the script
and it wasn't on its).  But then I changed the "$0 stop" to
"echo $0 stop" and got back "./network stop" which is
including the ./ which should be required to get around the
path problem.
Comment 1 Preston Brown 1999-04-05 16:18:59 EDT
this works for me in both 5.2 and 5.9.x.  You must have messed up
something on your system.
Comment 2 Jay Freeman 1999-04-05 18:31:59 EDT
I figured out why it happens (don't know why this didn't occur to me
before), and it IS a "problem" with the script.  The script contains
the line:

cd /etc/sysconfig/network-scripts

:before it gets to the case statement to see how it was called, which
bumps you (the script) out of the init.d directory, causing "network
restart" or "./network restart" to not function.
/etc/rc.d/init.d/network restart DOES function because the directory
in that case is explicitly named.  I understand if this is intended
functionality and not a problem, but it was rather disconcerting when
I tried it because the other scripts don't have a problem when run
like that.
Comment 3 Bill Nottingham 1999-04-06 12:25:59 EDT
fixed in latest initscripts (3.99-2).

Note You need to log in before you can comment on or make changes to this bug.