Solved

Test if site exists from Windows command line.

Posted on 2006-07-19
3
271 Views
Last Modified: 2010-03-19
I need to be able to find out if a specific site exists via the Windows CLI.
At first I was just using ping.
ping www.google.com
that shows me that www.google.com exists. But if I try say:
ping www.google.com/linux
then I get a "host not found" error even though I know that www.google.com/linux exists.

So obviously ping will not work. In the end I am trying to write a .BAT file where I can put in a domain name and it will automatically check if certain things exist. Like I can put in www.example.com and it will check for the existence of:
www.example.com/scripts
www.example.com/flash
www.example.com/old

What would be the best tool or technique to do this with? It has to be from the windows command line and I have to be able to automate it. I am not averse to downloading small utilities to call from the script but they have to be free and/or open source.

Thanks.
0
Comment
Question by:xy8088
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 5

Accepted Solution

by:
Dbergert earned 500 total points
ID: 17140927
ping uses ICMP and you are trying to use HTTP/..

you need wget for windows.   http://wget.techknight.com/

then you can run

wget http://wget.techknight.com/test.htm


0
 
LVL 3

Author Comment

by:xy8088
ID: 17140994
Awesome. Using "wget --spider -nv" does pretty much what I need. Thanks!
0
 
LVL 5

Expert Comment

by:Dbergert
ID: 17141035
Np, have a good one.
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Exchange 2016 - not receiving mail 17 100
Add GoToMeeting Invites Rooms to Exchange Conference Rooms 2 58
Reconfigure Corporate IP Address Scheme 2 62
Wannacry 44 104
Short answer to this question: there is no effective WiFi manager in iOS devices as seen in Windows WiFi or Macbook OSx WiFi management, but this article will try and provide some amicable solutions to better suite your needs.
This article will inform Clients about common and important expectations from the freelancers (Experts) who are looking at your Gig.
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question