[Solved]How to remove this warning message

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read this

[Solved]How to remove this warning message

Postby manmath on Sun Nov 07, 2010 1:59 pm

Hi All, thanks for the godsend LMDE. Please guide me how can I disable the warning message (see the bold text) during installation/upgradation.

apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be upgraded:
console-setup keyboard-configuration
2 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 891 kB of archives.
After this operation, 77.8 kB disk space will be freed.
Do you want to continue [Y/n]? y
Get:1 http://ftp.debian.org/debian/ squeeze/main keyboard-configuration all 1.58 [255 kB]
Get:2 http://ftp.debian.org/debian/ squeeze/main console-setup all 1.58 [636 kB]
Fetched 891 kB in 1min 13s (12.2 kB/s)
Reading changelogs... Done
Preconfiguring packages ...
(Reading database ... 84588 files and directories currently installed.)
Preparing to replace keyboard-configuration 1.57 (using .../keyboard-configuration_1.58_all.deb) ...
Unpacking replacement keyboard-configuration ...
Preparing to replace console-setup 1.57 (using .../console-setup_1.58_all.deb) ...
Unpacking replacement console-setup ...
Processing triggers for man-db ...
Setting up keyboard-configuration (1.58) ...
insserv: warning: script 'K01mintsystem' missing LSB tags and overrides
insserv: warning: script 'mintsystem' missing LSB tags and overrides
insserv: warning: script 'K01mintsystem' missing LSB tags and overrides
insserv: warning: script 'mintsystem' missing LSB tags and overrides

Setting up console-setup (1.58) ...
localepurge: Disk space freed in /usr/share/locale: 0 KiB
localepurge: Disk space freed in /usr/share/man: 0 KiB
localepurge: Disk space freed in /usr/share/gnome/help: 0 KiB
localepurge: Disk space freed in /usr/share/omf: 0 KiB

Total disk space freed by localepurge: 0 KiB
Last edited by manmath on Fri Nov 12, 2010 6:28 pm, edited 1 time in total.
still looking for a better *nix?
manmath
Level 2
Level 2
 
Posts: 52
Joined: Sat Jan 30, 2010 11:22 pm
Location: india

Linux Mint is funded by ads and donations.
 

Re: How to remove this warning message

Postby Leit on Mon Nov 08, 2010 2:25 am

one of your /etc/init.d/ scripts isn't LSB conformable.
every script should have a "header" like:

Code: Select all
#! /bin/sh

### BEGIN INIT INFO
# Provides:      servicename
# Required-Start:   $servicename $servicename //Means the services which has to be startet before running the script
# Required-Stop:   $servicename $servicename //Means the services which has to be stopped before stopping the script ... should be the same as in "Required-Start"
# Default-Start:   2 3 4 5 //runlevels where the script should run
# Default-Stop:      1    //runlevels where the script shouldn't run
# Short-Description:   enter text like you want // a description of the Daemon... you're free to write in what you want
### END INIT INFO



you should delete everything after "//" and even the "//" if you're using this "template".

~ Leit

EDIT: but normaly it's only a warning and nothing you should REALLY worry about.
It is interesting the way we create complex and powerful tools to save us
from the complex and powerful tools we created previously.
User avatar
Leit
Level 4
Level 4
 
Posts: 239
Joined: Tue May 04, 2010 3:05 am
Location: Germany

[Solved] How to remove this warning message

Postby manmath on Mon Nov 08, 2010 9:36 am

Followed you instruction and changed the header of mintsystem in /etc/init.d. That solved the problem.. Now no more warning message in upgrading/installing.
Thanks Leiton!
still looking for a better *nix?
manmath
Level 2
Level 2
 
Posts: 52
Joined: Sat Jan 30, 2010 11:22 pm
Location: india

Re: How to remove this warning message

Postby Leit on Mon Nov 08, 2010 9:48 am

Leiton? :lol:

no problem... would be nice if you could add something like [solved] to the topic of your thread, so that others can see that the problem is solved.

greetings, Leit
It is interesting the way we create complex and powerful tools to save us
from the complex and powerful tools we created previously.
User avatar
Leit
Level 4
Level 4
 
Posts: 239
Joined: Tue May 04, 2010 3:05 am
Location: Germany

Re: How to remove this warning message

Postby mads on Fri Nov 26, 2010 8:16 am

Leit wrote:one of your /etc/init.d/ scripts isn't LSB conformable.
every script should have a "header" like:

Code: Select all
#! /bin/sh

...


Sorry, should the header be changed to "#! /bin/sh" or "#!/bin/sh"?
Thanks
User avatar
mads
Level 6
Level 6
 
Posts: 1309
Joined: Wed Nov 03, 2010 3:44 pm

Re: [Solved]How to remove this warning message

Postby Leit on Fri Nov 26, 2010 10:46 am

#! /bin/sh is equivalent to #!/bin/sh

#!/bin/sh is the classic method but as long as the whitespace is only between #! and /bin/* it doesnt matter on "modern" systems

tryed with a testscript:
Code: Select all
#!/bin/sh
echo test

output: test

Code: Select all
#! /bin/sh
echo test


output: test

Code: Select all
#!/bin/blub
echo test


output: bash: ./test: /bin/blub: Defekter Interpreter: No such file or directory

Code: Select all
#! /bin/blub
echo test


output: bash: ./test: /bin/blub: Defekter Interpreter: No such file or directory

greetings,

Leit
Last edited by Leit on Fri Nov 26, 2010 8:49 pm, edited 1 time in total.
It is interesting the way we create complex and powerful tools to save us
from the complex and powerful tools we created previously.
User avatar
Leit
Level 4
Level 4
 
Posts: 239
Joined: Tue May 04, 2010 3:05 am
Location: Germany

Re: [Solved]How to remove this warning message

Postby mads on Fri Nov 26, 2010 11:09 am

Leit wrote:#! /bin/sh is equivalent to #!/bin/sh

#!/bin/sh is the classic method but as long as the whitespace is only between #! and /bin/* it doesnt matter on "modern" systems


Leit, thank you so much for your reply.

I asked this question because like the OP, I also got the error messages: "insserv: warning: script 'mintsystem' missing LSB tags and overrides", when running "apt-get dist-upgrade" command. Then I saw this thread and changed the header in /etc/init.d/mintsystem file from "#!/bin/bash" to "#! /bin/sh".
But it didn't stop the error messages. Yesterday, I decided to change the header again, this time to "#!/bin/sh". I will wait a week to see if those errors happen again or not. Either way, I will write a new post about it.
User avatar
mads
Level 6
Level 6
 
Posts: 1309
Joined: Wed Nov 03, 2010 3:44 pm

Re: [Solved]How to remove this warning message

Postby indaymadel on Fri Nov 26, 2010 8:08 pm

Which one should I edit? What file?
Get started building backlinks using my free backlinks collection.
indaymadel
Level 2
Level 2
 
Posts: 88
Joined: Thu Sep 30, 2010 8:57 pm

Re: [Solved] How to remove this warning message

Postby Leit on Fri Nov 26, 2010 8:48 pm

@indaymadel:
you should read manmaths post:
manmath wrote:Followed you instruction and changed the header of mintsystem in /etc/init.d. That solved the problem.. Now no more warning message in upgrading/installing.
Thanks Leiton!

/etc/init.d/mintsystem

@Mads: no problem, but you have to mind, that my "scriptheader" is only a template, you have to add the right files/programs, the best way would be to ask manmath, what he exactly wrote in his mintsystemscript, cause on his PC it seems to work :lol:

greetings,

Leit
It is interesting the way we create complex and powerful tools to save us
from the complex and powerful tools we created previously.
User avatar
Leit
Level 4
Level 4
 
Posts: 239
Joined: Tue May 04, 2010 3:05 am
Location: Germany

Re: [Solved] How to remove this warning message

Postby mads on Fri Nov 26, 2010 9:25 pm

Leit wrote:@Mads: no problem, but you have to mind, that my "scriptheader" is only a template, you have to add the right files/programs, the best way would be to ask manmath, what he exactly wrote in his mintsystemscript, cause on his PC it seems to work :lol:


Yes, you are right Leit. I wish manmath would write a brand new step to step How To about it. I mean it. :lol:
In the mean time. I will not focus too much on it. Like you said: "...but normaly it's only a warning and nothing you should REALLY worry about."
And thank you for writing "REALLY" and not "really". it made me feel MUCH better. :lol:
User avatar
mads
Level 6
Level 6
 
Posts: 1309
Joined: Wed Nov 03, 2010 3:44 pm

Re: [Solved]How to remove this warning message

Postby Leit on Fri Nov 26, 2010 9:59 pm

thank you :D :lol:

