Bug 456

Summary: chkconfig sets priorities to -1
Product: xprint Reporter: Andrew Schultz <ajschult>
Component: Server: Config: startup scriptsAssignee: Roland Mainz <roland.mainz>
Status: RESOLVED FIXED QA Contact:
Severity: major    
Priority: high CC: pthomas, tobias.burnus, vdvo
Version: unspecified   
Hardware: All   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Bug Depends on:    
Bug Blocks: 632    
Attachments:
Description Flags
Patch for 2004-05-26-oldcvs_trunk
none
Patch for 2004-05-26-trunk none

Description Andrew Schultz 2004-04-10 21:34:27 UTC
> when you do a 'chkconfig --add xprint', you discover
> that all of the symlinks created in the various runlevels have "-1"
> in their name instead of the correct sequence number "61" that your
> chkconfig: statement calls out.

this is correct.

> This happens because the "chkconfig:" statement in your xprint script
> is too far down in the comment block than the chkconfig tool will look.
> If you move your chkconfig: statement to near the top of the comment
> block, everything gets much better!

also correct.

Moving the chkconfig part between the ident and the LSB/Unite Linux part gets it
working for me, but you might just break that.  I'm not sure what the rules are
for that.

#ident  "@(#)xprint   0.5    2003/02/14 gisburn"
#
# Basic support for IRIX-style "chkconfig"
# chkconfig: 2345 61 61
# description: Startup/shutdown script for Xprint server(s)
#
# Basic support for the Linux Standard Base Specification 1.0.0
Comment 1 Roland Mainz 2004-04-11 12:58:04 UTC
Andrew Schultz:
Can you make a patch which moves the chkconfig lines little bit higher (e.g.
that chkconfig works), please ? We have to test that patch then against LSB and
see if that works...
Comment 2 Tobias Burnus 2004-04-12 02:37:47 UTC
> Moving the chkconfig part between the ident and the LSB/Unite Linux part
> gets it working for me, but you might just break that.
> I'm not sure what the rules are for that.
In principle all /usr/lib/lsb/install_initd scripts ignore the chkconfig part.
Furthermore, there is no limit in the gLSB spec which limits the area where
install_initd looks for the LSB header.
I think both Debian's and SUSE's install_initd (SUSE's insserv, chkconfig) only
look at the LSB header.

> Can you make a patch which moves the chkconfig lines little bit higher (e.g.
> that chkconfig works), please?
If I get the complete script I can test against Debian (Woody/Sarge) and against
SUSE (8.x plus should have the same insserv/chkconfig script).

> We have to test that patch then against LSB and see if that works...
What do you mean by that? The LSB itself is only a written specification and
cannot be tested against. But the there is nothing which says were the LSB
initscript header has to come. Thus is should simply work. The question is how
the different implementations handle it. For instance RedHat's install_initd
might only look at the first n lines ...
Comment 3 Roland Mainz 2004-05-11 01:00:23 UTC
Tobias Burnus wrote:
> > Moving the chkconfig part between the ident and the LSB/Unite Linux part
> > gets it working for me, but you might just break that.
> > I'm not sure what the rules are for that.
>
> In principle all /usr/lib/lsb/install_initd scripts ignore the chkconfig part.
> Furthermore, there is no limit in the gLSB spec which limits the area where
> install_initd looks for the LSB header.

... but do the the _implementations_ (like SuSE) have any limits where the LSB
stuff can be specified ?

> I think both Debian's and SUSE's install_initd (SUSE's insserv, chkconfig) 
> only look at the LSB header.

Can anyone from SuSE confirm that ?

> > Can you make a patch which moves the chkconfig lines little bit higher (e.g.
> > that chkconfig works), please?
> If I get the complete script I can test against Debian (Woody/Sarge) and 
> against SUSE (8.x plus should have the same insserv/chkconfig script).

Do you mean the build script to make the RPM or only the "/etc/init.d/xprint"
script ?

> > We have to test that patch then against LSB and see if that works...
>
> What do you mean by that? The LSB itself is only a written specification and
> cannot be tested against.

Erm... yes... :) I mean an LSB-implementation such as SuSE.

> But the there is nothing which says were the LSB
> initscript header has to come. Thus is should simply work. The question is how
> the different implementations handle it. For instance RedHat's install_initd
> might only look at the first n lines 

Is there any docs which describes how large |n| is (I need that into to make a
patch) ?
Comment 4 Roland Mainz 2004-05-26 18:09:11 UTC
Created attachment 325 [details] [review]
Patch for 2004-05-26-oldcvs_trunk
Comment 5 Roland Mainz 2004-05-26 18:17:39 UTC
Patch checked-in into oldcvs_trunk:

Checking in xc/programs/Xserver/Xprint/etc/init.d/xprint;
/cvs/xprint/xprint/src/xprint_main/xc/programs/Xserver/Xprint/etc/init.d/xprint,v 
<--  xprint
new revision: 1.50; previous revision: 1.49
done

... I'll make a RPM snapshot in a few hours for testing.
Comment 7 Roland Mainz 2004-05-27 06:44:06 UTC
Created attachment 329 [details] [review]
Patch for 2004-05-26-trunk

Patch for Xorg trunk
Comment 8 Roland Mainz 2004-05-27 06:46:25 UTC
Comment on attachment 329 [details] [review]
Patch for 2004-05-26-trunk

Patch checked-in into Xorg truk...

Checking in xc/ChangeLog;
/cvs/xorg/xc/ChangeLog,v  <--  ChangeLog
new revision: 1.49; previous revision: 1.48
done
Checking in xc/programs/Xserver/Xprint/etc/init.d/xprint;
/cvs/xorg/xc/programs/Xserver/Xprint/etc/init.d/xprint,v  <--  xprint
new revision: 1.6; previous revision: 1.5
done
Mailing the commit message to xorg-commit@pdx.freedesktop.org...
Comment 9 Roland Mainz 2004-05-27 06:48:04 UTC
ajschult:
Can you verify whether the test RPM solves the problem, please (I do not have
anything newer than RH8 right now) ?
Comment 10 Andrew Schultz 2004-05-27 23:14:07 UTC
the RPM listed in comment 6 works great.
Comment 11 Roland Mainz 2004-05-29 23:07:52 UTC
Andrew Schultz wrote:
> the RPM listed in comment 6 works great.

Thanks!

Marking bug as FIXED.
Comment 12 Jovana 2017-05-25 17:24:49 UTC
*** Bug 10054 has been marked as a duplicate of this bug. ***

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.