I've wrote a script which reads a log-file and write it into an Database. Because of many different line-types it would take about 30 minits executiontime.
Log-Files got:
~20 MB filesize
~200.000 lines
If I include it to my website, the script would run only with small log-files(~2MB tested), it won't run till end if i'm using normal-log-files. I included the script like this:
<?php
include "logLauncher/main.php";
?>
The strange thing is if i using a syscall it would run.
<?php
system("php5 logLauncher/main.php");
?>
Three last entrys in file: /var/log/apache2/error.log
[Wed Aug 26 11:11:22.210994 2015] [:error] [pid 18893] [client 192.168.0.100:54746] PHP 1. {main}() /var/www/cowrean_logs/alpha/main.php:0, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=2&left=1&right=1&event=5&trigger=18200&focus=2&filter1=&encounter=11982&&start=2015-05-27%2019:59:07&end=2015-05-27%2020:00:48
[Wed Aug 26 11:11:22.211004 2015] [:error] [pid 18893] [client 192.168.0.100:54746] PHP 2. include() /var/www/cowrean_logs/alpha/main.php:121, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=2&left=1&right=1&event=5&trigger=18200&focus=2&filter1=&encounter=11982&&start=2015-05-27%2019:59:07&end=2015-05-27%2020:00:48
[Wed Aug 26 11:11:22.211014 2015] [:error] [pid 18893] [client 192.168.0.100:54746] PHP 3. include() /var/www/cowrean_logs/alpha/mod_focus.php:192, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=2&left=1&right=1&event=5&trigger=18200&focus=2&filter1=&encounter=11982&&start=2015-05-27%2019:59:07&end=2015-05-27%2020:00:48
[Wed Aug 26 11:11:28.131411 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP Notice: A session had already been started - ignoring session_start() in /var/www/cowrean_logs/alpha/main.php on line 47, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=2&left=1&right=1&event=5&trigger=18200&focus=2&filter1=&encounter=11982&start=2015-05-27%2019:59:07&end=2015-05-27%2020:00:48
[Wed Aug 26 11:11:28.131462 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP Stack trace:, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=2&left=1&right=1&event=5&trigger=18200&focus=2&filter1=&encounter=11982&start=2015-05-27%2019:59:07&end=2015-05-27%2020:00:48
[Wed Aug 26 11:11:28.131481 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP 1. {main}() /var/www/cowrean_logs/alpha/main.php:0, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=2&left=1&right=1&event=5&trigger=18200&focus=2&filter1=&encounter=11982&start=2015-05-27%2019:59:07&end=2015-05-27%2020:00:48
[Wed Aug 26 11:11:28.131494 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP 2. session_start() /var/www/cowrean_logs/alpha/main.php:47, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=2&left=1&right=1&event=5&trigger=18200&focus=2&filter1=&encounter=11982&start=2015-05-27%2019:59:07&end=2015-05-27%2020:00:48
[Wed Aug 26 11:11:29.080694 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP Notice: A session had already been started - ignoring session_start() in /var/www/cowrean_logs/alpha/main.php on line 47, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=1&left=4&right=0
[Wed Aug 26 11:11:29.080728 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP Stack trace:, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=1&left=4&right=0
[Wed Aug 26 11:11:29.080741 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP 1. {main}() /var/www/cowrean_logs/alpha/main.php:0, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=1&left=4&right=0
[Wed Aug 26 11:11:29.080751 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP 2. session_start() /var/www/cowrean_logs/alpha/main.php:47, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=1&left=4&right=0
[Wed Aug 26 11:11:29.081747 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP Notice: Undefined property: mysqli::$close in /var/www/cowrean_logs/alpha/mod_execute_log.php on line 131, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=1&left=4&right=0
[Wed Aug 26 11:11:29.081769 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP Stack trace:, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=1&left=4&right=0
[Wed Aug 26 11:11:29.081790 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP 1. {main}() /var/www/cowrean_logs/alpha/main.php:0, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=1&left=4&right=0
[Wed Aug 26 11:11:29.081801 2015] [:error] [pid 18894] [client 192.168.0.100:54747] PHP 2. include() /var/www/cowrean_logs/alpha/main.php:118, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?top=1&left=4&right=0
[Wed Aug 26 11:11:35.819211 2015] [:error] [pid 21277] [client 192.168.0.100:54748] PHP Notice: A session had already been started - ignoring session_start() in /var/www/cowrean_logs/alpha/main.php on line 47, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?left=7&top=1&right=0
[Wed Aug 26 11:11:35.819247 2015] [:error] [pid 21277] [client 192.168.0.100:54748] PHP Stack trace:, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?left=7&top=1&right=0
[Wed Aug 26 11:11:35.819267 2015] [:error] [pid 21277] [client 192.168.0.100:54748] PHP 1. {main}() /var/www/cowrean_logs/alpha/main.php:0, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?left=7&top=1&right=0
[Wed Aug 26 11:11:35.819279 2015] [:error] [pid 21277] [client 192.168.0.100:54748] PHP 2. session_start() /var/www/cowrean_logs/alpha/main.php:47, referer: http://192.168.0.10/cowrean_logs/alpha/main.php?left=7&top=1&right=0
I would not post whole config-files because "/etc/php5/apache2/php.ini" and "/etc/php5/cli/php.ini" got more than 600 lines!
I think these lines could be interested, but they are in both files identical -.-
post_max_size = 20M
max_execution_time = 30
memory_limit = -1
Got anyone have a solution for me to kick out the syscall from my code? And include the log-reader script directly into my page? Syscalls doesn't look fine!
Ubuntu 14.4
PHP5
Apache2
PHP-CLI
In the script in question add this at the top of the code
<?php
ini_set('max_execution_time', -1 );
This will tell PHP not to timeout this script.
It has its dangers, for example if you manage to code and infinite loop then the script will run till you kill either apache or PHP, depending on your configuration.
It is best not to change this in the php.ini as that will effect every php script.
Related
I have a simple website deployed on Elastic BeanTalk ( platform: PHP 5.6 ).
public
|about.html
|index.html
|style.css
|+ include
|subscribe-email.php
|+ phpmailer
When I checked the log, I received many errors related to '.php' not found or unable to stat. I don't know from where these php files were generated.
[Thu Jun 21 06:18:52.967190 2018] [:error] [pid 12523] [client xxx] script '/var/www/html/xxxx/public/wp-login.php' not found or unable to stat
[Thu Jun 21 06:25:46.354172 2018] [:error] [pid 12742] [client xxx] script '/var/www/html/xxxx/public/wp-login.php' not found or unable to stat
[Thu Jun 21 06:44:44.392342 2018] [:error] [pid 12963] [client xxx] script '/var/www/html/xxxx/public/wp-login.php' not found or unable to stat
[Thu Jun 21 07:18:12.899793 2018] [:error] [pid 13726] [client xxx] script '/var/www/html/xxxx/public/index.php' not found or unable to stat
[Thu Jun 21 07:18:24.145541 2018] [:error] [pid 13531] [client xxx] script '/var/www/html/xxxx/public/wuwu11.php' not found or unable to stat
[Thu Jun 21 07:18:24.925862 2018] [:error] [pid 13418] [client xxx] script '/var/www/html/xxxx/public/xw.php' not found or unable to stat
[Thu Jun 21 07:18:25.689064 2018] [:error] [pid 13418] [client xxx] script '/var/www/html/xxxx/public/xx.php' not found or unable to stat
[Thu Jun 21 07:18:26.489205 2018] [:error] [pid 13418] [client xxx] script '/var/www/html/xxxx/public/s.php' not found or unable to stat
[Thu Jun 21 07:18:27.282847 2018] [:error] [pid 13418] [client xxx] script '/var/www/html/xxxx/public/w.php' not found or unable to stat
[Thu Jun 21 07:18:28.081399 2018] [:error] [pid 13418] [client xxx] script '/var/www/html/xxxx/public/sheep.php' not found or unable
Any suggestion is appreciated.
It is not a solution but I had the same issue.
I'm posting it as an answer to be able to upload an image.
I found something very similar. Also PHP 5.6.
It was new droplet, recently updated. Ubuntu 16, I added a repo to be able to install PHP 5.6 instead of PHP 7 which is the default.
sudo add-apt-repository ppa:ondrej/php
Where does it comes from?
I get A lot of Error message and even some time server get hang from time to time
After check we get tow kind of Error repeated
Using Cento7 PHP5.6.30
/usr/local/apache/logs/error_log 1
[Mon May 07 01:00:20.638252 2018] [:error] [pid 7023:tid
139835738089216] [client 141.101.77.10:19927] PHP Fatal error: Call
to undefined function get_bloginfo() in
/home/XXX/public_html/home/wp-includes/class-wp-locale.php on line 231
[Mon May 07 01:00:25.681306 2018] [:error] [pid 9828:tid
139835780052736] [client 162.158.75.246:9299] PHP Fatal error: Call
to undefined function get_bloginfo() in
/home/XXX/public_html/home/wp-includes/class-wp-locale.php on line 231
[Mon May 07 01:00:29.018727 2018] [:error] [pid 7122:tid
139835847194368] [client 141.101.77.148:18581] PHP Fatal error: Call
to undefined function get_bloginfo() in
/home/XXX/public_html/home/wp-includes/class-wp-locale.php on line 231
[Mon May 07 01:00:35.808256 2018] [:error] [pid 7022:tid
139835838801664] [client 172.68.58.85:29845] PHP Fatal error: Call to
undefined function get_bloginfo() in
/home/XXX/public_html/home/wp-includes/class-wp-locale.php on line 231
[Mon May 07 01:00:38.813252 2018] [:error] [pid 9828:tid
139835973637888] [client 141.101.76.42:33479] PHP Fatal error: Call
to undefined function get_bloginfo() in
/home/XXX/public_html/home/wp-includes/class-wp-locale.php on line 231
2
[Mon May 07 12:57:07.966797 2018] [:error] [pid 9930:tid
139835973637888] [client 162.158.74.35:36655] File does not exist:
/home/XXX/public_html/index.php, referer:
http://www.almshaheer.com/article2-460759 [Mon May 07 12:57:20.420644
2018] [:error] [pid 7122:tid 139835830408960] [client
162.158.75.12:11787] File does not exist: /home/XXX/public_html/index.php, referer:
http://www.almshaheer.com/article2-585530 [Mon May 07 12:57:21.005455
2018] [:error] [pid 9930:tid 139835746481920] [client
172.68.58.37:23343] File does not exist: /home/XXX/public_html/index.php, referer:
http://www.almshaheer.com/article2-532518 [Mon May 07 12:58:59.024635
2018] [:error] [pid 9828:tid 139835754874624] [client
172.68.58.61:28733] File does not exist: /home/XXX/public_html/index.php, referer:
http://www.almshaheer.com/article2-696480 [Mon May 07 13:00:28.328754
2018] [:error] [pid 9828:tid 139835965245184] [client
162.158.75.240:17833] File does not exist: /home/XXX/public_html/index.php, referer:
http://www.almshaheer.com/article2-192047
any help, please
I'm trying to create a new WordPress site but I don't know the cause why I'm getting an error in the second part of installation (Information Needed) where we have to put the site title, username, password and email.
HTTP 500 error The localhost page isn’t working
And so, I can't login on this site because the data is not saved on phpMyAdmin database.
All data is correct database name, username and password. I don't get why it has database kind of error. This is Apache error log:
[Wed Jan 18 14:55:15.767038 2017] [:error] [pid 10596:tid 1664] [client ::1:62560] WordPress database error Unknown column 'myslca_' in 'field list' for query SELECT myslca_, referer: http://localhost:8020/sample-slca/wp-admin/setup-config.php?step=1
[Wed Jan 18 14:56:13.054742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP Fatal error: Maximum execution time of 30 seconds exceeded in C:\\xampp\\htdocs\\sample-slca\\wp-includes\\Requests\\Transport\\cURL.php on line 437, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
[Wed Jan 18 14:56:13.055742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP Stack trace:, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
[Wed Jan 18 14:56:13.056742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP 1. {main}() C:\\xampp\\htdocs\\sample-slca\\wp-admin\\install.php:0, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
[Wed Jan 18 14:56:13.056742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP 2. wp_install() C:\\xampp\\htdocs\\sample-slca\\wp-admin\\install.php:375, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
[Wed Jan 18 14:56:13.057742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP 3. wp_install_maybe_enable_pretty_permalinks() C:\\xampp\\htdocs\\sample-slca\\wp-admin\\includes\\upgrade.php:94, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
[Wed Jan 18 14:56:13.058742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP 4. wp_remote_get() C:\\xampp\\htdocs\\sample-slca\\wp-admin\\includes\\upgrade.php:340, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
[Wed Jan 18 14:56:13.059742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP 5. WP_Http->get() C:\\xampp\\htdocs\\sample-slca\\wp-includes\\http.php:170, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
[Wed Jan 18 14:56:13.059742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP 6. WP_Http->request() C:\\xampp\\htdocs\\sample-slca\\wp-includes\\class-http.php:593, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
[Wed Jan 18 14:56:13.060742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP 7. Requests::request() C:\\xampp\\htdocs\\sample-slca\\wp-includes\\class-http.php:366, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
[Wed Jan 18 14:56:13.061742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP 8. Requests_Transport_cURL->request() C:\\xampp\\htdocs\\sample-slca\\wp-includes\\class-requests.php:379, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
[Wed Jan 18 14:56:13.061742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP 9. curl_exec() C:\\xampp\\htdocs\\sample-slca\\wp-includes\\Requests\\Transport\\cURL.php:162, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
[Wed Jan 18 14:56:13.062742 2017] [:error] [pid 10596:tid 1704] [client ::1:62576] PHP 10. Requests_Transport_cURL->stream_headers() C:\\xampp\\htdocs\\sample-slca\\wp-includes\\Requests\\Transport\\cURL.php:162, referer: http://localhost:8020/sample-slca/wp-admin/install.php?language=en_US
This question already has answers here:
Am I being hacked?
(4 answers)
Closed 5 years ago.
I was reading the logs of the Apache server and I was shocked by seeing these logs!
[Sun Oct 25 06:44:48.922248 2015] [mpm_prefork:notice] [pid 17635] AH00163: Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.13 configured -- resuming normal operations
[Sun Oct 25 06:44:48.922322 2015] [core:notice] [pid 17635] AH00094: Command line: '/usr/sbin/apache2'
[Sun Oct 25 06:52:03.432156 2015] [:error] [pid 12247] [client 185.25.151.159:52483] script '/var/www/testproxy.php' not found or unable to stat
[Sun Oct 25 10:04:07.474749 2015] [:error] [pid 12246] [client 95.213.177.126:26970] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Sun Oct 25 13:30:45.499151 2015] [:error] [pid 12249] [client 95.213.177.124:12337] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Sun Oct 25 14:56:17.907266 2015] [core:error] [pid 12247] [client 204.232.231.193:42272] AH00126: Invalid URI in request GET HTTP/1.1 HTTP/1.1
[Sun Oct 25 16:47:51.671775 2015] [:error] [pid 13152] [client 95.213.177.122:22221] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Sun Oct 25 20:05:20.347574 2015] [:error] [pid 12250] [client 95.213.177.126:26093] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Sun Oct 25 20:12:20.573716 2015] [:error] [pid 12247] [client 195.211.154.57:59906] script '/var/www/wp-login.php' not found or unable to stat
[Sun Oct 25 20:12:20.925707 2015] [:error] [pid 12246] [client 195.211.154.57:59982] script '/var/www/wp-login.php' not found or unable to stat
[Sun Oct 25 20:12:21.286692 2015] [:error] [pid 14778] [client 195.211.154.57:60061] script '/var/www/wp-login.php' not found or unable to stat
[Sun Oct 25 20:12:21.653284 2015] [:error] [pid 12248] [client 195.211.154.57:60129] script '/var/www/wp-login.php' not found or unable to stat
[Sun Oct 25 23:40:01.996372 2015] [:error] [pid 13152] [client 95.213.177.125:11645] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Mon Oct 26 02:51:58.571464 2015] [:error] [pid 12247] [client 185.49.14.190:56375] script '/var/www/testproxy.php' not found or unable to stat
[Mon Oct 26 03:06:19.339766 2015] [:error] [pid 12246] [client 95.213.177.125:57675] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Mon Oct 26 05:40:34.837617 2015] [:error] [pid 12249] [client 212.26.4.140:45817] PHP Notice: Undefined index: fileToUpload in /var/www/upload.php on line 16, referer: http://MyServerIPAddress/index.html
[Mon Oct 26 05:40:34.845077 2015] [:error] [pid 12249] [client 212.26.4.140:45817] PHP Notice: Undefined index: fileToUpload in /var/www/upload.php on line 36, referer: http://MyServerIPAddress/index.html
[Mon Oct 26 06:35:27.184473 2015] [:error] [pid 12247] [client 95.213.177.123:49908] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Mon Oct 26 10:00:38.818189 2015] [:error] [pid 12250] [client 95.213.177.124:13503] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Mon Oct 26 13:31:03.088079 2015] [:error] [pid 12246] [client 95.213.177.126:29119] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Mon Oct 26 17:00:20.614876 2015] [:error] [pid 12247] [client 95.213.177.126:50712] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Mon Oct 26 20:29:44.660822 2015] [:error] [pid 12250] [client 95.213.177.126:1817] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Tue Oct 27 00:01:58.744948 2015] [:error] [pid 14778] [client 95.213.177.122:21314] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Tue Oct 27 01:11:03.468846 2015] [:error] [pid 18984] [client 185.25.148.240:59900] script '/var/www/testproxy.php' not found or unable to stat
[Tue Oct 27 03:30:14.778881 2015] [:error] [pid 18983] [client 95.213.177.125:18166] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Tue Oct 27 07:03:54.964307 2015] [:error] [pid 13152] [client 95.213.177.125:6661] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Tue Oct 27 10:29:50.276896 2015] [:error] [pid 12246] [client 95.213.177.124:61095] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Tue Oct 27 13:53:21.732290 2015] [:error] [pid 14778] [client 95.213.177.123:60280] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Tue Oct 27 17:21:02.887146 2015] [:error] [pid 12248] [client 95.213.177.125:63152] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Tue Oct 27 20:50:02.216260 2015] [:error] [pid 18983] [client 95.213.177.123:36963] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Tue Oct 27 21:14:02.927072 2015] [:error] [pid 12249] [client 185.25.148.240:60127] script '/var/www/testproxy.php' not found or unable to stat
[Wed Oct 28 00:14:25.724517 2015] [:error] [pid 12250] [client 95.213.177.123:49920] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Wed Oct 28 03:44:31.131853 2015] [:error] [pid 12246] [client 95.213.177.124:43972] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Wed Oct 28 07:10:14.870620 2015] [:error] [pid 18983] [client 95.213.177.122:64165] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Wed Oct 28 10:41:34.266047 2015] [:error] [pid 12249] [client 95.213.177.122:7384] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Wed Oct 28 14:04:14.227135 2015] [:error] [pid 13152] [client 95.213.177.122:51171] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Wed Oct 28 16:20:24.056612 2015] [:error] [pid 12247] [client 91.196.50.33:37592] script '/var/www/testproxy.php' not found or unable to stat
[Wed Oct 28 17:24:12.731783 2015] [:error] [pid 12250] [client 95.213.177.126:63964] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Wed Oct 28 21:01:47.135810 2015] [:error] [pid 12246] [client 95.213.177.122:46135] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Thu Oct 29 00:26:45.812360 2015] [:error] [pid 12249] [client 95.213.177.123:4377] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Thu Oct 29 03:51:35.202020 2015] [:error] [pid 13152] [client 95.213.177.123:5403] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Thu Oct 29 07:16:27.154161 2015] [:error] [pid 14778] [client 95.213.177.125:60001] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Thu Oct 29 10:47:57.392473 2015] [mpm_prefork:notice] [pid 17635] AH00169: caught SIGTERM, shutting down
[Thu Oct 29 10:47:58.276766 2015] [mpm_prefork:notice] [pid 10744] AH00163: Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.14 configured -- resuming normal operations
[Thu Oct 29 10:47:58.276856 2015] [core:notice] [pid 10744] AH00094: Command line: '/usr/sbin/apache2'
[Thu Oct 29 10:48:00.183820 2015] [mpm_prefork:notice] [pid 10744] AH00169: caught SIGTERM, shutting down
[Thu Oct 29 10:48:01.268504 2015] [mpm_prefork:notice] [pid 11109] AH00163: Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.14 configured -- resuming normal operations
[Thu Oct 29 10:48:01.268593 2015] [core:notice] [pid 11109] AH00094: Command line: '/usr/sbin/apache2'
[Thu Oct 29 10:53:55.208328 2015] [:error] [pid 11117] [client 95.213.177.126:24617] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Thu Oct 29 12:05:44.568022 2015] [:error] [pid 11116] [client 185.25.151.159:44881] script '/var/www/testproxy.php' not found or unable to stat
[Thu Oct 29 14:23:29.206838 2015] [:error] [pid 11113] [client 95.213.177.122:51825] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Thu Oct 29 17:46:40.522593 2015] [:error] [pid 11648] [client 95.213.177.123:6131] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Thu Oct 29 21:19:33.442885 2015] [:error] [pid 11642] [client 95.213.177.126:29530] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Thu Oct 29 21:40:04.453806 2015] [:error] [pid 11114] [client 195.211.154.57:60044] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:04.717870 2015] [:error] [pid 11643] [client 195.211.154.57:60066] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:04.982542 2015] [:error] [pid 11117] [client 195.211.154.57:60089] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:05.234578 2015] [:error] [pid 11115] [client 195.211.154.57:60114] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:05.482102 2015] [:error] [pid 11116] [client 195.211.154.57:60141] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:05.740567 2015] [:error] [pid 11113] [client 195.211.154.57:60161] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:05.993417 2015] [:error] [pid 11648] [client 195.211.154.57:60182] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:06.254748 2015] [:error] [pid 11642] [client 195.211.154.57:60210] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:06.501836 2015] [:error] [pid 11114] [client 195.211.154.57:60231] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:06.753228 2015] [:error] [pid 11643] [client 195.211.154.57:60252] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:07.015822 2015] [:error] [pid 11117] [client 195.211.154.57:60276] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:07.278555 2015] [:error] [pid 11115] [client 195.211.154.57:60304] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:07.529478 2015] [:error] [pid 11116] [client 195.211.154.57:60329] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:07.777850 2015] [:error] [pid 11113] [client 195.211.154.57:60351] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:08.022832 2015] [:error] [pid 11648] [client 195.211.154.57:60371] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:08.268446 2015] [:error] [pid 11642] [client 195.211.154.57:60393] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:08.524456 2015] [:error] [pid 11114] [client 195.211.154.57:60412] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:08.770056 2015] [:error] [pid 11643] [client 195.211.154.57:60434] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:09.031264 2015] [:error] [pid 11117] [client 195.211.154.57:60450] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:09.286882 2015] [:error] [pid 11115] [client 195.211.154.57:60473] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:09.537999 2015] [:error] [pid 11116] [client 195.211.154.57:60494] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:09.796330 2015] [:error] [pid 11113] [client 195.211.154.57:60512] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:10.047986 2015] [:error] [pid 11648] [client 195.211.154.57:60537] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:10.294042 2015] [:error] [pid 11642] [client 195.211.154.57:60560] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:10.549803 2015] [:error] [pid 11114] [client 195.211.154.57:60581] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:10.808650 2015] [:error] [pid 11643] [client 195.211.154.57:60604] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:11.056997 2015] [:error] [pid 11117] [client 195.211.154.57:60625] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:11.301379 2015] [:error] [pid 11115] [client 195.211.154.57:60652] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:11.547697 2015] [:error] [pid 11116] [client 195.211.154.57:60668] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:11.797300 2015] [:error] [pid 11113] [client 195.211.154.57:60693] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:12.056947 2015] [:error] [pid 11648] [client 195.211.154.57:60717] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:12.312125 2015] [:error] [pid 11642] [client 195.211.154.57:60737] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:12.560742 2015] [:error] [pid 11114] [client 195.211.154.57:60757] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:12.813413 2015] [:error] [pid 11643] [client 195.211.154.57:60776] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:13.065100 2015] [:error] [pid 11117] [client 195.211.154.57:60801] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:13.320162 2015] [:error] [pid 11115] [client 195.211.154.57:60824] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:13.569527 2015] [:error] [pid 11116] [client 195.211.154.57:60848] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:13.814746 2015] [:error] [pid 11113] [client 195.211.154.57:60871] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:14.066743 2015] [:error] [pid 11648] [client 195.211.154.57:60887] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:14.326231 2015] [:error] [pid 11642] [client 195.211.154.57:60915] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:14.585975 2015] [:error] [pid 11114] [client 195.211.154.57:60936] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:14.844341 2015] [:error] [pid 11643] [client 195.211.154.57:60956] script '/var/www/wp-login.php' not found or unable to stat
[Thu Oct 29 21:40:15.095272 2015] [:error] [pid 11117] [client 195.211.154.57:60981] script '/var/www/wp-login.php' not found or unable to stat
[Fri Oct 30 00:47:05.284551 2015] [:error] [pid 11115] [client 95.213.177.125:26477] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Fri Oct 30 04:09:19.403419 2015] [:error] [pid 11116] [client 95.213.177.122:31198] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Fri Oct 30 07:42:17.527746 2015] [:error] [pid 11648] [client 95.213.177.124:59115] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Fri Oct 30 10:13:59.016697 2015] [:error] [pid 11642] [client 91.196.50.33:36603] script '/var/www/testproxy.php' not found or unable to stat
[Fri Oct 30 11:06:15.666434 2015] [:error] [pid 11114] [client 95.213.177.123:16988] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Fri Oct 30 14:28:18.705393 2015] [:error] [pid 11643] [client 95.213.177.124:53349] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Fri Oct 30 17:58:00.532339 2015] [:error] [pid 11115] [client 95.213.177.122:53827] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Fri Oct 30 21:12:46.869377 2015] [:error] [pid 11116] [client 95.213.177.122:54578] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Sat Oct 31 00:35:01.994847 2015] [:error] [pid 11113] [client 95.213.177.123:2596] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Sat Oct 31 02:24:36.644160 2015] [:error] [pid 11648] [client 185.25.148.240:58843] script '/var/www/testproxy.php' not found or unable to stat
[Sat Oct 31 04:05:26.854168 2015] [:error] [pid 11642] [client 95.213.177.123:5184] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Sat Oct 31 04:43:12.015411 2015] [:error] [pid 11114] [client 91.196.50.33:46098] script '/var/www/testproxy.php' not found or unable to stat
[Sat Oct 31 07:25:14.509690 2015] [:error] [pid 11117] [client 95.213.177.123:3185] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
[Sat Oct 31 10:15:58.489698 2015] [:error] [pid 11115] [client 5.8.66.115:54407] script '/var/www/xmlrpc.php' not found or unable to stat
[Sat Oct 31 10:46:10.183445 2015] [:error] [pid 11116] [client 95.213.177.122:28801] script '/var/www/azenv.php' not found or unable to stat, referer: https://proxyradar.com/
Should I be concerned with these logs? Do they indicate any kind of attack?
The ip trying to do all that stuff is coming from Poland. How can I ban this ip and remove all of the files he/she put on my server? I am using digitalocean service; is that related?
I saw similar traffic. My guess is someone is trying to exploit some kind of bug. I saw this sample code. See #joveha's comment.
I have no idea of what version of PHP I was using before, but I'm guessing it was an older version because it was working just fine before I switched from Nginx to Apache. I think I was using an older version of PHP on Nginx. Anyhow this is an example of code that is said to be deprecated. I am now on PHP 5.5.9.
<?php
// Establishing Connection with Server by passing server_name, user_id and password as a parameter
$connection = mysql_connect("localhost", "username", "password");
// Selecting Database
$db = mysql_select_db("database", $connection);
session_start();// Starting Session
// Storing Session
$user_check=$_SESSION['login_user'];
// SQL Query To Fetch Complete Information Of User
$ses_sql=mysql_query("select name from table where name='$user_check'", $connection);
$row = mysql_fetch_assoc($ses_sql);
$login_session =$row['name'];
if(!isset($login_session)){
mysql_close($connection); // Closing Connection
header('Location: index.php'); // Redirecting To Home Page
}
?>
All of my pages use PHP code similar to this so I'm just going to post one of them. This is my error log.
[Mon Jan 12 03:03:40.456254 2015] [mpm_event:notice] [pid 2415:tid 3074542208] AH00489: Apache/2.4.7 (Ubuntu) configured -- resuming normal operations
[Mon Jan 12 03:03:40.456344 2015] [core:notice] [pid 2415:tid 3074542208] AH00094: Command line: '/usr/sbin/apache2'
[Mon Jan 12 03:04:42.038619 2015] [mpm_event:notice] [pid 2415:tid 3074542208] AH00491: caught SIGTERM, shutting down
[Mon Jan 12 03:04:43.100702 2015] [mpm_prefork:notice] [pid 3617] AH00163: Apache/2.4.7 (Ubuntu) configured -- resuming normal operations
[Mon Jan 12 03:04:43.100786 2015] [core:notice] [pid 3617] AH00094: Command line: '/usr/sbin/apache2'
[Mon Jan 12 03:04:44.344041 2015] [mpm_prefork:notice] [pid 3617] AH00169: caught SIGTERM, shutting down
[Mon Jan 12 03:04:45.489917 2015] [mpm_prefork:notice] [pid 3708] AH00163: Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.5 configured -- resuming normal operations
[Mon Jan 12 03:04:45.489959 2015] [core:notice] [pid 3708] AH00094: Command line: '/usr/sbin/apache2'
[Mon Jan 12 03:06:19.837552 2015] [mpm_prefork:notice] [pid 3708] AH00169: caught SIGTERM, shutting down
[Mon Jan 12 03:06:20.873964 2015] [mpm_prefork:notice] [pid 3925] AH00163: Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.5 configured -- resuming normal operations
[Mon Jan 12 03:06:20.874005 2015] [core:notice] [pid 3925] AH00094: Command line: '/usr/sbin/apache2'
[Mon Jan 12 03:07:37.795009 2015] [:error] [pid 3932] [client 108.162.238.215:57356] script '/var/www/html/info.php' not found or unable to stat
[Mon Jan 12 03:09:01.713565 2015] [:error] [pid 3928] [client 108.162.238.215:28781] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4
[Mon Jan 12 03:09:06.002298 2015] [:error] [pid 3928] [client 108.162.238.215:28781] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4
[Mon Jan 12 03:09:17.906216 2015] [:error] [pid 3946] [client 108.162.238.215:64299] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4
[Mon Jan 12 03:09:23.456198 2015] [:error] [pid 3931] [client 108.162.238.215:36456] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4, referer: https://epicmc.us/404.php
[Mon Jan 12 03:09:26.631794 2015] [:error] [pid 3931] [client 108.162.238.215:36456] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4, referer: https://epicmc.us/404.php
[Mon Jan 12 03:09:55.207111 2015] [mpm_prefork:notice] [pid 3925] AH00169: caught SIGTERM, shutting down
[Mon Jan 12 03:09:55.300465 2015] [mpm_prefork:notice] [pid 3996] AH00163: Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.5 configured -- resuming normal operations
[Mon Jan 12 03:09:55.300511 2015] [core:notice] [pid 3996] AH00094: Command line: '/usr/sbin/apache2'
[Mon Jan 12 03:09:59.717164 2015] [:error] [pid 4001] [client 108.162.238.215:16174] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4, referer: https://epicmc.us/404.php
[Mon Jan 12 03:10:25.281382 2015] [:error] [pid 4002] [client 108.162.238.215:18754] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4
[Mon Jan 12 03:11:03.812550 2015] [:error] [pid 3999] [client 108.162.238.215:47026] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4
[Mon Jan 12 03:11:39.560256 2015] [:error] [pid 4016] [client 108.162.238.215:28585] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4
[Mon Jan 12 03:14:36.371451 2015] [:error] [pid 4001] [client 108.162.238.215:29588] PHP Notice: Undefined index: player in /var/www/html/stats.php on line 7
[Mon Jan 12 03:14:36.387589 2015] [:error] [pid 4017] [client 63.142.248.45:58023] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/api.php on line 9
[Mon Jan 12 03:14:36.387889 2015] [:error] [pid 4001] [client 108.162.238.215:29588] PHP Warning: file_get_contents(http://epicmc.us/api.php?task=stats&player=): failed to open stream: HTTP request failed! HTTP/1.0 500 Internal Server Error\r\n in /var/www/html/stats.php on line 7
[Mon Jan 12 03:14:36.387942 2015] [:error] [pid 4001] [client 108.162.238.215:29588] PHP Notice: Undefined index: player in /var/www/html/stats.php on line 10
[Mon Jan 12 03:14:36.387956 2015] [:error] [pid 4001] [client 108.162.238.215:29588] PHP Notice: Undefined index: player in /var/www/html/stats.php on line 20
[Mon Jan 12 03:14:36.388029 2015] [:error] [pid 4001] [client 108.162.238.215:29588] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4
[Mon Jan 12 03:14:40.516471 2015] [:error] [pid 4001] [client 108.162.238.215:29588] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/api.php on line 9
[Mon Jan 12 03:16:26.882760 2015] [:error] [pid 4003] [client 108.162.214.137:51884] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4, referer: https://epicmc.us
[Mon Jan 12 03:18:35.605165 2015] [mpm_prefork:notice] [pid 3996] AH00169: caught SIGTERM, shutting down
[Mon Jan 12 03:18:36.649524 2015] [mpm_prefork:notice] [pid 4105] AH00163: Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.5 configured -- resuming normal operations
[Mon Jan 12 03:18:36.649586 2015] [core:notice] [pid 4105] AH00094: Command line: '/usr/sbin/apache2'
[Mon Jan 12 03:18:40.845243 2015] [:error] [pid 4111] [client 108.162.238.215:26322] PHP Notice: Undefined index: player in /var/www/html/stats.php on line 7
[Mon Jan 12 03:18:40.849347 2015] [:error] [pid 4112] [client 63.142.248.45:34942] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/api.php on line 9
[Mon Jan 12 03:18:40.849619 2015] [:error] [pid 4111] [client 108.162.238.215:26322] PHP Warning: file_get_contents(http://epicmc.us/api.php?task=stats&player=): failed to open stream: HTTP request failed! HTTP/1.0 500 Internal Server Error\r\n in /var/www/html/stats.php on line 7
[Mon Jan 12 03:18:40.849660 2015] [:error] [pid 4111] [client 108.162.238.215:26322] PHP Notice: Undefined index: player in /var/www/html/stats.php on line 10
[Mon Jan 12 03:18:40.849671 2015] [:error] [pid 4111] [client 108.162.238.215:26322] PHP Notice: Undefined index: player in /var/www/html/stats.php on line 20
[Mon Jan 12 03:18:40.850012 2015] [:error] [pid 4111] [client 108.162.238.215:26322] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 4
[Mon Jan 12 03:22:59.264503 2015] [:error] [pid 4110] [client 108.162.238.215:39205] PHP Fatal error: Call to undefined function mysqli_connect() in /var/www/html/session.php on line 3
[Mon Jan 12 03:25:15.361204 2015] [:error] [pid 4109] [client 108.162.238.215:31116] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 3
[Mon Jan 12 03:26:55.673865 2015] [:error] [pid 4108] [client 108.162.238.215:44137] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 3
[Mon Jan 12 03:26:59.193970 2015] [:error] [pid 4112] [client 108.162.238.215:43815] PHP Notice: Undefined index: player in /var/www/html/stats.php on line 7
[Mon Jan 12 03:26:59.197756 2015] [:error] [pid 4125] [client 63.142.248.45:44475] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/api.php on line 9
[Mon Jan 12 03:26:59.197950 2015] [:error] [pid 4112] [client 108.162.238.215:43815] PHP Warning: file_get_contents(http://epicmc.us/api.php?task=stats&player=): failed to open stream: HTTP request failed! HTTP/1.0 500 Internal Server Error\r\n in /var/www/html/stats.php on line 7
[Mon Jan 12 03:26:59.197982 2015] [:error] [pid 4112] [client 108.162.238.215:43815] PHP Notice: Undefined index: player in /var/www/html/stats.php on line 10
[Mon Jan 12 03:26:59.197992 2015] [:error] [pid 4112] [client 108.162.238.215:43815] PHP Notice: Undefined index: player in /var/www/html/stats.php on line 20
[Mon Jan 12 03:26:59.198047 2015] [:error] [pid 4112] [client 108.162.238.215:43815] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/session.php on line 3
[Mon Jan 12 03:27:03.942299 2015] [:error] [pid 4111] [client 108.162.238.215:51061] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/api.php on line 9
[Mon Jan 12 03:27:16.010513 2015] [:error] [pid 4110] [client 108.162.238.215:42175] PHP Fatal error: Call to undefined function mysql_connect() in /var/www/html/api.php on line 9
If somebody out there could re-write the entire PHP code I posted above in PHP 5 format so that I know where to start that would be awesome. Currently Apache2 is just a blank site with only a couple HTML elements working here and there. Sorry if this sounds like a noob question I'd just really like a reference.
There is two php.ini files. One is in /etc/php5/apache2
PHP INI ATTACHED EXTERNALLY BECAUSE I DON'T HAVE ENOUGH ROOM TO POST IT HERE
http://pastebin.com/UpwuC2Hj
you appear to be missing the mysql modules for php. installing them should get your site back up again, then you can start on upgrading your code.
read the comments in the section Dynamic Extensions of the ini file and uncomment the correct line.