the problem is... the most people ain't got this message... I ain't got it in LM 7 Main, LM 8 KDE (I've never used the Main version of LM 8 ), LM 9 Main and LM 9 KDE and i even ain't got it on LM10 (always x64), so you ain't have to worry about this message but about the system itself.. something has went wrong if you get such a message, could be a program you installed or a configuration you made... or the whole installation has a failure (which I aint expect).

sorry for destroying you're good feeling :lol: , but i've wanted to give you that hint.
but just like i said, i think it's simply a configuration problem caused by some program, and home-PC's ain't need to be LSB-conformable, but if you're working on a firm with linux and got secure configurated PC's you shouldn't be able to execute script without a LSB-Header.

greeting,

~Leit

and now i'm going to sleep...
Last edited by Leit on Tue Nov 30, 2010 4:53 am, edited 1 time in total.
It is interesting the way we create complex and powerful tools to save us
from the complex and powerful tools we created previously.
User avatar
Leit
Level 4
Level 4
 
Posts: 239
Joined: Tue May 04, 2010 3:05 am
Location: Germany

Re: [Solved]How to remove this warning message

Postby mads on Mon Nov 29, 2010 3:54 pm

Leit wrote:.. something has went wrong if you get such a message, could be a program you installed or a configuration you made... or the whole installation has a failure (which I aint expect).

In the absence of a solution to this issue (manmath, where are you?), I edited /etc/init.d/mintsystem script and replaced the original lines

Code: Select all
#!/bin/bash

/usr/lib/linuxmint/mintSystem/mint-adjust.py


with this (SOURCE: https://bugs.launchpad.net/linuxmint/+bug/681238):
Code: Select all
#!/bin/sh -e

### BEGIN INIT INFO
# Provides: mintsystem
# Required-Start: mountkernfs $local_fs
# Required-Stop: $local_fs
# Should-Start:
# Should-Stop:
# Default-Start: S
# Default-Stop: 0 6
# Short-Description: Start Various mint services.
### END INIT INFO

/usr/lib/linuxmint/mintSystem/mint-adjust.py


And finally ran
Code: Select all
sudo dpkg-reconfigure sysv-rc

with success
Code: Select all
info: Checking if it is safe to convert to dependency based boot.
info: Reordering boot system, log to /var/lib/insserv/run-20101129T2009.log
success: Enabled dependency based boot system.


Leit, could you please explain a little bit more what this code is/does?
Is there anybody who could confirm this? Or has a better solution. Thanks.
User avatar
mads
Level 6
Level 6
 
Posts: 1309
Joined: Wed Nov 03, 2010 3:44 pm

Re: [Solved]How to remove this warning message

Postby Leit on Mon Nov 29, 2010 4:48 pm

you mean:
Code: Select all
#!/bin/sh -e

### BEGIN INIT INFO
# Provides: mintsystem
# Required-Start: mountkernfs $local_fs
# Required-Stop: $local_fs
# Should-Start:
# Should-Stop:
# Default-Start: S
# Default-Stop: 0 6
# Short-Description: Start Various mint services.
### END INIT INFO

?

your script says:
it Provides Mintsystem (how hard to find out :lol:)
to start it requires the local filesystem.. I aint know whats mountkernfs, but I would say it means, that the kernel must be startet
it stops when the local filesystem is unmounted.
it doesn't wishes any programs started or stopped.
Default start... I see this "S" argument for the first times, I think it means all normal runmodes 1-5
Stops on shutdown or Reboot.
Short Description is selfexplaining.
It is interesting the way we create complex and powerful tools to save us
from the complex and powerful tools we created previously.
User avatar
Leit
Level 4
Level 4
 
Posts: 239
Joined: Tue May 04, 2010 3:05 am
Location: Germany

Re: [Solved]How to remove this warning message

Postby mads on Mon Nov 29, 2010 5:02 pm

Thank you so much. :D

What about the header "#!/bin/sh -e", compared to "#!/bin/sh"?
Thanks.
User avatar
mads
Level 6
Level 6
 
Posts: 1309
Joined: Wed Nov 03, 2010 3:44 pm

Re: [Solved]How to remove this warning message

Postby Leit on Mon Nov 29, 2010 5:19 pm

#!/bin/sh is the interpreter, also it could be #!/bin/bash or #!/bin/tsh or something else, but sh is the normal linuxshell.
-e stands for errexit, it means the script to stop when an error occurs.
It is interesting the way we create complex and powerful tools to save us
from the complex and powerful tools we created previously.
User avatar
Leit
Level 4
Level 4
 
Posts: 239
Joined: Tue May 04, 2010 3:05 am
Location: Germany

Re: [Solved]How to remove this warning message

Postby mads on Mon Nov 29, 2010 5:30 pm

Leit wrote:#!/bin/sh is the interpreter, also it could be #!/bin/bash or #!/bin/tsh or something else, but sh is the normal linuxshell.

Thanks. The person who had posted this workaround, had also dropped a little comment about this:
"line 1 used to be #!/bin/bash, but this script runs perfectly also with dash ..."

Leit wrote:-e stands for errexit, it means the script to stop when an error occurs.

Thank you sir. :D
User avatar
mads
Level 6
Level 6
 
Posts: 1309
Joined: Wed Nov 03, 2010 3:44 pm

Re: [Solved]How to remove this warning message

Postby Leit on Mon Nov 29, 2010 6:15 pm

no problem^^
It is interesting the way we create complex and powerful tools to save us
from the complex and powerful tools we created previously.
User avatar
Leit
Level 4
Level 4
 
Posts: 239
Joined: Tue May 04, 2010 3:05 am
Location: Germany

Re: [Solved]How to remove this warning message

Postby Leit on Tue Nov 30, 2010 5:08 am

before I forget, in /etc/init.d/skeleton you can find a really good commented init-script-template.

greetings,

~ Leit
It is interesting the way we create complex and powerful tools to save us
from the complex and powerful tools we created previously.
User avatar
Leit
Level 4
Level 4
 
Posts: 239
Joined: Tue May 04, 2010 3:05 am
Location: Germany

Linux Mint is funded by ads and donations.
 

Return to Newbie Questions

Who is online

Users browsing this forum: No registered users and 3 guests