Unable to connect to a website using Curl

 
Thread Tools Search this Thread
Special Forums UNIX and Linux Applications Unable to connect to a website using Curl
# 1  
Old 10-04-2011
Unable to connect to a website using Curl

Hello,

I am using Curl command to make a function call to a web service. The issue I am facing right now is:

curl h**p://www.google.com

with the above command, I get a XML file as a response. Also when i execute :

wget h**p://www.google.com

Replace ** : tt
I can see status as connected. Which concludes the fact that I am able to connect to web.

But there is another web service that we are using. If I try to connect to it using same commands, I am not able connect to it.

The command keeps resolving host name and exits with an error ' Couldn't resolve host'. I am able to connect to the website using the browser ( IE / Chrome ).

Is there any firewall setting on Unix which needs to be disabled in order to achieve this ?

Any option in this regard will be extremely helpful. Let me know if you need any more details.

Thanks in advance

- Amit
# 2  
Old 10-28-2011
Can you ping the target host? If so, can you telnet to port of the service ( normally 80 )?
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Facing difficulty scraping website with curl

Hi, As an exercise, I am attempting to scrape the following website to obtain ticket price for a certain journey, so I can capture the cheapest ticket by running the script hourly. ... (4 Replies)
Discussion started by: sand1234
4 Replies

2. UNIX for Beginners Questions & Answers

Unable to open input kickstart file curl#37

Hi, Getting the below error while installing from ks.cfg unable to open input kickstart file curl#37 Couldn't open file /tmp/swappart Here am trying to include /tmp/swappart file from pre section under disks and partition section. Dont know where exactly am doing wrong My kickstart file... (3 Replies)
Discussion started by: Sumanthsv
3 Replies

3. AIX

Unable to connect ASMI

After following the instructions given by resident moderator Bakunin over here https://www.unix.com/aix/279862-installed-memory-32gb-but-shows-only-16gb.html #1 Connect to ASMI #2 Configure the deconfigured memory #3 Start the machine OK, everything is fine, however now cannot connect to... (5 Replies)
Discussion started by: filosophizer
5 Replies

4. Solaris

Unable to connect using ftp

hi I am having issues when trying to connect using ftp, I am having the following error: User (10.100.48.73:(none)): moz 331 Password required for moza. Password: 530 Login incorrect. Login failed. ftp> by 221 Goodbye. I have created a user like this: useradd -g 10 -d /lam/moza -m -s... (11 Replies)
Discussion started by: fretagi
11 Replies

5. Red Hat

Unable to connect Wireless

I have managed to install Broadcom BCM43228 Wireless adapter on a laptop running CentOS 5.9 using instructions at: wiki.centos.org/HowTos/Laptops/Wireless/Broadcom I had the problem "Error for wireless request "Set Encode" (8B2A): SET failed on device... mentioned on the same page and solved... (0 Replies)
Discussion started by: cooltoad
0 Replies

6. Shell Programming and Scripting

CURL getting Error- couldn't connect to host

Hi i am trying to open HTTP by curl command. i am tryng to do that from command or script BASH. also iptables is off it doesnt work i am getting an error: curl: (7) coudn't connect to host the scipt is: #! /bin/bash curl http://www.cnn.com (1 Reply)
Discussion started by: zigizag
1 Replies

7. Emergency UNIX and Linux Support

Unable to connect using SFTP

I shall explain the situation that I am facing to the best extent possible. I require some help, as this situation is an urgent one. I am trying to automate sending data from one AIX machine to another. A script runs that tries to push data received from an upstream application to another AIX... (7 Replies)
Discussion started by: ggayathri
7 Replies

8. Solaris

Unable to connect to Internet

Hi friends recently i have installed SXDE 1/08 into my machine,and i installed wifi driver also its working fine,Recently i was unable to connect to Internet,I have not changed any configurations and any installations,thing is that i got my iwk0 interface is UP and IP address also and i can... (6 Replies)
Discussion started by: srinivas2828
6 Replies

9. UNIX for Dummies Questions & Answers

can't connect to 1 website

this isn't really a UNIX issue.. but you guys are smart (spelled "s-m-r-t") so I was hoping someone can help me out. I have posted on other forums and no one is able to help me out. For the past 3 months I was playing a browser based game at http://www.ogame.org. It is located in Europe, I... (1 Reply)
Discussion started by: Bobafart
1 Replies

10. HP-UX

Unable to connect to HP-UX 11.11 via eXceed 7.1

Hello HP-UX Gurus, I am having issues trying to start an x-session via eXceed 7.1. When I bring up eXceed via XDMCP Braodcast I see the host name and IP Address but when I try to connect the X window does not come up. I made the modification to the following file “/etc/dt/config/Xaccess”... (2 Replies)
Discussion started by: smokie
2 Replies
Login or Register to Ask a Question