Board index   FAQ   Search  
Register  Login
Board index php forum :: php coding PHP coding => General

how to ping

Ask about general coding issues or problems here.

Moderators: macek, egami, gesf

how to ping

Postby leon » Tue Apr 29, 2003 4:29 am

Hi !

anyone can tell me why this little script does not work ?
( I receive following error
ping: icmp open socket: Operation not permitted )


Code: Select all
<?
$domain="yahoo.com";
$run = shell_exec("/bin/ping -c5 -n -q -w5 $domain 2>&1");
echo $run;
?>


Thanks 1000X!
User avatar
leon
New php-forum User
New php-forum User
 
Posts: 36
Joined: Sat Aug 03, 2002 11:54 am

Postby Oleg Butuzov » Tue Apr 29, 2003 11:01 pm

you are not root - Unix system admin

BTW
http://pear.php.net/package-info.php?pacid=12
Oleg Butuzov
Last Samuray
Last Samuray
 
Posts: 831
Joined: Sun Jun 02, 2002 3:09 am

Postby leon » Wed Apr 30, 2003 12:25 am

Understand , Thank you for link !!!
User avatar
leon
New php-forum User
New php-forum User
 
Posts: 36
Joined: Sat Aug 03, 2002 11:54 am

Postby leon » Wed Apr 30, 2003 1:24 am

unluckly pear link didn't help .It still require root and my php scripts run nobody .Searching a perl script :cry:
User avatar
leon
New php-forum User
New php-forum User
 
Posts: 36
Joined: Sat Aug 03, 2002 11:54 am

Postby mike » Sun May 04, 2003 7:00 am

Try the simple ping "ping domain.com"
User avatar
mike
New php-forum User
New php-forum User
 
Posts: 73
Joined: Sun May 04, 2003 4:26 am
Location: Athens


Return to PHP coding => General

Who is online

Users browsing this forum: No registered users and 3 guests

Sponsored by Sitebuilder Web hosting and Traduzioni Italiano Rumeno and antispam for cPanel.