Bug 494861 - Syntax error from /etc/rc.d/init.d/halt
Summary: Syntax error from /etc/rc.d/init.d/halt
Keywords:
Status: CLOSED DUPLICATE of bug 480799
Alias: None
Product: Fedora
Classification: Fedora
Component: initscripts
Version: 10
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Bill Nottingham
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-04-08 12:41 UTC by Mary Ellen Foster
Modified: 2014-03-17 03:18 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-04-09 09:20:49 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Mary Ellen Foster 2009-04-08 12:41:09 UTC
Description of problem:
Whenever I shut down or reboot my computer, I now get a warning regarding line 178 of /etc/rc.d/rc0.d/S01halt or /etc/rc.d/rc6.d/S01reboot (which are both /etc/rc.d/init.d/halt) saying that there is a missing "]" character. The line in question doesn't actually look suspicious ...

Rebooting still works (i.e., the computer restarts after the error), but shutting down now just prints "system halted" but does not actually turn off the machine.


Version-Release number of selected component (if applicable):
initscripts-8.86.2-1.i386


How reproducible:
Every time, on two different computers

Comment 1 Bill Nottingham 2009-04-08 14:46:26 UTC
Please try 8.86.3-1.

Comment 2 James Ralston 2009-04-08 15:11:18 UTC
Mary, the problem is that line 178 has a syntax error.  Specifically, this:

[ "$INIT_HALT" != "HALT"] && HALTARGS="$HALTARGS -p"

Must be this:

[ "$INIT_HALT" != "HALT" ] && HALTARGS="$HALTARGS -p"

The space is required for the shell to treat '"HALT"' and ']' as two separate lexical tokens, instead of a single token '"HALT"]'.

Comment 3 Mary Ellen Foster 2009-04-09 09:20:49 UTC

*** This bug has been marked as a duplicate of bug 480799 ***


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