| View previous topic :: View next topic |
| Author |
Message |
miroR l33t

Joined: 05 Mar 2008 Posts: 826
|
Posted: Sat Feb 06, 2010 5:53 pm Post subject: bash script won't run in bg anymore |
|
|
It's a duplicate. Pls. take a look at my post here:
http://groups.google.com/group/gnu.bash.bug/browse_thread/thread/22cbfddd174c56a2#
The reason I'm also posting it here is that I am not sure if something else might be the matter in question for the strange bash behavior, in other wirds whether something else in my Gentoo is not causing this.
In short, if someone else has similar issues, let's fix this together...
And I'll post a version more understandable and simplified of the script on gnu.bash.bug above. In the future it might be worthy of a little reference to newer newbies than me.
#!/bin/bash
#
# this script is named:
# dvd_Write_and_md5_check_with_SCSI_syntax_Schily.sh
#
# The aim of the script is burning the DVD and checking that it's done well through md5 fingerprint.
#
# It's run like this, to write on /dev/hda:
#
# dvd_Write_and_md5_check_with_SCSI_syntax_Schily.sh 12 0 0 a ISO_FILE.iso ISO_FILE.iso.md5 &
# or to write on /dev/hdc
#
# dvd_Write_and_md5_check_with_SCSI_syntax_Schily.sh 12 1 0 c ISO_FILE.iso ISO_FILE.iso.md5 &
#
# for the parts "0 0" in "... 12 0 0 a ..." or "1 0" in "... 1 0 c ...", it's the scsi syntax
# of the program, pls. do: "man cdrecord" to find out.
#
# the play line just alerts that the script has burned the disk or finished, respectively.
#
# I wrote this script, because I could very easily burn on all 4 DVD drives, at the same time,
# as they would all do the work without any further assistence (old PATA, so it's slow,
# but it's little work). Just check the md5
# in the file already containing the md5's from previous burns and accept deleting the image
# of the new disk that was just burned if it was correct... Worked up to bash 4.0.28 (included).
# But with bash 4.0.35 that is no longer the case. It stops and doesn't do more than one job
# in the background...
#
# Well, I need to solve this, so I took time rewriting all of it clearly, to my best .
#
iso_file=$5_$4
iso_md5_file=$6
cdrecord -v speed=$1 dev=100$2,$3,0 $5
play -q /usr/share/sounds/KDE-Sys-Log-In-Short.ogg
eject /dev/hd$4
eject /dev/hd$4 -t
readcd dev=100$2,$3,0 f=$iso_file
md5sum $iso_file >> $iso_md5_file
play -q /usr/share/sounds/KDE-Sys-Log-In-Short.ogg
cat $iso_md5_file
echo "Remove $iso_file?"
rm -i $iso_file
eject /dev/hd$4 |
|
| Back to top |
|
 |
miroR l33t

Joined: 05 Mar 2008 Posts: 826
|
Posted: Sun Feb 07, 2010 9:58 am Post subject: Re: bash script won't run in bg anymore |
|
|
| miroR wrote: | ...not sure if something else might be the matter in question for the strange bash behavior...
#
#
# ... Worked up to bash 4.0.28 (included).
# But with bash 4.0.35 that is no longer the case. It stops and doesn't do more than one job
# in the background...
#
|
And I tried ~amd64 unstable readline_6.1 I think, and bash-4.0_p37 I think it was.
The same.
Then I tried masking readline and bash in package.mask and downgrading to really old versions (since the 4.0_p28 isn't availabel anymore. And I now have:
sys-libs/readline 5.2_p14
app-shells/bash 3.1_p17
installed.
Then I thought it could be the konsole of KDE which I use for most anything. And tried and found out it's just the same in the plain old-fashioned terminal (Ctrl+Alt+F2 e.g.).
And, judging by the fact that any of the versions produce the same miserable results, it could be an issue of something rather different breaking my system, and not bash nor readline bug at all.
What could this be? All is well in the system. The system is updated and shiny, but this is mind-boggling.
Any ideas will be greatly appreciated. I don't even badly need the abiliity to use that script at this time. It's just puzzled me so badly by now that I've grown curious immensely.
Thanks! |
|
| Back to top |
|
 |
miroR l33t

Joined: 05 Mar 2008 Posts: 826
|
Posted: Sun Feb 07, 2010 11:16 am Post subject: Re: bash script won't run in bg anymore |
|
|
| miroR wrote: | ...any of the versions ... same miserable results ... something rather different .. not bash nor readline bug ...
What could this be?...
Any ideas will be greatly appreciated. ...
Thanks!... |
... for the ideas, Miro!
It's solved.
Do you want to know what it was?
Post a "Tell me!" note on this thread. Right now. And pay 1,000€ on my account upfront.
No, it was just the sox winding me around. Really.
As soon as I took out and crush to pieces the lines:
play -q /usr/share/sounds/KDE-Sys-Log-In-Short.ogg
all is well again.
(play is part of sox package).
Who could have thought?!
Cheers! |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|