LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-21-2006, 01:46 AM   #1
rajnair0278
Member
 
Registered: Mar 2006
Posts: 62

Rep: Reputation: 15
Angry Configure Php for wget.....Anybody?????


When I type wget http://xxx.xxx.xxx.xxx/file.csv at the shell prompt it downloads the file smoothly. However when I enter the command
<?php
exec ("wget http://xxx.xxx.xxx.xxx/filename.csv")
?>
into a download.php file and execute it in the browser it doesnot download the file. When I move this download.php file to a another php-linux server it works fine. What is my server missing?? Is php not configured to accept wget?? If so, how can i overcome the problem.

Any steps and suggestions will be appreciated. My php version is 4.2.2. This is inspite of installing 5.1, phpinfo() still shows the installed version as 4.2.2

Pls, anybody out there....???
 
Old 03-21-2006, 02:13 AM   #2
nixcraft
Member
 
Registered: Nov 2004
Location: BIOS
Distribution: RHEL3.0, FreeBSD 5.x, Debian 3.x, Soaris x86 v10
Posts: 379

Rep: Reputation: 30
For security causes many sys admin blocks access to shell via exec and system (and other calls)
Or your apache web server runs in chrooted jail

Best way to debug this problem is to check apache log file and php log file
 
Old 03-21-2006, 02:30 AM   #3
rajnair0278
Member
 
Registered: Mar 2006
Posts: 62

Original Poster
Rep: Reputation: 15
Thx nixcraft that suggestion was really helpful. The /var/httpd/logs/error_logs clearly mentions Permission denied: for all the time I was trying the download option. So now I know thats the reason. Now which files permission should I change to enable this download. My apache is installed in /usr/local/httpd and php in /usr/local/php.
Feeling better now that we have zeroed in on the problem?? Thx again.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Urgent!!!!! Help with wget and php exec command ?? rajnair0278 Linux - Software 6 03-21-2006 03:19 AM
configure php with apache varunbihani Linux - Software 1 01-13-2005 05:43 AM
php 4.3.2 configure error adrianmak Linux - Software 0 06-19-2003 08:23 PM
Configure with php kelper Linux - Software 3 01-27-2003 06:47 PM
Configure PHP in RH 8 Ryanitus Linux - Newbie 2 01-03-2003 07:52 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:05 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration