Sponsored Content
Top Forums Web Development Passing variable from PHP to bash script Post 303009118 by kieranfoley on Saturday 9th of December 2017 03:02:03 AM
Old 12-09-2017
Thanks jgt. I get what you are saying. It definitely has something to do with how my apache webserver communicates with seieadpa01. I will investigate this.

---------- Post updated at 08:02 AM ---------- Previous update was at 07:53 AM ----------

This has been resolved. I ran the following command on my apache server and now I can connect without issues.

Code:
setsebool -P httpd_can_network_connect=1

Thanks again!
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

passing variable to my script

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)
Discussion started by: aladdin
5 Replies

2. Shell Programming and Scripting

Passing options to a bash script

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)
Discussion started by: DeCoTwc
3 Replies

3. Shell Programming and Scripting

passing variable from bash to perl from bash script

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)
Discussion started by: arsidh
10 Replies

4. Shell Programming and Scripting

Passing Bash variable to javascript

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)
Discussion started by: numele
3 Replies

5. Shell Programming and Scripting

help passing variable from script

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)
Discussion started by: Grueben
2 Replies

6. Shell Programming and Scripting

Passing variables from bash to php-cli

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)
Discussion started by: robbee
0 Replies

7. Shell Programming and Scripting

Trouble with passing Variable from bash to awk gsub command

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)
Discussion started by: Nostyx
9 Replies

8. Shell Programming and Scripting

Passing string as variable(s) in bash

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)
Discussion started by: Starting_Leaf
2 Replies

9. Shell Programming and Scripting

Passing arguments to a bash script

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)
Discussion started by: shree11
8 Replies

10. Shell Programming and Scripting

Passing variable from bash to perl script

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
VLOGGER(1)						User Contributed Perl Documentation						VLOGGER(1)

NAME
vlogger - flexible log rotation and usage tracking in perl SYNOPSIS
vlogger [OPTIONS]... [LOGDIR] DESCRIPTION
Vlogger is designed to make webserver log rotation simple and easy to manage. It deals with VirtualHost logs automatically, so only one directive is required to manage all hosts on a webserver. Vlogger takes piped output from Apache or another webserver, splits off the first field, and writes the logs to logfiles in subdirectories. It uses a filehandle cache to avoid resource limitations. It will start a new logfile at the beginning of a new day, and optionally start new files when a certain filesize is reached. It can maintain a symlink to the most recent log for easy access. Optionally, host parsing can be disabled for use in ErrorLog directives. To use vlogger, you need to add a "%v" to the first part of your LogFormat: LogFormat "%v %h %l %u %t "%r" %>s %b "%{Referer}i" "%{User-Agent}i"" combined Then call it from a customlog: CustomLog "| /usr/sbin/vlogger -s access.log -u www-logs -g www-logs /var/log/apache" combined OPTIONS
Options are given in short format on the command line. -a Do not autoflush files. This may improve performance but may break logfile analyzers that depend on full entries in the logs. -e ErrorLog mode. In this mode, the host parsing is disabled, and the file is written out using the template under the specified LOGDIR. -n Disables rotation. This option disables rotation altogether. -f MAXFILES Maximum number of filehandles to keep open. Defaults to 100. Setting this value too high may result in the system run- ning out of file descriptors. Setting it too low may affect performance. -u UID Change user to UID when running as root. -g GID Change group to GID when running as root. -t TEMPLATE Filename template using Date::Format codes. Default is "%m%d%Y-access.log", or "%m%d%Y-error.log". When using the -r option, the default becomes "%m%d%Y-%T-access.log" or "%m%d%Y-%T-error.log". -s SYMLINK Specifies the name of a symlink to the current file. -r SIZE Rotate files when they reach SIZE. SIZE is given in bytes. -d CONFIG Use the DBI usage tracker. -h Displays help. -v Prints version information. DBI USAGE TRACKER
Vlogger can automatically keep track of per-virtualhost usage statistics in a database. DBI and the relevant drivers (eg. DBD::mysql) needs to be installed for this to work. Create a table in your database to hold the data. A "mysql_create.sql" script is provided for using this feature with MySQL. Configure the dsn, user, pass and dump values in the vlogger-dbi.conf file. The "dump" parameter controls how often vlogger will dump its stats into the database (the default is 30 seconds). Copy this file to somewhere convienient on your filesystem (like /etc/apache/vlogger-dbi.conf) and start vlogger with "-d /etc/apache/vlogger-dbi.conf". You might want to use this feature to easily bill customers on a daily/weekly/monthly basis for bandwidth usage. SEE ALSO
cronolog(1), httplog(1) BUGS None, yet. AUTHORS Steve J. Kondik <;shade@chemlab.org> WWW: http://n0rp.chemlab.org/vlogger perl v5.8.6 2005-03-18 VLOGGER(1)
All times are GMT -4. The time now is 03:51 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy