Thank jgt That fixed that particular problem. Now I am getting a curl error though. If I run the curl from the command line I have no issue but when it is called from the php script which calls the bash script I get this error
The curl command works fine when I do it from the command line.
Any idea why this is happening?
---------- Post updated at 03:36 PM ---------- Previous update was at 03:34 PM ----------
This is the curl command (I have taken out the username and password
Hello everybody:
Im trying to run the following script on my sol9 machine:
line=''
((lineCount= 0))
export lineCount
more /tmp/MSISDNs | wc -l > /tmp/tmp
cat /tmp/tmp | read lineCount
export lineCount;
while (( lineCount > 0 ))
do
line= tail -$lineCount... (5 Replies)
I'm just not sure where to start looking into this. I want to be able to create switches for my script. Back in the day I'd make my scripts interactive...you know:
echo "what report do you want"
echo "A)boxes with errors"
echo "B)boxes with more than 5 errors"
echo "C)Service groups that have... (3 Replies)
Hi All,
I need to pass a variable to perl script from bash script, where in perl i am using if condition. Here is the cmd what i am using in perl
FROM_DATE="06/05/2008"
TO_DATE="07/05/2008"
"perl -ne ' print if ( $_ >="$FROM_DATE" && $_ <= "$TO_DATE" ) ' filename"
filename has... (10 Replies)
How do I pass a bash variable to a javascript?
I've tried
#!/bin/bash
echo "Content-type: text/html"
echo ""
echo "<html>"
echo "<head>"
counter=0
echo '<script>
window.parent.document.forms.counter.value = "$counter";
</script>'
I have an iframe script which I am trying to pass a... (3 Replies)
Hello,
How can I pass a variable into a 2nd file? I'm running a script:
ls -la $1 >pem99
cat pem99 | awk '{ print $3}' >us99
cat us99 | read us98
This then tells me the owner of a file.
my second file is:
echo OWNER GROUP OTHERS
echo
echo --data-- $us98
... (2 Replies)
Hello everyone,
I've been looking how to pass variables between bash and php-cli in 1 file. So far i got this:
#!/bin/bash
echo "This is bash"
php << EOF
<?php
echo "This is php\n";
?>
EOF
I would now like to be able to pass a variable declared in the bash to the php. I already... (0 Replies)
Would really appreciate it if someone could point out my mistake in this line of code, i've been staring blankly at it trying everything i can think of some time now and coming up with nothing.
#!/bin/bash
echo "Enter Username"
read Username
awk -F: -v var=${Username} '/^var:/... (9 Replies)
I'm trying to write a basic bash script that takes input you give (what directory, if any, what name, if any ....) and passes the information to find.
I'm trying to just create a string with all variables and then pass it to find. So far I have this extremely simple:
#!/bin/bash -f
... (2 Replies)
Hi,
I wanted to pass an argument to a bash script. So that the argument is used inside the awk command inside the bash script.
I know the noraml way of passing argument to a bash script as below :
sh myScript.sh abc
Inside the bash script i can use like this
myArg1=$1
wc $myArg
But... (8 Replies)
Hi All,
I need to pass a variable from bash script to perl script and in the perl script i am using those variables in the sql query but its giving
error :
Use of uninitialized value $ENV{"COUNTRYCD"} in concatenation (.) or string at /GIS_ROOT/custom/tables/DBread_vendor.pl line 50.
Can ... (6 Replies)
Discussion started by: NileshJ
6 Replies
LEARN ABOUT DEBIAN
pidfilehack
pidfilehack(8) System Manager's Manual pidfilehack(8)NAME
pidfilehack - work around daemons that always fork
SYNOPSIS
pidfilehack servicename pidfile command [parameters]
DESCRIPTION
pidfilehack is used to work around daemons that insist on forking into the background, but that do write a correct pid file.
pidfilehack forks the actual service, then waits for the pidfile to be written. Once it can read the pid from the pidfile it will tell
minit the real pid and quit.
USAGE
usually pidfilehack is symlinked as run command of a service.
servicename
the name of the service pidfilehack is installed for.
pidfile
the filename to read the pid from
command
the real command to start
parameters
additional parameters for the command
A typical use of this command will look like this:
/etc/minit/apache
/etc/minit/apache/params
apache
/var/run/apache.pid
apachectl
start
/etc/minit/apache/run
-> /sbin/pidfilehack
AUTHOR
minit was written by Felix von Leitner and can be downloaded from his page at http://www.fefe.de/minit/
This manpage was written by Erich Schubert <erich@debian.org> for the Debian GNU/Linux operating system.
SEE ALSO msvc(8), pidfilehack(8)pidfilehack(8)